mirror of
https://github.com/Shubhamsaboo/awesome-llm-apps.git
synced 2026-03-08 23:13:56 -05:00
fix: Update XAI Finance Agent to use new AgentOS and enable debug mode
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
agno
|
||||
agno>=2.2.10
|
||||
duckduckgo-search
|
||||
yfinance
|
||||
fastapi[standard]
|
||||
|
||||
@@ -3,7 +3,7 @@ from agno.agent import Agent
|
||||
from agno.models.xai import xAI
|
||||
from agno.tools.yfinance import YFinanceTools
|
||||
from agno.tools.duckduckgo import DuckDuckGoTools
|
||||
from agno.playground import Playground, serve_playground_app
|
||||
from agno.os import AgentOS
|
||||
|
||||
# create the AI finance agent
|
||||
agent = Agent(
|
||||
@@ -11,12 +11,13 @@ agent = Agent(
|
||||
model = xAI(id="grok-beta"),
|
||||
tools=[DuckDuckGoTools(), YFinanceTools(stock_price=True, analyst_recommendations=True, stock_fundamentals=True)],
|
||||
instructions = ["Always use tables to display financial/numerical data. For text data use bullet points and small paragrpahs."],
|
||||
show_tool_calls = True,
|
||||
debug_mode = True,
|
||||
markdown = True,
|
||||
)
|
||||
|
||||
# UI for finance agent
|
||||
app = Playground(agents=[agent]).get_app()
|
||||
agent_os = AgentOS(agents=[agent])
|
||||
app = agent_os.get_app()
|
||||
|
||||
if __name__ == "__main__":
|
||||
serve_playground_app("xai_finance_agent:app", reload=True)
|
||||
agent_os.serve(app="xai_finance_agent:app", reload=True)
|
||||
Reference in New Issue
Block a user