0xray 3.5.5 → 4.0.0
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.
- package/.mcp.json +51 -7
- package/.opencode/skills/api-design/SKILL.md +1 -1
- package/.opencode/skills/architect-tools/SKILL.md +1 -1
- package/.opencode/skills/architecture-patterns/SKILL.md +1 -1
- package/.opencode/skills/auto-format/SKILL.md +1 -1
- package/.opencode/skills/boot-orchestrator/SKILL.md +2 -6
- package/.opencode/skills/bug-triage/SKILL.md +1 -1
- package/.opencode/skills/code-analyzer/SKILL.md +1 -1
- package/.opencode/skills/code-review/SKILL.md +1 -1
- package/.opencode/skills/enforcer/SKILL.md +1 -1
- package/.opencode/skills/framework-compliance-audit/SKILL.md +1 -1
- package/.opencode/skills/git-workflow/SKILL.md +1 -1
- package/.opencode/skills/hermes-agent/SKILL.md +36 -36
- package/.opencode/skills/inference-improve/SKILL.md +1 -1
- package/.opencode/skills/lint/SKILL.md +1 -1
- package/.opencode/skills/log-monitor/SKILL.md +1 -1
- package/.opencode/skills/model-health-check/SKILL.md +1 -1
- package/.opencode/skills/multimodal-looker/SKILL.md +1 -1
- package/.opencode/skills/orchestrator/SKILL.md +38 -14
- package/.opencode/skills/performance-analysis/SKILL.md +1 -1
- package/.opencode/skills/performance-optimization/SKILL.md +1 -1
- package/.opencode/skills/processor-pipeline/SKILL.md +1 -1
- package/.opencode/skills/project-analysis/SKILL.md +1 -1
- package/.opencode/skills/refactoring-strategies/SKILL.md +1 -1
- package/.opencode/skills/registry.json +65 -0
- package/.opencode/skills/researcher/SKILL.md +18 -5
- package/.opencode/skills/security-audit/SKILL.md +1 -1
- package/.opencode/skills/security-scan/SKILL.md +1 -1
- package/.opencode/skills/session-management/SKILL.md +1 -1
- package/.opencode/skills/state-manager/SKILL.md +1 -1
- package/.opencode/skills/storyteller/SKILL.md +1 -1
- package/.opencode/skills/strategist/SKILL.md +12 -0
- package/.opencode/skills/testing-best-practices/SKILL.md +37 -0
- package/.opencode/skills/testing-strategy/SKILL.md +14 -3
- package/.opencode/skills/ui-ux-design/SKILL.md +1 -1
- package/.opencode/skills/xray-orchestrator/index.ts +267 -0
- package/.xray/codex.json +12 -3
- package/.xray/features.json +27 -5
- package/.xray/features.schema.json +31 -0
- package/AGENTS-consumer.md +16 -6
- package/AGENTS.md +11 -3
- package/README.md +13 -10
- package/SKILLS.md +1 -1
- package/dist/AGENTS.md +11 -3
- package/dist/CHANGELOG.md +65 -11
- package/dist/README.md +13 -10
- package/dist/SKILLS.md +1 -1
- package/dist/cli/commands/hermes-install.js +3 -0
- package/dist/cli/commands/openclaw-install.js +14 -0
- package/dist/core/features-config.d.ts +15 -2
- package/dist/infrastructure/schemas/cloud-schemas.d.ts +1 -1
- package/dist/integrations/grok/grok-cli.d.ts +3 -0
- package/dist/integrations/grok/grok-cli.js +92 -4
- package/dist/integrations/grok/hooks/grok-hook-utils.js +53 -7
- package/dist/integrations/grok/hooks/post-tool-use.js +68 -46
- package/dist/integrations/grok/hooks/pre-tool-use.js +14 -31
- package/dist/integrations/grok/hooks/session-start.js +86 -4
- package/dist/integrations/grok/plugin/0xray/hooks/hooks.json +31 -24
- package/dist/integrations/hermes-agent/bridge.mjs +19 -1
- package/dist/integrations/hooks/delegation-gate-runtime.mjs +32 -3
- package/dist/integrations/hooks/pipeline-hook-runtime.mjs +1 -1
- package/dist/integrations/hooks/station-hook-runtime.cjs +421 -0
- package/dist/integrations/hooks/station-hook-runtime.mjs +24 -0
- package/dist/integrations/hooks/station-memory-ingest.mjs +45 -0
- package/dist/integrations/hooks/station-memory-match.mjs +47 -0
- package/dist/integrations/openclaw/client.d.ts +5 -1
- package/dist/integrations/openclaw/client.js +17 -9
- package/dist/integrations/openclaw/config.js +0 -1
- package/dist/integrations/openclaw/hooks/pre-tool-gate-runtime.mjs +102 -0
- package/dist/integrations/openclaw/index.js +17 -0
- package/dist/integrations/openclaw/plugin/xray-pre-tool/index.js +75 -0
- package/dist/integrations/openclaw/plugin/xray-pre-tool/openclaw.plugin.json +10 -0
- package/dist/integrations/openclaw/plugin/xray-pre-tool/package.json +10 -0
- package/dist/integrations/openclaw/pre-tool-gate.d.ts +19 -0
- package/dist/integrations/openclaw/pre-tool-gate.js +39 -0
- package/dist/mcps/orchestrator/handlers/complexity-handler.js +2 -2
- package/dist/memory-routing/index.d.ts +1 -1
- package/dist/memory-routing/index.js +1 -1
- package/dist/memory-routing/provider-loader.d.ts +4 -0
- package/dist/memory-routing/provider-loader.js +44 -2
- package/dist/memory-routing/provider-registry.js +3 -2
- package/dist/nucleus/autonomy-kernel.d.ts +2 -2
- package/dist/nucleus/autonomy-kernel.js +17 -6
- package/dist/nucleus/confer.js +17 -3
- package/dist/nucleus/delegation-gate.d.ts +14 -8
- package/dist/nucleus/delegation-gate.js +151 -16
- package/dist/nucleus/suit-temperament.d.ts +40 -0
- package/dist/nucleus/suit-temperament.js +157 -0
- package/dist/nucleus/user-aside.js +1 -1
- package/dist/plugin/xray-codex-injection.js +14 -3
- package/dist/postprocessor/triggers/GitHookTrigger.js +11 -5
- package/opencode.json +88 -0
- package/package.json +14 -4
- package/scripts/hooks/install-hooks.cjs +18 -3
- package/scripts/hooks/run-hook.js +67 -3
- package/scripts/mjs/run-repertoire-mcp.mjs +39 -0
- package/scripts/mjs/verify-confer-core.mjs +1 -1
- package/scripts/mjs/verify-delegation-gate-core.mjs +29 -2
- package/scripts/mjs/verify-four-floor-compact.mjs +524 -0
- package/scripts/mjs/verify-pipeline-facets.mjs +215 -0
- package/scripts/mjs/verify-temperament-live.mjs +261 -0
- package/scripts/node/bridge-mcp-wiring.cjs +277 -29
- package/scripts/node/install-bridges.cjs +195 -33
- package/scripts/node/postinstall.cjs +50 -27
- package/scripts/node/release-gate.mjs +1 -1
- package/scripts/node/release.mjs +2 -2
- package/scripts/node/validate-release-docs.mjs +20 -33
- package/scripts/node/version-manager.mjs +25 -10
- package/src/integrations/grok/plugin/0xray/hooks/hooks.json +31 -24
- package/src/integrations/openclaw/README.md +134 -0
- package/src/integrations/openclaw/plugin/xray-pre-tool/index.js +75 -0
- package/src/integrations/openclaw/plugin/xray-pre-tool/openclaw.plugin.json +10 -0
- package/src/integrations/openclaw/plugin/xray-pre-tool/package.json +10 -0
- package/src/mcps/orchestrator/handlers/complexity-handler.ts +2 -1
- package/vendor/@0xray/repertoire/AGENTS.md +163 -0
- package/vendor/@0xray/repertoire/LICENSE +21 -0
- package/vendor/@0xray/repertoire/README.md +120 -0
- package/vendor/@0xray/repertoire/data/curated_signals.json +208 -0
- package/vendor/@0xray/repertoire/dist/RepertoireService.d.ts +78 -0
- package/vendor/@0xray/repertoire/dist/RepertoireService.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/RepertoireService.js +153 -0
- package/vendor/@0xray/repertoire/dist/RepertoireService.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/governance/ontological-trap-enforcer.d.ts +39 -0
- package/vendor/@0xray/repertoire/dist/governance/ontological-trap-enforcer.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/governance/ontological-trap-enforcer.js +60 -0
- package/vendor/@0xray/repertoire/dist/governance/ontological-trap-enforcer.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/index.d.ts +14 -0
- package/vendor/@0xray/repertoire/dist/index.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/index.js +14 -0
- package/vendor/@0xray/repertoire/dist/index.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-ingester.d.ts +26 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-ingester.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-ingester.js +109 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-ingester.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-parser.d.ts +18 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-parser.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-parser.js +94 -0
- package/vendor/@0xray/repertoire/dist/ingestion/groover-log-parser.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/orchestrator-feedback-ingester.d.ts +7 -0
- package/vendor/@0xray/repertoire/dist/ingestion/orchestrator-feedback-ingester.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/orchestrator-feedback-ingester.js +18 -0
- package/vendor/@0xray/repertoire/dist/ingestion/orchestrator-feedback-ingester.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/xray-session-ingester.d.ts +31 -0
- package/vendor/@0xray/repertoire/dist/ingestion/xray-session-ingester.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/ingestion/xray-session-ingester.js +83 -0
- package/vendor/@0xray/repertoire/dist/ingestion/xray-session-ingester.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/mcp/server.d.ts +6 -0
- package/vendor/@0xray/repertoire/dist/mcp/server.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/mcp/server.js +173 -0
- package/vendor/@0xray/repertoire/dist/mcp/server.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/RepertoireOrchestratorBridge.d.ts +27 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/RepertoireOrchestratorBridge.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/RepertoireOrchestratorBridge.js +107 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/RepertoireOrchestratorBridge.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/capability-enhancer.d.ts +11 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/capability-enhancer.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/capability-enhancer.js +32 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/capability-enhancer.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/confidence-gate.d.ts +9 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/confidence-gate.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/confidence-gate.js +72 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/confidence-gate.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-agent-affinity.d.ts +5 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-agent-affinity.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-agent-affinity.js +18 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-agent-affinity.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-injector.d.ts +31 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-injector.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-injector.js +218 -0
- package/vendor/@0xray/repertoire/dist/orchestrator-bridge/signal-injector.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/paths.d.ts +24 -0
- package/vendor/@0xray/repertoire/dist/paths.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/paths.js +74 -0
- package/vendor/@0xray/repertoire/dist/paths.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/provider/memory-routing-provider.d.ts +141 -0
- package/vendor/@0xray/repertoire/dist/provider/memory-routing-provider.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/provider/memory-routing-provider.js +210 -0
- package/vendor/@0xray/repertoire/dist/provider/memory-routing-provider.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/CuratedSignalsManager.d.ts +48 -0
- package/vendor/@0xray/repertoire/dist/registry/CuratedSignalsManager.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/CuratedSignalsManager.js +221 -0
- package/vendor/@0xray/repertoire/dist/registry/CuratedSignalsManager.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/InferenceStateManager.d.ts +11 -0
- package/vendor/@0xray/repertoire/dist/registry/InferenceStateManager.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/InferenceStateManager.js +43 -0
- package/vendor/@0xray/repertoire/dist/registry/InferenceStateManager.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/signal-prune.d.ts +15 -0
- package/vendor/@0xray/repertoire/dist/registry/signal-prune.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/registry/signal-prune.js +35 -0
- package/vendor/@0xray/repertoire/dist/registry/signal-prune.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/concrete-sections.d.ts +3 -0
- package/vendor/@0xray/repertoire/dist/synthesis/concrete-sections.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/concrete-sections.js +24 -0
- package/vendor/@0xray/repertoire/dist/synthesis/concrete-sections.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/meta-inference-engine.d.ts +24 -0
- package/vendor/@0xray/repertoire/dist/synthesis/meta-inference-engine.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/meta-inference-engine.js +148 -0
- package/vendor/@0xray/repertoire/dist/synthesis/meta-inference-engine.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/primitive-confidence-aggregator.d.ts +4 -0
- package/vendor/@0xray/repertoire/dist/synthesis/primitive-confidence-aggregator.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/primitive-confidence-aggregator.js +44 -0
- package/vendor/@0xray/repertoire/dist/synthesis/primitive-confidence-aggregator.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/synthesis-prompt-builder.d.ts +22 -0
- package/vendor/@0xray/repertoire/dist/synthesis/synthesis-prompt-builder.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/synthesis/synthesis-prompt-builder.js +66 -0
- package/vendor/@0xray/repertoire/dist/synthesis/synthesis-prompt-builder.js.map +1 -0
- package/vendor/@0xray/repertoire/dist/types.d.ts +210 -0
- package/vendor/@0xray/repertoire/dist/types.d.ts.map +1 -0
- package/vendor/@0xray/repertoire/dist/types.js +2 -0
- package/vendor/@0xray/repertoire/dist/types.js.map +1 -0
- package/vendor/@0xray/repertoire/docs/MEMORY-ROUTING-PROVIDER.md +54 -0
- package/vendor/@0xray/repertoire/hermes-mcp.example.json +20 -0
- package/vendor/@0xray/repertoire/mcp-config.example.json +11 -0
- package/vendor/@0xray/repertoire/package.json +124 -0
- package/vendor/@0xray/repertoire/schemas/curated-signal.schema.json +68 -0
- package/vendor/@0xray/repertoire/schemas/inference-log.schema.json +82 -0
- package/vendor/@0xray/repertoire/scripts/confirm-suit-all.mjs +253 -0
- package/vendor/@0xray/repertoire/scripts/confirm-suit-harness.mjs +220 -0
- package/vendor/@0xray/repertoire/scripts/run-live-synthesis-checkpoint.mjs +215 -0
- package/vendor/@0xray/repertoire/scripts/suit-bridge-shared.mjs +139 -0
- package/vendor/@0xray/repertoire/scripts/verify-grok-suit.mjs +304 -0
- package/vendor/@0xray/repertoire/scripts/verify-hermes-suit.mjs +163 -0
- package/vendor/@0xray/repertoire/scripts/verify-openclaw-suit.mjs +125 -0
- package/vendor/@0xray/repertoire/scripts/verify-opencode-suit.mjs +127 -0
- package/vendor/@0xray/repertoire/scripts/verify-synthesis-dogfood.mjs +207 -0
- package/vendor/@0xray/repertoire/skills/repertoire-trap-handling/SKILL.md +206 -0
- package/xray/codex.json +12 -3
- package/xray/features.json +27 -5
- package/xray/features.schema.json +31 -0
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: repertoire-trap-handling
|
|
3
|
+
description: Query Repertoire MCP tools before governance on ontological-trap tasks. Routes high-confidence traps to architect and injects matched signals as evidence.
|
|
4
|
+
author: 0xRay / Repertoire
|
|
5
|
+
version: 1.0.0
|
|
6
|
+
schema_version: "1.0"
|
|
7
|
+
tags: [repertoire, ontological-trap, governance, memory-routing, architect]
|
|
8
|
+
capabilities:
|
|
9
|
+
- evaluate_trap_confidence
|
|
10
|
+
- search_primitives
|
|
11
|
+
- route_trap_tasks
|
|
12
|
+
dependencies:
|
|
13
|
+
- repertoire-mcp
|
|
14
|
+
|
|
15
|
+
metadata:
|
|
16
|
+
hermes:
|
|
17
|
+
tags: [Repertoire, OntologicalTrap, Governance, MCP, Architect]
|
|
18
|
+
related_skills: [researcher, security-audit, architect-tools]
|
|
19
|
+
opencode:
|
|
20
|
+
tags: [repertoire, trap, governance]
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
# Repertoire Trap Handling
|
|
24
|
+
|
|
25
|
+
Use this skill when a task or proposal may involve an **ontological trap** — cases where attestation, closure, or verdict language masks an ongoing validation obligation at a trust boundary.
|
|
26
|
+
|
|
27
|
+
Repertoire maintains a curated primitive registry (`curated_signals.json`) fed by **enriched Groover logs** (`matched_primitives` + `match_confidence`). The MCP surface is the **primary contract** for LLM agents running in Hermes, OpenCode, Claude Code, or similar hosts.
|
|
28
|
+
|
|
29
|
+
## When to Activate
|
|
30
|
+
|
|
31
|
+
Trigger this skill when **any** of the following are true:
|
|
32
|
+
|
|
33
|
+
- Task or proposal text contains `TYPE: ontological-trap`
|
|
34
|
+
- Description mentions ontological-trap primitives (e.g. `attestation-as-map`, consumer-boundary revalidation)
|
|
35
|
+
- User asks for governance, architecture review, or researcher analysis on attestation / closure / verdict semantics
|
|
36
|
+
- You are about to call `analyze_proposal` on a trap-adjacent inference
|
|
37
|
+
|
|
38
|
+
Do **not** skip Repertoire on trap-classified work. In-process 0xRay routing may not be available in your host process.
|
|
39
|
+
|
|
40
|
+
## Required MCP Server
|
|
41
|
+
|
|
42
|
+
Register `repertoire-mcp` in your host config (see `mcp-config.example.json` in the repertoire repo):
|
|
43
|
+
|
|
44
|
+
```json
|
|
45
|
+
{
|
|
46
|
+
"mcpServers": {
|
|
47
|
+
"repertoire": {
|
|
48
|
+
"command": "node",
|
|
49
|
+
"args": ["/absolute/path/to/repertoire/dist/mcp/server.js"],
|
|
50
|
+
"env": {
|
|
51
|
+
"CURATED_SIGNALS_PATH": "/absolute/path/to/repertoire/data/curated_signals.json"
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Build first: `cd repertoire && npm run build`
|
|
59
|
+
|
|
60
|
+
Optional companion servers for governance follow-through:
|
|
61
|
+
|
|
62
|
+
- `xray-researcher` — `analyze_proposal` from a codebase/history perspective
|
|
63
|
+
- `xray-architect-tools` — architecture-level trap remediation
|
|
64
|
+
- `xray-code-review` / `xray-governance` — committee votes
|
|
65
|
+
|
|
66
|
+
## Workflow
|
|
67
|
+
|
|
68
|
+
### Step 1 — Evaluate task confidence
|
|
69
|
+
|
|
70
|
+
Call `repertoire__get_task_confidence` with the full task or proposal text.
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
repertoire__get_task_confidence({
|
|
74
|
+
description: "<title + description + relevant context>",
|
|
75
|
+
type: "governance",
|
|
76
|
+
taskId: "<optional-id>"
|
|
77
|
+
})
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
**Example description:**
|
|
81
|
+
|
|
82
|
+
```
|
|
83
|
+
TYPE: ontological-trap
|
|
84
|
+
Attestation-as-map requires consumer-side revalidation at the trust boundary.
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### Step 2 — Interpret the response
|
|
88
|
+
|
|
89
|
+
The tool returns JSON `TaskConfidenceContext`. Key fields:
|
|
90
|
+
|
|
91
|
+
| Field | Meaning |
|
|
92
|
+
|-------|---------|
|
|
93
|
+
| `highConfidenceTrapPresent` | Trap detected **and** at least one trap signal has confidence ≥ 0.55 |
|
|
94
|
+
| `ontologicalTrapDetected` | Trap language or tags matched (may be true without high confidence) |
|
|
95
|
+
| `matchedSignals` | Primitive names that passed the confidence gate |
|
|
96
|
+
| `signals` | `{ name, confidence, source }` details |
|
|
97
|
+
| `complexityBoost` | Suggested complexity increase for routing (orchestrator use) |
|
|
98
|
+
| `recommendedAgent` | `"architect"` when `highConfidenceTrapPresent`; otherwise `null` |
|
|
99
|
+
| `minConfidenceGate` | Threshold used (default `0.55`) |
|
|
100
|
+
|
|
101
|
+
### Step 3 — Act on high-confidence traps
|
|
102
|
+
|
|
103
|
+
If `highConfidenceTrapPresent === true`:
|
|
104
|
+
|
|
105
|
+
1. **Route preference:** Prefer `architect` (or `recommendedAgent` if set). Trap-capable agents: `architect`, `security-auditor`, `researcher`.
|
|
106
|
+
2. **Evidence:** Include `matchedSignals` and per-signal confidences in your reasoning and any governance evidence array.
|
|
107
|
+
3. **Complexity:** Treat the task as elevated complexity (`complexityBoost` is advisory for orchestrator routing).
|
|
108
|
+
4. **Do not flatten the trap:** Avoid approving language that treats attestation as a terminating verdict when the registry says consumer revalidation is required.
|
|
109
|
+
|
|
110
|
+
If `ontologicalTrapDetected === true` but `highConfidenceTrapPresent === false`:
|
|
111
|
+
|
|
112
|
+
- Proceed with caution; registry may lack enriched observations yet.
|
|
113
|
+
- Note that confidence is below the promotion gate — do not treat as validated memory.
|
|
114
|
+
|
|
115
|
+
### Step 4 — Optional primitive search
|
|
116
|
+
|
|
117
|
+
For additional registry context:
|
|
118
|
+
|
|
119
|
+
```
|
|
120
|
+
repertoire__search_primitives({
|
|
121
|
+
query: "attestation-as-map ontological-trap",
|
|
122
|
+
minConfidence: 0.55,
|
|
123
|
+
limit: 5
|
|
124
|
+
})
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
Use results for definitions, tags, `observationCount`, and `confidence` in your analysis. Only signals with `observation_stats` appear — no text-score fallbacks.
|
|
128
|
+
|
|
129
|
+
### Step 5 — Governance / analysis
|
|
130
|
+
|
|
131
|
+
Proceed with your governance or analysis tools, **referencing Repertoire explicitly**:
|
|
132
|
+
|
|
133
|
+
```
|
|
134
|
+
repertoire__get_task_confidence → highConfidenceTrapPresent: true
|
|
135
|
+
matchedSignals: attestation-as-map (0.90)
|
|
136
|
+
recommendedAgent: architect
|
|
137
|
+
→ calling xray-researcher analyze_proposal with signals as evidence
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
**Researcher example:**
|
|
141
|
+
|
|
142
|
+
```
|
|
143
|
+
xray-researcher.analyze_proposal({
|
|
144
|
+
proposalTitle: "Attestation boundary review",
|
|
145
|
+
proposalDescription: "TYPE: ontological-trap ...",
|
|
146
|
+
proposalType: "governance",
|
|
147
|
+
evidence: [
|
|
148
|
+
"Repertoire: attestation-as-map (confidence 0.90)",
|
|
149
|
+
"Repertoire recommendedAgent: architect",
|
|
150
|
+
"Repertoire complexityBoost: 19"
|
|
151
|
+
]
|
|
152
|
+
})
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
When the researcher response includes a `MEMORY_ROUTING:` block, preserve it in summaries — it is the auditable signal trail.
|
|
156
|
+
|
|
157
|
+
### Step 6 — Feedback (orchestrated runs only)
|
|
158
|
+
|
|
159
|
+
After task completion in an orchestrated session, record outcomes:
|
|
160
|
+
|
|
161
|
+
```
|
|
162
|
+
repertoire__ingest_feedback({
|
|
163
|
+
sessionId: "<session>",
|
|
164
|
+
taskId: "<task>",
|
|
165
|
+
assignedAgent: "architect",
|
|
166
|
+
memorySignals: ["attestation-as-map"],
|
|
167
|
+
complexity: 45,
|
|
168
|
+
success: true,
|
|
169
|
+
durationMs: 12000
|
|
170
|
+
})
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
## Decision Checklist
|
|
174
|
+
|
|
175
|
+
Before finalizing a trap-classified governance vote:
|
|
176
|
+
|
|
177
|
+
- [ ] Called `repertoire__get_task_confidence`
|
|
178
|
+
- [ ] Checked `highConfidenceTrapPresent`
|
|
179
|
+
- [ ] If true: noted `matchedSignals`, `recommendedAgent`, `complexityBoost`
|
|
180
|
+
- [ ] Included Repertoire evidence in reasoning
|
|
181
|
+
- [ ] Routed to architect (or trap-capable agent) when recommended
|
|
182
|
+
- [ ] Did not treat low-confidence trap detection as validated memory
|
|
183
|
+
|
|
184
|
+
## Example: Full trap flow
|
|
185
|
+
|
|
186
|
+
**User task:** Review a proposal that closes an attestation loop without consumer revalidation.
|
|
187
|
+
|
|
188
|
+
**Agent actions:**
|
|
189
|
+
|
|
190
|
+
1. `repertoire__get_task_confidence({ description: "TYPE: ontological-trap attestation-as-map ...", type: "governance" })`
|
|
191
|
+
2. Response: `highConfidenceTrapPresent: true`, `matchedSignals: ["attestation-as-map"]`, `recommendedAgent: "architect"`
|
|
192
|
+
3. `repertoire__search_primitives({ query: "attestation-as-map", minConfidence: 0.55 })` — read definition
|
|
193
|
+
4. Invoke `architect` or `xray-researcher analyze_proposal` with Repertoire evidence
|
|
194
|
+
5. Vote/recommend **reject** or **request revision** if proposal treats attestation as final without consumer boundary checks
|
|
195
|
+
|
|
196
|
+
## What This Skill Does Not Do
|
|
197
|
+
|
|
198
|
+
- **In-process MemoryRoutingProvider** — used by 0xRay `ExecutionPlanner` / `thinDispatch` inside the orchestrator process only. LLM hosts should use MCP tools.
|
|
199
|
+
- **Legacy log ingest** — unstructured Groover logs without `match_confidence` are skipped; empty registry → low confidence is expected until enriched logs land.
|
|
200
|
+
- **Replace architect judgment** — Repertoire supplies signal-backed context; the LLM still reasons and votes.
|
|
201
|
+
|
|
202
|
+
## Related Documentation
|
|
203
|
+
|
|
204
|
+
- [ARCHITECTURE.md](../../ARCHITECTURE.md) — deployment model, internal vs MCP surfaces
|
|
205
|
+
- [mcp-config.example.json](../../mcp-config.example.json) — MCP server registration
|
|
206
|
+
- [docs/MEMORY-ROUTING-PROVIDER.md](../../docs/MEMORY-ROUTING-PROVIDER.md) — in-process provider (0xRay orchestrator only)
|
package/xray/codex.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": "3.1.0",
|
|
3
|
-
"lastUpdated": "2026-
|
|
3
|
+
"lastUpdated": "2026-08-24",
|
|
4
4
|
"errorPreventionTarget": 0.998,
|
|
5
5
|
"terms": {
|
|
6
6
|
"1": {
|
|
@@ -546,6 +546,14 @@
|
|
|
546
546
|
"category": "process",
|
|
547
547
|
"zeroTolerance": false,
|
|
548
548
|
"enforcementLevel": "high"
|
|
549
|
+
},
|
|
550
|
+
"69": {
|
|
551
|
+
"number": 69,
|
|
552
|
+
"title": "No New MCP, Skill, or Handler Surface",
|
|
553
|
+
"description": "Do not add parallel APIs. Rewire existing MCP servers, skills, and orchestrator handlers. PreToolUse denies creating new src/mcps/*.server.ts, src/skills/*/SKILL.md, or orchestrator *-handler files. Existing files may be rewritten.",
|
|
554
|
+
"category": "process",
|
|
555
|
+
"zeroTolerance": true,
|
|
556
|
+
"enforcementLevel": "blocking"
|
|
549
557
|
}
|
|
550
558
|
},
|
|
551
559
|
"interweaves": [
|
|
@@ -589,10 +597,11 @@
|
|
|
589
597
|
"No type errors or any usage": true,
|
|
590
598
|
"Agent spawns go through governor": true,
|
|
591
599
|
"Subagent spawning prevented": true,
|
|
592
|
-
"PostProcessor validation passes": true
|
|
600
|
+
"PostProcessor validation passes": true,
|
|
601
|
+
"No new MCP/skill/handler surface": true
|
|
593
602
|
},
|
|
594
603
|
"frameworkAlignment": {
|
|
595
604
|
"OpenCode": "v1.1.1",
|
|
596
|
-
"0xRay": "
|
|
605
|
+
"0xRay": "v4.0.0"
|
|
597
606
|
}
|
|
598
607
|
}
|
package/xray/features.json
CHANGED
|
@@ -1,7 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "./features.schema.json",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "0xRay Framework - Unified Feature Configuration",
|
|
5
|
+
"suit_temperament": {
|
|
6
|
+
"profile": "auto",
|
|
7
|
+
"host_defaults": {
|
|
8
|
+
"grok": "frontier",
|
|
9
|
+
"hermes": "guided",
|
|
10
|
+
"opencode": "guided",
|
|
11
|
+
"openclaw": "guided",
|
|
12
|
+
"generic": "guided"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
5
15
|
"token_optimization": {
|
|
6
16
|
"enabled": true,
|
|
7
17
|
"max_context_tokens": 20000,
|
|
@@ -37,11 +47,19 @@
|
|
|
37
47
|
"auto_consult_major_work": true,
|
|
38
48
|
"no_new_surface": true,
|
|
39
49
|
"auto_chain_delegations": true,
|
|
50
|
+
"plan_stale_hours": 8,
|
|
51
|
+
"plan_archive_marker_hours": 24,
|
|
40
52
|
"user_asides": {
|
|
41
53
|
"enabled": true,
|
|
42
54
|
"auto_provision_worktree": false
|
|
43
55
|
}
|
|
44
56
|
},
|
|
57
|
+
"grok_postprocessor_light": true,
|
|
58
|
+
"inference_session_capture": {
|
|
59
|
+
"enabled": true,
|
|
60
|
+
"min_commits": 3,
|
|
61
|
+
"lookback_commits": 20
|
|
62
|
+
},
|
|
45
63
|
"autonomous_reporting": {
|
|
46
64
|
"enabled": true,
|
|
47
65
|
"interval_minutes": 60,
|
|
@@ -140,10 +158,14 @@
|
|
|
140
158
|
"min_success_rate": 0.7
|
|
141
159
|
},
|
|
142
160
|
"memory_routing": {
|
|
143
|
-
"enabled":
|
|
144
|
-
"provider": "
|
|
145
|
-
"module_path": "",
|
|
146
|
-
"config": {
|
|
161
|
+
"enabled": true,
|
|
162
|
+
"provider": "repertoire",
|
|
163
|
+
"module_path": "node_modules/@0xray/repertoire/dist/provider/memory-routing-provider.js",
|
|
164
|
+
"config": {
|
|
165
|
+
"signalsPath": "node_modules/@0xray/repertoire/data/curated_signals.json",
|
|
166
|
+
"statePath": ".xray/state/repertoire/inference-state.json",
|
|
167
|
+
"feedbackDir": ".xray/state/repertoire/feedback"
|
|
168
|
+
}
|
|
147
169
|
},
|
|
148
170
|
"synthesis": {
|
|
149
171
|
"enabled": false,
|
|
@@ -84,6 +84,37 @@
|
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
+
"grok_postprocessor_light": {
|
|
88
|
+
"type": "boolean",
|
|
89
|
+
"description": "Opt-in lightweight postprocessor marker + activity.log on Grok write tools"
|
|
90
|
+
},
|
|
91
|
+
"inference_session_capture": {
|
|
92
|
+
"type": "object",
|
|
93
|
+
"description": "git post-commit → captureSessionInference when commit threshold is met",
|
|
94
|
+
"properties": {
|
|
95
|
+
"enabled": { "type": "boolean" },
|
|
96
|
+
"min_commits": { "type": "integer", "minimum": 1 },
|
|
97
|
+
"lookback_commits": { "type": "integer", "minimum": 1 }
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
"suit_temperament": {
|
|
101
|
+
"type": "object",
|
|
102
|
+
"description": "0xRay 4.0 — constitution always on; ceremony scales by host. Missing key = guided (existing consumers unchanged).",
|
|
103
|
+
"properties": {
|
|
104
|
+
"profile": {
|
|
105
|
+
"type": "string",
|
|
106
|
+
"enum": ["auto", "frontier", "guided", "strict"],
|
|
107
|
+
"description": "auto = host_defaults (grok→frontier, hermes/opencode/openclaw→guided)"
|
|
108
|
+
},
|
|
109
|
+
"host_defaults": {
|
|
110
|
+
"type": "object",
|
|
111
|
+
"additionalProperties": {
|
|
112
|
+
"type": "string",
|
|
113
|
+
"enum": ["frontier", "guided", "strict"]
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
},
|
|
87
118
|
"synthesis": {
|
|
88
119
|
"type": "object",
|
|
89
120
|
"properties": {
|