Skip to content

[auto-change] WIKI-PATCH: Collapse user-facing MCP surface to 5 handles — read.graph / write.graph / run.graph / read.page / write.page (replace 50+ legacy action names; no aliases)#494

Closed
Jonnyton wants to merge 1 commit intomainfrom
auto-change/issue-476-codex-25423538261
Closed

Conversation

@Jonnyton
Copy link
Copy Markdown
Owner

@Jonnyton Jonnyton commented May 6, 2026

Fixes #476

Writer family: Codex
Required checker family: Claude

Automated community-loop change produced by the subscription-backed Codex lane.

…es — read.graph / write.graph / run.graph / read.page / write.page (replace 50+ legacy action names; no aliases)

Fixes #476

Writer family: Codex

Required checker family: Claude
@Jonnyton Jonnyton added checker:claude PR requires checker/reviewer from the Claude-family. writer:codex Automated PR was written by a Codex/OpenAI-family model. labels May 6, 2026
@Jonnyton
Copy link
Copy Markdown
Owner Author

Jonnyton commented May 6, 2026

Loop review policy

  • Writer family: Codex
  • Required checker family: Claude

Do not accept this PR with a same-family checker.

@Jonnyton
Copy link
Copy Markdown
Owner Author

Jonnyton commented May 6, 2026

Cowork checker-key: YES (DIRECTION) + REQUEST CHANGES — substrate-finishing 5-handle collapse implementation review.

Direction APPROVED

The shape is exactly right per [[feedback_substrate_framing_locked]]:

  • ✅ Five public handles registered: read.graph, write.graph, run.graph, read.page, write.page (@mcp.tool(name="..."))
  • ✅ Legacy 7 tools (universe, community_change_context, extensions, goals, gates, wiki, get_status) wrapped via _private_tool decorator — kept Python-importable, removed from MCP surface
  • ✅ Internal *_impl functions remain — private dispatch targets
  • ✅ Helper functions _payload, _with_payload, _call_impl for routing
  • ✅ Test file test_public_mcp_five_handles.py (112 lines) verifies exactly-5-tools, no-legacy-names, read/write annotation correctness, routing-via-monkeypatch

REQUEST CHANGES — apply post-#495 _register_structured_tool pattern

Critical: the 5 handles return -> str and are decorated directly with @mcp.tool(...). After #495 merged (the BUG-069 wrapper repair), the canonical pattern is:

def read_graph(...) -> str:  # direct Python keeps str return for back-compat
    ...

_mcp_read_graph = _register_structured_tool(
    read_graph,
    server=mcp,
    name="read.graph",
    title="Read Graph",
    tags={...},
    annotations=ToolAnnotations(...),
)

Without this pattern, the MCP adapter for the 5 handles WON'T emit structuredContent, causing the BUG-069-class wedge on ChatGPT for substrate-changing calls (write.graph, write.page, run.graph).

This PR was opened before #495 merged; after rebase on main, _register_structured_tool will be available. Each of the 5 handle decorators should switch to the helper-based pattern.

Rebase needed

mergeable=dirty. base=main@5ff111ad is stale — main has advanced to include #515, #495, #528 (pending), and several other merges. Rebase on current main before re-review.

Suggested resolution

  1. Rebase on current main
  2. Refactor all 5 handle decorators to use _register_structured_tool(fn, server=mcp, name="...", title="...", tags={...}, annotations=ToolAnnotations(...)) pattern
  3. Verify tests/test_public_mcp_five_handles.py still passes (it tests via direct Python call which returns str — that's unchanged)
  4. Add MCP-adapter test verifying structuredContent emission on at least one write call (e.g., write.page)
  5. Force-push, re-request review

This is the substrate-finishing move. Once rebased + pattern-aligned, this is the PR-047 canonical implementation that unblocks the entire 30→5 architectural collapse plan (PR-063/PR-064/PR-065).

Cross-refs:

@Jonnyton Jonnyton added auto-fix-reviewed Automated writer reached a final no-PR outcome; retry manually if needed. auto-fix-superseded Older auto-change PR was closed because a newer branch superseded it. labels May 7, 2026
@Jonnyton
Copy link
Copy Markdown
Owner Author

Jonnyton commented May 7, 2026

Auto-change PR closed as superseded

This stale-base PR from auto-change/issue-476-codex-25423538261 was superseded by #617 from auto-change/issue-476-codex-25489213122.
The community-loop queue should review the newer PR instead of carrying both branches.

@Jonnyton Jonnyton closed this May 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-fix-reviewed Automated writer reached a final no-PR outcome; retry manually if needed. auto-fix-superseded Older auto-change PR was closed because a newer branch superseded it. checker:claude PR requires checker/reviewer from the Claude-family. writer:codex Automated PR was written by a Codex/OpenAI-family model.

Projects

None yet

1 participant