@alan512/experienceengine 0.1.3 → 0.2.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 (605) hide show
  1. package/.claude-plugin/marketplace.json +0 -0
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/.env.example +0 -0
  4. package/.mcp.json +0 -0
  5. package/LICENSE +0 -0
  6. package/README.md +196 -114
  7. package/README.zh-CN.md +230 -100
  8. package/dist/adapters/claude-code/event-store.d.ts +0 -0
  9. package/dist/adapters/claude-code/event-store.js +0 -0
  10. package/dist/adapters/claude-code/event-store.js.map +0 -0
  11. package/dist/adapters/claude-code/hook-normalizer.d.ts +0 -0
  12. package/dist/adapters/claude-code/hook-normalizer.js +0 -0
  13. package/dist/adapters/claude-code/hook-normalizer.js.map +0 -0
  14. package/dist/adapters/claude-code/runtime-projection.d.ts +0 -0
  15. package/dist/adapters/claude-code/runtime-projection.js +0 -0
  16. package/dist/adapters/claude-code/runtime-projection.js.map +0 -0
  17. package/dist/adapters/claude-code/session-store.d.ts +1 -0
  18. package/dist/adapters/claude-code/session-store.js +24 -1
  19. package/dist/adapters/claude-code/session-store.js.map +1 -1
  20. package/dist/adapters/codex/action-registry.d.ts +84 -0
  21. package/dist/adapters/codex/action-registry.js +277 -0
  22. package/dist/adapters/codex/action-registry.js.map +1 -0
  23. package/dist/adapters/codex/broker-tools.d.ts +114 -0
  24. package/dist/adapters/codex/broker-tools.js +130 -0
  25. package/dist/adapters/codex/broker-tools.js.map +1 -0
  26. package/dist/adapters/codex/instruction-template.d.ts +0 -0
  27. package/dist/adapters/codex/instruction-template.js +0 -0
  28. package/dist/adapters/codex/instruction-template.js.map +0 -0
  29. package/dist/adapters/codex/mcp-server.d.ts +21 -0
  30. package/dist/adapters/codex/mcp-server.js +103 -423
  31. package/dist/adapters/codex/mcp-server.js.map +1 -1
  32. package/dist/analyzer/candidate-signals.d.ts +3 -1
  33. package/dist/analyzer/candidate-signals.js +159 -0
  34. package/dist/analyzer/candidate-signals.js.map +1 -1
  35. package/dist/analyzer/experience-analyzer.d.ts +0 -0
  36. package/dist/analyzer/experience-analyzer.js +0 -0
  37. package/dist/analyzer/experience-analyzer.js.map +0 -0
  38. package/dist/analyzer/extraction-evidence.d.ts +0 -0
  39. package/dist/analyzer/extraction-evidence.js +0 -0
  40. package/dist/analyzer/extraction-evidence.js.map +0 -0
  41. package/dist/analyzer/llm-learning-gate.d.ts +12 -1
  42. package/dist/analyzer/llm-learning-gate.js +633 -16
  43. package/dist/analyzer/llm-learning-gate.js.map +1 -1
  44. package/dist/analyzer/node-deduper.d.ts +0 -0
  45. package/dist/analyzer/node-deduper.js +0 -0
  46. package/dist/analyzer/node-deduper.js.map +0 -0
  47. package/dist/analyzer/node-normalizer.d.ts +0 -0
  48. package/dist/analyzer/node-normalizer.js +0 -0
  49. package/dist/analyzer/node-normalizer.js.map +0 -0
  50. package/dist/analyzer/storage-gate.d.ts +0 -0
  51. package/dist/analyzer/storage-gate.js +0 -0
  52. package/dist/analyzer/storage-gate.js.map +0 -0
  53. package/dist/analyzer/strategy-extractor.d.ts +0 -0
  54. package/dist/analyzer/strategy-extractor.js +0 -0
  55. package/dist/analyzer/strategy-extractor.js.map +0 -0
  56. package/dist/analyzer/warning-extractor.d.ts +0 -0
  57. package/dist/analyzer/warning-extractor.js +0 -0
  58. package/dist/analyzer/warning-extractor.js.map +0 -0
  59. package/dist/cli/commands/backup.d.ts +0 -0
  60. package/dist/cli/commands/backup.js +0 -0
  61. package/dist/cli/commands/backup.js.map +0 -0
  62. package/dist/cli/commands/claude-hook.d.ts +0 -0
  63. package/dist/cli/commands/claude-hook.js +11 -4
  64. package/dist/cli/commands/claude-hook.js.map +1 -1
  65. package/dist/cli/commands/codex-mcp-server.d.ts +0 -0
  66. package/dist/cli/commands/codex-mcp-server.js +0 -0
  67. package/dist/cli/commands/codex-mcp-server.js.map +0 -0
  68. package/dist/cli/commands/codex.d.ts +60 -0
  69. package/dist/cli/commands/codex.js +188 -0
  70. package/dist/cli/commands/codex.js.map +1 -0
  71. package/dist/cli/commands/config.d.ts +0 -0
  72. package/dist/cli/commands/config.js +0 -0
  73. package/dist/cli/commands/config.js.map +0 -0
  74. package/dist/cli/commands/cool.d.ts +0 -0
  75. package/dist/cli/commands/cool.js +0 -0
  76. package/dist/cli/commands/cool.js.map +0 -0
  77. package/dist/cli/commands/disable.d.ts +0 -0
  78. package/dist/cli/commands/disable.js +0 -0
  79. package/dist/cli/commands/disable.js.map +0 -0
  80. package/dist/cli/commands/doctor.d.ts +0 -0
  81. package/dist/cli/commands/doctor.js +20 -0
  82. package/dist/cli/commands/doctor.js.map +1 -1
  83. package/dist/cli/commands/enable.d.ts +0 -0
  84. package/dist/cli/commands/enable.js +0 -0
  85. package/dist/cli/commands/enable.js.map +0 -0
  86. package/dist/cli/commands/evaluate.d.ts +9 -3
  87. package/dist/cli/commands/evaluate.js +31 -5
  88. package/dist/cli/commands/evaluate.js.map +1 -1
  89. package/dist/cli/commands/export.d.ts +0 -0
  90. package/dist/cli/commands/export.js +0 -0
  91. package/dist/cli/commands/export.js.map +0 -0
  92. package/dist/cli/commands/feedback.d.ts +0 -0
  93. package/dist/cli/commands/feedback.js +0 -0
  94. package/dist/cli/commands/feedback.js.map +0 -0
  95. package/dist/cli/commands/import.d.ts +0 -0
  96. package/dist/cli/commands/import.js +0 -0
  97. package/dist/cli/commands/import.js.map +0 -0
  98. package/dist/cli/commands/init.d.ts +0 -0
  99. package/dist/cli/commands/init.js +21 -8
  100. package/dist/cli/commands/init.js.map +1 -1
  101. package/dist/cli/commands/inspect.d.ts +0 -0
  102. package/dist/cli/commands/inspect.js +69 -1
  103. package/dist/cli/commands/inspect.js.map +1 -1
  104. package/dist/cli/commands/install.d.ts +0 -0
  105. package/dist/cli/commands/install.js +0 -0
  106. package/dist/cli/commands/install.js.map +0 -0
  107. package/dist/cli/commands/maintenance.d.ts +0 -0
  108. package/dist/cli/commands/maintenance.js +0 -0
  109. package/dist/cli/commands/maintenance.js.map +0 -0
  110. package/dist/cli/commands/mcp-server.d.ts +0 -0
  111. package/dist/cli/commands/mcp-server.js +0 -0
  112. package/dist/cli/commands/mcp-server.js.map +0 -0
  113. package/dist/cli/commands/models.d.ts +0 -0
  114. package/dist/cli/commands/models.js +0 -0
  115. package/dist/cli/commands/models.js.map +0 -0
  116. package/dist/cli/commands/repair.d.ts +0 -0
  117. package/dist/cli/commands/repair.js +3 -3
  118. package/dist/cli/commands/repair.js.map +1 -1
  119. package/dist/cli/commands/retire.d.ts +0 -0
  120. package/dist/cli/commands/retire.js +0 -0
  121. package/dist/cli/commands/retire.js.map +0 -0
  122. package/dist/cli/commands/rollback.d.ts +0 -0
  123. package/dist/cli/commands/rollback.js +0 -0
  124. package/dist/cli/commands/rollback.js.map +0 -0
  125. package/dist/cli/commands/stats.d.ts +0 -0
  126. package/dist/cli/commands/stats.js +0 -0
  127. package/dist/cli/commands/stats.js.map +0 -0
  128. package/dist/cli/commands/status.d.ts +0 -0
  129. package/dist/cli/commands/status.js +32 -0
  130. package/dist/cli/commands/status.js.map +1 -1
  131. package/dist/cli/commands/upgrade.d.ts +0 -0
  132. package/dist/cli/commands/upgrade.js +0 -0
  133. package/dist/cli/commands/upgrade.js.map +0 -0
  134. package/dist/cli/dispatch.d.ts +0 -0
  135. package/dist/cli/dispatch.js +16 -4
  136. package/dist/cli/dispatch.js.map +1 -1
  137. package/dist/cli/index.d.ts +0 -0
  138. package/dist/cli/index.js.map +0 -0
  139. package/dist/cli/state-model.d.ts +0 -0
  140. package/dist/cli/state-model.js +0 -0
  141. package/dist/cli/state-model.js.map +0 -0
  142. package/dist/config/config-schema.d.ts +177 -0
  143. package/dist/config/config-schema.js +142 -1
  144. package/dist/config/config-schema.js.map +1 -1
  145. package/dist/config/default-config.d.ts +0 -0
  146. package/dist/config/default-config.js +19 -1
  147. package/dist/config/default-config.js.map +1 -1
  148. package/dist/config/load-config.d.ts +0 -0
  149. package/dist/config/load-config.js +72 -1
  150. package/dist/config/load-config.js.map +1 -1
  151. package/dist/config/path-resolver.d.ts +0 -0
  152. package/dist/config/path-resolver.js +0 -0
  153. package/dist/config/path-resolver.js.map +0 -0
  154. package/dist/config/runtime-env.d.ts +0 -0
  155. package/dist/config/runtime-env.js +0 -0
  156. package/dist/config/runtime-env.js.map +0 -0
  157. package/dist/config/secrets-store.d.ts +0 -0
  158. package/dist/config/secrets-store.js +0 -0
  159. package/dist/config/secrets-store.js.map +0 -0
  160. package/dist/config/settings-store.d.ts +19 -0
  161. package/dist/config/settings-store.js +11 -0
  162. package/dist/config/settings-store.js.map +1 -1
  163. package/dist/controller/candidate-retriever.d.ts +15 -1
  164. package/dist/controller/candidate-retriever.js +91 -137
  165. package/dist/controller/candidate-retriever.js.map +1 -1
  166. package/dist/controller/injection-renderer.d.ts +0 -0
  167. package/dist/controller/injection-renderer.js +0 -0
  168. package/dist/controller/injection-renderer.js.map +0 -0
  169. package/dist/controller/injection-scorecard.d.ts +2 -14
  170. package/dist/controller/injection-scorecard.js +29 -0
  171. package/dist/controller/injection-scorecard.js.map +1 -1
  172. package/dist/controller/inline-notice.d.ts +0 -0
  173. package/dist/controller/inline-notice.js +0 -0
  174. package/dist/controller/inline-notice.js.map +0 -0
  175. package/dist/controller/intervention-controller.d.ts +3 -15
  176. package/dist/controller/intervention-controller.js +217 -57
  177. package/dist/controller/intervention-controller.js.map +1 -1
  178. package/dist/controller/lexical-retriever.d.ts +0 -0
  179. package/dist/controller/lexical-retriever.js +0 -0
  180. package/dist/controller/lexical-retriever.js.map +0 -0
  181. package/dist/controller/model-reranker.d.ts +0 -0
  182. package/dist/controller/model-reranker.js +0 -0
  183. package/dist/controller/model-reranker.js.map +0 -0
  184. package/dist/controller/node-ranker.d.ts +0 -0
  185. package/dist/controller/node-ranker.js +0 -0
  186. package/dist/controller/node-ranker.js.map +0 -0
  187. package/dist/controller/policy-enricher.d.ts +10 -0
  188. package/dist/controller/policy-enricher.js +186 -0
  189. package/dist/controller/policy-enricher.js.map +1 -0
  190. package/dist/controller/query-rewrite.d.ts +0 -0
  191. package/dist/controller/query-rewrite.js +0 -0
  192. package/dist/controller/query-rewrite.js.map +0 -0
  193. package/dist/controller/retrieval-context.d.ts +3 -0
  194. package/dist/controller/retrieval-context.js +37 -0
  195. package/dist/controller/retrieval-context.js.map +1 -0
  196. package/dist/controller/second-opinion-gate.d.ts +41 -0
  197. package/dist/controller/second-opinion-gate.js +225 -0
  198. package/dist/controller/second-opinion-gate.js.map +1 -0
  199. package/dist/controller/trigger-evaluator.d.ts +4 -0
  200. package/dist/controller/trigger-evaluator.js +8 -2
  201. package/dist/controller/trigger-evaluator.js.map +1 -1
  202. package/dist/distillation/errors.d.ts +0 -0
  203. package/dist/distillation/errors.js +0 -0
  204. package/dist/distillation/errors.js.map +0 -0
  205. package/dist/distillation/experience-family.d.ts +0 -0
  206. package/dist/distillation/experience-family.js +0 -0
  207. package/dist/distillation/experience-family.js.map +0 -0
  208. package/dist/distillation/host-llm.d.ts +0 -0
  209. package/dist/distillation/host-llm.js +0 -0
  210. package/dist/distillation/host-llm.js.map +0 -0
  211. package/dist/distillation/llm-distiller.d.ts +0 -0
  212. package/dist/distillation/llm-distiller.js +0 -0
  213. package/dist/distillation/llm-distiller.js.map +0 -0
  214. package/dist/distillation/merge-decider.d.ts +0 -0
  215. package/dist/distillation/merge-decider.js +0 -0
  216. package/dist/distillation/merge-decider.js.map +0 -0
  217. package/dist/distillation/model-catalog.d.ts +0 -0
  218. package/dist/distillation/model-catalog.js +0 -0
  219. package/dist/distillation/model-catalog.js.map +0 -0
  220. package/dist/distillation/prompt-contract.d.ts +1 -1
  221. package/dist/distillation/prompt-contract.js +3 -1
  222. package/dist/distillation/prompt-contract.js.map +1 -1
  223. package/dist/distillation/providers/anthropic.d.ts +0 -0
  224. package/dist/distillation/providers/anthropic.js +0 -0
  225. package/dist/distillation/providers/anthropic.js.map +0 -0
  226. package/dist/distillation/providers/azure-openai.d.ts +0 -0
  227. package/dist/distillation/providers/azure-openai.js +0 -0
  228. package/dist/distillation/providers/azure-openai.js.map +0 -0
  229. package/dist/distillation/providers/baidu-qianfan.d.ts +0 -0
  230. package/dist/distillation/providers/baidu-qianfan.js +0 -0
  231. package/dist/distillation/providers/baidu-qianfan.js.map +0 -0
  232. package/dist/distillation/providers/bedrock.d.ts +0 -0
  233. package/dist/distillation/providers/bedrock.js +0 -0
  234. package/dist/distillation/providers/bedrock.js.map +0 -0
  235. package/dist/distillation/providers/dashscope.d.ts +0 -0
  236. package/dist/distillation/providers/dashscope.js +0 -0
  237. package/dist/distillation/providers/dashscope.js.map +0 -0
  238. package/dist/distillation/providers/deepseek.d.ts +0 -0
  239. package/dist/distillation/providers/deepseek.js +0 -0
  240. package/dist/distillation/providers/deepseek.js.map +0 -0
  241. package/dist/distillation/providers/gemini.d.ts +0 -0
  242. package/dist/distillation/providers/gemini.js +5 -1
  243. package/dist/distillation/providers/gemini.js.map +1 -1
  244. package/dist/distillation/providers/google-adc.d.ts +0 -0
  245. package/dist/distillation/providers/google-adc.js +0 -0
  246. package/dist/distillation/providers/google-adc.js.map +0 -0
  247. package/dist/distillation/providers/minimax.d.ts +0 -0
  248. package/dist/distillation/providers/minimax.js +0 -0
  249. package/dist/distillation/providers/minimax.js.map +0 -0
  250. package/dist/distillation/providers/moonshot.d.ts +0 -0
  251. package/dist/distillation/providers/moonshot.js +0 -0
  252. package/dist/distillation/providers/moonshot.js.map +0 -0
  253. package/dist/distillation/providers/openai-compatible-factory.d.ts +0 -0
  254. package/dist/distillation/providers/openai-compatible-factory.js +0 -0
  255. package/dist/distillation/providers/openai-compatible-factory.js.map +0 -0
  256. package/dist/distillation/providers/openai-compatible.d.ts +0 -0
  257. package/dist/distillation/providers/openai-compatible.js +0 -0
  258. package/dist/distillation/providers/openai-compatible.js.map +0 -0
  259. package/dist/distillation/providers/openai.d.ts +0 -0
  260. package/dist/distillation/providers/openai.js +0 -0
  261. package/dist/distillation/providers/openai.js.map +0 -0
  262. package/dist/distillation/providers/openrouter.d.ts +0 -0
  263. package/dist/distillation/providers/openrouter.js +0 -0
  264. package/dist/distillation/providers/openrouter.js.map +0 -0
  265. package/dist/distillation/providers/registry.d.ts +0 -0
  266. package/dist/distillation/providers/registry.js +0 -0
  267. package/dist/distillation/providers/registry.js.map +0 -0
  268. package/dist/distillation/providers/siliconflow.d.ts +0 -0
  269. package/dist/distillation/providers/siliconflow.js +0 -0
  270. package/dist/distillation/providers/siliconflow.js.map +0 -0
  271. package/dist/distillation/providers/tencent-hunyuan.d.ts +0 -0
  272. package/dist/distillation/providers/tencent-hunyuan.js +0 -0
  273. package/dist/distillation/providers/tencent-hunyuan.js.map +0 -0
  274. package/dist/distillation/providers/types.d.ts +0 -0
  275. package/dist/distillation/providers/types.js +0 -0
  276. package/dist/distillation/providers/types.js.map +0 -0
  277. package/dist/distillation/providers/volcengine-ark.d.ts +0 -0
  278. package/dist/distillation/providers/volcengine-ark.js +0 -0
  279. package/dist/distillation/providers/volcengine-ark.js.map +0 -0
  280. package/dist/distillation/providers/zhipu.d.ts +0 -0
  281. package/dist/distillation/providers/zhipu.js +0 -0
  282. package/dist/distillation/providers/zhipu.js.map +0 -0
  283. package/dist/distillation/queue-worker.d.ts +0 -0
  284. package/dist/distillation/queue-worker.js +22 -3
  285. package/dist/distillation/queue-worker.js.map +1 -1
  286. package/dist/distillation/types.d.ts +0 -0
  287. package/dist/distillation/types.js +0 -0
  288. package/dist/distillation/types.js.map +0 -0
  289. package/dist/evaluation/benchmark-report.d.ts +0 -0
  290. package/dist/evaluation/benchmark-report.js +0 -0
  291. package/dist/evaluation/benchmark-report.js.map +0 -0
  292. package/dist/evaluation/benchmark-summary.d.ts +0 -0
  293. package/dist/evaluation/benchmark-summary.js +0 -0
  294. package/dist/evaluation/benchmark-summary.js.map +0 -0
  295. package/dist/evaluation/codex-lifecycle-validation.d.ts +60 -0
  296. package/dist/evaluation/codex-lifecycle-validation.js +233 -0
  297. package/dist/evaluation/codex-lifecycle-validation.js.map +1 -0
  298. package/dist/evaluation/hybrid-phase1-rollout-summary.d.ts +63 -0
  299. package/dist/evaluation/hybrid-phase1-rollout-summary.js +108 -0
  300. package/dist/evaluation/hybrid-phase1-rollout-summary.js.map +1 -0
  301. package/dist/evaluation/hybrid-phase3-gate-metrics.d.ts +26 -0
  302. package/dist/evaluation/hybrid-phase3-gate-metrics.js +23 -0
  303. package/dist/evaluation/hybrid-phase3-gate-metrics.js.map +1 -0
  304. package/dist/evaluation/openclaw-baseline.d.ts +8 -0
  305. package/dist/evaluation/openclaw-baseline.js +27 -0
  306. package/dist/evaluation/openclaw-baseline.js.map +1 -1
  307. package/dist/evaluation/openclaw-scenarios.d.ts +0 -0
  308. package/dist/evaluation/openclaw-scenarios.js +0 -0
  309. package/dist/evaluation/openclaw-scenarios.js.map +0 -0
  310. package/dist/experience-management/governance-observability.d.ts +13 -0
  311. package/dist/experience-management/governance-observability.js +37 -0
  312. package/dist/experience-management/governance-observability.js.map +1 -0
  313. package/dist/experience-management/node-lifecycle-governance.d.ts +8 -0
  314. package/dist/experience-management/node-lifecycle-governance.js +80 -0
  315. package/dist/experience-management/node-lifecycle-governance.js.map +1 -0
  316. package/dist/experience-management/task-management-signals.d.ts +29 -0
  317. package/dist/experience-management/task-management-signals.js +148 -0
  318. package/dist/experience-management/task-management-signals.js.map +1 -0
  319. package/dist/feedback/automatic-attribution.d.ts +0 -0
  320. package/dist/feedback/automatic-attribution.js +0 -0
  321. package/dist/feedback/automatic-attribution.js.map +0 -0
  322. package/dist/feedback/feedback-manager.d.ts +4 -1
  323. package/dist/feedback/feedback-manager.js +11 -22
  324. package/dist/feedback/feedback-manager.js.map +1 -1
  325. package/dist/feedback/harm-detector.d.ts +0 -0
  326. package/dist/feedback/harm-detector.js +0 -0
  327. package/dist/feedback/harm-detector.js.map +0 -0
  328. package/dist/feedback/state-transition.d.ts +6 -1
  329. package/dist/feedback/state-transition.js +6 -3
  330. package/dist/feedback/state-transition.js.map +1 -1
  331. package/dist/feedback/stats-updater.d.ts +0 -0
  332. package/dist/feedback/stats-updater.js +0 -0
  333. package/dist/feedback/stats-updater.js.map +0 -0
  334. package/dist/hybrid/capsule-builder.d.ts +23 -0
  335. package/dist/hybrid/capsule-builder.js +114 -0
  336. package/dist/hybrid/capsule-builder.js.map +1 -0
  337. package/dist/hybrid/explain-provider-client.d.ts +19 -0
  338. package/dist/hybrid/explain-provider-client.js +34 -0
  339. package/dist/hybrid/explain-provider-client.js.map +1 -0
  340. package/dist/hybrid/postmortem-provider-client.d.ts +19 -0
  341. package/dist/hybrid/postmortem-provider-client.js +34 -0
  342. package/dist/hybrid/postmortem-provider-client.js.map +1 -0
  343. package/dist/hybrid/rollout.d.ts +9 -0
  344. package/dist/hybrid/rollout.js +49 -0
  345. package/dist/hybrid/rollout.js.map +1 -0
  346. package/dist/hybrid/router.d.ts +4 -0
  347. package/dist/hybrid/router.js +62 -0
  348. package/dist/hybrid/router.js.map +1 -0
  349. package/dist/hybrid/types.d.ts +140 -0
  350. package/dist/hybrid/types.js +2 -0
  351. package/dist/hybrid/types.js.map +1 -0
  352. package/dist/hybrid/validators.d.ts +5 -0
  353. package/dist/hybrid/validators.js +94 -0
  354. package/dist/hybrid/validators.js.map +1 -0
  355. package/dist/hybrid/worker-client.d.ts +61 -0
  356. package/dist/hybrid/worker-client.js +196 -0
  357. package/dist/hybrid/worker-client.js.map +1 -0
  358. package/dist/hybrid/workers/explain-decision-llm.d.ts +8 -0
  359. package/dist/hybrid/workers/explain-decision-llm.js +152 -0
  360. package/dist/hybrid/workers/explain-decision-llm.js.map +1 -0
  361. package/dist/hybrid/workers/explain-decision.d.ts +2 -0
  362. package/dist/hybrid/workers/explain-decision.js +40 -0
  363. package/dist/hybrid/workers/explain-decision.js.map +1 -0
  364. package/dist/hybrid/workers/postmortem-review-llm.d.ts +8 -0
  365. package/dist/hybrid/workers/postmortem-review-llm.js +398 -0
  366. package/dist/hybrid/workers/postmortem-review-llm.js.map +1 -0
  367. package/dist/hybrid/workers/postmortem-review.d.ts +2 -0
  368. package/dist/hybrid/workers/postmortem-review.js +66 -0
  369. package/dist/hybrid/workers/postmortem-review.js.map +1 -0
  370. package/dist/index.d.ts +0 -0
  371. package/dist/index.js +0 -0
  372. package/dist/index.js.map +0 -0
  373. package/dist/input/context-summary-adapter.d.ts +0 -0
  374. package/dist/input/context-summary-adapter.js +0 -0
  375. package/dist/input/context-summary-adapter.js.map +0 -0
  376. package/dist/input/input-adapter.d.ts +0 -0
  377. package/dist/input/input-adapter.js +0 -0
  378. package/dist/input/input-adapter.js.map +0 -0
  379. package/dist/input/outcome-resolver.d.ts +0 -0
  380. package/dist/input/outcome-resolver.js +0 -0
  381. package/dist/input/outcome-resolver.js.map +0 -0
  382. package/dist/input/scope-resolver.d.ts +0 -0
  383. package/dist/input/scope-resolver.js +0 -0
  384. package/dist/input/scope-resolver.js.map +0 -0
  385. package/dist/input/tasktype-resolver.d.ts +0 -0
  386. package/dist/input/tasktype-resolver.js +0 -0
  387. package/dist/input/tasktype-resolver.js.map +0 -0
  388. package/dist/input/tool-event-significance.d.ts +0 -0
  389. package/dist/input/tool-event-significance.js +0 -0
  390. package/dist/input/tool-event-significance.js.map +0 -0
  391. package/dist/install/claude-cli.d.ts +0 -0
  392. package/dist/install/claude-cli.js +0 -0
  393. package/dist/install/claude-cli.js.map +0 -0
  394. package/dist/install/claude-code-doctor.d.ts +1 -0
  395. package/dist/install/claude-code-doctor.js +20 -4
  396. package/dist/install/claude-code-doctor.js.map +1 -1
  397. package/dist/install/claude-code-installer.d.ts +0 -0
  398. package/dist/install/claude-code-installer.js +50 -1
  399. package/dist/install/claude-code-installer.js.map +1 -1
  400. package/dist/install/claude-marketplace-state.d.ts +0 -0
  401. package/dist/install/claude-marketplace-state.js +0 -0
  402. package/dist/install/claude-marketplace-state.js.map +0 -0
  403. package/dist/install/claude-runtime-target.d.ts +0 -0
  404. package/dist/install/claude-runtime-target.js +0 -0
  405. package/dist/install/claude-runtime-target.js.map +0 -0
  406. package/dist/install/codex-cli.d.ts +15 -0
  407. package/dist/install/codex-cli.js +55 -3
  408. package/dist/install/codex-cli.js.map +1 -1
  409. package/dist/install/codex-installer.d.ts +0 -0
  410. package/dist/install/codex-installer.js +0 -0
  411. package/dist/install/codex-installer.js.map +0 -0
  412. package/dist/install/codex-runtime-target.d.ts +0 -0
  413. package/dist/install/codex-runtime-target.js +0 -0
  414. package/dist/install/codex-runtime-target.js.map +0 -0
  415. package/dist/install/host-detection.d.ts +0 -0
  416. package/dist/install/host-detection.js +0 -0
  417. package/dist/install/host-detection.js.map +0 -0
  418. package/dist/install/openclaw-cli.d.ts +11 -0
  419. package/dist/install/openclaw-cli.js +0 -0
  420. package/dist/install/openclaw-cli.js.map +1 -1
  421. package/dist/install/openclaw-installer.d.ts +12 -7
  422. package/dist/install/openclaw-installer.js +197 -46
  423. package/dist/install/openclaw-installer.js.map +1 -1
  424. package/dist/install/public-install.d.ts +0 -0
  425. package/dist/install/public-install.js +0 -0
  426. package/dist/install/public-install.js.map +0 -0
  427. package/dist/install/registry-health.d.ts +0 -0
  428. package/dist/install/registry-health.js +0 -0
  429. package/dist/install/registry-health.js.map +0 -0
  430. package/dist/interaction/operational-actions-service.d.ts +0 -0
  431. package/dist/interaction/operational-actions-service.js +0 -0
  432. package/dist/interaction/operational-actions-service.js.map +0 -0
  433. package/dist/interaction/operational-service.d.ts +0 -0
  434. package/dist/interaction/operational-service.js +0 -0
  435. package/dist/interaction/operational-service.js.map +0 -0
  436. package/dist/interaction/repo-summary.d.ts +0 -0
  437. package/dist/interaction/repo-summary.js +0 -0
  438. package/dist/interaction/repo-summary.js.map +0 -0
  439. package/dist/interaction/service.d.ts +15 -0
  440. package/dist/interaction/service.js +174 -20
  441. package/dist/interaction/service.js.map +1 -1
  442. package/dist/interaction/state-artifact-service.d.ts +0 -0
  443. package/dist/interaction/state-artifact-service.js +0 -0
  444. package/dist/interaction/state-artifact-service.js.map +0 -0
  445. package/dist/maintenance/claude-validate-print.d.ts +0 -0
  446. package/dist/maintenance/claude-validate-print.js +0 -0
  447. package/dist/maintenance/claude-validate-print.js.map +0 -0
  448. package/dist/maintenance/embedding-smoke.d.ts +0 -0
  449. package/dist/maintenance/embedding-smoke.js +0 -0
  450. package/dist/maintenance/embedding-smoke.js.map +0 -0
  451. package/dist/maintenance/redistill-rule-nodes.d.ts +0 -0
  452. package/dist/maintenance/redistill-rule-nodes.js +0 -0
  453. package/dist/maintenance/redistill-rule-nodes.js.map +0 -0
  454. package/dist/maintenance/scope-merge.d.ts +0 -0
  455. package/dist/maintenance/scope-merge.js +0 -0
  456. package/dist/maintenance/scope-merge.js.map +0 -0
  457. package/dist/maintenance/warning-variant-cleanup.d.ts +0 -0
  458. package/dist/maintenance/warning-variant-cleanup.js +0 -0
  459. package/dist/maintenance/warning-variant-cleanup.js.map +0 -0
  460. package/dist/plugin/fixture-sanitizer.d.ts +0 -0
  461. package/dist/plugin/fixture-sanitizer.js +0 -0
  462. package/dist/plugin/fixture-sanitizer.js.map +0 -0
  463. package/dist/plugin/hooks/before-prompt-build.d.ts +1 -0
  464. package/dist/plugin/hooks/before-prompt-build.js +4 -1
  465. package/dist/plugin/hooks/before-prompt-build.js.map +1 -1
  466. package/dist/plugin/hooks/message-sent.d.ts +0 -0
  467. package/dist/plugin/hooks/message-sent.js +0 -0
  468. package/dist/plugin/hooks/message-sent.js.map +0 -0
  469. package/dist/plugin/hooks/tool-result-persist.d.ts +0 -0
  470. package/dist/plugin/hooks/tool-result-persist.js +0 -0
  471. package/dist/plugin/hooks/tool-result-persist.js.map +0 -0
  472. package/dist/plugin/openclaw-install-state.d.ts +39 -0
  473. package/dist/plugin/openclaw-install-state.js +24 -0
  474. package/dist/plugin/openclaw-install-state.js.map +1 -0
  475. package/dist/plugin/openclaw-plugin.d.ts +125 -0
  476. package/dist/plugin/openclaw-plugin.js +18 -7
  477. package/dist/plugin/openclaw-plugin.js.map +1 -1
  478. package/dist/plugin/openclaw-routine-interaction.d.ts +2 -1
  479. package/dist/plugin/openclaw-routine-interaction.js +12 -7
  480. package/dist/plugin/openclaw-routine-interaction.js.map +1 -1
  481. package/dist/plugin/openclaw-runtime-defaults.d.ts +16 -0
  482. package/dist/plugin/openclaw-runtime-defaults.js +16 -0
  483. package/dist/plugin/openclaw-runtime-defaults.js.map +1 -0
  484. package/dist/plugin/runtime-capture.d.ts +0 -0
  485. package/dist/plugin/runtime-capture.js +0 -0
  486. package/dist/plugin/runtime-capture.js.map +0 -0
  487. package/dist/plugin/runtime-helpers.d.ts +0 -0
  488. package/dist/plugin/runtime-helpers.js +0 -0
  489. package/dist/plugin/runtime-helpers.js.map +0 -0
  490. package/dist/runtime/service.d.ts +33 -5
  491. package/dist/runtime/service.js +408 -22
  492. package/dist/runtime/service.js.map +1 -1
  493. package/dist/store/logs/jsonl-logger.d.ts +0 -0
  494. package/dist/store/logs/jsonl-logger.js +0 -0
  495. package/dist/store/logs/jsonl-logger.js.map +0 -0
  496. package/dist/store/sqlite/db.d.ts +0 -0
  497. package/dist/store/sqlite/db.js +28 -0
  498. package/dist/store/sqlite/db.js.map +1 -1
  499. package/dist/store/sqlite/migrations.d.ts +0 -0
  500. package/dist/store/sqlite/migrations.js +0 -0
  501. package/dist/store/sqlite/migrations.js.map +0 -0
  502. package/dist/store/sqlite/repositories/candidate-repo.d.ts +0 -0
  503. package/dist/store/sqlite/repositories/candidate-repo.js +0 -0
  504. package/dist/store/sqlite/repositories/candidate-repo.js.map +0 -0
  505. package/dist/store/sqlite/repositories/distillation-job-repo.d.ts +0 -0
  506. package/dist/store/sqlite/repositories/distillation-job-repo.js +0 -0
  507. package/dist/store/sqlite/repositories/distillation-job-repo.js.map +0 -0
  508. package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.d.ts +11 -0
  509. package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.js +76 -0
  510. package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.js.map +1 -0
  511. package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.d.ts +11 -0
  512. package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.js +73 -0
  513. package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.js.map +1 -0
  514. package/dist/store/sqlite/repositories/injection-repo.d.ts +0 -0
  515. package/dist/store/sqlite/repositories/injection-repo.js +0 -0
  516. package/dist/store/sqlite/repositories/injection-repo.js.map +0 -0
  517. package/dist/store/sqlite/repositories/input-record-repo.d.ts +1 -0
  518. package/dist/store/sqlite/repositories/input-record-repo.js +13 -0
  519. package/dist/store/sqlite/repositories/input-record-repo.js.map +1 -1
  520. package/dist/store/sqlite/repositories/node-repo.d.ts +3 -0
  521. package/dist/store/sqlite/repositories/node-repo.js +45 -6
  522. package/dist/store/sqlite/repositories/node-repo.js.map +1 -1
  523. package/dist/store/sqlite/repositories/outcome-record-repo.d.ts +0 -0
  524. package/dist/store/sqlite/repositories/outcome-record-repo.js +0 -0
  525. package/dist/store/sqlite/repositories/outcome-record-repo.js.map +0 -0
  526. package/dist/store/sqlite/repositories/review-event-repo.d.ts +0 -0
  527. package/dist/store/sqlite/repositories/review-event-repo.js +0 -0
  528. package/dist/store/sqlite/repositories/review-event-repo.js.map +0 -0
  529. package/dist/store/sqlite/repositories/scope-repo.d.ts +0 -0
  530. package/dist/store/sqlite/repositories/scope-repo.js +0 -0
  531. package/dist/store/sqlite/repositories/scope-repo.js.map +0 -0
  532. package/dist/store/sqlite/repositories/stats-repo.d.ts +0 -0
  533. package/dist/store/sqlite/repositories/stats-repo.js +0 -0
  534. package/dist/store/sqlite/repositories/stats-repo.js.map +0 -0
  535. package/dist/store/sqlite/repositories/task-run-repo.d.ts +0 -0
  536. package/dist/store/sqlite/repositories/task-run-repo.js +0 -0
  537. package/dist/store/sqlite/repositories/task-run-repo.js.map +0 -0
  538. package/dist/store/sqlite/schema.sql +40 -0
  539. package/dist/store/vector/api-embedding-provider.d.ts +0 -0
  540. package/dist/store/vector/api-embedding-provider.js +0 -0
  541. package/dist/store/vector/api-embedding-provider.js.map +0 -0
  542. package/dist/store/vector/embeddings.d.ts +0 -0
  543. package/dist/store/vector/embeddings.js +26 -8
  544. package/dist/store/vector/embeddings.js.map +1 -1
  545. package/dist/store/vector/lancedb.d.ts +0 -0
  546. package/dist/store/vector/lancedb.js +0 -0
  547. package/dist/store/vector/lancedb.js.map +0 -0
  548. package/dist/store/vector/local-provider.d.ts +0 -0
  549. package/dist/store/vector/local-provider.js +0 -0
  550. package/dist/store/vector/local-provider.js.map +0 -0
  551. package/dist/store/vector/node-index.d.ts +0 -0
  552. package/dist/store/vector/node-index.js +0 -0
  553. package/dist/store/vector/node-index.js.map +0 -0
  554. package/dist/store/vector/provider-types.d.ts +0 -0
  555. package/dist/store/vector/provider-types.js +0 -0
  556. package/dist/store/vector/provider-types.js.map +0 -0
  557. package/dist/types/analyzer.d.ts +0 -0
  558. package/dist/types/analyzer.js +0 -0
  559. package/dist/types/analyzer.js.map +0 -0
  560. package/dist/types/domain.d.ts +136 -1
  561. package/dist/types/domain.js +0 -0
  562. package/dist/types/domain.js.map +0 -0
  563. package/dist/types/plugin.d.ts +2 -1
  564. package/dist/types/plugin.js +0 -0
  565. package/dist/types/plugin.js.map +0 -0
  566. package/dist/types/storage.d.ts +0 -0
  567. package/dist/types/storage.js +0 -0
  568. package/dist/types/storage.js.map +0 -0
  569. package/dist/utils/clock.d.ts +0 -0
  570. package/dist/utils/clock.js +0 -0
  571. package/dist/utils/clock.js.map +0 -0
  572. package/dist/utils/errors.d.ts +0 -0
  573. package/dist/utils/errors.js +0 -0
  574. package/dist/utils/errors.js.map +0 -0
  575. package/dist/utils/hashing.d.ts +0 -0
  576. package/dist/utils/hashing.js +0 -0
  577. package/dist/utils/hashing.js.map +0 -0
  578. package/dist/utils/ids.d.ts +0 -0
  579. package/dist/utils/ids.js +0 -0
  580. package/dist/utils/ids.js.map +0 -0
  581. package/dist/utils/text.d.ts +0 -0
  582. package/dist/utils/text.js +0 -0
  583. package/dist/utils/text.js.map +0 -0
  584. package/dist/version/package-version.d.ts +0 -0
  585. package/dist/version/package-version.js +0 -0
  586. package/dist/version/package-version.js.map +0 -0
  587. package/dist/version/remote-release.d.ts +0 -0
  588. package/dist/version/remote-release.js +0 -0
  589. package/dist/version/remote-release.js.map +0 -0
  590. package/docs/releases/v0.1.0.md +0 -0
  591. package/docs/releases/v0.1.1.md +0 -0
  592. package/docs/releases/v0.1.2.md +0 -0
  593. package/docs/releases/v0.1.3.md +3 -2
  594. package/docs/releases/v0.2.0.md +85 -0
  595. package/docs/user-guide.md +39 -12
  596. package/hooks/hooks.json +0 -0
  597. package/openclaw.plugin.json +81 -1
  598. package/package.json +23 -15
  599. package/plugins/claude-code-experienceengine/.claude-plugin/plugin.json +1 -1
  600. package/plugins/claude-code-experienceengine/.mcp.json +0 -0
  601. package/plugins/claude-code-experienceengine/hooks/hooks.json +0 -0
  602. package/plugins/claude-code-experienceengine/scripts/claude-hook.sh +0 -0
  603. package/plugins/claude-code-experienceengine/scripts/install-deps.sh +1 -1
  604. package/scripts/claude-plugin/claude-hook.sh +0 -0
  605. package/scripts/claude-plugin/install-deps.sh +0 -0
File without changes
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "experienceengine",
3
3
  "description": "Context-aware experience intervention controller for Claude Code.",
4
- "version": "0.1.3",
4
+ "version": "0.2.0",
5
5
  "author": {
6
6
  "name": "ExperienceEngine"
7
7
  },
package/.env.example CHANGED
File without changes
package/.mcp.json CHANGED
File without changes
package/LICENSE CHANGED
File without changes
package/README.md CHANGED
@@ -1,39 +1,105 @@
1
1
  # ExperienceEngine
2
2
 
3
- [简体中文版 README](./README.zh-CN.md)
3
+ English | [简体中文](./README.zh-CN.md)
4
4
 
5
- ExperienceEngine is a local experience-intervention layer for coding agents.
5
+ ExperienceEngine is a governance layer for coding agents that reuses real execution experience without turning memory into noise. It injects short task-specific guidance only when relevant, then tracks whether that intervention helped or harmed.
6
6
 
7
- It learns short, task-specific guidance from real coding work, injects that guidance into later similar tasks, and records whether the intervention helped or harmed the outcome.
7
+ **Memory does addition. ExperienceEngine does governance.**
8
+
9
+ Supported hosts today: `OpenClaw`, `Claude Code`, `Codex`
10
+
11
+ ## 10-Second Example
12
+
13
+ Without ExperienceEngine:
14
+ - the agent repeats the same SQLite migration mistake in a similar repo
15
+
16
+ With ExperienceEngine:
17
+ - it injects a hint like: `Run the migration before opening the DB connection`
18
+ - later you mark that intervention `helpful` or `harmful`
19
+ - the experience can then become active, cool down, or retire
20
+
21
+ ```text
22
+ task signals -> distilled experience -> retrieval -> short intervention -> feedback -> governance
23
+ ```
24
+
25
+ <details>
26
+ <summary>Example host transcript</summary>
27
+
28
+ ```text
29
+ User: Fix the SQLite startup failure in this repo.
30
+
31
+ ExperienceEngine:
32
+ Hint: Run the migration before opening the DB connection.
33
+
34
+ Host agent:
35
+ I’ll apply the migration first, then retry startup.
36
+
37
+ User:
38
+ Why did that ExperienceEngine hint match?
39
+
40
+ Host agent:
41
+ It matched a prior task in this repo with the same SQLite startup pattern and a successful migration-first fix.
42
+
43
+ User:
44
+ Mark the last ExperienceEngine intervention as helpful.
45
+
46
+ Host agent:
47
+ Recorded. That experience gets stronger for similar future tasks.
48
+ ```
49
+
50
+ </details>
51
+
52
+ ![Example `ee inspect --last --verbose` output](./docs/assets/readme/inspect-last-example.svg)
53
+
54
+ ## Quick Start
55
+
56
+ Fastest host-specific install paths:
8
57
 
9
- Supported hosts today:
10
58
  - `OpenClaw`
11
- - `Claude Code`
59
+ - `openclaw plugins install @alan512/experienceengine`
60
+ - `openclaw gateway restart`
61
+ - `ee init`
12
62
  - `Codex`
63
+ - `ee install codex`
64
+ - `ee init`
65
+ - `Claude Code`
66
+ - `/plugin marketplace add https://github.com/Alan-512/ExperienceEngine.git`
67
+ - `/plugin install experienceengine@experienceengine`
68
+ - `ee init`
13
69
 
14
- OpenClaw compatibility:
15
- - requires a working OpenClaw installation with native plugin support
16
- - the documented OpenClaw path assumes `openclaw plugins install` and `openclaw gateway restart` are available
17
- - Node.js `>=20` is required for the published package
70
+ `ee init` initializes shared ExperienceEngine state after the host-specific installation step.
18
71
 
19
- ## The Problem It Solves
72
+ Need detailed per-host setup instructions, fallback paths, readiness states, or operator workflows? Jump to [Full Setup and Operator Details](#full-setup-and-operator-details).
20
73
 
21
- Coding agents repeat the same mistakes for a simple reason: most sessions do not accumulate reusable execution experience in a governed way.
74
+ ## Who It's For
22
75
 
23
- The usual failure modes are:
24
- - a fix worked yesterday, but the next similar session starts from zero again
25
- - memory systems keep adding facts and preferences, but they rarely retire low-value guidance
26
- - as recalled memory grows, context gets heavier and the agent's attention gets diluted
76
+ Use ExperienceEngine if:
77
+ - you use coding agents repeatedly in similar repos or workflows
78
+ - you want **small, intervention-focused guidance**, not general memory recall
79
+ - you want to know whether reused experience actually **helped or harmed**
80
+ - you want stale guidance to cool down or retire instead of accumulating forever
27
81
 
28
- ExperienceEngine is designed for that gap. It does not try to remember everything. It tries to decide:
29
- - when prior experience should intervene
30
- - which `strategy` or `warning` should be injected
31
- - whether that intervention actually helped
32
- - whether the experience should stay active, cool down, or retire
82
+ Do not use ExperienceEngine if:
83
+ - you only want a personal note-taking memory
84
+ - you want generic document RAG
85
+ - you rarely repeat workflows
86
+ - you want the system to remember everything by default
33
87
 
34
- **Memory does addition. ExperienceEngine does governance.**
88
+ ## Host Support Matrix
89
+
90
+ | Host | Install path | Routine interaction | Maturity |
91
+ |---|---|---|---|
92
+ | `OpenClaw` | native plugin install | host-native | most complete today |
93
+ | `Claude Code` | marketplace plugin, with `ee install claude-code` fallback | MCP + plugin hooks | supported |
94
+ | `Codex` | `ee install codex`, with native MCP fallback | MCP-native | supported |
35
95
 
36
- ## ExperienceEngine vs Memory
96
+ ## Why It Exists
97
+
98
+ Coding agents often repeat the same mistakes because prior execution experience is not reused in a governed way.
99
+
100
+ ExperienceEngine is designed for intervention governance, not general memory accumulation.
101
+
102
+ ## Why Not Memory / RAG
37
103
 
38
104
  | Question | Memory Systems | ExperienceEngine |
39
105
  |---|---|---|
@@ -42,9 +108,12 @@ ExperienceEngine is designed for that gap. It does not try to remember everythin
42
108
  | Track whether a recalled item helped or harmed | Usually no | Yes, per intervention |
43
109
  | Retire stale or harmful guidance automatically | Usually no | Yes, cooling and retirement are built in |
44
110
  | Keep context small and intervention-focused | Not the main goal | Yes, it injects short task-specific guidance |
111
+ | Generic document lookup | Common fit | Not the primary job |
45
112
 
46
113
  ## Where It Sits In The Agent Loop
47
114
 
115
+ At a high level, ExperienceEngine operates around the agent loop like this:
116
+
48
117
  ```text
49
118
  User task
50
119
  -> before_prompt_build: retrieve and inject matching experience
@@ -67,26 +136,64 @@ task signals
67
136
 
68
137
  Each node moves through that lifecycle using real task outcomes, not just time-based cleanup. Helpful experience gets reinforced; harmful experience gets cooled or retired.
69
138
 
70
- ## What You Can Use Today
139
+ ## What You Can Do Today
140
+
141
+ - reuse short guidance from similar coding work
142
+ - review why a hint matched
143
+ - mark interventions helpful or harmful
144
+ - inspect active, cooling, and retired experience
145
+ - run across `OpenClaw`, `Claude Code`, and `Codex`
146
+
147
+ ### Under The Hood
71
148
 
72
- Already available in the repository:
73
- - host integration for `OpenClaw`, `Claude Code`, and `Codex`
74
149
  - MCP-native interaction surfaces plus CLI/operator fallback
75
- - API-first semantic retrieval with graceful fallback:
76
- - OpenAI `text-embedding-3-small`
77
- - Gemini `gemini-embedding-001`
78
- - Jina `jina-embeddings-v3`
79
- - managed local embedding fallback
80
- - legacy hash-based fallback
150
+ - semantic retrieval with API and local fallback
81
151
  - host-agent driven inspection and feedback, with CLI fallback commands such as `ee inspect --last`, `ee helped`, and `ee harmed`
82
152
 
83
153
  For a more detailed explanation of what ExperienceEngine records and how an experience node is structured, see:
84
154
 
85
155
  - [Experience Model Overview](./docs/development/experience-model.md)
86
156
 
87
- ## Quick Start
157
+ ## Current Status
158
+
159
+ - Stable: core experience lifecycle, inspect/helped/harmed loop, host integrations, CLI/operator fallback
160
+ - Good path today: `OpenClaw` native plugin install
161
+ - Evolving: retrieval tuning, provider strategy, advanced host UX
162
+ - If you want the smoothest first experience today, start with `OpenClaw`.
163
+
164
+ ## What First Success Looks Like
165
+
166
+ After installation and initialization, the first visible signs of value are:
167
+
168
+ - ExperienceEngine injects a short hint during a real task
169
+ - the host can explain why that hint matched
170
+ - feedback on the last intervention affects future reuse
171
+ - `ee inspect --last` shows the recent intervention and related node state
172
+
173
+ ## Prerequisites
174
+
175
+ Before installing an adapter, make sure the host CLI already works on this machine:
176
+
177
+ - `openclaw` for the OpenClaw plugin/runtime integration
178
+ - `claude` for the Claude Code adapter
179
+ - `codex` for the Codex adapter
180
+
181
+ **ExperienceEngine does not install those host CLIs for you.** It wires itself into an already working host environment.
182
+
183
+ OpenClaw notes:
184
+ - requires a working OpenClaw installation with native plugin support
185
+ - the documented OpenClaw path assumes `openclaw plugins install` and `openclaw gateway restart` are available
186
+ - OpenClaw now uses the shared background learning loop by default
187
+ - OpenClaw still keeps async hybrid posttask review disabled by default; `ee status` and `ee doctor openclaw` show that explicitly
188
+
189
+ General package requirement:
190
+ - Node.js `>=20` is required for the published package
191
+
192
+ ## Full Setup and Operator Details
88
193
 
89
- ExperienceEngine no longer treats the `ee` CLI as the first-install entrypoint.
194
+ ### Full Setup by Host
195
+
196
+ ExperienceEngine no longer treats the `ee` CLI as the universal first-install entrypoint across all hosts.
90
197
 
91
198
  Install ExperienceEngine through the host setup flow for the host you want to use:
92
199
 
@@ -99,7 +206,7 @@ Install ExperienceEngine through the host setup flow for the host you want to us
99
206
  - EE-managed Codex setup:
100
207
  - `ee install codex`
101
208
  - native/manual fallback:
102
- - `codex mcp add experienceengine --env EXPERIENCE_ENGINE_HOME=$HOME/.experienceengine -- npx -y @alan512/experienceengine codex-mcp-server`
209
+ - see the advanced example below if you need direct MCP wiring
103
210
  - after either path, start a new Codex session in the repo so the MCP wiring and `AGENTS.md` instruction block are picked up
104
211
  - `Claude Code`
105
212
  - host-native marketplace install:
@@ -110,56 +217,15 @@ Install ExperienceEngine through the host setup flow for the host you want to us
110
217
  - `ee install claude-code` remains the operator fallback when you need direct hooks + MCP wiring outside the marketplace flow
111
218
  - after installation, start a new Claude Code session so the plugin hooks and bundled MCP config are loaded
112
219
 
113
- Across all three hosts, the intended product journey is the same:
220
+ Across all three hosts, the intended flow is the same:
114
221
 
115
222
  1. install ExperienceEngine through the host-specific setup path
116
223
  2. initialize shared ExperienceEngine state with `ee init`
117
224
  3. restart or open a fresh host session until the repo is `Ready`
118
- 4. keep routine review and feedback inside the host agent when the host supports it cleanly
225
+ 4. keep routine inspection and feedback inside the host when supported
119
226
  5. use `ee` as the operator fallback for validation, repair, and deeper inspection
120
227
 
121
- The host-specific differences are real, but they sit underneath one shared model:
122
-
123
- - installation mechanics differ by host
124
- - routine interaction should feel similar wherever the host supports it
125
- - CLI remains the explicit fallback and operator surface
126
-
127
- ExperienceEngine now treats onboarding and value as two separate layers:
128
-
129
- - `Setup state`
130
- - `Installed`
131
- - `Initialized`
132
- - `Ready`
133
- - `Value state`
134
- - `Warming up`
135
- - `First value reached`
136
-
137
- These are not one linear ladder. A repo can already be `Ready` while still `Warming up`.
138
-
139
- For routine use, ask the host agent naturally for ExperienceEngine state or feedback actions, for example:
140
-
141
- - "What did ExperienceEngine just inject?"
142
- - "Why did that ExperienceEngine hint match?"
143
- - "Mark the last ExperienceEngine intervention as helpful or harmful."
144
-
145
- OpenClaw now also supports these additional phase-2 routine questions in-session:
146
-
147
- - "Is ExperienceEngine ready here?"
148
- - "Is ExperienceEngine still warming up in this repo?"
149
- - "Why didn't ExperienceEngine inject anything just now?"
150
-
151
- For `OpenClaw`, `Codex`, and `Claude Code`, the common review-and-feedback follow-ups should stay in the host session first.
152
- For the extra readiness, warm-up, and recent-silence questions above, only `OpenClaw` supports the in-session phase-2 path today.
153
- Use CLI fallback whenever the host-side path is unavailable or you need explicit operator control.
154
-
155
- Use the `ee` CLI only when you need explicit operator validation or troubleshooting:
156
-
157
- ```bash
158
- ee init
159
- ee doctor <openclaw|claude-code|codex>
160
- ee status
161
- ee maintenance embedding-smoke
162
- ```
228
+ ### Shared Initialization
163
229
 
164
230
  `ee init` is shared-product initialization, not host-specific setup.
165
231
 
@@ -175,8 +241,6 @@ After installation, ExperienceEngine should orient the user toward the next setu
175
241
  - after shared state is configured with `ee init`, the product is `Initialized`
176
242
  - once the host or repo has reloaded correctly for real work, the product is `Ready`
177
243
 
178
- `First value reached` should only be claimed after visible output from a real task run. A generic warm-up message or static onboarding text does not count as first value.
179
-
180
244
  Minimal shared initialization example:
181
245
 
182
246
  ```bash
@@ -188,49 +252,61 @@ ee init show
188
252
 
189
253
  If you prefer Gemini or Jina for embeddings, use the same `ee init embedding` flow with the matching provider and model.
190
254
 
191
- ## Prerequisites
255
+ ### Routine Use vs Operator Use
192
256
 
193
- Before installing an adapter, make sure the host CLI already works on this machine:
257
+ For routine use, ask the host agent naturally for ExperienceEngine state or feedback actions, for example:
194
258
 
195
- - `openclaw` for the OpenClaw plugin/runtime integration
196
- - `claude` for the Claude Code adapter
197
- - `codex` for the Codex adapter
259
+ - "What did ExperienceEngine just inject?"
260
+ - "Why did that ExperienceEngine hint match?"
261
+ - "Mark the last ExperienceEngine intervention as helpful or harmful."
198
262
 
199
- ExperienceEngine does not install those host CLIs for you. It wires itself into an already working host environment.
263
+ OpenClaw also supports these additional readiness and recent-silence questions in-session:
200
264
 
201
- ## Installation Model
265
+ - "Is ExperienceEngine ready here?"
266
+ - "Is ExperienceEngine still warming up in this repo?"
267
+ - "Why didn't ExperienceEngine inject anything just now?"
202
268
 
203
- ExperienceEngine now treats installation and operations as separate concerns:
269
+ For `OpenClaw`, `Codex`, and `Claude Code`, the common review-and-feedback follow-ups should stay in the host session first.
270
+ Use CLI fallback whenever the host-side path is unavailable or you need explicit operator control.
204
271
 
205
- - installation belongs to the host
206
- - validation and maintenance belong to `ee`
272
+ Use the `ee` CLI when you need explicit operator validation or troubleshooting:
207
273
 
208
- That means the user-facing concepts stay stable even though the host integrations differ:
274
+ ```bash
275
+ ee init
276
+ ee doctor <openclaw|claude-code|codex>
277
+ ee status
278
+ ee maintenance embedding-smoke
279
+ ```
209
280
 
210
- - `OpenClaw`
211
- - installs through plugin/runtime integration
212
- - keeps stronger CLI/operator support today
213
- - `Claude Code`
214
- - installs through Claude-native marketplace/plugin assets
215
- - prefers MCP-native routine interaction inside the host session
216
- - `Codex`
217
- - uses the shared ExperienceEngine MCP server
218
- - prefers MCP-native routine interaction inside the host session
281
+ ### Readiness and Value States
282
+
283
+ ExperienceEngine treats onboarding and value as two separate layers:
284
+
285
+ - `Setup state`
286
+ - `Installed`
287
+ - `Initialized`
288
+ - `Ready`
289
+ - `Value state`
290
+ - `Warming up`
291
+ - `First value reached`
219
292
 
220
- Once installation is complete, the host agent remains the primary interaction surface.
293
+ These are not one linear ladder. A repo can already be `Ready` while still `Warming up`.
221
294
 
222
- `ee` is the operational surface for:
295
+ `First value reached` should only be claimed after visible output from a real task run. A generic warm-up message or static onboarding text does not count as first value.
223
296
 
224
- - shared provider/model initialization
225
- - health checks
226
- - repair guidance
227
- - status inspection
228
- - learning and intervention feedback
297
+ ## Installation Model
298
+
299
+ ExperienceEngine separates:
300
+ - host installation
301
+ - shared initialization
302
+ - operator workflows
229
303
 
230
- `ee status` is the daily product-progress view.
231
- `ee doctor <host>` is the explicit validation and troubleshooting view.
304
+ The host remains the primary interaction surface.
305
+ `ee` remains the explicit operator surface for setup, validation, repair, status, and maintenance.
232
306
 
233
- ## Advanced Per-Host Commands
307
+ ## Advanced Per-Host Commands (Operator / Development Only)
308
+
309
+ Most users can ignore this section and use the host-specific setup flow above.
234
310
 
235
311
  If you need explicit per-host control as an operator or while developing the product, these commands still exist:
236
312
 
@@ -240,6 +316,15 @@ ee install claude-code
240
316
  ee install codex
241
317
  ```
242
318
 
319
+ <details>
320
+ <summary>Native/manual Codex MCP fallback example</summary>
321
+
322
+ ```bash
323
+ codex mcp add experienceengine --env EXPERIENCE_ENGINE_HOME=$HOME/.experienceengine -- npx -y @alan512/experienceengine codex-mcp-server
324
+ ```
325
+
326
+ </details>
327
+
243
328
  Notes:
244
329
  - `OpenClaw` uses plugin/runtime integration (not `src/adapters/`) and CLI fallback for management.
245
330
  - `Claude Code` installs both hooks and the shared ExperienceEngine MCP server.
@@ -269,10 +354,7 @@ That managed state includes:
269
354
  Current default behavior:
270
355
 
271
356
  - `embeddingProvider = "api"`
272
- - provider priority:
273
- - OpenAI when `OPENAI_API_KEY` is present
274
- - Gemini when `GEMINI_API_KEY` is present
275
- - Jina when `JINA_API_KEY` is present
357
+ - provider priority: OpenAI -> Gemini -> Jina
276
358
  - if no API provider is available, ExperienceEngine falls back to the managed local embedding model
277
359
 
278
360
  Useful environment variables: