Insurance Claims Assistant
MCP server that processes car insurance claims by extracting structured data from raw accident reports, classifying severity using a two-model judge pipeline, and generating broker notifications.
README
Insurance Claims Assistant
An MCP server for automated car insurance claim processing, built with TypeScript and the Anthropic Claude API.
I built this after a year working on Guidewire ClaimCenter at AXA France, where I integrated the EDI broker flows (506/508/509) for automated claim opening and modification. The business logic here mirrors what I dealt with there — entity extraction, severity triage, broker notifications — but implemented with LLMs instead of static rules.
The core of it is a two-model validation pipeline: a fast model classifies, a stronger model reviews and can overrule it before anything ships.
What it does
Three tools, chained together:
↓ analyze_claim_report
Structured ClaimData
↓ classify_claim_severity
Severity + judge verdict
↓ generate_broker_notification
Formal broker notification
The judge
Classification runs through two models.
Claude Haiku takes the structured claim and returns a severity plus a confidence score and its reasoning. Claude Sonnet then receives the same claim data alongside Haiku's answer, and returns a verdict:
{
"approved": false,
"feedback": "Injuries confirmed in the report — AUTO_PROCESS is not applicable",
"finalSeverity": "URGENT_ESCALATION"
}
Sonnet doesn't ask Haiku to retry. It overrides directly, and finalSeverity is what the pipeline uses downstream. The judge always has the last word.
The reason this pattern is here and not somewhere cheaper: in claims processing, a misclassification isn't a cosmetic error. An URGENT_ESCALATION claim with injuries routed to AUTO_PROCESS means someone waits longer for assistance. Haiku is cheap enough to run on every claim; Sonnet costs more but only runs once, as a gate.
analyze_claim_report
Takes raw accident report text and returns structured JSON: vehicles, parties, damages, circumstances, witnesses.
Uses an Agent Skill pattern — the extraction prompt lives in its own module (skills/claim-extraction.skill.ts) rather than being inlined in the tool.
classify_claim_severity
Classifies a claim as AUTO_PROCESS, REVIEW_NEEDED, or URGENT_ESCALATION.
generate_broker_notification
Generates a formal notification letter for the broker, with the required actions based on the severity classification.
This one sends MCP progress notifications (1/3, 2/3, 3/3) so the client can display real-time status.
Architecture
├── index.ts MCP server, tool registration
├── tools/
│ ├── analyze-claim.ts
│ ├── classify-claim.ts
│ └── generate-notification.ts
├── skills/
│ └── claim-extraction.skill.ts Reusable prompt template
├── judge/
│ └── classification-judge.ts Sonnet validates Haiku
├── utils/
│ ├── anthropic-client.ts Shared SDK instance + model config
│ ├── logger.ts stderr logging
│ └── progress.ts Progress notification helper
└── types/
└── claim.types.ts
A few decisions worth explaining
Logging goes to stderr, not stdout. MCP servers using stdio transport reserve stdout for JSON-RPC messages. A stray console.log corrupts the protocol and the client drops the connection. Everything logs to stderr instead.
Haiku everywhere except the judge. Extraction, classification, and notification generation all run on Haiku. Sonnet only runs as the validator. On a real claim volume, that cost difference matters.
Progress notifications are optional. The sendProgressFn parameter is optional so the tool still works with clients that don't support progress updates. No client should crash because it didn't send a progress token.
Zod for input validation. The MCP SDK uses Zod schemas to validate tool inputs at the server boundary, before any business logic runs. It also gives typed handler arguments for free.
Setup
Requires Node.js 18+ and an Anthropic API key.
git clone https://github.com/youssefmkb/insurance-claims-assistant
cd insurance-claims-assistant
npm install
cp .env.example .env # add your API key
npm run build
Run the server:
node dist/index.js
Test it with MCP Inspector:
npx @modelcontextprotocol/inspector node dist/index.js
Screenshots
Tools exposed by the server:

Entity extraction from a raw accident report:

Classification with the judge verdict:

Broker notification, with progress updates visible bottom right:

Stack
Node.js, TypeScript, @modelcontextprotocol/sdk v4, Anthropic SDK (Haiku + Sonnet), Zod, stdio transport.
V2 ideas
Things I'd add if this went further:
- Actual email delivery — right now the notification is generated but not sent. Hooking up SendGrid or Nodemailer would close the loop.
- Persistence — claims are stateless today. A database would let you track a claim across its lifecycle instead of processing each call in isolation.
- MCP sampling — let the server request completions from the client's model rather than calling the API directly.
- Remote transport — currently stdio only. Streamable HTTP would make it deployable.
Author
Youssef Mokhbi — github.com/youssefmkb · LinkedIn
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。