from exa_py import Exa
exa = Exa()
run = exa.agent.runs.create(
query="What are prominent podcast hosts and guests saying about AI regulation in 2025?",
data_sources=[{"provider": "particle_news"}],
output_schema={
"type": "object",
"required": ["mentions"],
"properties": {
"mentions": {
"type": "array",
"maxItems": 10,
"items": {
"type": "object",
"required": ["podcast", "episode", "speaker", "quote", "stance"],
"properties": {
"podcast": {"type": "string"},
"episode": {"type": "string"},
"speaker": {"type": "string"},
"quote": {"type": "string"},
"stance": {"type": "string", "description": "pro-regulation, anti-regulation, or nuanced"},
},
},
}
},
},
)
run = exa.agent.runs.poll_until_finished(run.id)