Commit Graph

177 Commits

Author SHA1 Message Date
Willem Jiang 19a90d59eb fix: handle non-string tool results to fix #631 (#633)
- Backend: Convert non-string content (lists, dicts) to JSON strings in _create_event_stream_message to ensure frontend always receives string content
- Frontend: Add type guard before calling startsWith() on toolCall.result for defensive programming

This fixes the TypeError: toolCall.result.startsWith is not a function when tools return complex objects.
2025-10-20 23:10:58 +08:00
Willem Jiang a0a0057c86 fix: optimize animations to prevent browser freeze with many research steps (#630)
Fixes #570 where browser freezes when research plan has 8+ steps.

Performance optimizations:
- Add animation throttling: only animate first 10 activity items
- Reduce animation durations (0.4s → 0.3s for activities, 0.2s → 0.15s for results)
- Remove scale animations (GPU-intensive) from search results
- Limit displayed results (20 pages, 10 images max)
- Add conditional animations based on item index
- Cap animation delays to prevent excessive staggering
- Add React.memo to ActivityMessage and ActivityListItem components

These changes significantly improve performance when rendering multiple
research steps while maintaining visual appeal for smaller lists.
2025-10-19 19:24:57 +08:00
Willem Jiang a6451251d8 fix: prevent repeated content animation during thinking streaming (#614) (#623)
* fix: prevent repeated content animation during thinking streaming (#614)

- Implement chunked rendering using reasoningContentChunks
- Static content (previous chunks) renders without animation
- Only current streaming chunk animates
- Disable animation on plan content (title, thought, steps) during streaming
- Animation applies after content finishes streaming (when complete)
- Prevents visual duplication of repeated sentences in thinking process
2025-10-16 19:48:05 +08:00
Willem Jiang fd244d8bf6 fix: add unique key prop to conversation starter list items (#619)
- Changed key from question text to combination of index and question text
- Ensures unique keys even if translation has duplicate questions
- Resolves React warning: 'Each child in a list should have a unique key prop'
2025-10-16 18:24:36 +08:00
jimmyuconn1982 fabec4abb6 feat: Add intelligent clarification feature in coordinate step for research queries (#613)
* fix: support local models by making thought field optional in Plan model

- Make thought field optional in Plan model to fix Pydantic validation errors with local models
- Add Ollama configuration example to conf.yaml.example
- Update documentation to include local model support
- Improve planner prompt with better JSON format requirements

Fixes local model integration issues where models like qwen3:14b would fail
due to missing thought field in JSON output.

* feat: Add intelligent clarification feature for research queries

- Add multi-turn clarification process to refine vague research questions
- Implement three-dimension clarification standard (Tech/App, Focus, Scope)
- Add clarification state management in coordinator node
- Update coordinator prompt with detailed clarification guidelines
- Add UI settings to enable/disable clarification feature (disabled by default)
- Update workflow to handle clarification rounds recursively
- Add comprehensive test coverage for clarification functionality
- Update documentation with clarification feature usage guide

Key components:
- src/graph/nodes.py: Core clarification logic and state management
- src/prompts/coordinator.md: Detailed clarification guidelines
- src/workflow.py: Recursive clarification handling
- web/: UI settings integration
- tests/: Comprehensive test coverage
- docs/: Updated configuration guide

* fix: Improve clarification conversation continuity

- Add comprehensive conversation history to clarification context
- Include previous exchanges summary in system messages
- Add explicit guidelines for continuing rounds in coordinator prompt
- Prevent LLM from starting new topics during clarification
- Ensure topic continuity across clarification rounds

Fixes issue where LLM would restart clarification instead of building upon previous exchanges.

* fix: Add conversation history to clarification context

* fix: resolve clarification feature message to planer, prompt, test issues

- Optimize coordinator.md prompt template for better clarification flow
- Simplify final message sent to planner after clarification
- Fix API key assertion issues in test_search.py

* fix: Add configurable max_clarification_rounds and comprehensive tests

- Add max_clarification_rounds parameter for external configuration
- Add comprehensive test cases for clarification feature in test_app.py
- Fixes issues found during interactive mode testing where:
  - Recursive call failed due to missing initial_state parameter
  - Clarification exited prematurely at max rounds
  - Incorrect logging of max rounds reached

* Move clarification tests to test_nodes.py and add max_clarification_rounds to zh.json
2025-10-14 13:35:57 +08:00
HagonChan 4de5724389 feat: add strategic_investment report style (#595)
* add strategic_investment mode

* make format

* make lint

* fix: repair
lint-frontend
2025-09-24 09:50:36 +08:00
CHANGXUBO 84c2eec410 feat: Implement Milvus retriver for RAG (#516)
* feat: Implement MilvusRetriever with embedding model and resource management

* chore: Update configuration and loader files for consistency

* chore: Clean up test_milvus.py for improved readability and organization

* feat: Add tests for DashscopeEmbeddings query and document embedding methods

* feat: Add tests for embedding model initialization and example file loading in MilvusProvider

* chore: Remove unused imports and clean up test_milvus.py for better readability

* chore: Clean up test_milvus.py for improved readability and organization

* chore: Clean up test_milvus.py for improved readability and organization

* fix: replace print statements with logging in recursion limit function

* Implement feature X to enhance user experience and optimize performance

* refactor: clean up unused imports and comments in AboutTab component

* Implement feature X to enhance user experience and fix bug Y in module Z

---------

Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
2025-09-12 22:20:55 +08:00
Willem Jiang f4d70caf2c Fix: build of font end of #466 (#530) 2025-08-21 23:25:52 +08:00
道心坚定韩道友 9c6fa30667 FIX/Adapt message box to handle long text in frontend (#466)
* fix:ui

* fix:ui bug

---------

Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
2025-08-21 10:31:54 +08:00
suntp 96ea40da49 fix: Add streamable MCP server support (#468)
* fix: Add streamable MCP server support(#349)

* “Revert-timeout”

* fix lint and test check

* modify streamable error notify

---------

Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
2025-07-29 14:04:04 +08:00
Willem Jiang a363c2b44b feat: add the Chinese i8n support on the setting table (#404)
* feat: Added i8n to the mcp table

* feat: Added i8n to the about table
2025-07-12 21:28:08 +08:00
johnny0120 5e1b2dfb22 feat: add i18n support and add Chinese (#372)
* feat: add i18n support and add Chinese

* fix: resolve conflicts

* Update en.json with cancle settings

* Update zh.json with settngs cancle

---------

Co-authored-by: johnny0120 <15564476+johnny0120@users.noreply.github.com>
Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
Co-authored-by: Willem Jiang <143703838+willem-bd@users.noreply.github.com>
2025-07-12 15:18:28 +08:00
JeffJiang e4411d80d7 fix: next server fetch error (#374) 2025-06-27 14:23:04 +08:00
Abeautifulsnow 2fcbb91c10 improve: add abort btn to abort the mcp add request. (#284) 2025-06-26 08:51:46 +08:00
Young 208d3344af fix: settings tab display name (#250) 2025-06-19 14:33:00 +08:00
Luludle 8e4de0a498 fix: add line breaks to mcp edit dialog (#313) 2025-06-17 08:31:35 +08:00
3Spiders f924289c4c fix(web): priority displayName for settings name error (#336) 2025-06-17 08:26:13 +08:00
DanielWalnut b6edc0fc8a feat: add deep think feature (#311)
* feat: implement backend logic

* feat: implement api/config endpoint

* rename the symbol

* feat: re-implement configuration at client-side

* feat: add client-side of deep thinking

* fix backend bug

* feat: add reasoning block

* docs: update readme

* fix: translate into English

* fix: change icon to lightbulb

* feat: ignore more bad cases

* feat: adjust thinking layout, and implement auto scrolling

* docs: add comments

---------

Co-authored-by: Henry Li <henry1943@163.com>
2025-06-14 13:12:43 +08:00
JeffJiang 3ee58925af fix: mcp config styles (#320) 2025-06-13 18:01:19 +08:00
Muharrem Okutan 446901ec0b feat: added report download button (#78) 2025-06-11 09:50:48 +08:00
DanielWalnut ffa6604297 feat: implement enhance prompt (#294)
* feat: implement enhance prompt

* add unit test

* fix prompt

* fix: fix eslint and compiling issues

* feat: add border-beam animation

* fix: fix importing issues

---------

Co-authored-by: Henry Li <henry1943@163.com>
2025-06-08 19:41:59 +08:00
DanielWalnut 01b1c21044 feat: support to adjust writing style (#290)
* feat: implment backend for adjust report style

* feat: add web part

* fix test cases

* fix: fix typing

---------

Co-authored-by: Henry Li <henry1943@163.com>
2025-06-07 20:48:39 +08:00
SToneX 3dbf0e36ae feat(chat): add animated deer to response indicator (#269) 2025-05-31 19:13:13 +08:00
JeffJiang 15cdfe631e feat: rag retrieving tool call result display (#263)
* feat: local search tool call result display

* chore: add file copyright

* fix: miss edit plan interrupt feedback

* feat: disable pasting html into input box
2025-05-29 19:52:34 +08:00
JeffJiang d2ffcc5dfb fix: editing plan style (#261) 2025-05-29 10:46:05 +08:00
JeffJiang 0210729ad3 fix: message block width (#257) 2025-05-28 19:11:20 +08:00
JeffJiang 96fd196baa feat: RAG Integration (#238)
* feat: add rag provider and retriever

* feat: retriever tool

* feat: add retriever tool to the researcher node

* feat: add rag http apis

* feat: new message input supports resource mentions

* feat: new message input component support resource mentions

* refactor: need_web_search to need_search

* chore: RAG integration docs

* chore: change example api host

* fix: user message color in dark mode

* fix: mentions style

* feat: add local_search_tool to researcher prompt

* chore: research prompt

* fix: ragflow page size and reporter with

* docs: ragflow integration and add acknowledgment projects

* chore: format
2025-05-28 14:13:46 +08:00
DanielWalnut bc95f4fca6 feat: config max_search_results for search engine (#192)
* feat: implement UI

* feat: config max_search_results for search engine via api

---------

Co-authored-by: Henry Li <henry1943@163.com>
2025-05-18 13:23:52 +08:00
Zhengbin Sun f250de3c00 fix: update responsive design calculations for chat layout (#168) 2025-05-16 11:40:26 +08:00
Leo Hui fac1376df0 feat: refactor crawler trust link style (#166)
* feat: refactor crawler trust link style

* feat: enhance link credibility checks in Markdown and related components
2025-05-15 17:17:10 +08:00
JeffJiang c99513d604 fix: report editor styles (#163)
* fix: report editor styles
2025-05-15 15:18:01 +08:00
Leo Hui cbd0470a8c fix: adjust slider width for responsive design in multi-agent visualization (#134) 2025-05-15 11:59:16 +08:00
JeffJiang 0f9ac7cd23 Check the output links are hallucinations from AI (#139)
* feat: check output links if a hallucination from AI
2025-05-15 10:39:53 +08:00
Henry Li 239098bb20 feat: add python result and error handling (#141) 2025-05-14 03:47:28 -07:00
Henry Li de014db3a5 fix: fix compiling issues 2025-05-13 08:57:09 +08:00
Henry Li be5159a4c1 feat: use number ticker to display star count (#89) 2025-05-12 23:15:43 +08:00
Henry Li fda3b53317 fix: add error handling for podcast generation (#59)
Co-authored-by: Jiang Feng <jiangfeng.11@bytedance.com>
2025-05-12 20:56:38 +08:00
JeffJiang 560ecad165 pref: message render performence (#81)
* fix: message card always unmount when messages change

* pref: add useShallow for complex store selector
2025-05-12 20:21:54 +08:00
Leo Hui 54ee700bb8 feat: show repo star on site-header (#27)
* feat: show repo star on site-header

* feat: add GITHUB_OAUTH_TOKEN to environment configuration

* feat: remove comment

* feat: show star counter only in website
2025-05-12 14:36:50 +08:00
Leo Hui 8c48fd2149 feat: adjust Suspense loading (#26) 2025-05-12 14:33:13 +08:00
Henry Li fdf5208dc5 refactor: rename to `animated` 2025-05-12 11:59:24 +08:00
DanielWalnut e0ef130cd9 feat: add necessary log when no tool calls (#16) 2025-05-09 14:22:07 +08:00
Henry Li 8109de3b73 fix: allow the first activity to be reporting (#8) 2025-05-09 10:32:49 +08:00
Nonoroazoro 5bbaa30b42 fix: auto-scrolling to the bottom occasionally fails when toggling research (#7) 2025-05-08 19:49:56 +08:00
Li Xin a512d77108 fix: fix known issue caused by https://github.com/vercel/next.js/issues/78548 2025-05-08 12:21:21 +08:00
Li Xin e5e3bbc06a feat: integrated with Amplitude in static website mode 2025-05-08 11:13:52 +08:00
Li Xin 03bf6f1f07 feat: enhance replay mode in static website 2025-05-08 09:53:09 +08:00
Li Xin d6c15fa075 docs: rewording 2025-05-08 09:03:12 +08:00
Li Xin 1ce8e21b31 refactor: move to `sections` folder 2025-05-08 08:53:47 +08:00
Jiang Feng 58d9ba37ab fix: general form default value 2025-05-07 13:22:21 +08:00