Leonardo commited on
Commit
65ccec8
·
verified ·
1 Parent(s): 6998578

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +36 -18
app.py CHANGED
@@ -89,28 +89,46 @@ from huggingface_hub import login
89
  from rich.console import Console
90
  from rich.logging import RichHandler
91
  from smolagents import FinalAnswerTool # smolagents
92
- from smolagents import (CodeAgent, GoogleSearchTool, HfApiModel, LiteLLMModel,
93
- OpenAIServerModel, Tool, TransformersModel)
94
- from smolagents.agent_types import AgentText
95
- from smolagents.gradio_ui import (handle_agent_output_types,
96
- pull_messages_from_step)
 
 
 
 
 
 
97
 
98
  # local
99
- from scripts.finance_tools import (DataVisualizationTool,
100
- FinancialCalculatorTool, TrendAnalysisTool,
101
- get_balance_sheet_data, get_cash_flow_data,
102
- get_company_overview_data,
103
- get_earnings_data,
104
- get_income_statement_data,
105
- get_market_news_sentiment,
106
- get_stock_quote_data, get_time_series_daily,
107
- search_symbols)
 
 
 
 
 
108
  from scripts.flux_lora_tool import FluxLoRATool
109
  from scripts.text_cleaner_tool import TextCleanerTool
110
  from scripts.text_inspector_tool import TextInspectorTool
111
- from scripts.text_web_browser import (ArchiveSearchTool, DownloadTool,
112
- FinderTool, FindNextTool, PageDownTool,
113
- PageUpTool, SimpleTextBrowser, VisitTool)
 
 
 
 
 
 
 
114
  from scripts.time_tools import get_temporal_context
115
  from scripts.visual_qa import visualizer
116
 
@@ -135,7 +153,7 @@ AUTHORIZED_IMPORTS = [
135
  "pubchempy", # Accessing PubChem chemical database
136
  "yaml",
137
  "xml", # XML processing
138
- "yahoo_finance", # Fetching stock datauv
139
  "Bio", # Bioinformatics tools (e.g., sequence analysis)
140
  "sklearn", # Scikit-learn for machine learning
141
  "scipy", # Scientific computing (stats, optimization)
 
89
  from rich.console import Console
90
  from rich.logging import RichHandler
91
  from smolagents import FinalAnswerTool # smolagents
92
+ from smolagents import (
93
+ CodeAgent,
94
+ GoogleSearchTool,
95
+ HfApiModel,
96
+ LiteLLMModel,
97
+ OpenAIServerModel,
98
+ Tool,
99
+ TransformersModel,
100
+ )
101
+ from smolagents.agent_types import AgentText, handle_agent_output_types
102
+ from smolagents.gradio_ui import pull_messages_from_step
103
 
104
  # local
105
+ from scripts.finance_tools import (
106
+ DataVisualizationTool,
107
+ FinancialCalculatorTool,
108
+ TrendAnalysisTool,
109
+ get_balance_sheet_data,
110
+ get_cash_flow_data,
111
+ get_company_overview_data,
112
+ get_earnings_data,
113
+ get_income_statement_data,
114
+ get_market_news_sentiment,
115
+ get_stock_quote_data,
116
+ get_time_series_daily,
117
+ search_symbols,
118
+ )
119
  from scripts.flux_lora_tool import FluxLoRATool
120
  from scripts.text_cleaner_tool import TextCleanerTool
121
  from scripts.text_inspector_tool import TextInspectorTool
122
+ from scripts.text_web_browser import (
123
+ ArchiveSearchTool,
124
+ DownloadTool,
125
+ FinderTool,
126
+ FindNextTool,
127
+ PageDownTool,
128
+ PageUpTool,
129
+ SimpleTextBrowser,
130
+ VisitTool,
131
+ )
132
  from scripts.time_tools import get_temporal_context
133
  from scripts.visual_qa import visualizer
134
 
 
153
  "pubchempy", # Accessing PubChem chemical database
154
  "yaml",
155
  "xml", # XML processing
156
+ "yahoo_finance", # Fetching stock datauv
157
  "Bio", # Bioinformatics tools (e.g., sequence analysis)
158
  "sklearn", # Scikit-learn for machine learning
159
  "scipy", # Scientific computing (stats, optimization)