Skip to content

Commit

Permalink
Update docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
mnicstruwig committed Jun 3, 2024
1 parent 8d66256 commit 4eef9a3
Showing 1 changed file with 20 additions and 13 deletions.
33 changes: 20 additions & 13 deletions openbb_agents/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,6 @@ def openbb_agent(
) -> str:
"""Answer a query using the OpenBB Agent equipped with tools.
By default all available openbb tools are used. You can have a query
answered using a smaller subset of OpenBB tools by using the `openbb_tools`
argument.
Parameters
----------
query : str
Expand All @@ -50,6 +46,12 @@ def openbb_agent(
openbb_pat : str | None, optional
The OpenBB PAT for retrieving credentials from the OpenBB Hub. If not
provided, local OpenBB credentials will be used.
extra_tools : list[Callable] | None, optional
A list of extra tools to add to the tool index, which makes it available
to the LLM to use.
verbose : bool, optional
Whether to print out additional information about the agent's behavior.
Defaults to True.
Examples
--------
Expand All @@ -58,7 +60,6 @@ def openbb_agent(
>>> # Use only the specified tools to answer the query
>>> openbb_agent("What is the stock price of TSLA?",
... openbb_tools=['.equity.price.quote'])
"""
configure_logging(verbose)
if openbb_pat:
Expand Down Expand Up @@ -108,17 +109,23 @@ async def aopenbb_agent(
Async variant of `openbb_agent`.
By default all available openbb tools are used. You can have a query
answered using a smaller subset of OpenBB tools by using the `openbb_tools`
argument.
Parameters
----------
query : str
The query you want to have answered.
openbb_tools : list[Callable]
Optional. Specify the OpenBB functions you want to use. If not
specified, every available OpenBB tool will be used.
The query to be answered.
openbb_tools : list[str] | None, optional
A list of specific OpenBB functions to use. If not provided, all
available OpenBB tools that you have valid credentials for will be
utilized. See `openbb_pat`.
openbb_pat : str | None, optional
The OpenBB PAT for retrieving credentials from the OpenBB Hub. If not
provided, local OpenBB credentials will be used.
extra_tools : list[Callable] | None, optional
A list of extra tools to add to the tool index, which makes it available
to the LLM to use.
verbose : bool, optional
Whether to print out additional information about the agent's behavior.
Defaults to True.
Examples
--------
Expand Down

0 comments on commit 4eef9a3

Please sign in to comment.