AksharaSachin commited on
Commit
29331af
·
verified ·
1 Parent(s): 8a52178

Update agent.py

Browse files
Files changed (1) hide show
  1. agent.py +10 -6
agent.py CHANGED
@@ -47,12 +47,16 @@ def build_agent():
47
  # huggingfacehub_api_token=os.getenv("HUGGINGFACEHUB_API_TOKEN")
48
  # )
49
 
50
- llm = ChatHuggingFace(HuggingFaceHub(repo_id="distilbert/distilgpt2", task="text-generation",
51
- model_kwargs={
52
- "temperature": 0.7, # Controls randomness (0.0 = deterministic)
53
- "max_new_tokens": 100 # Optional: max output length
54
- },
55
- verbose=True ))
 
 
 
 
56
 
57
  tools = [use_wikipedia_tool, use_search_tool]
58
 
 
47
  # huggingfacehub_api_token=os.getenv("HUGGINGFACEHUB_API_TOKEN")
48
  # )
49
 
50
+ llm = ChatHuggingFace(
51
+ HuggingFaceHub(
52
+ repo_id="microsoft/DialoGPT-medium",
53
+ task="text-generation",
54
+ model_kwargs={
55
+ "temperature": 0.7,
56
+ "max_new_tokens": 100
57
+ }
58
+ ),
59
+ verbose=True)
60
 
61
  tools = [use_wikipedia_tool, use_search_tool]
62