cowrycode commited on
Commit
ed09e37
·
verified ·
1 Parent(s): 42ed707

Update agent.py

Browse files
Files changed (1) hide show
  1. agent.py +3 -1
agent.py CHANGED
@@ -1,3 +1,4 @@
 
1
  import asyncio
2
  import nest_asyncio
3
  from llama_index.core.agent.workflow import AgentWorkflow
@@ -6,7 +7,8 @@ from youtube_tool import youtube_transcript_tool, youtube_transcript_snippet_too
6
  from multiple_tools import round_to_two_decimals_tool, text_inverter_tool, google_web_search_tool, wikipedia_search_tool
7
 
8
 
9
- async def smart_agent(api_key : str) -> AgentWorkflow:
 
10
  llm = HuggingFaceInferenceAPI(
11
  model_name="deepseek-ai/DeepSeek-R1-0528",
12
  token=api_key,
 
1
+ import os
2
  import asyncio
3
  import nest_asyncio
4
  from llama_index.core.agent.workflow import AgentWorkflow
 
7
  from multiple_tools import round_to_two_decimals_tool, text_inverter_tool, google_web_search_tool, wikipedia_search_tool
8
 
9
 
10
+ async def smart_agent() -> AgentWorkflow:
11
+ api_key = os.getenv("HF_TOKEN")
12
  llm = HuggingFaceInferenceAPI(
13
  model_name="deepseek-ai/DeepSeek-R1-0528",
14
  token=api_key,