0xray 3.0.14 → 3.1.1

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 (296) hide show
  1. package/.gitignore.default +59 -0
  2. package/.mcp.json +35 -0
  3. package/.opencode/codex.codex +1 -1
  4. package/.opencode/commands/dependency-audit.md +3 -3
  5. package/.opencode/commands/summary-logger.md +4 -4
  6. package/.opencode/enforcer-config.json +2 -2
  7. package/.opencode/hooks/post-commit +1 -1
  8. package/.opencode/init.sh +10 -4
  9. package/.plugin/plugin.json +11 -0
  10. package/AGENTS-consumer.md +46 -0
  11. package/AGENTS.md +10 -10
  12. package/LICENSE +1 -1
  13. package/README.md +8 -8
  14. package/SKILLS.md +140 -0
  15. package/dist/.gitignore.default +59 -0
  16. package/dist/AGENTS.md +10 -10
  17. package/dist/CHANGELOG.md +34 -0
  18. package/dist/LICENSE +1 -1
  19. package/dist/README.md +8 -8
  20. package/dist/SKILLS.md +140 -0
  21. package/dist/agents/index.js +3 -1
  22. package/dist/agents/registry.js +13 -0
  23. package/dist/analytics/routing-refiner.js +1 -1
  24. package/dist/architect/architectural-integrity.js +3 -3
  25. package/dist/benchmark/performance-benchmark.js +4 -3
  26. package/dist/cli/commands/antigravity-status.js +23 -23
  27. package/dist/cli/commands/credible-init.js +1 -1
  28. package/dist/cli/commands/hermes-install.js +12 -4
  29. package/dist/cli/commands/mcp-install.js +1 -1
  30. package/dist/cli/commands/openclaw-install.js +10 -1
  31. package/dist/cli/commands/opencode-install.js +22 -0
  32. package/dist/cli/commands/plugin-commands.js +2 -2
  33. package/dist/cli/commands/publish-agent.js +5 -5
  34. package/dist/cli/commands/skill-install.js +39 -2
  35. package/dist/cli/commands/status.js +8 -3
  36. package/dist/cli/commands/storyteller.js +2 -2
  37. package/dist/cli/index.js +17 -11
  38. package/dist/cli/server.js +4 -4
  39. package/dist/core/activity-logger.js +4 -4
  40. package/dist/core/agent-spawn-gate.js +1 -1
  41. package/dist/core/boot-orchestrator.js +30 -31
  42. package/dist/core/bridge.mjs +26 -26
  43. package/dist/core/codex-formatter.js +2 -3
  44. package/dist/core/codex-injector.js +7 -7
  45. package/dist/core/config-loader.js +3 -2
  46. package/dist/core/config-paths.js +38 -31
  47. package/dist/core/context-loader.js +5 -5
  48. package/dist/core/features-config.js +1 -1
  49. package/dist/core/index.js +2 -2
  50. package/dist/core/logging-config.js +7 -7
  51. package/dist/core/orchestrator.js +2 -2
  52. package/dist/core/system-prompt-generator.js +2 -2
  53. package/dist/core/xray-activation.js +42 -41
  54. package/dist/delegation/agent-delegator.js +3 -3
  55. package/dist/enforcement/enforcer-tools.js +4 -4
  56. package/dist/enforcement/loaders/codex-loader.js +2 -2
  57. package/dist/execution/opencode-cli-invoker.js +1 -1
  58. package/dist/governance/governance-service.js +1 -1
  59. package/dist/governance/llm-governance-provider.js +223 -0
  60. package/dist/index.js +6 -6
  61. package/dist/inference/deploy-verifier.js +1 -1
  62. package/dist/inference/inference-cycle.js +16 -16
  63. package/dist/integrations/base/README.md +1 -1
  64. package/dist/integrations/enforcement-gate.js +2 -2
  65. package/dist/integrations/governance/index.js +1 -1
  66. package/dist/integrations/grok/grok-cli.js +20 -6
  67. package/dist/integrations/grok/hooks/pre-tool-use.js +3 -3
  68. package/dist/integrations/grok/plugin/0xray/.mcp.json +16 -4
  69. package/dist/integrations/grok/plugin/0xray/hooks/hooks.json +2 -2
  70. package/dist/integrations/hermes-agent/__init__.py +90 -79
  71. package/dist/integrations/hermes-agent/after-install.md +14 -14
  72. package/dist/integrations/hermes-agent/bridge.mjs +60 -25
  73. package/dist/integrations/hermes-agent/plugin.yaml +5 -5
  74. package/dist/integrations/hermes-agent/schemas.py +61 -12
  75. package/dist/integrations/hermes-agent/test_plugin.py +124 -124
  76. package/dist/integrations/hermes-agent/tools.py +129 -25
  77. package/dist/integrations/openclaw/README.md +6 -6
  78. package/dist/integrations/openclaw/config.js +1 -1
  79. package/dist/integrations/openclaw/index.js +2 -2
  80. package/dist/integrations/openclaw/types.js +3 -3
  81. package/dist/integrations/plugins/plugin-integration.js +1 -1
  82. package/dist/integrations/plugins/plugin-registry.js +3 -3
  83. package/dist/mcps/architect-tools.server.js +3 -2
  84. package/dist/mcps/auto-format.server.js +2 -2
  85. package/dist/mcps/boot-orchestrator.server.js +2 -2
  86. package/dist/mcps/config/config-loader.js +40 -9
  87. package/dist/mcps/config/server-config-registry.js +10 -10
  88. package/dist/mcps/connection/mcp-connection.js +1 -1
  89. package/dist/mcps/enforcer-tools.server.js +2 -2
  90. package/dist/mcps/estimation.server.js +3 -2
  91. package/dist/mcps/framework-compliance-audit.server.js +2 -2
  92. package/dist/mcps/framework-help.server.js +9 -8
  93. package/dist/mcps/governance.server.js +8 -4
  94. package/dist/mcps/knowledge-skills/api-design.server.js +3 -2
  95. package/dist/mcps/knowledge-skills/architecture-patterns.server.js +3 -2
  96. package/dist/mcps/knowledge-skills/bug-triage-specialist.server.js +3 -3
  97. package/dist/mcps/knowledge-skills/code-analyzer.server.js +2 -2
  98. package/dist/mcps/knowledge-skills/code-review.server.js +14 -39
  99. package/dist/mcps/knowledge-skills/content-creator.server.js +3 -3
  100. package/dist/mcps/knowledge-skills/database-design.server.js +2 -2
  101. package/dist/mcps/knowledge-skills/devops-deployment.server.js +3 -2
  102. package/dist/mcps/knowledge-skills/git-workflow.server.js +3 -2
  103. package/dist/mcps/knowledge-skills/growth-strategist.server.js +3 -3
  104. package/dist/mcps/knowledge-skills/log-monitor.server.js +3 -3
  105. package/dist/mcps/knowledge-skills/mobile-development.server.js +3 -3
  106. package/dist/mcps/knowledge-skills/multimodal-looker.server.js +3 -3
  107. package/dist/mcps/knowledge-skills/performance-optimization.server.js +2 -2
  108. package/dist/mcps/knowledge-skills/project-analysis.server.js +2 -2
  109. package/dist/mcps/knowledge-skills/refactoring-strategies.server.js +3 -2
  110. package/dist/mcps/knowledge-skills/security-audit.server.js +14 -44
  111. package/dist/mcps/knowledge-skills/seo-consultant.server.js +3 -2
  112. package/dist/mcps/knowledge-skills/session-management.server.js +3 -2
  113. package/dist/mcps/knowledge-skills/skill-invocation.server.js +105 -3
  114. package/dist/mcps/knowledge-skills/strategist.server.js +3 -3
  115. package/dist/mcps/knowledge-skills/tech-writer.server.js +3 -3
  116. package/dist/mcps/knowledge-skills/testing-best-practices.server.js +3 -2
  117. package/dist/mcps/knowledge-skills/testing-strategy.server.js +2 -2
  118. package/dist/mcps/knowledge-skills/ui-ux-design.server.js +5 -4
  119. package/dist/mcps/lint.server.js +4 -4
  120. package/dist/mcps/mcp-client.js +5 -5
  121. package/dist/mcps/model-health-check.server.js +3 -2
  122. package/dist/mcps/orchestrator/server.js +4 -3
  123. package/dist/mcps/orchestrator.server.js +2 -1
  124. package/dist/mcps/performance-analysis.server.js +2 -2
  125. package/dist/mcps/processor-pipeline.server.js +3 -2
  126. package/dist/mcps/registry.json +1 -1
  127. package/dist/mcps/researcher.server.js +14 -39
  128. package/dist/mcps/security-scan.server.js +2 -2
  129. package/dist/mcps/simulation/server-simulations.js +3 -3
  130. package/dist/mcps/state-manager.server.js +5 -5
  131. package/dist/metrics/agent-metrics.js +1 -1
  132. package/dist/orchestrator/enhanced-multi-agent-orchestrator.js +4 -4
  133. package/dist/orchestrator/intelligent-commit-batcher.js +2 -3
  134. package/dist/orchestrator/multi-agent-orchestration-coordinator.js +9 -9
  135. package/dist/orchestrator/orchestrator.js +9 -8
  136. package/dist/orchestrator/universal-registry-bridge.js +4 -4
  137. package/dist/postprocessor/PostProcessor.js +9 -9
  138. package/dist/postprocessor/services/RegressionAnalysisService.js +4 -4
  139. package/dist/postprocessor/triggers/GitHookTrigger.js +18 -18
  140. package/dist/processors/implementations/agents-md-validation-processor.js +2 -2
  141. package/dist/processors/implementations/inference-improvement-processor.js +1 -2
  142. package/dist/processors/implementations/log-protection-processor.js +2 -2
  143. package/dist/processors/implementations/publish-preflight-processor.js +2 -3
  144. package/dist/processors/implementations/regression-testing-processor.js +2 -2
  145. package/dist/processors/implementations/session-summary-processor.js +2 -2
  146. package/dist/processors/implementations/storytelling-trigger-processor.js +1 -2
  147. package/dist/public/about.html +6 -6
  148. package/dist/public/enterprise.html +1 -1
  149. package/dist/public/features.html +2 -2
  150. package/dist/public/index.html +4 -4
  151. package/dist/reporting/report-formatter.js +1 -1
  152. package/dist/scripts/activate-kernel-pipeline.js +4 -4
  153. package/dist/scripts/pre-command +1 -1
  154. package/dist/services/inference-tuner.js +2 -2
  155. package/dist/skills/api-design/SKILL.md +1 -1
  156. package/dist/skills/architect-tools/SKILL.md +1 -1
  157. package/dist/skills/architecture-patterns/SKILL.md +1 -1
  158. package/dist/skills/auto-format/SKILL.md +1 -1
  159. package/dist/skills/boot-orchestrator/SKILL.md +1 -1
  160. package/dist/skills/bug-triage/SKILL.md +1 -1
  161. package/dist/skills/code-analyzer/SKILL.md +1 -1
  162. package/dist/skills/code-review/SKILL.md +1 -1
  163. package/dist/skills/enforcer/SKILL.md +1 -1
  164. package/dist/skills/framework-compliance-audit/SKILL.md +1 -1
  165. package/dist/skills/git-workflow/SKILL.md +1 -1
  166. package/dist/skills/hermes-agent/SKILL.md +42 -42
  167. package/dist/skills/inference-improve/SKILL.md +1 -1
  168. package/dist/skills/lint/SKILL.md +1 -1
  169. package/dist/skills/log-monitor/SKILL.md +1 -1
  170. package/dist/skills/model-health-check/SKILL.md +1 -1
  171. package/dist/skills/multimodal-looker/SKILL.md +1 -1
  172. package/dist/skills/orchestrator/SKILL.md +1 -1
  173. package/dist/skills/performance-analysis/SKILL.md +1 -1
  174. package/dist/skills/performance-optimization/SKILL.md +1 -1
  175. package/dist/skills/processor-pipeline/SKILL.md +1 -1
  176. package/dist/skills/project-analysis/SKILL.md +1 -1
  177. package/dist/skills/refactoring-strategies/SKILL.md +1 -1
  178. package/dist/skills/registry.json +1 -1
  179. package/dist/skills/researcher/SKILL.md +1 -1
  180. package/dist/skills/security-audit/SKILL.md +1 -1
  181. package/dist/skills/security-scan/SKILL.md +1 -1
  182. package/dist/skills/session-management/SKILL.md +1 -1
  183. package/dist/skills/state-manager/SKILL.md +1 -1
  184. package/dist/skills/storyteller/SKILL.md +1 -1
  185. package/dist/skills/testing-best-practices/SKILL.md +1 -1
  186. package/dist/skills/testing-strategy/SKILL.md +1 -1
  187. package/dist/skills/ui-ux-design/SKILL.md +1 -1
  188. package/dist/state/index.js +1 -1
  189. package/dist/state/state-manager.js +3 -4
  190. package/dist/utils/import-resolver.js +1 -1
  191. package/dist/utils/path-resolver.js +2 -2
  192. package/dist/utils/token-manager.js +1 -1
  193. package/dist/validation/estimation-validator.js +1 -1
  194. package/package.json +10 -3
  195. package/scripts/hooks/pre-command +1 -1
  196. package/scripts/hooks/run-hook.js +2 -2
  197. package/scripts/node/auto-reflection-generator.mjs +30 -36
  198. package/scripts/node/govern-reflection.mjs +1 -1
  199. package/scripts/node/postinstall.cjs +37 -2
  200. package/scripts/node/pre-publish-guard.js +13 -9
  201. package/scripts/node/setup-xai-oauth.mjs +244 -0
  202. package/scripts/node/universal-version-manager.js +8 -8
  203. package/scripts/node/version-manager.mjs +1 -1
  204. package/src/integrations/grok/plugin/0xray/.mcp.json +16 -4
  205. package/src/integrations/grok/plugin/0xray/hooks/hooks.json +2 -2
  206. package/src/mcps/architect-tools.server.ts +2 -2
  207. package/src/mcps/auto-format.server.ts +2 -2
  208. package/src/mcps/boot-orchestrator.server.ts +2 -2
  209. package/src/mcps/config/__tests__/config-loader.test.ts +29 -33
  210. package/src/mcps/config/__tests__/server-config-registry.test.ts +12 -12
  211. package/src/mcps/config/config-loader.ts +50 -11
  212. package/src/mcps/config/server-config-registry.ts +10 -10
  213. package/src/mcps/connection/mcp-connection.ts +1 -1
  214. package/src/mcps/enforcer-tools.server.ts +2 -2
  215. package/src/mcps/estimation.server.ts +3 -2
  216. package/src/mcps/framework-compliance-audit.server.ts +2 -2
  217. package/src/mcps/framework-help.server.ts +9 -8
  218. package/src/mcps/governance.server.ts +8 -3
  219. package/src/mcps/knowledge-skills/api-design.server.ts +3 -2
  220. package/src/mcps/knowledge-skills/architecture-patterns.server.ts +2 -2
  221. package/src/mcps/knowledge-skills/bug-triage-specialist.server.ts +2 -2
  222. package/src/mcps/knowledge-skills/code-analyzer.server.ts +2 -2
  223. package/src/mcps/knowledge-skills/code-review.server.ts +21 -36
  224. package/src/mcps/knowledge-skills/content-creator.server.ts +3 -3
  225. package/src/mcps/knowledge-skills/database-design.server.ts +2 -2
  226. package/src/mcps/knowledge-skills/devops-deployment.server.ts +3 -2
  227. package/src/mcps/knowledge-skills/git-workflow.server.ts +3 -2
  228. package/src/mcps/knowledge-skills/growth-strategist.server.ts +3 -3
  229. package/src/mcps/knowledge-skills/log-monitor.server.ts +3 -3
  230. package/src/mcps/knowledge-skills/mobile-development.server.ts +3 -3
  231. package/src/mcps/knowledge-skills/multimodal-looker.server.ts +3 -3
  232. package/src/mcps/knowledge-skills/performance-optimization.server.ts +2 -2
  233. package/src/mcps/knowledge-skills/project-analysis.server.ts +2 -2
  234. package/src/mcps/knowledge-skills/refactoring-strategies.server.ts +3 -2
  235. package/src/mcps/knowledge-skills/security-audit.server.ts +21 -40
  236. package/src/mcps/knowledge-skills/seo-consultant.server.ts +3 -2
  237. package/src/mcps/knowledge-skills/session-management.server.ts +3 -2
  238. package/src/mcps/knowledge-skills/skill-invocation.server.ts +113 -3
  239. package/src/mcps/knowledge-skills/strategist.server.ts +3 -3
  240. package/src/mcps/knowledge-skills/tech-writer.server.ts +3 -3
  241. package/src/mcps/knowledge-skills/testing-best-practices.server.ts +3 -2
  242. package/src/mcps/knowledge-skills/testing-strategy.server.ts +2 -2
  243. package/src/mcps/knowledge-skills/ui-ux-design.server.ts +5 -4
  244. package/src/mcps/lint.server.ts +4 -4
  245. package/src/mcps/mcp-client.ts +5 -5
  246. package/src/mcps/model-health-check.server.ts +2 -2
  247. package/src/mcps/orchestrator/server.ts +4 -3
  248. package/src/mcps/orchestrator.server.ts +2 -1
  249. package/src/mcps/performance-analysis.server.ts +2 -2
  250. package/src/mcps/processor-pipeline.server.ts +3 -2
  251. package/src/mcps/registry.json +1 -1
  252. package/src/mcps/researcher.server.ts +21 -36
  253. package/src/mcps/security-scan.server.ts +2 -2
  254. package/src/mcps/simulation/server-simulations.ts +3 -3
  255. package/src/mcps/state-manager.server.ts +5 -5
  256. package/src/opencode/codex.codex +1 -1
  257. package/src/opencode/commands/dependency-audit.md +3 -3
  258. package/src/opencode/commands/summary-logger.md +4 -4
  259. package/src/opencode/enforcer-config.json +2 -2
  260. package/src/skills/api-design/SKILL.md +1 -1
  261. package/src/skills/architect-tools/SKILL.md +1 -1
  262. package/src/skills/architecture-patterns/SKILL.md +1 -1
  263. package/src/skills/auto-format/SKILL.md +1 -1
  264. package/src/skills/boot-orchestrator/SKILL.md +1 -1
  265. package/src/skills/bug-triage/SKILL.md +1 -1
  266. package/src/skills/code-analyzer/SKILL.md +1 -1
  267. package/src/skills/code-review/SKILL.md +1 -1
  268. package/src/skills/enforcer/SKILL.md +1 -1
  269. package/src/skills/framework-compliance-audit/SKILL.md +1 -1
  270. package/src/skills/git-workflow/SKILL.md +1 -1
  271. package/src/skills/hermes-agent/SKILL.md +42 -42
  272. package/src/skills/inference-improve/SKILL.md +1 -1
  273. package/src/skills/lint/SKILL.md +1 -1
  274. package/src/skills/log-monitor/SKILL.md +1 -1
  275. package/src/skills/model-health-check/SKILL.md +1 -1
  276. package/src/skills/multimodal-looker/SKILL.md +1 -1
  277. package/src/skills/orchestrator/SKILL.md +1 -1
  278. package/src/skills/performance-analysis/SKILL.md +1 -1
  279. package/src/skills/performance-optimization/SKILL.md +1 -1
  280. package/src/skills/processor-pipeline/SKILL.md +1 -1
  281. package/src/skills/project-analysis/SKILL.md +1 -1
  282. package/src/skills/refactoring-strategies/SKILL.md +1 -1
  283. package/src/skills/registry.json +1 -1
  284. package/src/skills/researcher/SKILL.md +1 -1
  285. package/src/skills/security-audit/SKILL.md +1 -1
  286. package/src/skills/security-scan/SKILL.md +1 -1
  287. package/src/skills/session-management/SKILL.md +1 -1
  288. package/src/skills/state-manager/SKILL.md +1 -1
  289. package/src/skills/storyteller/SKILL.md +1 -1
  290. package/src/skills/testing-best-practices/SKILL.md +1 -1
  291. package/src/skills/testing-strategy/SKILL.md +1 -1
  292. package/src/skills/ui-ux-design/SKILL.md +1 -1
  293. package/xray/agents_template.md +46 -0
  294. package/xray/codex.json +598 -0
  295. package/dist/plugin/xray-codex-injection.js +0 -857
  296. /package/dist/integrations/openclaw/hooks/{strray-hooks.js → xray-hooks.js} +0 -0
@@ -0,0 +1,223 @@
1
+ import { readFileSync, existsSync } from "node:fs";
2
+ import { homedir } from "node:os";
3
+ import { join } from "node:path";
4
+ import { frameworkLogger } from "../core/framework-logger.js";
5
+ const XAI_ENDPOINT = "https://api.x.ai/v1/chat/completions";
6
+ const XAI_MODEL = "grok-4.3";
7
+ const ROLE_PROMPTS = {
8
+ "code-review": `You are a senior code reviewer on a governance committee for a software project. Analyze the following proposal from a code quality, maintainability, readability, and engineering best practices perspective.
9
+
10
+ Consider:
11
+ - Does the proposal improve or degrade code quality?
12
+ - Does it follow established design patterns?
13
+ - Does it introduce technical debt?
14
+ - Are there potential regressions or edge cases?
15
+
16
+ Respond with a structured vote in exactly this format:
17
+ DECISION: approve|reject|abstain
18
+ CONFIDENCE: <0.0-1.0>
19
+ REASONING: <2-4 sentence analysis of the proposal's code quality implications>`,
20
+ "security-audit": `You are a senior security engineer on a governance committee for a software project. Analyze the following proposal from a security, threat modeling, and compliance perspective.
21
+
22
+ Consider:
23
+ - Does the proposal introduce new attack surface?
24
+ - Does it handle authentication, authorization, and data protection properly?
25
+ - Are there compliance implications (GDPR, SOC2, PCI-DSS, etc.)?
26
+ - Does it follow security best practices (input validation, least privilege, defense in depth)?
27
+
28
+ Respond with a structured vote in exactly this format:
29
+ DECISION: approve|reject|abstain
30
+ CONFIDENCE: <0.0-1.0>
31
+ REASONING: <2-4 sentence analysis of the proposal's security implications>`,
32
+ "researcher": `You are a senior architect and researcher on a governance committee for a software project. Analyze the following proposal from a codebase-wide architectural and historical perspective.
33
+
34
+ Consider:
35
+ - Does the proposal align with the project's observed architecture patterns?
36
+ - Does it integrate well with existing systems and data flows?
37
+ - Does it address recurring problems observed in the project history?
38
+ - What is the broader impact on the codebase ecosystem?
39
+
40
+ Respond with a structured vote in exactly this format:
41
+ DECISION: approve|reject|abstain
42
+ CONFIDENCE: <0.0-1.0>
43
+ REASONING: <2-4 sentence analysis of the proposal's broader project impact>`,
44
+ };
45
+ function readHermesOAuthToken() {
46
+ try {
47
+ const authPath = join(homedir(), ".hermes", "auth.json");
48
+ if (!existsSync(authPath))
49
+ return null;
50
+ const raw = readFileSync(authPath, "utf-8");
51
+ const data = JSON.parse(raw);
52
+ let entry;
53
+ if (data && typeof data === "object" && !Array.isArray(data)) {
54
+ entry = data["xai-oauth"];
55
+ if (!entry?.access_token && data.access_token) {
56
+ entry = data;
57
+ }
58
+ }
59
+ if (!entry?.access_token && Array.isArray(data)) {
60
+ entry = data.find((e) => e.provider === "xai-oauth" || !!e.access_token);
61
+ }
62
+ if (!entry?.access_token) {
63
+ process.stderr.write("[llm] readHermesOAuthToken: no access_token in auth file\n");
64
+ return null;
65
+ }
66
+ if (entry.expires_at && Date.now() / 1000 > entry.expires_at) {
67
+ frameworkLogger.log("llm-governance", "hermes-token-expired", "warning", { expiresAt: entry.expires_at });
68
+ return null;
69
+ }
70
+ return entry.access_token;
71
+ }
72
+ catch (err) {
73
+ frameworkLogger.log("llm-governance", "hermes-auth-read-error", "warning", { error: String(err) });
74
+ return null;
75
+ }
76
+ }
77
+ function getConfig() {
78
+ const directEndpoint = process.env.XRAY_LLM_ENDPOINT ||
79
+ process.env.XRAY_GOVERNANCE_LLM_ENDPOINT ||
80
+ "";
81
+ const directApiKey = process.env.XRAY_LLM_API_KEY ||
82
+ process.env.XRAY_GOVERNANCE_LLM_API_KEY ||
83
+ "";
84
+ const directModel = process.env.XRAY_LLM_MODEL ||
85
+ process.env.XRAY_GOVERNANCE_LLM_MODEL ||
86
+ "gpt-4o";
87
+ // First try: direct env-var config (highest priority)
88
+ const directEnabled = process.env.XRAY_GOVERNANCE_LLM_ENABLED === "true" ||
89
+ process.env.XRAY_LLM_ENABLED === "true";
90
+ if (directEnabled && directEndpoint && directApiKey) {
91
+ return { endpoint: directEndpoint, apiKey: directApiKey, model: directModel };
92
+ }
93
+ // Second try: Hermes xAI OAuth token from ~/.hermes/auth.json
94
+ const hermesToken = readHermesOAuthToken();
95
+ if (hermesToken) {
96
+ frameworkLogger.log("llm-governance", "using-hermes-oauth", "info", { provider: "xai-oauth", endpoint: XAI_ENDPOINT, model: XAI_MODEL });
97
+ return { endpoint: XAI_ENDPOINT, apiKey: hermesToken, model: XAI_MODEL };
98
+ }
99
+ // Third try: direct endpoint even without explicit enable flag (if endpoint+key set)
100
+ if (directEndpoint && directApiKey) {
101
+ return { endpoint: directEndpoint, apiKey: directApiKey, model: directModel };
102
+ }
103
+ if (process.env.DEBUG_LLM) {
104
+ process.stderr.write("[llm-debug] No config found. directEnabled=" + directEnabled + " endpoint=" + !!directEndpoint + " apiKey=" + !!directApiKey + " hermes=" + !!hermesToken + "\n");
105
+ }
106
+ return null;
107
+ }
108
+ function parseVote(text) {
109
+ const decisionMatch = text.match(/DECISION:\s*(approve|reject|abstain)/i);
110
+ const confidenceMatch = text.match(/CONFIDENCE:\s*([0-9.]+)/i);
111
+ const reasoningMatch = text.match(/REASONING:\s*(.+)/is);
112
+ if (!decisionMatch || !decisionMatch[1])
113
+ return null;
114
+ const rawConfidence = confidenceMatch?.[1];
115
+ const confidence = rawConfidence ? parseFloat(rawConfidence) : 0.5;
116
+ return {
117
+ decision: decisionMatch[1].toLowerCase(),
118
+ confidence: isNaN(confidence) ? 0.5 : Math.min(1, Math.max(0, confidence)),
119
+ reasoning: reasoningMatch?.[1]?.trim() || "No reasoning provided",
120
+ };
121
+ }
122
+ export async function tryLLMGovernance(role, proposalTitle, proposalDescription, evidence, proposalType) {
123
+ const config = getConfig();
124
+ if (!config) {
125
+ process.stderr.write("[llm] no config for role=" + role + "\n");
126
+ return null;
127
+ }
128
+ process.stderr.write("[llm] using config endpoint=" + config.endpoint + " model=" + config.model + "\n");
129
+ const systemPrompt = ROLE_PROMPTS[role];
130
+ const userMessage = `## Proposal
131
+
132
+ **Title:** ${proposalTitle}
133
+
134
+ **Description:** ${proposalDescription}
135
+
136
+ **Type:** ${proposalType}
137
+
138
+ ${evidence.length > 0 ? `**Supporting Evidence:**\n${evidence.map((e, i) => `${i + 1}. ${e}`).join("\n")}` : ""}
139
+
140
+ ---
141
+
142
+ Please provide your structured vote.`;
143
+ try {
144
+ const response = await fetch(config.endpoint, {
145
+ method: "POST",
146
+ headers: {
147
+ "Content-Type": "application/json",
148
+ Authorization: `Bearer ${config.apiKey}`,
149
+ },
150
+ body: JSON.stringify({
151
+ model: config.model,
152
+ messages: [
153
+ { role: "system", content: systemPrompt },
154
+ { role: "user", content: userMessage },
155
+ ],
156
+ temperature: 0.3,
157
+ max_tokens: 500,
158
+ }),
159
+ });
160
+ if (!response.ok) {
161
+ frameworkLogger.log("llm-governance", "api-call", "error", {
162
+ status: response.status,
163
+ statusText: response.statusText,
164
+ role,
165
+ });
166
+ return null;
167
+ }
168
+ const data = (await response.json());
169
+ const choices = data?.choices;
170
+ const message = choices?.[0]?.message;
171
+ const content = message?.content;
172
+ if (!content) {
173
+ frameworkLogger.log("llm-governance", "parse", "warning", {
174
+ issue: "missing content in response",
175
+ role,
176
+ });
177
+ return null;
178
+ }
179
+ const vote = parseVote(content);
180
+ if (!vote) {
181
+ frameworkLogger.log("llm-governance", "parse", "warning", {
182
+ issue: "unparseable response",
183
+ snippet: content.slice(0, 200),
184
+ role,
185
+ });
186
+ return null;
187
+ }
188
+ frameworkLogger.log("llm-governance", "vote", "success", {
189
+ role,
190
+ decision: vote.decision,
191
+ confidence: vote.confidence,
192
+ });
193
+ return vote;
194
+ }
195
+ catch (error) {
196
+ frameworkLogger.log("llm-governance", "error", "error", {
197
+ error: String(error),
198
+ role,
199
+ });
200
+ return null;
201
+ }
202
+ }
203
+ export function checkHermesOAuthStatus() {
204
+ const config = getConfig();
205
+ if (!config) {
206
+ const hermesPath = join(homedir(), ".hermes", "auth.json");
207
+ if (existsSync(hermesPath)) {
208
+ return {
209
+ configured: false,
210
+ error: "Hermes auth file found but no valid xai-oauth token. Run: hermes auth add xai-oauth --no-browser",
211
+ };
212
+ }
213
+ return {
214
+ configured: false,
215
+ error: "No Hermes auth file found (~/.hermes/auth.json). Install Hermes and run: hermes auth add xai-oauth --no-browser",
216
+ };
217
+ }
218
+ return {
219
+ configured: true,
220
+ endpoint: XAI_ENDPOINT,
221
+ model: XAI_MODEL,
222
+ };
223
+ }
package/dist/index.js CHANGED
@@ -4,17 +4,17 @@
4
4
  * This is the main entry point for the 0xRay framework.
5
5
  * It exports the core initialization function and key components.
6
6
  */
7
- export { StringRayOrchestrator } from "./orchestrator/orchestrator.js";
8
- export { StringRayStateManager } from "./state/index.js";
7
+ export { XrayOrchestrator } from "./orchestrator/orchestrator.js";
8
+ export { XrayStateManager } from "./state/index.js";
9
9
  export { AgentDelegator } from "./delegation/index.js";
10
10
  export { frameworkLogger } from "./core/framework-logger.js";
11
11
  export { BUILTIN_CODEX } from "./core/codex-formatter.js";
12
- import { defaultStringRayConfig } from "./core/index.js";
13
- export { defaultStringRayConfig };
12
+ import { defaultXrayConfig } from "./core/index.js";
13
+ export { defaultXrayConfig };
14
14
  export { OpenClawIntegration, initializeOpenClawIntegration, getOpenClawIntegration, shutdownOpenClawIntegration } from "./integrations/openclaw/index.js";
15
15
  // Main initialization function
16
- export function initializeStringRay(config = {}) {
17
- const mergedConfig = { ...defaultStringRayConfig, ...config };
16
+ export function initializeXray(config = {}) {
17
+ const mergedConfig = { ...defaultXrayConfig, ...config };
18
18
  // Return a standardized initialization result
19
19
  return {
20
20
  success: true,
@@ -43,7 +43,7 @@ export class DeployVerifier {
43
43
  if (!packCheck.passed) {
44
44
  return this.result(false, version, tarballPath, installDir, checks, startTime);
45
45
  }
46
- installDir = fs.mkdtempSync(path.join(os.tmpdir(), "strray-deploy-verify-"));
46
+ installDir = fs.mkdtempSync(path.join(os.tmpdir(), "xray-deploy-verify-"));
47
47
  const installCheck = this.runCheck("npm-install-fresh", () => {
48
48
  this.exec(`npm install ${tarballPath} --no-save`, installDir, 60000);
49
49
  return "Fresh install succeeded";
@@ -3,7 +3,7 @@ import * as path from "path";
3
3
  import { shouldTriggerCycle, accumulateCorpus } from "./inference-accumulator.js";
4
4
  import { DeployVerifier } from "./deploy-verifier.js";
5
5
  import { VotingCoordinator } from "../delegation/voting-coordinator.js";
6
- import { StringRayStateManager } from "../state/state-manager.js";
6
+ import { XrayStateManager } from "../state/state-manager.js";
7
7
  import { frameworkLogger } from "../core/framework-logger.js";
8
8
  import { getGovernanceIntegration } from "../integrations/governance/index.js";
9
9
  import { featuresConfigLoader } from "../core/features-config.js";
@@ -50,7 +50,7 @@ export class InferenceCycle {
50
50
  constructor(projectRoot, agentInvoker, options) {
51
51
  this.projectRoot = projectRoot || process.cwd();
52
52
  this.inferenceDir = path.join(this.projectRoot, "docs", "inference");
53
- this.stateDir = path.join(this.projectRoot, ".strray", "inference");
53
+ this.stateDir = path.join(this.projectRoot, ".xray", "inference");
54
54
  this.agentInvoker = agentInvoker ?? null;
55
55
  this.options = options ?? {};
56
56
  }
@@ -328,7 +328,7 @@ export class InferenceCycle {
328
328
  try {
329
329
  let agentName = p.type === "refactor" ? "refactorer" : "code-reviewer";
330
330
  // In pure MCP mode, use real skill server names so the orchestrator dispatches to actual MCP tools
331
- if (process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true') {
331
+ if (process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true') {
332
332
  agentName = p.type === "refactor" ? "refactoring-strategies" : "code-review";
333
333
  }
334
334
  await this.invokeAgentInternal(agentName, prompt);
@@ -353,11 +353,11 @@ export class InferenceCycle {
353
353
  ``,
354
354
  `1. Read the relevant source files`,
355
355
  `2. Add the missing guard, validation, or edge case handling`,
356
- `3. If this is a codex rule, add the term to .opencode/strray/codex.json`,
356
+ `3. If this is a codex rule, add the term to .xray/codex.json`,
357
357
  `4. Make minimal, surgical changes`,
358
358
  ].join("\n");
359
359
  try {
360
- const agentName = process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true'
360
+ const agentName = process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true'
361
361
  ? "code-review"
362
362
  : "code-reviewer";
363
363
  await this.invokeAgentInternal(agentName, prompt);
@@ -388,7 +388,7 @@ export class InferenceCycle {
388
388
  `3. Implement it if straightforward, otherwise describe the design`,
389
389
  ].join("\n");
390
390
  try {
391
- const agentName = process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true'
391
+ const agentName = process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true'
392
392
  ? "architecture-patterns"
393
393
  : "architect";
394
394
  await this.invokeAgentInternal(agentName, prompt);
@@ -455,7 +455,7 @@ Respond with EXACTLY one of:
455
455
  async governProposals(proposals) {
456
456
  // Primary path: Use the first-class Governance MCP (real skill servers + required Dynamo)
457
457
  // This is the clean, centralized path (governance.server.ts + GovernanceService)
458
- const useGovernanceMcp = process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true' ||
458
+ const useGovernanceMcp = process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true' ||
459
459
  this.isGovernanceMcpPreferred();
460
460
  if (useGovernanceMcp) {
461
461
  try {
@@ -488,7 +488,7 @@ Respond with EXACTLY one of:
488
488
  error: err instanceof Error ? err.message : String(err),
489
489
  });
490
490
  // In forced pure MCP mode we must not silently fall back
491
- if (process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true') {
491
+ if (process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true') {
492
492
  throw err;
493
493
  }
494
494
  // In normal mode, fall back to legacy path with deprecation warning.
@@ -552,7 +552,7 @@ Respond with EXACTLY one of:
552
552
  */
553
553
  async governProposalsInternal(proposals) {
554
554
  // Defensive: if pure MCP mode is forced, use individual skill servers only
555
- if (process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true') {
555
+ if (process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true') {
556
556
  return this.governProposalsWithIndividualSkills(proposals);
557
557
  }
558
558
  const coordinator = this.getCoordinator();
@@ -633,7 +633,7 @@ Respond with EXACTLY one of:
633
633
  }
634
634
  /**
635
635
  * Pure individual knowledge-skill MCP path for governance.
636
- * Used when STRRAY_FORCE_MCP_GOVERNANCE=true.
636
+ * Used when XRAY_FORCE_MCP_GOVERNANCE=true.
637
637
  * Each proposal is evaluated directly by the relevant skill servers using analyze_proposal.
638
638
  */
639
639
  async governProposalsWithIndividualSkills(proposals) {
@@ -801,7 +801,7 @@ Respond with EXACTLY one of:
801
801
  responseText = JSON.stringify(result);
802
802
  }
803
803
  // In pure MCP governance mode, trust the orchestrator response (it now does real work)
804
- const isPureMcp = process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true';
804
+ const isPureMcp = process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true';
805
805
  const hasRealContent = /PROPOSAL:\s*\d+/i.test(responseText) ||
806
806
  /DECISION:\s*(approve|reject|abstain)/i.test(responseText) ||
807
807
  /Agent Outputs \(real MCP responses\):/i.test(responseText);
@@ -830,7 +830,7 @@ Respond with EXACTLY one of:
830
830
  return this.agentInvoker(agentName, prompt);
831
831
  }
832
832
  // Only fall back to OpenCode if not in forced pure MCP mode
833
- if (process.env.STRRAY_FORCE_MCP_GOVERNANCE === 'true') {
833
+ if (process.env.XRAY_FORCE_MCP_GOVERNANCE === 'true') {
834
834
  throw new Error(`[PURE MCP] Orchestrator returned no usable response for agent "${agentName}" and OpenCode fallback is disabled`);
835
835
  }
836
836
  return this.invokeViaOpencode(agentName, prompt);
@@ -922,7 +922,7 @@ Respond with EXACTLY one of:
922
922
  fs.mkdirSync(this.stateDir, { recursive: true });
923
923
  }
924
924
  const stateFile = path.join(this.stateDir, "governance-state.json");
925
- const stateManager = new StringRayStateManager();
925
+ const stateManager = new XrayStateManager();
926
926
  if (fs.existsSync(stateFile)) {
927
927
  try {
928
928
  const data = JSON.parse(fs.readFileSync(stateFile, "utf-8"));
@@ -975,10 +975,10 @@ Respond with EXACTLY one of:
975
975
  return texts.join("\n").trim();
976
976
  }
977
977
  resolveOpencodeRoot() {
978
- // Use the provider-agnostic config path resolver (prefers .strray/, falls back to .opencode/strray/)
978
+ // Use the provider-agnostic config path resolver (prefers .xray/)
979
979
  const configDir = getConfigDir(this.projectRoot);
980
- // If we resolved to a .strray or custom dir, use its parent as the "root"
981
- if (configDir.includes(".strray") || configDir.includes("strray")) {
980
+ // If we resolved to a .xray or custom dir, use its parent as the "root"
981
+ if (configDir.includes(".xray") || configDir.includes("xray")) {
982
982
  return path.dirname(configDir);
983
983
  }
984
984
  // Legacy fallback
@@ -21,7 +21,7 @@ src/integrations/
21
21
  │ ├── ExampleIntegration.ts # Example implementation
22
22
  │ └── index.ts # Module exports
23
23
  ├── core/ # Core framework integrations
24
- │ └── strray-integration.ts # Cross-framework integration
24
+ │ └── xray-integration.ts # Cross-framework integration
25
25
  └── openclaw/ # External service integrations
26
26
  ├── index.ts
27
27
  ├── client.ts
@@ -48,7 +48,7 @@ async function loadV3PostProcessor() {
48
48
  if (global.xrayPostProcessor && typeof global.xrayPostProcessor.executePostProcessorLoop === "function") {
49
49
  return global.xrayPostProcessor;
50
50
  }
51
- // strRayPostProcessor fallback removed in v2.2
51
+ // xrayPostProcessor fallback removed in v2.2
52
52
  return null;
53
53
  }
54
54
  // ── Context Builder ────────────────────────────────────────────
@@ -302,7 +302,7 @@ async function loadStateManager() {
302
302
  const global = globalThis;
303
303
  if (global.xrayStateManager)
304
304
  return global.xrayStateManager;
305
- // strRayStateManager fallback removed in v2.2
305
+ // xrayStateManager fallback removed in v2.2
306
306
  const candidatePaths = [
307
307
  () => import("../state/state-manager.js"),
308
308
  () => import("../../node_modules/0xray/dist/state/state-manager.js"),
@@ -283,7 +283,7 @@ export class InferenceGovernanceIntegration extends BaseIntegration {
283
283
  */
284
284
  async loadConfig() {
285
285
  try {
286
- const configPath = path.join(process.cwd(), '.opencode', 'strray', 'features.json');
286
+ const configPath = path.join(process.cwd(), '.xray', 'features.json');
287
287
  if (!fs.existsSync(configPath)) {
288
288
  await this.log('warning', 'features.json not found, using defaults');
289
289
  return;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Grok CLI Integration for StringRay / 0xRay
2
+ * Grok CLI Integration for 0xRay
3
3
  *
4
4
  * This module provides the integration points for using 0xRay with the official Grok CLI.
5
5
  *
@@ -18,6 +18,7 @@ import { frameworkLogger } from '../../core/framework-logger.js';
18
18
  import fs from 'fs';
19
19
  import path from 'path';
20
20
  import { execSync } from 'child_process';
21
+ import { syncBuiltinSkills } from '../../cli/commands/skill-install.js';
21
22
  // ESM-compatible __dirname (this file is compiled to ESM)
22
23
  const __dirname = path.dirname(new URL(import.meta.url).pathname);
23
24
  export async function installForGrokCLI(options = {}) {
@@ -47,6 +48,13 @@ export async function installForGrokCLI(options = {}) {
47
48
  fs.cpSync(sourceDir, targetPluginDir, { recursive: true, force: true });
48
49
  frameworkLogger.log('grok-integration', 'plugin-copied', 'info', { destination: targetPluginDir });
49
50
  console.log(`\x1b[32m✓ Copied Grok plugin to ${targetPluginDir}\x1b[0m`);
51
+ // Sync builtin skills to Grok plugin skills dir
52
+ const grokSkillsDir = path.join(targetPluginDir, 'skills');
53
+ const skillsCopied = syncBuiltinSkills(grokSkillsDir);
54
+ if (skillsCopied > 0) {
55
+ console.log(`\x1b[32m✓ Synced ${skillsCopied} builtin skills to Grok plugin\x1b[0m`);
56
+ }
57
+ frameworkLogger.log('grok-integration', 'skills-synced', 'info', { count: skillsCopied });
50
58
  // Attempt auto-trust (best effort)
51
59
  try {
52
60
  execSync(`grok plugins trust "${targetPluginDir}"`, { stdio: 'ignore' });
@@ -59,15 +67,21 @@ export async function installForGrokCLI(options = {}) {
59
67
  // Register MCP servers via grok mcp add (most reliable mechanism)
60
68
  const govMcpPath = path.resolve(__dirname, '..', '..', '..', 'dist/mcps/governance.server.js');
61
69
  const skillsMcpPath = path.resolve(__dirname, '..', '..', '..', 'dist/mcps/knowledge-skills/skill-invocation.server.js');
70
+ const orchMcpPath = path.resolve(__dirname, '..', '..', '..', 'dist/mcps/orchestrator.server.js');
71
+ const enforcerMcpPath = path.resolve(__dirname, '..', '..', '..', 'dist/mcps/enforcer-tools.server.js');
62
72
  try {
63
- execSync(`grok mcp add strray-governance --command node --args "${govMcpPath}" --env "STRRAY_FORCE_MCP_GOVERNANCE=true" --env "STRRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
64
- execSync(`grok mcp add strray-skills --command node --args "${skillsMcpPath}" --env "STRRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
65
- console.log('\x1b[32m✓ Registered strray MCP servers with Grok CLI\x1b[0m');
73
+ execSync(`grok mcp add xray-governance --command node --args "${govMcpPath}" --env "XRAY_FORCE_MCP_GOVERNANCE=true" --env "XRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
74
+ execSync(`grok mcp add xray-skills --command node --args "${skillsMcpPath}" --env "XRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
75
+ execSync(`grok mcp add xray-orchestrator --command node --args "${orchMcpPath}" --env "XRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
76
+ execSync(`grok mcp add xray-enforcer --command node --args "${enforcerMcpPath}" --env "XRAY_ROOT=${process.cwd()}"`, { stdio: 'pipe' });
77
+ console.log('\x1b[32m✓ Registered xray MCP servers with Grok CLI\x1b[0m');
66
78
  }
67
79
  catch {
68
80
  console.log('\nCould not auto-register MCP servers. Run manually:');
69
- console.log(` grok mcp add strray-governance --command node --args "${govMcpPath}"`);
70
- console.log(` grok mcp add strray-skills --command node --args "${skillsMcpPath}"`);
81
+ console.log(` grok mcp add xray-governance --command node --args "${govMcpPath}"`);
82
+ console.log(` grok mcp add xray-skills --command node --args "${skillsMcpPath}"`);
83
+ console.log(` grok mcp add xray-orchestrator --command node --args "${orchMcpPath}"`);
84
+ console.log(` grok mcp add xray-enforcer --command node --args "${enforcerMcpPath}"`);
71
85
  }
72
86
  console.log('\n✅ 0xRay is now installed as a first-class Grok CLI plugin!');
73
87
  console.log('Restart Grok or run `grok` to load the new hooks and MCP servers.');
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  /**
3
- * Grok CLI PreToolUse Hook Handler for StringRay (0xRay) — First Class Citizen
3
+ * Grok CLI PreToolUse Hook Handler for 0xRay — First Class Citizen
4
4
  *
5
5
  * Real governance enforcement hook.
6
6
  * When Grok is about to execute a tool (write_file, edit, terminal cmd, etc.),
@@ -16,7 +16,7 @@ function findGovernanceCore() {
16
16
  const here = path.dirname(new URL(import.meta.url).pathname);
17
17
 
18
18
  // Priority: explicit dev root
19
- const devRoot = process.env.STRRAY_ROOT;
19
+ const devRoot = process.env.XRAY_ROOT;
20
20
  if (devRoot) {
21
21
  const devCandidate = path.resolve(devRoot, 'dist/governance/governance-core.js');
22
22
  if (fs.existsSync(devCandidate)) return devCandidate;
@@ -49,7 +49,7 @@ function walkUpForCore(startDir, maxLevels = 8) {
49
49
  if (fs.existsSync(pkgPath)) {
50
50
  try {
51
51
  const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf8'));
52
- if (pkg.name === 'strray-ai' || pkg.name === 'stringray' || pkg.name === '0xray') {
52
+ if (pkg.name === '0xray') {
53
53
  results.push(path.resolve(current, 'dist/governance/governance-core.js'));
54
54
  results.push(path.resolve(current, 'governance/governance-core.js'));
55
55
  }
@@ -1,23 +1,35 @@
1
1
  {
2
2
  "mcpServers": {
3
- "0xray-governance": {
3
+ "xray-governance": {
4
4
  "command": "npx",
5
5
  "args": ["-y", "0xray", "mcp", "governance"],
6
6
  "env": {
7
7
  "XRAY_FORCE_MCP_GOVERNANCE": "true"
8
8
  }
9
9
  },
10
- "0xray-skills": {
10
+ "xray-skills": {
11
11
  "command": "npx",
12
12
  "args": ["-y", "0xray", "mcp", "skills"]
13
13
  },
14
- "0xray-orchestrator": {
14
+ "xray-orchestrator": {
15
15
  "command": "npx",
16
16
  "args": ["-y", "0xray", "mcp", "orchestrator"]
17
17
  },
18
- "0xray-enforcer": {
18
+ "xray-enforcer": {
19
19
  "command": "npx",
20
20
  "args": ["-y", "0xray", "mcp", "enforcer"]
21
+ },
22
+ "xray-researcher": {
23
+ "command": "npx",
24
+ "args": ["-y", "0xray", "mcp", "researcher"]
25
+ },
26
+ "xray-code-review": {
27
+ "command": "npx",
28
+ "args": ["-y", "0xray", "mcp", "code-review"]
29
+ },
30
+ "xray-architect-tools": {
31
+ "command": "npx",
32
+ "args": ["-y", "0xray", "mcp", "architect-tools"]
21
33
  }
22
34
  }
23
35
  }
@@ -8,7 +8,7 @@
8
8
  "type": "command",
9
9
  "command": "node",
10
10
  "args": [
11
- "${STRRAY_AI_PATH:-node_modules/0xray}/dist/integrations/grok/hooks/pre-tool-use.js"
11
+ "${XRAY_AI_PATH:-node_modules/0xray}/dist/integrations/grok/hooks/pre-tool-use.js"
12
12
  ],
13
13
  "timeout": 30000
14
14
  }
@@ -21,7 +21,7 @@
21
21
  {
22
22
  "type": "command",
23
23
  "command": "echo",
24
- "args": ["[0xRay] Grok session started with StringRay governance enabled"]
24
+ "args": ["[0xRay] Grok session started with 0xRay governance enabled"]
25
25
  }
26
26
  ]
27
27
  }