File Processing
Attach Files to an Agent Run
from glaip_sdk import Agent
agent = Agent(name="analysis-agent", instruction="You analyze documents.")
response = agent.run(
"Summarise the document and extract key metrics",
files=["./reports/q1.pdf", "./reports/q2.pdf"],
)
print(response)aip agents run analysis-agent \
--input "Summarise these reports" \
--file reports/q1.pdf \
--file reports/q2.pdf \
--view json > summary.jsonCommon attachment errors
Symptom
Likely cause
Fix
Reuse Chunk IDs from Prior Attachments
Retrieve Artifacts and Output
Best Practices
Related Documentation
Last updated
Was this helpful?