← Back to Pull requests

Embed route_task as a project MCP server; clean the public tree #13

Open
unknown opened this pull request with 151 lines diff across 1 files
View on GitHub
unknown unknown commented on Oct 26, 2026 16:23 UTC
Author

What


Makes the router's sub-agent delegation installable from the repo, and removes two incidental values from the public tree.

  • .mcp.json at the repo root declares the cortados-route MCP server (cortados_router/subagent_mcp.py), reading CORTADOS_PROVIDER_URL and CORTADOS_PROVIDER_TOKEN from the environment. No address or secret is committed.

  • AGENTS.md gains a short section: prefer route_task for self-contained delegated subtasks; fall back to an ordinary sub-agent for repo-touching work or when the provider is unreachable. Claude reads it through CLAUDE.md; Codex reads it directly.

  • README documents delegation, the two env vars, Claude Code auto-pickup, and the one-time codex mcp add. Test count refreshed to 506.

  • tests/test_mcp_config.py fails if .mcp.json ever carries a literal value instead of a ${...} placeholder, or stops launching the server.

  • Scrubs: a tailnet address in the S1 endpoint test and a home path in the outcome test, replaced with placeholders.
  • Testing


    python3 -B -m unittest discover -s tests -t . → 506 tests OK, 7 skipped. core.py table → table v 17 ok.

    🤖 Generated with Claude Code

    Diff: 151 lines (+113 / -38) across 1 files Reviewer: copilot-pull-request-reviewer[bot] Review duration: 1m
    All Vouch review confidence checks passed
    Residual risk 0.30 = Change Risk (0.38) × (1 − Review Confidence (0.20)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.38 · 151 lines diff across 1 files
    0.38
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.02 · 1 substantive comment(s)
    0.02
    Model 3 · Review Timing & Attention
    Session adequacy: 29% · Reviewer familiarity: 35%
    20%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Shallow Review Depth shallow_review_depth
    0.344
    Diff Size diff_size
    0.301
    Ai Authored ai_authored
    0.050
    Real PR Conversation Timeline
    1 comments
    "Review active on #13"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 20.3% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 38% (MEDIUM) · Higher = larger blast radius
    38%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 20.3% · Lower = rushed or shallow review
    20.3%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 30.3% · Safe to merge
    30.3%