from agno.agent import Agent
from agno.tools.knowledge import KnowledgeTools
from agno.knowledge import Knowledge
# Initialize knowledge base
knowledge = Knowledge()
knowledge.load_documents("./docs/")
agent = Agent(
instructions=[
"You are a knowledge assistant that helps find and analyze information",
"Search through the knowledge base to answer questions",
"Provide detailed analysis and reasoning about the information found",
"Always cite your sources and explain your reasoning",
],
tools=[KnowledgeTools(knowledge=knowledge)],
)
agent.print_response("What are the best practices for API design?", stream=True)