Customs Agent
At a glance
- Live at: Adani Ports (primary)
- Channels: API (document processing), email (notifications)
- Languages: EN
- Owner: Ports pod
- Key use case: Automated customs document validation and pre-filing preparation
The problem it solves
Customs clearance is document-heavy and error-prone. A single import or export shipment involves multiple documents — Bill of Entry (BoE), Bill of Lading (BoL), Delivery Order (DO), Let Export Order (LEO), Shipping Bill — each with mandatory fields, cross-references, and regulatory requirements.
Manual document checking is slow and misses errors. A wrong HS code, a mismatched consignee name, or a missing field means the shipment gets held at customs — adding days of delay and potentially triggering penalties.
How it works
Step by step
- Document intake — Customs documents arrive via API (uploaded by CHA, broker, or internal ops).
- Field extraction — Uses OCR and LLM parsing to extract structured data from each document.
- Cross-validation — Checks consistency across documents:
- Consignee name matches across BoE and BoL
- HS codes are valid and match the commodity description
- Weights and quantities match between documents
- Reference numbers cross-reference correctly
- HS code validation — Validates HS (Harmonized System) codes against the tariff database. Flags potentially incorrect classifications.
- Pre-Bayan preparation — For the Saudi/GCC market, prepares the pre-Bayan customs declaration filing with validated data.
- Discrepancy handling — Flags mismatches with specific details (which field, which documents, what the expected value should be) and notifies the relevant party.
- Filing readiness — Marks the shipment as ready for customs filing once all validations pass.
Supported document types
| Document | Abbreviation | Used for |
|---|---|---|
| Bill of Entry | BoE | Import customs declaration |
| Bill of Lading | BoL | Proof of shipment from carrier |
| Delivery Order | DO | Authorization to release cargo |
| Let Export Order | LEO | Customs approval to export |
| Shipping Bill | SB | Export customs declaration |
| Pre-Bayan declaration | — | GCC customs pre-filing |
Integration with other agents
At Adani Ports, the Customs agent works alongside:
- Appointment agent — Dock slots depend on clearance status; customs clearance triggers slot availability
- Demurrage prevention agent — Customs delays are a top cause of demurrage; the customs agent’s speed directly reduces charges
Tech stack
| Layer | What’s used |
|---|---|
| Models | LLM for document parsing + field extraction. Classification for HS code validation. |
| Memory | Short-term: document set context. Long-term: historical filing patterns, known discrepancy types. |
| Tools (MCP) | ProjectX API (consignment data), tariff database lookup, document storage, email notification. |
| Guardrails | Cannot file customs declarations directly (human approval required). Read-only for financial fields. |
| Evals | Document accuracy (extraction correctness), cross-validation precision/recall, HS code validation accuracy. |
Sources
- Shipsy for Adani Ports
- Adani Ports CFS (detailed)
- Adani Process Mapping & AI
- See Adani Ports case study for the full deployment context
Changelog
- 26 May 2026: Full content from Adani Ports deployment details and Drive decks.