0xray 2.0.1 → 2.1.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.
Files changed (240) hide show
  1. package/.opencode/codex.codex +1 -1
  2. package/AGENTS.md +1 -1
  3. package/dist/AGENTS.md +1 -1
  4. package/dist/benchmark/performance-benchmark.d.ts +2 -2
  5. package/dist/benchmark/performance-benchmark.js +3 -3
  6. package/dist/cli/commands/hermes-install.js +4 -4
  7. package/dist/cli/commands/mcp-install.js +1 -1
  8. package/dist/cli/commands/openclaw-install.js +1 -1
  9. package/dist/cli/commands/plugin-commands.js +2 -2
  10. package/dist/cli/commands/publish-agent.js +5 -5
  11. package/dist/cli/commands/skill-install.js +1 -1
  12. package/dist/cli/commands/status.js +3 -3
  13. package/dist/cli/commands/storyteller.js +2 -2
  14. package/dist/cli/index.js +8 -8
  15. package/dist/cli/server.js +1 -1
  16. package/dist/core/agent-spawn-gate.d.ts +1 -1
  17. package/dist/core/agent-spawn-gate.js +1 -1
  18. package/dist/core/boot-orchestrator.d.ts +4 -4
  19. package/dist/core/boot-orchestrator.js +26 -26
  20. package/dist/core/bridge.mjs +22 -22
  21. package/dist/core/codex-formatter.js +2 -2
  22. package/dist/core/codex-injector.d.ts +4 -3
  23. package/dist/core/codex-injector.js +11 -10
  24. package/dist/core/config-loader.d.ts +5 -4
  25. package/dist/core/config-loader.js +4 -2
  26. package/dist/core/config-paths.d.ts +9 -8
  27. package/dist/core/config-paths.js +24 -23
  28. package/dist/core/context-loader.d.ts +4 -3
  29. package/dist/core/context-loader.js +7 -5
  30. package/dist/core/index.d.ts +1 -1
  31. package/dist/core/index.js +1 -1
  32. package/dist/core/orchestrator.d.ts +1 -0
  33. package/dist/core/orchestrator.js +3 -2
  34. package/dist/core/system-prompt-generator.js +2 -2
  35. package/dist/core/xray-activation.d.ts +4 -4
  36. package/dist/core/xray-activation.js +29 -24
  37. package/dist/delegation/agent-delegator.d.ts +3 -3
  38. package/dist/delegation/agent-delegator.js +3 -3
  39. package/dist/delegation/metrics-aggregator.d.ts +11 -11
  40. package/dist/delegation/session-coordinator.d.ts +3 -3
  41. package/dist/delegation/voting-coordinator.d.ts +3 -3
  42. package/dist/enforcement/enforcer-tools.js +2 -2
  43. package/dist/enforcement/loaders/codex-loader.d.ts +1 -1
  44. package/dist/enforcement/loaders/codex-loader.js +2 -2
  45. package/dist/index.d.ts +5 -5
  46. package/dist/index.js +6 -6
  47. package/dist/inference/deploy-verifier.js +1 -1
  48. package/dist/inference/inference-cycle.js +7 -7
  49. package/dist/integrations/base/README.md +2 -2
  50. package/dist/integrations/governance/index.js +1 -1
  51. package/dist/integrations/grok/grok-cli.d.ts +1 -1
  52. package/dist/integrations/grok/grok-cli.js +6 -6
  53. package/dist/integrations/grok/hooks/pre-tool-use.js +1 -1
  54. package/dist/integrations/grok/plugin/0xray/.mcp.json +3 -3
  55. package/dist/integrations/grok/plugin/0xray/hooks/hooks.json +2 -2
  56. package/dist/integrations/hermes-agent/__init__.py +77 -71
  57. package/dist/integrations/hermes-agent/__pycache__/__init__.cpython-313.pyc +0 -0
  58. package/dist/integrations/hermes-agent/__pycache__/conftest.cpython-313-pytest-9.0.2.pyc +0 -0
  59. package/dist/integrations/hermes-agent/__pycache__/schemas.cpython-313.pyc +0 -0
  60. package/dist/integrations/hermes-agent/__pycache__/test_plugin.cpython-313-pytest-9.0.2.pyc +0 -0
  61. package/dist/integrations/hermes-agent/__pycache__/test_plugin.cpython-313.pyc +0 -0
  62. package/dist/integrations/hermes-agent/__pycache__/tools.cpython-313.pyc +0 -0
  63. package/dist/integrations/hermes-agent/after-install.md +14 -14
  64. package/dist/integrations/hermes-agent/bridge.mjs +14 -14
  65. package/dist/integrations/hermes-agent/logs/framework/routing-outcomes.json +1 -0
  66. package/dist/integrations/hermes-agent/plugin.yaml +5 -5
  67. package/dist/integrations/hermes-agent/schemas.py +12 -12
  68. package/dist/integrations/hermes-agent/test_plugin.py +128 -125
  69. package/dist/integrations/hermes-agent/tools.py +85 -23
  70. package/dist/integrations/openclaw/README.md +16 -16
  71. package/dist/integrations/openclaw/api-server.d.ts +4 -4
  72. package/dist/integrations/openclaw/api-server.js +9 -9
  73. package/dist/integrations/openclaw/config.js +1 -1
  74. package/dist/integrations/openclaw/hooks/{strray-hooks.d.ts → xray-hooks.d.ts} +4 -4
  75. package/dist/integrations/openclaw/index.d.ts +4 -4
  76. package/dist/integrations/openclaw/index.js +4 -4
  77. package/dist/integrations/openclaw/types.d.ts +1 -1
  78. package/dist/integrations/plugins/plugin-registry.js +2 -2
  79. package/dist/mcps/architect-tools.server.d.ts +2 -2
  80. package/dist/mcps/architect-tools.server.js +3 -3
  81. package/dist/mcps/auto-format.server.d.ts +2 -2
  82. package/dist/mcps/auto-format.server.js +3 -3
  83. package/dist/mcps/boot-orchestrator.server.d.ts +2 -2
  84. package/dist/mcps/boot-orchestrator.server.js +3 -3
  85. package/dist/mcps/config/server-config-registry.d.ts +1 -1
  86. package/dist/mcps/config/server-config-registry.js +7 -7
  87. package/dist/mcps/connection/mcp-connection.js +1 -1
  88. package/dist/mcps/enforcer-tools.server.d.ts +2 -2
  89. package/dist/mcps/enforcer-tools.server.js +3 -3
  90. package/dist/mcps/framework-compliance-audit.server.d.ts +2 -2
  91. package/dist/mcps/framework-compliance-audit.server.js +3 -3
  92. package/dist/mcps/framework-help.server.js +6 -6
  93. package/dist/mcps/in-process-skill-registry.js +6 -6
  94. package/dist/mcps/knowledge-skills/api-design.server.d.ts +2 -2
  95. package/dist/mcps/knowledge-skills/api-design.server.js +3 -3
  96. package/dist/mcps/knowledge-skills/architecture-patterns.server.d.ts +2 -2
  97. package/dist/mcps/knowledge-skills/architecture-patterns.server.js +3 -3
  98. package/dist/mcps/knowledge-skills/code-review.server.d.ts +2 -2
  99. package/dist/mcps/knowledge-skills/code-review.server.js +3 -3
  100. package/dist/mcps/knowledge-skills/database-design.server.d.ts +2 -2
  101. package/dist/mcps/knowledge-skills/database-design.server.js +3 -3
  102. package/dist/mcps/knowledge-skills/devops-deployment.server.d.ts +2 -2
  103. package/dist/mcps/knowledge-skills/devops-deployment.server.js +3 -3
  104. package/dist/mcps/knowledge-skills/git-workflow.server.d.ts +2 -2
  105. package/dist/mcps/knowledge-skills/git-workflow.server.js +3 -3
  106. package/dist/mcps/knowledge-skills/mobile-development.server.d.ts +2 -2
  107. package/dist/mcps/knowledge-skills/mobile-development.server.js +3 -3
  108. package/dist/mcps/knowledge-skills/performance-optimization.server.d.ts +2 -2
  109. package/dist/mcps/knowledge-skills/performance-optimization.server.js +3 -3
  110. package/dist/mcps/knowledge-skills/refactoring-strategies.server.d.ts +2 -2
  111. package/dist/mcps/knowledge-skills/refactoring-strategies.server.js +3 -3
  112. package/dist/mcps/knowledge-skills/security-audit.server.d.ts +2 -2
  113. package/dist/mcps/knowledge-skills/security-audit.server.js +3 -3
  114. package/dist/mcps/knowledge-skills/tech-writer.server.d.ts +2 -2
  115. package/dist/mcps/knowledge-skills/tech-writer.server.js +3 -3
  116. package/dist/mcps/knowledge-skills/testing-best-practices.server.d.ts +2 -2
  117. package/dist/mcps/knowledge-skills/testing-best-practices.server.js +3 -3
  118. package/dist/mcps/knowledge-skills/testing-strategy.server.d.ts +2 -2
  119. package/dist/mcps/knowledge-skills/testing-strategy.server.js +3 -3
  120. package/dist/mcps/knowledge-skills/ui-ux-design.server.d.ts +2 -2
  121. package/dist/mcps/knowledge-skills/ui-ux-design.server.js +5 -5
  122. package/dist/mcps/lint.server.d.ts +2 -2
  123. package/dist/mcps/lint.server.js +5 -5
  124. package/dist/mcps/mcp-client.js +3 -3
  125. package/dist/mcps/model-health-check.server.d.ts +2 -2
  126. package/dist/mcps/model-health-check.server.js +3 -3
  127. package/dist/mcps/orchestrator/server.js +2 -2
  128. package/dist/mcps/performance-analysis.server.d.ts +2 -2
  129. package/dist/mcps/performance-analysis.server.js +3 -3
  130. package/dist/mcps/processor-pipeline.server.d.ts +2 -2
  131. package/dist/mcps/processor-pipeline.server.js +3 -3
  132. package/dist/mcps/researcher.server.d.ts +3 -3
  133. package/dist/mcps/researcher.server.js +4 -4
  134. package/dist/mcps/security-scan.server.d.ts +2 -2
  135. package/dist/mcps/security-scan.server.js +3 -3
  136. package/dist/mcps/simulation/server-simulations.js +3 -3
  137. package/dist/metrics/agent-metrics.d.ts +4 -4
  138. package/dist/metrics/agent-metrics.js +1 -1
  139. package/dist/orchestrator/enhanced-multi-agent-orchestrator.d.ts +2 -2
  140. package/dist/orchestrator/enhanced-multi-agent-orchestrator.js +2 -2
  141. package/dist/orchestrator/intelligent-commit-batcher.d.ts +1 -1
  142. package/dist/orchestrator/intelligent-commit-batcher.js +3 -3
  143. package/dist/orchestrator/multi-agent-orchestration-coordinator.d.ts +3 -3
  144. package/dist/orchestrator/multi-agent-orchestration-coordinator.js +9 -9
  145. package/dist/orchestrator/orchestrator.d.ts +3 -2
  146. package/dist/orchestrator/orchestrator.js +8 -6
  147. package/dist/plugin/xray-codex-injection.d.ts +1 -1
  148. package/dist/plugin/xray-codex-injection.js +8 -7
  149. package/dist/postprocessor/PostProcessor.d.ts +2 -2
  150. package/dist/postprocessor/PostProcessor.js +1 -1
  151. package/dist/postprocessor/monitoring/MonitoringEngine.d.ts +2 -2
  152. package/dist/postprocessor/services/RegressionAnalysisService.js +2 -2
  153. package/dist/postprocessor/triggers/GitHookTrigger.js +14 -14
  154. package/dist/processors/implementations/agents-md-validation-processor.js +2 -2
  155. package/dist/processors/implementations/inference-improvement-processor.js +2 -2
  156. package/dist/processors/implementations/log-protection-processor.d.ts +1 -1
  157. package/dist/processors/implementations/log-protection-processor.js +2 -2
  158. package/dist/processors/implementations/publish-preflight-processor.d.ts +1 -1
  159. package/dist/processors/implementations/publish-preflight-processor.js +3 -3
  160. package/dist/processors/implementations/regression-testing-processor.js +2 -2
  161. package/dist/processors/implementations/session-summary-processor.js +2 -2
  162. package/dist/processors/implementations/storytelling-trigger-processor.js +2 -2
  163. package/dist/processors/processor-manager.d.ts +2 -2
  164. package/dist/public/about.html +6 -6
  165. package/dist/public/enterprise.html +1 -1
  166. package/dist/public/features.html +2 -2
  167. package/dist/public/index.html +4 -4
  168. package/dist/reporting/report-formatter.js +1 -1
  169. package/dist/scripts/activate-kernel-pipeline.js +2 -2
  170. package/dist/scripts/pre-command +1 -1
  171. package/dist/services/inference-tuner.js +2 -2
  172. package/dist/session/session-cleanup-manager.d.ts +3 -3
  173. package/dist/session/session-monitor.d.ts +3 -3
  174. package/dist/session/session-state-manager.d.ts +3 -3
  175. package/dist/skills/hermes-agent/SKILL.md +11 -11
  176. package/dist/skills/storyteller/SKILL.md +1 -1
  177. package/dist/skills/xray-orchestrator/SKILL.md +141 -0
  178. package/dist/skills/xray-orchestrator/index.d.ts +13 -0
  179. package/dist/skills/xray-orchestrator/index.js +224 -0
  180. package/dist/state/index.d.ts +2 -1
  181. package/dist/state/index.js +2 -1
  182. package/dist/state/state-manager.d.ts +2 -2
  183. package/dist/state/state-manager.js +5 -4
  184. package/dist/utils/import-resolver.js +1 -1
  185. package/dist/utils/path-resolver.js +2 -2
  186. package/dist/utils/token-manager.js +1 -1
  187. package/dist/validation/estimation-validator.js +1 -1
  188. package/package.json +2 -2
  189. package/scripts/hooks/pre-command +1 -1
  190. package/scripts/hooks/run-hook.js +2 -2
  191. package/scripts/node/auto-reflection-generator.mjs +2 -2
  192. package/scripts/node/postinstall.cjs +1 -1
  193. package/scripts/node/release.js +6 -6
  194. package/scripts/node/release.mjs +10 -10
  195. package/scripts/node/version-manager.mjs +1 -1
  196. package/src/integrations/grok/plugin/0xray/.mcp.json +3 -3
  197. package/src/integrations/grok/plugin/0xray/hooks/hooks.json +2 -2
  198. package/src/mcps/architect-tools.server.ts +3 -3
  199. package/src/mcps/auto-format.server.ts +3 -3
  200. package/src/mcps/boot-orchestrator.server.ts +3 -3
  201. package/src/mcps/config/server-config-registry.ts +7 -7
  202. package/src/mcps/connection/mcp-connection.ts +1 -1
  203. package/src/mcps/enforcer-tools.server.ts +3 -3
  204. package/src/mcps/framework-compliance-audit.server.ts +3 -3
  205. package/src/mcps/framework-help.server.ts +6 -6
  206. package/src/mcps/in-process-skill-registry.ts +6 -6
  207. package/src/mcps/knowledge-skills/api-design.server.test.ts +8 -8
  208. package/src/mcps/knowledge-skills/api-design.server.ts +3 -3
  209. package/src/mcps/knowledge-skills/architecture-patterns.server.ts +3 -3
  210. package/src/mcps/knowledge-skills/code-review.server.ts +3 -3
  211. package/src/mcps/knowledge-skills/database-design.server.ts +3 -3
  212. package/src/mcps/knowledge-skills/devops-deployment.server.ts +3 -3
  213. package/src/mcps/knowledge-skills/git-workflow.server.ts +3 -3
  214. package/src/mcps/knowledge-skills/mobile-development.server.ts +3 -3
  215. package/src/mcps/knowledge-skills/performance-optimization.server.ts +3 -3
  216. package/src/mcps/knowledge-skills/refactoring-strategies.server.ts +3 -3
  217. package/src/mcps/knowledge-skills/security-audit.server.test.ts +23 -23
  218. package/src/mcps/knowledge-skills/security-audit.server.ts +3 -3
  219. package/src/mcps/knowledge-skills/tech-writer.server.ts +3 -3
  220. package/src/mcps/knowledge-skills/testing-best-practices.server.test.ts +28 -28
  221. package/src/mcps/knowledge-skills/testing-best-practices.server.ts +3 -3
  222. package/src/mcps/knowledge-skills/testing-strategy.server.test.ts +19 -19
  223. package/src/mcps/knowledge-skills/testing-strategy.server.ts +3 -3
  224. package/src/mcps/knowledge-skills/ui-ux-design.server.ts +5 -5
  225. package/src/mcps/lint.server.ts +5 -5
  226. package/src/mcps/mcp-client.ts +3 -3
  227. package/src/mcps/model-health-check.server.ts +3 -3
  228. package/src/mcps/orchestrator/server.ts +2 -2
  229. package/src/mcps/performance-analysis.server.ts +3 -3
  230. package/src/mcps/processor-pipeline.server.ts +3 -3
  231. package/src/mcps/researcher.server.ts +4 -4
  232. package/src/mcps/security-scan.server.ts +3 -3
  233. package/src/mcps/simulation/server-simulations.ts +3 -3
  234. package/src/opencode/codex.codex +1 -1
  235. package/src/skills/hermes-agent/SKILL.md +11 -11
  236. package/src/skills/storyteller/SKILL.md +1 -1
  237. package/src/skills/xray-orchestrator/SKILL.md +141 -0
  238. package/src/skills/xray-orchestrator/index.ts +268 -0
  239. package/scripts/validate-stringray-comprehensive.js +0 -636
  240. /package/dist/integrations/openclaw/hooks/{strray-hooks.js → xray-hooks.js} +0 -0
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "2.0.0",
2
+ "version": "2.1.0",
3
3
  "terms": [
4
4
  1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68
5
5
  ],
package/AGENTS.md CHANGED
@@ -86,7 +86,7 @@ xray enforces the Universal Development Codex (60 terms) via Dynamo governance.
86
86
 
87
87
  Pure v16 MCPs. Clean. Complete.
88
88
 
89
- ## Session: v2.0.0 Release Polish
89
+ ## Session: v2.1.0 Release Polish
90
90
 
91
91
  - Package: `0xray` (npm), `github.com/0xRayAI/xray`. Version `2.0.0`.
92
92
  - Renamed `strray-ai` → `0xray` across 60+ source files, CLI help text, grok plugin, hermes-agent bridge (Python + JS), docusaurus config.
package/dist/AGENTS.md CHANGED
@@ -86,7 +86,7 @@ xray enforces the Universal Development Codex (60 terms) via Dynamo governance.
86
86
 
87
87
  Pure v16 MCPs. Clean. Complete.
88
88
 
89
- ## Session: v2.0.0 Release Polish
89
+ ## Session: v2.1.0 Release Polish
90
90
 
91
91
  - Package: `0xray` (npm), `github.com/0xRayAI/xray`. Version `2.0.0`.
92
92
  - Renamed `strray-ai` → `0xray` across 60+ source files, CLI help text, grok plugin, hermes-agent bridge (Python + JS), docusaurus config.
@@ -54,7 +54,7 @@ export interface SessionBenchmarkResult {
54
54
  failoverTimes: number[];
55
55
  concurrentSessionOperations: number;
56
56
  }
57
- export declare class StringRayPerformanceBenchmark {
57
+ export declare class XrayPerformanceBenchmark {
58
58
  private results;
59
59
  private activeBenchmarks;
60
60
  /**
@@ -100,4 +100,4 @@ export declare class StringRayPerformanceBenchmark {
100
100
  */
101
101
  exportResults(): BenchmarkResult[];
102
102
  }
103
- export declare const performanceBenchmark: StringRayPerformanceBenchmark;
103
+ export declare const performanceBenchmark: XrayPerformanceBenchmark;
@@ -1,7 +1,7 @@
1
- // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .strray fallbacks)
1
+ // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .xray fallbacks)
2
2
  import { frameworkLogger } from "../core/framework-logger.js";
3
3
  import crypto from "crypto";
4
- export class StringRayPerformanceBenchmark {
4
+ export class XrayPerformanceBenchmark {
5
5
  results = [];
6
6
  activeBenchmarks = new Map();
7
7
  /**
@@ -369,4 +369,4 @@ export class StringRayPerformanceBenchmark {
369
369
  }
370
370
  }
371
371
  // Export singleton instance
372
- export const performanceBenchmark = new StringRayPerformanceBenchmark();
372
+ export const performanceBenchmark = new XrayPerformanceBenchmark();
@@ -16,14 +16,14 @@ export function registerHermesCommands(hermesCmd) {
16
16
  async function installForHermes(options = {}) {
17
17
  frameworkLogger.log('hermes-integration', 'install-start', 'info', { options });
18
18
  const home = homedir();
19
- const targetPluginDir = path.join(home, '.hermes/plugins/strray-hermes');
19
+ const targetPluginDir = path.join(home, '.hermes/plugins/xray-hermes');
20
20
  const possibleSources = [
21
21
  path.join(__dirname, '..', '..', '..', 'dist/integrations/hermes-agent'),
22
22
  path.join(__dirname, '..', '..', '..', 'src/integrations/hermes-agent'),
23
23
  ];
24
24
  let sourceDir = possibleSources.find(p => fs.existsSync(p));
25
25
  if (!sourceDir) {
26
- console.error('[Hermes] Could not locate the strray-hermes plugin inside the package.');
26
+ console.error('[Hermes] Could not locate the xray-hermes plugin inside the package.');
27
27
  return;
28
28
  }
29
29
  if (options.dryRun) {
@@ -32,7 +32,7 @@ async function installForHermes(options = {}) {
32
32
  }
33
33
  try {
34
34
  if (fs.existsSync(targetPluginDir) && !options.force) {
35
- console.log('[Hermes] strray-hermes plugin is already installed.');
35
+ console.log('[Hermes] xray-hermes plugin is already installed.');
36
36
  console.log('Use --force to reinstall.');
37
37
  return;
38
38
  }
@@ -56,7 +56,7 @@ async function installForHermes(options = {}) {
56
56
  }
57
57
  console.log('\n✅ 0xRay is now installed as a Hermes Agent plugin!');
58
58
  console.log('Restart Hermes to load the plugin and its tools.');
59
- console.log(' Run: /strray status (to verify)');
59
+ console.log(' Run: npx 0xray status (to verify)');
60
60
  }
61
61
  catch (err) {
62
62
  frameworkLogger.log('hermes-integration', 'install-error', 'error', { error: err.message });
@@ -3,7 +3,7 @@ import { join, dirname } from "path";
3
3
  import { execSync } from "child_process";
4
4
  import { getConfigDir } from "../../core/config-paths.js";
5
5
  function getMCPConfigPath() {
6
- return join(process.cwd(), ".opencode", "strray", "mcp-registry.json");
6
+ return join(process.cwd(), ".opencode", "xray", "mcp-registry.json");
7
7
  }
8
8
  function getBundledMCPRegistry() {
9
9
  const paths = [
@@ -14,7 +14,7 @@ export function registerOpenClawCommands(openclawCmd) {
14
14
  }
15
15
  async function installForOpenClaw(options = {}) {
16
16
  frameworkLogger.log('openclaw-integration', 'install-start', 'info', { options });
17
- const configPath = path.join(process.cwd(), '.strray', 'config', 'openclaw.json');
17
+ const configPath = path.join(process.cwd(), '.xray', 'config', 'openclaw.json');
18
18
  if (options.dryRun) {
19
19
  console.log(`[OpenClaw] Dry run: Would create config at ${configPath}`);
20
20
  return;
@@ -14,8 +14,8 @@
14
14
  import * as fs from "fs";
15
15
  import * as path from "path";
16
16
  import { spawnSync } from "child_process";
17
- const PLUGINS_DIR = ".strray/plugins";
18
- const CONFIG_PATH = ".strray/config/plugin-config.json";
17
+ const PLUGINS_DIR = ".xray/plugins";
18
+ const CONFIG_PATH = ".xray/config/plugin-config.json";
19
19
  export async function pluginListCommand() {
20
20
  console.log("\n📦 0xRay Plugins\n");
21
21
  console.log("═".repeat(60));
@@ -69,10 +69,10 @@ function getPackageVersion(cwd) {
69
69
  }
70
70
  }
71
71
  catch { /* ignore */ }
72
- const strrayPkgPath = join(cwd, ".opencode", "package.json");
72
+ const xrayPkgPath = join(cwd, ".opencode", "package.json");
73
73
  try {
74
- if (existsSync(strrayPkgPath)) {
75
- const pkg = JSON.parse(readFileSync(strrayPkgPath, "utf-8"));
74
+ if (existsSync(xrayPkgPath)) {
75
+ const pkg = JSON.parse(readFileSync(xrayPkgPath, "utf-8"));
76
76
  if (pkg.version)
77
77
  return pkg.version;
78
78
  }
@@ -89,7 +89,7 @@ function createAgentManifest(agentName, configPath, version, cwd) {
89
89
  author: extractYamlField(content, "author") || extractYamlField(content, "maintainer") || "0xRay User",
90
90
  license: extractYamlField(content, "license") || "MIT",
91
91
  source: extractYamlField(content, "source") || "custom",
92
- framework: "stringray",
92
+ framework: "xray",
93
93
  frameworkVersion: getPackageVersion(cwd),
94
94
  publishedAt: new Date().toISOString(),
95
95
  skills: [],
@@ -98,7 +98,7 @@ function createAgentManifest(agentName, configPath, version, cwd) {
98
98
  };
99
99
  }
100
100
  function packageAgent(agentName, configPath, version, cwd) {
101
- const outputDir = join(cwd, ".strray", "publish", agentName);
101
+ const outputDir = join(cwd, ".xray", "publish", agentName);
102
102
  mkdirSync(outputDir, { recursive: true });
103
103
  const manifest = createAgentManifest(agentName, configPath, version, cwd);
104
104
  writeFileSync(join(outputDir, "agent.json"), JSON.stringify(manifest, null, 2));
@@ -2,7 +2,7 @@ import { existsSync, readdirSync, readFileSync, mkdirSync, writeFileSync, cpSync
2
2
  import { join, basename, dirname } from "path";
3
3
  import { execSync } from "child_process";
4
4
  function getLocalRegistryPath() {
5
- return join(process.cwd(), ".opencode", "strray", "skill-registry.json");
5
+ return join(process.cwd(), ".opencode", "xray", "skill-registry.json");
6
6
  }
7
7
  function getBundledRegistry() {
8
8
  const paths = [
@@ -41,7 +41,7 @@ function getAgentsList(cwd) {
41
41
  ];
42
42
  const configuredAgents = [];
43
43
  const configDir = getConfigDir(cwd);
44
- const agentsConfigPath = join(configDir, "strray", "agents.json");
44
+ const agentsConfigPath = join(configDir, "xray", "agents.json");
45
45
  if (existsSync(agentsConfigPath)) {
46
46
  try {
47
47
  const config = JSON.parse(readFileSync(agentsConfigPath, "utf-8"));
@@ -51,7 +51,7 @@ function getAgentsList(cwd) {
51
51
  }
52
52
  catch { /* ignore */ }
53
53
  }
54
- const featuresPath = join(configDir, "strray", "features.json");
54
+ const featuresPath = join(configDir, "xray", "features.json");
55
55
  if (existsSync(featuresPath)) {
56
56
  try {
57
57
  const features = JSON.parse(readFileSync(featuresPath, "utf-8"));
@@ -93,7 +93,7 @@ function getInferenceStatus(cwd) {
93
93
  let outcomesCount = 0;
94
94
  let patternsCount = 0;
95
95
  try {
96
- const inferenceDir = join(getConfigDir(cwd), "strray", "inference");
96
+ const inferenceDir = join(getConfigDir(cwd), "xray", "inference");
97
97
  const tunerStatusPath = join(inferenceDir, "tuner-status.json");
98
98
  if (existsSync(tunerStatusPath)) {
99
99
  const status = JSON.parse(readFileSync(tunerStatusPath, "utf-8"));
@@ -16,8 +16,8 @@ import { execSync } from "child_process";
16
16
  const STORY_TYPES = ["reflection", "saga", "journey", "narrative"];
17
17
  function loadConfig(cwd) {
18
18
  const candidates = [
19
- join(cwd, ".opencode", "strray", "features.json"),
20
- join(cwd, ".strray", "features.json"),
19
+ join(cwd, ".opencode", "xray", "features.json"),
20
+ join(cwd, ".xray", "features.json"),
21
21
  ];
22
22
  for (const path of candidates) {
23
23
  if (existsSync(path)) {
package/dist/cli/index.js CHANGED
@@ -385,7 +385,7 @@ program
385
385
  const path = await import("path");
386
386
  let defaultLimit = 500;
387
387
  try {
388
- const featuresPath = path.join(process.cwd(), ".opencode", "plugins", "features.json"); // plain xray primary (min compat .strray/ handled in getConfigDir per Scope Rule)
388
+ const featuresPath = path.join(process.cwd(), ".opencode", "plugins", "features.json"); // plain xray primary (min compat .xray/ handled in getConfigDir per Scope Rule)
389
389
  if (fs.existsSync(featuresPath)) {
390
390
  const features = JSON.parse(fs.readFileSync(featuresPath, "utf-8"));
391
391
  defaultLimit = features.analytics?.default_limit || 500;
@@ -450,17 +450,17 @@ program
450
450
  else {
451
451
  console.log("✅ xray package installed");
452
452
  }
453
- // Check configuration - check for opencode.json or .strray/ (min compat .strray/ fallback for prior StringRay consumer runtime per Scope Rule; plain xray primary)
453
+ // Check configuration - check for opencode.json or .xray/ (min compat .xray/ fallback for prior StringRay consumer runtime per Scope Rule; plain xray primary)
454
454
  const cwd = process.cwd();
455
455
  const opencodeConfigPath = path.join(cwd, "opencode.json");
456
- const strrayDir = getConfigDir(cwd);
456
+ const xrayDir = getConfigDir(cwd);
457
457
  const opencodeExists = fs.existsSync(opencodeConfigPath);
458
- const strrayDirExists = fs.existsSync(strrayDir);
458
+ const xrayDirExists = fs.existsSync(xrayDir);
459
459
  if (opencodeExists) {
460
460
  console.log("✅ opencode configuration found");
461
461
  }
462
- else if (strrayDirExists) {
463
- console.log(`✅ Configuration directory found: ${strrayDir}`);
462
+ else if (xrayDirExists) {
463
+ console.log(`✅ Configuration directory found: ${xrayDir}`);
464
464
  }
465
465
  else {
466
466
  console.log("ℹ️ No opencode.json or config directory found (run: npx xray fix to create)");
@@ -684,13 +684,13 @@ program
684
684
  }
685
685
  else {
686
686
  console.log('Inference feature is disabled in features.json.');
687
- console.log('Enable it by setting inference.enabled = true in .opencode/plugins/features.json (min compat .strray/ fallback for prior StringRay consumer runtime per Scope Rule)');
687
+ console.log('Enable it by setting inference.enabled = true in .opencode/plugins/features.json (min compat .xray/ fallback for prior StringRay consumer runtime per Scope Rule)');
688
688
  }
689
689
  return;
690
690
  }
691
691
  const projectRoot = process.cwd();
692
692
  const inferenceDir = `${projectRoot}/docs/inference`;
693
- const stateDir = `${projectRoot}/.strray/inference`;
693
+ const stateDir = `${projectRoot}/.xray/inference`;
694
694
  const stateFile = `${stateDir}/inference-cycle-state.json`;
695
695
  if (!options.json) {
696
696
  console.log('xray Inference Cycle');
@@ -112,7 +112,7 @@ app.get("/", (req, res) => {
112
112
  });
113
113
  // Add route for refactoring logs
114
114
  app.get("/logs", requireAuth, async (req, res) => {
115
- const logPath = resolveConfigPath("REFACTORING_LOG.md") || join(__dirname, "..", ".strray", "REFACTORING_LOG.md");
115
+ const logPath = resolveConfigPath("REFACTORING_LOG.md") || join(__dirname, "..", ".xray", "REFACTORING_LOG.md");
116
116
  // Server debug logging - remove for production
117
117
  try {
118
118
  if (fs.existsSync(logPath)) {
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Agent Spawn Gate — Singleton (provider-agnostic)
3
3
  *
4
- * CENTRALIZED CONTROL for all agent process spawning across StringRay
4
+ * CENTRALIZED CONTROL for all agent process spawning across Xray
5
5
  * (OpenCode, Hermes, or any other MCP-compatible host).
6
6
  *
7
7
  * Purpose:
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Agent Spawn Gate — Singleton (provider-agnostic)
3
3
  *
4
- * CENTRALIZED CONTROL for all agent process spawning across StringRay
4
+ * CENTRALIZED CONTROL for all agent process spawning across Xray
5
5
  * (OpenCode, Hermes, or any other MCP-compatible host).
6
6
  *
7
7
  * Purpose:
@@ -1,7 +1,7 @@
1
1
  /**
2
- * Boot Orchestrator (min documented consumer runtime compat shim from prior StringRay releases; primary Xray* paths + XRAY_||STRRAY_ env + .strray fallbacks only; 1-line per Scope Rule).
2
+ * Boot Orchestrator (min documented consumer runtime compat shim from prior StringRay releases; primary Xray* paths + XRAY_||STRRAY_ env + .xray fallbacks only; 1-line per Scope Rule).
3
3
  */
4
- import { StringRayStateManager } from "../state/state-manager.js";
4
+ import { XrayStateManager } from "../state/state-manager.js";
5
5
  import { type MemoryStats } from "../monitoring/memory-monitor.js";
6
6
  export interface BootSequenceConfig {
7
7
  enableEnforcement: boolean;
@@ -28,7 +28,7 @@ export declare class BootOrchestrator {
28
28
  private pluginRegistry?;
29
29
  private pluginServerRegistry?;
30
30
  private shutdownInitialized;
31
- constructor(config?: Partial<BootSequenceConfig>, stateManager?: StringRayStateManager);
31
+ constructor(config?: Partial<BootSequenceConfig>, stateManager?: XrayStateManager);
32
32
  /**
33
33
  * Initialize delegation system components
34
34
  */
@@ -94,6 +94,6 @@ export declare class BootOrchestrator {
94
94
  * Execute the boot sequence (internal framework initialization)
95
95
  */
96
96
  executeBootSequence(): Promise<BootResult>;
97
- private loadStringRayConfiguration;
97
+ private loadXrayConfiguration;
98
98
  }
99
99
  export declare const bootOrchestrator: BootOrchestrator;
@@ -1,8 +1,8 @@
1
1
  /**
2
- * Boot Orchestrator (min documented consumer runtime compat shim from prior StringRay releases; primary Xray* paths + XRAY_||STRRAY_ env + .strray fallbacks only; 1-line per Scope Rule).
2
+ * Boot Orchestrator (min documented consumer runtime compat shim from prior StringRay releases; primary Xray* paths + XRAY_||STRRAY_ env + .xray fallbacks only; 1-line per Scope Rule).
3
3
  */
4
- import { StringRayContextLoader } from "./context-loader.js";
5
- import { StringRayStateManager } from "../state/state-manager.js";
4
+ import { XrayContextLoader } from "./context-loader.js";
5
+ import { XrayStateManager } from "../state/state-manager.js";
6
6
  import { ProcessorManager } from "../processors/processor-manager.js";
7
7
  import { pathResolver } from "../utils/path-resolver.js";
8
8
  import * as fs from "fs";
@@ -20,7 +20,7 @@ import { frameworkLogger } from "../core/framework-logger.js";
20
20
  import { featuresConfigLoader } from "../core/features-config.js";
21
21
  import { memoryMonitor } from "../monitoring/memory-monitor.js";
22
22
  import { advancedProfiler } from "../monitoring/advanced-profiler.js";
23
- import { strRayConfigLoader } from "./config-loader.js";
23
+ import { xrayConfigLoader } from "./config-loader.js";
24
24
  import { PluginRegistry } from "../integrations/plugins/index.js";
25
25
  import { PluginServerConfigRegistry } from "../mcps/config/index.js";
26
26
  import { initializeGovernanceIntegration } from "../integrations/governance/index.js";
@@ -30,10 +30,10 @@ import { initializeGovernanceIntegration } from "../integrations/governance/inde
30
30
  */
31
31
  function setupGracefulShutdown() {
32
32
  // Prevent duplicate listeners
33
- if (process._strrayShutdownSetup) {
33
+ if (process._xrayShutdownSetup) {
34
34
  return;
35
35
  }
36
- process._strrayShutdownSetup = true;
36
+ process._xrayShutdownSetup = true;
37
37
  let isShuttingDown = false;
38
38
  process.on("SIGINT", async () => {
39
39
  if (isShuttingDown) {
@@ -98,8 +98,8 @@ export class BootOrchestrator {
98
98
  shutdownInitialized = false;
99
99
  constructor(config = {}, stateManager) {
100
100
  // Initialize components first for state management
101
- this.contextLoader = StringRayContextLoader.getInstance();
102
- this.stateManager = stateManager || new StringRayStateManager();
101
+ this.contextLoader = XrayContextLoader.getInstance();
102
+ this.stateManager = stateManager || new XrayStateManager();
103
103
  this.processorManager = new ProcessorManager(this.stateManager);
104
104
  this.config = {
105
105
  enableEnforcement: true,
@@ -115,7 +115,7 @@ export class BootOrchestrator {
115
115
  */
116
116
  async initializeDelegationSystem() {
117
117
  try {
118
- const agentDelegator = createAgentDelegator(this.stateManager, strRayConfigLoader);
118
+ const agentDelegator = createAgentDelegator(this.stateManager, xrayConfigLoader);
119
119
  this.stateManager.set("delegation:agent_delegator", agentDelegator);
120
120
  const sessionCoordinator = createSessionCoordinator(this.stateManager);
121
121
  this.stateManager.set("delegation:session_coordinator", sessionCoordinator);
@@ -131,8 +131,8 @@ export class BootOrchestrator {
131
131
  loadProcessorsConfig() {
132
132
  try {
133
133
  const configPaths = [
134
- path.join(process.cwd(), ".strray", "features.json"),
135
- path.join(process.cwd(), ".opencode", "strray", "features.json"),
134
+ path.join(process.cwd(), ".xray", "features.json"),
135
+ path.join(process.cwd(), ".opencode", "xray", "features.json"),
136
136
  ];
137
137
  for (const configPath of configPaths) {
138
138
  if (existsSync(configPath)) {
@@ -152,7 +152,7 @@ export class BootOrchestrator {
152
152
  async initializePluginSystem(jobId) {
153
153
  try {
154
154
  frameworkLogger.log("boot-orchestrator", "initializing plugin system", "info", { jobId });
155
- const pluginsDir = path.join(process.cwd(), ".strray", "plugins");
155
+ const pluginsDir = path.join(process.cwd(), ".xray", "plugins");
156
156
  this.pluginRegistry = new PluginRegistry({
157
157
  pluginsDir,
158
158
  autoStart: true,
@@ -189,7 +189,7 @@ export class BootOrchestrator {
189
189
  });
190
190
  return false;
191
191
  }
192
- const orchestratorInstance = orchestratorModule.strRayOrchestrator;
192
+ const orchestratorInstance = orchestratorModule.xrayOrchestrator || orchestratorModule.strRayOrchestrator;
193
193
  if (!orchestratorInstance) {
194
194
  frameworkLogger.log("boot-orchestrator", "orchestrator-not-found", "error", { message: "Orchestrator instance not found in module" });
195
195
  return false;
@@ -596,8 +596,8 @@ export class BootOrchestrator {
596
596
  };
597
597
  try {
598
598
  frameworkLogger.log("boot-orchestrator", "loading xray configuration", "info", { jobId });
599
- // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .strray fallbacks)
600
- await this.loadStringRayConfiguration(jobId);
599
+ // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .xray fallbacks)
600
+ await this.loadXrayConfiguration(jobId);
601
601
  frameworkLogger.log("boot-orchestrator", "xray configuration loaded", "success", { jobId });
602
602
  // Phase 1: Initialize core systems
603
603
  frameworkLogger.log("boot-orchestrator", "initializing core systems", "info", { jobId });
@@ -727,11 +727,11 @@ export class BootOrchestrator {
727
727
  this.stateManager.set("boot:errors", result.errors);
728
728
  return result;
729
729
  }
730
- // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .strray fallbacks)
731
- async loadStringRayConfiguration(jobId) {
730
+ // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .xray fallbacks)
731
+ async loadXrayConfiguration(jobId) {
732
732
  try {
733
- // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .strray fallbacks)
734
- const stringRayConfig = {
733
+ // Consumer runtime compat shim from prior StringRay releases (1-line min per Scope Rule; primary xray paths + XRAY_||STRRAY_ env + .xray fallbacks)
734
+ const xrayConfig = {
735
735
  version: "2.0.0",
736
736
  codex_enabled: true,
737
737
  codex_version: "v2.0.0",
@@ -793,13 +793,13 @@ export class BootOrchestrator {
793
793
  },
794
794
  };
795
795
  // Store configuration in state manager for use by other components
796
- this.stateManager.set("strray:config", stringRayConfig);
797
- this.stateManager.set("strray:version", stringRayConfig.version);
798
- this.stateManager.set("strray:codex_enabled", stringRayConfig.codex_enabled);
799
- this.stateManager.set("strray:codex_terms", stringRayConfig.codex_terms);
800
- this.stateManager.set("strray:monitoring_metrics", stringRayConfig.monitoring_metrics);
801
- this.stateManager.set("strray:monitoring_alerts", stringRayConfig.monitoring_alerts);
802
- this.stateManager.set("strray:agent_capabilities", stringRayConfig.agent_capabilities);
796
+ this.stateManager.set("xray:config", xrayConfig);
797
+ this.stateManager.set("xray:version", xrayConfig.version);
798
+ this.stateManager.set("xray:codex_enabled", xrayConfig.codex_enabled);
799
+ this.stateManager.set("xray:codex_terms", xrayConfig.codex_terms);
800
+ this.stateManager.set("xray:monitoring_metrics", xrayConfig.monitoring_metrics);
801
+ this.stateManager.set("xray:monitoring_alerts", xrayConfig.monitoring_alerts);
802
+ this.stateManager.set("xray:agent_capabilities", xrayConfig.agent_capabilities);
803
803
  await frameworkLogger.log("boot-orchestrator", "configuration-loaded", "success", { jobId });
804
804
  }
805
805
  catch (error) {
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  /**
4
- * StringRay Universal Bridge
4
+ * Xray Universal Bridge
5
5
  *
6
- * Standalone bridge that provides StringRay framework capabilities
6
+ * Standalone bridge that provides Xray framework capabilities
7
7
  * to ANY consumer — no OpenCode dependency.
8
8
  *
9
9
  * Supports three transport modes:
@@ -84,7 +84,7 @@ function findProjectRoot() {
84
84
  const pkgPath = join(dir, "package.json");
85
85
  if (existsSync(pkgPath)) {
86
86
  const pkg = JSON.parse(readFileSync(pkgPath, "utf-8"));
87
- if (pkg.name === "strray-ai" || pkg.dependencies?.["strray-ai"] || pkg.name === "0xray" || pkg.dependencies?.["0xray"]) {
87
+ if (pkg.name === "0xray" || pkg.dependencies?.["0xray"]) {
88
88
  return dir;
89
89
  }
90
90
  }
@@ -219,11 +219,11 @@ async function handleHealth(input) {
219
219
  */
220
220
  /** Codex candidate paths — single source of truth for both loadCodexFromFs and handleGetConfig */
221
221
  function getCodexCandidates(projectRoot) {
222
- const envDir = process.env.STRRAY_CONFIG_DIR;
222
+ const envDir = process.env.XRAY_CONFIG_DIR || process.env.STRRAY_CONFIG_DIR;
223
223
  const candidates = [];
224
224
  if (envDir) candidates.push(join(projectRoot, envDir, "codex.json"));
225
- candidates.push(join(projectRoot, ".strray", "codex.json"));
226
- candidates.push(join(projectRoot, ".opencode", "strray", "codex.json"));
225
+ candidates.push(join(projectRoot, ".xray", "codex.json"));
226
+ candidates.push(join(projectRoot, ".opencode", "xray", "codex.json"));
227
227
  candidates.push(join(projectRoot, "codex.json"));
228
228
  return candidates;
229
229
  }
@@ -281,7 +281,7 @@ async function handleGetCodexPrompt(input, projectRoot, logDir) {
281
281
  terms.sort((a, b) => (severityOrder[a.severity] || 3) - (severityOrder[b.severity] || 3));
282
282
  if (maxTerms) terms = terms.slice(0, maxTerms);
283
283
 
284
- const lines = [`## StringRay Universal Development Codex v${termsSource.version}`];
284
+ const lines = [`## Xray Universal Development Codex v${termsSource.version}`];
285
285
  const emojis = { blocking: "🔴", high: "🟡", medium: "🟢" };
286
286
  const labels = { blocking: "BLOCKING", high: "HIGH PRIORITY", medium: "MEDIUM" };
287
287
 
@@ -348,8 +348,8 @@ async function handleGetConfig(input, projectRoot, logDir) {
348
348
  // Load features.json
349
349
  const featurePaths = [];
350
350
  if (envDir) featurePaths.push(join(projectRoot, envDir, "features.json"));
351
- featurePaths.push(join(projectRoot, ".strray", "features.json"));
352
- featurePaths.push(join(projectRoot, ".opencode", "strray", "features.json"));
351
+ featurePaths.push(join(projectRoot, ".xray", "features.json"));
352
+ featurePaths.push(join(projectRoot, ".opencode", "xray", "features.json"));
353
353
 
354
354
  let featurePath = null;
355
355
  for (const p of featurePaths) {
@@ -604,7 +604,7 @@ function handleHooks(input, projectRoot) {
604
604
  const { action, hooks } = input;
605
605
  const hookTypes = hooks || ["pre-commit", "post-commit", "pre-push", "post-push"];
606
606
  const gitHooksDir = join(projectRoot, ".git", "hooks");
607
- const strrayHooksDir = join(projectRoot, "hooks");
607
+ const xrayHooksDir = join(projectRoot, "hooks");
608
608
 
609
609
  if (!existsSync(gitHooksDir)) {
610
610
  return { error: "Not a git repository — no .git/hooks directory" };
@@ -616,14 +616,14 @@ function handleHooks(input, projectRoot) {
616
616
  if (action === "list" || action === "status") {
617
617
  for (const hookName of hookTypes) {
618
618
  const gitHook = join(gitHooksDir, hookName);
619
- const strrayHook = join(strrayHooksDir, hookName);
619
+ const xrayHook = join(xrayHooksDir, hookName);
620
620
 
621
621
  if (!existsSync(gitHook)) {
622
622
  result.missing.push(hookName);
623
623
  } else {
624
624
  try {
625
625
  const content = readFileSync(gitHook, "utf-8");
626
- if (content.includes("StringRay") || content.includes("strray") || content.includes("run-hook.js")) {
626
+ if (content.includes("Xray") || content.includes("StringRay") || content.includes("xray") || content.includes("strray") || content.includes("run-hook.js")) {
627
627
  result.managed.push(hookName);
628
628
  } else {
629
629
  result.external.push(hookName);
@@ -633,8 +633,8 @@ function handleHooks(input, projectRoot) {
633
633
  }
634
634
  }
635
635
 
636
- // Check if strray source hook exists
637
- if (!existsSync(strrayHook)) {
636
+ // Check if xray source hook exists
637
+ if (!existsSync(xrayHook)) {
638
638
  result.stale.push(hookName);
639
639
  }
640
640
  }
@@ -644,7 +644,7 @@ function handleHooks(input, projectRoot) {
644
644
  action,
645
645
  hooks: result,
646
646
  gitHooksDir,
647
- strrayHooksDir,
647
+ xrayHooksDir,
648
648
  };
649
649
  }
650
650
 
@@ -655,7 +655,7 @@ function handleHooks(input, projectRoot) {
655
655
  const errors = [];
656
656
 
657
657
  for (const hookName of hookTypes) {
658
- const src = join(strrayHooksDir, hookName);
658
+ const src = join(xrayHooksDir, hookName);
659
659
  const dst = join(gitHooksDir, hookName);
660
660
 
661
661
  if (!existsSync(src)) {
@@ -664,11 +664,11 @@ function handleHooks(input, projectRoot) {
664
664
  }
665
665
 
666
666
  try {
667
- // Backup existing non-strray hooks
667
+ // Backup existing non-xray hooks
668
668
  if (existsSync(dst)) {
669
669
  const content = readFileSync(dst, "utf-8");
670
- if (!content.includes("StringRay") && !content.includes("strray") && !content.includes("run-hook.js")) {
671
- renameSync(dst, `${dst}.strray-backup`);
670
+ if (!content.includes("Xray") && !content.includes("StringRay") && !content.includes("xray") && !content.includes("strray") && !content.includes("run-hook.js")) {
671
+ renameSync(dst, `${dst}.xray-backup`);
672
672
  } else {
673
673
  unlinkSync(dst);
674
674
  }
@@ -699,15 +699,15 @@ function handleHooks(input, projectRoot) {
699
699
 
700
700
  for (const hookName of hookTypes) {
701
701
  const dst = join(gitHooksDir, hookName);
702
- const backup = `${dst}.strray-backup`;
702
+ const backup = `${dst}.xray-backup`;
703
703
 
704
704
  if (!existsSync(dst)) continue;
705
705
 
706
706
  try {
707
707
  const content = readFileSync(dst, "utf-8");
708
- const isStrray = content.includes("StringRay") || content.includes("strray") || content.includes("run-hook.js");
708
+ const isXray = content.includes("Xray") || content.includes("StringRay") || content.includes("xray") || content.includes("strray") || content.includes("run-hook.js");
709
709
 
710
- if (isStrray || lstatSync(dst).isSymbolicLink()) {
710
+ if (isXray || lstatSync(dst).isSymbolicLink()) {
711
711
  unlinkSync(dst);
712
712
 
713
713
  // Restore backup if exists
@@ -89,8 +89,8 @@ export function findCodexPath(projectRoot) {
89
89
  if (envDir) {
90
90
  candidates.push(resolve(root, envDir, "codex.json"));
91
91
  }
92
- candidates.push(join(root, ".strray", "codex.json"));
93
- candidates.push(join(root, ".opencode", "strray", "codex.json"));
92
+ candidates.push(join(root, ".xray", "codex.json"));
93
+ candidates.push(join(root, ".opencode", "xray", "codex.json"));
94
94
  // Additional fallback locations (for standalone usage)
95
95
  candidates.push(join(root, "codex.json"));
96
96
  candidates.push(join(root, "src", "codex.json"));
@@ -8,14 +8,14 @@
8
8
  * @since 2026-01-06
9
9
  */
10
10
  /**
11
- * Create strray-codex-injector hook
11
+ * Create xray-codex-injector hook
12
12
  *
13
13
  * This hook injects codex context into tool outputs and displays
14
14
  * a welcome message on agent startup, following the production-tested
15
15
  * pattern from OpenCode's rules-injector.
16
16
  */
17
- export declare function createStringRayCodexInjectorHook(): {
18
- name: "strray-codex-injector";
17
+ export declare function createXrayCodexInjectorHook(): {
18
+ name: "xray-codex-injector";
19
19
  hooks: {
20
20
  "agent.start": (sessionId: string) => Promise<void>;
21
21
  "tool.execute.before": (input: {
@@ -72,3 +72,4 @@ export declare class CodexInjector {
72
72
  concerns: string[];
73
73
  };
74
74
  }
75
+ export { createXrayCodexInjectorHook as createStringRayCodexInjectorHook };