Skip to main content

triage-mcp

An MCP server over my ai-triage-agent queue. A local LLM classifies support tickets and drafts replies, a human approves or rejects every one, and this server lets any MCP-capable AI client read that queue and the decision log.

It answers questions like "whats waiting for review?" or "what did I reject this week and why?" straight from the files the agent writes. Four tools, all read-only. The model can look at the queue but it cant approve, reject or send anything.

Tools

Tool What it does
queue_status() Counts for inbox, pending review by priority, outbox and logged decisions
pending_items(priority) Tickets waiting for review, most urgent first, optional priority filter
recent_decisions(limit) Latest human decisions from the audit log, newest first
search_decisions(query) Search the decision log by id, outcome, category, priority or reject reason

Setup

pipx install triage-mcp

uvx triage-mcp works too if you prefer no install. Hacking on a clone instead:

python3 -m venv .venv
.venv/bin/pip install mcp

It reads ~/aiProjects/aminWork/automation-portfolio/ai-triage-agent/. Point TRIAGE_DATA_DIR at your own data folder if your copy lives somewhere else.

Wire it into Claude Code:

claude mcp add triage -- triage-mcp

Running from a clone, point it at the venv instead:

claude mcp add triage -- /path/to/triage-mcp/.venv/bin/python /path/to/triage-mcp/triage_mcp.py

Demo

What it looks like from Claude Code:

> anything urgent sitting in the triage queue?

⏺ triage · pending_items()

  2 pending item(s):
  demo-014 P1 security_incident -> security-team (high): User entered their password on a fake helpdesk link and asks what to do next.
  demo-017 P3 software_issue -> service-desk (medium): Spreadsheet app crashes when opening one monthly report file.

⏺ One P1. demo-014 looks like a phishing hit and is routed to security.
  Id review that one first. The Excel crash can wait.

The tickets above are demo data. The format is exactly what the server returns.

Design notes

  • Read-only by construction. No tool writes to the queue, the outbox or the log. Approving stays in review.py with a human at the keyboard.
  • Only metadata crosses the protocol. Ticket bodies, extracted entities and reply text never leave the server. Summaries and reject reasons are cut to 100 characters with emails and home paths masked.
  • Small on purpose. One file, standard library plus the mcp SDK.

Honest notes

  • It only reads what ai-triage-agent has already written. With an empty pending/ folder most answers are zeros, which is normal between triage runs.
  • The masking is regex based. It catches emails and home paths, not names written into a summary.
  • All ticket content in the demo and the tests is made up. The logic is tested against a synthetic queue in test_server.py. Run python test_server.py.

About

Al Amin Bashir Afara, Dubai · github.com/aminafara123 · linkedin.com/in/aminafara

Release files for triage-mcp 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for triage-mcp 1.0.1
File Size Uploaded
triage_mcp-1.0.1.tar.gz 5.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for triage-mcp 1.0.1
File Interpreter ABI Platform
triage_mcp-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 12.0 kB

Release files / triage_mcp-1.0.1.tar.gz

Download URL triage_mcp-1.0.1.tar.gz
Size 5.7 kB
Tags Source
SHA-256 checksum
How to use checksums
89bebc7856d00d22696fa9323d5aedd0ec77e6ebac749fc6db3aa2fe8cff9f24
BLAKE2b-256 checksum
How to use checksums
4436a4502f673bde1b7dd0c6cf97dad63af88debe8eb6c977941a9b410a03519
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.4

Release files / triage_mcp-1.0.1-py3-none-any.whl

Download URL triage_mcp-1.0.1-py3-none-any.whl
Size 6.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2d0f1779100ecbc846c8b5d856559fdee2aa9e9b4392e24a31c9a390dc3aaaf3
BLAKE2b-256 checksum
How to use checksums
958e50852ad3aaa70add2fb8430e7b37ce94a5b5b37158d879afde38b2e738e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.4

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page