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

feat: Tavily search integration #1039

Merged
merged 5 commits into from
Oct 29, 2024
Merged

feat: Tavily search integration #1039

merged 5 commits into from
Oct 29, 2024

Conversation

dxmaptin
Copy link
Collaborator

@dxmaptin dxmaptin commented Oct 10, 2024

Description

Implemented the Tavily search functionality and completed local testing with successful results.

Motivation and Context

This change introduces the search feature to the Tavily API. It addresses the need for efficient search capabilities. This feature enhances the user experience by enabling faster, more relevant search results.

  • I have raised an issue to propose this change (required for new features and bug fixes)

Types of changes

What types of changes does your code introduce? Put an x in all the boxes that apply:

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds core functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (update in the documentation)
  • Example (update in the folder of example)

Implemented Tasks

  • [ x] Integrated search logic
  • [ x] Added unit tests for search functionality
  • [ x] Performed successful local testing

Checklist

Go over all the following points, and put an x in all the boxes that apply.
If you are unsure about any of these, don't hesitate to ask. We are here to help!

  • [ x] I have read the CONTRIBUTION guide. (required)
  • My change requires a change to the documentation.
  • [ x] I have updated the tests accordingly. (required for a bug fix or a new feature)
  • I have updated the documentation accordingly.

@dxmaptin dxmaptin marked this pull request as draft October 10, 2024 18:20
@Wendong-Fan Wendong-Fan added this to the Sprint 14 milestone Oct 11, 2024
@Wendong-Fan Wendong-Fan linked an issue Oct 11, 2024 that may be closed by this pull request
2 tasks
@Wendong-Fan Wendong-Fan marked this pull request as ready for review October 15, 2024 07:41
Copy link
Member

@Wendong-Fan Wendong-Fan left a comment

Choose a reason for hiding this comment

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

Thanks @dxmaptin ! Left some comments below, could we also support tavily extract further?
https://docs.tavily.com/docs/python-sdk/tavily-extract/getting-started

pyproject.toml Outdated Show resolved Hide resolved
pyproject.toml Outdated Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

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

please double check the content in toml file and rerun potry lock to update

camel/toolkits/search_toolkit.py Outdated Show resolved Hide resolved
camel/toolkits/search_toolkit.py Outdated Show resolved Hide resolved
Comment on lines 344 to 354
Example:
{
'result_id': 1,
'title': 'OpenAI',
'description': 'An AI research organization...',
'long_description': 'OpenAI is a non-profit...',
'url': 'https://www.openai.com',
'content': 'OpenAI focuses on AI safety...',
'images': ['https://image.url/1.jpg'],
'published_date': '2024-09-15'
}
Copy link
Member

Choose a reason for hiding this comment

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

the output example should be under Returns part

camel/toolkits/search_toolkit.py Outdated Show resolved Hide resolved
@Wendong-Fan Wendong-Fan changed the title Toolkit/tavily feat: Tavily search integration Oct 15, 2024
@dxmaptin
Copy link
Collaborator Author

Fixed all issues raised above

@Wendong-Fan Wendong-Fan merged commit e02b7ee into master Oct 29, 2024
5 of 6 checks passed
@Wendong-Fan Wendong-Fan deleted the toolkit/tavily branch October 29, 2024 10:32
MuggleJinx pushed a commit that referenced this pull request Oct 30, 2024
Co-authored-by: Wendong <w3ndong.fan@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

[Feature Request] Integrate tavily
2 participants