Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: summary of duckduckgo_search #5488

Merged
merged 1 commit into from
Jun 22, 2024
Merged

fix: summary of duckduckgo_search #5488

merged 1 commit into from
Jun 22, 2024

Conversation

hjlarry
Copy link
Contributor

@hjlarry hjlarry commented Jun 21, 2024

Description

The origin summary method of BuildinTool is check how many token in the content, if the token < 60% of the llm's default max token, it won't work. It seems a support for large context content, But here I think a summary for the whole search result would be better.

Type of Change

  • Improvement, including but not limited to code refactoring, performance optimization, and UI/UX improvement

How Has This Been Tested?

I test the tool node execute result locally.

  • TODO

Suggested Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • I ran dev/reformat(backend) and cd web && npx lint-staged(frontend) to appease the lint gods
  • optional I have made corresponding changes to the documentation
  • optional I have added tests that prove my fix is effective or that my feature works
  • optional New and existing unit tests pass locally with my changes

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. 🐍 python 💪 enhancement New feature or request labels Jun 21, 2024
@crazywoola crazywoola requested a review from Yeuoly June 21, 2024 14:30
Copy link
Collaborator

@Yeuoly Yeuoly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Jun 22, 2024
@Yeuoly Yeuoly merged commit 5706309 into langgenius:main Jun 22, 2024
7 checks passed
XiaoLey pushed a commit to XiaoLey/dify that referenced this pull request Jun 22, 2024
ZhouhaoJiang added a commit that referenced this pull request Jun 24, 2024
* refs/heads/deploy/dev: (273 commits)
  chore: host required
  fix: monitor copywrite
  feat: make show citations enable default
  chore: use singular style in middleware config class name (#5502)
  refactor: extract hosted service configs into dify config (#5504)
  fix: summary of duckduckgo_search (#5488)
  fix: zhipu tool calling, this PR fixes the bug described in issue #5496 (#5469)
  fix: tongyi json output (#5396)
  fix: firecrawl apikey not start with fc- (#5498)
  fix lock
  refactor: extract db configs and celery configs into dify config (#5491)
  refactor: extract storage provider configs into dify configs (#5443)
  chore: use singular style in config class name (#5489)
  chore: remove pip support for api service (#5453)
  Add Oracle23ai as a vector datasource (#5342)
  build: support Poetry for depencencies tool in api's Dockerfile (#5105)
  feat: add ops trace encrypt_config decrypt_config obfuscate_config
  feat: add remove tracing app
  fix: max_tokens of qwen-plus & qwen-plus-chat (#5480)
  feat: add support for Vertex AI claude-3-5-sonnet@20240620 (#5475)
  ...
ZhouhaoJiang added a commit that referenced this pull request Jun 24, 2024
* refs/heads/main: (31 commits)
  feat: support predefined models for openrouter (#5494)
  chore: refactor the http executor node (#5212)
  chore: add create_json_message api for tools (#5440)
  fix(api/model_runtime/azure/llm): Switch to tool_call. (#5541)
  Fix: position of log modal (#5538)
  feat: Add program_name attribute to TiDB connection (#5499)
  add opensearch default value (#5536)
  feat: make Citations and Attributions display enable default (#5508)
  Fix: resolve issue with embedding model field visibility toggling on datasets page (#5451)
  Fix: custom disclaim (#5535)
  Chore: chat log refactor (#5523)
  feat: use root dir to start python and celery (#5515)
  feat: add new features to enhance image and link handling in Jina tool (#5517)
  fix: apply best practices for the latest buildkit (#5527)
  fix: added error handling for novita ai tool query (#5506)
  feat: add Asia/Ho_Chi_Minh timezone (#5521)
  fix: correct typos (#5510)
  chore: use singular style in middleware config class name (#5502)
  refactor: extract hosted service configs into dify config (#5504)
  fix: summary of duckduckgo_search (#5488)
  ...

# Conflicts:
#	api/core/app/apps/advanced_chat/app_generator.py
#	api/poetry.lock
#	api/requirements.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💪 enhancement New feature or request lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants