AttributeError: 'Agent' object has no attribute 'knowledge_base'

I am using the following code from documentation and giving error that
“AttributeError: ‘Agent’ object has no attribute ‘knowledge_base’”

Please someone help

db_url = "postgresql+psycopg://ai:ai@localhost:5532/ai"

agent = Agent(
    storage=PgAgentStorage(table_name="recipe_agent", db_url=db_url),
    knowledge_base=PDFUrlKnowledgeBase(
        urls=["https://phi-public.s3.amazonaws.com/recipes/ThaiRecipes.pdf"],
        vector_db=PgVector(table_name="recipe_documents", db_url=db_url),
    ),
    # Show tool calls in the response
    show_tool_calls=True,
    # Enable the agent to search the knowledge base
    search_knowledge=True,
    # Enable the agent to read the chat history
    read_chat_history=True,
)
# Comment out after first run
agent.knowledge_base.load(recreate=True)  # type: ignore

agent.print_response("How do I make pad thai?", markdown=True)```

Hi @sridharratna
Thank you for reaching out and using Phidata! I’ve tagged the relevant engineers to assist you with your query. We aim to respond within 48 hours.
If this is urgent, please feel free to let us know, and we’ll do our best to prioritize it.
Thanks for your patience!

Hi @sridharratna
I think you should use agent.knowledge instead.
Here are the docs Knowledge - Phidata