weather_brief.py Python import os
from maivn import Agent
from maivn.messages import HumanMessage
agent = Agent(
name="weather-brief",
api_key=os.environ["MAIVN_API_KEY"],
)
@agent.toolify(description="Current weather for a city")
def get_weather(city: str) -> dict:
return {"city": city, "forecast": "Sunny, 72F"}
res = agent.invoke(
[HumanMessage(content="Weather in Austin?")],
)
print(res.response)