@cchistory/lite 0.9.0 → 0.9.2

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 (228) hide show
  1. package/INSTALL.md +1 -1
  2. package/apps/lite-cli/dist/agent-contract.d.ts.map +1 -1
  3. package/apps/lite-cli/dist/agent-contract.js +41 -2
  4. package/apps/lite-cli/dist/agent-contract.js.map +1 -1
  5. package/apps/lite-cli/dist/help.js +5 -5
  6. package/apps/lite-cli/dist/index.d.ts.map +1 -1
  7. package/apps/lite-cli/dist/index.js +148 -17
  8. package/apps/lite-cli/dist/index.js.map +1 -1
  9. package/apps/lite-cli/dist/index.test.js +114 -95
  10. package/apps/lite-cli/dist/index.test.js.map +1 -1
  11. package/apps/lite-cli/dist/inventory-and-git.test.d.ts +7 -0
  12. package/apps/lite-cli/dist/inventory-and-git.test.d.ts.map +1 -0
  13. package/apps/lite-cli/dist/inventory-and-git.test.js +776 -0
  14. package/apps/lite-cli/dist/inventory-and-git.test.js.map +1 -0
  15. package/apps/lite-cli/dist/inventory-command.d.ts +30 -0
  16. package/apps/lite-cli/dist/inventory-command.d.ts.map +1 -0
  17. package/apps/lite-cli/dist/inventory-command.js +265 -0
  18. package/apps/lite-cli/dist/inventory-command.js.map +1 -0
  19. package/apps/lite-cli/dist/json-v2.d.ts +2 -2
  20. package/apps/lite-cli/dist/json-v2.d.ts.map +1 -1
  21. package/apps/lite-cli/dist/json-v2.js +9 -3
  22. package/apps/lite-cli/dist/json-v2.js.map +1 -1
  23. package/apps/lite-cli/dist/project-git-command.d.ts +28 -0
  24. package/apps/lite-cli/dist/project-git-command.d.ts.map +1 -0
  25. package/apps/lite-cli/dist/project-git-command.js +288 -0
  26. package/apps/lite-cli/dist/project-git-command.js.map +1 -0
  27. package/apps/lite-cli/dist/startup-render.d.ts +10 -0
  28. package/apps/lite-cli/dist/startup-render.d.ts.map +1 -0
  29. package/apps/lite-cli/dist/startup-render.js +335 -0
  30. package/apps/lite-cli/dist/startup-render.js.map +1 -0
  31. package/apps/lite-cli/dist/version.d.ts +1 -1
  32. package/apps/lite-cli/dist/version.js +1 -1
  33. package/apps/lite-tui/dist/index.d.ts.map +1 -1
  34. package/apps/lite-tui/dist/index.js +40 -9
  35. package/apps/lite-tui/dist/index.js.map +1 -1
  36. package/apps/lite-tui/dist/input.js +2 -2
  37. package/apps/lite-tui/dist/input.js.map +1 -1
  38. package/apps/lite-tui/dist/keys.d.ts.map +1 -1
  39. package/apps/lite-tui/dist/keys.js +52 -14
  40. package/apps/lite-tui/dist/keys.js.map +1 -1
  41. package/apps/lite-tui/dist/keys.test.js +29 -0
  42. package/apps/lite-tui/dist/keys.test.js.map +1 -1
  43. package/apps/lite-tui/dist/model.d.ts +2 -0
  44. package/apps/lite-tui/dist/model.d.ts.map +1 -1
  45. package/apps/lite-tui/dist/model.js +59 -9
  46. package/apps/lite-tui/dist/model.js.map +1 -1
  47. package/apps/lite-tui/dist/render.d.ts +1 -1
  48. package/apps/lite-tui/dist/render.d.ts.map +1 -1
  49. package/apps/lite-tui/dist/render.js +10 -4
  50. package/apps/lite-tui/dist/render.js.map +1 -1
  51. package/apps/lite-tui/dist/render.test.js +31 -0
  52. package/apps/lite-tui/dist/render.test.js.map +1 -1
  53. package/apps/lite-tui/dist/state.js +1 -1
  54. package/apps/lite-tui/dist/state.js.map +1 -1
  55. package/apps/lite-tui/dist/state.test.js +54 -0
  56. package/apps/lite-tui/dist/state.test.js.map +1 -1
  57. package/apps/lite-tui/dist/stats-dashboard.test.js +130 -0
  58. package/apps/lite-tui/dist/stats-dashboard.test.js.map +1 -1
  59. package/apps/lite-tui/dist/stats-render.d.ts +1 -1
  60. package/apps/lite-tui/dist/stats-render.d.ts.map +1 -1
  61. package/apps/lite-tui/dist/stats-render.js +3 -0
  62. package/apps/lite-tui/dist/stats-render.js.map +1 -1
  63. package/apps/lite-tui/dist/stats-visuals.d.ts.map +1 -1
  64. package/apps/lite-tui/dist/stats-visuals.js +3 -1
  65. package/apps/lite-tui/dist/stats-visuals.js.map +1 -1
  66. package/apps/lite-tui/dist/version.d.ts +1 -1
  67. package/apps/lite-tui/dist/version.js +1 -1
  68. package/docs/guide/for-agents.md +14 -0
  69. package/docs/guide/lite.md +53 -2
  70. package/node_modules/@cchistory/canonical/dist/agent-inventory.d.ts +25 -0
  71. package/node_modules/@cchistory/canonical/dist/agent-inventory.d.ts.map +1 -0
  72. package/node_modules/@cchistory/canonical/dist/agent-inventory.js +345 -0
  73. package/node_modules/@cchistory/canonical/dist/agent-inventory.js.map +1 -0
  74. package/node_modules/@cchistory/canonical/dist/agent-inventory.test.d.ts +7 -0
  75. package/node_modules/@cchistory/canonical/dist/agent-inventory.test.d.ts.map +1 -0
  76. package/node_modules/@cchistory/canonical/dist/agent-inventory.test.js +231 -0
  77. package/node_modules/@cchistory/canonical/dist/agent-inventory.test.js.map +1 -0
  78. package/node_modules/@cchistory/canonical/dist/directory-scope.d.ts.map +1 -1
  79. package/node_modules/@cchistory/canonical/dist/directory-scope.js +4 -1
  80. package/node_modules/@cchistory/canonical/dist/directory-scope.js.map +1 -1
  81. package/node_modules/@cchistory/canonical/dist/fallback-projects.d.ts.map +1 -1
  82. package/node_modules/@cchistory/canonical/dist/fallback-projects.js +5 -2
  83. package/node_modules/@cchistory/canonical/dist/fallback-projects.js.map +1 -1
  84. package/node_modules/@cchistory/canonical/dist/index.d.ts +3 -1
  85. package/node_modules/@cchistory/canonical/dist/index.d.ts.map +1 -1
  86. package/node_modules/@cchistory/canonical/dist/index.js +3 -1
  87. package/node_modules/@cchistory/canonical/dist/index.js.map +1 -1
  88. package/node_modules/@cchistory/canonical/dist/index.test.js +215 -1
  89. package/node_modules/@cchistory/canonical/dist/index.test.js.map +1 -1
  90. package/node_modules/@cchistory/canonical/dist/project-linker.d.ts +2 -1
  91. package/node_modules/@cchistory/canonical/dist/project-linker.d.ts.map +1 -1
  92. package/node_modules/@cchistory/canonical/dist/project-linker.js +113 -6
  93. package/node_modules/@cchistory/canonical/dist/project-linker.js.map +1 -1
  94. package/node_modules/@cchistory/canonical/dist/project-merge.d.ts +42 -0
  95. package/node_modules/@cchistory/canonical/dist/project-merge.d.ts.map +1 -0
  96. package/node_modules/@cchistory/canonical/dist/project-merge.js +396 -0
  97. package/node_modules/@cchistory/canonical/dist/project-merge.js.map +1 -0
  98. package/node_modules/@cchistory/canonical/dist/project-merge.test.d.ts +7 -0
  99. package/node_modules/@cchistory/canonical/dist/project-merge.test.d.ts.map +1 -0
  100. package/node_modules/@cchistory/canonical/dist/project-merge.test.js +319 -0
  101. package/node_modules/@cchistory/canonical/dist/project-merge.test.js.map +1 -0
  102. package/node_modules/@cchistory/canonical/dist/session-interpreter.d.ts.map +1 -1
  103. package/node_modules/@cchistory/canonical/dist/session-interpreter.js +38 -0
  104. package/node_modules/@cchistory/canonical/dist/session-interpreter.js.map +1 -1
  105. package/node_modules/@cchistory/canonical/dist/tool-call-summary.d.ts.map +1 -1
  106. package/node_modules/@cchistory/canonical/dist/tool-call-summary.js +8 -0
  107. package/node_modules/@cchistory/canonical/dist/tool-call-summary.js.map +1 -1
  108. package/node_modules/@cchistory/canonical/dist/usage-call-evaluation.d.ts.map +1 -1
  109. package/node_modules/@cchistory/canonical/dist/usage-call-evaluation.js +5 -1
  110. package/node_modules/@cchistory/canonical/dist/usage-call-evaluation.js.map +1 -1
  111. package/node_modules/@cchistory/canonical/dist/usage-trace.d.ts.map +1 -1
  112. package/node_modules/@cchistory/canonical/dist/usage-trace.js +10 -4
  113. package/node_modules/@cchistory/canonical/dist/usage-trace.js.map +1 -1
  114. package/node_modules/@cchistory/canonical/dist/usage.d.ts +2 -0
  115. package/node_modules/@cchistory/canonical/dist/usage.d.ts.map +1 -1
  116. package/node_modules/@cchistory/canonical/dist/usage.js +44 -6
  117. package/node_modules/@cchistory/canonical/dist/usage.js.map +1 -1
  118. package/node_modules/@cchistory/canonical/package.json +1 -1
  119. package/node_modules/@cchistory/domain/dist/agent-inventory.d.ts +146 -0
  120. package/node_modules/@cchistory/domain/dist/agent-inventory.d.ts.map +1 -0
  121. package/node_modules/@cchistory/domain/dist/agent-inventory.js +9 -0
  122. package/node_modules/@cchistory/domain/dist/agent-inventory.js.map +1 -0
  123. package/node_modules/@cchistory/domain/dist/agent-startup.d.ts +362 -0
  124. package/node_modules/@cchistory/domain/dist/agent-startup.d.ts.map +1 -0
  125. package/node_modules/@cchistory/domain/dist/agent-startup.js +8 -0
  126. package/node_modules/@cchistory/domain/dist/agent-startup.js.map +1 -0
  127. package/node_modules/@cchistory/domain/dist/index.d.ts +5 -0
  128. package/node_modules/@cchistory/domain/dist/index.d.ts.map +1 -1
  129. package/node_modules/@cchistory/domain/dist/index.js +3 -0
  130. package/node_modules/@cchistory/domain/dist/index.js.map +1 -1
  131. package/node_modules/@cchistory/domain/dist/index.test.js +18 -1
  132. package/node_modules/@cchistory/domain/dist/index.test.js.map +1 -1
  133. package/node_modules/@cchistory/domain/dist/project-git.d.ts +121 -0
  134. package/node_modules/@cchistory/domain/dist/project-git.d.ts.map +1 -0
  135. package/node_modules/@cchistory/domain/dist/project-git.js +93 -0
  136. package/node_modules/@cchistory/domain/dist/project-git.js.map +1 -0
  137. package/node_modules/@cchistory/domain/package.json +1 -1
  138. package/node_modules/@cchistory/live-runtime/dist/antigravity.test.js +15 -1
  139. package/node_modules/@cchistory/live-runtime/dist/antigravity.test.js.map +1 -1
  140. package/node_modules/@cchistory/live-runtime/dist/index.d.ts +3 -1
  141. package/node_modules/@cchistory/live-runtime/dist/index.d.ts.map +1 -1
  142. package/node_modules/@cchistory/live-runtime/dist/index.js +14 -8
  143. package/node_modules/@cchistory/live-runtime/dist/index.js.map +1 -1
  144. package/node_modules/@cchistory/live-runtime/dist/inventory-and-git.d.ts +35 -0
  145. package/node_modules/@cchistory/live-runtime/dist/inventory-and-git.d.ts.map +1 -0
  146. package/node_modules/@cchistory/live-runtime/dist/inventory-and-git.js +68 -0
  147. package/node_modules/@cchistory/live-runtime/dist/inventory-and-git.js.map +1 -0
  148. package/node_modules/@cchistory/live-runtime/package.json +1 -1
  149. package/node_modules/@cchistory/source-adapters/dist/core/git-project.d.ts +9 -0
  150. package/node_modules/@cchistory/source-adapters/dist/core/git-project.d.ts.map +1 -1
  151. package/node_modules/@cchistory/source-adapters/dist/core/git-project.js +130 -7
  152. package/node_modules/@cchistory/source-adapters/dist/core/git-project.js.map +1 -1
  153. package/node_modules/@cchistory/source-adapters/dist/index.d.ts +5 -0
  154. package/node_modules/@cchistory/source-adapters/dist/index.d.ts.map +1 -1
  155. package/node_modules/@cchistory/source-adapters/dist/index.js +5 -0
  156. package/node_modules/@cchistory/source-adapters/dist/index.js.map +1 -1
  157. package/node_modules/@cchistory/source-adapters/dist/index.test.d.ts +2 -0
  158. package/node_modules/@cchistory/source-adapters/dist/index.test.d.ts.map +1 -1
  159. package/node_modules/@cchistory/source-adapters/dist/index.test.js +2 -0
  160. package/node_modules/@cchistory/source-adapters/dist/index.test.js.map +1 -1
  161. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.d.ts +14 -0
  162. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.d.ts.map +1 -0
  163. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.js +397 -0
  164. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.js.map +1 -0
  165. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.test.d.ts +6 -0
  166. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.test.d.ts.map +1 -0
  167. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.test.js +106 -0
  168. package/node_modules/@cchistory/source-adapters/dist/inventory/agent-config-reader.test.js.map +1 -0
  169. package/node_modules/@cchistory/source-adapters/dist/inventory/config-io.d.ts +42 -0
  170. package/node_modules/@cchistory/source-adapters/dist/inventory/config-io.d.ts.map +1 -0
  171. package/node_modules/@cchistory/source-adapters/dist/inventory/config-io.js +368 -0
  172. package/node_modules/@cchistory/source-adapters/dist/inventory/config-io.js.map +1 -0
  173. package/node_modules/@cchistory/source-adapters/dist/inventory/redaction.d.ts +22 -0
  174. package/node_modules/@cchistory/source-adapters/dist/inventory/redaction.d.ts.map +1 -0
  175. package/node_modules/@cchistory/source-adapters/dist/inventory/redaction.js +195 -0
  176. package/node_modules/@cchistory/source-adapters/dist/inventory/redaction.js.map +1 -0
  177. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity-helpers.d.ts +23 -0
  178. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity-helpers.d.ts.map +1 -0
  179. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity-helpers.js +147 -0
  180. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity-helpers.js.map +1 -0
  181. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity.d.ts +11 -0
  182. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity.d.ts.map +1 -0
  183. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity.js +339 -0
  184. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/antigravity.js.map +1 -0
  185. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code-helpers.d.ts +70 -0
  186. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code-helpers.d.ts.map +1 -0
  187. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code-helpers.js +257 -0
  188. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code-helpers.js.map +1 -0
  189. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code.d.ts +11 -0
  190. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code.d.ts.map +1 -0
  191. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code.js +321 -0
  192. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/claude-code.js.map +1 -0
  193. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/codex.d.ts +12 -0
  194. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/codex.d.ts.map +1 -0
  195. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/codex.js +363 -0
  196. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/codex.js.map +1 -0
  197. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/deepseek-harness.d.ts +20 -0
  198. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/deepseek-harness.d.ts.map +1 -0
  199. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/deepseek-harness.js +408 -0
  200. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/deepseek-harness.js.map +1 -0
  201. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/index.d.ts +24 -0
  202. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/index.d.ts.map +1 -0
  203. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/index.js +225 -0
  204. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/index.js.map +1 -0
  205. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/opencode.d.ts +12 -0
  206. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/opencode.d.ts.map +1 -0
  207. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/opencode.js +372 -0
  208. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/opencode.js.map +1 -0
  209. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/shared.d.ts +62 -0
  210. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/shared.d.ts.map +1 -0
  211. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/shared.js +428 -0
  212. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/shared.js.map +1 -0
  213. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/startup.test.d.ts +7 -0
  214. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/startup.test.d.ts.map +1 -0
  215. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/startup.test.js +399 -0
  216. package/node_modules/@cchistory/source-adapters/dist/inventory/startup/startup.test.js.map +1 -0
  217. package/node_modules/@cchistory/source-adapters/dist/inventory/toml.d.ts +16 -0
  218. package/node_modules/@cchistory/source-adapters/dist/inventory/toml.d.ts.map +1 -0
  219. package/node_modules/@cchistory/source-adapters/dist/inventory/toml.js +478 -0
  220. package/node_modules/@cchistory/source-adapters/dist/inventory/toml.js.map +1 -0
  221. package/node_modules/@cchistory/source-adapters/package.json +1 -1
  222. package/package.json +5 -5
  223. package/schemas/cchistory-lite-agent-v1.schema.json +3 -1
  224. package/schemas/cchistory-lite-envelope-v1.schema.json +33 -0
  225. package/schemas/cchistory-lite-inventory-v1.schema.json +94 -0
  226. package/schemas/cchistory-lite-merged-projects-v1.schema.json +44 -0
  227. package/schemas/cchistory-lite-v2.schema.json +22 -1
  228. package/skills/using-cchistory-lite/SKILL.md +17 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codex.d.ts","sourceRoot":"","sources":["../../../src/inventory/startup/codex.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,KAAK,EACV,sBAAsB,EAKvB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAYL,KAAK,0BAA0B,EAEhC,MAAM,aAAa,CAAC;AAIrB,wBAAsB,mBAAmB,CACvC,KAAK,EAAE,0BAA0B,GAChC,OAAO,CAAC,sBAAsB,CAAC,CAgVjC"}
@@ -0,0 +1,363 @@
1
+ /**
2
+ * Role: Native pre-launch startup context resolver for OpenAI Codex CLI.
3
+ * Resolves ~/.codex/config.toml + trusted .codex/config.toml, [projects.<dir>].trust_level,
4
+ * profiles, AGENTS.override.md / AGENTS.md / fallback chain from global -> Git root -> cwd
5
+ * with cumulative project_doc_max_bytes (32 KiB default) truncation tracking, MCP servers,
6
+ * agents, skills, and hooks.
7
+ * Excludes history scanning, activity correlation, and CLI formatting.
8
+ */
9
+ import path from "node:path";
10
+ import { redactMcpCommand } from "../redaction.js";
11
+ import { asNonEmptyString, asRecord, buildRedactedMcpEntry, createReadTracker, estimateTokens, listSkillEntriesInDir, normalizeComparablePath, readTrackedTextFile, readTrackedTomlObject, safeReadDir, stripMcpResolutionFields, } from "./shared.js";
12
+ const DEFAULT_CODEX_DOC_MAX_BYTES = 32_768;
13
+ export async function resolveCodexStartup(input) {
14
+ const tracker = createReadTracker("codex");
15
+ const envCodexHome = input.env.CODEX_HOME?.trim();
16
+ const codexHome = envCodexHome ? path.resolve(envCodexHome) : path.join(input.homeDir, ".codex");
17
+ const globalConfigPath = path.join(codexHome, "config.toml");
18
+ const globalConfig = await readTrackedTomlObject(tracker, globalConfigPath, "codex_config");
19
+ // Determine project trust level from global `[projects."<path>"].trust_level`
20
+ const projectTrustLevel = resolveCodexTrustLevel(globalConfig, input.projectDir, input.gitRoot);
21
+ const projectTrusted = projectTrustLevel === "trusted";
22
+ // Check for project `.codex/config.toml` (closest in ancestor chain)
23
+ let projectConfigPath = null;
24
+ let projectConfig;
25
+ for (let i = input.ancestorDirsRootToCwd.length - 1; i >= 0; i -= 1) {
26
+ const candidate = path.join(input.ancestorDirsRootToCwd[i], ".codex", "config.toml");
27
+ const parsed = await readTrackedTomlObject(tracker, candidate, "codex_project_config");
28
+ if (parsed) {
29
+ projectConfigPath = candidate;
30
+ projectConfig = parsed;
31
+ break;
32
+ }
33
+ }
34
+ // Merge non-secret config settings (project applies only when trusted)
35
+ const effectiveLayers = [
36
+ ...(globalConfig ? [{ path: globalConfigPath, data: globalConfig, scope: "user" }] : []),
37
+ ...(projectConfig && projectConfigPath && projectTrusted
38
+ ? [{ path: projectConfigPath, data: projectConfig, scope: "project" }]
39
+ : []),
40
+ ];
41
+ let effectiveModel;
42
+ let reasoningEffort;
43
+ let approvalPolicy;
44
+ let sandboxMode;
45
+ let projectDocMaxBytes = DEFAULT_CODEX_DOC_MAX_BYTES;
46
+ let fallbackFilenames = [];
47
+ let activeProfile;
48
+ const profileNames = new Set();
49
+ for (const layer of effectiveLayers) {
50
+ const model = asNonEmptyString(layer.data.model);
51
+ if (model)
52
+ effectiveModel = model;
53
+ const effort = asNonEmptyString(layer.data.model_reasoning_effort);
54
+ if (effort)
55
+ reasoningEffort = effort;
56
+ const approval = asNonEmptyString(layer.data.approval_policy);
57
+ if (approval)
58
+ approvalPolicy = approval;
59
+ const sandbox = asNonEmptyString(layer.data.sandbox_mode);
60
+ if (sandbox)
61
+ sandboxMode = sandbox;
62
+ if (typeof layer.data.project_doc_max_bytes === "number" && layer.data.project_doc_max_bytes > 0) {
63
+ projectDocMaxBytes = Math.floor(layer.data.project_doc_max_bytes);
64
+ }
65
+ if (Array.isArray(layer.data.project_doc_fallback_filenames)) {
66
+ fallbackFilenames = layer.data.project_doc_fallback_filenames.filter((v) => typeof v === "string" && v.trim().length > 0);
67
+ }
68
+ const profile = asNonEmptyString(layer.data.profile);
69
+ if (profile)
70
+ activeProfile = profile;
71
+ const profiles = asRecord(layer.data.profiles);
72
+ if (profiles) {
73
+ for (const name of Object.keys(profiles))
74
+ profileNames.add(name);
75
+ }
76
+ }
77
+ // Apply active profile scalar overrides if present
78
+ if (activeProfile) {
79
+ for (const layer of effectiveLayers) {
80
+ const profileCfg = asRecord(asRecord(layer.data.profiles)?.[activeProfile]);
81
+ if (!profileCfg)
82
+ continue;
83
+ const model = asNonEmptyString(profileCfg.model);
84
+ if (model)
85
+ effectiveModel = model;
86
+ const effort = asNonEmptyString(profileCfg.model_reasoning_effort);
87
+ if (effort)
88
+ reasoningEffort = effort;
89
+ const approval = asNonEmptyString(profileCfg.approval_policy);
90
+ if (approval)
91
+ approvalPolicy = approval;
92
+ const sandbox = asNonEmptyString(profileCfg.sandbox_mode);
93
+ if (sandbox)
94
+ sandboxMode = sandbox;
95
+ }
96
+ }
97
+ // Build exact Codex instruction chain: global -> Git root -> ... -> cwd, with AGENTS.override.md shadowing + 32 KiB cap
98
+ const instructionChain = [];
99
+ let remainingBudget = projectDocMaxBytes;
100
+ const inspectInstructionDir = async (dir, layer, candidates) => {
101
+ const found = [];
102
+ for (const cand of candidates) {
103
+ const filePath = path.join(dir, cand.fileName);
104
+ const file = await readTrackedTextFile(tracker, filePath, "codex_instructions");
105
+ if (file && file.sizeBytes > 0) {
106
+ found.push({ fileName: cand.fileName, filePath, kind: cand.kind, sizeBytes: file.sizeBytes });
107
+ }
108
+ }
109
+ if (found.length === 0)
110
+ return;
111
+ const winner = found[0];
112
+ let status;
113
+ let includedBytes;
114
+ let droppedBytes;
115
+ if (remainingBudget <= 0) {
116
+ status = "budget_exhausted";
117
+ includedBytes = 0;
118
+ droppedBytes = winner.sizeBytes;
119
+ }
120
+ else if (winner.sizeBytes <= remainingBudget) {
121
+ status = "effective";
122
+ includedBytes = winner.sizeBytes;
123
+ droppedBytes = 0;
124
+ remainingBudget -= winner.sizeBytes;
125
+ }
126
+ else {
127
+ status = "truncated";
128
+ includedBytes = remainingBudget;
129
+ droppedBytes = winner.sizeBytes - remainingBudget;
130
+ remainingBudget = 0;
131
+ }
132
+ instructionChain.push({
133
+ path: winner.filePath,
134
+ directory: dir,
135
+ layer,
136
+ kind: winner.kind,
137
+ status,
138
+ size_bytes: winner.sizeBytes,
139
+ included_bytes: includedBytes,
140
+ dropped_bytes: droppedBytes,
141
+ estimated_tokens: estimateTokens(includedBytes),
142
+ });
143
+ for (let i = 1; i < found.length; i += 1) {
144
+ const shadowed = found[i];
145
+ instructionChain.push({
146
+ path: shadowed.filePath,
147
+ directory: dir,
148
+ layer,
149
+ kind: shadowed.kind,
150
+ status: "shadowed",
151
+ shadowed_by: winner.filePath,
152
+ size_bytes: shadowed.sizeBytes,
153
+ included_bytes: 0,
154
+ dropped_bytes: shadowed.sizeBytes,
155
+ estimated_tokens: 0,
156
+ });
157
+ }
158
+ };
159
+ await inspectInstructionDir(codexHome, "global", [
160
+ { fileName: "AGENTS.override.md", kind: "agents_override_md" },
161
+ { fileName: "AGENTS.md", kind: "agents_md" },
162
+ ]);
163
+ const projectCandidates = [
164
+ { fileName: "AGENTS.override.md", kind: "agents_override_md" },
165
+ { fileName: "AGENTS.md", kind: "agents_md" },
166
+ ...fallbackFilenames
167
+ .filter((name) => name !== "AGENTS.override.md" && name !== "AGENTS.md")
168
+ .map((fileName) => ({ fileName, kind: "fallback" })),
169
+ ];
170
+ for (let i = 0; i < input.ancestorDirsRootToCwd.length; i += 1) {
171
+ const dir = input.ancestorDirsRootToCwd[i];
172
+ const layer = i === input.ancestorDirsRootToCwd.length - 1
173
+ ? "cwd"
174
+ : i === 0 && input.gitRoot
175
+ ? "repo_root"
176
+ : "ancestor";
177
+ await inspectInstructionDir(dir, layer, projectCandidates);
178
+ }
179
+ // MCP servers: trusted project config > global config; untrusted project MCPs marked `trust_gated`
180
+ const mcpServers = [];
181
+ const winners = new Map();
182
+ if (projectConfig && projectConfigPath) {
183
+ const projMcp = asRecord(projectConfig.mcp_servers);
184
+ if (projMcp) {
185
+ for (const [id, val] of Object.entries(projMcp)) {
186
+ const rec = asRecord(val);
187
+ if (!rec)
188
+ continue;
189
+ const entry = buildRedactedMcpEntry("codex", "project", projectConfigPath, id, rec);
190
+ if (!projectTrusted) {
191
+ mcpServers.push({
192
+ ...entry,
193
+ status: "trust_gated",
194
+ precedence_layer: "project_config",
195
+ disabled_reason: "project_not_trusted_in_global_config",
196
+ });
197
+ }
198
+ else if (!entry.enabled) {
199
+ mcpServers.push({ ...entry, status: "disabled", precedence_layer: "project_config", disabled_reason: "config_disabled" });
200
+ }
201
+ else {
202
+ winners.set(id.toLowerCase(), `project_config (${projectConfigPath})`);
203
+ mcpServers.push({ ...entry, status: "effective", precedence_layer: "project_config" });
204
+ }
205
+ }
206
+ }
207
+ }
208
+ if (globalConfig) {
209
+ const userMcp = asRecord(globalConfig.mcp_servers);
210
+ if (userMcp) {
211
+ for (const [id, val] of Object.entries(userMcp)) {
212
+ const rec = asRecord(val);
213
+ if (!rec)
214
+ continue;
215
+ const entry = buildRedactedMcpEntry("codex", "user", globalConfigPath, id, rec);
216
+ if (!entry.enabled) {
217
+ mcpServers.push({ ...entry, status: "disabled", precedence_layer: "global_config", disabled_reason: "config_disabled" });
218
+ continue;
219
+ }
220
+ const winner = winners.get(id.toLowerCase());
221
+ if (winner) {
222
+ mcpServers.push({ ...entry, status: "shadowed", precedence_layer: "global_config", shadowed_by: winner });
223
+ }
224
+ else {
225
+ winners.set(id.toLowerCase(), `global_config (${globalConfigPath})`);
226
+ mcpServers.push({ ...entry, status: "effective", precedence_layer: "global_config" });
227
+ }
228
+ }
229
+ }
230
+ }
231
+ // Agents ([agents.*] in TOML + agents/ dirs)
232
+ const agents = [];
233
+ for (const layer of effectiveLayers) {
234
+ const tomlAgents = asRecord(layer.data.agents);
235
+ if (!tomlAgents)
236
+ continue;
237
+ for (const [name, val] of Object.entries(tomlAgents)) {
238
+ const rec = asRecord(val);
239
+ agents.push({
240
+ name,
241
+ source: "toml",
242
+ scope: layer.scope,
243
+ path: layer.path,
244
+ ...(asNonEmptyString(rec?.model) ? { model: asNonEmptyString(rec?.model) } : {}),
245
+ ...(asNonEmptyString(rec?.description) ? { description: asNonEmptyString(rec?.description) } : {}),
246
+ });
247
+ }
248
+ }
249
+ await collectCodexAgentFiles(tracker, path.join(codexHome, "agents"), "user", agents);
250
+ if (input.projectDir) {
251
+ await collectCodexAgentFiles(tracker, path.join(input.projectDir, ".codex", "agents"), "project", agents);
252
+ }
253
+ // Skills (project .codex/skills + .agents/skills > user ~/.codex/skills)
254
+ const skills = [];
255
+ const skillWinners = new Map();
256
+ const addSkills = (items, scope) => {
257
+ for (const item of items) {
258
+ const key = item.name.toLowerCase();
259
+ const winner = skillWinners.get(key);
260
+ if (winner) {
261
+ skills.push({ ...item, scope, status: "shadowed", shadowed_by: winner });
262
+ }
263
+ else {
264
+ skillWinners.set(key, `${scope} (${item.path})`);
265
+ skills.push({ ...item, scope, status: "effective" });
266
+ }
267
+ }
268
+ };
269
+ if (input.projectDir) {
270
+ addSkills(await listSkillEntriesInDir(tracker, path.join(input.projectDir, ".codex", "skills")), "project");
271
+ addSkills(await listSkillEntriesInDir(tracker, path.join(input.projectDir, ".agents", "skills")), "project");
272
+ }
273
+ addSkills(await listSkillEntriesInDir(tracker, path.join(codexHome, "skills")), "user");
274
+ // Hooks
275
+ const hooks = [];
276
+ for (const layer of effectiveLayers) {
277
+ const hooksObj = asRecord(layer.data.hooks);
278
+ if (!hooksObj)
279
+ continue;
280
+ for (const [event, val] of Object.entries(hooksObj)) {
281
+ const rec = asRecord(val);
282
+ const cmd = redactMcpCommand(asNonEmptyString(rec?.command) ?? (typeof val === "string" ? val : undefined));
283
+ hooks.push({
284
+ event,
285
+ ...(cmd ? { command: cmd } : {}),
286
+ enabled: rec?.enabled !== false,
287
+ source_path: layer.path,
288
+ });
289
+ }
290
+ }
291
+ const loadedBytes = instructionChain.reduce((sum, entry) => sum + entry.included_bytes, 0);
292
+ const truncatedCount = instructionChain.filter((e) => e.status === "truncated").length;
293
+ const exhaustedCount = instructionChain.filter((e) => e.status === "budget_exhausted").length;
294
+ const native = {
295
+ client: "codex",
296
+ codex_home: codexHome,
297
+ config_cascade: {
298
+ global_config_path: globalConfig ? globalConfigPath : null,
299
+ project_config_path: projectConfigPath,
300
+ project_trust_level: projectTrustLevel,
301
+ project_config_trusted: projectTrusted,
302
+ ...(effectiveModel ? { effective_model: effectiveModel } : {}),
303
+ ...(reasoningEffort ? { model_reasoning_effort: reasoningEffort } : {}),
304
+ ...(approvalPolicy ? { approval_policy: approvalPolicy } : {}),
305
+ ...(sandboxMode ? { sandbox_mode: sandboxMode } : {}),
306
+ project_doc_max_bytes: projectDocMaxBytes,
307
+ project_doc_fallback_filenames: fallbackFilenames,
308
+ ...(activeProfile ? { active_profile: activeProfile } : {}),
309
+ profiles: [...profileNames].sort(),
310
+ },
311
+ instruction_chain: instructionChain,
312
+ mcp_servers: mcpServers,
313
+ agents,
314
+ skills,
315
+ hooks,
316
+ startup_footprint: {
317
+ loaded_bytes: loadedBytes,
318
+ budget_bytes: projectDocMaxBytes,
319
+ budget_used_ratio: projectDocMaxBytes > 0 ? Number((loadedBytes / projectDocMaxBytes).toFixed(4)) : 0,
320
+ estimated_tokens: estimateTokens(loadedBytes),
321
+ truncated_file_count: truncatedCount,
322
+ budget_exhausted_file_count: exhaustedCount,
323
+ },
324
+ };
325
+ return {
326
+ client: "codex",
327
+ display_name: "Codex",
328
+ resolution_tier: "native",
329
+ project_dir: input.projectDir,
330
+ git_root: input.gitRoot,
331
+ files_read: tracker.filesRead,
332
+ mcp_servers: mcpServers.filter((m) => m.status === "effective").map(stripMcpResolutionFields),
333
+ diagnostics: tracker.diagnostics,
334
+ native,
335
+ };
336
+ }
337
+ function resolveCodexTrustLevel(globalConfig, projectDir, gitRoot) {
338
+ const projects = asRecord(globalConfig?.projects);
339
+ if (!projects || !projectDir)
340
+ return null;
341
+ const candidates = [projectDir, ...(gitRoot ? [gitRoot] : [])].map(normalizeComparablePath);
342
+ for (const target of candidates) {
343
+ for (const [key, val] of Object.entries(projects)) {
344
+ if (normalizeComparablePath(key) !== target)
345
+ continue;
346
+ const trust = asNonEmptyString(asRecord(val)?.trust_level);
347
+ if (trust)
348
+ return trust;
349
+ }
350
+ }
351
+ return null;
352
+ }
353
+ async function collectCodexAgentFiles(tracker, dirPath, scope, out) {
354
+ const entries = await safeReadDir(tracker, dirPath);
355
+ for (const entry of entries) {
356
+ if (entry.name.startsWith(".") || !entry.isFile())
357
+ continue;
358
+ const fullPath = path.join(dirPath, entry.name);
359
+ const name = entry.name.replace(/\.(?:toml|md|json)$/iu, "");
360
+ out.push({ name, source: "file", scope, path: fullPath });
361
+ }
362
+ }
363
+ //# sourceMappingURL=codex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codex.js","sourceRoot":"","sources":["../../../src/inventory/startup/codex.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,IAAI,MAAM,WAAW,CAAC;AAQ7B,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EACL,gBAAgB,EAChB,QAAQ,EACR,qBAAqB,EACrB,iBAAiB,EACjB,cA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AK,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC;YAClD,IAAI,uBAAuB,CAAC,GAAG,CAAC,KAAK,MAAM;gBAAE,SAAS;YACtD,MAAM,KAAK,GAAG,gBAAgB,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,WAAW,CAAC,CAAC;YAC3D,IAAI,KAAK;gBAAE,OAAO,KAAK,CAAC;QAC1B,CAAC;IACH,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,KAAK,UAAU,sBAAsB,CACnC,OAA2B,EAC3B,OAAe,EACf,KAAyB,EACzB,GAAkC;IAElC,MAAM,OAAO,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IACpD,KAAK,MAAM,KAAK,IAAI,OAAO,EAAE,CAAC;QAC5B,IAAI,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE;YAAE,SAAS;QAC5D,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;QAChD,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,uBAAuB,EAAE,EAAE,CAAC,CAAC;QAC7D,GAAG,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC;IAC5D,CAAC;AACH,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Role: Native pre-launch startup context resolver for DeepSeek Harness (`dsh`).
3
+ * Resolves `$DSH_HOME` (default `~/.dsh`), profile directories (`profiles/<name>/`),
4
+ * Cordis YAML layers (`cordis.yml`, `cordis.patch.yml`, `settings.yaml`), legacy configs,
5
+ * `@deepseek-ai/dsh-mcp-client` YAML MCP declarations (strictly redacted), `AGENTS.md`
6
+ * instructions, skills, subagents, and plugins.
7
+ * Security boundary: `.credentials.yaml` is checked for existence only and NEVER read.
8
+ * Excludes history correlation, CLI formatting, and secret value retention.
9
+ */
10
+ import type { AgentStartupResolution, ResolvedMcpServerState } from "@cchistory/domain";
11
+ import { type NativeStartupResolverInput } from "./shared.js";
12
+ export declare function resolveDeepSeekHarnessStartup(input: NativeStartupResolverInput): Promise<AgentStartupResolution>;
13
+ /**
14
+ * Zero-dep indentation-based YAML extractor for Cordis `@deepseek-ai/dsh-mcp-client`
15
+ * plugin blocks and top-level `mcpServers` / `mcp_servers` maps.
16
+ * Extracts only structural fields (`serverName`, `transport`, `command`, `args`, `url`,
17
+ * `enabled`/`disabled`) and key names of `env`/`headers` — never secret values.
18
+ */
19
+ export declare function extractCordisYamlMcp(yamlContent: string, layerName: string, scope: "user" | "project", sourcePath: string, mcpById: Map<string, ResolvedMcpServerState>, mcpHistory: ResolvedMcpServerState[]): void;
20
+ //# sourceMappingURL=deepseek-harness.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deepseek-harness.d.ts","sourceRoot":"","sources":["../../../src/inventory/startup/deepseek-harness.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,KAAK,EACV,sBAAsB,EAGtB,sBAAsB,EACvB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAYL,KAAK,0BAA0B,EAEhC,MAAM,aAAa,CAAC;AAMrB,wBAAsB,6BAA6B,CACjD,KAAK,EAAE,0BAA0B,GAChC,OAAO,CAAC,sBAAsB,CAAC,CAoKjC;AA2DD;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,MAAM,EACnB,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,MAAM,GAAG,SAAS,EACzB,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,sBAAsB,CAAC,EAC5C,UAAU,EAAE,sBAAsB,EAAE,GACnC,IAAI,CAkEN"}