1. Agent Overview
The Document Analyzer Agent is a multi-modal AI system that processes unstructured documents and converts them into structured, queryable knowledge. It handles PDF, DOCX, XLSX, images (OCR), and scanned documents.
Core Capabilities
| Capability | Description | Accuracy |
| Text Extraction | OCR + native text extraction from all formats | 99.2% |
| Entity Recognition | Names, dates, amounts, addresses, IDs | 96.5% |
| Document Classification | Auto-categorize into 50+ document types | 94.8% |
| Summarization | Executive summaries of 1-100 page documents | N/A (qualitative) |
| Q&A | Natural language questions about document content | 92.3% |
| Table Extraction | Structured tables from PDFs and images | 91.7% |
3. API Specification
Endpoints
| Method | Endpoint | Description |
| POST | /api/v1/documents/upload | Upload and process a document |
| GET | /api/v1/documents/{id}/status | Check processing status |
| GET | /api/v1/documents/{id}/summary | Get document summary |
| POST | /api/v1/documents/{id}/query | Ask a question about the document |
| GET | /api/v1/documents/{id}/entities | Get extracted entities |
| GET | /api/v1/documents/{id}/tables | Get extracted tables as JSON |
| POST | /api/v1/documents/batch | Batch upload (up to 50 files) |
Example Request & Response
POST /api/v1/documents/{id}/query
{
"question": "What is the total contract value?",
"response_format": "json"
}
Response:
{
"answer": "The total contract value is $2,450,000 USD",
"confidence": 0.97,
"sources": [
{"page": 3, "paragraph": 2, "text": "Total Contract Value: USD 2,450,000.00"}
]
}