@lucern/contracts 1.0.19 → 1.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/CHANGELOG.md +3 -0
  2. package/dist/function-registry/beliefs.js +13 -20
  3. package/dist/function-registry/beliefs.js.map +1 -1
  4. package/dist/function-registry/coding.js +8 -9
  5. package/dist/function-registry/coding.js.map +1 -1
  6. package/dist/function-registry/context.js +8 -9
  7. package/dist/function-registry/context.js.map +1 -1
  8. package/dist/function-registry/contracts.js +8 -9
  9. package/dist/function-registry/contracts.js.map +1 -1
  10. package/dist/function-registry/coordination.js +8 -9
  11. package/dist/function-registry/coordination.js.map +1 -1
  12. package/dist/function-registry/edges.js +8 -9
  13. package/dist/function-registry/edges.js.map +1 -1
  14. package/dist/function-registry/evidence.js +8 -15
  15. package/dist/function-registry/evidence.js.map +1 -1
  16. package/dist/function-registry/graph.js +8 -9
  17. package/dist/function-registry/graph.js.map +1 -1
  18. package/dist/function-registry/helpers.d.ts +2 -1
  19. package/dist/function-registry/helpers.js +9 -10
  20. package/dist/function-registry/helpers.js.map +1 -1
  21. package/dist/function-registry/identity.js +8 -9
  22. package/dist/function-registry/identity.js.map +1 -1
  23. package/dist/function-registry/index.d.ts +1 -1
  24. package/dist/function-registry/index.js +9 -10
  25. package/dist/function-registry/index.js.map +1 -1
  26. package/dist/function-registry/judgments.js +8 -9
  27. package/dist/function-registry/judgments.js.map +1 -1
  28. package/dist/function-registry/legacy.js +8 -9
  29. package/dist/function-registry/legacy.js.map +1 -1
  30. package/dist/function-registry/lenses.js +8 -9
  31. package/dist/function-registry/lenses.js.map +1 -1
  32. package/dist/function-registry/nodes.js +8 -9
  33. package/dist/function-registry/nodes.js.map +1 -1
  34. package/dist/function-registry/ontologies.js +8 -9
  35. package/dist/function-registry/ontologies.js.map +1 -1
  36. package/dist/function-registry/pipeline.js +8 -9
  37. package/dist/function-registry/pipeline.js.map +1 -1
  38. package/dist/function-registry/questions.js +8 -9
  39. package/dist/function-registry/questions.js.map +1 -1
  40. package/dist/function-registry/tasks.js +8 -9
  41. package/dist/function-registry/tasks.js.map +1 -1
  42. package/dist/function-registry/topics.js +13 -11
  43. package/dist/function-registry/topics.js.map +1 -1
  44. package/dist/function-registry/worktrees.js +8 -9
  45. package/dist/function-registry/worktrees.js.map +1 -1
  46. package/dist/index.js +1 -9
  47. package/dist/index.js.map +1 -1
  48. package/dist/proof-attestation.json +1 -1
  49. package/dist/sdk-methods.contract.d.ts +1 -3
  50. package/dist/sdk-tools.contract.js +1 -9
  51. package/dist/sdk-tools.contract.js.map +1 -1
  52. package/dist/sdk-tools.contract.registry.js +1 -9
  53. package/dist/sdk-tools.contract.registry.js.map +1 -1
  54. package/dist/sdk-tools.contract.values.js +1 -9
  55. package/dist/sdk-tools.contract.values.js.map +1 -1
  56. package/dist/tool-contracts.js +1 -9
  57. package/dist/tool-contracts.js.map +1 -1
  58. package/dist/tool-contracts.lifecycle.js +1 -9
  59. package/dist/tool-contracts.lifecycle.js.map +1 -1
  60. package/dist/tool-contracts.values.js +1 -9
  61. package/dist/tool-contracts.values.js.map +1 -1
  62. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/tool-contracts.lifecycle.ts","../../src/tool-contracts.worktrees.ts","../../src/types/reasoning-method.ts","../../src/tool-contracts.graph.ts","../../src/tool-contracts.embeddings.ts","../../src/tool-contracts.hybrid-discovery.ts","../../src/lens-workflow.contract.ts","../../src/tool-contracts.nodes-lenses.ts","../../src/tool-contracts.context-orientation.ts","../../src/tool-contracts.intelligence-evidence.ts","../../src/tool-contracts.questions-listing.ts","../../src/tool-contracts.policy-observation-task-topic.ts","../../src/tool-contracts.ontology.ts","../../src/tool-contracts.pipeline-coordination.ts","../../src/tool-contracts.ts","../../src/function-registry/manifest.ts","../../src/schemas/enums.ts","../../src/function-registry/helpers.ts","../../src/function-registry/coding.ts"],"names":["z","entries"],"mappings":";;;;;AAEO,IAAM,a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AAA,EAAc,QAAA;AAAA,IACd,SAAA,EAAW,eAAA;AAAA,IACX,OAAA,EAAS,6CAAA;AAAA,IACT,MAAA,EAAQ;AAAA,MACN,MAAA,EAAQ,UAAA;AAAA,MACR,YAAA,EAAc,QAAA;AAAA,MACd,IAAA,EAAM,UAAA;AAAA,MACN,eAAA,EAAiB;AAAA,KACnB;AAAA,IACA,IAAA,EAAM;AAAA,GACP,CAAA;AAAA,EACD,eAAA,CAAgB;AAAA,IACd,IAAA,EAAM,iBAAA;AAAA,IACN,IAAA,EAAM,OAAA;AAAA,IACN,MAAA,EAAQ,QAAA;AAAA,IACR,YAAA,EAAc,mBAAA;AAAA,IACd,IAAA,EAAM,qBAAA;AAAA,IACN,YAAA,EAAc,QAAA;AAAA,IACd,SAAA,EAAW,eAAA;AAAA,IACX,OAAA,EAAS,gCAAA;AAAA,IACT,MAAA,EAAQ;AAAA,MACN,MAAA,EAAQ,UAAA;AAAA,MACR,YAAA,EAAc,YAAA;AAAA,MACd,IAAA,EAAM,OAAA;AAAA,MACN,eAAA,EAAiB,CAAC,KAAA,KAChB,aAAA,CAAc;AAAA,QACZ,OAAA,EAAS,KAAA,CAAM,OAAA,IAAW,KAAA,CAAM,KAAA;AAAA,QAChC,OAAO,KAAA,CAAM,KAAA;AAAA,QACb,QAAQ,KAAA,CAAM,MAAA;AAAA,QACd,QAAQ,KAAA,CAAM;AAAA,OACf,CAAA;AAAA,MACH,kBAAkB,CAAC,MAAA,EAAQ,KAAA,KAAU,iBAAA,CAAkB,QAAQ,KAAK;AAAA;AACtE,GACD;AACH","file":"coding.js","sourcesContent":["import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CREATE_BELIEF: McpToolContract = {\n name: \"create_belief\",\n description:\n \"Commit a new belief (knowledge unit) to the reasoning graph. \" +\n \"Like `git commit` — creates an atomic, traceable knowledge object with a prior. \" +\n \"Creation requires a topic epistemic-node anchor and writes a `belongs_to` edge directly from belief node to topic node; orphan beliefs are invalid. \" +\n \"Creation stores the vacuous opinion `(0, 0, 1, a)`; attach supporting or contradicting evidence with create_evidence or link_evidence_to_belief to record evidential updates.\",\n parameters: {\n canonicalText: {\n type: \"string\",\n description: \"The belief statement — what the agent holds to be true\",\n },\n topicGlobalId: {\n type: \"string\",\n description:\n \"Required globalId (UUID) of the topic node in epistemicNodes that anchors the belief\",\n },\n topicNodeId: {\n type: \"string\",\n description:\n \"Optional internal epistemicNodes _id for the topic anchor. Prefer topicGlobalId for public callers.\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Deprecated compatibility alias for topicGlobalId. Must identify a topic epistemicNode, not a legacy topics-table row.\",\n },\n baseRate: {\n type: \"number\",\n description:\n \"Prior probability used to seed the vacuous opinion `(0, 0, 1, a)` at creation time. Defaults to 0.5 when omitted.\",\n },\n beliefType: {\n type: \"string\",\n description:\n \"Belief type (e.g., hypothesis, belief, principle, invariant, tenet, forecast). Validated against schemaEnumConfig.\",\n },\n metadata: {\n type: \"object\",\n description:\n \"Optional extra metadata merged into the node (e.g., { codeAnchors: ['path/to/file.ts'] } for coding intelligence)\",\n },\n },\n required: [\"canonicalText\", \"topicGlobalId\"],\n response: {\n description: \"The created canonical belief record\",\n fields: {\n id: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n beliefId: \"string — canonical belief ID\",\n text: \"string — canonical belief formulation\",\n topicId: \"string\",\n beliefStatus:\n \"string — assumption | hypothesis | active | superseded | resolved_true | resolved_false\",\n scoringState: \"string — unscored | scored\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const GET_BELIEF: McpToolContract = {\n name: \"get_belief\",\n description:\n \"Read one belief by ID. \" +\n \"Like `git show` — resolves the canonical belief payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical belief ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical belief record\",\n fields: {\n id: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n beliefId: \"string — canonical belief ID\",\n text: \"string — canonical belief formulation\",\n topicId: \"string\",\n beliefStatus:\n \"string — assumption | hypothesis | active | superseded | resolved_true | resolved_false\",\n scoringState: \"string — unscored | scored\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const REFINE_BELIEF: McpToolContract = {\n name: \"refine_belief\",\n description:\n \"Amend a draft belief in-place within an active worktree. \" +\n \"Like `git commit --amend` — rewrites the last commit on a feature branch. \" +\n \"Only valid before merge to main. Fails if the belief is already scored.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to refine\" },\n canonicalText: { type: \"string\", description: \"Updated belief statement\" },\n rationale: { type: \"string\", description: \"Why the refinement was made\" },\n },\n required: [\"nodeId\", \"canonicalText\"],\n response: {\n description: \"The updated belief node\",\n fields: {\n nodeId: \"string\",\n canonicalText: \"string — updated text\",\n updatedAt: \"number — timestamp\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const APPEND_SL_SCORING: McpToolContract = {\n name: \"append_sl_scoring\",\n description:\n \"Internal evidence-backed Subjective Logic scoring append. \" +\n \"This is not a public MCP tool: callers should attach supporting or contradicting evidence, and governed system paths append the derived SL tuple.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief receiving the SL score\" },\n belief: { type: \"number\", description: \"Subjective Logic belief mass b\" },\n disbelief: {\n type: \"number\",\n description: \"Subjective Logic disbelief mass d\",\n },\n uncertainty: {\n type: \"number\",\n description: \"Subjective Logic uncertainty mass u\",\n },\n baseRate: { type: \"number\", description: \"Subjective Logic base rate a\" },\n trigger: {\n type: \"string\",\n description: \"Evidence-bearing cause of the scoring event\",\n enum: [\n \"evidence_added\",\n \"evidence_removed\",\n \"contradiction_detected\",\n \"contradiction_resolved\",\n \"agent_assessment\",\n \"worktree_outcome\",\n \"worktree_completed\",\n \"fusion\",\n \"discount\",\n \"deduction\",\n \"backfill_synthetic\",\n ],\n },\n provenance: {\n type: \"object\",\n description:\n \"At least one of evidence, question, answer, contradiction, or worktree.\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this evidence-bearing event moved the SL tuple\",\n },\n },\n required: [\"nodeId\", \"belief\", \"disbelief\", \"uncertainty\", \"baseRate\", \"trigger\", \"rationale\"],\n response: {\n description: \"Internal SL scoring append receipt\",\n fields: {\n nodeId: \"string\",\n previousConfidence: \"number\",\n newConfidence: \"number\",\n beliefConfidenceId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const FORK_BELIEF: McpToolContract = {\n name: \"fork_belief\",\n description:\n \"Branch off an evidence-bearing belief to create a new formulation. \" +\n \"Like `git fork` — the parent remains immutable with full history, and every fork must cite evidence already attached to the parent through SL scoring. \" +\n \"`forkMode=supersede` marks the parent superseded and requires contradicting evidence; `forkMode=branch` preserves the parent and creates a derived child.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to fork from\" },\n newFormulation: {\n type: \"string\",\n description: \"The evolved belief statement\",\n },\n forkReason: {\n type: \"string\",\n description: \"Why this fork was created\",\n enum: [\n \"refinement\",\n \"contradiction_response\",\n \"scope_change\",\n \"confidence_collapse\",\n ],\n },\n forkMode: {\n type: \"string\",\n description:\n \"supersede replaces the parent; branch creates a child while preserving the parent.\",\n enum: [\"supersede\", \"branch\"],\n },\n triggeringEvidenceId: {\n type: \"string\",\n description:\n \"Evidence already attached to the parent belief that caused the fork.\",\n },\n },\n required: [\"nodeId\", \"newFormulation\", \"forkReason\", \"triggeringEvidenceId\"],\n response: {\n description: \"The forked canonical belief record\",\n fields: {\n id: \"string — canonical child belief ID\",\n nodeId: \"string — canonical child belief ID\",\n beliefId: \"string — canonical child belief ID\",\n parentBeliefId: \"string — canonical parent belief ID\",\n forkReason: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const ARCHIVE_BELIEF: McpToolContract = {\n name: \"archive_belief\",\n description:\n \"Soft-delete a belief by setting its status to archived. \" +\n \"Like `git rm` — removed from the working tree but preserved in history. \" +\n \"Beliefs are never truly deleted. Archived beliefs retain full lineage and confidence history.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to archive\" },\n rationale: {\n type: \"string\",\n description: \"Why this belief is being archived\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Archived canonical belief record\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n previousStatus: \"string | undefined\",\n newStatus: \"string — 'archived'\",\n status: \"string — 'archived'\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const CREATE_EPISTEMIC_CONTRACT: McpToolContract = {\n name: \"create_epistemic_contract\",\n description:\n \"Bind a machine-evaluable epistemic contract to a belief. \" +\n \"Like `git add` for falsification rules — records the verification condition, modulation policy, \" +\n \"and evaluation schedule that keep a belief accountable to reality.\",\n parameters: {\n beliefNodeId: {\n type: \"string\",\n description: \"The belief node to bind this contract to\",\n },\n title: {\n type: \"string\",\n description: \"Contract title\",\n },\n description: {\n type: \"string\",\n description: \"Optional contract description\",\n },\n conditionType: {\n type: \"string\",\n description: \"What kind of contract condition to evaluate\",\n enum: [\"assertion\", \"temporal\", \"evidential\", \"threshold\", \"composite\"],\n },\n direction: {\n type: \"string\",\n description: \"Whether satisfying the condition confirms or falsifies\",\n enum: [\"confirms\", \"falsifies\"],\n },\n condition: {\n type: \"object\",\n description:\n \"Condition payload: { expression, evaluator, evaluatorConfig? }\",\n },\n deadline: {\n type: \"number\",\n description: \"Optional Unix timestamp deadline for temporal contracts\",\n },\n compositeOf: {\n type: \"array\",\n description: \"Optional array of sub-contract IDs for composite contracts\",\n },\n compositeOperator: {\n type: \"string\",\n description: \"How composite sub-contracts should be combined\",\n enum: [\"all\", \"any\", \"majority\"],\n },\n modulation: {\n type: \"object\",\n description:\n \"Asymmetric modulation rules for confirmed, disconfirmed, expired, and partial outcomes\",\n },\n evaluationSchedule: {\n type: \"string\",\n description: \"When this contract should be evaluated\",\n enum: [\"on_demand\", \"on_evidence\", \"periodic\", \"event_driven\"],\n },\n periodicIntervalMs: {\n type: \"number\",\n description: \"Optional interval in milliseconds for periodic contracts\",\n },\n },\n required: [\n \"beliefNodeId\",\n \"title\",\n \"conditionType\",\n \"direction\",\n \"condition\",\n \"modulation\",\n \"evaluationSchedule\",\n ],\n response: {\n description: \"The created epistemic contract binding\",\n fields: {\n id: \"string — storage record ID\",\n contractId: \"string — contract identifier\",\n beliefId: \"string — canonical belief ID\",\n status: \"string — initial contract status\",\n title: \"string — contract title\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// EVIDENCE TOOLS\n// =============================================================================\n\nexport const ADD_EVIDENCE: McpToolContract = {\n name: \"add_evidence\",\n description:\n \"Commit evidence to the reasoning graph and attach it to a belief. \" +\n \"Like `git add && git commit` — an atomic write that creates a traceable evidence object. \" +\n \"Weight ranges from -1.0 (contradicts) to +1.0 (strongly supports). \" +\n \"Evidence is always context-bound: tied to its source, the time it was captured, and the belief it informs.\",\n parameters: {\n canonicalText: { type: \"string\", description: \"The evidence statement\" },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n sourceUrl: { type: \"string\", description: \"URL of the source material\" },\n targetNodeId: {\n type: \"string\",\n description: \"The belief this evidence bears on\",\n },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n reasoning: {\n type: \"string\",\n description: \"Why this evidence is relevant to the target belief\",\n },\n title: {\n type: \"string\",\n description: \"Optional short title for the evidence node\",\n },\n content: {\n type: \"string\",\n description:\n \"Optional long-form content (separate from canonicalText summary)\",\n },\n contentType: {\n type: \"string\",\n description:\n \"Content MIME type or format hint (e.g., 'text/markdown', 'code')\",\n },\n metadata: {\n type: \"object\",\n description:\n \"Optional extra metadata merged into the node (e.g., { codeAnchors: ['path/to/file.ts'], failedApproach: true } for coding intelligence)\",\n },\n },\n required: [\"canonicalText\", \"targetNodeId\", \"reasoning\"],\n response: {\n description: \"The created evidence node and its edge\",\n fields: {\n nodeId: \"string — evidence node ID\",\n edgeId: \"string — edge to target belief\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// CONTRADICTION TOOLS\n// =============================================================================\n\nexport const FLAG_CONTRADICTION: McpToolContract = {\n name: \"flag_contradiction\",\n description:\n \"Flag a contradiction between two beliefs. Contradictions are first-class objects \" +\n \"with their own lifecycle — they may remain permanently unresolved. \" +\n \"Like a merge conflict that is allowed to persist. \" +\n \"Contradictions can trigger structural changes: forking, confidence collapse, or decision blocking. \" +\n \"Resolution is NEVER automatic — always surfaces for human review.\",\n parameters: {\n beliefA: {\n type: \"string\",\n description: \"First belief in the contradiction\",\n },\n beliefB: {\n type: \"string\",\n description: \"Second belief in the contradiction\",\n },\n description: { type: \"string\", description: \"What the tension is about\" },\n severity: {\n type: \"string\",\n description: \"How serious the contradiction is\",\n enum: [\"low\", \"medium\", \"high\", \"critical\"],\n },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n defeatType: {\n type: \"string\",\n description:\n \"Pollock defeat classification: rebuts (direct contradiction), undercuts (attacks the inferential link), undermines (attacks a premise)\",\n enum: [\"rebuts\", \"undercuts\", \"undermines\"],\n },\n },\n required: [\"beliefA\", \"beliefB\", \"description\"],\n response: {\n description: \"The created contradiction object\",\n fields: {\n contradictionId: \"string\",\n status: \"string — 'unresolved'\",\n beliefA: \"string\",\n beliefB: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// WORKTREE TOOLS (git worktree add, git merge)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const ADD_WORKTREE: McpToolContract = {\n name: \"add_worktree\",\n description:\n \"Check out a branch into an active worktree for investigation. \" +\n \"Like `git worktree add <branch>` — creates independent working state on a thematic branch. \" +\n \"Beliefs committed within the worktree can be freely amended (draft code on a feature branch). \" +\n \"When investigation is complete, `merge` integrates findings into main.\",\n parameters: {\n title: { type: \"string\", description: \"Worktree name/objective\" },\n name: {\n type: \"string\",\n description:\n \"Optional storage-name alias for callers that already use backend naming\",\n },\n projectId: {\n type: \"string\",\n description: \"Legacy topicId alias or resolver hint\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope hint for resolver validation\",\n },\n topicHint: {\n type: \"string\",\n description: \"Natural-language topic hint for automatic topic resolution\",\n },\n branchId: {\n type: \"string\",\n description: \"The branch this worktree investigates\",\n },\n objective: {\n type: \"string\",\n description:\n \"Plain-text reasoning objective to auto-shape into a hypothesis, questions, tasks, and dependencies\",\n },\n hypothesis: {\n type: \"string\",\n description: \"The testable claim this worktree investigates\",\n },\n rationale: {\n type: \"string\",\n description:\n \"Why this worktree exists and why it belongs in the campaign\",\n },\n worktreeType: {\n type: \"string\",\n description:\n \"Schema-enum worktree type used by the kernel lifecycle and retrieval layers\",\n },\n gate: {\n type: \"string\",\n description: \"Exit gate name for this worktree\",\n },\n startDate: {\n type: \"number\",\n description: \"Planned start timestamp in milliseconds since epoch\",\n },\n endDate: {\n type: \"number\",\n description: \"Planned end timestamp in milliseconds since epoch\",\n },\n durationWeeks: {\n type: \"number\",\n description: \"Planned duration in weeks\",\n },\n confidenceImpact: {\n type: \"string\",\n description: \"Expected confidence impact if the worktree succeeds\",\n enum: [\"high\", \"medium\", \"low\"],\n },\n beliefFocus: {\n type: \"string\",\n description:\n \"Natural-language focus spanning the target belief neighborhood\",\n },\n beliefIds: {\n type: \"array\",\n description: \"Legacy alias for targetBeliefIds\",\n },\n beliefs: {\n type: \"array\",\n description: \"Legacy alias for targetBeliefIds\",\n },\n targetBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs this worktree is expected to test or update\",\n },\n targetQuestionIds: {\n type: \"array\",\n description: \"Question node IDs this worktree is expected to answer\",\n },\n keyQuestions: {\n type: \"array\",\n description:\n \"Inline key question objects with question, optional status, answer, answerConfidence, and linkedQuestionId\",\n },\n evidenceSignals: {\n type: \"array\",\n description:\n \"Evidence signal objects with signal, optional collected state, progress, and notes\",\n },\n decisionGate: {\n type: \"object\",\n description:\n \"Decision gate object with goCriteria, noGoSignals, optional verdict, rationale, decidedAt, and decidedBy\",\n },\n goCriteria: {\n type: \"array\",\n description: \"Shorthand go criteria used to build decisionGate\",\n },\n noGoSignals: {\n type: \"array\",\n description: \"Shorthand no-go signals used to build decisionGate\",\n },\n proofArtifacts: {\n type: \"array\",\n description: \"Expected proof artifacts required to close the worktree\",\n },\n autoShape: {\n type: \"boolean\",\n description:\n \"Whether to invoke inquiry auto-shaping during worktree creation\",\n },\n autoFixPolicy: {\n type: \"object\",\n description:\n \"Policy for permitted automatic remediation inside the worktree\",\n },\n domainPackId: {\n type: \"string\",\n description:\n \"Optional domain pack whose shaping hooks should influence generated questions and tasks\",\n },\n tags: {\n type: \"array\",\n description: \"Additional topic-resolution tags for the worktree\",\n },\n touchedPaths: {\n type: \"array\",\n description: \"File paths used as topic-resolution signals\",\n },\n sourceRef: {\n type: \"string\",\n description: \"Source reference used as a topic-resolution signal\",\n },\n sourceKind: {\n type: \"string\",\n description: \"Source kind used as a topic-resolution signal\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Top-level pipeline campaign number. Campaigns define the outer execution slice.\",\n },\n lane: {\n type: \"string\",\n description:\n \"GitButler-aligned workstream lane name inside the campaign.\",\n },\n laneOrderInCampaign: {\n type: \"number\",\n description:\n \"Ordering for this lane within its campaign.\",\n },\n orderInLane: {\n type: \"number\",\n description:\n \"Position of this worktree inside its lane.\",\n },\n dependsOn: {\n type: \"array\",\n description: \"Worktree IDs that must complete before this one can activate\",\n },\n blocks: {\n type: \"array\",\n description: \"Worktree IDs blocked by this worktree\",\n },\n staffingHint: {\n type: \"string\",\n description: \"Suggested staffing or agent allocation note\",\n },\n lensId: {\n type: \"string\",\n description: \"Lens that scopes this worktree when applicable\",\n },\n lastReconciledAt: {\n type: \"number\",\n description: \"Timestamp when worktree metadata was last reconciled\",\n },\n },\n required: [\"title\"],\n response: {\n description: \"The created worktree\",\n fields: {\n worktreeId: \"string\",\n branchId: \"string | null\",\n status: \"string — usually 'planning' or 'active'\",\n title: \"string\",\n hypothesis: \"string | null\",\n questionCount: \"number\",\n taskCount: \"number\",\n autoShapeApplied: \"boolean\",\n frameworkSuggestions: \"array\",\n dependencySuggestions: \"array\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const LIST_WORKTREES_BY_BELIEF: McpToolContract = {\n name: \"list_worktrees_by_belief\",\n description:\n \"List worktrees that adopted or reference a belief through the worktree-belief backref index. \" +\n \"Like `git branch --contains <commit>` for reasoning substrate — shows which \" +\n \"investigation branches carried a belief into the graph and with what adoption metadata.\",\n parameters: {\n beliefId: {\n type: \"string\",\n description: \"Belief node ID whose adopting worktrees should be listed.\",\n },\n status: {\n type: \"string\",\n description: \"Optional worktree lifecycle status filter.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum worktrees to return.\",\n },\n },\n required: [\"beliefId\"],\n response: {\n description: \"Worktrees that adopted or reference the belief\",\n fields: {\n beliefId: \"string — requested belief node id\",\n worktrees:\n \"array — worktree records with adoption relationType, confidence deltas, evidence counts, and timestamps\",\n total: \"number — returned worktree count\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const MERGE: McpToolContract = {\n name: \"merge\",\n description:\n \"Merge a worktree's findings into the stable knowledge base (main). \" +\n \"Like `git merge` to main — formulations freeze, confidence is recorded, findings are integrated. \" +\n \"Each belief gets a confidence score and rationale. After merge, beliefs can only evolve via fork. \" +\n \"Low-confidence beliefs may need forking.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to merge\" },\n outcomes: {\n type: \"array\",\n description:\n \"Merge outcomes as key-finding strings, or scoring outcomes for beliefs: { beliefId, confidence, rationale }\",\n },\n summary: { type: \"string\", description: \"Overall findings summary\" },\n },\n required: [\"worktreeId\", \"outcomes\"],\n response: {\n description: \"Merge result\",\n fields: {\n worktreeId: \"string\",\n status: \"string — 'merged'\",\n beliefsScored: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// LINEAGE AND AUDIT TOOLS\n// =============================================================================\n\nexport const PUSH: McpToolContract = {\n name: \"push\",\n description:\n \"Push scored beliefs from a merged worktree to other contexts. \" +\n \"Like `git push` — makes local findings available on the remote. \" +\n \"Only merged beliefs can be pushed. \" +\n \"Publication makes findings visible to other projects, teams, or external consumers.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The merged worktree whose findings to push\",\n },\n targetContext: {\n type: \"string\",\n description: \"Where to push (e.g., 'portfolio', 'ic_review', 'external')\",\n },\n beliefIds: {\n type: \"array\",\n description: \"Optional subset of beliefs to push (default: all scored)\",\n },\n },\n required: [\"worktreeId\", \"targetContext\"],\n response: {\n description: \"Push result\",\n fields: {\n pushedCount: \"number\",\n targetContext: \"string\",\n pushedAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// PULL REQUEST TOOLS (git pull request)\n// =============================================================================\n\nexport const OPEN_PULL_REQUEST: McpToolContract = {\n name: \"open_pull_request\",\n description:\n \"Open a pull request for peer review before merging a worktree. \" +\n \"Like opening a `git pull request` — the worktree's findings are ready but await approval before merge. \" +\n \"Reviewers can approve, request changes, or block the merge. \" +\n \"This is the gate between draft work and scored knowledge.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The worktree to submit for review\",\n },\n reviewers: {\n type: \"array\",\n description: \"User IDs of requested reviewers\",\n },\n summary: {\n type: \"string\",\n description: \"Summary of findings and why they're ready for merge\",\n },\n },\n required: [\"worktreeId\", \"summary\"],\n response: {\n description: \"The pull request\",\n fields: {\n pullRequestId: \"string\",\n worktreeId: \"string\",\n status: \"string — 'pending_review'\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// FORENSIC TOOLS (git bisect)\n// =============================================================================\n","/** Reasoning methods supported by the kernel edge schema. */\nexport const REASONING_METHODS = [\n \"deductive\",\n \"inductive\",\n \"abductive\",\n \"analogical\",\n \"causal\",\n \"correlational\",\n \"testimonial\",\n \"statistical\",\n \"implicit\",\n \"pattern_match\",\n] as const;\n\nexport type ReasoningMethod = (typeof REASONING_METHODS)[number];\n","import type { McpToolContract } from \"./tool-contracts.types\";\nimport { REASONING_METHODS } from \"./api-enums.contract\";\n\nexport const QUERY_LINEAGE: McpToolContract = {\n name: \"query_lineage\",\n description:\n \"Trace a belief's full ancestry — every fork, score, and SL scoring event. \" +\n \"Like `git log --graph`. \" +\n \"Returns the complete evolution chain showing how understanding developed over time. \" +\n \"Lineage is permanent and can never be erased (Invariant #3).\",\n parameters: {\n nodeId: { type: \"string\", description: \"Starting node to trace from\" },\n depth: {\n type: \"number\",\n description: \"How many generations to traverse (default: 5)\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Canonical lineage result\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n lineage: \"array — ancestry entries with beliefId, nodeId, formulation, forkReason, and createdAt\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const QUERY_ANCHOR_HISTORY: McpToolContract = {\n name: \"query_anchor_history\",\n description:\n \"Resolve anchor provenance history for a reasoning node. \" +\n \"Like `git log --ancestry-path` for derived reasoning — follows canonical \" +\n \"derived_from lineage while preserving the storage-only extracted_from alias.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Starting node to trace from\" },\n startNode: {\n type: \"string\",\n description: \"Starting node alias accepted by traversal callers\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth\",\n },\n mode: {\n type: \"string\",\n description: \"Traversal mode; defaults to anchor_down\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Anchor provenance lineage result\",\n fields: {\n lineage:\n \"array — provenance entries with node, depth, edgeType, and layer metadata\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_CONFIDENCE_HISTORY: McpToolContract = {\n name: \"get_confidence_history\",\n description:\n \"Get the full confidence history for a belief. \" +\n \"Each entry records the confidence level, trigger, rationale, and actor. \" +\n \"Like `git log` for a single metric — append-only, never overwritten.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to get history for\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Confidence history entries\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n entries: \"array — { confidence, trigger, rationale, timestamp, userId }\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const GET_AUDIT_TRAIL: McpToolContract = {\n name: \"get_audit_trail\",\n description:\n \"Get the full audit trail for a node — every mutation, who made it, when, and why. \" +\n \"Like `git blame` for knowledge. \" +\n \"All state transitions are explicit, attributable, and permanently queryable. \" +\n \"No silent changes are possible (Invariant #14).\",\n parameters: {\n nodeId: { type: \"string\", description: \"The node to audit\" },\n limit: {\n type: \"number\",\n description: \"Maximum entries to return (default: 50)\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Audit trail entries\",\n fields: {\n entries: \"array — { action, actor, timestamp, before, after, rationale }\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// GRAPH QUERY TOOLS\n// =============================================================================\n\nexport const TRAVERSE_GRAPH: McpToolContract = {\n name: \"traverse_graph\",\n description:\n \"Walk the reasoning graph from a starting node. \" +\n \"Like `git log --graph` — traverses connected lineage across nodes and edges. \" +\n \"Traversal follows epistemic layers: L4 (judgments) → L3 (beliefs, questions) → L2 (evidence) → L1 (sources). \" +\n \"Never skips layers. \" +\n \"Use direction 'up' to trace what a piece of evidence supports, 'down' to trace what supports a judgment.\",\n parameters: {\n startNode: { type: \"string\", description: \"Node to start traversal from\" },\n direction: {\n type: \"string\",\n description: \"Traversal direction\",\n enum: [\"up\", \"down\", \"both\"],\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth (default: 3)\",\n },\n },\n required: [\"startNode\"],\n response: {\n description: \"Subgraph of traversed nodes and edges\",\n fields: {\n nodes: \"array — traversed nodes\",\n edges: \"array — traversed edges\",\n depth: \"number\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_GRAPH_NEIGHBORHOOD: McpToolContract = {\n name: \"get_graph_neighborhood\",\n description:\n \"Retrieve the local neighborhood around one or more graph nodes. \" +\n \"Like `git log --graph --boundary` for a focused reasoning window. \" +\n \"Returns the canonical neighborhood payload shared by HTTP and SDK graph surfaces.\",\n parameters: {\n globalId: {\n type: \"string\",\n description: \"Single root node global identifier.\",\n },\n globalIds: {\n type: \"array\",\n description: \"Optional list of root node global identifiers.\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth (default: 2).\",\n },\n },\n required: [],\n response: {\n description: \"Canonical graph neighborhood payload\",\n fields: {\n nodes: \"array — graph nodes in the returned neighborhood\",\n edges: \"array — graph edges in the returned neighborhood\",\n depth: \"number — deepest traversed node depth\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const TRACE_ENTITY_IMPACT: McpToolContract = {\n name: \"trace_entity_impact\",\n description:\n \"Returns code-grounded beliefs, contracts, migration states, and failed attempts \" +\n \"anchored to a specific file or function path. \" +\n \"Like `git log -- <path>` — filters the knowledge graph to nodes anchored to a file path \" +\n \"via metadata.codeAnchors. Results are separated by coding belief type: decisions, contracts, \" +\n \"migrations, patterns, deprecations, and failures.\",\n parameters: {\n nodeId: {\n type: \"string\",\n description: \"Entity node ID to trace impact from\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description:\n \"Entity impact trace: direct beliefs, evidence, and indirect belief reach\",\n fields: {\n entityNodeId: \"string — the traced entity\",\n entityType: \"string — nodeType of the entity\",\n directBeliefConnections:\n \"array — beliefs directly connected via bridge edges\",\n evidenceConnections: \"array — evidence referencing this entity\",\n indirectBeliefConnections: \"array — beliefs reached through evidence\",\n totalBeliefReach: \"number — total unique beliefs impacted\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SEARCH_BELIEFS: McpToolContract = {\n name: \"search_beliefs\",\n description:\n \"Search for beliefs in the reasoning graph. \" +\n \"Like `git grep` — finds relevant beliefs across the full history and active state. \" +\n \"Supports semantic search, filtering by status (unscored, scored, archived), \" +\n \"confidence thresholds, and topic scope. \" +\n \"Returns beliefs with their current confidence, lineage depth, and contradiction count.\",\n parameters: {\n query: { type: \"string\", description: \"Semantic search query\" },\n status: {\n type: \"string\",\n description: \"Filter by belief status\",\n enum: [\"unscored\", \"scored\", \"archived\"],\n },\n minConfidence: {\n type: \"number\",\n description: \"Minimum confidence threshold (0-1)\",\n },\n topicId: { type: \"string\", description: \"Filter by topic\" },\n limit: { type: \"number\", description: \"Maximum results (default: 10)\" },\n },\n required: [\"query\"],\n response: {\n description: \"Matching beliefs with metadata\",\n fields: {\n results:\n \"array — { nodeId, canonicalText, confidence, status, contradictionCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const FIND_CONTRADICTIONS: McpToolContract = {\n name: \"find_contradictions\",\n description:\n \"Find contradictions in the reasoning graph — beliefs that are in tension with each other. \" +\n \"Like a merge conflict in `git` — surfaces incompatible states that require explicit resolution. \" +\n \"Contradictions are first-class objects that may remain permanently unresolved. \" +\n \"They can block judgments, trigger forks, or collapse confidence. \" +\n \"Filter by project, status (unresolved, resolved, accepted), and severity.\",\n parameters: {\n topicId: { type: \"string\", description: \"Required topic scope filter\" },\n nodeId: {\n type: \"string\",\n description: \"Optional belief identifier to filter contradictions within the topic\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\n \"unresolved\",\n \"investigating\",\n \"accepted_as_permanent\",\n \"resolved_by_fork\",\n \"resolved_by_evidence\",\n \"resolved_by_reinterpretation\",\n \"superseded\",\n ],\n },\n limit: { type: \"number\", description: \"Maximum contradictions to return\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Contradiction objects\",\n fields: {\n contradictions:\n \"array — { beliefA, beliefB, description, severity, status, defeatType }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// EDGE TOOLS\n// =============================================================================\n\nexport const BISECT_CONFIDENCE: McpToolContract = {\n name: \"bisect_confidence\",\n description:\n \"Find when a belief's confidence diverged from reality. \" +\n \"Like `git bisect` — binary search through the credence history to find the inflection point. \" +\n \"Given a belief that is now known to be wrong (or right), traces back through \" +\n \"SL scoring events to identify which evidence or event caused the divergence.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to bisect\" },\n expectedDirection: {\n type: \"string\",\n description: \"Was confidence too high or too low?\",\n enum: [\"overconfident\", \"underconfident\"],\n },\n timeRange: {\n type: \"object\",\n description:\n \"Optional time range to search within: { start: number, end: number }\",\n },\n },\n required: [\"nodeId\", \"expectedDirection\"],\n response: {\n description: \"The inflection point in confidence history\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n expectedDirection: \"string — overconfident | underconfident\",\n inflectionEntry: \"object — the scoring event where divergence began\",\n triggerEvent: \"string | null — what caused the divergence\",\n confidenceBefore: \"number | null\",\n confidenceAfter: \"number | null\",\n totalEntries: \"number\",\n inflectionIndex: \"number | null\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// GRAPH INTELLIGENCE TOOLS\n// =============================================================================\n\nexport const CREATE_EDGE: McpToolContract = {\n name: \"create_edge\",\n description:\n \"Commit a typed relationship between two nodes in the reasoning graph. \" +\n \"Like `git commit` — an atomic write that declares a dependency between nodes. \" +\n \"Accepts any public epistemic edge type between public graph node refs so agents can author the full spine.\",\n parameters: {\n from: {\n type: \"object\",\n description:\n \"Source graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'topic' }\",\n },\n to: {\n type: \"object\",\n description:\n \"Target graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'belief' }\",\n },\n edgeType: {\n type: \"string\",\n description:\n \"Relationship type from the public epistemic edge enum.\",\n },\n globalId: {\n type: \"string\",\n description: \"Optional idempotent edge global ID.\",\n },\n weight: {\n type: \"number\",\n description:\n \"Edge weight: -1.0 to +1.0 for informs edges, 0-1 for structural\",\n },\n reasoning: { type: \"string\", description: \"Why this relationship exists\" },\n reasoningMethod: {\n type: \"string\",\n description: \"How this was determined\",\n enum: [...REASONING_METHODS],\n },\n metadata: {\n type: \"object\",\n description: \"Optional edge metadata.\",\n },\n },\n required: [\"from\", \"to\", \"edgeType\"],\n response: {\n description: \"The created edge\",\n fields: {\n globalId: \"string — edge identifier\",\n edgeType: \"string\",\n fromLayer: \"string\",\n toLayer: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"showcase\",\n};\n\nexport const UPDATE_EDGE: McpToolContract = {\n name: \"update_edge\",\n description:\n \"Amend metadata on an existing graph edge. \" +\n \"Like `git commit --amend` — changes the edge annotation without recreating the relationship.\",\n parameters: {\n edgeId: { type: \"string\", description: \"Edge ID or global ID to update\" },\n weight: { type: \"number\", description: \"Updated edge weight\" },\n confidence: { type: \"number\", description: \"Updated confidence\" },\n context: { type: \"string\", description: \"Updated human-readable context\" },\n derivationType: { type: \"string\", description: \"Updated derivation type\" },\n metadata: { type: \"object\", description: \"Updated metadata\" },\n },\n required: [\"edgeId\"],\n response: {\n description: \"Edge update result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_EDGE: McpToolContract = {\n name: \"remove_edge\",\n description:\n \"Remove one graph edge by ID. \" +\n \"Like `git rm` — deletes a single explicit relationship from the spine.\",\n parameters: {\n edgeId: { type: \"string\", description: \"Edge ID or global ID to remove\" },\n },\n required: [\"edgeId\"],\n response: {\n description: \"Edge removal result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_EDGES_BETWEEN: McpToolContract = {\n name: \"remove_edges_between\",\n description:\n \"Remove graph edges between two nodes. \" +\n \"Like `git rm <pathspec>` — deletes relationships matching a source, target, and optional type.\",\n parameters: {\n fromNodeId: { type: \"string\", description: \"Source node ID or global ID\" },\n toNodeId: { type: \"string\", description: \"Target node ID or global ID\" },\n edgeType: { type: \"string\", description: \"Optional edge type filter\" },\n },\n required: [\"fromNodeId\", \"toNodeId\"],\n response: {\n description: \"Matched edge removal result\",\n fields: { deleted: \"number\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const BATCH_CREATE_EDGES: McpToolContract = {\n name: \"batch_create_edges\",\n description:\n \"Commit multiple typed graph edges. \" +\n \"Like `git commit` with many staged paths — writes a batch of explicit relationships atomically per edge.\",\n parameters: {\n edges: {\n type: \"array\",\n description:\n \"Edges to create, each with from, to, edgeType, and optional weight/confidence/context.\",\n },\n skipLayerValidation: {\n type: \"boolean\",\n description: \"Skip kernel layer validation for trusted materialization flows.\",\n },\n },\n required: [\"edges\"],\n response: {\n description: \"Batch edge creation result\",\n fields: {\n created: \"number\",\n results: \"array\",\n errors: \"array\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// EPISTEMIC NODE TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nconst sharedEmbeddingParameters = {\n topicId: {\n type: \"string\",\n description: \"Topic whose epistemic node embedding index should be queried.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Workspace scope for the embedding operation.\",\n },\n nodeType: {\n type: \"string\",\n description: \"Optional epistemic node type filter.\",\n },\n embeddingModel: {\n type: \"string\",\n description: \"Optional embedding model filter.\",\n },\n includeInactive: {\n type: \"boolean\",\n description: \"Include archived, superseded, or otherwise inactive epistemic nodes in coverage checks.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum rows to return.\",\n },\n} satisfies McpToolContract[\"parameters\"];\n\nexport const LIST_MISSING_EMBEDDINGS: McpToolContract = {\n name: \"list_missing_embeddings\",\n description:\n \"List epistemic nodes missing fresh Convex embeddings. \" +\n \"Like `git status` for the semantic index — shows which graph nodes still need indexing before retrieval can be trusted.\",\n parameters: sharedEmbeddingParameters,\n required: [\"topicId\", \"workspaceId\"],\n response: {\n description: \"Missing or stale embedding candidates\",\n fields: {\n nodes: \"array — node candidates missing fresh embeddings\",\n total: \"number — candidate count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SEARCH_EMBEDDINGS: McpToolContract = {\n name: \"search_embeddings\",\n description:\n \"Search topic-scoped epistemic nodes through the Convex vector index. \" +\n \"Like `git grep` with semantic distance — finds matching beliefs, questions, evidence, and other nodes even when wording differs.\",\n parameters: {\n ...sharedEmbeddingParameters,\n queryText: {\n type: \"string\",\n description: \"Natural-language query to embed and search with.\",\n },\n queryVector: {\n type: \"array\",\n description: \"Optional precomputed query vector.\",\n },\n minScore: {\n type: \"number\",\n description: \"Optional minimum cosine-similarity score.\",\n },\n },\n required: [\"topicId\", \"workspaceId\"],\n response: {\n description: \"Vector search matches\",\n fields: {\n results: \"array — semantic matches with nodeId, nodeType, score, text, and provenance\",\n total: \"number — match count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_EMBEDDINGS_BY_NODE_IDS: McpToolContract = {\n name: \"get_embeddings_by_node_ids\",\n description:\n \"Fetch embedding records for explicit epistemic node IDs. \" +\n \"Like `git show` for semantic-index rows — inspects exactly which vectors exist for named graph nodes.\",\n parameters: {\n ...sharedEmbeddingParameters,\n nodeIds: {\n type: \"array\",\n description: \"Epistemic node IDs to inspect.\",\n },\n },\n required: [\"topicId\", \"workspaceId\", \"nodeIds\"],\n response: {\n description: \"Embedding records for explicit node IDs\",\n fields: {\n embeddings: \"array — embedding metadata records\",\n total: \"number — embedding count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const QUEUE_EMBEDDING_BACKFILL: McpToolContract = {\n name: \"queue_embedding_backfill\",\n description:\n \"Queue background embedding generation for explicit epistemic nodes. \" +\n \"Like `git add` for semantic-index work — stages graph nodes for the kernel backfill scheduler.\",\n parameters: {\n ...sharedEmbeddingParameters,\n nodeIds: {\n type: \"array\",\n description: \"Epistemic node IDs to queue for embedding generation.\",\n },\n },\n required: [\"topicId\", \"workspaceId\", \"nodeIds\"],\n response: {\n description: \"Backfill queue receipt\",\n fields: {\n queued: \"number — queued node count\",\n nodeIds: \"array — node IDs queued for embedding generation\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nconst hybridParameters = {\n query: {\n type: \"string\",\n description: \"Natural-language query text to resolve against the typed reasoning graph.\",\n },\n queryText: {\n type: \"string\",\n description: \"Explicit query text alias for clients that separate command words from search text.\",\n },\n text: {\n type: \"string\",\n description: \"Raw pasted text to use as a semantic retrieval seed.\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope. When omitted, semantic topic candidates are resolved first.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Optional workspace scope used by semantic topic candidates and vector search.\",\n },\n nodeId: {\n type: \"string\",\n description: \"Optional source node used for related-node or impact analysis.\",\n },\n include: {\n type: \"array\",\n description:\n \"Result families to include, such as topics, nodes, worktrees, tasks, evidence, and edges.\",\n },\n via: {\n type: \"array\",\n description:\n \"Retrieval methods to use: bm25, embeddings, edges, topic-tree, state, graph-algorithms.\",\n },\n depth: {\n type: \"number\",\n description: \"Graph expansion depth. Defaults to 1 and is capped by the server.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum rows per result family.\",\n },\n minScore: {\n type: \"number\",\n description: \"Minimum semantic or fused score for candidate rows.\",\n },\n campaign: {\n type: \"number\",\n description: \"Optional worktree campaign filter.\",\n },\n lane: {\n type: \"string\",\n description: \"Optional worktree lane filter.\",\n },\n status: {\n type: \"string\",\n description: \"Optional node, task, or worktree state/status filter.\",\n },\n nodeTypes: {\n type: \"array\",\n description: \"Optional epistemic node types to include.\",\n },\n changedPaths: {\n type: \"array\",\n description: \"Changed file paths used as impact-analysis query signals.\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional planner metadata for receipts and caller provenance.\",\n },\n} satisfies McpToolContract[\"parameters\"];\n\nconst hybridResponse = {\n description: \"Hybrid semantic graph planner response with ranked result families and retrieval receipt.\",\n fields: {\n results: \"array — ranked mixed graph results with score, kind, source, and ranking signals\",\n topics: \"array — candidate or traversed topics\",\n nodes: \"array — matching epistemic nodes\",\n worktrees: \"array — matching worktrees\",\n tasks: \"array — matching tasks\",\n evidence: \"array — matching evidence\",\n edges: \"array — graph neighborhood edges\",\n receipt: \"object — planner steps, candidate counts, ranking weights, source/cache posture\",\n },\n} satisfies McpToolContract[\"response\"];\n\nexport const HYBRID_DISCOVER: McpToolContract = {\n name: \"hybrid_discover\",\n description:\n \"Discover typed reasoning graph context with BM25, embeddings, topic tree traversal, and graph neighborhoods. \" +\n \"Like `git grep` plus `git log --graph` for Lucern's typed reasoning graph — finds the relevant branches of thought and explains why.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const RESOLVE_TOPIC_SEMANTIC: McpToolContract = {\n name: \"resolve_topic_semantic\",\n description:\n \"Resolve an ambiguous topic using BM25, vector candidates, and topic-tree context. \" +\n \"Like `git remote show` for a reasoning topic — finds the canonical branch and nearby branches before reading deeper.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const EXPAND_GRAPH_NEIGHBORHOOD: McpToolContract = {\n name: \"expand_graph_neighborhood\",\n description:\n \"Expand a typed graph neighborhood around a query, topic, or node. \" +\n \"Like `git log --graph --decorate` for reasoning state — follows typed edges and surfaces the surrounding context.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const FIND_RELATED_NODES: McpToolContract = {\n name: \"find_related_nodes\",\n description:\n \"Find semantically and structurally related nodes across the reasoning graph. \" +\n \"Like `git blame` across branches — starts from a node or text and finds nearby responsibility, evidence, and related claims.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const ANALYZE_GRAPH_IMPACT: McpToolContract = {\n name: \"analyze_graph_impact\",\n description:\n \"Analyze which graph objects are affected by files, PR text, incidents, or campaign objectives. \" +\n \"Like `git diff --name-only` plus semantic blame — maps a change signal onto topics, beliefs, tasks, and unresolved questions.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const DETECT_GRAPH_DRIFT: McpToolContract = {\n name: \"detect_graph_drift\",\n description:\n \"Detect duplicate, stale, orphaned, or weakly linked reasoning graph surface. \" +\n \"Like `git fsck` for the reasoning graph — finds semantic duplicates, stale docs/code references, and missing links.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n","/**\n * Canonical lens workflow contract shared across schema, SDK, and MCP surfaces.\n */\n\n// Re-export filter criteria types for consumers who import from lens-workflow\nexport type {\n LensFilterCriteria,\n TaxonomyFilterCriteriaV1,\n EntityTypeFilterV1,\n OntologyScope,\n FilterValidationResult,\n} from \"./lens-filter.contract\";\nexport {\n validateFilterCriteria,\n isLensFilterCriteria,\n isTaxonomyFilterCriteriaV1,\n} from \"./lens-filter.contract\";\n\nexport const LENS_PERSPECTIVE_TYPES = [\n \"investigation\",\n \"monitoring\",\n \"analysis\",\n \"comparison\",\n \"taxonomy\",\n] as const;\n\nexport type LensPerspectiveType = (typeof LENS_PERSPECTIVE_TYPES)[number];\n\nexport const LENS_STATUSES = [\"draft\", \"active\", \"archived\"] as const;\n\nexport type LensStatus = (typeof LENS_STATUSES)[number];\n\nexport const LENS_TASK_TEMPLATE_PRIORITIES = [\n \"critical\",\n \"high\",\n \"medium\",\n \"low\",\n] as const;\n\nexport type LensTaskTemplatePriority =\n (typeof LENS_TASK_TEMPLATE_PRIORITIES)[number];\n\nexport type LensLooseMetadata = Record<string, unknown>;\n\nexport type LensPromptTemplateReference = {\n key: string;\n promptRef: string;\n phase?: string;\n role?: string;\n version?: string;\n required?: boolean;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensWorkflowStepTemplate = {\n key: string;\n title: string;\n description?: string;\n promptTemplateKey?: string;\n taskTemplateKeys?: string[];\n metadata?: LensLooseMetadata;\n};\n\nexport type LensWorkflowTemplate = {\n key: string;\n name: string;\n description?: string;\n steps: LensWorkflowStepTemplate[];\n metadata?: LensLooseMetadata;\n};\n\nexport type LensTaskTemplate = {\n key: string;\n title: string;\n description?: string;\n priority?: LensTaskTemplatePriority;\n phase?: string;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensQuestionTemplate = {\n key: string;\n text: string;\n priority?: LensTaskTemplatePriority;\n linkedBeliefKey?: string;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensBranchMigrationSuggestion = {\n recommendedTool: \"create_lens\";\n perspectiveType: LensPerspectiveType;\n message: string;\n suggestedPayload: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n perspectiveType: LensPerspectiveType;\n };\n};\n\nexport const BRANCH_DEPRECATION_MESSAGE =\n \"Branches are deprecated for operational framing. Create a workspace-scoped lens instead.\";\n\nexport type DeprecatedBranchMetadata = {\n deprecated: true;\n deprecationMessage: string;\n lensSuggestion: LensBranchMigrationSuggestion;\n};\n\nexport function inferLensPerspectiveTypeFromBranchSchema(\n schema?: string | null\n): LensPerspectiveType {\n const normalized = schema?.trim().toLowerCase();\n if (normalized === \"phase\") {\n return \"monitoring\";\n }\n if (normalized === \"axis\" || normalized === \"dimension\") {\n return \"comparison\";\n }\n if (normalized === \"track\") {\n return \"investigation\";\n }\n return \"analysis\";\n}\n\nexport function migrateBranchToLens(args: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n schema?: string | null;\n}): LensBranchMigrationSuggestion {\n const perspectiveType = inferLensPerspectiveTypeFromBranchSchema(args.schema);\n return {\n recommendedTool: \"create_lens\",\n perspectiveType,\n message:\n \"Branches are deprecated for operational framing. Create a workspace-scoped lens with the suggested payload instead.\",\n suggestedPayload: {\n name: args.name,\n description: args.description,\n topicId: args.topicId,\n workspaceId: args.workspaceId,\n perspectiveType,\n },\n };\n}\n\nexport function buildDeprecatedBranchMetadata(args: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n schema?: string | null;\n}): DeprecatedBranchMetadata {\n return {\n deprecated: true,\n deprecationMessage: BRANCH_DEPRECATION_MESSAGE,\n lensSuggestion: migrateBranchToLens(args),\n };\n}\n","import type { McpToolContract } from \"./tool-contracts.types\";\nimport { LENS_PERSPECTIVE_TYPES } from \"./lens-workflow.contract\";\n\nexport const CREATE_EPISTEMIC_NODE: McpToolContract = {\n name: \"create_epistemic_node\",\n description:\n \"Commit a generic epistemic graph node. \" +\n \"Like `git commit` — creates a canonical node in the public spine for topics, beliefs, evidence, questions, answers, sources, and entities.\",\n parameters: {\n globalId: { type: \"string\", description: \"Optional idempotent node global ID\" },\n nodeType: { type: \"string\", description: \"Public epistemic node type\" },\n canonicalText: { type: \"string\", description: \"Canonical node text\" },\n text: { type: \"string\", description: \"Alias for canonicalText\" },\n contentHash: { type: \"string\", description: \"Optional idempotency content hash\" },\n sourceType: { type: \"string\", description: \"Source type for provenance\" },\n topicId: { type: \"string\", description: \"Optional topic scope\" },\n content: { type: \"string\", description: \"Extended content\" },\n title: { type: \"string\", description: \"Display title\" },\n metadata: { type: \"object\", description: \"Optional node metadata\" },\n },\n required: [\"nodeType\"],\n response: {\n description: \"Created node result\",\n fields: {\n nodeId: \"string\",\n nodeGlobalId: \"string\",\n isDuplicate: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_EPISTEMIC_NODE: McpToolContract = {\n name: \"get_epistemic_node\",\n description:\n \"Read one epistemic graph node. \" +\n \"Like `git show` — resolves a canonical spine node by ID or global ID.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"The resolved node\",\n fields: { node: \"object\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const LIST_EPISTEMIC_NODES: McpToolContract = {\n name: \"list_epistemic_nodes\",\n description:\n \"List epistemic graph nodes. \" +\n \"Like `git ls-tree` — lists canonical spine nodes by topic, type, status, or search query.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope\" },\n nodeType: { type: \"string\", description: \"Optional node type filter\" },\n status: { type: \"string\", description: \"Optional lifecycle status\" },\n searchQuery: { type: \"string\", description: \"Optional text search query\" },\n limit: { type: \"number\", description: \"Maximum nodes to return\" },\n },\n required: [],\n response: {\n description: \"Matching nodes\",\n fields: { nodes: \"array\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_EPISTEMIC_NODE: McpToolContract = {\n name: \"update_epistemic_node\",\n description:\n \"Amend an epistemic graph node. \" +\n \"Like `git commit --amend` — updates mutable node metadata, text, status, or verification fields.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n canonicalText: { type: \"string\", description: \"Updated canonical text\" },\n text: { type: \"string\", description: \"Alias for canonicalText\" },\n contentHash: { type: \"string\", description: \"Updated content hash\" },\n content: { type: \"string\", description: \"Updated content\" },\n title: { type: \"string\", description: \"Updated display title\" },\n metadata: { type: \"object\", description: \"Updated metadata\" },\n confidence: { type: \"number\", description: \"Updated confidence\" },\n verificationStatus: { type: \"string\", description: \"Updated verification status\" },\n status: { type: \"string\", description: \"Updated lifecycle status\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Node update result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_EPISTEMIC_NODE: McpToolContract = {\n name: \"archive_epistemic_node\",\n description:\n \"Archive an epistemic graph node. \" +\n \"Like `git rm --cached` — removes a node from active traversal without hard-deleting it.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Archive result\",\n fields: { success: \"boolean\", effectiveStatus: \"string\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const VERIFY_EPISTEMIC_NODE: McpToolContract = {\n name: \"verify_epistemic_node\",\n description:\n \"Record verification state on an epistemic graph node. \" +\n \"Like `git tag` — marks the node with a reviewed verification state.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n verificationStatus: { type: \"string\", description: \"Verification status\" },\n confidence: { type: \"number\", description: \"Optional confidence update\" },\n },\n required: [\"nodeId\", \"verificationStatus\"],\n response: {\n description: \"Verification result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SUPERSEDE_EPISTEMIC_NODE: McpToolContract = {\n name: \"supersede_epistemic_node\",\n description:\n \"Supersede an epistemic graph node with a new version. \" +\n \"Like `git commit --amend` on an immutable history branch — creates the replacement and marks the old node superseded.\",\n parameters: {\n oldNodeId: { type: \"string\", description: \"Node ID or global ID to supersede\" },\n newGlobalId: { type: \"string\", description: \"Optional replacement global ID\" },\n newCanonicalText: { type: \"string\", description: \"Replacement canonical text\" },\n text: { type: \"string\", description: \"Alias for newCanonicalText\" },\n newContentHash: { type: \"string\", description: \"Optional replacement content hash\" },\n reason: { type: \"string\", description: \"Reason for superseding\" },\n },\n required: [\"oldNodeId\"],\n response: {\n description: \"Supersede result\",\n fields: { oldNodeId: \"string\", newNodeId: \"string\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const BATCH_CREATE_EPISTEMIC_NODES: McpToolContract = {\n name: \"batch_create_epistemic_nodes\",\n description:\n \"Commit multiple epistemic graph nodes. \" +\n \"Like `git commit` with many staged files — writes a batch of canonical spine nodes.\",\n parameters: {\n nodes: {\n type: \"array\",\n description: \"Nodes to create with nodeType, canonicalText/text, and optional metadata.\",\n },\n },\n required: [\"nodes\"],\n response: {\n description: \"Batch node creation result\",\n fields: { created: \"number\", results: \"array\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// JUDGMENT TOOLS (Phase 1: new vocabulary, aliased to decision implementation)\n// =============================================================================\n\nexport const RECORD_JUDGMENT: McpToolContract = {\n name: \"record_judgment\",\n description:\n \"Record a judgment — an irreversible commitment based on the current epistemic state. \" +\n \"Like a `git tag` marking a release. \" +\n \"A judgment synthesizes beliefs, evidence, and uncertainties into a determination. \" +\n \"Once issued, a judgment is evaluated against the epistemic state that existed when it was made \" +\n \"(knowledge horizon evaluation, Invariant #10).\",\n parameters: {\n title: { type: \"string\", description: \"Short judgment statement\" },\n rationale: {\n type: \"string\",\n description: \"Full reasoning behind the judgment\",\n },\n topicId: { type: \"string\", description: \"Topic scope\" },\n beliefIds: {\n type: \"array\",\n description: \"Beliefs that warrant this judgment\",\n },\n confidence: {\n type: \"number\",\n description: \"Confidence in the judgment (0-1)\",\n },\n },\n required: [\"title\", \"rationale\"],\n response: {\n description: \"The recorded judgment\",\n fields: {\n judgmentId: \"string\",\n title: \"string\",\n status: \"string — 'issued'\",\n },\n },\n ownerModule: \"decisions\",\n ontologyPrimitive: \"judgment\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// LENS TOOLS (workspace-scoped operational frames)\n// =============================================================================\n\nexport const CREATE_LENS: McpToolContract = {\n name: \"create_lens\",\n description:\n \"Create a reusable lens that overlays a workspace topic with a specific analytical perspective. \" +\n \"Like `git branch <name>` for operational scaffolding — a lens persists across worktrees and carries prompts, workflows, and task templates. \" +\n \"Multiple topics in the same workspace can reuse the same lens.\",\n parameters: {\n name: {\n type: \"string\",\n description: \"Lens name (e.g., 'market dynamics', 'team quality')\",\n },\n workspaceId: {\n type: \"string\",\n description:\n \"Workspace scope for the lens. Required unless topicId resolves to a workspace-scoped topic.\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Optional originating topic scope. Lenses remain reusable across topics even when this is set.\",\n },\n description: {\n type: \"string\",\n description: \"What this lens is designed to investigate or monitor\",\n },\n perspectiveType: {\n type: \"string\",\n description:\n \"Perspective type for the lens. Validated against schemaEnumConfig category 'lens_perspective_type'.\",\n enum: [...LENS_PERSPECTIVE_TYPES],\n },\n promptTemplates: {\n type: \"array\",\n description: \"Langfuse prompt references used when operating through this lens\",\n },\n workflowTemplates: {\n type: \"array\",\n description: \"Guided workflow templates for lens-driven investigations\",\n },\n taskTemplates: {\n type: \"array\",\n description: \"Default task templates instantiated when the lens is applied\",\n },\n filterCriteria: {\n type: \"object\",\n description: \"Belief/evidence filtering rules applied by the lens\",\n },\n },\n required: [\"name\", \"perspectiveType\"],\n response: {\n description: \"The created lens\",\n fields: {\n lensId: \"string\",\n name: \"string\",\n workspaceId: \"string\",\n status: \"string — 'active'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"showcase\",\n};\n\nexport const LIST_LENSES: McpToolContract = {\n name: \"list_lenses\",\n description:\n \"List reusable lenses for a workspace, optionally scored by whether they are active on a topic. \" +\n \"Like `git branch --list` — shows the available named frames you can activate. \" +\n \"When topicId is provided, the response can indicate which lenses are already applied there.\",\n parameters: {\n workspaceId: {\n type: \"string\",\n description: \"Workspace scope to list lenses from\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Optional topic scope used to derive workspace and annotate applied lenses\",\n },\n status: {\n type: \"string\",\n description: \"Filter by lens lifecycle status\",\n enum: [\"draft\", \"active\", \"archived\"],\n },\n perspectiveType: {\n type: \"string\",\n description: \"Filter by perspective type\",\n enum: [...LENS_PERSPECTIVE_TYPES],\n },\n },\n required: [],\n response: {\n description: \"Available lenses\",\n fields: {\n lenses:\n \"array — each item includes lensId, name, workspaceId, perspectiveType, status, and optional isAppliedToTopic\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\nexport const APPLY_LENS_TO_TOPIC: McpToolContract = {\n name: \"apply_lens_to_topic\",\n description:\n \"Apply a lens to a topic so it becomes an active perspective overlay. \" +\n \"Like `git checkout <branch>` for a reusable frame — the topic keeps its knowledge, but the active lens shapes guidance and retrieval. \" +\n \"Multiple active lenses can coexist on the same topic.\",\n parameters: {\n lensId: { type: \"string\", description: \"Lens to activate on the topic\" },\n topicId: { type: \"string\", description: \"Topic that should receive the lens\" },\n },\n required: [\"lensId\", \"topicId\"],\n response: {\n description: \"Lens activation result\",\n fields: {\n bindingId: \"string\",\n lensId: \"string\",\n topicId: \"string\",\n status: \"string — 'active'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_LENS_FROM_TOPIC: McpToolContract = {\n name: \"remove_lens_from_topic\",\n description:\n \"Remove an active lens overlay from a topic. \" +\n \"Like `git switch` away from a frame — the topic remains, but the lens stops shaping the investigation context. \" +\n \"Historical binding state is preserved for auditability.\",\n parameters: {\n lensId: { type: \"string\", description: \"Lens to remove from the topic\" },\n topicId: { type: \"string\", description: \"Topic that currently has the lens applied\" },\n },\n required: [\"lensId\", \"topicId\"],\n response: {\n description: \"Lens removal result\",\n fields: {\n bindingId: \"string\",\n lensId: \"string\",\n topicId: \"string\",\n status: \"string — 'removed'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// PUSH TOOLS (git push)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const LUCERN_ORIENT: McpToolContract = {\n name: \"lucern_orient\",\n description:\n \"Load the Lucern reasoning grammar before operating. \" +\n \"Like `git help` plus a repository CONTRIBUTING guide for reasoning state - teaches the git-shaped model of topics, campaigns, lanes, worktrees, beliefs, questions, evidence, receipts, gates, and merges.\",\n parameters: {\n audience: {\n type: \"string\",\n description: \"Audience for the primer: agent, human, operator, or developer.\",\n enum: [\"agent\", \"human\", \"operator\", \"developer\"],\n },\n depth: {\n type: \"string\",\n description: \"Orientation depth: quick, standard, or deep.\",\n enum: [\"quick\", \"standard\", \"deep\"],\n },\n situation: {\n type: \"string\",\n description:\n \"Optional task or query context used to tailor suggested next calls.\",\n },\n includeExamples: {\n type: \"boolean\",\n description: \"Whether to include concrete tool-call examples.\",\n },\n includeToolMap: {\n type: \"boolean\",\n description: \"Whether to include situation-to-tool routing guidance.\",\n },\n includeFuture: {\n type: \"boolean\",\n description:\n \"Whether to include future exemplar, gauntlet, and training-data capabilities.\",\n },\n },\n required: [],\n response: {\n description:\n \"Canonical operator primer for Lucern's git-shaped reasoning substrate.\",\n fields: {\n schemaVersion: \"string - lucern_orientation.v1\",\n canonicalMentalModel:\n \"object - concise model of Lucern as git-shaped reasoning state\",\n workflow:\n \"array - recommended branch -> investigate -> prove gate -> merge workflow\",\n grammarMap:\n \"array - primitive-to-git-analogy map for topics, campaigns, worktrees, beliefs, questions, evidence, edges, contradictions, and gates\",\n firstMoves: \"array - recommended first tools for a cold-start agent\",\n receiptRules:\n \"array - how to interpret candidateCounts, broadening, coverageWarning, narrativeCoverage, synthesisLints, and noDefaultGlobalScan\",\n safetyRules:\n \"array - mutation and completion rules that preserve reasoning lineage\",\n toolMap:\n \"array | undefined - situation-to-tool routing map when requested\",\n examples: \"array | undefined - concrete tool-call examples when requested\",\n futureCapabilities:\n \"array | undefined - exemplar, gauntlet, trace-corpus, and native-model-training capabilities when requested\",\n suggestedNextCalls:\n \"array - safe next tool calls for the current situation\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const DETECT_CONFIRMATION_BIAS: McpToolContract = {\n name: \"detect_confirmation_bias\",\n description:\n \"Detect confirmation bias in the evidence graph. \" +\n \"Like `git diff --stat` for reasoning — analyzes the ratio of supporting vs challenging evidence \" +\n \"per belief and flags beliefs where the evidence is suspiciously one-sided. \" +\n \"Returns risk classification (critical/high/moderate/healthy).\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n threshold: {\n type: \"number\",\n description: \"Bias threshold (0-1, default 0.7)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Beliefs with bias scores, risk levels, and evidence counts\",\n fields: {\n beliefs:\n \"array — { nodeId, biasScore, riskLevel, supportingCount, challengingCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_GRAPH_STRUCTURE_ANALYSIS: McpToolContract = {\n name: \"get_graph_structure_analysis\",\n description:\n \"Run comprehensive structural analysis on the knowledge graph. \" +\n \"Like `git fsck` combined with PageRank — runs 14 algorithmic detectors including \" +\n \"PageRank centrality, Louvain community detection, Tarjan SCC, Fiedler vector spectral analysis, \" +\n \"Bayesian surprise, and overconfidence detection.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Structural analysis with detector results and recommendations\",\n fields: {\n topicId: \"string — canonical topic scope\",\n metric: \"string — analysis metric identifier\",\n payload: \"object — detector results, recommendations, graph metrics\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const LIST_GRAPH_INTELLIGENCE_QUERIES: McpToolContract = {\n name: \"list_graph_intelligence_queries\",\n description:\n \"List the Graph Intelligence query catalog that powers structural graph analysis experiences. \" +\n \"Returns categories, query IDs, prompt templates, modes, and the public tool plan each query can use.\",\n parameters: {\n categoryId: {\n type: \"string\",\n description: \"Optional category filter, such as problems or strategic\",\n },\n mode: {\n type: \"string\",\n description:\n \"Optional mode filter: core, bias, stress, operational, alpha, semantic, or evidence\",\n },\n },\n required: [],\n response: {\n description:\n \"Graph Intelligence query catalog and mode-to-tool mapping\",\n fields: {\n categories: \"array — query categories\",\n queries: \"array — query definitions with prompt templates and tools\",\n quickQueries: \"array — recommended one-click query presets\",\n publicToolNamesByMode:\n \"object — public tool names available to each Graph Intelligence mode\",\n },\n },\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const RUN_GRAPH_INTELLIGENCE_QUERY: McpToolContract = {\n name: \"run_graph_intelligence_query\",\n description:\n \"Run a named Graph Intelligence query against a tenant topic graph. \" +\n \"Returns the selected query, prompt, deterministic graph-analysis bundle, graph context, and public tool plan for model synthesis.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n queryId: {\n type: \"string\",\n description:\n \"Graph Intelligence query ID, such as confirmation-bias, pre-mortem, or thesis-summary\",\n },\n prompt: {\n type: \"string\",\n description: \"Optional custom prompt for custom analysis runs\",\n },\n input: {\n type: \"string\",\n description:\n \"Optional entity, theme, belief, company, or search text for input-driven queries\",\n },\n mode: {\n type: \"string\",\n description:\n \"Optional mode override: core, bias, stress, operational, alpha, semantic, or evidence\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum graph context rows to return\",\n },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Graph Intelligence query result bundle ready for model or prompt-library synthesis\",\n fields: {\n query: \"object — selected query definition\",\n prompt: \"string — resolved prompt template\",\n toolPlan: \"array — public tools and args the model can call next\",\n analysis:\n \"object — structure, coverage, gap, and confirmation-bias analysis\",\n context: \"object — sampled beliefs, questions, evidence, edges, and contradictions\",\n },\n },\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_FALSIFICATION_QUESTIONS: McpToolContract = {\n name: \"get_falsification_questions\",\n description:\n \"Generate Popperian falsification questions for beliefs. \" +\n \"Like `git test` — identifies the questions most likely to disprove current beliefs. \" +\n \"Karl Popper as a tool: surfaces what would need to be true to invalidate each belief.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n beliefIds: { type: \"array\", description: \"Specific beliefs to target\" },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Questions with falsification potential scores and target beliefs\",\n fields: {\n questions:\n \"array — { questionText, falsificationPotential, targetBeliefId, targetBeliefText }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// EVIDENCE OPERATION TOOLS\n// =============================================================================\n\nexport const SEARCH_EVIDENCE: McpToolContract = {\n name: \"search_evidence\",\n description:\n \"Search for evidence across the reasoning graph. \" +\n \"Like `git grep` — returns the evidence records that best match a textual query. \" +\n \"Results share the same canonical semantics as the HTTP and SDK evidence search surface.\",\n parameters: {\n q: { type: \"string\", description: \"Search text\" },\n topicId: { type: \"string\", description: \"Topic scope filter\" },\n targetId: {\n type: \"string\",\n description: \"Optional belief or question identifier to scope the search\",\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [\"q\"],\n response: {\n description: \"Canonical evidence search results page\",\n fields: {\n results:\n \"array — { evidenceId, nodeId, globalId?, text, source?, kind?, relevanceScore }\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const CREATE_EVIDENCE: McpToolContract = {\n name: \"create_evidence\",\n description:\n \"Commit evidence to the reasoning graph. \" +\n \"Like `git commit` — creates a traceable evidence record with canonical public IDs. \" +\n \"Evidence creation must link to at least one belief and must include a signed impact score. \" +\n \"Positive scores support the belief; negative scores contradict it. SL confidence is derived from these weighted evidence relations.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n text: { type: \"string\", description: \"Canonical evidence text\" },\n source: { type: \"string\", description: \"Source URL or source label\" },\n targetId: {\n type: \"string\",\n description: \"Belief identifier to link immediately\",\n },\n weight: {\n type: \"number\",\n description:\n \"Required nonzero signed impact score: -1.0 (contradicts) to +1.0 (supports).\",\n },\n evidenceRelation: {\n type: \"string\",\n enum: [\"supports\", \"contradicts\"],\n description:\n \"Canonical relation to targetId/linkedBeliefNodeId. Prefer this over relying on signed weight inference.\",\n },\n confidence: {\n type: \"number\",\n description:\n \"Deprecated hint. Runtime confidence is derived from the signed impact score.\",\n },\n beliefRelations: {\n type: \"array\",\n description:\n \"Optional additional belief relations: [{ beliefId|beliefNodeId|targetId, evidenceRelation|relation, confidence?, weight?, rationale? }]. Use one evidence node with multiple relations when the same fact supports or contradicts several beliefs.\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional metadata merged into the canonical evidence node\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this evidence should enter the reasoning graph\",\n },\n title: { type: \"string\", description: \"Optional short title\" },\n content: { type: \"string\", description: \"Optional long-form content\" },\n contentType: {\n type: \"string\",\n description: \"Optional content format or MIME hint\",\n },\n kind: { type: \"string\", description: \"Optional evidence kind\" },\n },\n required: [\"text\", \"rationale\", \"weight\"],\n response: {\n description: \"The created canonical evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n text: \"string\",\n topicId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const GET_EVIDENCE: McpToolContract = {\n name: \"get_evidence\",\n description:\n \"Read one evidence record by ID. \" +\n \"Like `git show` — resolves the canonical evidence payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical evidence ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n text: \"string\",\n topicId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const LIST_EVIDENCE: McpToolContract = {\n name: \"list_evidence\",\n description:\n \"List evidence records within a topic or linked to a target. \" +\n \"Like `git log -- path` — returns the canonical evidence page for a topic, belief, or question scope.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope filter\" },\n targetId: {\n type: \"string\",\n description: \"Optional belief or question identifier to scope by linkage\",\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [],\n response: {\n description: \"Canonical evidence page\",\n fields: {\n evidence: \"array — canonical evidence records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_EVIDENCE: McpToolContract = {\n name: \"archive_evidence\",\n description:\n \"Archive an evidence record while preserving its reasoning history. \" +\n \"Like `git rm` — removes evidence from active workflows without erasing the audit trail. \" +\n \"Use this for evidence hygiene after the evidence has been superseded, corrected, or ruled out.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical evidence ID\" },\n evidenceId: { type: \"string\", description: \"Evidence ID alias\" },\n nodeId: { type: \"string\", description: \"Evidence node ID alias\" },\n insightId: { type: \"string\", description: \"Legacy insight ID alias\" },\n reason: {\n type: \"string\",\n description: \"Why this evidence is being archived\",\n },\n },\n required: [],\n response: {\n description: \"Archive confirmation for the evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence node ID\",\n status: \"string — archived or removed from active evidence views\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE: McpToolContract = {\n name: \"link_evidence\",\n description:\n \"Link evidence to a belief or question. \" +\n \"Like `git notes add` — attaches a supporting or contradicting edge without rewriting the evidence itself.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"Canonical evidence ID\" },\n targetId: {\n type: \"string\",\n description: \"Canonical belief or question ID\",\n },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n rationale: { type: \"string\", description: \"Why this link exists\" },\n },\n required: [\"evidenceId\", \"targetId\", \"weight\"],\n response: {\n description: \"The created canonical evidence edge summary\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n targetId: \"string\",\n targetType: \"string — belief | question\",\n weight: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE_TO_BELIEF: McpToolContract = {\n name: \"link_evidence_to_belief\",\n description:\n \"Link evidence to a belief with a support weight. \" +\n \"Like `git add` — stages evidence in support of (or against) a belief. \" +\n \"The weight ranges from -1.0 (strongly contradicts) to +1.0 (strongly supports). \" +\n \"This relation appends to the SL confidence ledger; do not hand-write confidence separately.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"The evidence node ID\" },\n beliefId: { type: \"string\", description: \"The belief node ID\" },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n evidenceRelation: {\n type: \"string\",\n enum: [\"supports\", \"contradicts\"],\n description:\n \"Canonical semantic relation. If omitted, the sign of weight is used.\",\n },\n confidence: {\n type: \"number\",\n description: \"Confidence in this evidence-to-belief relation, 0.0 to 1.0\",\n },\n rationale: { type: \"string\", description: \"Why this evidence is relevant\" },\n },\n required: [\"evidenceId\", \"beliefId\", \"weight\"],\n response: {\n description: \"The created edge linking evidence to belief\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n beliefId: \"string\",\n weight: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// QUESTION OPERATION TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CREATE_QUESTION: McpToolContract = {\n name: \"create_question\",\n description:\n \"Commit an investigation question to the reasoning graph. \" +\n \"Like `git issue` — creates a traceable question that drives research and evidence collection. \" +\n \"Questions test beliefs and guide worktree investigation.\",\n parameters: {\n text: { type: \"string\", description: \"The question text\" },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n priority: {\n type: \"string\",\n description: \"Priority: urgent, high, medium, low\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Belief this question tests\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional metadata merged into the question record\",\n },\n },\n required: [\"text\"],\n response: {\n description: \"The created canonical question record\",\n fields: {\n id: \"string — canonical question ID\",\n nodeId: \"string — canonical question ID\",\n questionId: \"string — canonical question ID\",\n text: \"string\",\n status: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const GET_QUESTION: McpToolContract = {\n name: \"get_question\",\n description:\n \"Read one question by ID. \" +\n \"Like `git show` — resolves the canonical question payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical question ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical question record\",\n fields: {\n id: \"string — canonical question ID\",\n nodeId: \"string — canonical question ID\",\n questionId: \"string — canonical question ID\",\n text: \"string\",\n status: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const REFINE_QUESTION: McpToolContract = {\n name: \"refine_question\",\n description:\n \"Refine a question's framing or scope. \" +\n \"Like `git commit --amend` for questions — updates the question text, scope, or worktree link \" +\n \"while preserving its identity and linked evidence.\",\n parameters: {\n id: { type: \"string\", description: \"The question to refine\" },\n text: { type: \"string\", description: \"Updated question text\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Worktree this existing question belongs to\",\n },\n rationale: {\n type: \"string\",\n description: \"Why the question is being refined\",\n },\n },\n required: [\"id\"],\n response: {\n description: \"The refined question\",\n fields: {\n id: \"string\",\n questionId: \"string\",\n updatedText: \"string\",\n previousText: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const LIST_QUESTIONS: McpToolContract = {\n name: \"list_questions\",\n description:\n \"List questions scoped to a topic or worktree. \" +\n \"Like `git issue list` — returns questions with their status, priority, and linked belief context. \" +\n \"Supports filtering by status and priority.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n worktreeId: { type: \"string\", description: \"Filter to worktree scope\" },\n status: {\n type: \"string\",\n description: \"Filter by canonical question status\",\n enum: [\"open\", \"researching\", \"answered\", \"parked\", \"closed\"],\n },\n priority: {\n type: \"string\",\n description: \"Filter by canonical question priority\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Canonical question page\",\n fields: {\n questions: \"array — canonical question records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const ANSWER_QUESTION: McpToolContract = {\n name: \"answer_question\",\n description:\n \"Answer a question with optional evidence links. \" +\n \"Like `git commit` on the question thread — records the answer and closes the loop with a canonical answered state.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical question ID\" },\n topicId: { type: \"string\", description: \"Topic scope for the answer\" },\n text: { type: \"string\", description: \"Answer text\" },\n confidence: {\n type: \"string\",\n description: \"Optional answer confidence\",\n enum: [\"weak\", \"medium\", \"strong\"],\n },\n evidenceIds: {\n type: \"array\",\n description: \"Optional canonical evidence IDs supporting the answer\",\n },\n rationale: { type: \"string\", description: \"Why this answer is credible\" },\n },\n required: [\"id\", \"topicId\", \"text\"],\n response: {\n description: \"Answer result\",\n fields: {\n questionId: \"string\",\n answerId: \"string\",\n status: \"string — answered\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_QUESTION_STATUS: McpToolContract = {\n name: \"update_question_status\",\n description:\n \"Transition a question's status through its lifecycle. \" +\n \"Like `git issue update` — moves a question through the canonical reasoning lifecycle. \" +\n \"Status transitions preserve history and keep linked evidence intact.\",\n parameters: {\n id: { type: \"string\", description: \"The question to update\" },\n status: {\n type: \"string\",\n description: \"New status\",\n enum: [\"open\", \"researching\", \"answered\", \"parked\", \"closed\"],\n },\n rationale: { type: \"string\", description: \"Why the status is changing\" },\n },\n required: [\"id\", \"status\"],\n response: {\n description: \"Updated question status\",\n fields: {\n id: \"string\",\n questionId: \"string\",\n previousStatus: \"string\",\n newStatus: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_QUESTION: McpToolContract = {\n name: \"archive_question\",\n description:\n \"Archive a question no longer relevant to current investigation scope. \" +\n \"Like `git issue close` — removes it from active work while preserving audit history. \" +\n \"Archived questions keep their existing links to beliefs and evidence.\",\n parameters: {\n questionId: { type: \"string\", description: \"The question to archive\" },\n reason: {\n type: \"string\",\n description: \"Why the question is being archived\",\n },\n },\n required: [\"questionId\"],\n response: {\n description: \"Archive confirmation\",\n fields: {\n questionId: \"string\",\n status: \"string — 'archived'\",\n archivedAt: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE_TO_QUESTION: McpToolContract = {\n name: \"link_evidence_to_question\",\n description:\n \"Link evidence to the question it helps answer. \" +\n \"Like `git notes add` — attaches supporting detail to an active question. \" +\n \"Question-level links improve answer quality and traceability to beliefs.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"The evidence to link\" },\n questionId: {\n type: \"string\",\n description: \"The question this evidence addresses\",\n },\n relevance: { type: \"number\", description: \"Relevance score in [0,1]\" },\n rationale: {\n type: \"string\",\n description: \"How this evidence bears on the question\",\n },\n },\n required: [\"evidenceId\", \"questionId\"],\n response: {\n description: \"The created edge\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n questionId: \"string\",\n relevance: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// ANSWER LIFECYCLE TOOLS\n// =============================================================================\n\nexport const CREATE_ANSWER: McpToolContract = {\n name: \"create_answer\",\n description:\n \"Create an answer node responding to a question. \" +\n \"Like `git commit` for resolved questions — creates an immutable answer snapshot at L2. \" +\n \"New answers supersede old ones, preserving full version history. \" +\n \"Answers link to supporting evidence via based_on edges.\",\n parameters: {\n questionNodeId: {\n type: \"string\",\n description: \"The question node ID this answers\",\n },\n answerText: {\n type: \"string\",\n description: \"The answer content — the actual response to the question\",\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope (optional if question already has topicId)\",\n },\n confidence: {\n type: \"string\",\n description:\n \"Answer confidence: definitive, strong, moderate, weak, speculative\",\n },\n evidenceNodeIds: {\n type: \"array\",\n description: \"Supporting evidence node IDs to link via based_on edges\",\n },\n answerSource: {\n type: \"string\",\n description:\n \"How the answer was produced: human, ai_generated, deep_research, synthesis\",\n },\n },\n required: [\"questionNodeId\", \"answerText\"],\n response: {\n description: \"The created answer node with version metadata\",\n fields: {\n nodeId: \"string — unique node identifier\",\n globalId: \"string — globally unique ID\",\n versionNumber: \"number — version of this answer (auto-incremented)\",\n questionNodeId: \"string — the question this answers\",\n confidence: \"string — answer confidence level\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\nexport const GET_ANSWER: McpToolContract = {\n name: \"get_answer\",\n description:\n \"Get the latest answer for a question. \" +\n \"Like `git show HEAD` for a question's resolution — returns the active answer snapshot. \" +\n \"Returns null if the question is unanswered.\",\n parameters: {\n questionNodeId: {\n type: \"string\",\n description: \"The question node ID to get the answer for\",\n },\n },\n required: [\"questionNodeId\"],\n response: {\n description: \"The active answer node or null\",\n fields: {\n nodeId: \"string | null\",\n globalId: \"string | null\",\n answerText: \"string | null\",\n versionNumber: \"number\",\n isLatest: \"boolean\",\n evidenceCount: \"number\",\n confidence: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const GET_HIGH_PRIORITY_QUESTIONS: McpToolContract = {\n name: \"get_high_priority_questions\",\n description:\n \"Rank open questions by urgency and expected decision impact. \" +\n \"Like `git issue list --sort=priority` — brings the highest-leverage open questions to the top. \" +\n \"Ranking accounts for linked belief criticality and evidence gaps.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n limit: { type: \"number\", description: \"Maximum results (default: 20)\" },\n includeAnswered: {\n type: \"boolean\",\n description: \"Include answered questions (default: false)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Priority-ranked questions\",\n fields: {\n questions:\n \"array — { questionId, text, priority, urgencyScore, linkedBeliefCount, evidenceGapCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const FIND_MISSING_QUESTIONS: McpToolContract = {\n name: \"find_missing_questions\",\n description:\n \"Identify beliefs missing testing questions. \" +\n \"Like `git diff --check` — surfaces reasoning coverage gaps before merge. \" +\n \"Returns candidate beliefs that need explicit question coverage.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n minConfidence: {\n type: \"number\",\n description: \"Only check beliefs above this confidence (default: 0)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Beliefs missing testing questions\",\n fields: {\n gaps: \"array — { beliefId, canonicalText, confidence, suggestedQuestions }\",\n totalGaps: \"number\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// LISTING & QUERY TOOLS\n// =============================================================================\n\nexport const LIST_BELIEFS: McpToolContract = {\n name: \"list_beliefs\",\n description:\n \"List beliefs scoped to a topic or worktree. \" +\n \"Like `git log --oneline` — returns beliefs with their confidence, status, and scoring state. \" +\n \"Supports filtering by status and confidence threshold.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n worktreeId: { type: \"string\", description: \"Filter to worktree scope\" },\n status: {\n type: \"string\",\n description: \"Filter: unscored, scored, archived\",\n enum: [\"unscored\", \"scored\", \"archived\"],\n },\n minConfidence: {\n type: \"number\",\n description: \"Minimum confidence threshold\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum results\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Canonical belief page\",\n fields: {\n beliefs: \"array — canonical belief records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const LIST_WORKTREES: McpToolContract = {\n name: \"list_worktrees\",\n description:\n \"List all worktrees for a topic. \" +\n \"Like `git worktree list` — shows active and completed investigation branches \" +\n \"with lifecycle phase, pipeline campaign/lane, status, and belief counts.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n status: {\n type: \"string\",\n description: \"Filter: active, merged, abandoned\",\n enum: [\"active\", \"merged\", \"abandoned\"],\n },\n groupBy: {\n type: \"string\",\n description: \"Optional grouping mode for the response.\",\n enum: [\"campaign\", \"lane\", \"flat\"],\n },\n lane: {\n type: \"string\",\n description: \"Filter by GitButler-aligned lane name.\",\n },\n campaign: {\n type: \"number\",\n description: \"Filter by top-level pipeline campaign number.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum results to return.\",\n },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Worktrees with lifecycle phase, campaign, lane, status, belief count, and creation time\",\n fields: {\n worktrees:\n \"array — { worktreeId, title, phase, campaign, lane, laneOrderInCampaign, orderInLane, status, beliefCount, createdAt }\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const LIST_ALL_WORKTREES: McpToolContract = {\n name: \"list_all_worktrees\",\n description:\n \"List ALL worktrees across ALL topics in one query. No topic scope required. \" +\n \"Like `git worktree list --all` — returns the complete pipeline inventory with \" +\n \"campaign, lane, lane order, dependencies, and status. \" +\n \"Supports filtering by status, lane, and campaign. \" +\n \"This is the PM's primary pipeline query — one call, full picture.\",\n parameters: {\n status: {\n type: \"string\",\n description:\n \"Filter by status: planning, active, completed, abandoned, superseded, long_term, idea, paused, suggested, dismissed\",\n enum: [\n \"planning\",\n \"active\",\n \"completed\",\n \"abandoned\",\n \"superseded\",\n \"long_term\",\n \"idea\",\n \"paused\",\n \"suggested\",\n \"dismissed\",\n ],\n },\n lane: {\n type: \"string\",\n description:\n \"Filter by lane name (e.g., 'ontology', 'tc-scope', 'control-plane', 'dev-portal', 'mcp-sdk-parity')\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Filter by campaign number (e.g., 1, 2, 3). Returns only worktrees in that campaign.\",\n },\n groupBy: {\n type: \"string\",\n description: \"Optional grouping mode for the response.\",\n enum: [\"campaign\", \"lane\", \"flat\"],\n },\n limit: {\n type: \"number\",\n description: \"Maximum results to return (default: 500, max: 1000)\",\n },\n },\n required: [],\n response: {\n description: \"All worktrees across all topics with full pipeline metadata\",\n fields: {\n worktrees:\n \"array — { worktreeId, title, topicId, topicName, phase, status, hypothesis, campaign, lane, laneOrderInCampaign, orderInLane, dependsOn, blocks, gate, createdAt }\",\n total: \"number — total count after filtering\",\n lanes: \"object — { laneName: count } summary of worktrees per lane\",\n campaigns:\n \"object — { campaignNumber: count } summary of worktrees per campaign\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const GET_WORKTREE: McpToolContract = {\n name: \"get_worktree\",\n description:\n \"Get one worktree by ID. \" +\n \"Like `git worktree list --porcelain <worktree>` — inspects one investigation branch without scanning the full pipeline inventory.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"Canonical worktree ID to retrieve\" },\n id: { type: \"string\", description: \"Legacy alias for worktreeId\" },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Single worktree record with pipeline metadata\",\n fields: {\n worktree:\n \"object — { worktreeId, title, topicId, status, hypothesis, campaign, lane, laneOrderInCampaign, orderInLane, dependsOn, blocks, gate }\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const LIST_CAMPAIGNS: McpToolContract = {\n name: \"list_campaigns\",\n description:\n \"List compact pipeline campaigns with their nested lanes. \" +\n \"Use this to see the top-level campaign > lane > worktree shape without pulling the full worktree inventory.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope.\",\n },\n status: {\n type: \"string\",\n description:\n \"Optional worktree status filter before grouping campaigns and lanes.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum worktrees to scan before grouping.\",\n },\n },\n required: [],\n response: {\n description: \"Pipeline campaigns with nested lane summaries.\",\n fields: {\n campaigns:\n \"array — { campaign, lanes: [{ lane, laneOrderInCampaign, worktreeCount, activeCount, readyCount, blockedCount, completedCount, nextWorktree }] }\",\n totalWorktrees: \"number — total worktrees scanned after filtering\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const ACTIVATE_WORKTREE: McpToolContract = {\n name: \"activate_worktree\",\n description:\n \"Activate a worktree to begin investigation. \" +\n \"Like `git checkout <branch>` — transitions a worktree from planning to active status. \" +\n \"Sets the initial phase and enables belief/question editing within the worktree scope.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to activate\" },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Activation result with initial phase\",\n fields: {\n worktreeId: \"string\",\n status: \"string — 'active'\",\n phase: \"string\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_WORKTREE_TARGETS: McpToolContract = {\n name: \"update_worktree_targets\",\n description:\n \"Update the target beliefs and questions tracked by a worktree. \" +\n \"Like `git add/rm <files>` — stages or unstages beliefs/questions for investigation \" +\n \"within the worktree scope. Supports adding and removing targets atomically.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to update\" },\n addBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs to add to the worktree\",\n },\n addQuestionIds: {\n type: \"array\",\n description: \"Question node IDs to add to the worktree\",\n },\n removeBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs to remove from the worktree\",\n },\n removeQuestionIds: {\n type: \"array\",\n description: \"Question node IDs to remove from the worktree\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Updated target counts\",\n fields: {\n worktreeId: \"string\",\n beliefCount: \"number\",\n questionCount: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_WORKTREE_METADATA: McpToolContract = {\n name: \"update_worktree_metadata\",\n description:\n \"Update worktree sequencing metadata — campaign, lane, dependencies, blocking relations, and gates. \" +\n \"Like `git config` for a worktree — sets the scheduling and dependency metadata that determines \" +\n \"when this worktree can activate relative to others. Use to backfill or correct sequencing data.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to update\" },\n hypothesis: {\n type: \"string\",\n description: \"Testable claim this worktree investigates\",\n },\n campaign: {\n type: \"number\",\n description: \"Top-level pipeline campaign number.\",\n },\n lane: {\n type: \"string\",\n description:\n \"GitButler-aligned workstream lane name inside the campaign.\",\n },\n laneOrderInCampaign: {\n type: \"number\",\n description: \"Ordering for this lane within the campaign.\",\n },\n orderInLane: {\n type: \"number\",\n description: \"Position of this worktree inside its lane.\",\n },\n dependsOn: {\n type: \"array\",\n description:\n \"Worktree IDs that must complete before this one can activate\",\n },\n blocks: {\n type: \"array\",\n description: \"Worktree IDs that are blocked until this one completes\",\n },\n gate: {\n type: \"string\",\n description: \"Exit gate name (e.g., 'gate:ontology-schema-hardened')\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this worktree is sequenced here\",\n },\n objective: {\n type: \"string\",\n description: \"What we're trying to learn/prove\",\n },\n proofArtifacts: {\n type: \"array\",\n description:\n \"Typed proof artifacts that define what evidence or deliverables this worktree must emit before it can claim success.\",\n },\n staffingHint: {\n type: \"string\",\n description:\n \"Advisory staffing shape for the worktree (for example `backend+tests` or `fullstack`).\",\n },\n lastReconciledAt: {\n type: \"number\",\n description:\n \"Timestamp of the last deterministic workflow reconciliation pass against this worktree.\",\n },\n autoFixPolicy: {\n type: \"object\",\n description:\n \"Calibrated auto-fix policy controlling dry-run vs safe execution, per-run action caps, and permitted mutation tiers.\",\n },\n status: {\n type: \"string\",\n description:\n \"Override the worktree status. Use for lifecycle transitions like marking a worktree superseded, long-term, or as a raw idea.\",\n enum: [\n \"suggested\",\n \"planning\",\n \"active\",\n \"paused\",\n \"completed\",\n \"dismissed\",\n \"abandoned\",\n \"superseded\",\n \"long_term\",\n \"idea\",\n ],\n },\n topicId: {\n type: \"string\",\n description:\n \"Reassign this worktree's primary topic. Validates the target topic exists before updating.\",\n },\n additionalTopicIds: {\n type: \"array\",\n description:\n \"Set additional topic associations for cross-topic worktrees. Each topic ID is validated before updating. \" +\n \"Use when a worktree spans multiple knowledge domains.\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Update confirmation\",\n fields: { worktreeId: \"string\", success: \"boolean\" },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const IDENTITY_WHOAMI: McpToolContract = {\n name: \"identity_whoami\",\n description:\n \"Read the authenticated identity summary for the current session. \" +\n \"Like `git config --get user.name` — shows who the current MCP session is acting as.\",\n parameters: {},\n required: [],\n response: {\n description: \"Canonical identity summary for the current session\",\n fields: {\n principalId:\n \"string — canonical principal identifier; for humans this is the Clerk user_... ID\",\n principalType: \"string — human, service, agent, group, or external_viewer\",\n tenantId: \"string | undefined — resolved tenant scope\",\n workspaceId: \"string | undefined — resolved workspace scope\",\n scopes: \"string[] | undefined — granted scopes for this session\",\n roles: \"string[] | undefined — canonical roles for this session\",\n },\n },\n ownerModule: \"identity-core\",\n ontologyPrimitive: \"identity\",\n tier: \"workhorse\",\n};\n\nexport const RESOLVE_INTERACTIVE_PRINCIPAL: McpToolContract = {\n name: \"resolve_interactive_principal\",\n description:\n \"Read the Permit-backed Lucern principal context for an authenticated Clerk user. \" +\n \"Like `git config --get user.email` plus the repository ACL — resolves the Clerk subject into tenant/workspace authorization context.\",\n parameters: {\n clerkId: {\n type: \"string\",\n description: \"Authenticated Clerk subject (`sub`). Clerk proves identity only; it is not the authorization record.\",\n },\n tenantId: {\n type: \"string\",\n description: \"Optional tenant scope. Omit only when the Clerk alias is globally unambiguous.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Optional workspace scope. Required when the principal has access to multiple workspaces and no default can be inferred.\",\n },\n providerProjectId: {\n type: \"string\",\n description: \"Optional Clerk project or provider instance id for tenants with multiple identity providers.\",\n },\n },\n required: [\"clerkId\"],\n response: {\n description: \"Permit-backed Lucern principal context for tenant SDK bootstrap\",\n fields: {\n principalId:\n \"string — canonical Clerk user_... ID for human sessions\",\n principalType: \"string — human, service, agent, group, or external_viewer\",\n clerkId: \"string — authenticated Clerk subject alias\",\n tenantId: \"string — resolved tenant scope\",\n workspaceId: \"string | null — resolved workspace scope\",\n roles: \"string[] — effective Permit roles\",\n scopes: \"string[] — effective scopes derived from Permit/control-plane projection\",\n groupIds: \"string[] — active Permit group memberships\",\n principalStatus: \"string — active, invited, suspended, disabled, revoked, or missing\",\n tenantStatus: \"string — projected tenant resource status\",\n workspaceStatus: \"string — projected workspace resource status\",\n permit: \"object — Permit subject, tenant, and optional workspace tuple\",\n },\n },\n ownerModule: \"control-plane\",\n ontologyPrimitive: \"identity\",\n tier: \"workhorse\",\n};\n\nexport const COMPILE_CONTEXT: McpToolContract = {\n name: \"compile_context\",\n description:\n \"Compile a focused reasoning context. If topicId is omitted, Lucern resolves the best topic from the query. \" +\n \"Like `git log --graph --decorate` for the reasoning substrate — returns the canonical Pillar 3 context pack through the public API shape.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope ID. Omit to resolve the topic from query.\",\n },\n query: {\n type: \"string\",\n description:\n \"Focus query used to resolve the topic and rank context items. Required when topicId is omitted.\",\n },\n topicHint: {\n type: \"string\",\n description:\n \"Optional natural-language topic hint used by the resolver when topicId is omitted or stale.\",\n },\n tags: {\n type: \"array\",\n description:\n \"Optional resolver tags. Useful for narrowing topic inference without knowing the exact topic id.\",\n },\n touchedPaths: {\n type: \"array\",\n description:\n \"Optional file or documentation paths used as resolver signals.\",\n },\n sourceRef: {\n type: \"string\",\n description:\n \"Optional source reference used as a resolver signal, such as a worktree id, PR, or feature slug.\",\n },\n sourceKind: {\n type: \"string\",\n description:\n \"Optional source kind used as a resolver signal, such as cli, worktree, commit, or docs.\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Optional campaign dimension seed. When supplied without topicId, the compiler fans out across all carrier topics for that campaign instead of resolving a single topic.\",\n },\n lane: {\n type: \"string\",\n description:\n \"Optional lane dimension seed. When supplied without topicId, the compiler reads all matching worktrees and their carrier topics.\",\n },\n status: {\n type: \"string\",\n description:\n \"Optional state/status dimension seed for worktrees and graph rows.\",\n },\n principalId: {\n type: \"string\",\n description:\n \"Optional principal seed for work authored, touched, or owned by a human, agent, group, or service principal.\",\n },\n workspaceId: {\n type: \"string\",\n description:\n \"Optional workspace seed used by hosted MCP and SDK clients when compiling tenant-scoped context.\",\n },\n budget: {\n type: \"number\",\n description: \"Token budget for prompt injection planning\",\n },\n tokenBudget: {\n type: \"number\",\n description:\n \"Compatibility alias for budget. External MCP clients may send tokenBudget when requesting prompt injection planning.\",\n },\n ranking: {\n type: \"string\",\n description: \"Ranking profile for context ordering\",\n enum: [\"baseline_v1\", \"weighted_v1\"],\n },\n limit: {\n type: \"number\",\n description: \"Optional per-section item limit\",\n },\n contentTopicLimit: {\n type: \"number\",\n description:\n \"Dimension-seeded compiles synthesize every matching worktree but bound raw belief/question/evidence enrichment to this many carrier topics (max 16) so hosted Convex queries remain fast. Receipts report any omitted raw topic enrichment.\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Optional descendant topic depth for neighborhood expansion\",\n },\n traversalMode: {\n type: \"string\",\n description:\n \"Optional C2-LK.2 traversal mode declaration for strict context compilation.\",\n enum: [\n \"anchored_ranked\",\n \"bounded_exploration\",\n \"contradiction_scan\",\n \"pattern_recall\",\n \"forensic_replay\",\n ],\n },\n requestedDepth: {\n type: \"string\",\n description:\n \"Optional C2-LK.2 constitutional depth declaration for context compilation.\",\n enum: [\"low\", \"medium\", \"high\", \"extra-high\"],\n },\n includeEntities: {\n type: \"boolean\",\n description: \"Include related ontological entities in the compiled result\",\n },\n },\n required: [],\n response: {\n description: \"Compiled context pack for the requested topic\",\n fields: {\n contextNarrative:\n \"array — first field; ordered synthesis blocks with kind/text, starting with executive_summary and canonical narrative blocks before raw objects\",\n narrativeCoverage:\n \"object — recordsSynthesized, recordsNamed, recordsOmitted, topicsSynthesized, topicsEnriched, topicContentOmitted, enrichmentMode, and blocksEmitted for the narrative\",\n synthesisLints:\n \"array — inline quality warnings for degenerate synthesis blocks or weak narrative coverage\",\n retrievalReceipt:\n \"object — candidateCounts, coverageWarning, narrativeCoverage, synthesisLints, and suggestedNextActions\",\n supportingObjects:\n \"object — raw graph records grouped behind the synthesis: invariants, activeBeliefs, openQuestions, recentEvidence, worktrees, lanes, entities, and contradictions\",\n schemaVersion: \"string\",\n topicId: \"string\",\n topicName: \"string\",\n scopedTopicIds: \"array — topic IDs included in the compilation neighborhood\",\n generatedAt:\n \"number — deterministic graph-backed reference timestamp for this compilation\",\n ranking: \"string — baseline_v1 | weighted_v1\",\n summary: \"object — counts and scoped health signals\",\n injectionPolicy: \"object — token-budgeted section selections\",\n diagnostics: \"object — scoring and utilization telemetry\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// POLICY / ACL TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CHECK_PERMISSION: McpToolContract = {\n name: \"check_permission\",\n description:\n \"Check whether a principal can read or mutate a topic scope. \" +\n \"Like `git check-ref-format` for ACLs — validates whether the requested operation is allowed before execution.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope to evaluate\" },\n permission: {\n type: \"string\",\n description: \"Permission to evaluate\",\n enum: [\"read\", \"write\"],\n },\n principal: {\n type: \"string\",\n description:\n \"Optional principal override (defaults to current principal)\",\n },\n beliefClusterId: {\n type: \"string\",\n description: \"Optional neighborhood scope within a topic\",\n },\n },\n required: [\"topicId\", \"permission\"],\n response: {\n description: \"Permission evaluation result\",\n fields: {\n allowed: \"boolean\",\n decision: \"string — allow | deny\",\n reasonCode: \"string\",\n principalId: \"string\",\n topicId: \"string\",\n permission: \"string — read | write\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\nexport const FILTER_BY_PERMISSION: McpToolContract = {\n name: \"filter_by_permission\",\n description:\n \"Filter a topic set down to ACL-authorized topics. \" +\n \"Like `git rev-list --ancestry-path` for policy boundaries — keeps only topics permitted for the requested action.\",\n parameters: {\n topicIds: { type: \"array\", description: \"Topic IDs to evaluate\" },\n permission: {\n type: \"string\",\n description: \"Permission filter\",\n enum: [\"read\", \"write\"],\n },\n principal: {\n type: \"string\",\n description: \"Optional principal override (tenant admin only)\",\n },\n },\n required: [\"topicIds\", \"permission\"],\n response: {\n description: \"Allowed/denied split for the requested topic set\",\n fields: {\n permission: \"string — read | write\",\n allowedTopicIds: \"array — topic IDs allowed by policy\",\n deniedTopics: \"array — { topicId, reasonCode }\",\n count: \"number\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\nexport const COMPILE_CAPABILITY_SLICE: McpToolContract = {\n name: \"compile_capability_slice\",\n description:\n \"Compile a Permit-clipped graph capability slice. \" +\n \"Like `git sparse-checkout` for policy-visible reasoning — returns allowed objects plus public-safe omission records.\",\n parameters: {\n sliceUuid: { type: \"string\", description: \"Stable slice UUID or request id\" },\n context: {\n type: \"string\",\n description:\n \"Slice context such as context_compile, graph_traversal, source_horizon, output_export, or agent_run\",\n },\n surface: {\n type: \"string\",\n description: \"Caller surface such as mcp, sdk, cli, rest, web, or agent\",\n },\n baseFacts: {\n type: \"object\",\n description: \"Graph policy facts for the root resource and principal\",\n },\n nodes: {\n type: \"array\",\n description: \"Candidate graph nodes/resources to clip\",\n },\n edges: {\n type: \"array\",\n description: \"Candidate graph edges to clip\",\n },\n fallbackPermitDecision: {\n type: \"object\",\n description: \"Fallback Permit decision; omitted decisions fail closed\",\n },\n permitDecisionsByResourceId: {\n type: \"object\",\n description: \"Permit decisions keyed by resourceId after PDP evaluation\",\n },\n },\n required: [\"baseFacts\", \"nodes\"],\n response: {\n description: \"Permission-clipped capability slice envelope\",\n fields: {\n decision: \"string — allow | allow_with_omissions | deny\",\n visibleNodes: \"array — policy-visible graph nodes/resources\",\n visibleEdges: \"array — policy-visible graph edges\",\n publicOmissionRecords: \"array — public-safe omission records\",\n sealedOmissionRecords: \"array — sealed audit-only omission records\",\n policy: \"object — Permit decision proof envelope\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// OBSERVATION TOOLS\n// =============================================================================\n\nexport const INGEST_OBSERVATION: McpToolContract = {\n name: \"ingest_observation\",\n description:\n \"Record an observational delta for a topic context stream. \" +\n \"Like `git notes add` — attaches structured observation metadata without mutating graph state directly. \" +\n \"Used by watcher/cowork agents to stage candidate updates before explicit write confirmation.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope hint for the observation\",\n },\n observationType: {\n type: \"string\",\n description: \"Observation class\",\n enum: [\n \"claim\",\n \"evidence\",\n \"question\",\n \"contradiction\",\n \"judgment\",\n \"note\",\n ],\n },\n summary: {\n type: \"string\",\n description: \"Human-readable observation summary\",\n },\n source: {\n type: \"string\",\n description: \"Optional source (message ID, tool name, URL, etc.)\",\n },\n confidence: { type: \"number\", description: \"Optional confidence in [0,1]\" },\n tags: { type: \"array\", description: \"Optional observation tags\" },\n metadata: {\n type: \"object\",\n description: \"Optional structured metadata payload\",\n },\n },\n required: [\"observationType\", \"summary\"],\n response: {\n description: \"Recorded observation entry\",\n fields: {\n observationId: \"string\",\n topicId: \"string\",\n observationType: \"string\",\n createdAt: \"number\",\n contextResourceUri: \"string\",\n },\n },\n ownerModule: \"agent-frameworks\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_OBSERVATION_CONTEXT: McpToolContract = {\n name: \"get_observation_context\",\n description:\n \"Retrieve observer-ready context for a topic, including recent deltas and semantic matches. \" +\n \"Like `git log --grep` — shows recent context and filtered matches across observation history. \" +\n \"This powers prompt context injection without mutating graph state.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n query: {\n type: \"string\",\n description: \"Optional semantic query over observation history\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum entries in each returned collection\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Observation context payload\",\n fields: {\n topicId: \"string\",\n totalObservations: \"number\",\n latest: \"array\",\n semanticMatches: \"array\",\n byType: \"object\",\n generatedAt: \"number\",\n },\n },\n ownerModule: \"agent-frameworks\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// TASK LIFECYCLE TOOLS\n// =============================================================================\n\nexport const CREATE_TASK: McpToolContract = {\n name: \"create_task\",\n description:\n \"Create an execution task tied to the reasoning state. \" +\n \"Like `git task` — tracks concrete work items (calls to make, data to gather, analyses to run) \" +\n \"linked to questions, beliefs, or worktrees.\",\n parameters: {\n title: { type: \"string\", description: \"Task title\" },\n topicId: { type: \"string\", description: \"Topic scope\" },\n description: {\n type: \"string\",\n description: \"Long-form task description\",\n },\n taskType: {\n type: \"string\",\n description: \"Task taxonomy\",\n enum: [\n \"general\",\n \"find_evidence\",\n \"verify_claim\",\n \"research\",\n \"review\",\n \"interview\",\n \"analysis\",\n \"track_metrics\",\n ],\n },\n priority: {\n type: \"string\",\n description: \"Priority\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n status: {\n type: \"string\",\n description: \"Initial status (defaults to todo)\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Worktree this task belongs to\",\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Belief this task supports\",\n },\n linkedQuestionId: {\n type: \"string\",\n description: \"Question this task addresses\",\n },\n assigneeId: {\n type: \"string\",\n description: \"Principal assigned to the task\",\n },\n dueDate: {\n type: \"number\",\n description: \"Due date as epoch milliseconds\",\n },\n tags: {\n type: \"array\",\n description: \"Free-form string tags\",\n },\n metadata: {\n type: \"object\",\n description: \"Structured task metadata for handoff context and routing hints\",\n },\n },\n required: [\"title\"],\n response: {\n description: \"The created task\",\n fields: {\n taskId: \"string\",\n status: \"string — 'pending'\",\n createdAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const COMPLETE_TASK: McpToolContract = {\n name: \"complete_task\",\n description:\n \"Mark a task as complete with an output summary. \" +\n \"Like `git tag` for work items — records the discrete completion event and captures what was learned. \" +\n \"Completed tasks feed back into the evidence graph.\",\n parameters: {\n taskId: { type: \"string\", description: \"The task to complete\" },\n outputSummary: {\n type: \"string\",\n description: \"What was accomplished or learned\",\n },\n evidenceCreated: {\n type: \"boolean\",\n description: \"Whether new evidence was created from this task\",\n },\n },\n required: [\"taskId\", \"outputSummary\"],\n response: {\n description: \"The completed task\",\n fields: {\n taskId: \"string\",\n completedAt: \"number\",\n outputSummary: \"string\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_TASK: McpToolContract = {\n name: \"update_task\",\n description:\n \"Update a task's fields — relink to a different worktree, belief, or question, change title/priority/status. \" +\n \"Like `git task edit` — mutates an existing task in place instead of requiring recreate-plus-supersede.\",\n parameters: {\n taskId: { type: \"string\", description: \"The task to update\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Reassign this task to a different worktree\",\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Link or relink this task to a belief node\",\n },\n linkedQuestionId: {\n type: \"string\",\n description: \"Link or relink this task to a question node\",\n },\n title: { type: \"string\", description: \"Updated task title\" },\n description: {\n type: \"string\",\n description: \"Updated task description\",\n },\n priority: {\n type: \"string\",\n description: \"Updated priority\",\n enum: [\"critical\", \"high\", \"medium\", \"low\"],\n },\n status: {\n type: \"string\",\n description: \"Updated status\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n metadata: {\n type: \"object\",\n description: \"Structured task metadata to replace or refine\",\n },\n },\n required: [\"taskId\"],\n response: {\n description: \"The updated task\",\n fields: {\n taskId: \"string\",\n updatedAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const LIST_TASKS: McpToolContract = {\n name: \"list_tasks\",\n description:\n \"List tasks for a topic or worktree. \" +\n \"Like `git task list` — returns tasks with status, priority, and linked nodes. \" +\n \"Filter by worktree to see tasks for a specific investigation, or by status to find incomplete work.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Filter to tasks linked to this worktree\",\n },\n worktreeId: {\n type: \"string\",\n description: \"Alias for linkedWorktreeId\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status: todo, in_progress, blocked, done\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n limit: { type: \"number\", description: \"Maximum results (default: 100)\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"List of tasks with metadata\",\n fields: { tasks: \"array of task objects\", count: \"number\" },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// TOPIC TOOLS (git init, git remote)\n// =============================================================================\n\nexport const CREATE_TOPIC: McpToolContract = {\n name: \"create_topic\",\n description:\n \"Create a new topic container for scoping knowledge. \" +\n \"Like `git init` — initializes a new repository for a knowledge domain. \" +\n \"Topics are hierarchical: a deal topic can nest under a theme topic. \" +\n \"Types: domain, theme, deal, strategy, constitution, project, portfolio.\",\n parameters: {\n globalId: {\n type: \"string\",\n description: \"Optional idempotent topic global ID\",\n },\n name: { type: \"string\", description: \"Topic name\" },\n type: {\n type: \"string\",\n description:\n \"Topic type. Validated against schemaEnumConfig category 'topic_type'.\",\n },\n description: { type: \"string\", description: \"What this topic covers\" },\n parentTopicId: {\n type: \"string\",\n description: \"Optional parent topic for nesting\",\n },\n parentTopicGlobalId: {\n type: \"string\",\n description: \"Optional parent topic global ID for nesting\",\n },\n tenantId: { type: \"string\", description: \"Optional tenant scope\" },\n workspaceId: { type: \"string\", description: \"Optional workspace scope\" },\n visibility: {\n type: \"string\",\n description: \"Topic visibility\",\n enum: [\"private\", \"team\", \"firm\", \"external\", \"public\"],\n },\n metadata: { type: \"object\", description: \"Optional topic metadata\" },\n createdBy: { type: \"string\", description: \"Who created this topic\" },\n },\n required: [\"name\", \"type\"],\n response: {\n description: \"The created topic\",\n fields: {\n id: \"string — topic ID\",\n globalId: \"string — globally unique ID\",\n topicGlobalId: \"string — topic global ID\",\n epistemicNodeId: \"string — materialized topic node ID\",\n epistemicNodeGlobalId: \"string — materialized topic node global ID\",\n depth: \"number — nesting depth\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const LIST_TOPICS: McpToolContract = {\n name: \"list_topics\",\n description:\n \"List topics, optionally filtered by type or parent. \" +\n \"Like `git remote -v` — shows all knowledge containers with their types and hierarchy.\",\n parameters: {\n type: {\n type: \"string\",\n description: \"Filter by topic type (e.g., 'theme', 'deal')\",\n },\n parentTopicId: {\n type: \"string\",\n description: \"Filter to children of this parent\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\"active\", \"archived\", \"watching\"],\n },\n },\n required: [],\n response: {\n description: \"List of topics with metadata\",\n fields: {\n topics: \"array — { id, name, type, depth, status, parentTopicId }\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC: McpToolContract = {\n name: \"get_topic\",\n description:\n \"Get one topic by ID. \" +\n \"Like `git remote show origin` — inspects a single knowledge container in detail.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Canonical topic ID to retrieve\",\n },\n id: {\n type: \"string\",\n description: \"Legacy alias for topicId\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Single topic record\",\n fields: {\n topic:\n \"object — { id, globalId, name, type, depth, status, parentTopicId, description }\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_TOPIC: McpToolContract = {\n name: \"update_topic\",\n description:\n \"Update an existing topic's metadata. \" +\n \"Like `git remote set-url` — changes the canonical configuration for a knowledge container without recreating it.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Canonical topic ID to update\",\n },\n id: {\n type: \"string\",\n description: \"Legacy alias for topicId\",\n },\n name: { type: \"string\", description: \"Updated topic name\" },\n description: { type: \"string\", description: \"Updated topic description\" },\n type: {\n type: \"string\",\n description:\n \"Updated topic type. Validated against schemaEnumConfig category 'topic_type'.\",\n },\n ontologyId: {\n type: \"string\",\n description: \"Updated ontology binding\",\n },\n clearOntologyId: {\n type: \"boolean\",\n description: \"Clear the current ontology binding\",\n },\n status: {\n type: \"string\",\n description: \"Updated topic status\",\n enum: [\"active\", \"archived\", \"watching\"],\n },\n visibility: {\n type: \"string\",\n description: \"Updated topic visibility\",\n enum: [\"private\", \"team\", \"firm\", \"external\", \"public\"],\n },\n },\n required: [],\n response: {\n description: \"The updated topic\",\n fields: {\n id: \"string — topic ID\",\n globalId: \"string — globally unique ID\",\n status: \"string — topic lifecycle status\",\n visibility: \"string — topic visibility\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC_TREE: McpToolContract = {\n name: \"get_topic_tree\",\n description:\n \"Get the full topic hierarchy from a root. \" +\n \"Like `git log --graph --all` — shows the complete tree of nested topics.\",\n parameters: {\n rootId: { type: \"string\", description: \"Root topic to start from\" },\n maxDepth: {\n type: \"number\",\n description: \"Maximum depth to traverse (default: 5)\",\n },\n },\n required: [\"rootId\"],\n response: {\n description: \"Tree of topics with nesting\",\n fields: { tree: \"array — topics in BFS order with depth and path\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const MATERIALIZE_TOPIC_GRAPH: McpToolContract = {\n name: \"materialize_topic_graph\",\n description:\n \"Backfill the topic graph spine. \" +\n \"Like `git fsck --connectivity-only` with repair enabled — creates missing topic nodes and parent-child edges idempotently.\",\n parameters: {\n rootTopicId: {\n type: \"string\",\n description: \"Optional root topic for a bounded materialization pass\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"When true, report missing rows without writing them\",\n },\n },\n required: [],\n response: {\n description: \"Topic graph materialization counts\",\n fields: {\n topicsSeen: \"number\",\n nodesCreated: \"number\",\n nodesExisting: \"number\",\n edgesCreated: \"number\",\n edgesExisting: \"number\",\n errors: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC_GRAPH_SPINE: McpToolContract = {\n name: \"get_topic_graph_spine\",\n description:\n \"Verify the topic graph spine. \" +\n \"Like `git fsck` — reads topics, materialized topic nodes, parent-child edges, and missing spine rows.\",\n parameters: {\n rootTopicId: {\n type: \"string\",\n description: \"Optional root topic for a bounded verifier pass\",\n },\n includeTopicBeliefEdges: {\n type: \"boolean\",\n description: \"Include topic -> belief edges in the verifier payload\",\n },\n },\n required: [],\n response: {\n description: \"Topic graph spine verification payload\",\n fields: {\n ok: \"boolean\",\n counts: \"object\",\n topics: \"array\",\n topicNodes: \"array\",\n parentEdges: \"array\",\n missingTopicNodes: \"array\",\n missingParentEdges: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// CODING INTELLIGENCE TOOLS (code-grounded knowledge)\n// =============================================================================\n\nexport const GET_CODE_CONTEXT: McpToolContract = {\n name: \"get_code_context\",\n description:\n \"Returns code-grounded beliefs, contracts, migration states, and failed attempts anchored to a specific file or function path. \" +\n \"Like `git log -- <path>` — filters the knowledge graph to nodes anchored to a file path via metadata.codeAnchors. \" +\n \"Results are separated by coding belief type: decisions, contracts, migrations, patterns, deprecations, and failures.\",\n parameters: {\n filePath: {\n type: \"string\",\n description:\n \"File path to search for (partial matches supported, e.g. 'epistemicBeliefs.ts' or 'convex/epistemicBeliefs.ts')\",\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope (optional, uses default if not provided)\",\n },\n includeFailures: {\n type: \"boolean\",\n description: \"Whether to include failed attempt evidence (default: true)\",\n },\n },\n required: [\"filePath\"],\n response: {\n description: \"Code-anchored beliefs and evidence grouped by type\",\n fields: {\n filePath: \"string — queried path\",\n decisions: \"array — implementation_decision beliefs\",\n contracts: \"array — interface_contract beliefs\",\n migrations: \"array — migration_state beliefs\",\n patterns: \"array — code_pattern beliefs\",\n deprecations: \"array — deprecation_notice beliefs\",\n failures: \"array — failed attempt evidence\",\n totalMatched: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const GET_CHANGE_HISTORY: McpToolContract = {\n name: \"get_change_history\",\n description:\n \"Returns recent changes and decisions for a file path — the 'why' behind recent code changes. \" +\n \"Like `git log --follow <path>` — shows the evolution of understanding anchored to a specific file. \" +\n \"Searches beliefs and evidence updated recently, sorted by most recent first.\",\n parameters: {\n filePath: { type: \"string\", description: \"File path to get history for\" },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n limit: { type: \"number\", description: \"Max results (default: 10)\" },\n },\n required: [\"filePath\"],\n response: {\n description: \"Recent code-anchored changes sorted by recency\",\n fields: {\n filePath: \"string — queried path\",\n changes:\n \"array — nodes with coding view (nodeId, beliefType, canonicalText, codeAnchors, timestamps)\",\n totalFound: \"number\",\n showing: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const RECORD_ATTEMPT: McpToolContract = {\n name: \"record_attempt\",\n description:\n \"Log a failed approach as evidence linked to a belief. \" +\n \"Like `git stash` for failed experiments — preserves what was tried so the same mistake isn't repeated. \" +\n \"Creates evidence with metadata.failedApproach=true and metadata.codeAnchors. \" +\n \"The key anti-repetition mechanism: future agents check the failure log before trying new approaches.\",\n parameters: {\n description: {\n type: \"string\",\n description: \"What was attempted and why it failed\",\n },\n filePaths: {\n type: \"array\",\n description: \"File paths involved in the attempt\",\n },\n errorMessage: {\n type: \"string\",\n description: \"Error message or failure reason\",\n },\n linkedBeliefId: {\n type: \"string\",\n description:\n \"Belief this attempt was targeting (creates -0.5 weight edge)\",\n },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n },\n required: [\"description\"],\n response: {\n description: \"The recorded failed attempt evidence node\",\n fields: {\n nodeId: \"string — evidence node ID\",\n edgeId: \"string | null — edge to linked belief\",\n recorded: \"boolean — true\",\n filePaths: \"array — anchored file paths\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\nexport const GET_FAILURE_LOG: McpToolContract = {\n name: \"get_failure_log\",\n description:\n \"Search past failed attempts matching a task description. \" +\n \"Like `git log --grep='FAILED'` — finds evidence of what was tried before and didn't work. \" +\n \"Before trying a new approach, check this log to avoid repeating the same mistake. \" +\n \"Filters to evidence with metadata.failedApproach=true, sorted by recency.\",\n parameters: {\n query: {\n type: \"string\",\n description: \"Description of the task or approach to search for\",\n },\n filePath: {\n type: \"string\",\n description: \"Optional file path to narrow results\",\n },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n limit: { type: \"number\", description: \"Max results (default: 5)\" },\n },\n required: [\"query\"],\n response: {\n description: \"Failed attempts matching the query\",\n fields: {\n query: \"string — search query\",\n failures: \"array — failed attempt evidence with coding view\",\n totalFound: \"number\",\n showing: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// GRAPH SELF-INTELLIGENCE TOOLS\n// =============================================================================\n\nexport const GET_TOPIC_COVERAGE: McpToolContract = {\n name: \"get_topic_coverage\",\n description:\n \"Returns per-topic belief/question/evidence counts across the topic tree. \" +\n \"Like `git diff --stat` for the knowledge graph — shows coverage density \" +\n \"and empty spots across the topic hierarchy. Use to identify which topics \" +\n \"need more beliefs, which lack questions, and overall graph health.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID (optional, uses default if not provided)\",\n },\n includeDescendants: {\n type: \"boolean\",\n description:\n \"Whether to include descendant topics in the coverage report (default: true)\",\n },\n maxDepth: {\n type: \"number\",\n description:\n \"Maximum descendant topic depth for neighborhood expansion. \" +\n \"Defaults to 4 for root/theme scopes, 2 for deeper scopes.\",\n },\n },\n required: [],\n response: {\n description: \"Per-topic coverage metrics and aggregate summary\",\n fields: {\n topics:\n \"array — per-topic { topicId, name, type, depth, beliefs, questions, evidence, coverage }\",\n summary:\n \"object — { totalTopics, coveredTopics, emptyTopics, coveragePercent, totalBeliefs, totalQuestions, totalEvidence }\",\n scopeTopicId: \"string — the root topic used for scoping\",\n },\n },\n ownerModule: \"coverage-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_GRAPH_GAPS: McpToolContract = {\n name: \"get_graph_gaps\",\n description:\n \"Identify structural gaps in the knowledge graph — empty topics, beliefs \" +\n \"without questions, beliefs without evidence, and orphan edges. \" +\n \"Like `git fsck` for reasoning coverage — surfaces holes that weaken \" +\n \"the epistemic foundation. Returns prioritized gap list.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID (optional, uses default if not provided)\",\n },\n maxDepth: {\n type: \"number\",\n description:\n \"Maximum descendant topic depth for neighborhood expansion (default: 4)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Prioritized list of graph gaps by category\",\n fields: {\n emptyTopics:\n \"array — topics with zero beliefs { topicId, name, type, depth }\",\n beliefsWithoutQuestions:\n \"array — beliefs that have no testing questions { nodeId, canonicalText, topicId }\",\n beliefsWithoutEvidence:\n \"array — beliefs that have no supporting evidence { nodeId, canonicalText, topicId }\",\n summary:\n \"object — { totalGaps, emptyTopicCount, untestedBeliefCount, unsupportedBeliefCount }\",\n scopeTopicId: \"string — the root topic used for scoping\",\n },\n },\n ownerModule: \"coverage-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// SESSION INITIALIZATION\n// =============================================================================\n\n// =============================================================================\n// WRITE POLICY (S2-13K Graph Compounding)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const MANAGE_WRITE_POLICY: McpToolContract = {\n name: \"manage_write_policy\",\n description:\n \"Manage write policies for MCP mutation tools. \" +\n \"Like `git config` for write permissions — sets per-topic or global \" +\n \"policies that control which roles can mutate the graph.\",\n parameters: {\n action: {\n type: \"string\",\n description:\n \"Action to perform: 'get' (read policies) or 'set' (upsert a policy)\",\n enum: [\"get\", \"set\"],\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope for the policy. Omit for global policies.\",\n },\n role: {\n type: \"string\",\n description:\n \"Role to set policy for (required for 'set'). E.g. 'agent:internal' or a Permit role key such as 'workspace_admin'.\",\n },\n permission: {\n type: \"string\",\n description: \"Permission level (required for 'set').\",\n enum: [\"allow\", \"deny\", \"read_only\"],\n },\n maxWritesPerSession: {\n type: \"number\",\n description: \"Optional per-session write limit for this role+scope.\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this policy is being set (audit trail).\",\n },\n },\n required: [\"action\"],\n response: {\n description: \"Policy operation result\",\n fields: {\n action: \"string — get | set\",\n topicId: \"string|null — topic scope or null for global\",\n policies: \"array — (for get) list of matching policies\",\n role: \"string — (for set) role that was updated\",\n permission: \"string — (for set) new permission level\",\n maxWritesPerSession: \"number|null — (for set) session write cap\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// ONTOLOGY TOOLS (ontology lifecycle, version management)\n// =============================================================================\n\nexport const LIST_ONTOLOGIES: McpToolContract = {\n name: \"list_ontologies\",\n description:\n \"List ontology definitions with optional filters. \" +\n \"Like `git remote -v` for ontologies — shows all registered ontology definitions \" +\n \"with their tier, status, and tenant scope.\",\n parameters: {\n tenantId: {\n type: \"string\",\n description: \"Filter by tenant ID. Omit for platform-level ontologies.\",\n },\n tier: {\n type: \"string\",\n description: \"Filter by tier\",\n enum: [\"platform\", \"pack\", \"tenant\"],\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\"draft\", \"active\", \"deprecated\", \"archived\"],\n },\n },\n required: [],\n response: {\n description: \"Array of ontology definitions\",\n fields: {\n ontologies:\n \"array — ontology definitions with id, ontologyKey, name, tier, status\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const GET_ONTOLOGY: McpToolContract = {\n name: \"get_ontology\",\n description:\n \"Get a single ontology definition by ID or ontologyKey. \" +\n \"Like `git show` for an ontology — returns the definition metadata plus the latest \" +\n \"published version with entity types and edge types.\",\n parameters: {\n id: {\n type: \"string\",\n description: \"Ontology definition ID (Convex document ID)\",\n },\n ontologyKey: {\n type: \"string\",\n description:\n \"Ontology key (e.g., 'investment-ontology'). Alternative to id.\",\n },\n tenantId: {\n type: \"string\",\n description: \"Tenant scope for key lookup. Omit for platform-level.\",\n },\n },\n required: [\"id\"],\n response: {\n description: \"Ontology definition with latest published version\",\n fields: {\n id: \"string — definition ID\",\n ontologyKey: \"string — unique key\",\n name: \"string — display name\",\n publishedVersion:\n \"object|null — latest published version with entityTypes and edgeTypes\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const APPLY_ONTOLOGY: McpToolContract = {\n name: \"apply_ontology\",\n description:\n \"Bind an ontology definition directly to a topic. \" +\n \"Like `git checkout` for a domain vocabulary — applies an ontology to a topic so the topic \" +\n \"and its descendants inherit the configured entity and edge schema.\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Canonical ontology identifier to bind\",\n },\n topicId: {\n type: \"string\",\n description: \"Canonical topic identifier to receive the binding\",\n },\n },\n required: [\"ontologyId\", \"topicId\"],\n response: {\n description: \"Ontology binding summary\",\n fields: {\n applied: \"boolean — true when the binding was written\",\n source: \"string — always 'direct' for an explicit bind\",\n ontologyId: \"string — canonical ontology ID\",\n ontologyKey: \"string — ontology key\",\n topicId: \"string — canonical topic ID\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const MATCH_ENTITY_TYPE: McpToolContract = {\n name: \"match_entity_type\",\n description:\n \"Classify free text against the effective ontology vocabulary. \" +\n \"Like `git grep` for ontology types — ranks the most likely entity types for the supplied text \" +\n \"using the topic-bound or explicitly selected ontology.\",\n parameters: {\n text: {\n type: \"string\",\n description: \"Free text to classify against ontology entity types\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Canonical topic ID used to resolve the effective ontology when ontologyId is omitted\",\n },\n ontologyId: {\n type: \"string\",\n description:\n \"Optional ontology definition ID to match against instead of the topic-bound ontology\",\n },\n minScore: {\n type: \"number\",\n description: \"Optional lower similarity bound for returned matches\",\n },\n limit: {\n type: \"number\",\n description: \"Optional maximum number of ranked matches to return\",\n },\n },\n required: [\"text\", \"ontologyId\"],\n response: {\n description: \"Ranked ontology entity type matches\",\n fields: {\n matches:\n \"array — ranked entity type matches with score, entityType, label, and optional description\",\n ontologyId: \"string|null — ontology used for matching\",\n topicId: \"string|null — topic scope used for ontology resolution\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const CREATE_ONTOLOGY: McpToolContract = {\n name: \"create_ontology\",\n description:\n \"Create a new ontology definition. \" +\n \"Like `git init` for a domain vocabulary — creates a named, versioned container for \" +\n \"entity types and edge types. Starts in 'draft' status.\",\n parameters: {\n ontologyKey: {\n type: \"string\",\n description:\n \"Unique key (lowercase, hyphens, e.g., 'investment-ontology')\",\n },\n name: { type: \"string\", description: \"Human-readable name\" },\n description: { type: \"string\", description: \"What this ontology covers\" },\n tenantId: {\n type: \"string\",\n description: \"Tenant scope. Omit for platform-level.\",\n },\n tier: {\n type: \"string\",\n description: \"Ontology tier\",\n enum: [\"platform\", \"pack\", \"tenant\"],\n },\n parentOntologyId: {\n type: \"string\",\n description: \"Parent ontology ID for layered composition\",\n },\n },\n required: [\"ontologyKey\", \"name\", \"tier\"],\n response: {\n description: \"Created ontology definition\",\n fields: {\n id: \"string — new definition ID\",\n ontologyKey: \"string — normalized key\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const UPDATE_ONTOLOGY: McpToolContract = {\n name: \"update_ontology\",\n description:\n \"Update an ontology definition's metadata (name, description, status). \" +\n \"Like `git config` for an ontology — updates mutable fields on the definition. \" +\n \"Only allowed while the ontology is in draft or active status.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology definition ID\" },\n name: { type: \"string\", description: \"New display name\" },\n description: { type: \"string\", description: \"New description\" },\n status: {\n type: \"string\",\n description: \"New status\",\n enum: [\"draft\", \"active\", \"deprecated\"],\n },\n },\n required: [\"id\"],\n response: {\n description: \"Update confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_ONTOLOGY: McpToolContract = {\n name: \"archive_ontology\",\n description:\n \"Archive an ontology definition. \" +\n \"Like `git rm` for an ontology — soft-deletes the definition. \" +\n \"Archived ontologies are preserved in history but no longer active.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology definition ID to archive\" },\n },\n required: [\"id\"],\n response: {\n description: \"Archive confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const CREATE_ONTOLOGY_VERSION: McpToolContract = {\n name: \"create_ontology_version\",\n description:\n \"Create a new version snapshot for an ontology definition. \" +\n \"Like `git commit` for ontology content — captures entity types and edge types \" +\n \"in a versioned snapshot. Starts in 'draft' status. Publish to freeze.\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Parent ontology definition ID\",\n },\n version: {\n type: \"string\",\n description: \"Semantic version string (X.Y.Z format)\",\n },\n entityTypes: {\n type: \"array\",\n description:\n \"Array of entity type definitions: [{ value, label, description?, schema?, subtypes? }]\",\n },\n edgeTypes: {\n type: \"array\",\n description:\n \"Array of edge type definitions: [{ value, label, description?, sourceTypes?, targetTypes?, constraintSeverity? }]\",\n },\n releaseNotes: {\n type: \"string\",\n description: \"Optional release notes for this version\",\n },\n },\n required: [\"ontologyId\", \"version\", \"entityTypes\", \"edgeTypes\"],\n response: {\n description: \"Created version\",\n fields: {\n id: \"string — new version ID\",\n version: \"string — version string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const PUBLISH_ONTOLOGY_VERSION: McpToolContract = {\n name: \"publish_ontology_version\",\n description:\n \"Publish a draft ontology version — freezes it permanently. \" +\n \"Like `git tag` for an ontology release — the version becomes immutable after publish. \" +\n \"If the parent definition is still in 'draft', promotes it to 'active'.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology version ID to publish\" },\n },\n required: [\"id\"],\n response: {\n description: \"Publish confirmation\",\n fields: {\n success: \"boolean\",\n publishedAt: \"number — timestamp\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const DEPRECATE_ONTOLOGY_VERSION: McpToolContract = {\n name: \"deprecate_ontology_version\",\n description:\n \"Deprecate a published ontology version. \" +\n \"Like `git tag -d` for an ontology release — marks the version as deprecated. \" +\n \"Only published versions can be deprecated.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology version ID to deprecate\" },\n },\n required: [\"id\"],\n response: {\n description: \"Deprecation confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const RESOLVE_EFFECTIVE_ONTOLOGY: McpToolContract = {\n name: \"resolve_effective_ontology\",\n description:\n \"Resolve the effective ontology by composing the parent chain. \" +\n \"Like `git merge --squash` for ontology layers — walks parentOntologyId chain \" +\n \"(max depth 3) and merges entity/edge types additively from root (platform) to leaf (tenant).\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Ontology definition ID to resolve from\",\n },\n },\n required: [\"ontologyId\"],\n response: {\n description: \"Merged ontology with composed entity and edge types\",\n fields: {\n entityTypes: \"array — merged entity types from all layers\",\n edgeTypes: \"array — merged edge types from all layers\",\n layers: \"array — ontology keys in composition order\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// FUNCTION SURFACE WORKFLOW TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const RECORD_SCOPE_LEARNING: McpToolContract = {\n name: \"record_scope_learning\",\n description:\n \"Write a structured learning entry into the epistemic spine. \" +\n \"Like `git commit` for scope learnings — records evidence, can attach to a belief, and can open a follow-up belief/question in one atomic workflow.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope ID\" },\n summary: { type: \"string\", description: \"Atomic learning statement\" },\n title: {\n type: \"string\",\n description: \"Optional evidence title, such as a commit, doc, or issue.\",\n },\n body: {\n type: \"string\",\n description:\n \"Optional rich evidence body. If omitted, body is synthesized from summary and touched paths.\",\n },\n contentType: {\n type: \"string\",\n description: \"Optional evidence body format, such as markdown or text.\",\n },\n sourceKind: {\n type: \"string\",\n description: \"Source type for the learning event\",\n enum: [\"commit\", \"merge\", \"doc\", \"issue\", \"manual\"],\n },\n sourceRef: {\n type: \"string\",\n description: \"Optional source reference, such as SHA, PR number, or URL slug.\",\n },\n sourceUrl: { type: \"string\", description: \"Optional canonical source URL\" },\n touchedPaths: {\n type: \"array\",\n description: \"Optional touched file paths for retrieval hints\",\n },\n tags: { type: \"array\", description: \"Optional tags\" },\n linkedBeliefNodeId: {\n type: \"string\",\n description: \"Optional belief to attach evidence to\",\n },\n evidenceRelation: {\n type: \"string\",\n description: \"Relation to linked belief\",\n enum: [\"supports\", \"contradicts\"],\n },\n confidence: { type: \"number\", description: \"Optional confidence in [0,1]\" },\n createQuestionText: {\n type: \"string\",\n description: \"Optional follow-up question text\",\n },\n createBeliefText: {\n type: \"string\",\n description: \"Optional new belief text\",\n },\n beliefType: {\n type: \"string\",\n description: \"Optional belief type for createBeliefText\",\n },\n },\n required: [\"summary\"],\n response: {\n description: \"Created learning artifacts\",\n fields: {\n topicId: \"string — resolved topic ID\",\n evidenceNodeId: \"string\",\n linkedBeliefNodeId: \"string | null\",\n createdQuestionId: \"string | null\",\n createdBeliefId: \"string | null\",\n sourceUrl: \"string\",\n createdAt: \"number\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const PIPELINE_SNAPSHOT: McpToolContract = {\n name: \"pipeline_snapshot\",\n description:\n \"Summarize a topic's worktree pipeline in campaign-and-lane form. \" +\n \"Like `git status --short` for Lucern execution — returns the hinge worktree, next planned wave, blockers, critical path, superseded work, and graph hygiene debt.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope ID\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Human-oriented pipeline summary for a single topic scope\",\n fields: {\n topicId: \"string\",\n topicName: \"string\",\n currentCampaign: \"number | null\",\n nextCampaign: \"number | null\",\n activeWorktrees: \"array — current hinge worktree(s)\",\n nextWave: \"array — worktrees in the next planned campaign\",\n readyNow: \"array — planning worktrees with dependencies completed\",\n blockedBy: \"array — grouped blockers\",\n criticalPath: \"array — ordered incomplete worktree chain\",\n campaigns: \"array — incomplete worktrees grouped by campaign\",\n superseded: \"array — worktrees marked superseded or not for activation\",\n graphHygiene: \"object — untargeted and taskless worktree debt\",\n riskQuestions: \"array — critical/high open questions\",\n narrative: \"array — concise natural-language summary lines\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const DISCOVER: McpToolContract = {\n name: \"discover\",\n description:\n \"Navigate the topic tree to find where knowledge lives. \" +\n \"Like `git log --all --grep` — searches across the graph using bottom-up content matching plus top-down structural scoring.\",\n parameters: {\n query: {\n type: \"string\",\n description: \"What to look for across the topic tree\",\n },\n topK: {\n type: \"number\",\n description: \"How many matching topics to return (default: 3, max: 10)\",\n },\n includeNeighborhood: {\n type: \"boolean\",\n description:\n \"Whether to include beliefs/questions/evidence for matched topics\",\n },\n },\n required: [\"query\"],\n response: {\n description: \"Ranked topic matches with optional neighborhood content\",\n fields: {\n query: \"string — original query\",\n matchedTopics: \"array — ranked topics with scores and paths\",\n neighborhoods: \"array — beliefs, questions, evidence for each match\",\n totalTopicsScored: \"number\",\n topicTreeSize: \"number\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n deprecated: \"Deprecated: use lucern.context.compile() with topicId\",\n};\n\nexport const ANALYZE_TOPIC_DENSITY: McpToolContract = {\n name: \"analyze_topic_density\",\n description:\n \"Analyze topic belief density and identify natural conceptual clusters. \" +\n \"Like `git diff --stat` for topic organization — detects when a topic has accumulated too many beliefs and suggests subtopic decomposition.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic ID to analyze\" },\n threshold: {\n type: \"number\",\n description: \"Belief count threshold for density warning\",\n },\n minModularity: {\n type: \"number\",\n description: \"Minimum modularity score for suggesting decomposition\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Density analysis with cluster suggestions\",\n fields: {\n topicId: \"string\",\n topicName: \"string\",\n beliefCount: \"number\",\n edgeCount: \"number\",\n threshold: \"number\",\n isDense: \"boolean\",\n modularity: \"number\",\n clusterCount: \"number\",\n clusters: \"array — suggested belief clusters\",\n recommendation: \"string\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const APPLY_AUTO_BRANCHING: McpToolContract = {\n name: \"apply_auto_branching\",\n description:\n \"Execute topic decomposition by creating subtopics and reassigning beliefs. \" +\n \"Like `git subtree split` — splits a dense topic into focused subtopics while preserving belief identity and edges.\",\n parameters: {\n topicId: { type: \"string\", description: \"Parent topic ID to decompose\" },\n clusters: {\n type: \"array\",\n description:\n \"Cluster definitions from analyze_topic_density, each with name and beliefIds\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"Preview changes without applying them\",\n },\n },\n required: [\"topicId\", \"clusters\"],\n response: {\n description: \"Results of the auto-branching operation\",\n fields: {\n success: \"boolean\",\n parentTopicId: \"string\",\n createdSubtopics: \"array\",\n totalReassigned: \"number\",\n totalSkipped: \"number\",\n dryRun: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const SEED_BELIEF_LATTICE: McpToolContract = {\n name: \"seed_belief_lattice\",\n description:\n \"Seed belief lattice coverage for a topic based on its resolved ontology. \" +\n \"Like `git init` for ontology coverage — creates or previews seed beliefs for entity types that need a baseline anchor.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID. Lattice seeding must target a child topic.\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"Preview seeds without creating them\",\n },\n },\n required: [],\n response: {\n description: \"Lattice seed results with per-entity-type status\",\n fields: {\n topicId: \"string\",\n ontologyResolved: \"boolean\",\n ontologyKey: \"string | null\",\n ontologyVersion: \"string | null\",\n entityTypeCount: \"number\",\n seeds: \"array — per-entity-type seed status\",\n summary: \"object — created/existing/scored/total counts\",\n dryRun: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GET_LATTICE_COVERAGE: McpToolContract = {\n name: \"get_lattice_coverage\",\n description:\n \"Report belief lattice coverage for a topic. \" +\n \"Like `git fsck` for ontology coverage — identifies anchored, hollow, and missing entity-type belief coverage.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID to check lattice coverage for\",\n },\n },\n required: [],\n response: {\n description: \"Per-entity-type coverage with overall score\",\n fields: {\n topicId: \"string\",\n ontologyKey: \"string | null\",\n ontologyVersion: \"string | null\",\n entityTypes: \"array — per-entity-type coverage rows\",\n summary: \"object — total/anchored/hollow/missing/coverageScore\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const DISCOVER_ENTITY_CONNECTIONS: McpToolContract = {\n name: \"discover_entity_connections\",\n description:\n \"Find existing entities that should be connected to a belief/question/evidence node. \" +\n \"Like `git log --diff-filter=M` for missing entity connections — scans entities in scope and suggests bridge edge types.\",\n parameters: {\n nodeId: {\n type: \"string\",\n description: \"Epistemic node ID to find entity connections for\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope override\",\n },\n minScore: {\n type: \"number\",\n description: \"Minimum match score threshold\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum candidates to return\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Ranked entity connection candidates\",\n fields: {\n nodeId: \"string\",\n candidateCount: \"number\",\n candidates: \"array — suggested entity bridge candidates\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const TRIGGER_BELIEF_REVIEW: McpToolContract = {\n name: \"trigger_belief_review\",\n description:\n \"Flag beliefs for review after an entity changes. \" +\n \"Like `git bisect` for stale beliefs — traverses bridge edges from the changed entity and creates review questions for stale connected beliefs.\",\n parameters: {\n entityNodeId: {\n type: \"string\",\n description: \"The entity node that changed\",\n },\n changeDescription: {\n type: \"string\",\n description: \"What changed about the entity\",\n },\n maxQuestions: {\n type: \"number\",\n description: \"Maximum review questions to create\",\n },\n },\n required: [\"entityNodeId\"],\n response: {\n description: \"Affected beliefs and created review questions\",\n fields: {\n entityNodeId: \"string\",\n entityTitle: \"string\",\n entityType: \"string\",\n changeDescription: \"string\",\n affectedBeliefCount: \"number\",\n questionsCreated: \"number\",\n reviewedBeliefs: \"array\",\n questions: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const EVALUATE_CONTRACT: McpToolContract = {\n name: \"evaluate_contract\",\n description:\n \"Run a contract evaluation and record the append-only result. \" +\n \"Like `git test` for a belief binding — executes the evaluator, logs the result, and applies any allowed SL scoring action.\",\n parameters: {\n contractId: { type: \"string\", description: \"Which contract to evaluate\" },\n trigger: {\n type: \"string\",\n description: \"What caused this evaluation\",\n },\n },\n required: [\"contractId\"],\n response: {\n description: \"The most recent contract evaluation result\",\n fields: {\n evaluationId: \"string\",\n result: \"string\",\n status: \"string\",\n confidenceBefore: \"number\",\n confidenceAfter: \"number\",\n rationale: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const GET_CONTRACT_STATUS: McpToolContract = {\n name: \"get_contract_status\",\n description:\n \"Inspect epistemic contracts and their latest evaluations. \" +\n \"Like `git status` for verification bindings — returns the contract rows plus the freshest recorded evaluation for each one.\",\n parameters: {\n beliefNodeId: {\n type: \"string\",\n description: \"Return all contracts attached to a specific belief\",\n },\n contractId: {\n type: \"string\",\n description: \"Return one specific contract by contractId\",\n },\n status: {\n type: \"string\",\n description: \"Optional status filter applied after lookup\",\n enum: [\"active\", \"satisfied\", \"violated\", \"expired\", \"suspended\", \"archived\"],\n },\n },\n required: [],\n response: {\n description: \"Matching contract rows with latest evaluation context\",\n fields: {\n contracts: \"array — matching contracts with latestEvaluation attached\",\n count: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const REGISTER_SESSION: McpToolContract = {\n name: \"register_session\",\n description:\n \"Announce this agent session's presence to other parallel sessions. \" +\n \"Like `git init` for coordination — creates a session record so other agents can discover you.\",\n parameters: {\n sessionName: { type: \"string\", description: \"Human-readable session label\" },\n agentType: { type: \"string\", description: \"Agent type\" },\n topicId: { type: \"string\", description: \"Current Lucern topic scope ID\" },\n worktreeId: { type: \"string\", description: \"Active Lucern worktree ID\" },\n gitBranch: { type: \"string\", description: \"Current git branch name\" },\n },\n required: [],\n response: {\n description: \"Session registration result\",\n fields: {\n sessionId: \"string\",\n status: \"string — active\",\n isNew: \"boolean\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const HEARTBEAT_SESSION: McpToolContract = {\n name: \"heartbeat_session\",\n description:\n \"Update this session's heartbeat and optional status fields. \" +\n \"Like `git status` — signals liveness and updates what you are working on.\",\n parameters: {\n topicId: { type: \"string\", description: \"Updated topic scope\" },\n worktreeId: { type: \"string\", description: \"Updated worktree ID\" },\n gitBranch: { type: \"string\", description: \"Updated git branch\" },\n status: {\n type: \"string\",\n description: \"Session status update\",\n enum: [\"active\", \"idle\"],\n },\n },\n required: [],\n response: {\n description: \"Heartbeat result\",\n fields: {\n success: \"boolean\",\n message: \"string\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const END_SESSION: McpToolContract = {\n name: \"end_session\",\n description:\n \"Gracefully end this agent session. \" +\n \"Like `git stash` — marks the session as ended so other agents know you are gone.\",\n parameters: {},\n required: [],\n response: {\n description: \"Session end result\",\n fields: {\n success: \"boolean\",\n message: \"string\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const LIST_ACTIVE_SESSIONS: McpToolContract = {\n name: \"list_active_sessions\",\n description:\n \"See who else is online with active agent sessions, scope, branch, and file claims. \" +\n \"Like `git branch --list` for live agents — shows active and idle sessions before editing.\",\n parameters: {\n includeIdle: {\n type: \"boolean\",\n description: \"Include idle sessions\",\n },\n },\n required: [],\n response: {\n description: \"List of active/idle agent sessions\",\n fields: {\n sessions: \"array — active session records\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const SEND_AGENT_MESSAGE: McpToolContract = {\n name: \"send_agent_message\",\n description:\n \"Send a directed message to a specific agent session. \" +\n \"Like `git notes` — leaves a coordination note for a specific peer.\",\n parameters: {\n toSessionId: { type: \"string\", description: \"Target session ID\" },\n content: { type: \"string\", description: \"Message text\" },\n messageType: {\n type: \"string\",\n description: \"Message intent\",\n enum: [\"note\", \"question\", \"answer\", \"alert\", \"handoff\"],\n },\n relatedBeliefId: {\n type: \"string\",\n description: \"Optional related belief node ID\",\n },\n relatedWorktreeId: {\n type: \"string\",\n description: \"Optional related worktree ID\",\n },\n },\n required: [\"toSessionId\", \"content\"],\n response: {\n description: \"Message delivery result\",\n fields: { messageId: \"string\" },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const BROADCAST_MESSAGE: McpToolContract = {\n name: \"broadcast_message\",\n description:\n \"Send a message to all active agent sessions. \" +\n \"Like `git tag` — marks an important event visible to everyone.\",\n parameters: {\n content: { type: \"string\", description: \"Broadcast message text\" },\n messageType: {\n type: \"string\",\n description: \"Message intent\",\n enum: [\"note\", \"alert\", \"handoff\"],\n },\n relatedBeliefId: {\n type: \"string\",\n description: \"Optional related belief node ID\",\n },\n relatedWorktreeId: {\n type: \"string\",\n description: \"Optional related worktree ID\",\n },\n },\n required: [\"content\"],\n response: {\n description: \"Broadcast result\",\n fields: { messageId: \"string\" },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GET_AGENT_INBOX: McpToolContract = {\n name: \"get_agent_inbox\",\n description:\n \"Check unread messages addressed to this session. \" +\n \"Like `git log --incoming` — shows direct and broadcast messages from other agents.\",\n parameters: {\n limit: { type: \"number\", description: \"Max messages to return\" },\n markAsRead: {\n type: \"boolean\",\n description: \"Mark returned messages as read\",\n },\n },\n required: [],\n response: {\n description: \"Inbox messages\",\n fields: {\n messages: \"array — unread direct and broadcast messages\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const CLAIM_FILES: McpToolContract = {\n name: \"claim_files\",\n description:\n \"Declare which files this session is actively editing. \" +\n \"Like `git add` for coordination — tells other sessions what you are touching and returns advisory conflicts.\",\n parameters: {\n files: {\n type: \"array\",\n description: \"File paths this session is actively editing\",\n },\n },\n required: [\"files\"],\n response: {\n description: \"File claim result with conflict detection\",\n fields: {\n success: \"boolean\",\n conflicts: \"array — conflicting file claims\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GENERATE_SESSION_HANDOFF: McpToolContract = {\n name: \"generate_session_handoff\",\n description:\n \"Generate a complete, zero-context handoff message for a new coding session. \" +\n \"Like `git format-patch` — produces a self-contained instruction set that bootstraps a fresh Lucern worktree session.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The Lucern worktree ID to generate handoff instructions for\",\n },\n gitWorktreePath: {\n type: \"string\",\n description: \"Optional existing git worktree path\",\n },\n gitBranchName: {\n type: \"string\",\n description: \"Optional branch name for the session\",\n },\n additionalContext: {\n type: \"string\",\n description: \"Optional extra context to include in the handoff\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"A complete handoff message ready for a new coding session\",\n fields: {\n handoffMessage: \"string\",\n worktreeId: \"string\",\n worktreeName: \"string\",\n trackBoundary: \"object\",\n needsActivation: \"boolean\",\n needsGitSetup: \"string — create | fast-forward | ready\",\n },\n },\n ownerModule: \"bootstrap\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n internal: true,\n};\n\nexport const BEGIN_BUILD_SESSION: McpToolContract = {\n name: \"begin_build_session\",\n description:\n \"Bootstrap a coding build session for a Lucern worktree. \" +\n \"Like `git worktree add` plus `git status` — returns the compact context packet an agent needs before editing.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The Lucern worktree ID to bootstrap.\",\n },\n branch: {\n type: \"string\",\n description:\n \"Optional git branch name. Auto-generated from the worktree name when omitted.\",\n },\n branchBase: {\n type: \"string\",\n description: 'Base branch for the feature branch. Default: \"staging\".',\n },\n prBase: {\n type: \"string\",\n description: 'Target branch for the PR. Default: \"staging\".',\n },\n sessionMode: {\n type: \"string\",\n description:\n 'Session mode: \"async\" for Codex/headless or \"interactive\" for live sessions.',\n enum: [\"async\", \"interactive\"],\n },\n activateIfPlanning: {\n type: \"boolean\",\n description:\n \"When true, automatically activate a planning worktree during bootstrap.\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description:\n \"A compact build-session packet with worktree metadata, graph anchors, questions, dependencies, and git defaults.\",\n fields: {\n topicId: \"string — canonical topic scope\",\n topicName: \"string — human-readable topic name\",\n worktreeId: \"string — worktree ID\",\n worktreeName: \"string — human-readable worktree name\",\n branch: \"string — git branch name\",\n branchBase: \"string — base branch\",\n prBase: \"string — PR target branch\",\n campaign: \"number | null — top-level pipeline campaign\",\n lane: \"string — campaign lane\",\n gate: \"string — exit gate\",\n hypothesis: \"string — worktree hypothesis\",\n focus: \"string — session focus\",\n status: \"string — worktree status after optional activation\",\n sessionMode: \"string — async | interactive\",\n targetBeliefIds: \"array — scoped belief IDs\",\n targetQuestionIds: \"array — scoped question IDs\",\n taskIds: \"array — assigned task IDs for this worktree\",\n incompleteTaskIds:\n \"array — assigned task IDs that still require done/deferred/blocked proof\",\n tasks:\n \"array — assigned task packet with id, title, status, priority, links, and summaries\",\n topBeliefs: \"array — highest-confidence scoped beliefs\",\n openQuestions: \"array — open scoped questions\",\n resolvedDecisions: \"array — answered questions summarized for the session\",\n dependencies: \"array — upstream worktrees\",\n unblocks: \"array — downstream worktrees\",\n mergeOrderNotes: \"string — merge ordering advisory\",\n },\n },\n ownerModule: \"bootstrap\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n internal: true,\n};\n","/**\n * MCP Tool Contract Definitions\n *\n * Stable facade for the split MCP contract catalog. Contract literals live in\n * focused tool-contracts.* modules; this file preserves the public import path\n * and owns the registry plus validation helpers.\n */\n\nimport type { McpToolContract } from \"./tool-contracts.types\";\n\nimport {\n CREATE_BELIEF,\n GET_BELIEF,\n REFINE_BELIEF,\n APPEND_SL_SCORING,\n FORK_BELIEF,\n ARCHIVE_BELIEF,\n CREATE_EPISTEMIC_CONTRACT,\n ADD_EVIDENCE,\n FLAG_CONTRADICTION,\n} from \"./tool-contracts.lifecycle\";\n\nimport {\n ADD_WORKTREE,\n LIST_WORKTREES_BY_BELIEF,\n MERGE,\n PUSH,\n OPEN_PULL_REQUEST,\n} from \"./tool-contracts.worktrees\";\n\nimport {\n QUERY_LINEAGE,\n QUERY_ANCHOR_HISTORY,\n GET_CONFIDENCE_HISTORY,\n GET_AUDIT_TRAIL,\n TRAVERSE_GRAPH,\n GET_GRAPH_NEIGHBORHOOD,\n TRACE_ENTITY_IMPACT,\n SEARCH_BELIEFS,\n FIND_CONTRADICTIONS,\n BISECT_CONFIDENCE,\n CREATE_EDGE,\n UPDATE_EDGE,\n REMOVE_EDGE,\n REMOVE_EDGES_BETWEEN,\n BATCH_CREATE_EDGES,\n} from \"./tool-contracts.graph\";\n\nimport {\n GET_EMBEDDINGS_BY_NODE_IDS,\n LIST_MISSING_EMBEDDINGS,\n QUEUE_EMBEDDING_BACKFILL,\n SEARCH_EMBEDDINGS,\n} from \"./tool-contracts.embeddings\";\n\nimport {\n ANALYZE_GRAPH_IMPACT,\n DETECT_GRAPH_DRIFT,\n EXPAND_GRAPH_NEIGHBORHOOD,\n FIND_RELATED_NODES,\n HYBRID_DISCOVER,\n RESOLVE_TOPIC_SEMANTIC,\n} from \"./tool-contracts.hybrid-discovery\";\n\nimport {\n CREATE_EPISTEMIC_NODE,\n GET_EPISTEMIC_NODE,\n LIST_EPISTEMIC_NODES,\n UPDATE_EPISTEMIC_NODE,\n ARCHIVE_EPISTEMIC_NODE,\n VERIFY_EPISTEMIC_NODE,\n SUPERSEDE_EPISTEMIC_NODE,\n BATCH_CREATE_EPISTEMIC_NODES,\n RECORD_JUDGMENT,\n CREATE_LENS,\n LIST_LENSES,\n APPLY_LENS_TO_TOPIC,\n REMOVE_LENS_FROM_TOPIC,\n} from \"./tool-contracts.nodes-lenses\";\n\nimport { LUCERN_ORIENT } from \"./tool-contracts.context-orientation\";\n\nimport {\n DETECT_CONFIRMATION_BIAS,\n GET_GRAPH_STRUCTURE_ANALYSIS,\n LIST_GRAPH_INTELLIGENCE_QUERIES,\n RUN_GRAPH_INTELLIGENCE_QUERY,\n GET_FALSIFICATION_QUESTIONS,\n SEARCH_EVIDENCE,\n CREATE_EVIDENCE,\n GET_EVIDENCE,\n LIST_EVIDENCE,\n ARCHIVE_EVIDENCE,\n LINK_EVIDENCE,\n LINK_EVIDENCE_TO_BELIEF,\n} from \"./tool-contracts.intelligence-evidence\";\n\nimport {\n CREATE_QUESTION,\n GET_QUESTION,\n REFINE_QUESTION,\n LIST_QUESTIONS,\n ANSWER_QUESTION,\n UPDATE_QUESTION_STATUS,\n ARCHIVE_QUESTION,\n LINK_EVIDENCE_TO_QUESTION,\n CREATE_ANSWER,\n GET_ANSWER,\n GET_HIGH_PRIORITY_QUESTIONS,\n FIND_MISSING_QUESTIONS,\n LIST_BELIEFS,\n GET_WORKTREE,\n LIST_WORKTREES,\n LIST_ALL_WORKTREES,\n LIST_CAMPAIGNS,\n ACTIVATE_WORKTREE,\n UPDATE_WORKTREE_TARGETS,\n UPDATE_WORKTREE_METADATA,\n IDENTITY_WHOAMI,\n RESOLVE_INTERACTIVE_PRINCIPAL,\n COMPILE_CONTEXT,\n} from \"./tool-contracts.questions-listing\";\n\nimport {\n CHECK_PERMISSION,\n COMPILE_CAPABILITY_SLICE,\n FILTER_BY_PERMISSION,\n INGEST_OBSERVATION,\n GET_OBSERVATION_CONTEXT,\n CREATE_TASK,\n COMPLETE_TASK,\n UPDATE_TASK,\n LIST_TASKS,\n CREATE_TOPIC,\n LIST_TOPICS,\n GET_TOPIC,\n UPDATE_TOPIC,\n GET_TOPIC_TREE,\n MATERIALIZE_TOPIC_GRAPH,\n GET_TOPIC_GRAPH_SPINE,\n GET_CODE_CONTEXT,\n GET_CHANGE_HISTORY,\n RECORD_ATTEMPT,\n GET_FAILURE_LOG,\n GET_TOPIC_COVERAGE,\n GET_GRAPH_GAPS,\n} from \"./tool-contracts.policy-observation-task-topic\";\n\nimport {\n MANAGE_WRITE_POLICY,\n LIST_ONTOLOGIES,\n GET_ONTOLOGY,\n APPLY_ONTOLOGY,\n MATCH_ENTITY_TYPE,\n CREATE_ONTOLOGY,\n UPDATE_ONTOLOGY,\n ARCHIVE_ONTOLOGY,\n CREATE_ONTOLOGY_VERSION,\n PUBLISH_ONTOLOGY_VERSION,\n DEPRECATE_ONTOLOGY_VERSION,\n RESOLVE_EFFECTIVE_ONTOLOGY,\n} from \"./tool-contracts.ontology\";\n\nimport {\n RECORD_SCOPE_LEARNING,\n PIPELINE_SNAPSHOT,\n DISCOVER,\n ANALYZE_TOPIC_DENSITY,\n APPLY_AUTO_BRANCHING,\n SEED_BELIEF_LATTICE,\n GET_LATTICE_COVERAGE,\n DISCOVER_ENTITY_CONNECTIONS,\n TRIGGER_BELIEF_REVIEW,\n EVALUATE_CONTRACT,\n GET_CONTRACT_STATUS,\n REGISTER_SESSION,\n HEARTBEAT_SESSION,\n END_SESSION,\n LIST_ACTIVE_SESSIONS,\n SEND_AGENT_MESSAGE,\n BROADCAST_MESSAGE,\n GET_AGENT_INBOX,\n CLAIM_FILES,\n GENERATE_SESSION_HANDOFF,\n BEGIN_BUILD_SESSION,\n} from \"./tool-contracts.pipeline-coordination\";\n\nexport type { McpParameterDef, McpResponseDef, McpToolContract } from \"./tool-contracts.types\";\nexport * from \"./tool-contracts.lifecycle\";\nexport * from \"./tool-contracts.worktrees\";\nexport * from \"./tool-contracts.graph\";\nexport * from \"./tool-contracts.embeddings\";\nexport * from \"./tool-contracts.hybrid-discovery\";\nexport * from \"./tool-contracts.nodes-lenses\";\nexport * from \"./tool-contracts.context-orientation\";\nexport * from \"./tool-contracts.intelligence-evidence\";\nexport * from \"./tool-contracts.questions-listing\";\nexport * from \"./tool-contracts.policy-observation-task-topic\";\nexport * from \"./tool-contracts.ontology\";\nexport * from \"./tool-contracts.pipeline-coordination\";\n\n// =============================================================================\n// TOOL REGISTRY\n// =============================================================================\n\n/** All MCP tool contracts, indexed by name */\nexport const MCP_TOOL_CONTRACTS: Record<string, McpToolContract> = {\n // Belief lifecycle (commit, amend, fork, archive)\n create_belief: CREATE_BELIEF,\n get_belief: GET_BELIEF,\n refine_belief: REFINE_BELIEF,\n append_sl_scoring: APPEND_SL_SCORING,\n fork_belief: FORK_BELIEF,\n archive_belief: ARCHIVE_BELIEF,\n create_epistemic_contract: CREATE_EPISTEMIC_CONTRACT,\n evaluate_contract: EVALUATE_CONTRACT,\n get_contract_status: GET_CONTRACT_STATUS,\n // Evidence (commit)\n create_evidence: CREATE_EVIDENCE,\n get_evidence: GET_EVIDENCE,\n list_evidence: LIST_EVIDENCE,\n archive_evidence: ARCHIVE_EVIDENCE,\n link_evidence: LINK_EVIDENCE,\n add_evidence: ADD_EVIDENCE,\n // Contradictions (merge conflict)\n flag_contradiction: FLAG_CONTRADICTION,\n // Lens lifecycle (workspace-scoped operational frames)\n create_lens: CREATE_LENS,\n list_lenses: LIST_LENSES,\n apply_lens_to_topic: APPLY_LENS_TO_TOPIC,\n remove_lens_from_topic: REMOVE_LENS_FROM_TOPIC,\n // Worktree lifecycle (git worktree add → merge → push → pull request)\n add_worktree: ADD_WORKTREE,\n merge: MERGE,\n push: PUSH,\n open_pull_request: OPEN_PULL_REQUEST,\n // Lineage and audit (log, blame)\n query_lineage: QUERY_LINEAGE,\n query_anchor_history: QUERY_ANCHOR_HISTORY,\n get_confidence_history: GET_CONFIDENCE_HISTORY,\n get_audit_trail: GET_AUDIT_TRAIL,\n // Graph queries (traverse, search, bisect, entity impact)\n traverse_graph: TRAVERSE_GRAPH,\n get_graph_neighborhood: GET_GRAPH_NEIGHBORHOOD,\n trace_entity_impact: TRACE_ENTITY_IMPACT,\n search_beliefs: SEARCH_BELIEFS,\n find_contradictions: FIND_CONTRADICTIONS,\n bisect_confidence: BISECT_CONFIDENCE,\n list_missing_embeddings: LIST_MISSING_EMBEDDINGS,\n search_embeddings: SEARCH_EMBEDDINGS,\n get_embeddings_by_node_ids: GET_EMBEDDINGS_BY_NODE_IDS,\n queue_embedding_backfill: QUEUE_EMBEDDING_BACKFILL,\n hybrid_discover: HYBRID_DISCOVER,\n resolve_topic_semantic: RESOLVE_TOPIC_SEMANTIC,\n expand_graph_neighborhood: EXPAND_GRAPH_NEIGHBORHOOD,\n find_related_nodes: FIND_RELATED_NODES,\n analyze_graph_impact: ANALYZE_GRAPH_IMPACT,\n detect_graph_drift: DETECT_GRAPH_DRIFT,\n // Edges (commit)\n create_edge: CREATE_EDGE,\n update_edge: UPDATE_EDGE,\n remove_edge: REMOVE_EDGE,\n remove_edges_between: REMOVE_EDGES_BETWEEN,\n batch_create_edges: BATCH_CREATE_EDGES,\n // Epistemic node spine (commit/amend/show)\n create_epistemic_node: CREATE_EPISTEMIC_NODE,\n get_epistemic_node: GET_EPISTEMIC_NODE,\n list_epistemic_nodes: LIST_EPISTEMIC_NODES,\n update_epistemic_node: UPDATE_EPISTEMIC_NODE,\n archive_epistemic_node: ARCHIVE_EPISTEMIC_NODE,\n verify_epistemic_node: VERIFY_EPISTEMIC_NODE,\n supersede_epistemic_node: SUPERSEDE_EPISTEMIC_NODE,\n batch_create_epistemic_nodes: BATCH_CREATE_EPISTEMIC_NODES,\n // Judgments (tag)\n record_judgment: RECORD_JUDGMENT,\n // Graph intelligence (showcase)\n detect_confirmation_bias: DETECT_CONFIRMATION_BIAS,\n get_graph_structure_analysis: GET_GRAPH_STRUCTURE_ANALYSIS,\n list_graph_intelligence_queries: LIST_GRAPH_INTELLIGENCE_QUERIES,\n run_graph_intelligence_query: RUN_GRAPH_INTELLIGENCE_QUERY,\n get_falsification_questions: GET_FALSIFICATION_QUESTIONS,\n // Evidence operations (workhorse)\n search_evidence: SEARCH_EVIDENCE,\n link_evidence_to_belief: LINK_EVIDENCE_TO_BELIEF,\n // Answer lifecycle (L2 question responses)\n create_answer: CREATE_ANSWER,\n get_answer: GET_ANSWER,\n // Question operations (workhorse)\n create_question: CREATE_QUESTION,\n get_question: GET_QUESTION,\n refine_question: REFINE_QUESTION,\n list_questions: LIST_QUESTIONS,\n answer_question: ANSWER_QUESTION,\n update_question_status: UPDATE_QUESTION_STATUS,\n archive_question: ARCHIVE_QUESTION,\n link_evidence_to_question: LINK_EVIDENCE_TO_QUESTION,\n get_high_priority_questions: GET_HIGH_PRIORITY_QUESTIONS,\n find_missing_questions: FIND_MISSING_QUESTIONS,\n // Listing & query (workhorse)\n list_beliefs: LIST_BELIEFS,\n get_worktree: GET_WORKTREE,\n list_worktrees: LIST_WORKTREES,\n list_all_worktrees: LIST_ALL_WORKTREES,\n list_worktrees_by_belief: LIST_WORKTREES_BY_BELIEF,\n list_campaigns: LIST_CAMPAIGNS,\n activate_worktree: ACTIVATE_WORKTREE,\n update_worktree_targets: UPDATE_WORKTREE_TARGETS,\n update_worktree_metadata: UPDATE_WORKTREE_METADATA,\n identity_whoami: IDENTITY_WHOAMI,\n resolve_interactive_principal: RESOLVE_INTERACTIVE_PRINCIPAL,\n lucern_orient: LUCERN_ORIENT,\n compile_context: COMPILE_CONTEXT,\n record_scope_learning: RECORD_SCOPE_LEARNING,\n pipeline_snapshot: PIPELINE_SNAPSHOT,\n discover: DISCOVER,\n analyze_topic_density: ANALYZE_TOPIC_DENSITY,\n apply_auto_branching: APPLY_AUTO_BRANCHING,\n seed_belief_lattice: SEED_BELIEF_LATTICE,\n get_lattice_coverage: GET_LATTICE_COVERAGE,\n discover_entity_connections: DISCOVER_ENTITY_CONNECTIONS,\n trigger_belief_review: TRIGGER_BELIEF_REVIEW,\n register_session: REGISTER_SESSION,\n heartbeat_session: HEARTBEAT_SESSION,\n end_session: END_SESSION,\n list_active_sessions: LIST_ACTIVE_SESSIONS,\n send_agent_message: SEND_AGENT_MESSAGE,\n broadcast_message: BROADCAST_MESSAGE,\n get_agent_inbox: GET_AGENT_INBOX,\n claim_files: CLAIM_FILES,\n generate_session_handoff: GENERATE_SESSION_HANDOFF,\n begin_build_session: BEGIN_BUILD_SESSION,\n // Policy / ACL (workhorse)\n check_permission: CHECK_PERMISSION,\n compile_capability_slice: COMPILE_CAPABILITY_SLICE,\n filter_by_permission: FILTER_BY_PERMISSION,\n // Write policy (S2-13K Graph Compounding)\n manage_write_policy: MANAGE_WRITE_POLICY,\n // Observation context (workhorse)\n ingest_observation: INGEST_OBSERVATION,\n get_observation_context: GET_OBSERVATION_CONTEXT,\n // Task lifecycle (workhorse)\n create_task: CREATE_TASK,\n complete_task: COMPLETE_TASK,\n update_task: UPDATE_TASK,\n list_tasks: LIST_TASKS,\n // Topic lifecycle (init, remote)\n create_topic: CREATE_TOPIC,\n list_topics: LIST_TOPICS,\n get_topic: GET_TOPIC,\n update_topic: UPDATE_TOPIC,\n get_topic_tree: GET_TOPIC_TREE,\n materialize_topic_graph: MATERIALIZE_TOPIC_GRAPH,\n get_topic_graph_spine: GET_TOPIC_GRAPH_SPINE,\n // Coding intelligence (code-grounded knowledge)\n get_code_context: GET_CODE_CONTEXT,\n get_change_history: GET_CHANGE_HISTORY,\n record_attempt: RECORD_ATTEMPT,\n get_failure_log: GET_FAILURE_LOG,\n // Graph self-intelligence (coverage, gaps)\n get_topic_coverage: GET_TOPIC_COVERAGE,\n get_graph_gaps: GET_GRAPH_GAPS,\n // Ontology lifecycle (definition CRUD, version management)\n list_ontologies: LIST_ONTOLOGIES,\n get_ontology: GET_ONTOLOGY,\n apply_ontology: APPLY_ONTOLOGY,\n match_entity_type: MATCH_ENTITY_TYPE,\n create_ontology: CREATE_ONTOLOGY,\n update_ontology: UPDATE_ONTOLOGY,\n archive_ontology: ARCHIVE_ONTOLOGY,\n create_ontology_version: CREATE_ONTOLOGY_VERSION,\n publish_ontology_version: PUBLISH_ONTOLOGY_VERSION,\n deprecate_ontology_version: DEPRECATE_ONTOLOGY_VERSION,\n resolve_effective_ontology: RESOLVE_EFFECTIVE_ONTOLOGY,\n};\n\n/** Tool names that MUST include git-semantic language in descriptions */\nexport const GIT_SEMANTIC_REQUIRED_TOOLS = Object.keys(MCP_TOOL_CONTRACTS);\n\n/**\n * Lint validation: every tool description must contain \"Like `git\" or \"Like a `git\"\n * or reference a git operation in the first sentence.\n */\nexport function validateGitSemantics(tool: McpToolContract): {\n valid: boolean;\n reason?: string;\n} {\n const desc = tool.description;\n const hasGitReference =\n /Like (`git |a `git |a merge conflict|opening a `git)/.test(desc);\n if (!hasGitReference) {\n return {\n valid: false,\n reason: `Tool \"${tool.name}\" description missing git-semantic reference`,\n };\n }\n return { valid: true };\n}\n","import type {\n FunctionSurfaceIntent,\n SurfaceClass,\n SurfaceExposure,\n FunctionSurfaceMap,\n} from \"./types.js\";\n\nexport type LucernOperationManifestEntry = {\n name: string;\n surfaceClass: SurfaceClass;\n surfaceIntent: FunctionSurfaceIntent;\n surfaces: FunctionSurfaceMap;\n rationale: string;\n};\n\nconst publicEverywhere: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"public\",\n cli: \"public\",\n};\n\nconst internalSystem: FunctionSurfaceMap = {\n sdk: \"internal\",\n rest: \"internal\",\n mcp: \"internal\",\n cli: \"internal\",\n};\n\nconst internalSdkRestOnly: FunctionSurfaceMap = {\n sdk: \"internal\",\n rest: \"internal\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst publicWithInternalMcp: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"internal\",\n cli: \"public\",\n};\n\nconst publicWithoutMcp: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst sdkOnlyPublic: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"none\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst mcpOnlyInternal: FunctionSurfaceMap = {\n sdk: \"none\",\n rest: \"none\",\n mcp: \"internal\",\n cli: \"none\",\n};\n\nfunction entries(\n names: readonly string[],\n surfaceClass: SurfaceClass,\n surfaceIntent: FunctionSurfaceIntent,\n surfaces: FunctionSurfaceMap,\n rationale: string\n): Record<string, LucernOperationManifestEntry> {\n return Object.fromEntries(\n names.map((name) => [\n name,\n {\n name,\n surfaceClass,\n surfaceIntent,\n surfaces,\n rationale,\n },\n ])\n );\n}\n\nexport const MCP_CORE_OPERATION_NAMES = [\n \"lucern_orient\",\n \"compile_context\",\n \"identity_whoami\",\n \"resolve_interactive_principal\",\n \"check_permission\",\n \"compile_capability_slice\",\n \"filter_by_permission\",\n \"create_belief\",\n \"get_belief\",\n \"list_beliefs\",\n \"refine_belief\",\n \"fork_belief\",\n \"archive_belief\",\n \"search_beliefs\",\n \"bisect_confidence\",\n \"create_evidence\",\n \"get_evidence\",\n \"list_evidence\",\n \"archive_evidence\",\n \"search_evidence\",\n \"link_evidence_to_belief\",\n \"link_evidence_to_question\",\n \"create_question\",\n \"get_question\",\n \"list_questions\",\n \"refine_question\",\n \"update_question_status\",\n \"archive_question\",\n \"create_answer\",\n \"get_answer\",\n \"find_missing_questions\",\n \"get_high_priority_questions\",\n \"get_falsification_questions\",\n \"create_epistemic_node\",\n \"get_epistemic_node\",\n \"list_epistemic_nodes\",\n \"update_epistemic_node\",\n \"archive_epistemic_node\",\n \"verify_epistemic_node\",\n \"supersede_epistemic_node\",\n \"batch_create_epistemic_nodes\",\n \"create_topic\",\n \"get_topic\",\n \"list_topics\",\n \"update_topic\",\n \"get_topic_tree\",\n \"materialize_topic_graph\",\n \"get_topic_graph_spine\",\n] as const;\n\nexport const MCP_ANALYSIS_PLATFORM_OPERATION_NAMES = [\n \"create_edge\",\n \"update_edge\",\n \"remove_edge\",\n \"remove_edges_between\",\n \"batch_create_edges\",\n \"query_lineage\",\n \"query_anchor_history\",\n \"traverse_graph\",\n \"get_graph_neighborhood\",\n \"get_graph_structure_analysis\",\n \"list_graph_intelligence_queries\",\n \"run_graph_intelligence_query\",\n \"list_missing_embeddings\",\n \"search_embeddings\",\n \"get_embeddings_by_node_ids\",\n \"queue_embedding_backfill\",\n \"hybrid_discover\",\n \"resolve_topic_semantic\",\n \"expand_graph_neighborhood\",\n \"find_related_nodes\",\n \"analyze_graph_impact\",\n \"detect_graph_drift\",\n \"find_contradictions\",\n \"flag_contradiction\",\n \"detect_confirmation_bias\",\n \"get_topic_coverage\",\n \"get_graph_gaps\",\n] as const;\n\nexport const MCP_ANALYSIS_TENANT_OPERATION_NAMES = [\n \"analyze_topic_density\",\n \"discover_entity_connections\",\n \"trace_entity_impact\",\n] as const;\n\nexport const MCP_WORKFLOW_PLATFORM_OPERATION_NAMES = [\n \"list_lenses\",\n \"apply_lens_to_topic\",\n \"remove_lens_from_topic\",\n \"get_ontology\",\n \"list_ontologies\",\n \"apply_ontology\",\n \"match_entity_type\",\n \"resolve_effective_ontology\",\n \"add_worktree\",\n \"get_worktree\",\n \"activate_worktree\",\n \"list_worktrees\",\n \"list_all_worktrees\",\n \"list_worktrees_by_belief\",\n \"list_campaigns\",\n \"update_worktree_targets\",\n \"update_worktree_metadata\",\n \"create_task\",\n \"list_tasks\",\n \"update_task\",\n \"complete_task\",\n] as const;\n\nexport const MCP_WORKFLOW_TENANT_OPERATION_NAMES = [\n \"resolve_effective_ontology\",\n \"get_observation_context\",\n \"ingest_observation\",\n \"merge\",\n] as const;\n\nexport const MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES = [\n \"create_lens\",\n \"create_ontology\",\n \"update_ontology\",\n \"archive_ontology\",\n \"create_ontology_version\",\n] as const;\n\nexport const MCP_GOVERNANCE_TENANT_OPERATION_NAMES = [\n \"create_epistemic_contract\",\n \"evaluate_contract\",\n \"get_contract_status\",\n \"publish_ontology_version\",\n \"deprecate_ontology_version\",\n \"manage_write_policy\",\n] as const;\n\nexport const MCP_AUTOMATION_OPERATION_NAMES = [\n \"apply_auto_branching\",\n \"trigger_belief_review\",\n] as const;\n\nexport const DUPLICATE_OPERATION_NAMES = [\n \"link_evidence\",\n] as const;\n\nexport const PLATFORM_PUBLIC_OPERATION_NAMES = [\n ...MCP_CORE_OPERATION_NAMES,\n ...MCP_ANALYSIS_PLATFORM_OPERATION_NAMES,\n ...MCP_WORKFLOW_PLATFORM_OPERATION_NAMES,\n ...MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES,\n ...DUPLICATE_OPERATION_NAMES,\n] as const;\n\nexport const TENANT_PUBLIC_OPERATION_NAMES = [\n ...MCP_ANALYSIS_TENANT_OPERATION_NAMES,\n ...MCP_WORKFLOW_TENANT_OPERATION_NAMES,\n ...MCP_GOVERNANCE_TENANT_OPERATION_NAMES,\n ...MCP_AUTOMATION_OPERATION_NAMES,\n] as const;\n\nexport const PLATFORM_INTERNAL_OPERATION_NAMES = [\n \"register_session\",\n \"heartbeat_session\",\n \"end_session\",\n \"list_active_sessions\",\n \"send_agent_message\",\n \"broadcast_message\",\n \"get_agent_inbox\",\n \"claim_files\",\n \"generate_session_handoff\",\n \"record_scope_learning\",\n \"pipeline_snapshot\",\n \"seed_belief_lattice\",\n \"get_lattice_coverage\",\n \"get_code_context\",\n \"get_change_history\",\n \"get_failure_log\",\n \"record_attempt\",\n \"begin_build_session\",\n \"push\",\n \"open_pull_request\",\n \"record_judgment\",\n \"get_audit_trail\",\n] as const;\n\nexport const LEGACY_COMPAT_OPERATION_NAMES = [\n \"discover\",\n \"add_evidence\",\n \"answer_question\",\n \"get_confidence_history\",\n] as const;\n\nexport const SDK_ONLY_OPERATION_NAMES = [\n \"start_worktree\",\n \"update_worktree_phase\",\n \"advance_worktree_phase\",\n \"add_note_to_worktree\",\n \"link_document_to_worktree\",\n \"link_evidence_to_worktree\",\n \"link_question_to_worktree\",\n \"link_belief_to_worktree\",\n \"create_synthesized_belief\",\n \"complete_hypothesis_formation\",\n \"complete_evidence_review\",\n \"refine_worktree_belief\",\n \"trace_provenance\",\n \"get_belief_relationships\",\n \"get_belief_support_chain\",\n \"explore_connections\",\n \"get_deep_lineage\",\n \"graph_aware_search\",\n \"get_collection_conviction\",\n \"get_conviction_trend\",\n \"analyze_belief_criticality\",\n \"analyze_belief_cluster_candidates\",\n \"create_belief_conditional\",\n \"get_necessary_evidence\",\n \"analyze_reasoning_depth\",\n \"get_evidence_by_methodology\",\n \"create_evidence_task\",\n \"get_task_counts\",\n \"add_research_action\",\n \"get_predictions\",\n \"get_surprise_detection\",\n \"get_challenged_beliefs\",\n \"get_causal_chains\",\n \"get_non_consensus_beliefs\",\n \"get_beliefs_by_epistemic_status\",\n \"detect_anchoring_bias\",\n \"detect_source_concentration\",\n \"find_soft_contradictions\",\n \"find_semantic_bridges\",\n \"find_semantic_orphans\",\n] as const;\n\nexport const MCP_ONLY_INTERNAL_OPERATION_NAMES = [\n \"evaluate_engineering_contract\",\n \"evaluate_research_contract\",\n] as const;\n\nexport const FORBIDDEN_APPLICATION_OPERATION_NAMES = [\n \"execute_deep_research\",\n \"search_sources\",\n \"search_resources\",\n \"get_privileged_evidence\",\n \"get_privileged_signals\",\n \"get_thesis_artifacts\",\n] as const;\n\nexport const LUCERN_OPERATION_MANIFEST = {\n ...entries(\n MCP_CORE_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_core\",\n publicEverywhere,\n \"Default conversational Lucern MCP primitive for reading, writing, and shaping the reasoning graph.\"\n ),\n ...entries(\n MCP_ANALYSIS_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"High-signal graph analysis operation that belongs in chat/MCP because users naturally ask for gaps, contradictions, lineage, and coverage.\"\n ),\n ...entries(\n MCP_ANALYSIS_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"Tenant-scoped analysis operation that remains MCP-visible because agents can answer graph-quality and impact questions from chat.\"\n ),\n ...entries(\n MCP_WORKFLOW_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_workflow\",\n publicEverywhere,\n \"Workflow operation expected by coding agents and human MCP users managing Lucern worktrees, tasks, lenses, and observations.\"\n ),\n ...entries(\n MCP_WORKFLOW_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_workflow\",\n publicEverywhere,\n \"Tenant-scoped workflow operation expected by coding agents and human MCP users managing observations and worktree lifecycle.\"\n ),\n ...entries(\n MCP_AUTOMATION_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"Tenant-scoped automation that remains MCP-visible because agents can explicitly request review or branching assistance.\"\n ),\n ...entries(\n MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_governance\",\n publicWithInternalMcp,\n \"Governance/admin operation. SDK, REST, and CLI remain public, but MCP is internal by default to keep chat surfaces focused.\"\n ),\n ...entries(\n MCP_GOVERNANCE_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_governance\",\n publicWithInternalMcp,\n \"Governance/admin operation. SDK, REST, and CLI remain public, but MCP is internal by default to keep chat surfaces focused.\"\n ),\n ...entries(\n DUPLICATE_OPERATION_NAMES,\n \"platform_public\",\n \"compatibility\",\n publicWithoutMcp,\n \"Duplicate compatibility operation kept for SDK/REST callers, removed from MCP/CLI discovery in favor of the canonical specific tool.\"\n ),\n ...entries(\n PLATFORM_INTERNAL_OPERATION_NAMES,\n \"platform_internal\",\n \"system\",\n internalSystem,\n \"Lucern system/background operation. Available to platform code paths, hidden from public MCP discovery.\"\n ),\n append_sl_scoring: {\n name: \"append_sl_scoring\",\n surfaceClass: \"platform_internal\",\n surfaceIntent: \"system\",\n surfaces: internalSdkRestOnly,\n rationale:\n \"Internal SL scoring append primitive. Public callers attach evidence or contradiction relations; confidence is derived algorithmically.\",\n },\n ...entries(\n LEGACY_COMPAT_OPERATION_NAMES,\n \"legacy_compat\",\n \"compatibility\",\n publicWithoutMcp,\n \"Temporary compatibility operation. Must name a canonical replacement before removal.\"\n ),\n ...entries(\n SDK_ONLY_OPERATION_NAMES,\n \"tenant_public\",\n \"sdk_granular\",\n sdkOnlyPublic,\n \"Granular Lucern SDK operation. Not an MCP, REST, or CLI tool until backed by the generated function pipe.\"\n ),\n ...entries(\n MCP_ONLY_INTERNAL_OPERATION_NAMES,\n \"platform_internal\",\n \"system\",\n mcpOnlyInternal,\n \"Lucern MCP-only platform operation for local agent/bootstrap or verification workflows. Hidden from public discovery.\"\n ),\n} as const satisfies Record<string, LucernOperationManifestEntry>;\n\nexport type LucernOperationName = keyof typeof LUCERN_OPERATION_MANIFEST;\n\nexport function surfaceEnabled(exposure: SurfaceExposure): boolean {\n return exposure !== \"none\";\n}\n\nexport function surfaceIntentGateViolations(\n entry: LucernOperationManifestEntry\n): string[] {\n const violations: string[] = [];\n if (entry.surfaceIntent === \"system\" && entry.surfaces.mcp === \"public\") {\n violations.push(\"system operations cannot be public MCP tools\");\n }\n if (\n entry.surfaceIntent === \"compatibility\" &&\n entry.surfaces.mcp !== \"none\"\n ) {\n violations.push(\"compatibility operations must not be MCP tools\");\n }\n if (entry.surfaceIntent === \"sdk_granular\" && entry.surfaces.mcp !== \"none\") {\n violations.push(\"SDK-granular operations must not be MCP tools\");\n }\n if (\n entry.surfaceIntent === \"mcp_governance\" &&\n entry.surfaces.mcp === \"public\"\n ) {\n violations.push(\"governance operations must be internal or absent from MCP\");\n }\n return violations;\n}\n","/**\n * Shared schema enums referenced by the initial table manifest.\n */\n\nimport { z } from 'zod';\n\nexport const NODE_TYPE = z.enum([\"decision\", \"belief\", \"question\", \"theme\", \"deal\", \"topic\", \"claim\", \"evidence\", \"synthesis\", \"answer\", \"atomic_fact\", \"excerpt\", \"source\", \"company\", \"person\", \"investor\", \"function\", \"value_chain\"]);\n\nexport const EDGE_TYPE_VALUES = [\"supports\", \"informs\", \"depends_on\", \"derived_from\", \"contains\", \"tests\", \"supersedes\", \"responds_to\", \"belongs_to\", \"relates_to_thesis\", \"works_at\", \"invested_in\", \"competes_with\", \"participates_in\", \"founded_by\", \"evaluates\", \"performs\", \"function_in\", \"impacts\", \"raised_from\", \"mentioned_in\", \"perspective_on\", \"plays_theme\", \"answers\", \"explores\", \"qualifies\", \"based_on\", \"based_on_belief\", \"based_on_question\", \"blocked_by_contradiction\", \"informed_by_theme\", \"same_as\", \"reinforces\", \"parent_of\", \"child_of\", \"falsified_by\", \"exclusive_with\", \"collapses_if\", \"cascade_from\", \"counterfactual_of\", \"cascade_to\", \"mutually_exclusive\", \"correlates_with\", \"amplifies\", \"precondition_for\", \"in_tension_with\", \"strengthened_by\", \"weakened_by\", \"alternative_to\", \"subsumes\", \"validated_by\", \"required_for\", \"blocks\", \"prerequisite_for\", \"parallel_to\", \"corroborates\", \"extends\", \"same_source_as\", \"same_theme_as\", \"assumes\", \"would_predict\", \"analogous_to\", \"independent_of\", \"implements\", \"violates\", \"co_changes_with\", \"migrating_from\", \"migrating_to\", \"scoped_by\", \"about_entity\", \"entity_referenced_in\", \"contradicts\", \"cites\", \"summarizes\", \"related_to\", \"partially_answers\", \"refines\", \"branches_from\"] as const;\n\nexport const STORAGE_EDGE_TYPE_VALUES = [...EDGE_TYPE_VALUES, \"extracted_from\"] as const;\n\nexport const EDGE_TYPE = z.enum(EDGE_TYPE_VALUES);\n\n// Storage accepts the legacy provenance spelling while existing rows migrate.\n// Public surfaces should continue to expose EDGE_TYPE only.\nexport const STORAGE_EDGE_TYPE = z.enum(STORAGE_EDGE_TYPE_VALUES);\n\nexport const TOPIC_STATUS = z.enum([\"active\", \"archived\", \"watching\"]);\n\nexport const TOPIC_VISIBILITY = z.enum([\"private\", \"team\", \"firm\", \"external\", \"public\"]);\n","import { z } from \"zod\";\nimport type { FunctionEffect } from \"../dsl/defineFunction.js\";\nimport { encodePrefixedId } from \"../ids.contract.js\";\nimport type { McpParameterDef, McpToolContract } from \"../tool-contracts.js\";\nimport { MCP_TOOL_CONTRACTS } from \"../tool-contracts.js\";\nimport type {\n ContractProjectionContext,\n FunctionContract,\n SurfaceClass,\n} from \"./types.js\";\nimport {\n LUCERN_OPERATION_MANIFEST,\n type LucernOperationManifestEntry,\n} from \"./manifest.js\";\nexport { NODE_TYPE } from \"../schemas/enums.js\";\n\nexport const jsonObjectSchema = z.record(z.unknown());\nconst sdkSessionIdSchema = z.string().optional();\n\nexport function publicPrefixedId(prefix: string, rawId: string): string {\n return rawId.startsWith(`${prefix}_`) ? rawId : encodePrefixedId(prefix, rawId);\n}\n\nfunction mcpContractShape(contract: McpToolContract): z.ZodRawShape {\n const required = new Set(contract.required);\n return Object.fromEntries(\n Object.entries(contract.parameters).map(([name, parameter]) => {\n const schema = schemaForMcpParameter(parameter);\n return [\n name,\n required.has(name) || parameter.required ? schema : schema.optional(),\n ];\n }),\n );\n}\n\nfunction schemaForMcpParameter(parameter: McpParameterDef): z.ZodTypeAny {\n if (parameter.enum && parameter.enum.length > 0) {\n const [first, ...rest] = parameter.enum;\n return z.enum([first, ...rest] as [string, ...string[]]);\n }\n\n switch (parameter.type) {\n case \"array\":\n return z.array(z.unknown());\n case \"boolean\":\n return z.boolean();\n case \"number\":\n return z.number();\n case \"object\":\n return z.record(z.unknown());\n case \"string\":\n return z.string();\n }\n}\n\nexport function argsSchemaFromMcpContract(\n contract: McpToolContract,\n): z.ZodObject<z.ZodRawShape> {\n return z.object(mcpContractShape(contract));\n}\n\nexport function inputSchemaFromMcpContract(\n contract: McpToolContract,\n): z.ZodObject<z.ZodRawShape> {\n return withInternalSurfaceFields(argsSchemaFromMcpContract(contract));\n}\n\n// Backward compatibility helper: public contract builders still reserve the\n// internal SDK session field on object-shaped inputs.\nfunction withInternalSurfaceFields(\n schema: z.ZodObject<z.ZodRawShape>,\n): z.ZodObject<z.ZodRawShape> {\n return schema.extend({ __sdkSessionId: sdkSessionIdSchema }).strict();\n}\n\nfunction normalizeInputSchema(schema: z.ZodTypeAny): z.ZodTypeAny {\n if (schema instanceof z.ZodObject) {\n return withInternalSurfaceFields(schema);\n }\n return schema;\n}\n\nfunction unwrapObjectSchema(\n schema: z.ZodTypeAny,\n): z.ZodObject<z.ZodRawShape> | undefined {\n let current = schema;\n while (true) {\n switch (current._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodEffects:\n current = current._def.schema;\n continue;\n case z.ZodFirstPartyTypeKind.ZodBranded:\n current = current._def.type;\n continue;\n default:\n return current instanceof z.ZodObject ? current : undefined;\n }\n }\n}\n\nfunction getObjectShape(schema: z.ZodTypeAny) {\n const objectSchema = unwrapObjectSchema(schema);\n if (!objectSchema) {\n throw new Error(\n `Expected a Zod object schema, received ${schema._def.typeName}.`,\n );\n }\n const shape =\n typeof objectSchema._def.shape === \"function\"\n ? objectSchema._def.shape()\n : objectSchema._def.shape;\n return shape as z.ZodRawShape;\n}\n\nfunction unwrapMcpParameterSchema(schema: z.ZodTypeAny): {\n schema: z.ZodTypeAny;\n required: boolean;\n description?: string;\n} {\n let current = schema;\n let required = true;\n let description = schema.description;\n\n while (true) {\n description ??= current.description;\n\n switch (current._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodOptional:\n case z.ZodFirstPartyTypeKind.ZodDefault:\n required = false;\n current = current._def.innerType;\n continue;\n case z.ZodFirstPartyTypeKind.ZodNullable:\n current = current._def.innerType;\n continue;\n case z.ZodFirstPartyTypeKind.ZodBranded:\n current = current._def.type;\n continue;\n case z.ZodFirstPartyTypeKind.ZodEffects:\n current = current._def.schema;\n continue;\n default:\n return {\n schema: current,\n required,\n description: description ?? current.description,\n };\n }\n }\n}\n\nfunction mcpParameterFromZod(\n fieldName: string,\n schema: z.ZodTypeAny,\n contractName: string,\n): { parameter: McpParameterDef; required: boolean } {\n const {\n schema: unwrapped,\n required,\n description: schemaDescription,\n } = unwrapMcpParameterSchema(schema);\n const description = schemaDescription ?? unwrapped.description ?? fieldName;\n\n switch (unwrapped._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodString:\n return { parameter: { type: \"string\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodNumber:\n return { parameter: { type: \"number\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodBoolean:\n return { parameter: { type: \"boolean\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodArray:\n return { parameter: { type: \"array\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodObject:\n case z.ZodFirstPartyTypeKind.ZodRecord:\n case z.ZodFirstPartyTypeKind.ZodDiscriminatedUnion:\n return { parameter: { type: \"object\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodEnum:\n return {\n parameter: {\n type: \"string\",\n description,\n enum: [...unwrapped._def.values],\n },\n required,\n };\n case z.ZodFirstPartyTypeKind.ZodLiteral:\n if (typeof unwrapped._def.value === \"string\") {\n return {\n parameter: {\n type: \"string\",\n description,\n enum: [unwrapped._def.value],\n },\n required,\n };\n }\n break;\n }\n\n throw new Error(\n `Function surface contract ${contractName}.${fieldName} cannot be lowered to an MCP parameter from ${unwrapped._def.typeName}.`,\n );\n}\n\nfunction mcpContractFromArgsSchema(\n base: FunctionContract[\"mcp\"],\n args: z.ZodTypeAny,\n contractName: string,\n): FunctionContract[\"mcp\"] {\n const entries = Object.entries(getObjectShape(args)).sort(([left], [right]) =>\n left.localeCompare(right),\n );\n const converted = entries.map(\n ([fieldName, schema]) =>\n [\n fieldName,\n mcpParameterFromZod(fieldName, schema, contractName),\n ] as const,\n );\n\n return {\n ...base,\n parameters: Object.fromEntries(\n converted.map(([fieldName, field]) => [fieldName, field.parameter]),\n ),\n required: converted\n .filter(([, field]) => field.required)\n .map(([fieldName]) => fieldName),\n };\n}\n\nexport const defineFunctionContract = <T extends FunctionContract>(\n contract: T,\n): T => contract;\n\nexport function classifyContract<\n T extends Omit<FunctionContract, \"surfaceClass\"> & {\n surfaceClass?: SurfaceClass;\n },\n>(contract: T, surfaceClass: SurfaceClass): T & { surfaceClass: SurfaceClass } {\n return {\n ...contract,\n surfaceClass: contract.surfaceClass ?? surfaceClass,\n };\n}\n\nexport function authUserId(context: ContractProjectionContext): string {\n return context.userId ?? context.principalId ?? \"lucern-agent\";\n}\n\nexport function withUserId(\n input: Record<string, unknown>,\n context: ContractProjectionContext,\n): Record<string, unknown> {\n return {\n ...input,\n userId:\n typeof input.userId === \"string\" ? input.userId : authUserId(context),\n };\n}\n\nexport function withCreatedBy(\n input: Record<string, unknown>,\n context: ContractProjectionContext,\n): Record<string, unknown> {\n return {\n ...input,\n createdBy:\n typeof input.createdBy === \"string\"\n ? input.createdBy\n : authUserId(context),\n };\n}\n\nexport function compactRecord(\n input: Record<string, unknown>,\n): Record<string, unknown> {\n return Object.fromEntries(\n Object.entries(input).filter(([, value]) => value !== undefined),\n );\n}\n\nexport function recordValue(value: unknown): Record<string, unknown> {\n return value && typeof value === \"object\" && !Array.isArray(value)\n ? (value as Record<string, unknown>)\n : {};\n}\n\nexport function surfaceMcpContract(name: string): FunctionContract[\"mcp\"] {\n const contract = MCP_TOOL_CONTRACTS[name];\n if (!contract) {\n throw new Error(\n `Function surface contract ${name} is missing from MCP_TOOL_CONTRACTS.`,\n );\n }\n\n return {\n ...contract,\n exposed: true,\n toolName: contract.name,\n };\n}\n\nfunction deriveFunctionEffects(args: {\n kind: FunctionContract[\"kind\"];\n domain: string;\n surfaceIntent: FunctionContract[\"surfaceIntent\"];\n}): readonly FunctionEffect[] {\n if (args.kind === \"query\") {\n return [\"read\"];\n }\n\n if (\n args.surfaceIntent === \"system\" ||\n args.surfaceIntent === \"mcp_governance\" ||\n args.domain === \"identity\" ||\n args.domain === \"contracts\" ||\n args.domain === \"coordination\" ||\n args.domain === \"pipeline\"\n ) {\n return [\"admin\"];\n }\n\n return [\"write\"];\n}\n\nexport function surfaceContract(args: {\n name: string;\n kind: FunctionContract[\"kind\"];\n domain: string;\n surfaceClass: SurfaceClass;\n method?: FunctionContract[\"rest\"][\"method\"];\n path: string;\n sdkNamespace: string;\n sdkMethod: string;\n summary: string;\n tags?: string[];\n scopes?: string[];\n replacedBy?: string;\n idempotent?: FunctionContract[\"idempotent\"];\n convex?: FunctionContract[\"convex\"];\n gateway?: FunctionContract[\"gateway\"];\n args?: z.ZodTypeAny;\n returns?: z.ZodTypeAny;\n input?: z.ZodTypeAny;\n output?: z.ZodTypeAny;\n effects?: readonly FunctionEffect[];\n invariants?: readonly string[];\n}) {\n const manifest = LUCERN_OPERATION_MANIFEST as Record<\n string,\n LucernOperationManifestEntry | undefined\n >;\n const manifestEntry = manifest[args.name];\n if (!manifestEntry) {\n throw new Error(\n `Function surface contract ${args.name} is not in LUCERN_OPERATION_MANIFEST.`,\n );\n }\n if (manifestEntry.surfaceClass !== args.surfaceClass) {\n throw new Error(\n `Function surface contract ${args.name} is classified as ${args.surfaceClass}, but manifest requires ${manifestEntry.surfaceClass}.`,\n );\n }\n if (\n manifestEntry.surfaces.sdk === \"none\" &&\n manifestEntry.surfaces.rest === \"none\"\n ) {\n throw new Error(\n `Function surface contract ${args.name} has no SDK or REST exposure in the manifest.`,\n );\n }\n\n const baseMcp = surfaceMcpContract(args.name);\n const canonicalArgs = args.args ?? argsSchemaFromMcpContract(baseMcp);\n const mcp = args.args\n ? mcpContractFromArgsSchema(baseMcp, canonicalArgs, args.name)\n : baseMcp;\n const canonicalReturns = args.returns ?? jsonObjectSchema;\n const input = normalizeInputSchema(\n args.input ?? inputSchemaFromMcpContract(mcp),\n );\n const output = args.output ?? canonicalReturns;\n\n return defineFunctionContract({\n name: args.name,\n kind: args.kind,\n idempotent: args.idempotent ?? (args.kind === \"query\" ? false : true),\n effects:\n args.effects ??\n deriveFunctionEffects({\n kind: args.kind,\n domain: args.domain,\n surfaceIntent: manifestEntry.surfaceIntent,\n }),\n invariants: args.invariants,\n surfaceIntent: manifestEntry.surfaceIntent,\n domain: args.domain,\n surfaceClass: manifestEntry.surfaceClass,\n surfaces: manifestEntry.surfaces,\n replacedBy: args.replacedBy,\n rest: {\n method: args.method ?? \"POST\",\n path: args.path,\n },\n sdk: {\n namespace: args.sdkNamespace,\n method: args.sdkMethod,\n },\n mcp,\n auth: {\n scopes: args.scopes ?? [\n args.kind === \"query\" ? `${args.domain}.read` : `${args.domain}.write`,\n ],\n allowedPrincipalTypes: [\n \"user\",\n \"service\",\n \"agent\",\n \"group\",\n \"external_viewer\",\n ],\n },\n convex: args.convex,\n gateway: args.gateway,\n args: canonicalArgs,\n returns: canonicalReturns,\n input,\n output,\n openapi: {\n summary: args.summary,\n tags: args.tags ?? [args.domain],\n },\n });\n}\n\nexport function assertSurfaceCoverage(contracts: readonly FunctionContract[]) {\n const names = new Set<string>();\n for (const contract of contracts) {\n if (names.has(contract.name)) {\n throw new Error(`Duplicate function contract name: ${contract.name}`);\n }\n names.add(contract.name);\n }\n\n for (const contract of contracts) {\n if (contract.replacedBy && !names.has(contract.replacedBy)) {\n throw new Error(\n `Function contract ${contract.name} replacedBy target ${contract.replacedBy} is not registered.`,\n );\n }\n }\n}\n","import { z } from \"zod\";\nimport {\n compactRecord,\n recordValue,\n surfaceContract,\n withUserId,\n} from \"./helpers.js\";\nimport type { ContractProjectionContext, FunctionContract } from \"./types.js\";\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return Boolean(value) && typeof value === \"object\" && !Array.isArray(value);\n}\n\nfunction stringValues(value: unknown): string[] {\n if (typeof value === \"string\") {\n return [value];\n }\n if (Array.isArray(value)) {\n return value.flatMap((item) => stringValues(item));\n }\n return [];\n}\n\nfunction nestedEvidenceRows(value: unknown): Record<string, unknown>[] {\n if (Array.isArray(value)) {\n return value.flatMap((item) => nestedEvidenceRows(item));\n }\n if (!isRecord(value)) {\n return [];\n }\n\n const nestedKeys = [\"evidence\", \"items\", \"nodes\"];\n const nestedRows = nestedKeys.flatMap((key) => nestedEvidenceRows(value[key]));\n return nestedRows.length > 0 ? nestedRows : [value];\n}\n\nfunction isFailedAttemptRow(row: Record<string, unknown>): boolean {\n const metadata = isRecord(row.metadata) ? row.metadata : null;\n return (\n metadata?.failedApproach === true ||\n metadata?.isFailedAttempt === true\n );\n}\n\nfunction failureLogSearchFields(row: Record<string, unknown>): string[] {\n const metadata = isRecord(row.metadata) ? row.metadata : null;\n return [\n ...stringValues(row.id),\n ...stringValues(row._id),\n ...stringValues(row.title),\n ...stringValues(row.text),\n ...stringValues(row.canonicalText),\n ...stringValues(row.content),\n ...stringValues(metadata?.codeAnchor),\n ...stringValues(metadata?.codeAnchors),\n ...stringValues(metadata?.anchor),\n ...stringValues(metadata?.anchors),\n ...stringValues(metadata?.filePath),\n ...stringValues(metadata?.filePaths),\n ...stringValues(metadata?.path),\n ...stringValues(metadata?.paths),\n ...stringValues(metadata?.sourceRef),\n ...stringValues(metadata?.touchedPaths),\n ];\n}\n\nfunction projectFailureLog(\n output: unknown,\n input: Record<string, unknown>,\n): {\n query?: string;\n failures: Record<string, unknown>[];\n totalFound: number;\n showing: number;\n} {\n const rawQuery =\n typeof input.query === \"string\" && input.query.trim().length > 0\n ? input.query.trim()\n : undefined;\n const searchKey = rawQuery?.toLowerCase();\n const failures = nestedEvidenceRows(output)\n .filter((row) => isFailedAttemptRow(row))\n .filter((row) =>\n !searchKey\n ? true\n : failureLogSearchFields(row).some((field) =>\n field.toLowerCase().includes(searchKey),\n ),\n );\n\n return {\n query: rawQuery,\n failures,\n totalFound: failures.length,\n showing: failures.length,\n };\n}\n\nconst recordScopeLearningArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope ID\"),\n summary: z.string().describe(\"Atomic learning statement\"),\n title: z\n .string()\n .optional()\n .describe(\"Optional evidence title, such as a commit, doc, or issue.\"),\n body: z\n .string()\n .optional()\n .describe(\n \"Optional rich evidence body. If omitted, body is synthesized from summary and touched paths.\"\n ),\n contentType: z\n .string()\n .optional()\n .describe(\"Optional evidence body format, such as markdown or text.\"),\n sourceKind: z\n .enum([\"commit\", \"merge\", \"doc\", \"issue\", \"manual\"])\n .optional()\n .describe(\"Source type for the learning event\"),\n sourceRef: z\n .string()\n .optional()\n .describe(\"Optional source reference, such as SHA, PR number, or URL slug.\"),\n sourceUrl: z.string().optional().describe(\"Optional canonical source URL\"),\n touchedPaths: z\n .array(z.string())\n .optional()\n .describe(\"Optional touched file paths for retrieval hints\"),\n tags: z.array(z.string()).optional().describe(\"Optional tags\"),\n linkedBeliefNodeId: z\n .string()\n .optional()\n .describe(\"Optional belief to attach evidence to\"),\n evidenceRelation: z\n .enum([\"supports\", \"contradicts\"])\n .optional()\n .describe(\"Relation to linked belief\"),\n confidence: z.number().optional().describe(\"Optional confidence in [0,1]\"),\n rationale: z\n .string()\n .optional()\n .describe(\"Why this learning should enter the reasoning graph\"),\n createQuestionText: z\n .string()\n .optional()\n .describe(\"Optional follow-up question text\"),\n createBeliefText: z\n .string()\n .optional()\n .describe(\"Optional new belief text\"),\n beliefType: z\n .string()\n .optional()\n .describe(\"Optional belief type for createBeliefText\"),\n text: z.string().optional().describe(\"Canonical learning text alias.\"),\n content: z\n .string()\n .optional()\n .describe(\"Canonical learning content alias.\"),\n kind: z.string().optional().describe(\"Evidence kind to store.\"),\n sourceType: z.string().optional().describe(\"Evidence source type.\"),\n externalSourceType: z\n .string()\n .optional()\n .describe(\"External source type alias.\"),\n metadata: z.record(z.unknown()).optional().describe(\"Learning metadata.\"),\n});\n\nconst codeContextArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope.\"),\n filePath: z.string().optional().describe(\"File path anchor.\"),\n includeFailures: z\n .boolean()\n .optional()\n .describe(\"Whether to include failed attempts.\"),\n limit: z.number().optional().describe(\"Maximum records to return.\"),\n status: z.string().optional().describe(\"Evidence status filter.\"),\n});\n\nconst recordAttemptArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope.\"),\n description: z.string().describe(\"Attempt description.\"),\n errorMessage: z.string().optional().describe(\"Failure or error message.\"),\n filePaths: z\n .array(z.string())\n .optional()\n .describe(\"Files involved in the attempt.\"),\n filePath: z.string().optional().describe(\"Single file path alias.\"),\n linkedBeliefId: z.string().optional().describe(\"Linked belief ID.\"),\n metadata: z.record(z.unknown()).optional().describe(\"Attempt metadata.\"),\n rationale: z\n .string()\n .optional()\n .describe(\"Why this attempt should be recorded.\"),\n title: z.string().optional().describe(\"Attempt evidence title.\"),\n});\n\nconst learningInput = (\n input: Record<string, unknown>,\n context: ContractProjectionContext\n) => {\n const sourceKind = input.sourceKind ?? input.externalSourceType;\n return withUserId(\n compactRecord({\n projectId: input.projectId,\n topicId: input.topicId,\n text: input.summary ?? input.text,\n title: input.title ?? input.summary ?? \"Scope learning\",\n content: input.body ?? input.content ?? input.summary,\n contentType: input.contentType,\n kind: input.kind ?? \"learning\",\n tags: input.tags ?? [],\n sourceType: input.sourceType,\n externalSourceType: input.externalSourceType ?? input.sourceKind,\n sourceUrl: input.sourceUrl,\n metadata: compactRecord({\n ...recordValue(input.metadata),\n sourceRef: input.sourceRef,\n sourceKind,\n touchedPaths: input.touchedPaths,\n createQuestionText: input.createQuestionText,\n createBeliefText: input.createBeliefText,\n beliefType: input.beliefType,\n }),\n linkedBeliefNodeId: input.linkedBeliefNodeId,\n evidenceRelation: input.evidenceRelation,\n confidence: input.confidence,\n rationale:\n input.rationale ??\n input.reasoning ??\n input.summary ??\n input.text ??\n \"Recorded scope learning\",\n trustedBypassAccessCheck: input.trustedBypassAccessCheck ?? true,\n }),\n context\n );\n};\n\nconst attemptInput = (\n input: Record<string, unknown>,\n context: ContractProjectionContext\n) =>\n withUserId(\n compactRecord({\n projectId: input.projectId,\n topicId: input.topicId,\n text: input.description,\n title: input.title ?? input.description,\n content: input.errorMessage ?? input.description,\n kind: \"code_attempt\",\n tags: [\"code_attempt\"],\n metadata: compactRecord({\n ...recordValue(input.metadata),\n failedApproach: true,\n isFailedAttempt: true,\n filePaths: input.filePaths,\n filePath: input.filePath,\n errorMessage: input.errorMessage,\n linkedBeliefId: input.linkedBeliefId,\n }),\n rationale:\n input.rationale ??\n input.reasoning ??\n input.errorMessage ??\n input.description ??\n \"Recorded implementation attempt\",\n trustedBypassAccessCheck: input.trustedBypassAccessCheck ?? true,\n }),\n context\n );\n\nexport const codingContracts = [\n surfaceContract({\n name: \"record_scope_learning\",\n kind: \"mutation\",\n domain: \"scope\",\n surfaceClass: \"platform_internal\",\n path: \"/scope/learnings\",\n sdkNamespace: \"context\",\n sdkMethod: \"recordScopeLearning\",\n summary: \"Record a scope-level learning to the reasoning graph.\",\n args: recordScopeLearningArgs,\n input: recordScopeLearningArgs,\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: learningInput,\n },\n }),\n surfaceContract({\n name: \"manage_write_policy\",\n kind: \"mutation\",\n domain: \"policy\",\n surfaceClass: \"tenant_public\",\n path: \"/policy/write-policy/manage\",\n sdkNamespace: \"policy\",\n sdkMethod: \"manageWritePolicy\",\n summary: \"Manage MCP write policy rules.\",\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: (input, context) =>\n learningInput(\n {\n ...input,\n summary:\n input.summary ??\n `Write policy ${String(input.action ?? \"update\")}`,\n sourceKind: \"write_policy\",\n },\n context\n ),\n },\n }),\n surfaceContract({\n name: \"get_code_context\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/context\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getCodeContext\",\n summary: \"Read code context for graph-linked files.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n },\n args: codeContextArgs,\n }),\n surfaceContract({\n name: \"get_change_history\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/change-history\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getChangeHistory\",\n summary: \"Read recorded code change attempts.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n },\n }),\n surfaceContract({\n name: \"record_attempt\",\n kind: \"mutation\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/attempts\",\n sdkNamespace: \"coding\",\n sdkMethod: \"recordAttempt\",\n summary: \"Record a code attempt for failure learning.\",\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: attemptInput,\n },\n args: recordAttemptArgs,\n }),\n surfaceContract({\n name: \"get_failure_log\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/failure-log\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getFailureLog\",\n summary: \"Read code failure log entries.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId ?? input.query,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n outputProjection: (output, input) => projectFailureLog(output, input),\n },\n }),\n] as const satisfies readonly FunctionContract[];\n"]}
1
+ {"version":3,"sources":["../../src/ids/index.ts","../../src/tool-contracts.lifecycle.ts","../../src/tool-contracts.worktrees.ts","../../src/types/reasoning-method.ts","../../src/tool-contracts.graph.ts","../../src/tool-contracts.embeddings.ts","../../src/tool-contracts.hybrid-discovery.ts","../../src/lens-workflow.contract.ts","../../src/tool-contracts.nodes-lenses.ts","../../src/tool-contracts.context-orientation.ts","../../src/tool-contracts.intelligence-evidence.ts","../../src/tool-contracts.questions-listing.ts","../../src/tool-contracts.policy-observation-task-topic.ts","../../src/tool-contracts.ontology.ts","../../src/tool-contracts.pipeline-coordination.ts","../../src/tool-contracts.ts","../../src/function-registry/manifest.ts","../../src/schemas/enums.ts","../../src/function-registry/helpers.ts","../../src/function-registry/coding.ts"],"names":["z","entries"],"mappings":";;;;;AAGA,IAAM,YAAA,GACJ,uEAAA;AAmCK,SAAS,SAAS,KAAA,EAAwB;AAC/C,EAAA,OAAO,YAAA,CAAa,KAAK,KAAK,CAAA,IAAK,MAAM,EAAE,CAAA,EAAG,aAAY,KAAM,GAAA;AAClE;;;ACvCO,IAAM,aAAA,GAAiC;AAAA,EAC5C,IAAA,EAAM,eAAA;AAAA,EACN,WAAA,EACE,qdAAA;AAAA,EAIF,UAAA,EAAY;AAAA,IACV,aAAA,EAAe;AAAA,MACb,IAAA,EAAM,QAAA;AAAA,MACN,WAAA,EAAa;AAAA,KACf;AAAA,IACA,aAAA,EAAe;AAAA,MACb,IAAA,EAAM,QAAA;AAAA,MACN,WAAA,EACE;AAAA,KACJ;AAAA,IACA,QAAA,EAAU;AAAA,MACR,IAAA,EAAM,QAAA;AAAA,MACN,WAAA,EACE;AAAA,KACJ;AAAA,IACA,UAAA,E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SAAA,EAAW,eAAA;AAAA,IACX,OAAA,EAAS,gCAAA;AAAA,IACT,MAAA,EAAQ;AAAA,MACN,MAAA,EAAQ,UAAA;AAAA,MACR,YAAA,EAAc,YAAA;AAAA,MACd,IAAA,EAAM,OAAA;AAAA,MACN,eAAA,EAAiB,CAAC,KAAA,KAChB,aAAA,CAAc;AAAA,QACZ,OAAA,EAAS,KAAA,CAAM,OAAA,IAAW,KAAA,CAAM,KAAA;AAAA,QAChC,OAAO,KAAA,CAAM,KAAA;AAAA,QACb,QAAQ,KAAA,CAAM,MAAA;AAAA,QACd,QAAQ,KAAA,CAAM;AAAA,OACf,CAAA;AAAA,MACH,kBAAkB,CAAC,MAAA,EAAQ,KAAA,KAAU,iBAAA,CAAkB,QAAQ,KAAK;AAAA;AACtE,GACD;AACH","file":"coding.js","sourcesContent":["export * from \"./public-uuid-resolver.js\";\nexport * from \"./uuid-edge-spine.js\";\n\nconst UUID_PATTERN =\n /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;\n\nfunction formatUuid(bytes: Uint8Array): string {\n const hex = Array.from(bytes, (byte) => byte.toString(16).padStart(2, \"0\")).join(\n \"\",\n );\n return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-${hex.slice(12, 16)}-${hex.slice(16, 20)}-${hex.slice(20)}`;\n}\n\nfunction timestampByte(nowMs: number, byteIndex: number): number {\n return Math.floor(nowMs / 2 ** (8 * (5 - byteIndex))) % 256;\n}\n\nexport function generateUuidV7(nowMs = Date.now()): string {\n if (!Number.isInteger(nowMs) || nowMs < 0 || nowMs > 0xffffffffffff) {\n throw new Error(\"UUIDv7 timestamp must be an integer Unix millisecond value below 2^48.\");\n }\n\n const bytes = new Uint8Array(16);\n crypto.getRandomValues(bytes);\n bytes[0] = timestampByte(nowMs, 0);\n bytes[1] = timestampByte(nowMs, 1);\n bytes[2] = timestampByte(nowMs, 2);\n bytes[3] = timestampByte(nowMs, 3);\n bytes[4] = timestampByte(nowMs, 4);\n bytes[5] = timestampByte(nowMs, 5);\n bytes[6] = (bytes[6] & 0x0f) | 0x70;\n bytes[8] = (bytes[8] & 0x3f) | 0x80;\n return formatUuid(bytes);\n}\n\nexport function generateGlobalId(): string {\n return generateUuidV7();\n}\n\nexport function isUuidV7(value: string): boolean {\n return UUID_PATTERN.test(value) && value[14]?.toLowerCase() === \"7\";\n}\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CREATE_BELIEF: McpToolContract = {\n name: \"create_belief\",\n description:\n \"Commit a new belief (knowledge unit) to the reasoning graph. \" +\n \"Like `git commit` — creates an atomic, traceable knowledge object with a prior. \" +\n \"Creation requires a topic epistemic-node anchor and writes a `belongs_to` edge directly from belief node to topic node; orphan beliefs are invalid. \" +\n \"Creation stores the vacuous opinion `(0, 0, 1, a)`; attach supporting or contradicting evidence with create_evidence or link_evidence_to_belief to record evidential updates.\",\n parameters: {\n canonicalText: {\n type: \"string\",\n description: \"The belief statement — what the agent holds to be true\",\n },\n topicGlobalId: {\n type: \"string\",\n description:\n \"Required UUIDv7 globalId of the topic node in epistemicNodes that anchors the belief. Legacy topics-table ids, Convex storage locators, and UUIDv4 values are refused.\",\n },\n baseRate: {\n type: \"number\",\n description:\n \"Prior probability used to seed the vacuous opinion `(0, 0, 1, a)` at creation time. Defaults to 0.5 when omitted.\",\n },\n beliefType: {\n type: \"string\",\n description:\n \"Belief type (e.g., hypothesis, belief, principle, invariant, tenet, forecast). Validated against schemaEnumConfig.\",\n },\n metadata: {\n type: \"object\",\n description:\n \"Optional extra metadata merged into the node (e.g., { codeAnchors: ['path/to/file.ts'] } for coding intelligence)\",\n },\n },\n required: [\"canonicalText\", \"topicGlobalId\"],\n response: {\n description: \"The created canonical belief record\",\n fields: {\n id: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n beliefId: \"string — canonical belief ID\",\n text: \"string — canonical belief formulation\",\n topicId: \"string\",\n beliefStatus:\n \"string — assumption | hypothesis | active | superseded | resolved_true | resolved_false\",\n scoringState: \"string — unscored | scored\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const GET_BELIEF: McpToolContract = {\n name: \"get_belief\",\n description:\n \"Read one belief by ID. \" +\n \"Like `git show` — resolves the canonical belief payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical belief ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical belief record\",\n fields: {\n id: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n beliefId: \"string — canonical belief ID\",\n text: \"string — canonical belief formulation\",\n topicId: \"string\",\n beliefStatus:\n \"string — assumption | hypothesis | active | superseded | resolved_true | resolved_false\",\n scoringState: \"string — unscored | scored\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const REFINE_BELIEF: McpToolContract = {\n name: \"refine_belief\",\n description:\n \"Amend a draft belief in-place within an active worktree. \" +\n \"Like `git commit --amend` — rewrites the last commit on a feature branch. \" +\n \"Only valid before merge to main. Fails if the belief is already scored.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to refine\" },\n canonicalText: { type: \"string\", description: \"Updated belief statement\" },\n rationale: { type: \"string\", description: \"Why the refinement was made\" },\n },\n required: [\"nodeId\", \"canonicalText\"],\n response: {\n description: \"The updated belief node\",\n fields: {\n nodeId: \"string\",\n canonicalText: \"string — updated text\",\n updatedAt: \"number — timestamp\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const APPEND_SL_SCORING: McpToolContract = {\n name: \"append_sl_scoring\",\n description:\n \"Internal evidence-backed Subjective Logic scoring append. \" +\n \"This is not a public MCP tool: callers should attach supporting or contradicting evidence, and governed system paths append the derived SL tuple.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief receiving the SL score\" },\n belief: { type: \"number\", description: \"Subjective Logic belief mass b\" },\n disbelief: {\n type: \"number\",\n description: \"Subjective Logic disbelief mass d\",\n },\n uncertainty: {\n type: \"number\",\n description: \"Subjective Logic uncertainty mass u\",\n },\n baseRate: { type: \"number\", description: \"Subjective Logic base rate a\" },\n trigger: {\n type: \"string\",\n description: \"Evidence-bearing cause of the scoring event\",\n enum: [\n \"evidence_added\",\n \"evidence_removed\",\n \"contradiction_detected\",\n \"contradiction_resolved\",\n \"agent_assessment\",\n \"worktree_outcome\",\n \"worktree_completed\",\n \"fusion\",\n \"discount\",\n \"deduction\",\n \"backfill_synthetic\",\n ],\n },\n provenance: {\n type: \"object\",\n description:\n \"At least one of evidence, question, answer, contradiction, or worktree.\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this evidence-bearing event moved the SL tuple\",\n },\n },\n required: [\"nodeId\", \"belief\", \"disbelief\", \"uncertainty\", \"baseRate\", \"trigger\", \"rationale\"],\n response: {\n description: \"Internal SL scoring append receipt\",\n fields: {\n nodeId: \"string\",\n previousConfidence: \"number\",\n newConfidence: \"number\",\n beliefConfidenceId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const FORK_BELIEF: McpToolContract = {\n name: \"fork_belief\",\n description:\n \"Branch off an evidence-bearing belief to create a new formulation. \" +\n \"Like `git fork` — the parent remains immutable with full history, and every fork must cite evidence already attached to the parent through SL scoring. \" +\n \"`forkMode=supersede` marks the parent superseded and requires contradicting evidence; `forkMode=branch` preserves the parent and creates a derived child.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to fork from\" },\n newFormulation: {\n type: \"string\",\n description: \"The evolved belief statement\",\n },\n forkReason: {\n type: \"string\",\n description: \"Why this fork was created\",\n enum: [\n \"refinement\",\n \"contradiction_response\",\n \"scope_change\",\n \"confidence_collapse\",\n ],\n },\n forkMode: {\n type: \"string\",\n description:\n \"supersede replaces the parent; branch creates a child while preserving the parent.\",\n enum: [\"supersede\", \"branch\"],\n },\n triggeringEvidenceId: {\n type: \"string\",\n description:\n \"Evidence already attached to the parent belief that caused the fork.\",\n },\n },\n required: [\"nodeId\", \"newFormulation\", \"forkReason\", \"triggeringEvidenceId\"],\n response: {\n description: \"The forked canonical belief record\",\n fields: {\n id: \"string — canonical child belief ID\",\n nodeId: \"string — canonical child belief ID\",\n beliefId: \"string — canonical child belief ID\",\n parentBeliefId: \"string — canonical parent belief ID\",\n forkReason: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const ARCHIVE_BELIEF: McpToolContract = {\n name: \"archive_belief\",\n description:\n \"Soft-delete a belief by setting its status to archived. \" +\n \"Like `git rm` — removed from the working tree but preserved in history. \" +\n \"Beliefs are never truly deleted. Archived beliefs retain full lineage and confidence history.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to archive\" },\n rationale: {\n type: \"string\",\n description: \"Why this belief is being archived\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Archived canonical belief record\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n nodeId: \"string — canonical belief ID\",\n previousStatus: \"string | undefined\",\n newStatus: \"string — 'archived'\",\n status: \"string — 'archived'\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const CREATE_EPISTEMIC_CONTRACT: McpToolContract = {\n name: \"create_epistemic_contract\",\n description:\n \"Bind a machine-evaluable epistemic contract to a belief. \" +\n \"Like `git add` for falsification rules — records the verification condition, modulation policy, \" +\n \"and evaluation schedule that keep a belief accountable to reality.\",\n parameters: {\n beliefNodeId: {\n type: \"string\",\n description: \"The belief node to bind this contract to\",\n },\n title: {\n type: \"string\",\n description: \"Contract title\",\n },\n description: {\n type: \"string\",\n description: \"Optional contract description\",\n },\n conditionType: {\n type: \"string\",\n description: \"What kind of contract condition to evaluate\",\n enum: [\"assertion\", \"temporal\", \"evidential\", \"threshold\", \"composite\"],\n },\n direction: {\n type: \"string\",\n description: \"Whether satisfying the condition confirms or falsifies\",\n enum: [\"confirms\", \"falsifies\"],\n },\n condition: {\n type: \"object\",\n description:\n \"Condition payload: { expression, evaluator, evaluatorConfig? }\",\n },\n deadline: {\n type: \"number\",\n description: \"Optional Unix timestamp deadline for temporal contracts\",\n },\n compositeOf: {\n type: \"array\",\n description: \"Optional array of sub-contract IDs for composite contracts\",\n },\n compositeOperator: {\n type: \"string\",\n description: \"How composite sub-contracts should be combined\",\n enum: [\"all\", \"any\", \"majority\"],\n },\n modulation: {\n type: \"object\",\n description:\n \"Asymmetric modulation rules for confirmed, disconfirmed, expired, and partial outcomes\",\n },\n evaluationSchedule: {\n type: \"string\",\n description: \"When this contract should be evaluated\",\n enum: [\"on_demand\", \"on_evidence\", \"periodic\", \"event_driven\"],\n },\n periodicIntervalMs: {\n type: \"number\",\n description: \"Optional interval in milliseconds for periodic contracts\",\n },\n },\n required: [\n \"beliefNodeId\",\n \"title\",\n \"conditionType\",\n \"direction\",\n \"condition\",\n \"modulation\",\n \"evaluationSchedule\",\n ],\n response: {\n description: \"The created epistemic contract binding\",\n fields: {\n id: \"string — storage record ID\",\n contractId: \"string — contract identifier\",\n beliefId: \"string — canonical belief ID\",\n status: \"string — initial contract status\",\n title: \"string — contract title\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// EVIDENCE TOOLS\n// =============================================================================\n\nexport const ADD_EVIDENCE: McpToolContract = {\n name: \"add_evidence\",\n description:\n \"Commit evidence to the reasoning graph and attach it to a belief. \" +\n \"Like `git add && git commit` — an atomic write that creates a traceable evidence object. \" +\n \"Weight ranges from -1.0 (contradicts) to +1.0 (strongly supports). \" +\n \"Evidence is always context-bound: tied to its source, the time it was captured, and the belief it informs.\",\n parameters: {\n canonicalText: { type: \"string\", description: \"The evidence statement\" },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n sourceUrl: { type: \"string\", description: \"URL of the source material\" },\n targetNodeId: {\n type: \"string\",\n description: \"The belief this evidence bears on\",\n },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n reasoning: {\n type: \"string\",\n description: \"Why this evidence is relevant to the target belief\",\n },\n title: {\n type: \"string\",\n description: \"Optional short title for the evidence node\",\n },\n content: {\n type: \"string\",\n description:\n \"Optional long-form content (separate from canonicalText summary)\",\n },\n contentType: {\n type: \"string\",\n description:\n \"Content MIME type or format hint (e.g., 'text/markdown', 'code')\",\n },\n metadata: {\n type: \"object\",\n description:\n \"Optional extra metadata merged into the node (e.g., { codeAnchors: ['path/to/file.ts'], failedApproach: true } for coding intelligence)\",\n },\n },\n required: [\"canonicalText\", \"targetNodeId\", \"reasoning\"],\n response: {\n description: \"The created evidence node and its edge\",\n fields: {\n nodeId: \"string — evidence node ID\",\n edgeId: \"string — edge to target belief\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// CONTRADICTION TOOLS\n// =============================================================================\n\nexport const FLAG_CONTRADICTION: McpToolContract = {\n name: \"flag_contradiction\",\n description:\n \"Flag a contradiction between two beliefs. Contradictions are first-class objects \" +\n \"with their own lifecycle — they may remain permanently unresolved. \" +\n \"Like a merge conflict that is allowed to persist. \" +\n \"Contradictions can trigger structural changes: forking, confidence collapse, or decision blocking. \" +\n \"Resolution is NEVER automatic — always surfaces for human review.\",\n parameters: {\n beliefA: {\n type: \"string\",\n description: \"First belief in the contradiction\",\n },\n beliefB: {\n type: \"string\",\n description: \"Second belief in the contradiction\",\n },\n description: { type: \"string\", description: \"What the tension is about\" },\n severity: {\n type: \"string\",\n description: \"How serious the contradiction is\",\n enum: [\"low\", \"medium\", \"high\", \"critical\"],\n },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n defeatType: {\n type: \"string\",\n description:\n \"Pollock defeat classification: rebuts (direct contradiction), undercuts (attacks the inferential link), undermines (attacks a premise)\",\n enum: [\"rebuts\", \"undercuts\", \"undermines\"],\n },\n },\n required: [\"beliefA\", \"beliefB\", \"description\"],\n response: {\n description: \"The created contradiction object\",\n fields: {\n contradictionId: \"string\",\n status: \"string — 'unresolved'\",\n beliefA: \"string\",\n beliefB: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// WORKTREE TOOLS (git worktree add, git merge)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const ADD_WORKTREE: McpToolContract = {\n name: \"add_worktree\",\n description:\n \"Check out a branch into an active worktree for investigation. \" +\n \"Like `git worktree add <branch>` — creates independent working state on a thematic branch. \" +\n \"Beliefs committed within the worktree can be freely amended (draft code on a feature branch). \" +\n \"When investigation is complete, `merge` integrates findings into main.\",\n parameters: {\n title: { type: \"string\", description: \"Worktree name/objective\" },\n name: {\n type: \"string\",\n description:\n \"Optional storage-name alias for callers that already use backend naming\",\n },\n projectId: {\n type: \"string\",\n description: \"Legacy topicId alias or resolver hint\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope hint for resolver validation\",\n },\n topicHint: {\n type: \"string\",\n description: \"Natural-language topic hint for automatic topic resolution\",\n },\n branchId: {\n type: \"string\",\n description: \"The branch this worktree investigates\",\n },\n objective: {\n type: \"string\",\n description:\n \"Plain-text reasoning objective to auto-shape into a hypothesis, questions, tasks, and dependencies\",\n },\n hypothesis: {\n type: \"string\",\n description: \"The testable claim this worktree investigates\",\n },\n rationale: {\n type: \"string\",\n description:\n \"Why this worktree exists and why it belongs in the campaign\",\n },\n worktreeType: {\n type: \"string\",\n description:\n \"Schema-enum worktree type used by the kernel lifecycle and retrieval layers\",\n },\n gate: {\n type: \"string\",\n description: \"Exit gate name for this worktree\",\n },\n startDate: {\n type: \"number\",\n description: \"Planned start timestamp in milliseconds since epoch\",\n },\n endDate: {\n type: \"number\",\n description: \"Planned end timestamp in milliseconds since epoch\",\n },\n durationWeeks: {\n type: \"number\",\n description: \"Planned duration in weeks\",\n },\n confidenceImpact: {\n type: \"string\",\n description: \"Expected confidence impact if the worktree succeeds\",\n enum: [\"high\", \"medium\", \"low\"],\n },\n beliefFocus: {\n type: \"string\",\n description:\n \"Natural-language focus spanning the target belief neighborhood\",\n },\n beliefIds: {\n type: \"array\",\n description: \"Legacy alias for targetBeliefIds\",\n },\n beliefs: {\n type: \"array\",\n description: \"Legacy alias for targetBeliefIds\",\n },\n targetBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs this worktree is expected to test or update\",\n },\n targetQuestionIds: {\n type: \"array\",\n description: \"Question node IDs this worktree is expected to answer\",\n },\n keyQuestions: {\n type: \"array\",\n description:\n \"Inline key question objects with question, optional status, answer, answerConfidence, and linkedQuestionId\",\n },\n evidenceSignals: {\n type: \"array\",\n description:\n \"Evidence signal objects with signal, optional collected state, progress, and notes\",\n },\n decisionGate: {\n type: \"object\",\n description:\n \"Decision gate object with goCriteria, noGoSignals, optional verdict, rationale, decidedAt, and decidedBy\",\n },\n goCriteria: {\n type: \"array\",\n description: \"Shorthand go criteria used to build decisionGate\",\n },\n noGoSignals: {\n type: \"array\",\n description: \"Shorthand no-go signals used to build decisionGate\",\n },\n proofArtifacts: {\n type: \"array\",\n description: \"Expected proof artifacts required to close the worktree\",\n },\n autoShape: {\n type: \"boolean\",\n description:\n \"Whether to invoke inquiry auto-shaping during worktree creation\",\n },\n autoFixPolicy: {\n type: \"object\",\n description:\n \"Policy for permitted automatic remediation inside the worktree\",\n },\n domainPackId: {\n type: \"string\",\n description:\n \"Optional domain pack whose shaping hooks should influence generated questions and tasks\",\n },\n tags: {\n type: \"array\",\n description: \"Additional topic-resolution tags for the worktree\",\n },\n touchedPaths: {\n type: \"array\",\n description: \"File paths used as topic-resolution signals\",\n },\n sourceRef: {\n type: \"string\",\n description: \"Source reference used as a topic-resolution signal\",\n },\n sourceKind: {\n type: \"string\",\n description: \"Source kind used as a topic-resolution signal\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Top-level pipeline campaign number. Campaigns define the outer execution slice.\",\n },\n lane: {\n type: \"string\",\n description:\n \"GitButler-aligned workstream lane name inside the campaign.\",\n },\n laneOrderInCampaign: {\n type: \"number\",\n description:\n \"Ordering for this lane within its campaign.\",\n },\n orderInLane: {\n type: \"number\",\n description:\n \"Position of this worktree inside its lane.\",\n },\n dependsOn: {\n type: \"array\",\n description: \"Worktree IDs that must complete before this one can activate\",\n },\n blocks: {\n type: \"array\",\n description: \"Worktree IDs blocked by this worktree\",\n },\n staffingHint: {\n type: \"string\",\n description: \"Suggested staffing or agent allocation note\",\n },\n lensId: {\n type: \"string\",\n description: \"Lens that scopes this worktree when applicable\",\n },\n lastReconciledAt: {\n type: \"number\",\n description: \"Timestamp when worktree metadata was last reconciled\",\n },\n },\n required: [\"title\"],\n response: {\n description: \"The created worktree\",\n fields: {\n worktreeId: \"string\",\n branchId: \"string | null\",\n status: \"string — usually 'planning' or 'active'\",\n title: \"string\",\n hypothesis: \"string | null\",\n questionCount: \"number\",\n taskCount: \"number\",\n autoShapeApplied: \"boolean\",\n frameworkSuggestions: \"array\",\n dependencySuggestions: \"array\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const LIST_WORKTREES_BY_BELIEF: McpToolContract = {\n name: \"list_worktrees_by_belief\",\n description:\n \"List worktrees that adopted or reference a belief through the worktree-belief backref index. \" +\n \"Like `git branch --contains <commit>` for reasoning substrate — shows which \" +\n \"investigation branches carried a belief into the graph and with what adoption metadata.\",\n parameters: {\n beliefId: {\n type: \"string\",\n description: \"Belief node ID whose adopting worktrees should be listed.\",\n },\n status: {\n type: \"string\",\n description: \"Optional worktree lifecycle status filter.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum worktrees to return.\",\n },\n },\n required: [\"beliefId\"],\n response: {\n description: \"Worktrees that adopted or reference the belief\",\n fields: {\n beliefId: \"string — requested belief node id\",\n worktrees:\n \"array — worktree records with adoption relationType, confidence deltas, evidence counts, and timestamps\",\n total: \"number — returned worktree count\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const MERGE: McpToolContract = {\n name: \"merge\",\n description:\n \"Merge a worktree's findings into the stable knowledge base (main). \" +\n \"Like `git merge` to main — formulations freeze, confidence is recorded, findings are integrated. \" +\n \"Each belief gets a confidence score and rationale. After merge, beliefs can only evolve via fork. \" +\n \"Low-confidence beliefs may need forking.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to merge\" },\n outcomes: {\n type: \"array\",\n description:\n \"Merge outcomes as key-finding strings, or scoring outcomes for beliefs: { beliefId, confidence, rationale }\",\n },\n summary: { type: \"string\", description: \"Overall findings summary\" },\n },\n required: [\"worktreeId\", \"outcomes\"],\n response: {\n description: \"Merge result\",\n fields: {\n worktreeId: \"string\",\n status: \"string — 'merged'\",\n beliefsScored: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// LINEAGE AND AUDIT TOOLS\n// =============================================================================\n\nexport const PUSH: McpToolContract = {\n name: \"push\",\n description:\n \"Push scored beliefs from a merged worktree to other contexts. \" +\n \"Like `git push` — makes local findings available on the remote. \" +\n \"Only merged beliefs can be pushed. \" +\n \"Publication makes findings visible to other projects, teams, or external consumers.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The merged worktree whose findings to push\",\n },\n targetContext: {\n type: \"string\",\n description: \"Where to push (e.g., 'portfolio', 'ic_review', 'external')\",\n },\n beliefIds: {\n type: \"array\",\n description: \"Optional subset of beliefs to push (default: all scored)\",\n },\n },\n required: [\"worktreeId\", \"targetContext\"],\n response: {\n description: \"Push result\",\n fields: {\n pushedCount: \"number\",\n targetContext: \"string\",\n pushedAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// PULL REQUEST TOOLS (git pull request)\n// =============================================================================\n\nexport const OPEN_PULL_REQUEST: McpToolContract = {\n name: \"open_pull_request\",\n description:\n \"Open a pull request for peer review before merging a worktree. \" +\n \"Like opening a `git pull request` — the worktree's findings are ready but await approval before merge. \" +\n \"Reviewers can approve, request changes, or block the merge. \" +\n \"This is the gate between draft work and scored knowledge.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The worktree to submit for review\",\n },\n reviewers: {\n type: \"array\",\n description: \"User IDs of requested reviewers\",\n },\n summary: {\n type: \"string\",\n description: \"Summary of findings and why they're ready for merge\",\n },\n },\n required: [\"worktreeId\", \"summary\"],\n response: {\n description: \"The pull request\",\n fields: {\n pullRequestId: \"string\",\n worktreeId: \"string\",\n status: \"string — 'pending_review'\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// FORENSIC TOOLS (git bisect)\n// =============================================================================\n","/** Reasoning methods supported by the kernel edge schema. */\nexport const REASONING_METHODS = [\n \"deductive\",\n \"inductive\",\n \"abductive\",\n \"analogical\",\n \"causal\",\n \"correlational\",\n \"testimonial\",\n \"statistical\",\n \"implicit\",\n \"pattern_match\",\n] as const;\n\nexport type ReasoningMethod = (typeof REASONING_METHODS)[number];\n","import type { McpToolContract } from \"./tool-contracts.types\";\nimport { REASONING_METHODS } from \"./api-enums.contract\";\n\nexport const QUERY_LINEAGE: McpToolContract = {\n name: \"query_lineage\",\n description:\n \"Trace a belief's full ancestry — every fork, score, and SL scoring event. \" +\n \"Like `git log --graph`. \" +\n \"Returns the complete evolution chain showing how understanding developed over time. \" +\n \"Lineage is permanent and can never be erased (Invariant #3).\",\n parameters: {\n nodeId: { type: \"string\", description: \"Starting node to trace from\" },\n depth: {\n type: \"number\",\n description: \"How many generations to traverse (default: 5)\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Canonical lineage result\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n lineage: \"array — ancestry entries with beliefId, nodeId, formulation, forkReason, and createdAt\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const QUERY_ANCHOR_HISTORY: McpToolContract = {\n name: \"query_anchor_history\",\n description:\n \"Resolve anchor provenance history for a reasoning node. \" +\n \"Like `git log --ancestry-path` for derived reasoning — follows canonical \" +\n \"derived_from lineage while preserving the storage-only extracted_from alias.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Starting node to trace from\" },\n startNode: {\n type: \"string\",\n description: \"Starting node alias accepted by traversal callers\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth\",\n },\n mode: {\n type: \"string\",\n description: \"Traversal mode; defaults to anchor_down\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Anchor provenance lineage result\",\n fields: {\n lineage:\n \"array — provenance entries with node, depth, edgeType, and layer metadata\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_CONFIDENCE_HISTORY: McpToolContract = {\n name: \"get_confidence_history\",\n description:\n \"Get the full confidence history for a belief. \" +\n \"Each entry records the confidence level, trigger, rationale, and actor. \" +\n \"Like `git log` for a single metric — append-only, never overwritten.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to get history for\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Confidence history entries\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n entries: \"array — { confidence, trigger, rationale, timestamp, userId }\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const GET_AUDIT_TRAIL: McpToolContract = {\n name: \"get_audit_trail\",\n description:\n \"Get the full audit trail for a node — every mutation, who made it, when, and why. \" +\n \"Like `git blame` for knowledge. \" +\n \"All state transitions are explicit, attributable, and permanently queryable. \" +\n \"No silent changes are possible (Invariant #14).\",\n parameters: {\n nodeId: { type: \"string\", description: \"The node to audit\" },\n limit: {\n type: \"number\",\n description: \"Maximum entries to return (default: 50)\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Audit trail entries\",\n fields: {\n entries: \"array — { action, actor, timestamp, before, after, rationale }\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// GRAPH QUERY TOOLS\n// =============================================================================\n\nexport const TRAVERSE_GRAPH: McpToolContract = {\n name: \"traverse_graph\",\n description:\n \"Walk the reasoning graph from a starting node. \" +\n \"Like `git log --graph` — traverses connected lineage across nodes and edges. \" +\n \"Traversal follows epistemic layers: L4 (judgments) → L3 (beliefs, questions) → L2 (evidence) → L1 (sources). \" +\n \"Never skips layers. \" +\n \"Use direction 'up' to trace what a piece of evidence supports, 'down' to trace what supports a judgment.\",\n parameters: {\n startNode: { type: \"string\", description: \"Node to start traversal from\" },\n direction: {\n type: \"string\",\n description: \"Traversal direction\",\n enum: [\"up\", \"down\", \"both\"],\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth (default: 3)\",\n },\n },\n required: [\"startNode\"],\n response: {\n description: \"Subgraph of traversed nodes and edges\",\n fields: {\n nodes: \"array — traversed nodes\",\n edges: \"array — traversed edges\",\n depth: \"number\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_GRAPH_NEIGHBORHOOD: McpToolContract = {\n name: \"get_graph_neighborhood\",\n description:\n \"Retrieve the local neighborhood around one or more graph nodes. \" +\n \"Like `git log --graph --boundary` for a focused reasoning window. \" +\n \"Returns the canonical neighborhood payload shared by HTTP and SDK graph surfaces.\",\n parameters: {\n globalId: {\n type: \"string\",\n description: \"Single root node global identifier.\",\n },\n globalIds: {\n type: \"array\",\n description: \"Optional list of root node global identifiers.\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Maximum traversal depth (default: 2).\",\n },\n },\n required: [],\n response: {\n description: \"Canonical graph neighborhood payload\",\n fields: {\n nodes: \"array — graph nodes in the returned neighborhood\",\n edges: \"array — graph edges in the returned neighborhood\",\n depth: \"number — deepest traversed node depth\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const TRACE_ENTITY_IMPACT: McpToolContract = {\n name: \"trace_entity_impact\",\n description:\n \"Returns code-grounded beliefs, contracts, migration states, and failed attempts \" +\n \"anchored to a specific file or function path. \" +\n \"Like `git log -- <path>` — filters the knowledge graph to nodes anchored to a file path \" +\n \"via metadata.codeAnchors. Results are separated by coding belief type: decisions, contracts, \" +\n \"migrations, patterns, deprecations, and failures.\",\n parameters: {\n nodeId: {\n type: \"string\",\n description: \"Entity node ID to trace impact from\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description:\n \"Entity impact trace: direct beliefs, evidence, and indirect belief reach\",\n fields: {\n entityNodeId: \"string — the traced entity\",\n entityType: \"string — nodeType of the entity\",\n directBeliefConnections:\n \"array — beliefs directly connected via bridge edges\",\n evidenceConnections: \"array — evidence referencing this entity\",\n indirectBeliefConnections: \"array — beliefs reached through evidence\",\n totalBeliefReach: \"number — total unique beliefs impacted\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SEARCH_BELIEFS: McpToolContract = {\n name: \"search_beliefs\",\n description:\n \"Search for beliefs in the reasoning graph. \" +\n \"Like `git grep` — finds relevant beliefs across the full history and active state. \" +\n \"Supports semantic search, filtering by status (unscored, scored, archived), \" +\n \"confidence thresholds, and topic scope. \" +\n \"Returns beliefs with their current confidence, lineage depth, and contradiction count.\",\n parameters: {\n query: { type: \"string\", description: \"Semantic search query\" },\n status: {\n type: \"string\",\n description: \"Filter by belief status\",\n enum: [\"unscored\", \"scored\", \"archived\"],\n },\n minConfidence: {\n type: \"number\",\n description: \"Minimum confidence threshold (0-1)\",\n },\n topicId: { type: \"string\", description: \"Filter by topic\" },\n limit: { type: \"number\", description: \"Maximum results (default: 10)\" },\n },\n required: [\"query\"],\n response: {\n description: \"Matching beliefs with metadata\",\n fields: {\n results:\n \"array — { nodeId, canonicalText, confidence, status, contradictionCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const FIND_CONTRADICTIONS: McpToolContract = {\n name: \"find_contradictions\",\n description:\n \"Find contradictions in the reasoning graph — beliefs that are in tension with each other. \" +\n \"Like a merge conflict in `git` — surfaces incompatible states that require explicit resolution. \" +\n \"Contradictions are first-class objects that may remain permanently unresolved. \" +\n \"They can block judgments, trigger forks, or collapse confidence. \" +\n \"Filter by project, status (unresolved, resolved, accepted), and severity.\",\n parameters: {\n topicId: { type: \"string\", description: \"Required topic scope filter\" },\n nodeId: {\n type: \"string\",\n description: \"Optional belief identifier to filter contradictions within the topic\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\n \"unresolved\",\n \"investigating\",\n \"accepted_as_permanent\",\n \"resolved_by_fork\",\n \"resolved_by_evidence\",\n \"resolved_by_reinterpretation\",\n \"superseded\",\n ],\n },\n limit: { type: \"number\", description: \"Maximum contradictions to return\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Contradiction objects\",\n fields: {\n contradictions:\n \"array — { beliefA, beliefB, description, severity, status, defeatType }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// EDGE TOOLS\n// =============================================================================\n\nexport const BISECT_CONFIDENCE: McpToolContract = {\n name: \"bisect_confidence\",\n description:\n \"Find when a belief's confidence diverged from reality. \" +\n \"Like `git bisect` — binary search through the credence history to find the inflection point. \" +\n \"Given a belief that is now known to be wrong (or right), traces back through \" +\n \"SL scoring events to identify which evidence or event caused the divergence.\",\n parameters: {\n nodeId: { type: \"string\", description: \"The belief to bisect\" },\n expectedDirection: {\n type: \"string\",\n description: \"Was confidence too high or too low?\",\n enum: [\"overconfident\", \"underconfident\"],\n },\n timeRange: {\n type: \"object\",\n description:\n \"Optional time range to search within: { start: number, end: number }\",\n },\n },\n required: [\"nodeId\", \"expectedDirection\"],\n response: {\n description: \"The inflection point in confidence history\",\n fields: {\n beliefId: \"string — canonical belief ID\",\n expectedDirection: \"string — overconfident | underconfident\",\n inflectionEntry: \"object — the scoring event where divergence began\",\n triggerEvent: \"string | null — what caused the divergence\",\n confidenceBefore: \"number | null\",\n confidenceAfter: \"number | null\",\n totalEntries: \"number\",\n inflectionIndex: \"number | null\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// GRAPH INTELLIGENCE TOOLS\n// =============================================================================\n\nexport const CREATE_EDGE: McpToolContract = {\n name: \"create_edge\",\n description:\n \"Commit a typed relationship between two nodes in the reasoning graph. \" +\n \"Like `git commit` — an atomic write that declares a dependency between nodes. \" +\n \"Accepts any public epistemic edge type between public graph node refs so agents can author the full spine.\",\n parameters: {\n from: {\n type: \"object\",\n description:\n \"Source graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'topic' }\",\n },\n to: {\n type: \"object\",\n description:\n \"Target graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'belief' }\",\n },\n edgeType: {\n type: \"string\",\n description:\n \"Relationship type from the public epistemic edge enum.\",\n },\n globalId: {\n type: \"string\",\n description: \"Optional idempotent edge global ID.\",\n },\n weight: {\n type: \"number\",\n description:\n \"Edge weight: -1.0 to +1.0 for informs edges, 0-1 for structural\",\n },\n reasoning: { type: \"string\", description: \"Why this relationship exists\" },\n reasoningMethod: {\n type: \"string\",\n description: \"How this was determined\",\n enum: [...REASONING_METHODS],\n },\n metadata: {\n type: \"object\",\n description: \"Optional edge metadata.\",\n },\n },\n required: [\"from\", \"to\", \"edgeType\"],\n response: {\n description: \"The created edge\",\n fields: {\n globalId: \"string — edge identifier\",\n edgeType: \"string\",\n fromLayer: \"string\",\n toLayer: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"showcase\",\n};\n\nexport const UPDATE_EDGE: McpToolContract = {\n name: \"update_edge\",\n description:\n \"Amend metadata on an existing graph edge. \" +\n \"Like `git commit --amend` — changes the edge annotation without recreating the relationship.\",\n parameters: {\n edgeId: { type: \"string\", description: \"Edge ID or global ID to update\" },\n weight: { type: \"number\", description: \"Updated edge weight\" },\n confidence: { type: \"number\", description: \"Updated confidence\" },\n context: { type: \"string\", description: \"Updated human-readable context\" },\n derivationType: { type: \"string\", description: \"Updated derivation type\" },\n metadata: { type: \"object\", description: \"Updated metadata\" },\n },\n required: [\"edgeId\"],\n response: {\n description: \"Edge update result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_EDGE: McpToolContract = {\n name: \"remove_edge\",\n description:\n \"Remove one graph edge by ID. \" +\n \"Like `git rm` — deletes a single explicit relationship from the spine.\",\n parameters: {\n edgeId: { type: \"string\", description: \"Edge ID or global ID to remove\" },\n },\n required: [\"edgeId\"],\n response: {\n description: \"Edge removal result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_EDGES_BETWEEN: McpToolContract = {\n name: \"remove_edges_between\",\n description:\n \"Remove graph edges between two nodes. \" +\n \"Like `git rm <pathspec>` — deletes relationships matching a source, target, and optional type.\",\n parameters: {\n fromNodeId: { type: \"string\", description: \"Source node ID or global ID\" },\n toNodeId: { type: \"string\", description: \"Target node ID or global ID\" },\n edgeType: { type: \"string\", description: \"Optional edge type filter\" },\n },\n required: [\"fromNodeId\", \"toNodeId\"],\n response: {\n description: \"Matched edge removal result\",\n fields: { deleted: \"number\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const BATCH_CREATE_EDGES: McpToolContract = {\n name: \"batch_create_edges\",\n description:\n \"Commit multiple typed graph edges. \" +\n \"Like `git commit` with many staged paths — writes a batch of explicit relationships atomically per edge.\",\n parameters: {\n edges: {\n type: \"array\",\n description:\n \"Edges to create, each with from, to, edgeType, and optional weight/confidence/context.\",\n },\n skipLayerValidation: {\n type: \"boolean\",\n description: \"Skip kernel layer validation for trusted materialization flows.\",\n },\n },\n required: [\"edges\"],\n response: {\n description: \"Batch edge creation result\",\n fields: {\n created: \"number\",\n results: \"array\",\n errors: \"array\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// EPISTEMIC NODE TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nconst sharedEmbeddingParameters = {\n topicId: {\n type: \"string\",\n description: \"Topic whose epistemic node embedding index should be queried.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Workspace scope for the embedding operation.\",\n },\n nodeType: {\n type: \"string\",\n description: \"Optional epistemic node type filter.\",\n },\n embeddingModel: {\n type: \"string\",\n description: \"Optional embedding model filter.\",\n },\n includeInactive: {\n type: \"boolean\",\n description: \"Include archived, superseded, or otherwise inactive epistemic nodes in coverage checks.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum rows to return.\",\n },\n} satisfies McpToolContract[\"parameters\"];\n\nexport const LIST_MISSING_EMBEDDINGS: McpToolContract = {\n name: \"list_missing_embeddings\",\n description:\n \"List epistemic nodes missing fresh Convex embeddings. \" +\n \"Like `git status` for the semantic index — shows which graph nodes still need indexing before retrieval can be trusted.\",\n parameters: sharedEmbeddingParameters,\n required: [\"topicId\", \"workspaceId\"],\n response: {\n description: \"Missing or stale embedding candidates\",\n fields: {\n nodes: \"array — node candidates missing fresh embeddings\",\n total: \"number — candidate count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SEARCH_EMBEDDINGS: McpToolContract = {\n name: \"search_embeddings\",\n description:\n \"Search topic-scoped epistemic nodes through the Convex vector index. \" +\n \"Like `git grep` with semantic distance — finds matching beliefs, questions, evidence, and other nodes even when wording differs.\",\n parameters: {\n ...sharedEmbeddingParameters,\n queryText: {\n type: \"string\",\n description: \"Natural-language query to embed and search with.\",\n },\n queryVector: {\n type: \"array\",\n description: \"Optional precomputed query vector.\",\n },\n minScore: {\n type: \"number\",\n description: \"Optional minimum cosine-similarity score.\",\n },\n },\n required: [\"topicId\", \"workspaceId\"],\n response: {\n description: \"Vector search matches\",\n fields: {\n results: \"array — semantic matches with nodeId, nodeType, score, text, and provenance\",\n total: \"number — match count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_EMBEDDINGS_BY_NODE_IDS: McpToolContract = {\n name: \"get_embeddings_by_node_ids\",\n description:\n \"Fetch embedding records for explicit epistemic node IDs. \" +\n \"Like `git show` for semantic-index rows — inspects exactly which vectors exist for named graph nodes.\",\n parameters: {\n ...sharedEmbeddingParameters,\n nodeIds: {\n type: \"array\",\n description: \"Epistemic node IDs to inspect.\",\n },\n },\n required: [\"topicId\", \"workspaceId\", \"nodeIds\"],\n response: {\n description: \"Embedding records for explicit node IDs\",\n fields: {\n embeddings: \"array — embedding metadata records\",\n total: \"number — embedding count\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const QUEUE_EMBEDDING_BACKFILL: McpToolContract = {\n name: \"queue_embedding_backfill\",\n description:\n \"Queue background embedding generation for explicit epistemic nodes. \" +\n \"Like `git add` for semantic-index work — stages graph nodes for the kernel backfill scheduler.\",\n parameters: {\n ...sharedEmbeddingParameters,\n nodeIds: {\n type: \"array\",\n description: \"Epistemic node IDs to queue for embedding generation.\",\n },\n },\n required: [\"topicId\", \"workspaceId\", \"nodeIds\"],\n response: {\n description: \"Backfill queue receipt\",\n fields: {\n queued: \"number — queued node count\",\n nodeIds: \"array — node IDs queued for embedding generation\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nconst hybridParameters = {\n query: {\n type: \"string\",\n description: \"Natural-language query text to resolve against the typed reasoning graph.\",\n },\n queryText: {\n type: \"string\",\n description: \"Explicit query text alias for clients that separate command words from search text.\",\n },\n text: {\n type: \"string\",\n description: \"Raw pasted text to use as a semantic retrieval seed.\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope. When omitted, semantic topic candidates are resolved first.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Optional workspace scope used by semantic topic candidates and vector search.\",\n },\n nodeId: {\n type: \"string\",\n description: \"Optional source node used for related-node or impact analysis.\",\n },\n include: {\n type: \"array\",\n description:\n \"Result families to include, such as topics, nodes, worktrees, tasks, evidence, and edges.\",\n },\n via: {\n type: \"array\",\n description:\n \"Retrieval methods to use: bm25, embeddings, edges, topic-tree, state, graph-algorithms.\",\n },\n depth: {\n type: \"number\",\n description: \"Graph expansion depth. Defaults to 1 and is capped by the server.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum rows per result family.\",\n },\n minScore: {\n type: \"number\",\n description: \"Minimum semantic or fused score for candidate rows.\",\n },\n campaign: {\n type: \"number\",\n description: \"Optional worktree campaign filter.\",\n },\n lane: {\n type: \"string\",\n description: \"Optional worktree lane filter.\",\n },\n status: {\n type: \"string\",\n description: \"Optional node, task, or worktree state/status filter.\",\n },\n nodeTypes: {\n type: \"array\",\n description: \"Optional epistemic node types to include.\",\n },\n changedPaths: {\n type: \"array\",\n description: \"Changed file paths used as impact-analysis query signals.\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional planner metadata for receipts and caller provenance.\",\n },\n} satisfies McpToolContract[\"parameters\"];\n\nconst hybridResponse = {\n description: \"Hybrid semantic graph planner response with ranked result families and retrieval receipt.\",\n fields: {\n results: \"array — ranked mixed graph results with score, kind, source, and ranking signals\",\n topics: \"array — candidate or traversed topics\",\n nodes: \"array — matching epistemic nodes\",\n worktrees: \"array — matching worktrees\",\n tasks: \"array — matching tasks\",\n evidence: \"array — matching evidence\",\n edges: \"array — graph neighborhood edges\",\n receipt: \"object — planner steps, candidate counts, ranking weights, source/cache posture\",\n },\n} satisfies McpToolContract[\"response\"];\n\nexport const HYBRID_DISCOVER: McpToolContract = {\n name: \"hybrid_discover\",\n description:\n \"Discover typed reasoning graph context with BM25, embeddings, topic tree traversal, and graph neighborhoods. \" +\n \"Like `git grep` plus `git log --graph` for Lucern's typed reasoning graph — finds the relevant branches of thought and explains why.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const RESOLVE_TOPIC_SEMANTIC: McpToolContract = {\n name: \"resolve_topic_semantic\",\n description:\n \"Resolve an ambiguous topic using BM25, vector candidates, and topic-tree context. \" +\n \"Like `git remote show` for a reasoning topic — finds the canonical branch and nearby branches before reading deeper.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const EXPAND_GRAPH_NEIGHBORHOOD: McpToolContract = {\n name: \"expand_graph_neighborhood\",\n description:\n \"Expand a typed graph neighborhood around a query, topic, or node. \" +\n \"Like `git log --graph --decorate` for reasoning state — follows typed edges and surfaces the surrounding context.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const FIND_RELATED_NODES: McpToolContract = {\n name: \"find_related_nodes\",\n description:\n \"Find semantically and structurally related nodes across the reasoning graph. \" +\n \"Like `git blame` across branches — starts from a node or text and finds nearby responsibility, evidence, and related claims.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const ANALYZE_GRAPH_IMPACT: McpToolContract = {\n name: \"analyze_graph_impact\",\n description:\n \"Analyze which graph objects are affected by files, PR text, incidents, or campaign objectives. \" +\n \"Like `git diff --name-only` plus semantic blame — maps a change signal onto topics, beliefs, tasks, and unresolved questions.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const DETECT_GRAPH_DRIFT: McpToolContract = {\n name: \"detect_graph_drift\",\n description:\n \"Detect duplicate, stale, orphaned, or weakly linked reasoning graph surface. \" +\n \"Like `git fsck` for the reasoning graph — finds semantic duplicates, stale docs/code references, and missing links.\",\n parameters: hybridParameters,\n required: [],\n response: hybridResponse,\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n","/**\n * Canonical lens workflow contract shared across schema, SDK, and MCP surfaces.\n */\n\n// Re-export filter criteria types for consumers who import from lens-workflow\nexport type {\n LensFilterCriteria,\n TaxonomyFilterCriteriaV1,\n EntityTypeFilterV1,\n OntologyScope,\n FilterValidationResult,\n} from \"./lens-filter.contract\";\nexport {\n validateFilterCriteria,\n isLensFilterCriteria,\n isTaxonomyFilterCriteriaV1,\n} from \"./lens-filter.contract\";\n\nexport const LENS_PERSPECTIVE_TYPES = [\n \"investigation\",\n \"monitoring\",\n \"analysis\",\n \"comparison\",\n \"taxonomy\",\n] as const;\n\nexport type LensPerspectiveType = (typeof LENS_PERSPECTIVE_TYPES)[number];\n\nexport const LENS_STATUSES = [\"draft\", \"active\", \"archived\"] as const;\n\nexport type LensStatus = (typeof LENS_STATUSES)[number];\n\nexport const LENS_TASK_TEMPLATE_PRIORITIES = [\n \"critical\",\n \"high\",\n \"medium\",\n \"low\",\n] as const;\n\nexport type LensTaskTemplatePriority =\n (typeof LENS_TASK_TEMPLATE_PRIORITIES)[number];\n\nexport type LensLooseMetadata = Record<string, unknown>;\n\nexport type LensPromptTemplateReference = {\n key: string;\n promptRef: string;\n phase?: string;\n role?: string;\n version?: string;\n required?: boolean;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensWorkflowStepTemplate = {\n key: string;\n title: string;\n description?: string;\n promptTemplateKey?: string;\n taskTemplateKeys?: string[];\n metadata?: LensLooseMetadata;\n};\n\nexport type LensWorkflowTemplate = {\n key: string;\n name: string;\n description?: string;\n steps: LensWorkflowStepTemplate[];\n metadata?: LensLooseMetadata;\n};\n\nexport type LensTaskTemplate = {\n key: string;\n title: string;\n description?: string;\n priority?: LensTaskTemplatePriority;\n phase?: string;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensQuestionTemplate = {\n key: string;\n text: string;\n priority?: LensTaskTemplatePriority;\n linkedBeliefKey?: string;\n metadata?: LensLooseMetadata;\n};\n\nexport type LensBranchMigrationSuggestion = {\n recommendedTool: \"create_lens\";\n perspectiveType: LensPerspectiveType;\n message: string;\n suggestedPayload: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n perspectiveType: LensPerspectiveType;\n };\n};\n\nexport const BRANCH_DEPRECATION_MESSAGE =\n \"Branches are deprecated for operational framing. Create a workspace-scoped lens instead.\";\n\nexport type DeprecatedBranchMetadata = {\n deprecated: true;\n deprecationMessage: string;\n lensSuggestion: LensBranchMigrationSuggestion;\n};\n\nexport function inferLensPerspectiveTypeFromBranchSchema(\n schema?: string | null\n): LensPerspectiveType {\n const normalized = schema?.trim().toLowerCase();\n if (normalized === \"phase\") {\n return \"monitoring\";\n }\n if (normalized === \"axis\" || normalized === \"dimension\") {\n return \"comparison\";\n }\n if (normalized === \"track\") {\n return \"investigation\";\n }\n return \"analysis\";\n}\n\nexport function migrateBranchToLens(args: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n schema?: string | null;\n}): LensBranchMigrationSuggestion {\n const perspectiveType = inferLensPerspectiveTypeFromBranchSchema(args.schema);\n return {\n recommendedTool: \"create_lens\",\n perspectiveType,\n message:\n \"Branches are deprecated for operational framing. Create a workspace-scoped lens with the suggested payload instead.\",\n suggestedPayload: {\n name: args.name,\n description: args.description,\n topicId: args.topicId,\n workspaceId: args.workspaceId,\n perspectiveType,\n },\n };\n}\n\nexport function buildDeprecatedBranchMetadata(args: {\n name: string;\n description?: string;\n topicId?: string;\n workspaceId?: string;\n schema?: string | null;\n}): DeprecatedBranchMetadata {\n return {\n deprecated: true,\n deprecationMessage: BRANCH_DEPRECATION_MESSAGE,\n lensSuggestion: migrateBranchToLens(args),\n };\n}\n","import type { McpToolContract } from \"./tool-contracts.types\";\nimport { LENS_PERSPECTIVE_TYPES } from \"./lens-workflow.contract\";\n\nexport const CREATE_EPISTEMIC_NODE: McpToolContract = {\n name: \"create_epistemic_node\",\n description:\n \"Commit a generic epistemic graph node. \" +\n \"Like `git commit` — creates a canonical node in the public spine for topics, beliefs, evidence, questions, answers, sources, and entities.\",\n parameters: {\n globalId: { type: \"string\", description: \"Optional idempotent node global ID\" },\n nodeType: { type: \"string\", description: \"Public epistemic node type\" },\n canonicalText: { type: \"string\", description: \"Canonical node text\" },\n text: { type: \"string\", description: \"Alias for canonicalText\" },\n contentHash: { type: \"string\", description: \"Optional idempotency content hash\" },\n sourceType: { type: \"string\", description: \"Source type for provenance\" },\n topicId: { type: \"string\", description: \"Optional topic scope\" },\n content: { type: \"string\", description: \"Extended content\" },\n title: { type: \"string\", description: \"Display title\" },\n metadata: { type: \"object\", description: \"Optional node metadata\" },\n },\n required: [\"nodeType\"],\n response: {\n description: \"Created node result\",\n fields: {\n nodeId: \"string\",\n nodeGlobalId: \"string\",\n isDuplicate: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_EPISTEMIC_NODE: McpToolContract = {\n name: \"get_epistemic_node\",\n description:\n \"Read one epistemic graph node. \" +\n \"Like `git show` — resolves a canonical spine node by ID or global ID.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"The resolved node\",\n fields: { node: \"object\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const LIST_EPISTEMIC_NODES: McpToolContract = {\n name: \"list_epistemic_nodes\",\n description:\n \"List epistemic graph nodes. \" +\n \"Like `git ls-tree` — lists canonical spine nodes by topic, type, status, or search query.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope\" },\n nodeType: { type: \"string\", description: \"Optional node type filter\" },\n status: { type: \"string\", description: \"Optional lifecycle status\" },\n searchQuery: { type: \"string\", description: \"Optional text search query\" },\n limit: { type: \"number\", description: \"Maximum nodes to return\" },\n },\n required: [],\n response: {\n description: \"Matching nodes\",\n fields: { nodes: \"array\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_EPISTEMIC_NODE: McpToolContract = {\n name: \"update_epistemic_node\",\n description:\n \"Amend an epistemic graph node. \" +\n \"Like `git commit --amend` — updates mutable node metadata, text, status, or verification fields.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n canonicalText: { type: \"string\", description: \"Updated canonical text\" },\n text: { type: \"string\", description: \"Alias for canonicalText\" },\n contentHash: { type: \"string\", description: \"Updated content hash\" },\n content: { type: \"string\", description: \"Updated content\" },\n title: { type: \"string\", description: \"Updated display title\" },\n metadata: { type: \"object\", description: \"Updated metadata\" },\n confidence: { type: \"number\", description: \"Updated confidence\" },\n verificationStatus: { type: \"string\", description: \"Updated verification status\" },\n status: { type: \"string\", description: \"Updated lifecycle status\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Node update result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_EPISTEMIC_NODE: McpToolContract = {\n name: \"archive_epistemic_node\",\n description:\n \"Archive an epistemic graph node. \" +\n \"Like `git rm --cached` — removes a node from active traversal without hard-deleting it.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Archive result\",\n fields: { success: \"boolean\", effectiveStatus: \"string\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const VERIFY_EPISTEMIC_NODE: McpToolContract = {\n name: \"verify_epistemic_node\",\n description:\n \"Record verification state on an epistemic graph node. \" +\n \"Like `git tag` — marks the node with a reviewed verification state.\",\n parameters: {\n nodeId: { type: \"string\", description: \"Node ID or global ID\" },\n verificationStatus: { type: \"string\", description: \"Verification status\" },\n confidence: { type: \"number\", description: \"Optional confidence update\" },\n },\n required: [\"nodeId\", \"verificationStatus\"],\n response: {\n description: \"Verification result\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const SUPERSEDE_EPISTEMIC_NODE: McpToolContract = {\n name: \"supersede_epistemic_node\",\n description:\n \"Supersede an epistemic graph node with a new version. \" +\n \"Like `git commit --amend` on an immutable history branch — creates the replacement and marks the old node superseded.\",\n parameters: {\n oldNodeId: { type: \"string\", description: \"Node ID or global ID to supersede\" },\n newGlobalId: { type: \"string\", description: \"Optional replacement global ID\" },\n newCanonicalText: { type: \"string\", description: \"Replacement canonical text\" },\n text: { type: \"string\", description: \"Alias for newCanonicalText\" },\n newContentHash: { type: \"string\", description: \"Optional replacement content hash\" },\n reason: { type: \"string\", description: \"Reason for superseding\" },\n },\n required: [\"oldNodeId\"],\n response: {\n description: \"Supersede result\",\n fields: { oldNodeId: \"string\", newNodeId: \"string\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const BATCH_CREATE_EPISTEMIC_NODES: McpToolContract = {\n name: \"batch_create_epistemic_nodes\",\n description:\n \"Commit multiple epistemic graph nodes. \" +\n \"Like `git commit` with many staged files — writes a batch of canonical spine nodes.\",\n parameters: {\n nodes: {\n type: \"array\",\n description: \"Nodes to create with nodeType, canonicalText/text, and optional metadata.\",\n },\n },\n required: [\"nodes\"],\n response: {\n description: \"Batch node creation result\",\n fields: { created: \"number\", results: \"array\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// JUDGMENT TOOLS (Phase 1: new vocabulary, aliased to decision implementation)\n// =============================================================================\n\nexport const RECORD_JUDGMENT: McpToolContract = {\n name: \"record_judgment\",\n description:\n \"Record a judgment — an irreversible commitment based on the current epistemic state. \" +\n \"Like a `git tag` marking a release. \" +\n \"A judgment synthesizes beliefs, evidence, and uncertainties into a determination. \" +\n \"Once issued, a judgment is evaluated against the epistemic state that existed when it was made \" +\n \"(knowledge horizon evaluation, Invariant #10).\",\n parameters: {\n title: { type: \"string\", description: \"Short judgment statement\" },\n rationale: {\n type: \"string\",\n description: \"Full reasoning behind the judgment\",\n },\n topicId: { type: \"string\", description: \"Topic scope\" },\n beliefIds: {\n type: \"array\",\n description: \"Beliefs that warrant this judgment\",\n },\n confidence: {\n type: \"number\",\n description: \"Confidence in the judgment (0-1)\",\n },\n },\n required: [\"title\", \"rationale\"],\n response: {\n description: \"The recorded judgment\",\n fields: {\n judgmentId: \"string\",\n title: \"string\",\n status: \"string — 'issued'\",\n },\n },\n ownerModule: \"decisions\",\n ontologyPrimitive: \"judgment\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// LENS TOOLS (workspace-scoped operational frames)\n// =============================================================================\n\nexport const CREATE_LENS: McpToolContract = {\n name: \"create_lens\",\n description:\n \"Create a reusable lens that overlays a workspace topic with a specific analytical perspective. \" +\n \"Like `git branch <name>` for operational scaffolding — a lens persists across worktrees and carries prompts, workflows, and task templates. \" +\n \"Multiple topics in the same workspace can reuse the same lens.\",\n parameters: {\n name: {\n type: \"string\",\n description: \"Lens name (e.g., 'market dynamics', 'team quality')\",\n },\n workspaceId: {\n type: \"string\",\n description:\n \"Workspace scope for the lens. Required unless topicId resolves to a workspace-scoped topic.\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Optional originating topic scope. Lenses remain reusable across topics even when this is set.\",\n },\n description: {\n type: \"string\",\n description: \"What this lens is designed to investigate or monitor\",\n },\n perspectiveType: {\n type: \"string\",\n description:\n \"Perspective type for the lens. Validated against schemaEnumConfig category 'lens_perspective_type'.\",\n enum: [...LENS_PERSPECTIVE_TYPES],\n },\n promptTemplates: {\n type: \"array\",\n description: \"Langfuse prompt references used when operating through this lens\",\n },\n workflowTemplates: {\n type: \"array\",\n description: \"Guided workflow templates for lens-driven investigations\",\n },\n taskTemplates: {\n type: \"array\",\n description: \"Default task templates instantiated when the lens is applied\",\n },\n filterCriteria: {\n type: \"object\",\n description: \"Belief/evidence filtering rules applied by the lens\",\n },\n },\n required: [\"name\", \"perspectiveType\"],\n response: {\n description: \"The created lens\",\n fields: {\n lensId: \"string\",\n name: \"string\",\n workspaceId: \"string\",\n status: \"string — 'active'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"showcase\",\n};\n\nexport const LIST_LENSES: McpToolContract = {\n name: \"list_lenses\",\n description:\n \"List reusable lenses for a workspace, optionally scored by whether they are active on a topic. \" +\n \"Like `git branch --list` — shows the available named frames you can activate. \" +\n \"When topicId is provided, the response can indicate which lenses are already applied there.\",\n parameters: {\n workspaceId: {\n type: \"string\",\n description: \"Workspace scope to list lenses from\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Optional topic scope used to derive workspace and annotate applied lenses\",\n },\n status: {\n type: \"string\",\n description: \"Filter by lens lifecycle status\",\n enum: [\"draft\", \"active\", \"archived\"],\n },\n perspectiveType: {\n type: \"string\",\n description: \"Filter by perspective type\",\n enum: [...LENS_PERSPECTIVE_TYPES],\n },\n },\n required: [],\n response: {\n description: \"Available lenses\",\n fields: {\n lenses:\n \"array — each item includes lensId, name, workspaceId, perspectiveType, status, and optional isAppliedToTopic\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\nexport const APPLY_LENS_TO_TOPIC: McpToolContract = {\n name: \"apply_lens_to_topic\",\n description:\n \"Apply a lens to a topic so it becomes an active perspective overlay. \" +\n \"Like `git checkout <branch>` for a reusable frame — the topic keeps its knowledge, but the active lens shapes guidance and retrieval. \" +\n \"Multiple active lenses can coexist on the same topic.\",\n parameters: {\n lensId: { type: \"string\", description: \"Lens to activate on the topic\" },\n topicId: { type: \"string\", description: \"Topic that should receive the lens\" },\n },\n required: [\"lensId\", \"topicId\"],\n response: {\n description: \"Lens activation result\",\n fields: {\n bindingId: \"string\",\n lensId: \"string\",\n topicId: \"string\",\n status: \"string — 'active'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\nexport const REMOVE_LENS_FROM_TOPIC: McpToolContract = {\n name: \"remove_lens_from_topic\",\n description:\n \"Remove an active lens overlay from a topic. \" +\n \"Like `git switch` away from a frame — the topic remains, but the lens stops shaping the investigation context. \" +\n \"Historical binding state is preserved for auditability.\",\n parameters: {\n lensId: { type: \"string\", description: \"Lens to remove from the topic\" },\n topicId: { type: \"string\", description: \"Topic that currently has the lens applied\" },\n },\n required: [\"lensId\", \"topicId\"],\n response: {\n description: \"Lens removal result\",\n fields: {\n bindingId: \"string\",\n lensId: \"string\",\n topicId: \"string\",\n status: \"string — 'removed'\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"lens\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// PUSH TOOLS (git push)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const LUCERN_ORIENT: McpToolContract = {\n name: \"lucern_orient\",\n description:\n \"Load the Lucern reasoning grammar before operating. \" +\n \"Like `git help` plus a repository CONTRIBUTING guide for reasoning state - teaches the git-shaped model of topics, campaigns, lanes, worktrees, beliefs, questions, evidence, receipts, gates, and merges.\",\n parameters: {\n audience: {\n type: \"string\",\n description: \"Audience for the primer: agent, human, operator, or developer.\",\n enum: [\"agent\", \"human\", \"operator\", \"developer\"],\n },\n depth: {\n type: \"string\",\n description: \"Orientation depth: quick, standard, or deep.\",\n enum: [\"quick\", \"standard\", \"deep\"],\n },\n situation: {\n type: \"string\",\n description:\n \"Optional task or query context used to tailor suggested next calls.\",\n },\n includeExamples: {\n type: \"boolean\",\n description: \"Whether to include concrete tool-call examples.\",\n },\n includeToolMap: {\n type: \"boolean\",\n description: \"Whether to include situation-to-tool routing guidance.\",\n },\n includeFuture: {\n type: \"boolean\",\n description:\n \"Whether to include future exemplar, gauntlet, and training-data capabilities.\",\n },\n },\n required: [],\n response: {\n description:\n \"Canonical operator primer for Lucern's git-shaped reasoning substrate.\",\n fields: {\n schemaVersion: \"string - lucern_orientation.v1\",\n canonicalMentalModel:\n \"object - concise model of Lucern as git-shaped reasoning state\",\n workflow:\n \"array - recommended branch -> investigate -> prove gate -> merge workflow\",\n grammarMap:\n \"array - primitive-to-git-analogy map for topics, campaigns, worktrees, beliefs, questions, evidence, edges, contradictions, and gates\",\n firstMoves: \"array - recommended first tools for a cold-start agent\",\n receiptRules:\n \"array - how to interpret candidateCounts, broadening, coverageWarning, narrativeCoverage, synthesisLints, and noDefaultGlobalScan\",\n safetyRules:\n \"array - mutation and completion rules that preserve reasoning lineage\",\n toolMap:\n \"array | undefined - situation-to-tool routing map when requested\",\n examples: \"array | undefined - concrete tool-call examples when requested\",\n futureCapabilities:\n \"array | undefined - exemplar, gauntlet, trace-corpus, and native-model-training capabilities when requested\",\n suggestedNextCalls:\n \"array - safe next tool calls for the current situation\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const DETECT_CONFIRMATION_BIAS: McpToolContract = {\n name: \"detect_confirmation_bias\",\n description:\n \"Detect confirmation bias in the evidence graph. \" +\n \"Like `git diff --stat` for reasoning — analyzes the ratio of supporting vs challenging evidence \" +\n \"per belief and flags beliefs where the evidence is suspiciously one-sided. \" +\n \"Returns risk classification (critical/high/moderate/healthy).\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n threshold: {\n type: \"number\",\n description: \"Bias threshold (0-1, default 0.7)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Beliefs with bias scores, risk levels, and evidence counts\",\n fields: {\n beliefs:\n \"array — { nodeId, biasScore, riskLevel, supportingCount, challengingCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_GRAPH_STRUCTURE_ANALYSIS: McpToolContract = {\n name: \"get_graph_structure_analysis\",\n description:\n \"Run comprehensive structural analysis on the knowledge graph. \" +\n \"Like `git fsck` combined with PageRank — runs 14 algorithmic detectors including \" +\n \"PageRank centrality, Louvain community detection, Tarjan SCC, Fiedler vector spectral analysis, \" +\n \"Bayesian surprise, and overconfidence detection.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Structural analysis with detector results and recommendations\",\n fields: {\n topicId: \"string — canonical topic scope\",\n metric: \"string — analysis metric identifier\",\n payload: \"object — detector results, recommendations, graph metrics\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const LIST_GRAPH_INTELLIGENCE_QUERIES: McpToolContract = {\n name: \"list_graph_intelligence_queries\",\n description:\n \"List the Graph Intelligence query catalog that powers structural graph analysis experiences. \" +\n \"Returns categories, query IDs, prompt templates, modes, and the public tool plan each query can use.\",\n parameters: {\n categoryId: {\n type: \"string\",\n description: \"Optional category filter, such as problems or strategic\",\n },\n mode: {\n type: \"string\",\n description:\n \"Optional mode filter: core, bias, stress, operational, alpha, semantic, or evidence\",\n },\n },\n required: [],\n response: {\n description:\n \"Graph Intelligence query catalog and mode-to-tool mapping\",\n fields: {\n categories: \"array — query categories\",\n queries: \"array — query definitions with prompt templates and tools\",\n quickQueries: \"array — recommended one-click query presets\",\n publicToolNamesByMode:\n \"object — public tool names available to each Graph Intelligence mode\",\n },\n },\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const RUN_GRAPH_INTELLIGENCE_QUERY: McpToolContract = {\n name: \"run_graph_intelligence_query\",\n description:\n \"Run a named Graph Intelligence query against a tenant topic graph. \" +\n \"Returns the selected query, prompt, deterministic graph-analysis bundle, graph context, and public tool plan for model synthesis.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n queryId: {\n type: \"string\",\n description:\n \"Graph Intelligence query ID, such as confirmation-bias, pre-mortem, or thesis-summary\",\n },\n prompt: {\n type: \"string\",\n description: \"Optional custom prompt for custom analysis runs\",\n },\n input: {\n type: \"string\",\n description:\n \"Optional entity, theme, belief, company, or search text for input-driven queries\",\n },\n mode: {\n type: \"string\",\n description:\n \"Optional mode override: core, bias, stress, operational, alpha, semantic, or evidence\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum graph context rows to return\",\n },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Graph Intelligence query result bundle ready for model or prompt-library synthesis\",\n fields: {\n query: \"object — selected query definition\",\n prompt: \"string — resolved prompt template\",\n toolPlan: \"array — public tools and args the model can call next\",\n analysis:\n \"object — structure, coverage, gap, and confirmation-bias analysis\",\n context: \"object — sampled beliefs, questions, evidence, edges, and contradictions\",\n },\n },\n ownerModule: \"graph-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_FALSIFICATION_QUESTIONS: McpToolContract = {\n name: \"get_falsification_questions\",\n description:\n \"Generate Popperian falsification questions for beliefs. \" +\n \"Like `git test` — identifies the questions most likely to disprove current beliefs. \" +\n \"Karl Popper as a tool: surfaces what would need to be true to invalidate each belief.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic to analyze\" },\n beliefIds: { type: \"array\", description: \"Specific beliefs to target\" },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Questions with falsification potential scores and target beliefs\",\n fields: {\n questions:\n \"array — { questionText, falsificationPotential, targetBeliefId, targetBeliefText }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// EVIDENCE OPERATION TOOLS\n// =============================================================================\n\nexport const SEARCH_EVIDENCE: McpToolContract = {\n name: \"search_evidence\",\n description:\n \"Search for evidence across the reasoning graph. \" +\n \"Like `git grep` — returns the evidence records that best match a textual query. \" +\n \"Results share the same canonical semantics as the HTTP and SDK evidence search surface.\",\n parameters: {\n q: { type: \"string\", description: \"Search text\" },\n topicId: { type: \"string\", description: \"Topic scope filter\" },\n targetId: {\n type: \"string\",\n description: \"Optional belief or question identifier to scope the search\",\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [\"q\"],\n response: {\n description: \"Canonical evidence search results page\",\n fields: {\n results:\n \"array — { evidenceId, nodeId, globalId?, text, source?, kind?, relevanceScore }\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const CREATE_EVIDENCE: McpToolContract = {\n name: \"create_evidence\",\n description:\n \"Commit evidence to the reasoning graph. \" +\n \"Like `git commit` — creates a traceable evidence record with canonical public IDs. \" +\n \"Evidence creation must link to at least one belief and must include a signed impact score. \" +\n \"Positive scores support the belief; negative scores contradict it. SL confidence is derived from these weighted evidence relations.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n text: { type: \"string\", description: \"Canonical evidence text\" },\n source: { type: \"string\", description: \"Source URL or source label\" },\n targetId: {\n type: \"string\",\n description: \"Belief identifier to link immediately\",\n },\n weight: {\n type: \"number\",\n description:\n \"Required nonzero signed impact score: -1.0 (contradicts) to +1.0 (supports).\",\n },\n evidenceRelation: {\n type: \"string\",\n enum: [\"supports\", \"contradicts\"],\n description:\n \"Canonical relation to targetId/linkedBeliefNodeId. Prefer this over relying on signed weight inference.\",\n },\n confidence: {\n type: \"number\",\n description:\n \"Deprecated hint. Runtime confidence is derived from the signed impact score.\",\n },\n beliefRelations: {\n type: \"array\",\n description:\n \"Optional additional belief relations: [{ beliefId|beliefNodeId|targetId, evidenceRelation|relation, confidence?, weight?, rationale? }]. Use one evidence node with multiple relations when the same fact supports or contradicts several beliefs.\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional metadata merged into the canonical evidence node\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this evidence should enter the reasoning graph\",\n },\n title: { type: \"string\", description: \"Optional short title\" },\n content: { type: \"string\", description: \"Optional long-form content\" },\n contentType: {\n type: \"string\",\n description: \"Optional content format or MIME hint\",\n },\n kind: { type: \"string\", description: \"Optional evidence kind\" },\n },\n required: [\"text\", \"rationale\", \"weight\"],\n response: {\n description: \"The created canonical evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n text: \"string\",\n topicId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const GET_EVIDENCE: McpToolContract = {\n name: \"get_evidence\",\n description:\n \"Read one evidence record by ID. \" +\n \"Like `git show` — resolves the canonical evidence payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical evidence ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n text: \"string\",\n topicId: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const LIST_EVIDENCE: McpToolContract = {\n name: \"list_evidence\",\n description:\n \"List evidence records within a topic or linked to a target. \" +\n \"Like `git log -- path` — returns the canonical evidence page for a topic, belief, or question scope.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope filter\" },\n targetId: {\n type: \"string\",\n description: \"Optional belief or question identifier to scope by linkage\",\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [],\n response: {\n description: \"Canonical evidence page\",\n fields: {\n evidence: \"array — canonical evidence records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_EVIDENCE: McpToolContract = {\n name: \"archive_evidence\",\n description:\n \"Archive an evidence record while preserving its reasoning history. \" +\n \"Like `git rm` — removes evidence from active workflows without erasing the audit trail. \" +\n \"Use this for evidence hygiene after the evidence has been superseded, corrected, or ruled out.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical evidence ID\" },\n evidenceId: { type: \"string\", description: \"Evidence ID alias\" },\n nodeId: { type: \"string\", description: \"Evidence node ID alias\" },\n insightId: { type: \"string\", description: \"Legacy insight ID alias\" },\n reason: {\n type: \"string\",\n description: \"Why this evidence is being archived\",\n },\n },\n required: [],\n response: {\n description: \"Archive confirmation for the evidence record\",\n fields: {\n id: \"string — canonical evidence ID\",\n evidenceId: \"string — canonical evidence ID\",\n nodeId: \"string — canonical evidence node ID\",\n status: \"string — archived or removed from active evidence views\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE: McpToolContract = {\n name: \"link_evidence\",\n description:\n \"Link evidence to a belief or question. \" +\n \"Like `git notes add` — attaches a supporting or contradicting edge without rewriting the evidence itself.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"Canonical evidence ID\" },\n targetId: {\n type: \"string\",\n description: \"Canonical belief or question ID\",\n },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n rationale: { type: \"string\", description: \"Why this link exists\" },\n },\n required: [\"evidenceId\", \"targetId\", \"weight\"],\n response: {\n description: \"The created canonical evidence edge summary\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n targetId: \"string\",\n targetType: \"string — belief | question\",\n weight: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE_TO_BELIEF: McpToolContract = {\n name: \"link_evidence_to_belief\",\n description:\n \"Link evidence to a belief with a support weight. \" +\n \"Like `git add` — stages evidence in support of (or against) a belief. \" +\n \"The weight ranges from -1.0 (strongly contradicts) to +1.0 (strongly supports). \" +\n \"This relation appends to the SL confidence ledger; do not hand-write confidence separately.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"The evidence node ID\" },\n beliefId: { type: \"string\", description: \"The belief node ID\" },\n weight: {\n type: \"number\",\n description: \"Support weight: -1.0 (contradicts) to +1.0 (supports)\",\n },\n evidenceRelation: {\n type: \"string\",\n enum: [\"supports\", \"contradicts\"],\n description:\n \"Canonical semantic relation. If omitted, the sign of weight is used.\",\n },\n confidence: {\n type: \"number\",\n description: \"Confidence in this evidence-to-belief relation, 0.0 to 1.0\",\n },\n rationale: { type: \"string\", description: \"Why this evidence is relevant\" },\n },\n required: [\"evidenceId\", \"beliefId\", \"weight\"],\n response: {\n description: \"The created edge linking evidence to belief\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n beliefId: \"string\",\n weight: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// QUESTION OPERATION TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CREATE_QUESTION: McpToolContract = {\n name: \"create_question\",\n description:\n \"Commit an investigation question to the reasoning graph. \" +\n \"Like `git issue` — creates a traceable question that drives research and evidence collection. \" +\n \"Questions test beliefs and guide worktree investigation.\",\n parameters: {\n text: { type: \"string\", description: \"The question text\" },\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n priority: {\n type: \"string\",\n description: \"Priority: urgent, high, medium, low\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Belief this question tests\",\n },\n metadata: {\n type: \"object\",\n description: \"Optional metadata merged into the question record\",\n },\n },\n required: [\"text\"],\n response: {\n description: \"The created canonical question record\",\n fields: {\n id: \"string — canonical question ID\",\n nodeId: \"string — canonical question ID\",\n questionId: \"string — canonical question ID\",\n text: \"string\",\n status: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const GET_QUESTION: McpToolContract = {\n name: \"get_question\",\n description:\n \"Read one question by ID. \" +\n \"Like `git show` — resolves the canonical question payload for a single identifier.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical question ID\" },\n },\n required: [\"id\"],\n response: {\n description: \"The canonical question record\",\n fields: {\n id: \"string — canonical question ID\",\n nodeId: \"string — canonical question ID\",\n questionId: \"string — canonical question ID\",\n text: \"string\",\n status: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const REFINE_QUESTION: McpToolContract = {\n name: \"refine_question\",\n description:\n \"Refine a question's framing or scope. \" +\n \"Like `git commit --amend` for questions — updates the question text, scope, or worktree link \" +\n \"while preserving its identity and linked evidence.\",\n parameters: {\n id: { type: \"string\", description: \"The question to refine\" },\n text: { type: \"string\", description: \"Updated question text\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Worktree this existing question belongs to\",\n },\n rationale: {\n type: \"string\",\n description: \"Why the question is being refined\",\n },\n },\n required: [\"id\"],\n response: {\n description: \"The refined question\",\n fields: {\n id: \"string\",\n questionId: \"string\",\n updatedText: \"string\",\n previousText: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const LIST_QUESTIONS: McpToolContract = {\n name: \"list_questions\",\n description:\n \"List questions scoped to a topic or worktree. \" +\n \"Like `git issue list` — returns questions with their status, priority, and linked belief context. \" +\n \"Supports filtering by status and priority.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n worktreeId: { type: \"string\", description: \"Filter to worktree scope\" },\n status: {\n type: \"string\",\n description: \"Filter by canonical question status\",\n enum: [\"open\", \"researching\", \"answered\", \"parked\", \"closed\"],\n },\n priority: {\n type: \"string\",\n description: \"Filter by canonical question priority\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n limit: { type: \"number\", description: \"Max results\" },\n cursor: { type: \"string\", description: \"Pagination cursor\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Canonical question page\",\n fields: {\n questions: \"array — canonical question records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const ANSWER_QUESTION: McpToolContract = {\n name: \"answer_question\",\n description:\n \"Answer a question with optional evidence links. \" +\n \"Like `git commit` on the question thread — records the answer and closes the loop with a canonical answered state.\",\n parameters: {\n id: { type: \"string\", description: \"Canonical question ID\" },\n topicId: { type: \"string\", description: \"Topic scope for the answer\" },\n text: { type: \"string\", description: \"Answer text\" },\n confidence: {\n type: \"string\",\n description: \"Optional answer confidence\",\n enum: [\"weak\", \"medium\", \"strong\"],\n },\n evidenceIds: {\n type: \"array\",\n description: \"Optional canonical evidence IDs supporting the answer\",\n },\n rationale: { type: \"string\", description: \"Why this answer is credible\" },\n },\n required: [\"id\", \"topicId\", \"text\"],\n response: {\n description: \"Answer result\",\n fields: {\n questionId: \"string\",\n answerId: \"string\",\n status: \"string — answered\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_QUESTION_STATUS: McpToolContract = {\n name: \"update_question_status\",\n description:\n \"Transition a question's status through its lifecycle. \" +\n \"Like `git issue update` — moves a question through the canonical reasoning lifecycle. \" +\n \"Status transitions preserve history and keep linked evidence intact.\",\n parameters: {\n id: { type: \"string\", description: \"The question to update\" },\n status: {\n type: \"string\",\n description: \"New status\",\n enum: [\"open\", \"researching\", \"answered\", \"parked\", \"closed\"],\n },\n rationale: { type: \"string\", description: \"Why the status is changing\" },\n },\n required: [\"id\", \"status\"],\n response: {\n description: \"Updated question status\",\n fields: {\n id: \"string\",\n questionId: \"string\",\n previousStatus: \"string\",\n newStatus: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_QUESTION: McpToolContract = {\n name: \"archive_question\",\n description:\n \"Archive a question no longer relevant to current investigation scope. \" +\n \"Like `git issue close` — removes it from active work while preserving audit history. \" +\n \"Archived questions keep their existing links to beliefs and evidence.\",\n parameters: {\n questionId: { type: \"string\", description: \"The question to archive\" },\n reason: {\n type: \"string\",\n description: \"Why the question is being archived\",\n },\n },\n required: [\"questionId\"],\n response: {\n description: \"Archive confirmation\",\n fields: {\n questionId: \"string\",\n status: \"string — 'archived'\",\n archivedAt: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const LINK_EVIDENCE_TO_QUESTION: McpToolContract = {\n name: \"link_evidence_to_question\",\n description:\n \"Link evidence to the question it helps answer. \" +\n \"Like `git notes add` — attaches supporting detail to an active question. \" +\n \"Question-level links improve answer quality and traceability to beliefs.\",\n parameters: {\n evidenceId: { type: \"string\", description: \"The evidence to link\" },\n questionId: {\n type: \"string\",\n description: \"The question this evidence addresses\",\n },\n relevance: { type: \"number\", description: \"Relevance score in [0,1]\" },\n rationale: {\n type: \"string\",\n description: \"How this evidence bears on the question\",\n },\n },\n required: [\"evidenceId\", \"questionId\"],\n response: {\n description: \"The created edge\",\n fields: {\n edgeId: \"string\",\n evidenceId: \"string\",\n questionId: \"string\",\n relevance: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"edge\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// ANSWER LIFECYCLE TOOLS\n// =============================================================================\n\nexport const CREATE_ANSWER: McpToolContract = {\n name: \"create_answer\",\n description:\n \"Create an answer node responding to a question. \" +\n \"Like `git commit` for resolved questions — creates an immutable answer snapshot at L2. \" +\n \"New answers supersede old ones, preserving full version history. \" +\n \"Answers link to supporting evidence via based_on edges.\",\n parameters: {\n questionNodeId: {\n type: \"string\",\n description: \"The question node ID this answers\",\n },\n answerText: {\n type: \"string\",\n description: \"The answer content — the actual response to the question\",\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope (optional if question already has topicId)\",\n },\n confidence: {\n type: \"string\",\n description:\n \"Answer confidence: definitive, strong, moderate, weak, speculative\",\n },\n evidenceNodeIds: {\n type: \"array\",\n description: \"Supporting evidence node IDs to link via based_on edges\",\n },\n answerSource: {\n type: \"string\",\n description:\n \"How the answer was produced: human, ai_generated, deep_research, synthesis\",\n },\n },\n required: [\"questionNodeId\", \"answerText\"],\n response: {\n description: \"The created answer node with version metadata\",\n fields: {\n nodeId: \"string — unique node identifier\",\n globalId: \"string — globally unique ID\",\n versionNumber: \"number — version of this answer (auto-incremented)\",\n questionNodeId: \"string — the question this answers\",\n confidence: \"string — answer confidence level\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\nexport const GET_ANSWER: McpToolContract = {\n name: \"get_answer\",\n description:\n \"Get the latest answer for a question. \" +\n \"Like `git show HEAD` for a question's resolution — returns the active answer snapshot. \" +\n \"Returns null if the question is unanswered.\",\n parameters: {\n questionNodeId: {\n type: \"string\",\n description: \"The question node ID to get the answer for\",\n },\n },\n required: [\"questionNodeId\"],\n response: {\n description: \"The active answer node or null\",\n fields: {\n nodeId: \"string | null\",\n globalId: \"string | null\",\n answerText: \"string | null\",\n versionNumber: \"number\",\n isLatest: \"boolean\",\n evidenceCount: \"number\",\n confidence: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n};\n\nexport const GET_HIGH_PRIORITY_QUESTIONS: McpToolContract = {\n name: \"get_high_priority_questions\",\n description:\n \"Rank open questions by urgency and expected decision impact. \" +\n \"Like `git issue list --sort=priority` — brings the highest-leverage open questions to the top. \" +\n \"Ranking accounts for linked belief criticality and evidence gaps.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n limit: { type: \"number\", description: \"Maximum results (default: 20)\" },\n includeAnswered: {\n type: \"boolean\",\n description: \"Include answered questions (default: false)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Priority-ranked questions\",\n fields: {\n questions:\n \"array — { questionId, text, priority, urgencyScore, linkedBeliefCount, evidenceGapCount }\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\nexport const FIND_MISSING_QUESTIONS: McpToolContract = {\n name: \"find_missing_questions\",\n description:\n \"Identify beliefs missing testing questions. \" +\n \"Like `git diff --check` — surfaces reasoning coverage gaps before merge. \" +\n \"Returns candidate beliefs that need explicit question coverage.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n minConfidence: {\n type: \"number\",\n description: \"Only check beliefs above this confidence (default: 0)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Beliefs missing testing questions\",\n fields: {\n gaps: \"array — { beliefId, canonicalText, confidence, suggestedQuestions }\",\n totalGaps: \"number\",\n },\n },\n ownerModule: \"graph-search\",\n ontologyPrimitive: \"question\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// LISTING & QUERY TOOLS\n// =============================================================================\n\nexport const LIST_BELIEFS: McpToolContract = {\n name: \"list_beliefs\",\n description:\n \"List beliefs scoped to a topic or worktree. \" +\n \"Like `git log --oneline` — returns beliefs with their confidence, status, and scoring state. \" +\n \"Supports filtering by status and confidence threshold.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n worktreeId: { type: \"string\", description: \"Filter to worktree scope\" },\n status: {\n type: \"string\",\n description: \"Filter: unscored, scored, archived\",\n enum: [\"unscored\", \"scored\", \"archived\"],\n },\n minConfidence: {\n type: \"number\",\n description: \"Minimum confidence threshold\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum results\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Canonical belief page\",\n fields: {\n beliefs: \"array — canonical belief records\",\n nextCursor: \"string | null\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const LIST_WORKTREES: McpToolContract = {\n name: \"list_worktrees\",\n description:\n \"List all worktrees for a topic. \" +\n \"Like `git worktree list` — shows active and completed investigation branches \" +\n \"with lifecycle phase, pipeline campaign/lane, status, and belief counts.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n status: {\n type: \"string\",\n description: \"Filter: active, merged, abandoned\",\n enum: [\"active\", \"merged\", \"abandoned\"],\n },\n groupBy: {\n type: \"string\",\n description: \"Optional grouping mode for the response.\",\n enum: [\"campaign\", \"lane\", \"flat\"],\n },\n lane: {\n type: \"string\",\n description: \"Filter by GitButler-aligned lane name.\",\n },\n campaign: {\n type: \"number\",\n description: \"Filter by top-level pipeline campaign number.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum results to return.\",\n },\n },\n required: [\"topicId\"],\n response: {\n description:\n \"Worktrees with lifecycle phase, campaign, lane, status, belief count, and creation time\",\n fields: {\n worktrees:\n \"array — { worktreeId, title, phase, campaign, lane, laneOrderInCampaign, orderInLane, status, beliefCount, createdAt }\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const LIST_ALL_WORKTREES: McpToolContract = {\n name: \"list_all_worktrees\",\n description:\n \"List ALL worktrees across ALL topics in one query. No topic scope required. \" +\n \"Like `git worktree list --all` — returns the complete pipeline inventory with \" +\n \"campaign, lane, lane order, dependencies, and status. \" +\n \"Supports filtering by status, lane, and campaign. \" +\n \"This is the PM's primary pipeline query — one call, full picture.\",\n parameters: {\n status: {\n type: \"string\",\n description:\n \"Filter by status: planning, active, completed, abandoned, superseded, long_term, idea, paused, suggested, dismissed\",\n enum: [\n \"planning\",\n \"active\",\n \"completed\",\n \"abandoned\",\n \"superseded\",\n \"long_term\",\n \"idea\",\n \"paused\",\n \"suggested\",\n \"dismissed\",\n ],\n },\n lane: {\n type: \"string\",\n description:\n \"Filter by lane name (e.g., 'ontology', 'tc-scope', 'control-plane', 'dev-portal', 'mcp-sdk-parity')\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Filter by campaign number (e.g., 1, 2, 3). Returns only worktrees in that campaign.\",\n },\n groupBy: {\n type: \"string\",\n description: \"Optional grouping mode for the response.\",\n enum: [\"campaign\", \"lane\", \"flat\"],\n },\n limit: {\n type: \"number\",\n description: \"Maximum results to return (default: 500, max: 1000)\",\n },\n },\n required: [],\n response: {\n description: \"All worktrees across all topics with full pipeline metadata\",\n fields: {\n worktrees:\n \"array — { worktreeId, title, topicId, topicName, phase, status, hypothesis, campaign, lane, laneOrderInCampaign, orderInLane, dependsOn, blocks, gate, createdAt }\",\n total: \"number — total count after filtering\",\n lanes: \"object — { laneName: count } summary of worktrees per lane\",\n campaigns:\n \"object — { campaignNumber: count } summary of worktrees per campaign\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const GET_WORKTREE: McpToolContract = {\n name: \"get_worktree\",\n description:\n \"Get one worktree by ID. \" +\n \"Like `git worktree list --porcelain <worktree>` — inspects one investigation branch without scanning the full pipeline inventory.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"Canonical worktree ID to retrieve\" },\n id: { type: \"string\", description: \"Legacy alias for worktreeId\" },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Single worktree record with pipeline metadata\",\n fields: {\n worktree:\n \"object — { worktreeId, title, topicId, status, hypothesis, campaign, lane, laneOrderInCampaign, orderInLane, dependsOn, blocks, gate }\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const LIST_CAMPAIGNS: McpToolContract = {\n name: \"list_campaigns\",\n description:\n \"List compact pipeline campaigns with their nested lanes. \" +\n \"Use this to see the top-level campaign > lane > worktree shape without pulling the full worktree inventory.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope.\",\n },\n status: {\n type: \"string\",\n description:\n \"Optional worktree status filter before grouping campaigns and lanes.\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum worktrees to scan before grouping.\",\n },\n },\n required: [],\n response: {\n description: \"Pipeline campaigns with nested lane summaries.\",\n fields: {\n campaigns:\n \"array — { campaign, lanes: [{ lane, laneOrderInCampaign, worktreeCount, activeCount, readyCount, blockedCount, completedCount, nextWorktree }] }\",\n totalWorktrees: \"number — total worktrees scanned after filtering\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n};\n\nexport const ACTIVATE_WORKTREE: McpToolContract = {\n name: \"activate_worktree\",\n description:\n \"Activate a worktree to begin investigation. \" +\n \"Like `git checkout <branch>` — transitions a worktree from planning to active status. \" +\n \"Sets the initial phase and enables belief/question editing within the worktree scope.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to activate\" },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Activation result with initial phase\",\n fields: {\n worktreeId: \"string\",\n status: \"string — 'active'\",\n phase: \"string\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_WORKTREE_TARGETS: McpToolContract = {\n name: \"update_worktree_targets\",\n description:\n \"Update the target beliefs and questions tracked by a worktree. \" +\n \"Like `git add/rm <files>` — stages or unstages beliefs/questions for investigation \" +\n \"within the worktree scope. Supports adding and removing targets atomically.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to update\" },\n addBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs to add to the worktree\",\n },\n addQuestionIds: {\n type: \"array\",\n description: \"Question node IDs to add to the worktree\",\n },\n removeBeliefIds: {\n type: \"array\",\n description: \"Belief node IDs to remove from the worktree\",\n },\n removeQuestionIds: {\n type: \"array\",\n description: \"Question node IDs to remove from the worktree\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Updated target counts\",\n fields: {\n worktreeId: \"string\",\n beliefCount: \"number\",\n questionCount: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_WORKTREE_METADATA: McpToolContract = {\n name: \"update_worktree_metadata\",\n description:\n \"Update worktree sequencing metadata — campaign, lane, dependencies, blocking relations, and gates. \" +\n \"Like `git config` for a worktree — sets the scheduling and dependency metadata that determines \" +\n \"when this worktree can activate relative to others. Use to backfill or correct sequencing data.\",\n parameters: {\n worktreeId: { type: \"string\", description: \"The worktree to update\" },\n hypothesis: {\n type: \"string\",\n description: \"Testable claim this worktree investigates\",\n },\n campaign: {\n type: \"number\",\n description: \"Top-level pipeline campaign number.\",\n },\n lane: {\n type: \"string\",\n description:\n \"GitButler-aligned workstream lane name inside the campaign.\",\n },\n laneOrderInCampaign: {\n type: \"number\",\n description: \"Ordering for this lane within the campaign.\",\n },\n orderInLane: {\n type: \"number\",\n description: \"Position of this worktree inside its lane.\",\n },\n dependsOn: {\n type: \"array\",\n description:\n \"Worktree IDs that must complete before this one can activate\",\n },\n blocks: {\n type: \"array\",\n description: \"Worktree IDs that are blocked until this one completes\",\n },\n gate: {\n type: \"string\",\n description: \"Exit gate name (e.g., 'gate:ontology-schema-hardened')\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this worktree is sequenced here\",\n },\n objective: {\n type: \"string\",\n description: \"What we're trying to learn/prove\",\n },\n proofArtifacts: {\n type: \"array\",\n description:\n \"Typed proof artifacts that define what evidence or deliverables this worktree must emit before it can claim success.\",\n },\n staffingHint: {\n type: \"string\",\n description:\n \"Advisory staffing shape for the worktree (for example `backend+tests` or `fullstack`).\",\n },\n lastReconciledAt: {\n type: \"number\",\n description:\n \"Timestamp of the last deterministic workflow reconciliation pass against this worktree.\",\n },\n autoFixPolicy: {\n type: \"object\",\n description:\n \"Calibrated auto-fix policy controlling dry-run vs safe execution, per-run action caps, and permitted mutation tiers.\",\n },\n status: {\n type: \"string\",\n description:\n \"Override the worktree status. Use for lifecycle transitions like marking a worktree superseded, long-term, or as a raw idea.\",\n enum: [\n \"suggested\",\n \"planning\",\n \"active\",\n \"paused\",\n \"completed\",\n \"dismissed\",\n \"abandoned\",\n \"superseded\",\n \"long_term\",\n \"idea\",\n ],\n },\n topicId: {\n type: \"string\",\n description:\n \"Reassign this worktree's primary topic. Validates the target topic exists before updating.\",\n },\n additionalTopicIds: {\n type: \"array\",\n description:\n \"Set additional topic associations for cross-topic worktrees. Each topic ID is validated before updating. \" +\n \"Use when a worktree spans multiple knowledge domains.\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"Update confirmation\",\n fields: { worktreeId: \"string\", success: \"boolean\" },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"worktree\",\n tier: \"workhorse\",\n};\n\nexport const IDENTITY_WHOAMI: McpToolContract = {\n name: \"identity_whoami\",\n description:\n \"Read the authenticated identity summary for the current session. \" +\n \"Like `git config --get user.name` — shows who the current MCP session is acting as.\",\n parameters: {},\n required: [],\n response: {\n description: \"Canonical identity summary for the current session\",\n fields: {\n principalId:\n \"string — canonical principal identifier; for humans this is the Clerk user_... ID\",\n principalType: \"string — human, service, agent, group, or external_viewer\",\n tenantId: \"string | undefined — resolved tenant scope\",\n workspaceId: \"string | undefined — resolved workspace scope\",\n scopes: \"string[] | undefined — granted scopes for this session\",\n roles: \"string[] | undefined — canonical roles for this session\",\n },\n },\n ownerModule: \"identity-core\",\n ontologyPrimitive: \"identity\",\n tier: \"workhorse\",\n};\n\nexport const RESOLVE_INTERACTIVE_PRINCIPAL: McpToolContract = {\n name: \"resolve_interactive_principal\",\n description:\n \"Read the Permit-backed Lucern principal context for an authenticated Clerk user. \" +\n \"Like `git config --get user.email` plus the repository ACL — resolves the Clerk subject into tenant/workspace authorization context.\",\n parameters: {\n clerkId: {\n type: \"string\",\n description: \"Authenticated Clerk subject (`sub`). Clerk proves identity only; it is not the authorization record.\",\n },\n tenantId: {\n type: \"string\",\n description: \"Optional tenant scope. Omit only when the Clerk alias is globally unambiguous.\",\n },\n workspaceId: {\n type: \"string\",\n description: \"Optional workspace scope. Required when the principal has access to multiple workspaces and no default can be inferred.\",\n },\n providerProjectId: {\n type: \"string\",\n description: \"Optional Clerk project or provider instance id for tenants with multiple identity providers.\",\n },\n },\n required: [\"clerkId\"],\n response: {\n description: \"Permit-backed Lucern principal context for tenant SDK bootstrap\",\n fields: {\n principalId:\n \"string — canonical Clerk user_... ID for human sessions\",\n principalType: \"string — human, service, agent, group, or external_viewer\",\n clerkId: \"string — authenticated Clerk subject alias\",\n tenantId: \"string — resolved tenant scope\",\n workspaceId: \"string | null — resolved workspace scope\",\n roles: \"string[] — effective Permit roles\",\n scopes: \"string[] — effective scopes derived from Permit/control-plane projection\",\n groupIds: \"string[] — active Permit group memberships\",\n principalStatus: \"string — active, invited, suspended, disabled, revoked, or missing\",\n tenantStatus: \"string — projected tenant resource status\",\n workspaceStatus: \"string — projected workspace resource status\",\n permit: \"object — Permit subject, tenant, and optional workspace tuple\",\n },\n },\n ownerModule: \"control-plane\",\n ontologyPrimitive: \"identity\",\n tier: \"workhorse\",\n};\n\nexport const COMPILE_CONTEXT: McpToolContract = {\n name: \"compile_context\",\n description:\n \"Compile a focused reasoning context. If topicId is omitted, Lucern resolves the best topic from the query. \" +\n \"Like `git log --graph --decorate` for the reasoning substrate — returns the canonical Pillar 3 context pack through the public API shape.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope ID. Omit to resolve the topic from query.\",\n },\n query: {\n type: \"string\",\n description:\n \"Focus query used to resolve the topic and rank context items. Required when topicId is omitted.\",\n },\n topicHint: {\n type: \"string\",\n description:\n \"Optional natural-language topic hint used by the resolver when topicId is omitted or stale.\",\n },\n tags: {\n type: \"array\",\n description:\n \"Optional resolver tags. Useful for narrowing topic inference without knowing the exact topic id.\",\n },\n touchedPaths: {\n type: \"array\",\n description:\n \"Optional file or documentation paths used as resolver signals.\",\n },\n sourceRef: {\n type: \"string\",\n description:\n \"Optional source reference used as a resolver signal, such as a worktree id, PR, or feature slug.\",\n },\n sourceKind: {\n type: \"string\",\n description:\n \"Optional source kind used as a resolver signal, such as cli, worktree, commit, or docs.\",\n },\n campaign: {\n type: \"number\",\n description:\n \"Optional campaign dimension seed. When supplied without topicId, the compiler fans out across all carrier topics for that campaign instead of resolving a single topic.\",\n },\n lane: {\n type: \"string\",\n description:\n \"Optional lane dimension seed. When supplied without topicId, the compiler reads all matching worktrees and their carrier topics.\",\n },\n status: {\n type: \"string\",\n description:\n \"Optional state/status dimension seed for worktrees and graph rows.\",\n },\n principalId: {\n type: \"string\",\n description:\n \"Optional principal seed for work authored, touched, or owned by a human, agent, group, or service principal.\",\n },\n workspaceId: {\n type: \"string\",\n description:\n \"Optional workspace seed used by hosted MCP and SDK clients when compiling tenant-scoped context.\",\n },\n budget: {\n type: \"number\",\n description: \"Token budget for prompt injection planning\",\n },\n tokenBudget: {\n type: \"number\",\n description:\n \"Compatibility alias for budget. External MCP clients may send tokenBudget when requesting prompt injection planning.\",\n },\n ranking: {\n type: \"string\",\n description: \"Ranking profile for context ordering\",\n enum: [\"baseline_v1\", \"weighted_v1\"],\n },\n limit: {\n type: \"number\",\n description: \"Optional per-section item limit\",\n },\n contentTopicLimit: {\n type: \"number\",\n description:\n \"Dimension-seeded compiles synthesize every matching worktree but bound raw belief/question/evidence enrichment to this many carrier topics (max 16) so hosted Convex queries remain fast. Receipts report any omitted raw topic enrichment.\",\n },\n maxDepth: {\n type: \"number\",\n description: \"Optional descendant topic depth for neighborhood expansion\",\n },\n traversalMode: {\n type: \"string\",\n description:\n \"Optional C2-LK.2 traversal mode declaration for strict context compilation.\",\n enum: [\n \"anchored_ranked\",\n \"bounded_exploration\",\n \"contradiction_scan\",\n \"pattern_recall\",\n \"forensic_replay\",\n ],\n },\n requestedDepth: {\n type: \"string\",\n description:\n \"Optional C2-LK.2 constitutional depth declaration for context compilation.\",\n enum: [\"low\", \"medium\", \"high\", \"extra-high\"],\n },\n includeEntities: {\n type: \"boolean\",\n description: \"Include related ontological entities in the compiled result\",\n },\n },\n required: [],\n response: {\n description: \"Compiled context pack for the requested topic\",\n fields: {\n contextNarrative:\n \"array — first field; ordered synthesis blocks with kind/text, starting with executive_summary and canonical narrative blocks before raw objects\",\n narrativeCoverage:\n \"object — recordsSynthesized, recordsNamed, recordsOmitted, topicsSynthesized, topicsEnriched, topicContentOmitted, enrichmentMode, and blocksEmitted for the narrative\",\n synthesisLints:\n \"array — inline quality warnings for degenerate synthesis blocks or weak narrative coverage\",\n retrievalReceipt:\n \"object — candidateCounts, coverageWarning, narrativeCoverage, synthesisLints, and suggestedNextActions\",\n supportingObjects:\n \"object — raw graph records grouped behind the synthesis: invariants, activeBeliefs, openQuestions, recentEvidence, worktrees, lanes, entities, and contradictions\",\n schemaVersion: \"string\",\n topicId: \"string\",\n topicName: \"string\",\n scopedTopicIds: \"array — topic IDs included in the compilation neighborhood\",\n generatedAt:\n \"number — deterministic graph-backed reference timestamp for this compilation\",\n ranking: \"string — baseline_v1 | weighted_v1\",\n summary: \"object — counts and scoped health signals\",\n injectionPolicy: \"object — token-budgeted section selections\",\n diagnostics: \"object — scoring and utilization telemetry\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// POLICY / ACL TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const CHECK_PERMISSION: McpToolContract = {\n name: \"check_permission\",\n description:\n \"Check whether a principal can read or mutate a topic scope. \" +\n \"Like `git check-ref-format` for ACLs — validates whether the requested operation is allowed before execution.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope to evaluate\" },\n permission: {\n type: \"string\",\n description: \"Permission to evaluate\",\n enum: [\"read\", \"write\"],\n },\n principal: {\n type: \"string\",\n description:\n \"Optional principal override (defaults to current principal)\",\n },\n beliefClusterId: {\n type: \"string\",\n description: \"Optional neighborhood scope within a topic\",\n },\n },\n required: [\"topicId\", \"permission\"],\n response: {\n description: \"Permission evaluation result\",\n fields: {\n allowed: \"boolean\",\n decision: \"string — allow | deny\",\n reasonCode: \"string\",\n principalId: \"string\",\n topicId: \"string\",\n permission: \"string — read | write\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\nexport const FILTER_BY_PERMISSION: McpToolContract = {\n name: \"filter_by_permission\",\n description:\n \"Filter a topic set down to ACL-authorized topics. \" +\n \"Like `git rev-list --ancestry-path` for policy boundaries — keeps only topics permitted for the requested action.\",\n parameters: {\n topicIds: { type: \"array\", description: \"Topic IDs to evaluate\" },\n permission: {\n type: \"string\",\n description: \"Permission filter\",\n enum: [\"read\", \"write\"],\n },\n principal: {\n type: \"string\",\n description: \"Optional principal override (tenant admin only)\",\n },\n },\n required: [\"topicIds\", \"permission\"],\n response: {\n description: \"Allowed/denied split for the requested topic set\",\n fields: {\n permission: \"string — read | write\",\n allowedTopicIds: \"array — topic IDs allowed by policy\",\n deniedTopics: \"array — { topicId, reasonCode }\",\n count: \"number\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\nexport const COMPILE_CAPABILITY_SLICE: McpToolContract = {\n name: \"compile_capability_slice\",\n description:\n \"Compile a Permit-clipped graph capability slice. \" +\n \"Like `git sparse-checkout` for policy-visible reasoning — returns allowed objects plus public-safe omission records.\",\n parameters: {\n sliceUuid: { type: \"string\", description: \"Stable slice UUID or request id\" },\n context: {\n type: \"string\",\n description:\n \"Slice context such as context_compile, graph_traversal, source_horizon, output_export, or agent_run\",\n },\n surface: {\n type: \"string\",\n description: \"Caller surface such as mcp, sdk, cli, rest, web, or agent\",\n },\n baseFacts: {\n type: \"object\",\n description: \"Graph policy facts for the root resource and principal\",\n },\n nodes: {\n type: \"array\",\n description: \"Candidate graph nodes/resources to clip\",\n },\n edges: {\n type: \"array\",\n description: \"Candidate graph edges to clip\",\n },\n fallbackPermitDecision: {\n type: \"object\",\n description: \"Fallback Permit decision; omitted decisions fail closed\",\n },\n permitDecisionsByResourceId: {\n type: \"object\",\n description: \"Permit decisions keyed by resourceId after PDP evaluation\",\n },\n },\n required: [\"baseFacts\", \"nodes\"],\n response: {\n description: \"Permission-clipped capability slice envelope\",\n fields: {\n decision: \"string — allow | allow_with_omissions | deny\",\n visibleNodes: \"array — policy-visible graph nodes/resources\",\n visibleEdges: \"array — policy-visible graph edges\",\n publicOmissionRecords: \"array — public-safe omission records\",\n sealedOmissionRecords: \"array — sealed audit-only omission records\",\n policy: \"object — Permit decision proof envelope\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// OBSERVATION TOOLS\n// =============================================================================\n\nexport const INGEST_OBSERVATION: McpToolContract = {\n name: \"ingest_observation\",\n description:\n \"Record an observational delta for a topic context stream. \" +\n \"Like `git notes add` — attaches structured observation metadata without mutating graph state directly. \" +\n \"Used by watcher/cowork agents to stage candidate updates before explicit write confirmation.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Optional topic scope hint for the observation\",\n },\n observationType: {\n type: \"string\",\n description: \"Observation class\",\n enum: [\n \"claim\",\n \"evidence\",\n \"question\",\n \"contradiction\",\n \"judgment\",\n \"note\",\n ],\n },\n summary: {\n type: \"string\",\n description: \"Human-readable observation summary\",\n },\n source: {\n type: \"string\",\n description: \"Optional source (message ID, tool name, URL, etc.)\",\n },\n confidence: { type: \"number\", description: \"Optional confidence in [0,1]\" },\n tags: { type: \"array\", description: \"Optional observation tags\" },\n metadata: {\n type: \"object\",\n description: \"Optional structured metadata payload\",\n },\n },\n required: [\"observationType\", \"summary\"],\n response: {\n description: \"Recorded observation entry\",\n fields: {\n observationId: \"string\",\n topicId: \"string\",\n observationType: \"string\",\n createdAt: \"number\",\n contextResourceUri: \"string\",\n },\n },\n ownerModule: \"agent-frameworks\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_OBSERVATION_CONTEXT: McpToolContract = {\n name: \"get_observation_context\",\n description:\n \"Retrieve observer-ready context for a topic, including recent deltas and semantic matches. \" +\n \"Like `git log --grep` — shows recent context and filtered matches across observation history. \" +\n \"This powers prompt context injection without mutating graph state.\",\n parameters: {\n topicId: { type: \"string\", description: \"Optional topic scope hint\" },\n query: {\n type: \"string\",\n description: \"Optional semantic query over observation history\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum entries in each returned collection\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Observation context payload\",\n fields: {\n topicId: \"string\",\n totalObservations: \"number\",\n latest: \"array\",\n semanticMatches: \"array\",\n byType: \"object\",\n generatedAt: \"number\",\n },\n },\n ownerModule: \"agent-frameworks\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// TASK LIFECYCLE TOOLS\n// =============================================================================\n\nexport const CREATE_TASK: McpToolContract = {\n name: \"create_task\",\n description:\n \"Create an execution task tied to the reasoning state. \" +\n \"Like `git task` — tracks concrete work items (calls to make, data to gather, analyses to run) \" +\n \"linked to questions, beliefs, or worktrees.\",\n parameters: {\n title: { type: \"string\", description: \"Task title\" },\n topicId: { type: \"string\", description: \"Topic scope\" },\n description: {\n type: \"string\",\n description: \"Long-form task description\",\n },\n taskType: {\n type: \"string\",\n description: \"Task taxonomy\",\n enum: [\n \"general\",\n \"find_evidence\",\n \"verify_claim\",\n \"research\",\n \"review\",\n \"interview\",\n \"analysis\",\n \"track_metrics\",\n ],\n },\n priority: {\n type: \"string\",\n description: \"Priority\",\n enum: [\"urgent\", \"high\", \"medium\", \"low\"],\n },\n status: {\n type: \"string\",\n description: \"Initial status (defaults to todo)\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Worktree this task belongs to\",\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Belief this task supports\",\n },\n linkedQuestionId: {\n type: \"string\",\n description: \"Question this task addresses\",\n },\n assigneeId: {\n type: \"string\",\n description: \"Principal assigned to the task\",\n },\n dueDate: {\n type: \"number\",\n description: \"Due date as epoch milliseconds\",\n },\n tags: {\n type: \"array\",\n description: \"Free-form string tags\",\n },\n metadata: {\n type: \"object\",\n description: \"Structured task metadata for handoff context and routing hints\",\n },\n },\n required: [\"title\"],\n response: {\n description: \"The created task\",\n fields: {\n taskId: \"string\",\n status: \"string — 'pending'\",\n createdAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const COMPLETE_TASK: McpToolContract = {\n name: \"complete_task\",\n description:\n \"Mark a task as complete with an output summary. \" +\n \"Like `git tag` for work items — records the discrete completion event and captures what was learned. \" +\n \"Completed tasks feed back into the evidence graph.\",\n parameters: {\n taskId: { type: \"string\", description: \"The task to complete\" },\n outputSummary: {\n type: \"string\",\n description: \"What was accomplished or learned\",\n },\n evidenceCreated: {\n type: \"boolean\",\n description: \"Whether new evidence was created from this task\",\n },\n },\n required: [\"taskId\", \"outputSummary\"],\n response: {\n description: \"The completed task\",\n fields: {\n taskId: \"string\",\n completedAt: \"number\",\n outputSummary: \"string\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_TASK: McpToolContract = {\n name: \"update_task\",\n description:\n \"Update a task's fields — relink to a different worktree, belief, or question, change title/priority/status. \" +\n \"Like `git task edit` — mutates an existing task in place instead of requiring recreate-plus-supersede.\",\n parameters: {\n taskId: { type: \"string\", description: \"The task to update\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Reassign this task to a different worktree\",\n },\n linkedBeliefId: {\n type: \"string\",\n description: \"Link or relink this task to a belief node\",\n },\n linkedQuestionId: {\n type: \"string\",\n description: \"Link or relink this task to a question node\",\n },\n title: { type: \"string\", description: \"Updated task title\" },\n description: {\n type: \"string\",\n description: \"Updated task description\",\n },\n priority: {\n type: \"string\",\n description: \"Updated priority\",\n enum: [\"critical\", \"high\", \"medium\", \"low\"],\n },\n status: {\n type: \"string\",\n description: \"Updated status\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n metadata: {\n type: \"object\",\n description: \"Structured task metadata to replace or refine\",\n },\n },\n required: [\"taskId\"],\n response: {\n description: \"The updated task\",\n fields: {\n taskId: \"string\",\n updatedAt: \"number\",\n },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\nexport const LIST_TASKS: McpToolContract = {\n name: \"list_tasks\",\n description:\n \"List tasks for a topic or worktree. \" +\n \"Like `git task list` — returns tasks with status, priority, and linked nodes. \" +\n \"Filter by worktree to see tasks for a specific investigation, or by status to find incomplete work.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope\" },\n linkedWorktreeId: {\n type: \"string\",\n description: \"Filter to tasks linked to this worktree\",\n },\n worktreeId: {\n type: \"string\",\n description: \"Alias for linkedWorktreeId\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status: todo, in_progress, blocked, done\",\n enum: [\"todo\", \"in_progress\", \"blocked\", \"done\"],\n },\n limit: { type: \"number\", description: \"Maximum results (default: 100)\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"List of tasks with metadata\",\n fields: { tasks: \"array of task objects\", count: \"number\" },\n },\n ownerModule: \"workflow-engine\",\n ontologyPrimitive: \"task\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// TOPIC TOOLS (git init, git remote)\n// =============================================================================\n\nexport const CREATE_TOPIC: McpToolContract = {\n name: \"create_topic\",\n description:\n \"Create a new topic container for scoping knowledge. \" +\n \"Like `git init` — initializes a new repository for a knowledge domain. \" +\n \"Topics are hierarchical: a deal topic can nest under a theme topic. \" +\n \"Types: domain, theme, deal, strategy, constitution, project, portfolio.\",\n parameters: {\n globalId: {\n type: \"string\",\n description: \"Optional idempotent topic global ID\",\n },\n name: { type: \"string\", description: \"Topic name\" },\n type: {\n type: \"string\",\n description:\n \"Topic type. Validated against schemaEnumConfig category 'topic_type'.\",\n },\n description: { type: \"string\", description: \"What this topic covers\" },\n parentTopicId: {\n type: \"string\",\n description: \"Optional parent topic for nesting\",\n },\n parentTopicGlobalId: {\n type: \"string\",\n description: \"Optional parent topic global ID for nesting\",\n },\n tenantId: { type: \"string\", description: \"Optional tenant scope\" },\n workspaceId: { type: \"string\", description: \"Optional workspace scope\" },\n visibility: {\n type: \"string\",\n description: \"Topic visibility\",\n enum: [\"private\", \"team\", \"firm\", \"external\", \"public\"],\n },\n metadata: { type: \"object\", description: \"Optional topic metadata\" },\n createdBy: { type: \"string\", description: \"Who created this topic\" },\n },\n required: [\"name\", \"type\"],\n response: {\n description: \"The created topic\",\n fields: {\n id: \"string — topic ID\",\n globalId: \"string — globally unique ID\",\n topicGlobalId: \"string — topic global ID\",\n epistemicNodeId: \"string — materialized topic node ID\",\n epistemicNodeGlobalId: \"string — materialized topic node global ID\",\n depth: \"number — nesting depth\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const LIST_TOPICS: McpToolContract = {\n name: \"list_topics\",\n description:\n \"List topics, optionally filtered by type or parent. \" +\n \"Like `git remote -v` — shows all knowledge containers with their types and hierarchy.\",\n parameters: {\n type: {\n type: \"string\",\n description: \"Filter by topic type (e.g., 'theme', 'deal')\",\n },\n parentTopicId: {\n type: \"string\",\n description: \"Filter to children of this parent\",\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\"active\", \"archived\", \"watching\"],\n },\n },\n required: [],\n response: {\n description: \"List of topics with metadata\",\n fields: {\n topics: \"array — { id, name, type, depth, status, parentTopicId }\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC: McpToolContract = {\n name: \"get_topic\",\n description:\n \"Get one topic by ID. \" +\n \"Like `git remote show origin` — inspects a single knowledge container in detail.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Canonical topic ID to retrieve\",\n },\n id: {\n type: \"string\",\n description: \"Legacy alias for topicId\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Single topic record\",\n fields: {\n topic:\n \"object — { id, globalId, name, type, depth, status, parentTopicId, description }\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const UPDATE_TOPIC: McpToolContract = {\n name: \"update_topic\",\n description:\n \"Update an existing topic's metadata. \" +\n \"Like `git remote set-url` — changes the canonical configuration for a knowledge container without recreating it.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Canonical topic ID to update\",\n },\n id: {\n type: \"string\",\n description: \"Legacy alias for topicId\",\n },\n name: { type: \"string\", description: \"Updated topic name\" },\n description: { type: \"string\", description: \"Updated topic description\" },\n type: {\n type: \"string\",\n description:\n \"Updated topic type. Validated against schemaEnumConfig category 'topic_type'.\",\n },\n ontologyId: {\n type: \"string\",\n description: \"Updated ontology binding\",\n },\n clearOntologyId: {\n type: \"boolean\",\n description: \"Clear the current ontology binding\",\n },\n status: {\n type: \"string\",\n description: \"Updated topic status\",\n enum: [\"active\", \"archived\", \"watching\"],\n },\n visibility: {\n type: \"string\",\n description: \"Updated topic visibility\",\n enum: [\"private\", \"team\", \"firm\", \"external\", \"public\"],\n },\n },\n required: [],\n response: {\n description: \"The updated topic\",\n fields: {\n id: \"string — topic ID\",\n globalId: \"string — globally unique ID\",\n status: \"string — topic lifecycle status\",\n visibility: \"string — topic visibility\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC_TREE: McpToolContract = {\n name: \"get_topic_tree\",\n description:\n \"Get the full topic hierarchy from a root. \" +\n \"Like `git log --graph --all` — shows the complete tree of nested topics.\",\n parameters: {\n rootId: { type: \"string\", description: \"Root topic to start from\" },\n maxDepth: {\n type: \"number\",\n description: \"Maximum depth to traverse (default: 5)\",\n },\n },\n required: [\"rootId\"],\n response: {\n description: \"Tree of topics with nesting\",\n fields: { tree: \"array — topics in BFS order with depth and path\" },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const MATERIALIZE_TOPIC_GRAPH: McpToolContract = {\n name: \"materialize_topic_graph\",\n description:\n \"Backfill the topic graph spine. \" +\n \"Like `git fsck --connectivity-only` with repair enabled — creates missing topic nodes and parent-child edges idempotently.\",\n parameters: {\n rootTopicId: {\n type: \"string\",\n description: \"Optional root topic for a bounded materialization pass\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"When true, report missing rows without writing them\",\n },\n },\n required: [],\n response: {\n description: \"Topic graph materialization counts\",\n fields: {\n topicsSeen: \"number\",\n nodesCreated: \"number\",\n nodesExisting: \"number\",\n edgesCreated: \"number\",\n edgesExisting: \"number\",\n errors: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\nexport const GET_TOPIC_GRAPH_SPINE: McpToolContract = {\n name: \"get_topic_graph_spine\",\n description:\n \"Verify the topic graph spine. \" +\n \"Like `git fsck` — reads topics, materialized topic nodes, parent-child edges, and missing spine rows.\",\n parameters: {\n rootTopicId: {\n type: \"string\",\n description: \"Optional root topic for a bounded verifier pass\",\n },\n includeTopicBeliefEdges: {\n type: \"boolean\",\n description: \"Include topic -> belief edges in the verifier payload\",\n },\n },\n required: [],\n response: {\n description: \"Topic graph spine verification payload\",\n fields: {\n ok: \"boolean\",\n counts: \"object\",\n topics: \"array\",\n topicNodes: \"array\",\n parentEdges: \"array\",\n missingTopicNodes: \"array\",\n missingParentEdges: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// CODING INTELLIGENCE TOOLS (code-grounded knowledge)\n// =============================================================================\n\nexport const GET_CODE_CONTEXT: McpToolContract = {\n name: \"get_code_context\",\n description:\n \"Returns code-grounded beliefs, contracts, migration states, and failed attempts anchored to a specific file or function path. \" +\n \"Like `git log -- <path>` — filters the knowledge graph to nodes anchored to a file path via metadata.codeAnchors. \" +\n \"Results are separated by coding belief type: decisions, contracts, migrations, patterns, deprecations, and failures.\",\n parameters: {\n filePath: {\n type: \"string\",\n description:\n \"File path to search for (partial matches supported, e.g. 'epistemicBeliefs.ts' or 'convex/epistemicBeliefs.ts')\",\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope (optional, uses default if not provided)\",\n },\n includeFailures: {\n type: \"boolean\",\n description: \"Whether to include failed attempt evidence (default: true)\",\n },\n },\n required: [\"filePath\"],\n response: {\n description: \"Code-anchored beliefs and evidence grouped by type\",\n fields: {\n filePath: \"string — queried path\",\n decisions: \"array — implementation_decision beliefs\",\n contracts: \"array — interface_contract beliefs\",\n migrations: \"array — migration_state beliefs\",\n patterns: \"array — code_pattern beliefs\",\n deprecations: \"array — deprecation_notice beliefs\",\n failures: \"array — failed attempt evidence\",\n totalMatched: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"belief\",\n tier: \"showcase\",\n};\n\nexport const GET_CHANGE_HISTORY: McpToolContract = {\n name: \"get_change_history\",\n description:\n \"Returns recent changes and decisions for a file path — the 'why' behind recent code changes. \" +\n \"Like `git log --follow <path>` — shows the evolution of understanding anchored to a specific file. \" +\n \"Searches beliefs and evidence updated recently, sorted by most recent first.\",\n parameters: {\n filePath: { type: \"string\", description: \"File path to get history for\" },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n limit: { type: \"number\", description: \"Max results (default: 10)\" },\n },\n required: [\"filePath\"],\n response: {\n description: \"Recent code-anchored changes sorted by recency\",\n fields: {\n filePath: \"string — queried path\",\n changes:\n \"array — nodes with coding view (nodeId, beliefType, canonicalText, codeAnchors, timestamps)\",\n totalFound: \"number\",\n showing: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const RECORD_ATTEMPT: McpToolContract = {\n name: \"record_attempt\",\n description:\n \"Log a failed approach as evidence linked to a belief. \" +\n \"Like `git stash` for failed experiments — preserves what was tried so the same mistake isn't repeated. \" +\n \"Creates evidence with metadata.failedApproach=true and metadata.codeAnchors. \" +\n \"The key anti-repetition mechanism: future agents check the failure log before trying new approaches.\",\n parameters: {\n description: {\n type: \"string\",\n description: \"What was attempted and why it failed\",\n },\n filePaths: {\n type: \"array\",\n description: \"File paths involved in the attempt\",\n },\n errorMessage: {\n type: \"string\",\n description: \"Error message or failure reason\",\n },\n linkedBeliefId: {\n type: \"string\",\n description:\n \"Belief this attempt was targeting (creates -0.5 weight edge)\",\n },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n },\n required: [\"description\"],\n response: {\n description: \"The recorded failed attempt evidence node\",\n fields: {\n nodeId: \"string — evidence node ID\",\n edgeId: \"string | null — edge to linked belief\",\n recorded: \"boolean — true\",\n filePaths: \"array — anchored file paths\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\nexport const GET_FAILURE_LOG: McpToolContract = {\n name: \"get_failure_log\",\n description:\n \"Search past failed attempts matching a task description. \" +\n \"Like `git log --grep='FAILED'` — finds evidence of what was tried before and didn't work. \" +\n \"Before trying a new approach, check this log to avoid repeating the same mistake. \" +\n \"Filters to evidence with metadata.failedApproach=true, sorted by recency.\",\n parameters: {\n query: {\n type: \"string\",\n description: \"Description of the task or approach to search for\",\n },\n filePath: {\n type: \"string\",\n description: \"Optional file path to narrow results\",\n },\n topicId: { type: \"string\", description: \"Topic scope (optional)\" },\n limit: { type: \"number\", description: \"Max results (default: 5)\" },\n },\n required: [\"query\"],\n response: {\n description: \"Failed attempts matching the query\",\n fields: {\n query: \"string — search query\",\n failures: \"array — failed attempt evidence with coding view\",\n totalFound: \"number\",\n showing: \"number\",\n },\n },\n ownerModule: \"coding-intelligence\",\n ontologyPrimitive: \"evidence\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// GRAPH SELF-INTELLIGENCE TOOLS\n// =============================================================================\n\nexport const GET_TOPIC_COVERAGE: McpToolContract = {\n name: \"get_topic_coverage\",\n description:\n \"Returns per-topic belief/question/evidence counts across the topic tree. \" +\n \"Like `git diff --stat` for the knowledge graph — shows coverage density \" +\n \"and empty spots across the topic hierarchy. Use to identify which topics \" +\n \"need more beliefs, which lack questions, and overall graph health.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID (optional, uses default if not provided)\",\n },\n includeDescendants: {\n type: \"boolean\",\n description:\n \"Whether to include descendant topics in the coverage report (default: true)\",\n },\n maxDepth: {\n type: \"number\",\n description:\n \"Maximum descendant topic depth for neighborhood expansion. \" +\n \"Defaults to 4 for root/theme scopes, 2 for deeper scopes.\",\n },\n },\n required: [],\n response: {\n description: \"Per-topic coverage metrics and aggregate summary\",\n fields: {\n topics:\n \"array — per-topic { topicId, name, type, depth, beliefs, questions, evidence, coverage }\",\n summary:\n \"object — { totalTopics, coveredTopics, emptyTopics, coveragePercent, totalBeliefs, totalQuestions, totalEvidence }\",\n scopeTopicId: \"string — the root topic used for scoping\",\n },\n },\n ownerModule: \"coverage-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const GET_GRAPH_GAPS: McpToolContract = {\n name: \"get_graph_gaps\",\n description:\n \"Identify structural gaps in the knowledge graph — empty topics, beliefs \" +\n \"without questions, beliefs without evidence, and orphan edges. \" +\n \"Like `git fsck` for reasoning coverage — surfaces holes that weaken \" +\n \"the epistemic foundation. Returns prioritized gap list.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID (optional, uses default if not provided)\",\n },\n maxDepth: {\n type: \"number\",\n description:\n \"Maximum descendant topic depth for neighborhood expansion (default: 4)\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Prioritized list of graph gaps by category\",\n fields: {\n emptyTopics:\n \"array — topics with zero beliefs { topicId, name, type, depth }\",\n beliefsWithoutQuestions:\n \"array — beliefs that have no testing questions { nodeId, canonicalText, topicId }\",\n beliefsWithoutEvidence:\n \"array — beliefs that have no supporting evidence { nodeId, canonicalText, topicId }\",\n summary:\n \"object — { totalGaps, emptyTopicCount, untestedBeliefCount, unsupportedBeliefCount }\",\n scopeTopicId: \"string — the root topic used for scoping\",\n },\n },\n ownerModule: \"coverage-intelligence\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\n// =============================================================================\n// SESSION INITIALIZATION\n// =============================================================================\n\n// =============================================================================\n// WRITE POLICY (S2-13K Graph Compounding)\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const MANAGE_WRITE_POLICY: McpToolContract = {\n name: \"manage_write_policy\",\n description:\n \"Manage write policies for MCP mutation tools. \" +\n \"Like `git config` for write permissions — sets per-topic or global \" +\n \"policies that control which roles can mutate the graph.\",\n parameters: {\n action: {\n type: \"string\",\n description:\n \"Action to perform: 'get' (read policies) or 'set' (upsert a policy)\",\n enum: [\"get\", \"set\"],\n },\n topicId: {\n type: \"string\",\n description: \"Topic scope for the policy. Omit for global policies.\",\n },\n role: {\n type: \"string\",\n description:\n \"Role to set policy for (required for 'set'). E.g. 'agent:internal' or a Permit role key such as 'workspace_admin'.\",\n },\n permission: {\n type: \"string\",\n description: \"Permission level (required for 'set').\",\n enum: [\"allow\", \"deny\", \"read_only\"],\n },\n maxWritesPerSession: {\n type: \"number\",\n description: \"Optional per-session write limit for this role+scope.\",\n },\n rationale: {\n type: \"string\",\n description: \"Why this policy is being set (audit trail).\",\n },\n },\n required: [\"action\"],\n response: {\n description: \"Policy operation result\",\n fields: {\n action: \"string — get | set\",\n topicId: \"string|null — topic scope or null for global\",\n policies: \"array — (for get) list of matching policies\",\n role: \"string — (for set) role that was updated\",\n permission: \"string — (for set) new permission level\",\n maxWritesPerSession: \"number|null — (for set) session write cap\",\n },\n },\n ownerModule: \"access-control\",\n ontologyPrimitive: \"policy\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// ONTOLOGY TOOLS (ontology lifecycle, version management)\n// =============================================================================\n\nexport const LIST_ONTOLOGIES: McpToolContract = {\n name: \"list_ontologies\",\n description:\n \"List ontology definitions with optional filters. \" +\n \"Like `git remote -v` for ontologies — shows all registered ontology definitions \" +\n \"with their tier, status, and tenant scope.\",\n parameters: {\n tenantId: {\n type: \"string\",\n description: \"Filter by tenant ID. Omit for platform-level ontologies.\",\n },\n tier: {\n type: \"string\",\n description: \"Filter by tier\",\n enum: [\"platform\", \"pack\", \"tenant\"],\n },\n status: {\n type: \"string\",\n description: \"Filter by status\",\n enum: [\"draft\", \"active\", \"deprecated\", \"archived\"],\n },\n },\n required: [],\n response: {\n description: \"Array of ontology definitions\",\n fields: {\n ontologies:\n \"array — ontology definitions with id, ontologyKey, name, tier, status\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const GET_ONTOLOGY: McpToolContract = {\n name: \"get_ontology\",\n description:\n \"Get a single ontology definition by ID or ontologyKey. \" +\n \"Like `git show` for an ontology — returns the definition metadata plus the latest \" +\n \"published version with entity types and edge types.\",\n parameters: {\n id: {\n type: \"string\",\n description: \"Ontology definition ID (Convex document ID)\",\n },\n ontologyKey: {\n type: \"string\",\n description:\n \"Ontology key (e.g., 'investment-ontology'). Alternative to id.\",\n },\n tenantId: {\n type: \"string\",\n description: \"Tenant scope for key lookup. Omit for platform-level.\",\n },\n },\n required: [\"id\"],\n response: {\n description: \"Ontology definition with latest published version\",\n fields: {\n id: \"string — definition ID\",\n ontologyKey: \"string — unique key\",\n name: \"string — display name\",\n publishedVersion:\n \"object|null — latest published version with entityTypes and edgeTypes\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const APPLY_ONTOLOGY: McpToolContract = {\n name: \"apply_ontology\",\n description:\n \"Bind an ontology definition directly to a topic. \" +\n \"Like `git checkout` for a domain vocabulary — applies an ontology to a topic so the topic \" +\n \"and its descendants inherit the configured entity and edge schema.\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Canonical ontology identifier to bind\",\n },\n topicId: {\n type: \"string\",\n description: \"Canonical topic identifier to receive the binding\",\n },\n },\n required: [\"ontologyId\", \"topicId\"],\n response: {\n description: \"Ontology binding summary\",\n fields: {\n applied: \"boolean — true when the binding was written\",\n source: \"string — always 'direct' for an explicit bind\",\n ontologyId: \"string — canonical ontology ID\",\n ontologyKey: \"string — ontology key\",\n topicId: \"string — canonical topic ID\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const MATCH_ENTITY_TYPE: McpToolContract = {\n name: \"match_entity_type\",\n description:\n \"Classify free text against the effective ontology vocabulary. \" +\n \"Like `git grep` for ontology types — ranks the most likely entity types for the supplied text \" +\n \"using the topic-bound or explicitly selected ontology.\",\n parameters: {\n text: {\n type: \"string\",\n description: \"Free text to classify against ontology entity types\",\n },\n topicId: {\n type: \"string\",\n description:\n \"Canonical topic ID used to resolve the effective ontology when ontologyId is omitted\",\n },\n ontologyId: {\n type: \"string\",\n description:\n \"Optional ontology definition ID to match against instead of the topic-bound ontology\",\n },\n minScore: {\n type: \"number\",\n description: \"Optional lower similarity bound for returned matches\",\n },\n limit: {\n type: \"number\",\n description: \"Optional maximum number of ranked matches to return\",\n },\n },\n required: [\"text\", \"ontologyId\"],\n response: {\n description: \"Ranked ontology entity type matches\",\n fields: {\n matches:\n \"array — ranked entity type matches with score, entityType, label, and optional description\",\n ontologyId: \"string|null — ontology used for matching\",\n topicId: \"string|null — topic scope used for ontology resolution\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const CREATE_ONTOLOGY: McpToolContract = {\n name: \"create_ontology\",\n description:\n \"Create a new ontology definition. \" +\n \"Like `git init` for a domain vocabulary — creates a named, versioned container for \" +\n \"entity types and edge types. Starts in 'draft' status.\",\n parameters: {\n ontologyKey: {\n type: \"string\",\n description:\n \"Unique key (lowercase, hyphens, e.g., 'investment-ontology')\",\n },\n name: { type: \"string\", description: \"Human-readable name\" },\n description: { type: \"string\", description: \"What this ontology covers\" },\n tenantId: {\n type: \"string\",\n description: \"Tenant scope. Omit for platform-level.\",\n },\n tier: {\n type: \"string\",\n description: \"Ontology tier\",\n enum: [\"platform\", \"pack\", \"tenant\"],\n },\n parentOntologyId: {\n type: \"string\",\n description: \"Parent ontology ID for layered composition\",\n },\n },\n required: [\"ontologyKey\", \"name\", \"tier\"],\n response: {\n description: \"Created ontology definition\",\n fields: {\n id: \"string — new definition ID\",\n ontologyKey: \"string — normalized key\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const UPDATE_ONTOLOGY: McpToolContract = {\n name: \"update_ontology\",\n description:\n \"Update an ontology definition's metadata (name, description, status). \" +\n \"Like `git config` for an ontology — updates mutable fields on the definition. \" +\n \"Only allowed while the ontology is in draft or active status.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology definition ID\" },\n name: { type: \"string\", description: \"New display name\" },\n description: { type: \"string\", description: \"New description\" },\n status: {\n type: \"string\",\n description: \"New status\",\n enum: [\"draft\", \"active\", \"deprecated\"],\n },\n },\n required: [\"id\"],\n response: {\n description: \"Update confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const ARCHIVE_ONTOLOGY: McpToolContract = {\n name: \"archive_ontology\",\n description:\n \"Archive an ontology definition. \" +\n \"Like `git rm` for an ontology — soft-deletes the definition. \" +\n \"Archived ontologies are preserved in history but no longer active.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology definition ID to archive\" },\n },\n required: [\"id\"],\n response: {\n description: \"Archive confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const CREATE_ONTOLOGY_VERSION: McpToolContract = {\n name: \"create_ontology_version\",\n description:\n \"Create a new version snapshot for an ontology definition. \" +\n \"Like `git commit` for ontology content — captures entity types and edge types \" +\n \"in a versioned snapshot. Starts in 'draft' status. Publish to freeze.\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Parent ontology definition ID\",\n },\n version: {\n type: \"string\",\n description: \"Semantic version string (X.Y.Z format)\",\n },\n entityTypes: {\n type: \"array\",\n description:\n \"Array of entity type definitions: [{ value, label, description?, schema?, subtypes? }]\",\n },\n edgeTypes: {\n type: \"array\",\n description:\n \"Array of edge type definitions: [{ value, label, description?, sourceTypes?, targetTypes?, constraintSeverity? }]\",\n },\n releaseNotes: {\n type: \"string\",\n description: \"Optional release notes for this version\",\n },\n },\n required: [\"ontologyId\", \"version\", \"entityTypes\", \"edgeTypes\"],\n response: {\n description: \"Created version\",\n fields: {\n id: \"string — new version ID\",\n version: \"string — version string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const PUBLISH_ONTOLOGY_VERSION: McpToolContract = {\n name: \"publish_ontology_version\",\n description:\n \"Publish a draft ontology version — freezes it permanently. \" +\n \"Like `git tag` for an ontology release — the version becomes immutable after publish. \" +\n \"If the parent definition is still in 'draft', promotes it to 'active'.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology version ID to publish\" },\n },\n required: [\"id\"],\n response: {\n description: \"Publish confirmation\",\n fields: {\n success: \"boolean\",\n publishedAt: \"number — timestamp\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"showcase\",\n};\n\nexport const DEPRECATE_ONTOLOGY_VERSION: McpToolContract = {\n name: \"deprecate_ontology_version\",\n description:\n \"Deprecate a published ontology version. \" +\n \"Like `git tag -d` for an ontology release — marks the version as deprecated. \" +\n \"Only published versions can be deprecated.\",\n parameters: {\n id: { type: \"string\", description: \"Ontology version ID to deprecate\" },\n },\n required: [\"id\"],\n response: {\n description: \"Deprecation confirmation\",\n fields: { success: \"boolean\" },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const RESOLVE_EFFECTIVE_ONTOLOGY: McpToolContract = {\n name: \"resolve_effective_ontology\",\n description:\n \"Resolve the effective ontology by composing the parent chain. \" +\n \"Like `git merge --squash` for ontology layers — walks parentOntologyId chain \" +\n \"(max depth 3) and merges entity/edge types additively from root (platform) to leaf (tenant).\",\n parameters: {\n ontologyId: {\n type: \"string\",\n description: \"Ontology definition ID to resolve from\",\n },\n },\n required: [\"ontologyId\"],\n response: {\n description: \"Merged ontology with composed entity and edge types\",\n fields: {\n entityTypes: \"array — merged entity types from all layers\",\n edgeTypes: \"array — merged edge types from all layers\",\n layers: \"array — ontology keys in composition order\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\n// =============================================================================\n// FUNCTION SURFACE WORKFLOW TOOLS\n// =============================================================================\n","import type { McpToolContract } from \"./tool-contracts.types\";\n\nexport const RECORD_SCOPE_LEARNING: McpToolContract = {\n name: \"record_scope_learning\",\n description:\n \"Write a structured learning entry into the epistemic spine. \" +\n \"Like `git commit` for scope learnings — records evidence, can attach to a belief, and can open a follow-up belief/question in one atomic workflow.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope ID\" },\n summary: { type: \"string\", description: \"Atomic learning statement\" },\n title: {\n type: \"string\",\n description: \"Optional evidence title, such as a commit, doc, or issue.\",\n },\n body: {\n type: \"string\",\n description:\n \"Optional rich evidence body. If omitted, body is synthesized from summary and touched paths.\",\n },\n contentType: {\n type: \"string\",\n description: \"Optional evidence body format, such as markdown or text.\",\n },\n sourceKind: {\n type: \"string\",\n description: \"Source type for the learning event\",\n enum: [\"commit\", \"merge\", \"doc\", \"issue\", \"manual\"],\n },\n sourceRef: {\n type: \"string\",\n description: \"Optional source reference, such as SHA, PR number, or URL slug.\",\n },\n sourceUrl: { type: \"string\", description: \"Optional canonical source URL\" },\n touchedPaths: {\n type: \"array\",\n description: \"Optional touched file paths for retrieval hints\",\n },\n tags: { type: \"array\", description: \"Optional tags\" },\n linkedBeliefNodeId: {\n type: \"string\",\n description: \"Optional belief to attach evidence to\",\n },\n evidenceRelation: {\n type: \"string\",\n description: \"Relation to linked belief\",\n enum: [\"supports\", \"contradicts\"],\n },\n confidence: { type: \"number\", description: \"Optional confidence in [0,1]\" },\n createQuestionText: {\n type: \"string\",\n description: \"Optional follow-up question text\",\n },\n createBeliefText: {\n type: \"string\",\n description: \"Optional new belief text\",\n },\n beliefType: {\n type: \"string\",\n description: \"Optional belief type for createBeliefText\",\n },\n },\n required: [\"summary\"],\n response: {\n description: \"Created learning artifacts\",\n fields: {\n topicId: \"string — resolved topic ID\",\n evidenceNodeId: \"string\",\n linkedBeliefNodeId: \"string | null\",\n createdQuestionId: \"string | null\",\n createdBeliefId: \"string | null\",\n sourceUrl: \"string\",\n createdAt: \"number\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"evidence\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const PIPELINE_SNAPSHOT: McpToolContract = {\n name: \"pipeline_snapshot\",\n description:\n \"Summarize a topic's worktree pipeline in campaign-and-lane form. \" +\n \"Like `git status --short` for Lucern execution — returns the hinge worktree, next planned wave, blockers, critical path, superseded work, and graph hygiene debt.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic scope ID\" },\n },\n required: [\"topicId\"],\n response: {\n description: \"Human-oriented pipeline summary for a single topic scope\",\n fields: {\n topicId: \"string\",\n topicName: \"string\",\n currentCampaign: \"number | null\",\n nextCampaign: \"number | null\",\n activeWorktrees: \"array — current hinge worktree(s)\",\n nextWave: \"array — worktrees in the next planned campaign\",\n readyNow: \"array — planning worktrees with dependencies completed\",\n blockedBy: \"array — grouped blockers\",\n criticalPath: \"array — ordered incomplete worktree chain\",\n campaigns: \"array — incomplete worktrees grouped by campaign\",\n superseded: \"array — worktrees marked superseded or not for activation\",\n graphHygiene: \"object — untargeted and taskless worktree debt\",\n riskQuestions: \"array — critical/high open questions\",\n narrative: \"array — concise natural-language summary lines\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const DISCOVER: McpToolContract = {\n name: \"discover\",\n description:\n \"Navigate the topic tree to find where knowledge lives. \" +\n \"Like `git log --all --grep` — searches across the graph using bottom-up content matching plus top-down structural scoring.\",\n parameters: {\n query: {\n type: \"string\",\n description: \"What to look for across the topic tree\",\n },\n topK: {\n type: \"number\",\n description: \"How many matching topics to return (default: 3, max: 10)\",\n },\n includeNeighborhood: {\n type: \"boolean\",\n description:\n \"Whether to include beliefs/questions/evidence for matched topics\",\n },\n },\n required: [\"query\"],\n response: {\n description: \"Ranked topic matches with optional neighborhood content\",\n fields: {\n query: \"string — original query\",\n matchedTopics: \"array — ranked topics with scores and paths\",\n neighborhoods: \"array — beliefs, questions, evidence for each match\",\n totalTopicsScored: \"number\",\n topicTreeSize: \"number\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n deprecated: \"Deprecated: use lucern.context.compile() with topicId\",\n};\n\nexport const ANALYZE_TOPIC_DENSITY: McpToolContract = {\n name: \"analyze_topic_density\",\n description:\n \"Analyze topic belief density and identify natural conceptual clusters. \" +\n \"Like `git diff --stat` for topic organization — detects when a topic has accumulated too many beliefs and suggests subtopic decomposition.\",\n parameters: {\n topicId: { type: \"string\", description: \"Topic ID to analyze\" },\n threshold: {\n type: \"number\",\n description: \"Belief count threshold for density warning\",\n },\n minModularity: {\n type: \"number\",\n description: \"Minimum modularity score for suggesting decomposition\",\n },\n },\n required: [\"topicId\"],\n response: {\n description: \"Density analysis with cluster suggestions\",\n fields: {\n topicId: \"string\",\n topicName: \"string\",\n beliefCount: \"number\",\n edgeCount: \"number\",\n threshold: \"number\",\n isDense: \"boolean\",\n modularity: \"number\",\n clusterCount: \"number\",\n clusters: \"array — suggested belief clusters\",\n recommendation: \"string\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const APPLY_AUTO_BRANCHING: McpToolContract = {\n name: \"apply_auto_branching\",\n description:\n \"Execute topic decomposition by creating subtopics and reassigning beliefs. \" +\n \"Like `git subtree split` — splits a dense topic into focused subtopics while preserving belief identity and edges.\",\n parameters: {\n topicId: { type: \"string\", description: \"Parent topic ID to decompose\" },\n clusters: {\n type: \"array\",\n description:\n \"Cluster definitions from analyze_topic_density, each with name and beliefIds\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"Preview changes without applying them\",\n },\n },\n required: [\"topicId\", \"clusters\"],\n response: {\n description: \"Results of the auto-branching operation\",\n fields: {\n success: \"boolean\",\n parentTopicId: \"string\",\n createdSubtopics: \"array\",\n totalReassigned: \"number\",\n totalSkipped: \"number\",\n dryRun: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"graph\",\n tier: \"showcase\",\n};\n\nexport const SEED_BELIEF_LATTICE: McpToolContract = {\n name: \"seed_belief_lattice\",\n description:\n \"Seed belief lattice coverage for a topic based on its resolved ontology. \" +\n \"Like `git init` for ontology coverage — creates or previews seed beliefs for entity types that need a baseline anchor.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID. Lattice seeding must target a child topic.\",\n },\n dryRun: {\n type: \"boolean\",\n description: \"Preview seeds without creating them\",\n },\n },\n required: [],\n response: {\n description: \"Lattice seed results with per-entity-type status\",\n fields: {\n topicId: \"string\",\n ontologyResolved: \"boolean\",\n ontologyKey: \"string | null\",\n ontologyVersion: \"string | null\",\n entityTypeCount: \"number\",\n seeds: \"array — per-entity-type seed status\",\n summary: \"object — created/existing/scored/total counts\",\n dryRun: \"boolean\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GET_LATTICE_COVERAGE: McpToolContract = {\n name: \"get_lattice_coverage\",\n description:\n \"Report belief lattice coverage for a topic. \" +\n \"Like `git fsck` for ontology coverage — identifies anchored, hollow, and missing entity-type belief coverage.\",\n parameters: {\n topicId: {\n type: \"string\",\n description: \"Topic scope ID to check lattice coverage for\",\n },\n },\n required: [],\n response: {\n description: \"Per-entity-type coverage with overall score\",\n fields: {\n topicId: \"string\",\n ontologyKey: \"string | null\",\n ontologyVersion: \"string | null\",\n entityTypes: \"array — per-entity-type coverage rows\",\n summary: \"object — total/anchored/hollow/missing/coverageScore\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const DISCOVER_ENTITY_CONNECTIONS: McpToolContract = {\n name: \"discover_entity_connections\",\n description:\n \"Find existing entities that should be connected to a belief/question/evidence node. \" +\n \"Like `git log --diff-filter=M` for missing entity connections — scans entities in scope and suggests bridge edge types.\",\n parameters: {\n nodeId: {\n type: \"string\",\n description: \"Epistemic node ID to find entity connections for\",\n },\n topicId: {\n type: \"string\",\n description: \"Optional topic scope override\",\n },\n minScore: {\n type: \"number\",\n description: \"Minimum match score threshold\",\n },\n limit: {\n type: \"number\",\n description: \"Maximum candidates to return\",\n },\n },\n required: [\"nodeId\"],\n response: {\n description: \"Ranked entity connection candidates\",\n fields: {\n nodeId: \"string\",\n candidateCount: \"number\",\n candidates: \"array — suggested entity bridge candidates\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const TRIGGER_BELIEF_REVIEW: McpToolContract = {\n name: \"trigger_belief_review\",\n description:\n \"Flag beliefs for review after an entity changes. \" +\n \"Like `git bisect` for stale beliefs — traverses bridge edges from the changed entity and creates review questions for stale connected beliefs.\",\n parameters: {\n entityNodeId: {\n type: \"string\",\n description: \"The entity node that changed\",\n },\n changeDescription: {\n type: \"string\",\n description: \"What changed about the entity\",\n },\n maxQuestions: {\n type: \"number\",\n description: \"Maximum review questions to create\",\n },\n },\n required: [\"entityNodeId\"],\n response: {\n description: \"Affected beliefs and created review questions\",\n fields: {\n entityNodeId: \"string\",\n entityTitle: \"string\",\n entityType: \"string\",\n changeDescription: \"string\",\n affectedBeliefCount: \"number\",\n questionsCreated: \"number\",\n reviewedBeliefs: \"array\",\n questions: \"array\",\n },\n },\n ownerModule: \"reasoning-kernel\",\n ontologyPrimitive: \"ontology\",\n tier: \"workhorse\",\n};\n\nexport const EVALUATE_CONTRACT: McpToolContract = {\n name: \"evaluate_contract\",\n description:\n \"Run a contract evaluation and record the append-only result. \" +\n \"Like `git test` for a belief binding — executes the evaluator, logs the result, and applies any allowed SL scoring action.\",\n parameters: {\n contractId: { type: \"string\", description: \"Which contract to evaluate\" },\n trigger: {\n type: \"string\",\n description: \"What caused this evaluation\",\n },\n },\n required: [\"contractId\"],\n response: {\n description: \"The most recent contract evaluation result\",\n fields: {\n evaluationId: \"string\",\n result: \"string\",\n status: \"string\",\n confidenceBefore: \"number\",\n confidenceAfter: \"number\",\n rationale: \"string\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const GET_CONTRACT_STATUS: McpToolContract = {\n name: \"get_contract_status\",\n description:\n \"Inspect epistemic contracts and their latest evaluations. \" +\n \"Like `git status` for verification bindings — returns the contract rows plus the freshest recorded evaluation for each one.\",\n parameters: {\n beliefNodeId: {\n type: \"string\",\n description: \"Return all contracts attached to a specific belief\",\n },\n contractId: {\n type: \"string\",\n description: \"Return one specific contract by contractId\",\n },\n status: {\n type: \"string\",\n description: \"Optional status filter applied after lookup\",\n enum: [\"active\", \"satisfied\", \"violated\", \"expired\", \"suspended\", \"archived\"],\n },\n },\n required: [],\n response: {\n description: \"Matching contract rows with latest evaluation context\",\n fields: {\n contracts: \"array — matching contracts with latestEvaluation attached\",\n count: \"number\",\n },\n },\n ownerModule: \"graph-primitives\",\n ontologyPrimitive: \"belief\",\n tier: \"workhorse\",\n};\n\nexport const REGISTER_SESSION: McpToolContract = {\n name: \"register_session\",\n description:\n \"Announce this agent session's presence to other parallel sessions. \" +\n \"Like `git init` for coordination — creates a session record so other agents can discover you.\",\n parameters: {\n sessionName: { type: \"string\", description: \"Human-readable session label\" },\n agentType: { type: \"string\", description: \"Agent type\" },\n topicId: { type: \"string\", description: \"Current Lucern topic scope ID\" },\n worktreeId: { type: \"string\", description: \"Active Lucern worktree ID\" },\n gitBranch: { type: \"string\", description: \"Current git branch name\" },\n },\n required: [],\n response: {\n description: \"Session registration result\",\n fields: {\n sessionId: \"string\",\n status: \"string — active\",\n isNew: \"boolean\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const HEARTBEAT_SESSION: McpToolContract = {\n name: \"heartbeat_session\",\n description:\n \"Update this session's heartbeat and optional status fields. \" +\n \"Like `git status` — signals liveness and updates what you are working on.\",\n parameters: {\n topicId: { type: \"string\", description: \"Updated topic scope\" },\n worktreeId: { type: \"string\", description: \"Updated worktree ID\" },\n gitBranch: { type: \"string\", description: \"Updated git branch\" },\n status: {\n type: \"string\",\n description: \"Session status update\",\n enum: [\"active\", \"idle\"],\n },\n },\n required: [],\n response: {\n description: \"Heartbeat result\",\n fields: {\n success: \"boolean\",\n message: \"string\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const END_SESSION: McpToolContract = {\n name: \"end_session\",\n description:\n \"Gracefully end this agent session. \" +\n \"Like `git stash` — marks the session as ended so other agents know you are gone.\",\n parameters: {},\n required: [],\n response: {\n description: \"Session end result\",\n fields: {\n success: \"boolean\",\n message: \"string\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const LIST_ACTIVE_SESSIONS: McpToolContract = {\n name: \"list_active_sessions\",\n description:\n \"See who else is online with active agent sessions, scope, branch, and file claims. \" +\n \"Like `git branch --list` for live agents — shows active and idle sessions before editing.\",\n parameters: {\n includeIdle: {\n type: \"boolean\",\n description: \"Include idle sessions\",\n },\n },\n required: [],\n response: {\n description: \"List of active/idle agent sessions\",\n fields: {\n sessions: \"array — active session records\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const SEND_AGENT_MESSAGE: McpToolContract = {\n name: \"send_agent_message\",\n description:\n \"Send a directed message to a specific agent session. \" +\n \"Like `git notes` — leaves a coordination note for a specific peer.\",\n parameters: {\n toSessionId: { type: \"string\", description: \"Target session ID\" },\n content: { type: \"string\", description: \"Message text\" },\n messageType: {\n type: \"string\",\n description: \"Message intent\",\n enum: [\"note\", \"question\", \"answer\", \"alert\", \"handoff\"],\n },\n relatedBeliefId: {\n type: \"string\",\n description: \"Optional related belief node ID\",\n },\n relatedWorktreeId: {\n type: \"string\",\n description: \"Optional related worktree ID\",\n },\n },\n required: [\"toSessionId\", \"content\"],\n response: {\n description: \"Message delivery result\",\n fields: { messageId: \"string\" },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const BROADCAST_MESSAGE: McpToolContract = {\n name: \"broadcast_message\",\n description:\n \"Send a message to all active agent sessions. \" +\n \"Like `git tag` — marks an important event visible to everyone.\",\n parameters: {\n content: { type: \"string\", description: \"Broadcast message text\" },\n messageType: {\n type: \"string\",\n description: \"Message intent\",\n enum: [\"note\", \"alert\", \"handoff\"],\n },\n relatedBeliefId: {\n type: \"string\",\n description: \"Optional related belief node ID\",\n },\n relatedWorktreeId: {\n type: \"string\",\n description: \"Optional related worktree ID\",\n },\n },\n required: [\"content\"],\n response: {\n description: \"Broadcast result\",\n fields: { messageId: \"string\" },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GET_AGENT_INBOX: McpToolContract = {\n name: \"get_agent_inbox\",\n description:\n \"Check unread messages addressed to this session. \" +\n \"Like `git log --incoming` — shows direct and broadcast messages from other agents.\",\n parameters: {\n limit: { type: \"number\", description: \"Max messages to return\" },\n markAsRead: {\n type: \"boolean\",\n description: \"Mark returned messages as read\",\n },\n },\n required: [],\n response: {\n description: \"Inbox messages\",\n fields: {\n messages: \"array — unread direct and broadcast messages\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const CLAIM_FILES: McpToolContract = {\n name: \"claim_files\",\n description:\n \"Declare which files this session is actively editing. \" +\n \"Like `git add` for coordination — tells other sessions what you are touching and returns advisory conflicts.\",\n parameters: {\n files: {\n type: \"array\",\n description: \"File paths this session is actively editing\",\n },\n },\n required: [\"files\"],\n response: {\n description: \"File claim result with conflict detection\",\n fields: {\n success: \"boolean\",\n conflicts: \"array — conflicting file claims\",\n },\n },\n ownerModule: \"coordination\",\n ontologyPrimitive: \"graph\",\n tier: \"workhorse\",\n internal: true,\n};\n\nexport const GENERATE_SESSION_HANDOFF: McpToolContract = {\n name: \"generate_session_handoff\",\n description:\n \"Generate a complete, zero-context handoff message for a new coding session. \" +\n \"Like `git format-patch` — produces a self-contained instruction set that bootstraps a fresh Lucern worktree session.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The Lucern worktree ID to generate handoff instructions for\",\n },\n gitWorktreePath: {\n type: \"string\",\n description: \"Optional existing git worktree path\",\n },\n gitBranchName: {\n type: \"string\",\n description: \"Optional branch name for the session\",\n },\n additionalContext: {\n type: \"string\",\n description: \"Optional extra context to include in the handoff\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description: \"A complete handoff message ready for a new coding session\",\n fields: {\n handoffMessage: \"string\",\n worktreeId: \"string\",\n worktreeName: \"string\",\n trackBoundary: \"object\",\n needsActivation: \"boolean\",\n needsGitSetup: \"string — create | fast-forward | ready\",\n },\n },\n ownerModule: \"bootstrap\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n internal: true,\n};\n\nexport const BEGIN_BUILD_SESSION: McpToolContract = {\n name: \"begin_build_session\",\n description:\n \"Bootstrap a coding build session for a Lucern worktree. \" +\n \"Like `git worktree add` plus `git status` — returns the compact context packet an agent needs before editing.\",\n parameters: {\n worktreeId: {\n type: \"string\",\n description: \"The Lucern worktree ID to bootstrap.\",\n },\n branch: {\n type: \"string\",\n description:\n \"Optional git branch name. Auto-generated from the worktree name when omitted.\",\n },\n branchBase: {\n type: \"string\",\n description: 'Base branch for the feature branch. Default: \"staging\".',\n },\n prBase: {\n type: \"string\",\n description: 'Target branch for the PR. Default: \"staging\".',\n },\n sessionMode: {\n type: \"string\",\n description:\n 'Session mode: \"async\" for Codex/headless or \"interactive\" for live sessions.',\n enum: [\"async\", \"interactive\"],\n },\n activateIfPlanning: {\n type: \"boolean\",\n description:\n \"When true, automatically activate a planning worktree during bootstrap.\",\n },\n },\n required: [\"worktreeId\"],\n response: {\n description:\n \"A compact build-session packet with worktree metadata, graph anchors, questions, dependencies, and git defaults.\",\n fields: {\n topicId: \"string — canonical topic scope\",\n topicName: \"string — human-readable topic name\",\n worktreeId: \"string — worktree ID\",\n worktreeName: \"string — human-readable worktree name\",\n branch: \"string — git branch name\",\n branchBase: \"string — base branch\",\n prBase: \"string — PR target branch\",\n campaign: \"number | null — top-level pipeline campaign\",\n lane: \"string — campaign lane\",\n gate: \"string — exit gate\",\n hypothesis: \"string — worktree hypothesis\",\n focus: \"string — session focus\",\n status: \"string — worktree status after optional activation\",\n sessionMode: \"string — async | interactive\",\n targetBeliefIds: \"array — scoped belief IDs\",\n targetQuestionIds: \"array — scoped question IDs\",\n taskIds: \"array — assigned task IDs for this worktree\",\n incompleteTaskIds:\n \"array — assigned task IDs that still require done/deferred/blocked proof\",\n tasks:\n \"array — assigned task packet with id, title, status, priority, links, and summaries\",\n topBeliefs: \"array — highest-confidence scoped beliefs\",\n openQuestions: \"array — open scoped questions\",\n resolvedDecisions: \"array — answered questions summarized for the session\",\n dependencies: \"array — upstream worktrees\",\n unblocks: \"array — downstream worktrees\",\n mergeOrderNotes: \"string — merge ordering advisory\",\n },\n },\n ownerModule: \"bootstrap\",\n ontologyPrimitive: \"worktree\",\n tier: \"showcase\",\n internal: true,\n};\n","/**\n * MCP Tool Contract Definitions\n *\n * Stable facade for the split MCP contract catalog. Contract literals live in\n * focused tool-contracts.* modules; this file preserves the public import path\n * and owns the registry plus validation helpers.\n */\n\nimport type { McpToolContract } from \"./tool-contracts.types\";\n\nimport {\n CREATE_BELIEF,\n GET_BELIEF,\n REFINE_BELIEF,\n APPEND_SL_SCORING,\n FORK_BELIEF,\n ARCHIVE_BELIEF,\n CREATE_EPISTEMIC_CONTRACT,\n ADD_EVIDENCE,\n FLAG_CONTRADICTION,\n} from \"./tool-contracts.lifecycle\";\n\nimport {\n ADD_WORKTREE,\n LIST_WORKTREES_BY_BELIEF,\n MERGE,\n PUSH,\n OPEN_PULL_REQUEST,\n} from \"./tool-contracts.worktrees\";\n\nimport {\n QUERY_LINEAGE,\n QUERY_ANCHOR_HISTORY,\n GET_CONFIDENCE_HISTORY,\n GET_AUDIT_TRAIL,\n TRAVERSE_GRAPH,\n GET_GRAPH_NEIGHBORHOOD,\n TRACE_ENTITY_IMPACT,\n SEARCH_BELIEFS,\n FIND_CONTRADICTIONS,\n BISECT_CONFIDENCE,\n CREATE_EDGE,\n UPDATE_EDGE,\n REMOVE_EDGE,\n REMOVE_EDGES_BETWEEN,\n BATCH_CREATE_EDGES,\n} from \"./tool-contracts.graph\";\n\nimport {\n GET_EMBEDDINGS_BY_NODE_IDS,\n LIST_MISSING_EMBEDDINGS,\n QUEUE_EMBEDDING_BACKFILL,\n SEARCH_EMBEDDINGS,\n} from \"./tool-contracts.embeddings\";\n\nimport {\n ANALYZE_GRAPH_IMPACT,\n DETECT_GRAPH_DRIFT,\n EXPAND_GRAPH_NEIGHBORHOOD,\n FIND_RELATED_NODES,\n HYBRID_DISCOVER,\n RESOLVE_TOPIC_SEMANTIC,\n} from \"./tool-contracts.hybrid-discovery\";\n\nimport {\n CREATE_EPISTEMIC_NODE,\n GET_EPISTEMIC_NODE,\n LIST_EPISTEMIC_NODES,\n UPDATE_EPISTEMIC_NODE,\n ARCHIVE_EPISTEMIC_NODE,\n VERIFY_EPISTEMIC_NODE,\n SUPERSEDE_EPISTEMIC_NODE,\n BATCH_CREATE_EPISTEMIC_NODES,\n RECORD_JUDGMENT,\n CREATE_LENS,\n LIST_LENSES,\n APPLY_LENS_TO_TOPIC,\n REMOVE_LENS_FROM_TOPIC,\n} from \"./tool-contracts.nodes-lenses\";\n\nimport { LUCERN_ORIENT } from \"./tool-contracts.context-orientation\";\n\nimport {\n DETECT_CONFIRMATION_BIAS,\n GET_GRAPH_STRUCTURE_ANALYSIS,\n LIST_GRAPH_INTELLIGENCE_QUERIES,\n RUN_GRAPH_INTELLIGENCE_QUERY,\n GET_FALSIFICATION_QUESTIONS,\n SEARCH_EVIDENCE,\n CREATE_EVIDENCE,\n GET_EVIDENCE,\n LIST_EVIDENCE,\n ARCHIVE_EVIDENCE,\n LINK_EVIDENCE,\n LINK_EVIDENCE_TO_BELIEF,\n} from \"./tool-contracts.intelligence-evidence\";\n\nimport {\n CREATE_QUESTION,\n GET_QUESTION,\n REFINE_QUESTION,\n LIST_QUESTIONS,\n ANSWER_QUESTION,\n UPDATE_QUESTION_STATUS,\n ARCHIVE_QUESTION,\n LINK_EVIDENCE_TO_QUESTION,\n CREATE_ANSWER,\n GET_ANSWER,\n GET_HIGH_PRIORITY_QUESTIONS,\n FIND_MISSING_QUESTIONS,\n LIST_BELIEFS,\n GET_WORKTREE,\n LIST_WORKTREES,\n LIST_ALL_WORKTREES,\n LIST_CAMPAIGNS,\n ACTIVATE_WORKTREE,\n UPDATE_WORKTREE_TARGETS,\n UPDATE_WORKTREE_METADATA,\n IDENTITY_WHOAMI,\n RESOLVE_INTERACTIVE_PRINCIPAL,\n COMPILE_CONTEXT,\n} from \"./tool-contracts.questions-listing\";\n\nimport {\n CHECK_PERMISSION,\n COMPILE_CAPABILITY_SLICE,\n FILTER_BY_PERMISSION,\n INGEST_OBSERVATION,\n GET_OBSERVATION_CONTEXT,\n CREATE_TASK,\n COMPLETE_TASK,\n UPDATE_TASK,\n LIST_TASKS,\n CREATE_TOPIC,\n LIST_TOPICS,\n GET_TOPIC,\n UPDATE_TOPIC,\n GET_TOPIC_TREE,\n MATERIALIZE_TOPIC_GRAPH,\n GET_TOPIC_GRAPH_SPINE,\n GET_CODE_CONTEXT,\n GET_CHANGE_HISTORY,\n RECORD_ATTEMPT,\n GET_FAILURE_LOG,\n GET_TOPIC_COVERAGE,\n GET_GRAPH_GAPS,\n} from \"./tool-contracts.policy-observation-task-topic\";\n\nimport {\n MANAGE_WRITE_POLICY,\n LIST_ONTOLOGIES,\n GET_ONTOLOGY,\n APPLY_ONTOLOGY,\n MATCH_ENTITY_TYPE,\n CREATE_ONTOLOGY,\n UPDATE_ONTOLOGY,\n ARCHIVE_ONTOLOGY,\n CREATE_ONTOLOGY_VERSION,\n PUBLISH_ONTOLOGY_VERSION,\n DEPRECATE_ONTOLOGY_VERSION,\n RESOLVE_EFFECTIVE_ONTOLOGY,\n} from \"./tool-contracts.ontology\";\n\nimport {\n RECORD_SCOPE_LEARNING,\n PIPELINE_SNAPSHOT,\n DISCOVER,\n ANALYZE_TOPIC_DENSITY,\n APPLY_AUTO_BRANCHING,\n SEED_BELIEF_LATTICE,\n GET_LATTICE_COVERAGE,\n DISCOVER_ENTITY_CONNECTIONS,\n TRIGGER_BELIEF_REVIEW,\n EVALUATE_CONTRACT,\n GET_CONTRACT_STATUS,\n REGISTER_SESSION,\n HEARTBEAT_SESSION,\n END_SESSION,\n LIST_ACTIVE_SESSIONS,\n SEND_AGENT_MESSAGE,\n BROADCAST_MESSAGE,\n GET_AGENT_INBOX,\n CLAIM_FILES,\n GENERATE_SESSION_HANDOFF,\n BEGIN_BUILD_SESSION,\n} from \"./tool-contracts.pipeline-coordination\";\n\nexport type { McpParameterDef, McpResponseDef, McpToolContract } from \"./tool-contracts.types\";\nexport * from \"./tool-contracts.lifecycle\";\nexport * from \"./tool-contracts.worktrees\";\nexport * from \"./tool-contracts.graph\";\nexport * from \"./tool-contracts.embeddings\";\nexport * from \"./tool-contracts.hybrid-discovery\";\nexport * from \"./tool-contracts.nodes-lenses\";\nexport * from \"./tool-contracts.context-orientation\";\nexport * from \"./tool-contracts.intelligence-evidence\";\nexport * from \"./tool-contracts.questions-listing\";\nexport * from \"./tool-contracts.policy-observation-task-topic\";\nexport * from \"./tool-contracts.ontology\";\nexport * from \"./tool-contracts.pipeline-coordination\";\n\n// =============================================================================\n// TOOL REGISTRY\n// =============================================================================\n\n/** All MCP tool contracts, indexed by name */\nexport const MCP_TOOL_CONTRACTS: Record<string, McpToolContract> = {\n // Belief lifecycle (commit, amend, fork, archive)\n create_belief: CREATE_BELIEF,\n get_belief: GET_BELIEF,\n refine_belief: REFINE_BELIEF,\n append_sl_scoring: APPEND_SL_SCORING,\n fork_belief: FORK_BELIEF,\n archive_belief: ARCHIVE_BELIEF,\n create_epistemic_contract: CREATE_EPISTEMIC_CONTRACT,\n evaluate_contract: EVALUATE_CONTRACT,\n get_contract_status: GET_CONTRACT_STATUS,\n // Evidence (commit)\n create_evidence: CREATE_EVIDENCE,\n get_evidence: GET_EVIDENCE,\n list_evidence: LIST_EVIDENCE,\n archive_evidence: ARCHIVE_EVIDENCE,\n link_evidence: LINK_EVIDENCE,\n add_evidence: ADD_EVIDENCE,\n // Contradictions (merge conflict)\n flag_contradiction: FLAG_CONTRADICTION,\n // Lens lifecycle (workspace-scoped operational frames)\n create_lens: CREATE_LENS,\n list_lenses: LIST_LENSES,\n apply_lens_to_topic: APPLY_LENS_TO_TOPIC,\n remove_lens_from_topic: REMOVE_LENS_FROM_TOPIC,\n // Worktree lifecycle (git worktree add → merge → push → pull request)\n add_worktree: ADD_WORKTREE,\n merge: MERGE,\n push: PUSH,\n open_pull_request: OPEN_PULL_REQUEST,\n // Lineage and audit (log, blame)\n query_lineage: QUERY_LINEAGE,\n query_anchor_history: QUERY_ANCHOR_HISTORY,\n get_confidence_history: GET_CONFIDENCE_HISTORY,\n get_audit_trail: GET_AUDIT_TRAIL,\n // Graph queries (traverse, search, bisect, entity impact)\n traverse_graph: TRAVERSE_GRAPH,\n get_graph_neighborhood: GET_GRAPH_NEIGHBORHOOD,\n trace_entity_impact: TRACE_ENTITY_IMPACT,\n search_beliefs: SEARCH_BELIEFS,\n find_contradictions: FIND_CONTRADICTIONS,\n bisect_confidence: BISECT_CONFIDENCE,\n list_missing_embeddings: LIST_MISSING_EMBEDDINGS,\n search_embeddings: SEARCH_EMBEDDINGS,\n get_embeddings_by_node_ids: GET_EMBEDDINGS_BY_NODE_IDS,\n queue_embedding_backfill: QUEUE_EMBEDDING_BACKFILL,\n hybrid_discover: HYBRID_DISCOVER,\n resolve_topic_semantic: RESOLVE_TOPIC_SEMANTIC,\n expand_graph_neighborhood: EXPAND_GRAPH_NEIGHBORHOOD,\n find_related_nodes: FIND_RELATED_NODES,\n analyze_graph_impact: ANALYZE_GRAPH_IMPACT,\n detect_graph_drift: DETECT_GRAPH_DRIFT,\n // Edges (commit)\n create_edge: CREATE_EDGE,\n update_edge: UPDATE_EDGE,\n remove_edge: REMOVE_EDGE,\n remove_edges_between: REMOVE_EDGES_BETWEEN,\n batch_create_edges: BATCH_CREATE_EDGES,\n // Epistemic node spine (commit/amend/show)\n create_epistemic_node: CREATE_EPISTEMIC_NODE,\n get_epistemic_node: GET_EPISTEMIC_NODE,\n list_epistemic_nodes: LIST_EPISTEMIC_NODES,\n update_epistemic_node: UPDATE_EPISTEMIC_NODE,\n archive_epistemic_node: ARCHIVE_EPISTEMIC_NODE,\n verify_epistemic_node: VERIFY_EPISTEMIC_NODE,\n supersede_epistemic_node: SUPERSEDE_EPISTEMIC_NODE,\n batch_create_epistemic_nodes: BATCH_CREATE_EPISTEMIC_NODES,\n // Judgments (tag)\n record_judgment: RECORD_JUDGMENT,\n // Graph intelligence (showcase)\n detect_confirmation_bias: DETECT_CONFIRMATION_BIAS,\n get_graph_structure_analysis: GET_GRAPH_STRUCTURE_ANALYSIS,\n list_graph_intelligence_queries: LIST_GRAPH_INTELLIGENCE_QUERIES,\n run_graph_intelligence_query: RUN_GRAPH_INTELLIGENCE_QUERY,\n get_falsification_questions: GET_FALSIFICATION_QUESTIONS,\n // Evidence operations (workhorse)\n search_evidence: SEARCH_EVIDENCE,\n link_evidence_to_belief: LINK_EVIDENCE_TO_BELIEF,\n // Answer lifecycle (L2 question responses)\n create_answer: CREATE_ANSWER,\n get_answer: GET_ANSWER,\n // Question operations (workhorse)\n create_question: CREATE_QUESTION,\n get_question: GET_QUESTION,\n refine_question: REFINE_QUESTION,\n list_questions: LIST_QUESTIONS,\n answer_question: ANSWER_QUESTION,\n update_question_status: UPDATE_QUESTION_STATUS,\n archive_question: ARCHIVE_QUESTION,\n link_evidence_to_question: LINK_EVIDENCE_TO_QUESTION,\n get_high_priority_questions: GET_HIGH_PRIORITY_QUESTIONS,\n find_missing_questions: FIND_MISSING_QUESTIONS,\n // Listing & query (workhorse)\n list_beliefs: LIST_BELIEFS,\n get_worktree: GET_WORKTREE,\n list_worktrees: LIST_WORKTREES,\n list_all_worktrees: LIST_ALL_WORKTREES,\n list_worktrees_by_belief: LIST_WORKTREES_BY_BELIEF,\n list_campaigns: LIST_CAMPAIGNS,\n activate_worktree: ACTIVATE_WORKTREE,\n update_worktree_targets: UPDATE_WORKTREE_TARGETS,\n update_worktree_metadata: UPDATE_WORKTREE_METADATA,\n identity_whoami: IDENTITY_WHOAMI,\n resolve_interactive_principal: RESOLVE_INTERACTIVE_PRINCIPAL,\n lucern_orient: LUCERN_ORIENT,\n compile_context: COMPILE_CONTEXT,\n record_scope_learning: RECORD_SCOPE_LEARNING,\n pipeline_snapshot: PIPELINE_SNAPSHOT,\n discover: DISCOVER,\n analyze_topic_density: ANALYZE_TOPIC_DENSITY,\n apply_auto_branching: APPLY_AUTO_BRANCHING,\n seed_belief_lattice: SEED_BELIEF_LATTICE,\n get_lattice_coverage: GET_LATTICE_COVERAGE,\n discover_entity_connections: DISCOVER_ENTITY_CONNECTIONS,\n trigger_belief_review: TRIGGER_BELIEF_REVIEW,\n register_session: REGISTER_SESSION,\n heartbeat_session: HEARTBEAT_SESSION,\n end_session: END_SESSION,\n list_active_sessions: LIST_ACTIVE_SESSIONS,\n send_agent_message: SEND_AGENT_MESSAGE,\n broadcast_message: BROADCAST_MESSAGE,\n get_agent_inbox: GET_AGENT_INBOX,\n claim_files: CLAIM_FILES,\n generate_session_handoff: GENERATE_SESSION_HANDOFF,\n begin_build_session: BEGIN_BUILD_SESSION,\n // Policy / ACL (workhorse)\n check_permission: CHECK_PERMISSION,\n compile_capability_slice: COMPILE_CAPABILITY_SLICE,\n filter_by_permission: FILTER_BY_PERMISSION,\n // Write policy (S2-13K Graph Compounding)\n manage_write_policy: MANAGE_WRITE_POLICY,\n // Observation context (workhorse)\n ingest_observation: INGEST_OBSERVATION,\n get_observation_context: GET_OBSERVATION_CONTEXT,\n // Task lifecycle (workhorse)\n create_task: CREATE_TASK,\n complete_task: COMPLETE_TASK,\n update_task: UPDATE_TASK,\n list_tasks: LIST_TASKS,\n // Topic lifecycle (init, remote)\n create_topic: CREATE_TOPIC,\n list_topics: LIST_TOPICS,\n get_topic: GET_TOPIC,\n update_topic: UPDATE_TOPIC,\n get_topic_tree: GET_TOPIC_TREE,\n materialize_topic_graph: MATERIALIZE_TOPIC_GRAPH,\n get_topic_graph_spine: GET_TOPIC_GRAPH_SPINE,\n // Coding intelligence (code-grounded knowledge)\n get_code_context: GET_CODE_CONTEXT,\n get_change_history: GET_CHANGE_HISTORY,\n record_attempt: RECORD_ATTEMPT,\n get_failure_log: GET_FAILURE_LOG,\n // Graph self-intelligence (coverage, gaps)\n get_topic_coverage: GET_TOPIC_COVERAGE,\n get_graph_gaps: GET_GRAPH_GAPS,\n // Ontology lifecycle (definition CRUD, version management)\n list_ontologies: LIST_ONTOLOGIES,\n get_ontology: GET_ONTOLOGY,\n apply_ontology: APPLY_ONTOLOGY,\n match_entity_type: MATCH_ENTITY_TYPE,\n create_ontology: CREATE_ONTOLOGY,\n update_ontology: UPDATE_ONTOLOGY,\n archive_ontology: ARCHIVE_ONTOLOGY,\n create_ontology_version: CREATE_ONTOLOGY_VERSION,\n publish_ontology_version: PUBLISH_ONTOLOGY_VERSION,\n deprecate_ontology_version: DEPRECATE_ONTOLOGY_VERSION,\n resolve_effective_ontology: RESOLVE_EFFECTIVE_ONTOLOGY,\n};\n\n/** Tool names that MUST include git-semantic language in descriptions */\nexport const GIT_SEMANTIC_REQUIRED_TOOLS = Object.keys(MCP_TOOL_CONTRACTS);\n\n/**\n * Lint validation: every tool description must contain \"Like `git\" or \"Like a `git\"\n * or reference a git operation in the first sentence.\n */\nexport function validateGitSemantics(tool: McpToolContract): {\n valid: boolean;\n reason?: string;\n} {\n const desc = tool.description;\n const hasGitReference =\n /Like (`git |a `git |a merge conflict|opening a `git)/.test(desc);\n if (!hasGitReference) {\n return {\n valid: false,\n reason: `Tool \"${tool.name}\" description missing git-semantic reference`,\n };\n }\n return { valid: true };\n}\n","import type {\n FunctionSurfaceIntent,\n SurfaceClass,\n SurfaceExposure,\n FunctionSurfaceMap,\n} from \"./types.js\";\n\nexport type LucernOperationManifestEntry = {\n name: string;\n surfaceClass: SurfaceClass;\n surfaceIntent: FunctionSurfaceIntent;\n surfaces: FunctionSurfaceMap;\n rationale: string;\n};\n\nconst publicEverywhere: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"public\",\n cli: \"public\",\n};\n\nconst internalSystem: FunctionSurfaceMap = {\n sdk: \"internal\",\n rest: \"internal\",\n mcp: \"internal\",\n cli: \"internal\",\n};\n\nconst internalSdkRestOnly: FunctionSurfaceMap = {\n sdk: \"internal\",\n rest: \"internal\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst publicWithInternalMcp: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"internal\",\n cli: \"public\",\n};\n\nconst publicWithoutMcp: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"public\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst sdkOnlyPublic: FunctionSurfaceMap = {\n sdk: \"public\",\n rest: \"none\",\n mcp: \"none\",\n cli: \"none\",\n};\n\nconst mcpOnlyInternal: FunctionSurfaceMap = {\n sdk: \"none\",\n rest: \"none\",\n mcp: \"internal\",\n cli: \"none\",\n};\n\nfunction entries(\n names: readonly string[],\n surfaceClass: SurfaceClass,\n surfaceIntent: FunctionSurfaceIntent,\n surfaces: FunctionSurfaceMap,\n rationale: string\n): Record<string, LucernOperationManifestEntry> {\n return Object.fromEntries(\n names.map((name) => [\n name,\n {\n name,\n surfaceClass,\n surfaceIntent,\n surfaces,\n rationale,\n },\n ])\n );\n}\n\nexport const MCP_CORE_OPERATION_NAMES = [\n \"lucern_orient\",\n \"compile_context\",\n \"identity_whoami\",\n \"resolve_interactive_principal\",\n \"check_permission\",\n \"compile_capability_slice\",\n \"filter_by_permission\",\n \"create_belief\",\n \"get_belief\",\n \"list_beliefs\",\n \"refine_belief\",\n \"fork_belief\",\n \"archive_belief\",\n \"search_beliefs\",\n \"bisect_confidence\",\n \"create_evidence\",\n \"get_evidence\",\n \"list_evidence\",\n \"archive_evidence\",\n \"search_evidence\",\n \"link_evidence_to_belief\",\n \"link_evidence_to_question\",\n \"create_question\",\n \"get_question\",\n \"list_questions\",\n \"refine_question\",\n \"update_question_status\",\n \"archive_question\",\n \"create_answer\",\n \"get_answer\",\n \"find_missing_questions\",\n \"get_high_priority_questions\",\n \"get_falsification_questions\",\n \"create_epistemic_node\",\n \"get_epistemic_node\",\n \"list_epistemic_nodes\",\n \"update_epistemic_node\",\n \"archive_epistemic_node\",\n \"verify_epistemic_node\",\n \"supersede_epistemic_node\",\n \"batch_create_epistemic_nodes\",\n \"create_topic\",\n \"get_topic\",\n \"list_topics\",\n \"update_topic\",\n \"get_topic_tree\",\n \"materialize_topic_graph\",\n \"get_topic_graph_spine\",\n] as const;\n\nexport const MCP_ANALYSIS_PLATFORM_OPERATION_NAMES = [\n \"create_edge\",\n \"update_edge\",\n \"remove_edge\",\n \"remove_edges_between\",\n \"batch_create_edges\",\n \"query_lineage\",\n \"query_anchor_history\",\n \"traverse_graph\",\n \"get_graph_neighborhood\",\n \"get_graph_structure_analysis\",\n \"list_graph_intelligence_queries\",\n \"run_graph_intelligence_query\",\n \"list_missing_embeddings\",\n \"search_embeddings\",\n \"get_embeddings_by_node_ids\",\n \"queue_embedding_backfill\",\n \"hybrid_discover\",\n \"resolve_topic_semantic\",\n \"expand_graph_neighborhood\",\n \"find_related_nodes\",\n \"analyze_graph_impact\",\n \"detect_graph_drift\",\n \"find_contradictions\",\n \"flag_contradiction\",\n \"detect_confirmation_bias\",\n \"get_topic_coverage\",\n \"get_graph_gaps\",\n] as const;\n\nexport const MCP_ANALYSIS_TENANT_OPERATION_NAMES = [\n \"analyze_topic_density\",\n \"discover_entity_connections\",\n \"trace_entity_impact\",\n] as const;\n\nexport const MCP_WORKFLOW_PLATFORM_OPERATION_NAMES = [\n \"list_lenses\",\n \"apply_lens_to_topic\",\n \"remove_lens_from_topic\",\n \"get_ontology\",\n \"list_ontologies\",\n \"apply_ontology\",\n \"match_entity_type\",\n \"resolve_effective_ontology\",\n \"add_worktree\",\n \"get_worktree\",\n \"activate_worktree\",\n \"list_worktrees\",\n \"list_all_worktrees\",\n \"list_worktrees_by_belief\",\n \"list_campaigns\",\n \"update_worktree_targets\",\n \"update_worktree_metadata\",\n \"create_task\",\n \"list_tasks\",\n \"update_task\",\n \"complete_task\",\n] as const;\n\nexport const MCP_WORKFLOW_TENANT_OPERATION_NAMES = [\n \"resolve_effective_ontology\",\n \"get_observation_context\",\n \"ingest_observation\",\n \"merge\",\n] as const;\n\nexport const MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES = [\n \"create_lens\",\n \"create_ontology\",\n \"update_ontology\",\n \"archive_ontology\",\n \"create_ontology_version\",\n] as const;\n\nexport const MCP_GOVERNANCE_TENANT_OPERATION_NAMES = [\n \"create_epistemic_contract\",\n \"evaluate_contract\",\n \"get_contract_status\",\n \"publish_ontology_version\",\n \"deprecate_ontology_version\",\n \"manage_write_policy\",\n] as const;\n\nexport const MCP_AUTOMATION_OPERATION_NAMES = [\n \"apply_auto_branching\",\n \"trigger_belief_review\",\n] as const;\n\nexport const DUPLICATE_OPERATION_NAMES = [\n \"link_evidence\",\n] as const;\n\nexport const PLATFORM_PUBLIC_OPERATION_NAMES = [\n ...MCP_CORE_OPERATION_NAMES,\n ...MCP_ANALYSIS_PLATFORM_OPERATION_NAMES,\n ...MCP_WORKFLOW_PLATFORM_OPERATION_NAMES,\n ...MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES,\n ...DUPLICATE_OPERATION_NAMES,\n] as const;\n\nexport const TENANT_PUBLIC_OPERATION_NAMES = [\n ...MCP_ANALYSIS_TENANT_OPERATION_NAMES,\n ...MCP_WORKFLOW_TENANT_OPERATION_NAMES,\n ...MCP_GOVERNANCE_TENANT_OPERATION_NAMES,\n ...MCP_AUTOMATION_OPERATION_NAMES,\n] as const;\n\nexport const PLATFORM_INTERNAL_OPERATION_NAMES = [\n \"register_session\",\n \"heartbeat_session\",\n \"end_session\",\n \"list_active_sessions\",\n \"send_agent_message\",\n \"broadcast_message\",\n \"get_agent_inbox\",\n \"claim_files\",\n \"generate_session_handoff\",\n \"record_scope_learning\",\n \"pipeline_snapshot\",\n \"seed_belief_lattice\",\n \"get_lattice_coverage\",\n \"get_code_context\",\n \"get_change_history\",\n \"get_failure_log\",\n \"record_attempt\",\n \"begin_build_session\",\n \"push\",\n \"open_pull_request\",\n \"record_judgment\",\n \"get_audit_trail\",\n] as const;\n\nexport const LEGACY_COMPAT_OPERATION_NAMES = [\n \"discover\",\n \"add_evidence\",\n \"answer_question\",\n \"get_confidence_history\",\n] as const;\n\nexport const SDK_ONLY_OPERATION_NAMES = [\n \"start_worktree\",\n \"update_worktree_phase\",\n \"advance_worktree_phase\",\n \"add_note_to_worktree\",\n \"link_document_to_worktree\",\n \"link_evidence_to_worktree\",\n \"link_question_to_worktree\",\n \"link_belief_to_worktree\",\n \"create_synthesized_belief\",\n \"complete_hypothesis_formation\",\n \"complete_evidence_review\",\n \"refine_worktree_belief\",\n \"trace_provenance\",\n \"get_belief_relationships\",\n \"get_belief_support_chain\",\n \"explore_connections\",\n \"get_deep_lineage\",\n \"graph_aware_search\",\n \"get_collection_conviction\",\n \"get_conviction_trend\",\n \"analyze_belief_criticality\",\n \"analyze_belief_cluster_candidates\",\n \"create_belief_conditional\",\n \"get_necessary_evidence\",\n \"analyze_reasoning_depth\",\n \"get_evidence_by_methodology\",\n \"create_evidence_task\",\n \"get_task_counts\",\n \"add_research_action\",\n \"get_predictions\",\n \"get_surprise_detection\",\n \"get_challenged_beliefs\",\n \"get_causal_chains\",\n \"get_non_consensus_beliefs\",\n \"get_beliefs_by_epistemic_status\",\n \"detect_anchoring_bias\",\n \"detect_source_concentration\",\n \"find_soft_contradictions\",\n \"find_semantic_bridges\",\n \"find_semantic_orphans\",\n] as const;\n\nexport const MCP_ONLY_INTERNAL_OPERATION_NAMES = [\n \"evaluate_engineering_contract\",\n \"evaluate_research_contract\",\n] as const;\n\nexport const FORBIDDEN_APPLICATION_OPERATION_NAMES = [\n \"execute_deep_research\",\n \"search_sources\",\n \"search_resources\",\n \"get_privileged_evidence\",\n \"get_privileged_signals\",\n \"get_thesis_artifacts\",\n] as const;\n\nexport const LUCERN_OPERATION_MANIFEST = {\n ...entries(\n MCP_CORE_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_core\",\n publicEverywhere,\n \"Default conversational Lucern MCP primitive for reading, writing, and shaping the reasoning graph.\"\n ),\n ...entries(\n MCP_ANALYSIS_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"High-signal graph analysis operation that belongs in chat/MCP because users naturally ask for gaps, contradictions, lineage, and coverage.\"\n ),\n ...entries(\n MCP_ANALYSIS_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"Tenant-scoped analysis operation that remains MCP-visible because agents can answer graph-quality and impact questions from chat.\"\n ),\n ...entries(\n MCP_WORKFLOW_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_workflow\",\n publicEverywhere,\n \"Workflow operation expected by coding agents and human MCP users managing Lucern worktrees, tasks, lenses, and observations.\"\n ),\n ...entries(\n MCP_WORKFLOW_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_workflow\",\n publicEverywhere,\n \"Tenant-scoped workflow operation expected by coding agents and human MCP users managing observations and worktree lifecycle.\"\n ),\n ...entries(\n MCP_AUTOMATION_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_analysis\",\n publicEverywhere,\n \"Tenant-scoped automation that remains MCP-visible because agents can explicitly request review or branching assistance.\"\n ),\n ...entries(\n MCP_GOVERNANCE_PLATFORM_OPERATION_NAMES,\n \"platform_public\",\n \"mcp_governance\",\n publicWithInternalMcp,\n \"Governance/admin operation. SDK, REST, and CLI remain public, but MCP is internal by default to keep chat surfaces focused.\"\n ),\n ...entries(\n MCP_GOVERNANCE_TENANT_OPERATION_NAMES,\n \"tenant_public\",\n \"mcp_governance\",\n publicWithInternalMcp,\n \"Governance/admin operation. SDK, REST, and CLI remain public, but MCP is internal by default to keep chat surfaces focused.\"\n ),\n ...entries(\n DUPLICATE_OPERATION_NAMES,\n \"platform_public\",\n \"compatibility\",\n publicWithoutMcp,\n \"Duplicate compatibility operation kept for SDK/REST callers, removed from MCP/CLI discovery in favor of the canonical specific tool.\"\n ),\n ...entries(\n PLATFORM_INTERNAL_OPERATION_NAMES,\n \"platform_internal\",\n \"system\",\n internalSystem,\n \"Lucern system/background operation. Available to platform code paths, hidden from public MCP discovery.\"\n ),\n append_sl_scoring: {\n name: \"append_sl_scoring\",\n surfaceClass: \"platform_internal\",\n surfaceIntent: \"system\",\n surfaces: internalSdkRestOnly,\n rationale:\n \"Internal SL scoring append primitive. Public callers attach evidence or contradiction relations; confidence is derived algorithmically.\",\n },\n ...entries(\n LEGACY_COMPAT_OPERATION_NAMES,\n \"legacy_compat\",\n \"compatibility\",\n publicWithoutMcp,\n \"Temporary compatibility operation. Must name a canonical replacement before removal.\"\n ),\n ...entries(\n SDK_ONLY_OPERATION_NAMES,\n \"tenant_public\",\n \"sdk_granular\",\n sdkOnlyPublic,\n \"Granular Lucern SDK operation. Not an MCP, REST, or CLI tool until backed by the generated function pipe.\"\n ),\n ...entries(\n MCP_ONLY_INTERNAL_OPERATION_NAMES,\n \"platform_internal\",\n \"system\",\n mcpOnlyInternal,\n \"Lucern MCP-only platform operation for local agent/bootstrap or verification workflows. Hidden from public discovery.\"\n ),\n} as const satisfies Record<string, LucernOperationManifestEntry>;\n\nexport type LucernOperationName = keyof typeof LUCERN_OPERATION_MANIFEST;\n\nexport function surfaceEnabled(exposure: SurfaceExposure): boolean {\n return exposure !== \"none\";\n}\n\nexport function surfaceIntentGateViolations(\n entry: LucernOperationManifestEntry\n): string[] {\n const violations: string[] = [];\n if (entry.surfaceIntent === \"system\" && entry.surfaces.mcp === \"public\") {\n violations.push(\"system operations cannot be public MCP tools\");\n }\n if (\n entry.surfaceIntent === \"compatibility\" &&\n entry.surfaces.mcp !== \"none\"\n ) {\n violations.push(\"compatibility operations must not be MCP tools\");\n }\n if (entry.surfaceIntent === \"sdk_granular\" && entry.surfaces.mcp !== \"none\") {\n violations.push(\"SDK-granular operations must not be MCP tools\");\n }\n if (\n entry.surfaceIntent === \"mcp_governance\" &&\n entry.surfaces.mcp === \"public\"\n ) {\n violations.push(\"governance operations must be internal or absent from MCP\");\n }\n return violations;\n}\n","/**\n * Shared schema enums referenced by the initial table manifest.\n */\n\nimport { z } from 'zod';\n\nexport const NODE_TYPE = z.enum([\"decision\", \"belief\", \"question\", \"theme\", \"deal\", \"topic\", \"claim\", \"evidence\", \"synthesis\", \"answer\", \"atomic_fact\", \"excerpt\", \"source\", \"company\", \"person\", \"investor\", \"function\", \"value_chain\"]);\n\nexport const EDGE_TYPE_VALUES = [\"supports\", \"informs\", \"depends_on\", \"derived_from\", \"contains\", \"tests\", \"supersedes\", \"responds_to\", \"belongs_to\", \"relates_to_thesis\", \"works_at\", \"invested_in\", \"competes_with\", \"participates_in\", \"founded_by\", \"evaluates\", \"performs\", \"function_in\", \"impacts\", \"raised_from\", \"mentioned_in\", \"perspective_on\", \"plays_theme\", \"answers\", \"explores\", \"qualifies\", \"based_on\", \"based_on_belief\", \"based_on_question\", \"blocked_by_contradiction\", \"informed_by_theme\", \"same_as\", \"reinforces\", \"parent_of\", \"child_of\", \"falsified_by\", \"exclusive_with\", \"collapses_if\", \"cascade_from\", \"counterfactual_of\", \"cascade_to\", \"mutually_exclusive\", \"correlates_with\", \"amplifies\", \"precondition_for\", \"in_tension_with\", \"strengthened_by\", \"weakened_by\", \"alternative_to\", \"subsumes\", \"validated_by\", \"required_for\", \"blocks\", \"prerequisite_for\", \"parallel_to\", \"corroborates\", \"extends\", \"same_source_as\", \"same_theme_as\", \"assumes\", \"would_predict\", \"analogous_to\", \"independent_of\", \"implements\", \"violates\", \"co_changes_with\", \"migrating_from\", \"migrating_to\", \"scoped_by\", \"about_entity\", \"entity_referenced_in\", \"contradicts\", \"cites\", \"summarizes\", \"related_to\", \"partially_answers\", \"refines\", \"branches_from\"] as const;\n\nexport const STORAGE_EDGE_TYPE_VALUES = [...EDGE_TYPE_VALUES, \"extracted_from\"] as const;\n\nexport const EDGE_TYPE = z.enum(EDGE_TYPE_VALUES);\n\n// Storage accepts the legacy provenance spelling while existing rows migrate.\n// Public surfaces should continue to expose EDGE_TYPE only.\nexport const STORAGE_EDGE_TYPE = z.enum(STORAGE_EDGE_TYPE_VALUES);\n\nexport const TOPIC_STATUS = z.enum([\"active\", \"archived\", \"watching\"]);\n\nexport const TOPIC_VISIBILITY = z.enum([\"private\", \"team\", \"firm\", \"external\", \"public\"]);\n","import { z } from \"zod\";\nimport type { FunctionEffect } from \"../dsl/defineFunction.js\";\nimport { isUuidV7 } from \"../ids/index.js\";\nimport { encodePrefixedId } from \"../ids.contract.js\";\nimport type { McpParameterDef, McpToolContract } from \"../tool-contracts.js\";\nimport { MCP_TOOL_CONTRACTS } from \"../tool-contracts.js\";\nimport type {\n ContractProjectionContext,\n FunctionContract,\n SurfaceClass,\n} from \"./types.js\";\nimport {\n LUCERN_OPERATION_MANIFEST,\n type LucernOperationManifestEntry,\n} from \"./manifest.js\";\nexport { NODE_TYPE } from \"../schemas/enums.js\";\n\nexport const jsonObjectSchema = z.record(z.unknown());\nexport const uuidV7StringSchema = z\n .string()\n .refine(isUuidV7, \"must be UUIDv7\");\nconst sdkSessionIdSchema = z.string().optional();\n\nexport function publicPrefixedId(prefix: string, rawId: string): string {\n return rawId.startsWith(`${prefix}_`) ? rawId : encodePrefixedId(prefix, rawId);\n}\n\nfunction mcpContractShape(contract: McpToolContract): z.ZodRawShape {\n const required = new Set(contract.required);\n return Object.fromEntries(\n Object.entries(contract.parameters).map(([name, parameter]) => {\n const schema = schemaForMcpParameter(parameter);\n return [\n name,\n required.has(name) || parameter.required ? schema : schema.optional(),\n ];\n }),\n );\n}\n\nfunction schemaForMcpParameter(parameter: McpParameterDef): z.ZodTypeAny {\n if (parameter.enum && parameter.enum.length > 0) {\n const [first, ...rest] = parameter.enum;\n return z.enum([first, ...rest] as [string, ...string[]]);\n }\n\n switch (parameter.type) {\n case \"array\":\n return z.array(z.unknown());\n case \"boolean\":\n return z.boolean();\n case \"number\":\n return z.number();\n case \"object\":\n return z.record(z.unknown());\n case \"string\":\n return z.string();\n }\n}\n\nexport function argsSchemaFromMcpContract(\n contract: McpToolContract,\n): z.ZodObject<z.ZodRawShape> {\n return z.object(mcpContractShape(contract));\n}\n\nexport function inputSchemaFromMcpContract(\n contract: McpToolContract,\n): z.ZodObject<z.ZodRawShape> {\n return withInternalSurfaceFields(argsSchemaFromMcpContract(contract));\n}\n\n// Backward compatibility helper: public contract builders still reserve the\n// internal SDK session field on object-shaped inputs.\nfunction withInternalSurfaceFields(\n schema: z.ZodObject<z.ZodRawShape>,\n): z.ZodObject<z.ZodRawShape> {\n return schema.extend({ __sdkSessionId: sdkSessionIdSchema }).strict();\n}\n\nfunction normalizeInputSchema(schema: z.ZodTypeAny): z.ZodTypeAny {\n if (schema instanceof z.ZodObject) {\n return withInternalSurfaceFields(schema);\n }\n return schema;\n}\n\nfunction unwrapObjectSchema(\n schema: z.ZodTypeAny,\n): z.ZodObject<z.ZodRawShape> | undefined {\n let current = schema;\n while (true) {\n switch (current._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodEffects:\n current = current._def.schema;\n continue;\n case z.ZodFirstPartyTypeKind.ZodBranded:\n current = current._def.type;\n continue;\n default:\n return current instanceof z.ZodObject ? current : undefined;\n }\n }\n}\n\nfunction getObjectShape(schema: z.ZodTypeAny) {\n const objectSchema = unwrapObjectSchema(schema);\n if (!objectSchema) {\n throw new Error(\n `Expected a Zod object schema, received ${schema._def.typeName}.`,\n );\n }\n const shape =\n typeof objectSchema._def.shape === \"function\"\n ? objectSchema._def.shape()\n : objectSchema._def.shape;\n return shape as z.ZodRawShape;\n}\n\nfunction unwrapMcpParameterSchema(schema: z.ZodTypeAny): {\n schema: z.ZodTypeAny;\n required: boolean;\n description?: string;\n} {\n let current = schema;\n let required = true;\n let description = schema.description;\n\n while (true) {\n description ??= current.description;\n\n switch (current._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodOptional:\n case z.ZodFirstPartyTypeKind.ZodDefault:\n required = false;\n current = current._def.innerType;\n continue;\n case z.ZodFirstPartyTypeKind.ZodNullable:\n current = current._def.innerType;\n continue;\n case z.ZodFirstPartyTypeKind.ZodBranded:\n current = current._def.type;\n continue;\n case z.ZodFirstPartyTypeKind.ZodEffects:\n current = current._def.schema;\n continue;\n default:\n return {\n schema: current,\n required,\n description: description ?? current.description,\n };\n }\n }\n}\n\nfunction mcpParameterFromZod(\n fieldName: string,\n schema: z.ZodTypeAny,\n contractName: string,\n): { parameter: McpParameterDef; required: boolean } {\n const {\n schema: unwrapped,\n required,\n description: schemaDescription,\n } = unwrapMcpParameterSchema(schema);\n const description = schemaDescription ?? unwrapped.description ?? fieldName;\n\n switch (unwrapped._def.typeName) {\n case z.ZodFirstPartyTypeKind.ZodString:\n return { parameter: { type: \"string\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodNumber:\n return { parameter: { type: \"number\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodBoolean:\n return { parameter: { type: \"boolean\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodArray:\n return { parameter: { type: \"array\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodObject:\n case z.ZodFirstPartyTypeKind.ZodRecord:\n case z.ZodFirstPartyTypeKind.ZodDiscriminatedUnion:\n return { parameter: { type: \"object\", description }, required };\n case z.ZodFirstPartyTypeKind.ZodEnum:\n return {\n parameter: {\n type: \"string\",\n description,\n enum: [...unwrapped._def.values],\n },\n required,\n };\n case z.ZodFirstPartyTypeKind.ZodLiteral:\n if (typeof unwrapped._def.value === \"string\") {\n return {\n parameter: {\n type: \"string\",\n description,\n enum: [unwrapped._def.value],\n },\n required,\n };\n }\n break;\n }\n\n throw new Error(\n `Function surface contract ${contractName}.${fieldName} cannot be lowered to an MCP parameter from ${unwrapped._def.typeName}.`,\n );\n}\n\nfunction mcpContractFromArgsSchema(\n base: FunctionContract[\"mcp\"],\n args: z.ZodTypeAny,\n contractName: string,\n): FunctionContract[\"mcp\"] {\n const entries = Object.entries(getObjectShape(args)).sort(([left], [right]) =>\n left.localeCompare(right),\n );\n const converted = entries.map(\n ([fieldName, schema]) =>\n [\n fieldName,\n mcpParameterFromZod(fieldName, schema, contractName),\n ] as const,\n );\n\n return {\n ...base,\n parameters: Object.fromEntries(\n converted.map(([fieldName, field]) => [fieldName, field.parameter]),\n ),\n required: converted\n .filter(([, field]) => field.required)\n .map(([fieldName]) => fieldName),\n };\n}\n\nexport const defineFunctionContract = <T extends FunctionContract>(\n contract: T,\n): T => contract;\n\nexport function classifyContract<\n T extends Omit<FunctionContract, \"surfaceClass\"> & {\n surfaceClass?: SurfaceClass;\n },\n>(contract: T, surfaceClass: SurfaceClass): T & { surfaceClass: SurfaceClass } {\n return {\n ...contract,\n surfaceClass: contract.surfaceClass ?? surfaceClass,\n };\n}\n\nexport function authUserId(context: ContractProjectionContext): string {\n return context.userId ?? context.principalId ?? \"lucern-agent\";\n}\n\nexport function withUserId(\n input: Record<string, unknown>,\n context: ContractProjectionContext,\n): Record<string, unknown> {\n return {\n ...input,\n userId:\n typeof input.userId === \"string\" ? input.userId : authUserId(context),\n };\n}\n\nexport function withCreatedBy(\n input: Record<string, unknown>,\n context: ContractProjectionContext,\n): Record<string, unknown> {\n return {\n ...input,\n createdBy:\n typeof input.createdBy === \"string\"\n ? input.createdBy\n : authUserId(context),\n };\n}\n\nexport function compactRecord(\n input: Record<string, unknown>,\n): Record<string, unknown> {\n return Object.fromEntries(\n Object.entries(input).filter(([, value]) => value !== undefined),\n );\n}\n\nexport function recordValue(value: unknown): Record<string, unknown> {\n return value && typeof value === \"object\" && !Array.isArray(value)\n ? (value as Record<string, unknown>)\n : {};\n}\n\nexport function surfaceMcpContract(name: string): FunctionContract[\"mcp\"] {\n const contract = MCP_TOOL_CONTRACTS[name];\n if (!contract) {\n throw new Error(\n `Function surface contract ${name} is missing from MCP_TOOL_CONTRACTS.`,\n );\n }\n\n return {\n ...contract,\n exposed: true,\n toolName: contract.name,\n };\n}\n\nfunction deriveFunctionEffects(args: {\n kind: FunctionContract[\"kind\"];\n domain: string;\n surfaceIntent: FunctionContract[\"surfaceIntent\"];\n}): readonly FunctionEffect[] {\n if (args.kind === \"query\") {\n return [\"read\"];\n }\n\n if (\n args.surfaceIntent === \"system\" ||\n args.surfaceIntent === \"mcp_governance\" ||\n args.domain === \"identity\" ||\n args.domain === \"contracts\" ||\n args.domain === \"coordination\" ||\n args.domain === \"pipeline\"\n ) {\n return [\"admin\"];\n }\n\n return [\"write\"];\n}\n\nexport function surfaceContract(args: {\n name: string;\n kind: FunctionContract[\"kind\"];\n domain: string;\n surfaceClass: SurfaceClass;\n method?: FunctionContract[\"rest\"][\"method\"];\n path: string;\n sdkNamespace: string;\n sdkMethod: string;\n summary: string;\n tags?: string[];\n scopes?: string[];\n replacedBy?: string;\n idempotent?: FunctionContract[\"idempotent\"];\n convex?: FunctionContract[\"convex\"];\n gateway?: FunctionContract[\"gateway\"];\n args?: z.ZodTypeAny;\n returns?: z.ZodTypeAny;\n input?: z.ZodTypeAny;\n output?: z.ZodTypeAny;\n effects?: readonly FunctionEffect[];\n invariants?: readonly string[];\n}) {\n const manifest = LUCERN_OPERATION_MANIFEST as Record<\n string,\n LucernOperationManifestEntry | undefined\n >;\n const manifestEntry = manifest[args.name];\n if (!manifestEntry) {\n throw new Error(\n `Function surface contract ${args.name} is not in LUCERN_OPERATION_MANIFEST.`,\n );\n }\n if (manifestEntry.surfaceClass !== args.surfaceClass) {\n throw new Error(\n `Function surface contract ${args.name} is classified as ${args.surfaceClass}, but manifest requires ${manifestEntry.surfaceClass}.`,\n );\n }\n if (\n manifestEntry.surfaces.sdk === \"none\" &&\n manifestEntry.surfaces.rest === \"none\"\n ) {\n throw new Error(\n `Function surface contract ${args.name} has no SDK or REST exposure in the manifest.`,\n );\n }\n\n const baseMcp = surfaceMcpContract(args.name);\n const canonicalArgs = args.args ?? argsSchemaFromMcpContract(baseMcp);\n const mcp = args.args\n ? mcpContractFromArgsSchema(baseMcp, canonicalArgs, args.name)\n : baseMcp;\n const canonicalReturns = args.returns ?? jsonObjectSchema;\n const input = normalizeInputSchema(\n args.input ?? inputSchemaFromMcpContract(mcp),\n );\n const output = args.output ?? canonicalReturns;\n\n return defineFunctionContract({\n name: args.name,\n kind: args.kind,\n idempotent: args.idempotent ?? (args.kind === \"query\" ? false : true),\n effects:\n args.effects ??\n deriveFunctionEffects({\n kind: args.kind,\n domain: args.domain,\n surfaceIntent: manifestEntry.surfaceIntent,\n }),\n invariants: args.invariants,\n surfaceIntent: manifestEntry.surfaceIntent,\n domain: args.domain,\n surfaceClass: manifestEntry.surfaceClass,\n surfaces: manifestEntry.surfaces,\n replacedBy: args.replacedBy,\n rest: {\n method: args.method ?? \"POST\",\n path: args.path,\n },\n sdk: {\n namespace: args.sdkNamespace,\n method: args.sdkMethod,\n },\n mcp,\n auth: {\n scopes: args.scopes ?? [\n args.kind === \"query\" ? `${args.domain}.read` : `${args.domain}.write`,\n ],\n allowedPrincipalTypes: [\n \"user\",\n \"service\",\n \"agent\",\n \"group\",\n \"external_viewer\",\n ],\n },\n convex: args.convex,\n gateway: args.gateway,\n args: canonicalArgs,\n returns: canonicalReturns,\n input,\n output,\n openapi: {\n summary: args.summary,\n tags: args.tags ?? [args.domain],\n },\n });\n}\n\nexport function assertSurfaceCoverage(contracts: readonly FunctionContract[]) {\n const names = new Set<string>();\n for (const contract of contracts) {\n if (names.has(contract.name)) {\n throw new Error(`Duplicate function contract name: ${contract.name}`);\n }\n names.add(contract.name);\n }\n\n for (const contract of contracts) {\n if (contract.replacedBy && !names.has(contract.replacedBy)) {\n throw new Error(\n `Function contract ${contract.name} replacedBy target ${contract.replacedBy} is not registered.`,\n );\n }\n }\n}\n","import { z } from \"zod\";\nimport {\n compactRecord,\n recordValue,\n surfaceContract,\n withUserId,\n} from \"./helpers.js\";\nimport type { ContractProjectionContext, FunctionContract } from \"./types.js\";\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return Boolean(value) && typeof value === \"object\" && !Array.isArray(value);\n}\n\nfunction stringValues(value: unknown): string[] {\n if (typeof value === \"string\") {\n return [value];\n }\n if (Array.isArray(value)) {\n return value.flatMap((item) => stringValues(item));\n }\n return [];\n}\n\nfunction nestedEvidenceRows(value: unknown): Record<string, unknown>[] {\n if (Array.isArray(value)) {\n return value.flatMap((item) => nestedEvidenceRows(item));\n }\n if (!isRecord(value)) {\n return [];\n }\n\n const nestedKeys = [\"evidence\", \"items\", \"nodes\"];\n const nestedRows = nestedKeys.flatMap((key) => nestedEvidenceRows(value[key]));\n return nestedRows.length > 0 ? nestedRows : [value];\n}\n\nfunction isFailedAttemptRow(row: Record<string, unknown>): boolean {\n const metadata = isRecord(row.metadata) ? row.metadata : null;\n return (\n metadata?.failedApproach === true ||\n metadata?.isFailedAttempt === true\n );\n}\n\nfunction failureLogSearchFields(row: Record<string, unknown>): string[] {\n const metadata = isRecord(row.metadata) ? row.metadata : null;\n return [\n ...stringValues(row.id),\n ...stringValues(row._id),\n ...stringValues(row.title),\n ...stringValues(row.text),\n ...stringValues(row.canonicalText),\n ...stringValues(row.content),\n ...stringValues(metadata?.codeAnchor),\n ...stringValues(metadata?.codeAnchors),\n ...stringValues(metadata?.anchor),\n ...stringValues(metadata?.anchors),\n ...stringValues(metadata?.filePath),\n ...stringValues(metadata?.filePaths),\n ...stringValues(metadata?.path),\n ...stringValues(metadata?.paths),\n ...stringValues(metadata?.sourceRef),\n ...stringValues(metadata?.touchedPaths),\n ];\n}\n\nfunction projectFailureLog(\n output: unknown,\n input: Record<string, unknown>,\n): {\n query?: string;\n failures: Record<string, unknown>[];\n totalFound: number;\n showing: number;\n} {\n const rawQuery =\n typeof input.query === \"string\" && input.query.trim().length > 0\n ? input.query.trim()\n : undefined;\n const searchKey = rawQuery?.toLowerCase();\n const failures = nestedEvidenceRows(output)\n .filter((row) => isFailedAttemptRow(row))\n .filter((row) =>\n !searchKey\n ? true\n : failureLogSearchFields(row).some((field) =>\n field.toLowerCase().includes(searchKey),\n ),\n );\n\n return {\n query: rawQuery,\n failures,\n totalFound: failures.length,\n showing: failures.length,\n };\n}\n\nconst recordScopeLearningArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope ID\"),\n summary: z.string().describe(\"Atomic learning statement\"),\n title: z\n .string()\n .optional()\n .describe(\"Optional evidence title, such as a commit, doc, or issue.\"),\n body: z\n .string()\n .optional()\n .describe(\n \"Optional rich evidence body. If omitted, body is synthesized from summary and touched paths.\"\n ),\n contentType: z\n .string()\n .optional()\n .describe(\"Optional evidence body format, such as markdown or text.\"),\n sourceKind: z\n .enum([\"commit\", \"merge\", \"doc\", \"issue\", \"manual\"])\n .optional()\n .describe(\"Source type for the learning event\"),\n sourceRef: z\n .string()\n .optional()\n .describe(\"Optional source reference, such as SHA, PR number, or URL slug.\"),\n sourceUrl: z.string().optional().describe(\"Optional canonical source URL\"),\n touchedPaths: z\n .array(z.string())\n .optional()\n .describe(\"Optional touched file paths for retrieval hints\"),\n tags: z.array(z.string()).optional().describe(\"Optional tags\"),\n linkedBeliefNodeId: z\n .string()\n .optional()\n .describe(\"Optional belief to attach evidence to\"),\n evidenceRelation: z\n .enum([\"supports\", \"contradicts\"])\n .optional()\n .describe(\"Relation to linked belief\"),\n confidence: z.number().optional().describe(\"Optional confidence in [0,1]\"),\n rationale: z\n .string()\n .optional()\n .describe(\"Why this learning should enter the reasoning graph\"),\n createQuestionText: z\n .string()\n .optional()\n .describe(\"Optional follow-up question text\"),\n createBeliefText: z\n .string()\n .optional()\n .describe(\"Optional new belief text\"),\n beliefType: z\n .string()\n .optional()\n .describe(\"Optional belief type for createBeliefText\"),\n text: z.string().optional().describe(\"Canonical learning text alias.\"),\n content: z\n .string()\n .optional()\n .describe(\"Canonical learning content alias.\"),\n kind: z.string().optional().describe(\"Evidence kind to store.\"),\n sourceType: z.string().optional().describe(\"Evidence source type.\"),\n externalSourceType: z\n .string()\n .optional()\n .describe(\"External source type alias.\"),\n metadata: z.record(z.unknown()).optional().describe(\"Learning metadata.\"),\n});\n\nconst codeContextArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope.\"),\n filePath: z.string().optional().describe(\"File path anchor.\"),\n includeFailures: z\n .boolean()\n .optional()\n .describe(\"Whether to include failed attempts.\"),\n limit: z.number().optional().describe(\"Maximum records to return.\"),\n status: z.string().optional().describe(\"Evidence status filter.\"),\n});\n\nconst recordAttemptArgs = z.object({\n topicId: z.string().optional().describe(\"Topic scope.\"),\n description: z.string().describe(\"Attempt description.\"),\n errorMessage: z.string().optional().describe(\"Failure or error message.\"),\n filePaths: z\n .array(z.string())\n .optional()\n .describe(\"Files involved in the attempt.\"),\n filePath: z.string().optional().describe(\"Single file path alias.\"),\n linkedBeliefId: z.string().optional().describe(\"Linked belief ID.\"),\n metadata: z.record(z.unknown()).optional().describe(\"Attempt metadata.\"),\n rationale: z\n .string()\n .optional()\n .describe(\"Why this attempt should be recorded.\"),\n title: z.string().optional().describe(\"Attempt evidence title.\"),\n});\n\nconst learningInput = (\n input: Record<string, unknown>,\n context: ContractProjectionContext\n) => {\n const sourceKind = input.sourceKind ?? input.externalSourceType;\n return withUserId(\n compactRecord({\n projectId: input.projectId,\n topicId: input.topicId,\n text: input.summary ?? input.text,\n title: input.title ?? input.summary ?? \"Scope learning\",\n content: input.body ?? input.content ?? input.summary,\n contentType: input.contentType,\n kind: input.kind ?? \"learning\",\n tags: input.tags ?? [],\n sourceType: input.sourceType,\n externalSourceType: input.externalSourceType ?? input.sourceKind,\n sourceUrl: input.sourceUrl,\n metadata: compactRecord({\n ...recordValue(input.metadata),\n sourceRef: input.sourceRef,\n sourceKind,\n touchedPaths: input.touchedPaths,\n createQuestionText: input.createQuestionText,\n createBeliefText: input.createBeliefText,\n beliefType: input.beliefType,\n }),\n linkedBeliefNodeId: input.linkedBeliefNodeId,\n evidenceRelation: input.evidenceRelation,\n confidence: input.confidence,\n rationale:\n input.rationale ??\n input.reasoning ??\n input.summary ??\n input.text ??\n \"Recorded scope learning\",\n trustedBypassAccessCheck: input.trustedBypassAccessCheck ?? true,\n }),\n context\n );\n};\n\nconst attemptInput = (\n input: Record<string, unknown>,\n context: ContractProjectionContext\n) =>\n withUserId(\n compactRecord({\n projectId: input.projectId,\n topicId: input.topicId,\n text: input.description,\n title: input.title ?? input.description,\n content: input.errorMessage ?? input.description,\n kind: \"code_attempt\",\n tags: [\"code_attempt\"],\n metadata: compactRecord({\n ...recordValue(input.metadata),\n failedApproach: true,\n isFailedAttempt: true,\n filePaths: input.filePaths,\n filePath: input.filePath,\n errorMessage: input.errorMessage,\n linkedBeliefId: input.linkedBeliefId,\n }),\n rationale:\n input.rationale ??\n input.reasoning ??\n input.errorMessage ??\n input.description ??\n \"Recorded implementation attempt\",\n trustedBypassAccessCheck: input.trustedBypassAccessCheck ?? true,\n }),\n context\n );\n\nexport const codingContracts = [\n surfaceContract({\n name: \"record_scope_learning\",\n kind: \"mutation\",\n domain: \"scope\",\n surfaceClass: \"platform_internal\",\n path: \"/scope/learnings\",\n sdkNamespace: \"context\",\n sdkMethod: \"recordScopeLearning\",\n summary: \"Record a scope-level learning to the reasoning graph.\",\n args: recordScopeLearningArgs,\n input: recordScopeLearningArgs,\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: learningInput,\n },\n }),\n surfaceContract({\n name: \"manage_write_policy\",\n kind: \"mutation\",\n domain: \"policy\",\n surfaceClass: \"tenant_public\",\n path: \"/policy/write-policy/manage\",\n sdkNamespace: \"policy\",\n sdkMethod: \"manageWritePolicy\",\n summary: \"Manage MCP write policy rules.\",\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: (input, context) =>\n learningInput(\n {\n ...input,\n summary:\n input.summary ??\n `Write policy ${String(input.action ?? \"update\")}`,\n sourceKind: \"write_policy\",\n },\n context\n ),\n },\n }),\n surfaceContract({\n name: \"get_code_context\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/context\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getCodeContext\",\n summary: \"Read code context for graph-linked files.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n },\n args: codeContextArgs,\n }),\n surfaceContract({\n name: \"get_change_history\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/change-history\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getChangeHistory\",\n summary: \"Read recorded code change attempts.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n },\n }),\n surfaceContract({\n name: \"record_attempt\",\n kind: \"mutation\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/attempts\",\n sdkNamespace: \"coding\",\n sdkMethod: \"recordAttempt\",\n summary: \"Record a code attempt for failure learning.\",\n convex: {\n module: \"evidence\",\n functionName: \"create\",\n kind: \"mutation\",\n inputProjection: attemptInput,\n },\n args: recordAttemptArgs,\n }),\n surfaceContract({\n name: \"get_failure_log\",\n kind: \"query\",\n domain: \"coding\",\n surfaceClass: \"platform_internal\",\n path: \"/coding/failure-log\",\n sdkNamespace: \"coding\",\n sdkMethod: \"getFailureLog\",\n summary: \"Read code failure log entries.\",\n convex: {\n module: \"evidence\",\n functionName: \"getByTopic\",\n kind: \"query\",\n inputProjection: (input) =>\n compactRecord({\n topicId: input.topicId ?? input.query,\n limit: input.limit,\n status: input.status,\n userId: input.userId,\n }),\n outputProjection: (output, input) => projectFailureLog(output, input),\n },\n }),\n] as const satisfies readonly FunctionContract[];\n"]}