Repository navigation
feat(OMN-12827): expose generated COMPUTE nodes as MCP tools (close-loop B2) - #1914
Conversation
…oop B2) Relax ServiceMCPToolSync exposure rule so generated COMPUTE nodes (mcp-enabled + node-type:compute + generated) surface as MCP tools alongside orchestrators, without relabeling them as orchestrators. Non-generated compute nodes and non-mcp nodes remain excluded. Implements Plan B2 of docs/plans/2026-06-08-close-the-loop-plan.md. Evidence-Source: 352dbc1e64c802fd3c942ec01fac0d6c719e4742 Evidence-Ticket: OMN-12827
|
Warning Review limit reached
More reviews will be available in 9 minutes and 51 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (5)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
detect_test_paths emitted tests/unit/dlq/ (a reverse-dep of the services
zone) which has no test directory; pytest aborts collection with exit 5
('no tests ran') and blocks every services-zone PR. Filter selected paths
to directories that exist on disk; the empty-result fallback to tests/unit/
already covers the all-missing case.
Evidence-Source: OCC#2352
Evidence-Ticket: OMN-12827
Summary
Implements Plan B2 (
docs/plans/2026-06-08-close-the-loop-plan.md, §Phase B) — MCP exposure of the generated COMPUTE node from the SEA self-extension loop.ServiceMCPToolSyncpreviously exposed an MCP tool only for events taggedmcp-enabled+node-type:orchestrator(_is_mcp_orchestrator), so generated COMPUTE nodes could never surface as MCP tools. This PR relaxes the rule via a renamed predicate_is_mcp_exposable(tags):mcp-enabled+node-type:orchestrator→ exposed (unchanged)mcp-enabled+node-type:compute+generated→ exposed (new)mcp-enabled+node-type:computeWITHOUTgenerated→ NOT exposedmcp-enabled→ NOT exposed (any type)Generated compute nodes are NOT relabeled as orchestrators: tool description and
metadata.node_kinddistinguish 'generated compute node' from 'orchestrator', and onlygeneratedcompute nodes surface (hand-authored compute nodes do not leak into the registry).This is the infra-side classification change only (off the critical path per the plan). The live-runtime 'MCP tool appears' assertion is Phase D (D1/D2), not claimed here.
Changes
src/omnibase_infra/services/mcp/service_mcp_tool_sync.py— predicate relaxed;TAG_NODE_TYPE_COMPUTE+TAG_GENERATEDconstants; type-aware tool description +node_kindmetadata.tests/unit/services/mcp/test_service_mcp_tool_sync_exposure.py— new TDD unit tests (orchestrator + generated compute exposed; non-generated compute, non-mcp, empty excluded).contracts/OMN-12827.yaml— evidence contract.dod_evidence (OMN-12827)
AttributeError: ... _is_mcp_exposable).uv run pytest tests/unit/services/mcp/test_service_mcp_tool_sync_exposure.py -v→ 6 passed.uv run pytest tests/unit/services/mcp/ tests/integration/services/mcp/ -q→ 132 passed, 25 skipped (kafka-gated).uv run mypy src/omnibase_infra/services/mcp/service_mcp_tool_sync.py --strict→ clean.uv run ruff check src/ tests/→ All checks passed;pre-commit run --files <changed>→ clean.tests/unit/→ 20160 passed, 1 pre-existing unrelated failure (migration vendor-sync; reproduces on pristinemain, caused by uncommitted sibling omnimarket migrations in the shared local clone; not touched by B2).Paired OCC receipt: OmniNode-ai/onex_change_control#2352
Evidence-Source: OCC#2352
Evidence-Ticket: OMN-12827