simplify dependencies
Browse files- app.py +2 -4
- requirements.txt +0 -13
app.py
CHANGED
@@ -1,6 +1,5 @@
|
|
1 |
import os
|
2 |
import gradio as gr
|
3 |
-
from datasets import load_dataset
|
4 |
from typing import Union, Dict, List, Optional
|
5 |
import pandas as pd
|
6 |
from smolagents import CodeAgent, HfApiModel, tool, GradioUI
|
@@ -11,7 +10,6 @@ from opentelemetry.exporter.otlp.proto.http.trace_exporter import OTLPSpanExport
|
|
11 |
from openinference.instrumentation.smolagents import SmolagentsInstrumentor
|
12 |
from openinference.semconv.resource import ResourceAttributes
|
13 |
from opentelemetry.sdk.resources import Resource
|
14 |
-
import Bio
|
15 |
|
16 |
resource = Resource(attributes={
|
17 |
ResourceAttributes.PROJECT_NAME: 'hf-parsimony'
|
@@ -89,11 +87,11 @@ class GradioUIWithExamples(GradioUI):
|
|
89 |
demo = self.build_interface()
|
90 |
demo.launch()
|
91 |
|
92 |
-
model = HfApiModel(
|
93 |
agent = CodeAgent(
|
94 |
tools=[],
|
95 |
model=model,
|
96 |
-
additional_authorized_imports=["
|
97 |
add_base_tools=True
|
98 |
)
|
99 |
|
|
|
1 |
import os
|
2 |
import gradio as gr
|
|
|
3 |
from typing import Union, Dict, List, Optional
|
4 |
import pandas as pd
|
5 |
from smolagents import CodeAgent, HfApiModel, tool, GradioUI
|
|
|
10 |
from openinference.instrumentation.smolagents import SmolagentsInstrumentor
|
11 |
from openinference.semconv.resource import ResourceAttributes
|
12 |
from opentelemetry.sdk.resources import Resource
|
|
|
13 |
|
14 |
resource = Resource(attributes={
|
15 |
ResourceAttributes.PROJECT_NAME: 'hf-parsimony'
|
|
|
87 |
demo = self.build_interface()
|
88 |
demo.launch()
|
89 |
|
90 |
+
model = HfApiModel()
|
91 |
agent = CodeAgent(
|
92 |
tools=[],
|
93 |
model=model,
|
94 |
+
additional_authorized_imports=["gradio","pandas","numpy"],
|
95 |
add_base_tools=True
|
96 |
)
|
97 |
|
requirements.txt
CHANGED
@@ -1,20 +1,7 @@
|
|
1 |
smolagents
|
2 |
gradio
|
3 |
pandas
|
4 |
-
datasets
|
5 |
numpy
|
6 |
-
biopython
|
7 |
-
rdflib
|
8 |
-
networkx
|
9 |
-
duckdb
|
10 |
-
aiohttp
|
11 |
-
google-cloud-bigquery
|
12 |
-
pandas-gbq
|
13 |
-
pybigquery
|
14 |
-
sqlalchemy
|
15 |
-
pyvis
|
16 |
-
streamlit
|
17 |
-
st-link-analysis
|
18 |
arize-otel
|
19 |
arize-phoenix
|
20 |
opentelemetry-sdk
|
|
|
1 |
smolagents
|
2 |
gradio
|
3 |
pandas
|
|
|
4 |
numpy
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
arize-otel
|
6 |
arize-phoenix
|
7 |
opentelemetry-sdk
|