Spaces:
Build error

web_agent / web_agent.py
piow's picture
Create web_agent.py
110ce14 verified
Raw History Blame Contribute Delete
931 Bytes
from agno.tools.duckduckgo import DuckDuckGoTools
from agno.models.groq import Groq
from huggingface_hub import configure_http_backend
from getpass import getpass
from agno.agent import Agent
from agno.models.huggingface import HuggingFace
import os
import requests
from dotenv import load_dotenv
import streamlit as st
load_dotenv()
def backend_factory() -> requests.Session:
session = requests.Session()
session.verify = False
return session
configure_http_backend(backend_factory=backend_factory)
os.environ['REQUESTS_CA_BUNDLE']=''
agent = Agent(
tools=[DuckDuckGoTools()],
show_tool_calls=True,
markdown=True,
model=HuggingFace(
id="meta-llama/Meta-Llama-3-8B-Instruct",
max_tokens=4096,
),
# model=Groq(id="llama-3.3-70b-versatile"),
)
agent.print_response("i have devlopped a platform and i created an admin panel how to connect the admin panel to the platform")