feat(mcp): add canonical model and 2025-11-25 adapter #36

Merged
lost-rob0t merged 14 commits from feature/issue-14-mcp-2025-11-25 into main 2026-08-13 01:13:20 +00:00
lost-rob0t commented 2026-08-12 21:55:39 +00:00 (Migrated from github.com)

Summary

  • replace the MCP stub with a version-neutral canonical client/server runtime
  • add canonical commands, capabilities, tools, resources, prompts, content, structured tool results, and notifications
  • isolate JSON-RPC, method names, protocol dates, headers, and session state in a dedicated MCP 2025-11-25 adapter
  • support persistent stdio and Streamable HTTP transport boundaries, including send-only stdio notifications
  • negotiate capabilities and fail closed when an operation was not negotiated
  • validate JSON-RPC response ids and protocol/session metadata
  • implement bounded Streamable HTTP 404 session invalidation, one re-initialization, and one command replay
  • expose ordered canonical MCP lifecycle traces
  • add deterministic client/server fixtures covering tools, resources, prompts, stdio, HTTP session recovery, notifications, response-id mismatch, and agent/graph protocol-boundary isolation
  • document the canonical MCP runtime and 2025-11-25 lifecycle/transport contracts

Validation

  • exact branch head aa7f2a0a0cdcd31e7bc9151c565534f77ff6d22c passes the deterministic SWI-Prolog suite
  • production modules static-load on the branch
  • final branch diff contains no workflow changes or credential material
  • PR CI must keep the existing REAL OpenRouter core and structured-repair gates green before merge

Closes #14

## Summary - replace the MCP stub with a version-neutral canonical client/server runtime - add canonical commands, capabilities, tools, resources, prompts, content, structured tool results, and notifications - isolate JSON-RPC, method names, protocol dates, headers, and session state in a dedicated MCP 2025-11-25 adapter - support persistent stdio and Streamable HTTP transport boundaries, including send-only stdio notifications - negotiate capabilities and fail closed when an operation was not negotiated - validate JSON-RPC response ids and protocol/session metadata - implement bounded Streamable HTTP 404 session invalidation, one re-initialization, and one command replay - expose ordered canonical MCP lifecycle traces - add deterministic client/server fixtures covering tools, resources, prompts, stdio, HTTP session recovery, notifications, response-id mismatch, and agent/graph protocol-boundary isolation - document the canonical MCP runtime and 2025-11-25 lifecycle/transport contracts ## Validation - exact branch head `aa7f2a0a0cdcd31e7bc9151c565534f77ff6d22c` passes the deterministic SWI-Prolog suite - production modules static-load on the branch - final branch diff contains no workflow changes or credential material - PR CI must keep the existing REAL OpenRouter core and structured-repair gates green before merge Closes #14
Sign in to join this conversation.
No description provided.