Mitheithel search
MitheithelSearchTool ¶
Bases: StructuredTool
StructuredTool that searches the Internet.
Source code in libs/gptstonks-multiagents/gptstonks/multiagents/tools/mitheithel_search.py
create(name='MitheithelSearch', description='Useful to search anything on the Internet', return_direct=False, timeout=180, use_quality=False, timelimit='w', return_json=False) classmethod ¶
Creates a LangChain tool to interact with Mitheithel API.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name | `str` | tool name for LangChain. | 'MitheithelSearch' |
name | `str` | the purpose of the tool, according to LangChain's documentation. | 'MitheithelSearch' |
return_direct | `bool` | Whether to return the result directly or as a callback. | False |
timeout | `float` | maximum time to wait for a response, in seconds. Speed takes 15-30s, and Quality 120-150s. | 180 |
use_quality | `bool` | whether to use quality or speed mode when searching. | False |
timelimit | `str` | how far into the past our search engine can look for data. One of d, w, m, y. Defaults to one week old. | 'w' |
return_json | `bool` | whether to return the complete JSON or only the content. | False |
Returns:
| Type | Description |
|---|---|
StructuredTool |
|
Source code in libs/gptstonks-multiagents/gptstonks/multiagents/tools/mitheithel_search.py
search(query, timeout=180, use_quality=False, timelimit='w', return_json=False) async classmethod ¶
Searches videos on Youtube related to a query.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
query | `str` | what to search using Mitheithel agents. It works better with full requests in natural language, instead of keywords. | required |
timeout | `float` | maximum time to wait for a response, in seconds. Speed takes 15-30s, and Quality 120-150s. | 180 |
use_quality | `bool` | whether to use quality or speed mode when searching. | False |
timelimit | `str` | how far into the past our search engine can look for data. One of d, w, m, y. Defaults to one week old. | 'w' |
return_json | `bool` | whether to return the complete JSON or only the content. | False |
Returns:
| Type | Description |
|---|---|
str |
|