feat(catalog): Graph Phase 4 (engine) — aggregator correlate tools + e2e proof - #210
Merged
Merged
Conversation
…f (Graph P4) Phase 2b/4: expose cross-provider correlation as agent-facing, hidden-but-callable tools on CatalogMcpSurface, plus the offline $0 falsifiable proof. - correlate_surfaces(a, b): resolve two providers via resolve_provider, delegate to the shared Phase-2 correlate.correlate_surfaces (same confirmed-gate scorer). - find_correlations(entity) / value_domain_index: the cross-provider "what correlates with X" query, reusing Phase-3 vindex. - Both getattr-guarded for duck-typed clients, control-plane clean, NOT enumerated in list_tools (projection stays byte-identical), callable by name. - tests/test_e2e_correlation.py proves the full chain THROUGH the aggregator: no DECLARED hint -> candidate; one customer-confirmed entity -> plan-eligible + grouped + cross_plan recovers first-plan-correct; provider-only -> stays a candidate (confirmed-gate holds to the executable plan). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Graph Phase 4 — the engine half (Video-2 production is a separate follow-up). Exposes correlation across providers as agent-facing tools + the end-to-end falsifiable proof.
Two aggregator tools on
CatalogMcpSurface(hidden, callable-by-name —list_toolsstays byte-identical)correlate_surfaces(a, b)— resolves both providers viaresolve_provider, delegates to Phase-2correlate.correlate_surfaces, returns the control-plane-cleanCorrelationResult.find_correlations(entity)/value_domain_index— the cross-provider "what correlates with X across all connected providers" query (Phase-3vindex), getattr-guarded for duck-typed clients.No new scoring — every plan-eligibility verdict flows through the shared Phase-2
_score.The confirmed-gate holds end-to-end
tests/test_e2e_correlation.py(2-provider aggregator, sharedsolana-token-mint) proves the full chain throughcall_tool:find_correlationsreturns no name-only bucket (§13.6).cross_planrecovers the chain first-plan-correct.provider-declared-unconfirmed), butcross_planrefuses it — a malicious provider can't mint an executable cross-system chain, proven at all three doors.Gate
The three tools are absent from
list_toolsyet callable by name; unknown provider raises. ruff + mypy clean · full suite 1906 passed / 1 skipped.Next: the Video-2 e2e showcase (production) on a real provider pair.
🤖 Generated with Claude Code