Skip to content

feat(private-server): agent guidance + published flag for MCP incidents#278

Merged
passcod merged 1 commit into
mainfrom
mcp-incident-guidance
Jun 25, 2026
Merged

feat(private-server): agent guidance + published flag for MCP incidents#278
passcod merged 1 commit into
mainfrom
mcp-incident-guidance

Conversation

@passcod

@passcod passcod commented Jun 25, 2026

Copy link
Copy Markdown
Member

🤖 Gives MCP agents the context to interpret incidents correctly — they were over-counting raw flapping rows as real incidents.

Stacked on #277 (base will retarget to main once that merges).

What an agent gets

  • Each incident now carries published — true when it actually surfaced to operators (its Slack open notice was delivered), which happens only when it outlived its group's grace window (slack_open_delay, ~3 min default) or it escalated (a critical issue joined, bypassing the grace). find_incidents also returns published_count, and each incident gets open_duration_secs.
  • published is derived from the slack_outbox (new SlackOutbox::delivered_open_ids) — the authoritative "it surfaced" signal. That's exact: it accounts for opens cancelled when an incident flaps shut within the grace, and for delivery give-ups. It is NOT a now - opened_at >= 10min approximation (the grace is per-group and defaults to 3 min, and a time guess would misclassify cancelled/failed deliveries).

The help text

  • The find_incidents tool description and the server-level instructions (returned at initialize) now explain that find_incidents includes heavy sub-grace flapping, that event_count is raw churn (not duration or severity — a huge count can be a sub-minute flap), and that summaries/rankings should count published incidents, not raw rows.

This is the mechanism for "give agents context": MCP clients read the server instructions on connect and the per-tool descriptions, so the guidance travels with the tools.

Spec updated; MCP tests extended to cover published / published_count.

…dents

Give MCP clients the context to interpret incidents correctly:
- Each incident now carries published (its Slack open was actually delivered:
  it outlived the group's grace window or escalated), open_duration_secs, and
  find_incidents reports published_count. published is derived from the
  slack_outbox (SlackOutbox::delivered_open_ids), the authoritative 'surfaced'
  signal — not a time approximation.
- Expanded the find_incidents tool description and the server instructions to
  explain that event_count is raw churn (not duration/severity) and that
  summaries should count published incidents, not raw flapping rows.

Spec updated.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Base automatically changed from mcp-snapshot-ids to main June 25, 2026 08:37
@passcod passcod added this pull request to the merge queue Jun 25, 2026
@passcod passcod removed this pull request from the merge queue due to a manual request Jun 25, 2026
@passcod passcod merged commit 6f4ce63 into main Jun 25, 2026
7 checks passed
@passcod passcod deleted the mcp-incident-guidance branch June 25, 2026 08:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant