Harrison/add submodule to docs (#10803)

This commit is contained in:
Harrison Chase
2023-09-19 17:03:32 -07:00
committed by GitHub
parent c15bbaac31
commit 1dae3c383e
2 changed files with 32 additions and 13 deletions

View File

@@ -8,10 +8,10 @@ def render_text_description(tools: List[BaseTool]) -> str:
Output will be in the format of:
```
search: This tool is used for search
calculator: This tool is used for math
```
.. code-block:: markdown
search: This tool is used for search
calculator: This tool is used for math
"""
return "\n".join([f"{tool.name}: {tool.description}" for tool in tools])
@@ -21,10 +21,11 @@ def render_text_description_and_args(tools: List[BaseTool]) -> str:
Output will be in the format of:
```
search: This tool is used for search, args: {"query": {"type": "string"}}
calculator: This tool is used for math, args: {"expression": {"type": "string"}}
```
.. code-block:: markdown
search: This tool is used for search, args: {"query": {"type": "string"}}
calculator: This tool is used for math, \
args: {"expression": {"type": "string"}}
"""
tool_strings = []
for tool in tools: