@alan512/experienceengine 0.1.3 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +213 -130
- package/README.zh-CN.md +250 -119
- package/dist/adapters/claude-code/session-store.d.ts +1 -0
- package/dist/adapters/claude-code/session-store.js +24 -1
- package/dist/adapters/claude-code/session-store.js.map +1 -1
- package/dist/adapters/codex/action-registry.d.ts +84 -0
- package/dist/adapters/codex/action-registry.js +277 -0
- package/dist/adapters/codex/action-registry.js.map +1 -0
- package/dist/adapters/codex/broker-tools.d.ts +114 -0
- package/dist/adapters/codex/broker-tools.js +130 -0
- package/dist/adapters/codex/broker-tools.js.map +1 -0
- package/dist/adapters/codex/mcp-server.d.ts +21 -0
- package/dist/adapters/codex/mcp-server.js +103 -423
- package/dist/adapters/codex/mcp-server.js.map +1 -1
- package/dist/analyzer/candidate-signals.d.ts +3 -1
- package/dist/analyzer/candidate-signals.js +159 -0
- package/dist/analyzer/candidate-signals.js.map +1 -1
- package/dist/analyzer/llm-learning-gate.d.ts +12 -1
- package/dist/analyzer/llm-learning-gate.js +633 -16
- package/dist/analyzer/llm-learning-gate.js.map +1 -1
- package/dist/cli/commands/claude-hook.js +11 -4
- package/dist/cli/commands/claude-hook.js.map +1 -1
- package/dist/cli/commands/codex.d.ts +60 -0
- package/dist/cli/commands/codex.js +188 -0
- package/dist/cli/commands/codex.js.map +1 -0
- package/dist/cli/commands/doctor.js +35 -2
- package/dist/cli/commands/doctor.js.map +1 -1
- package/dist/cli/commands/evaluate.d.ts +9 -3
- package/dist/cli/commands/evaluate.js +31 -5
- package/dist/cli/commands/evaluate.js.map +1 -1
- package/dist/cli/commands/init.js +21 -8
- package/dist/cli/commands/init.js.map +1 -1
- package/dist/cli/commands/inspect.js +73 -4
- package/dist/cli/commands/inspect.js.map +1 -1
- package/dist/cli/commands/repair.js +3 -3
- package/dist/cli/commands/repair.js.map +1 -1
- package/dist/cli/commands/status.js +38 -0
- package/dist/cli/commands/status.js.map +1 -1
- package/dist/cli/dispatch.js +16 -4
- package/dist/cli/dispatch.js.map +1 -1
- package/dist/config/config-schema.d.ts +177 -0
- package/dist/config/config-schema.js +142 -1
- package/dist/config/config-schema.js.map +1 -1
- package/dist/config/default-config.js +19 -1
- package/dist/config/default-config.js.map +1 -1
- package/dist/config/load-config.js +72 -1
- package/dist/config/load-config.js.map +1 -1
- package/dist/config/settings-store.d.ts +19 -0
- package/dist/config/settings-store.js +11 -0
- package/dist/config/settings-store.js.map +1 -1
- package/dist/controller/candidate-retriever.d.ts +16 -1
- package/dist/controller/candidate-retriever.js +199 -137
- package/dist/controller/candidate-retriever.js.map +1 -1
- package/dist/controller/injection-scorecard.d.ts +2 -14
- package/dist/controller/injection-scorecard.js +29 -0
- package/dist/controller/injection-scorecard.js.map +1 -1
- package/dist/controller/intervention-controller.d.ts +3 -15
- package/dist/controller/intervention-controller.js +219 -57
- package/dist/controller/intervention-controller.js.map +1 -1
- package/dist/controller/policy-enricher.d.ts +10 -0
- package/dist/controller/policy-enricher.js +186 -0
- package/dist/controller/policy-enricher.js.map +1 -0
- package/dist/controller/retrieval-context.d.ts +3 -0
- package/dist/controller/retrieval-context.js +37 -0
- package/dist/controller/retrieval-context.js.map +1 -0
- package/dist/controller/second-opinion-gate.d.ts +41 -0
- package/dist/controller/second-opinion-gate.js +225 -0
- package/dist/controller/second-opinion-gate.js.map +1 -0
- package/dist/controller/trigger-evaluator.d.ts +6 -1
- package/dist/controller/trigger-evaluator.js +31 -1
- package/dist/controller/trigger-evaluator.js.map +1 -1
- package/dist/distillation/prompt-contract.d.ts +1 -1
- package/dist/distillation/prompt-contract.js +3 -1
- package/dist/distillation/prompt-contract.js.map +1 -1
- package/dist/distillation/providers/gemini.js +5 -1
- package/dist/distillation/providers/gemini.js.map +1 -1
- package/dist/distillation/queue-worker.js +22 -3
- package/dist/distillation/queue-worker.js.map +1 -1
- package/dist/evaluation/codex-lifecycle-validation.d.ts +60 -0
- package/dist/evaluation/codex-lifecycle-validation.js +233 -0
- package/dist/evaluation/codex-lifecycle-validation.js.map +1 -0
- package/dist/evaluation/hybrid-phase1-rollout-summary.d.ts +63 -0
- package/dist/evaluation/hybrid-phase1-rollout-summary.js +108 -0
- package/dist/evaluation/hybrid-phase1-rollout-summary.js.map +1 -0
- package/dist/evaluation/hybrid-phase3-gate-metrics.d.ts +26 -0
- package/dist/evaluation/hybrid-phase3-gate-metrics.js +23 -0
- package/dist/evaluation/hybrid-phase3-gate-metrics.js.map +1 -0
- package/dist/evaluation/openclaw-baseline.d.ts +8 -0
- package/dist/evaluation/openclaw-baseline.js +27 -0
- package/dist/evaluation/openclaw-baseline.js.map +1 -1
- package/dist/experience-management/governance-observability.d.ts +13 -0
- package/dist/experience-management/governance-observability.js +37 -0
- package/dist/experience-management/governance-observability.js.map +1 -0
- package/dist/experience-management/node-lifecycle-governance.d.ts +8 -0
- package/dist/experience-management/node-lifecycle-governance.js +80 -0
- package/dist/experience-management/node-lifecycle-governance.js.map +1 -0
- package/dist/experience-management/task-management-signals.d.ts +29 -0
- package/dist/experience-management/task-management-signals.js +148 -0
- package/dist/experience-management/task-management-signals.js.map +1 -0
- package/dist/feedback/feedback-manager.d.ts +4 -1
- package/dist/feedback/feedback-manager.js +11 -22
- package/dist/feedback/feedback-manager.js.map +1 -1
- package/dist/feedback/state-transition.d.ts +6 -1
- package/dist/feedback/state-transition.js +6 -3
- package/dist/feedback/state-transition.js.map +1 -1
- package/dist/hybrid/capsule-builder.d.ts +23 -0
- package/dist/hybrid/capsule-builder.js +114 -0
- package/dist/hybrid/capsule-builder.js.map +1 -0
- package/dist/hybrid/explain-provider-client.d.ts +19 -0
- package/dist/hybrid/explain-provider-client.js +34 -0
- package/dist/hybrid/explain-provider-client.js.map +1 -0
- package/dist/hybrid/postmortem-provider-client.d.ts +19 -0
- package/dist/hybrid/postmortem-provider-client.js +34 -0
- package/dist/hybrid/postmortem-provider-client.js.map +1 -0
- package/dist/hybrid/rollout.d.ts +9 -0
- package/dist/hybrid/rollout.js +49 -0
- package/dist/hybrid/rollout.js.map +1 -0
- package/dist/hybrid/router.d.ts +4 -0
- package/dist/hybrid/router.js +62 -0
- package/dist/hybrid/router.js.map +1 -0
- package/dist/hybrid/types.d.ts +140 -0
- package/dist/hybrid/types.js +2 -0
- package/dist/hybrid/types.js.map +1 -0
- package/dist/hybrid/validators.d.ts +5 -0
- package/dist/hybrid/validators.js +94 -0
- package/dist/hybrid/validators.js.map +1 -0
- package/dist/hybrid/worker-client.d.ts +61 -0
- package/dist/hybrid/worker-client.js +196 -0
- package/dist/hybrid/worker-client.js.map +1 -0
- package/dist/hybrid/workers/explain-decision-llm.d.ts +8 -0
- package/dist/hybrid/workers/explain-decision-llm.js +152 -0
- package/dist/hybrid/workers/explain-decision-llm.js.map +1 -0
- package/dist/hybrid/workers/explain-decision.d.ts +2 -0
- package/dist/hybrid/workers/explain-decision.js +40 -0
- package/dist/hybrid/workers/explain-decision.js.map +1 -0
- package/dist/hybrid/workers/postmortem-review-llm.d.ts +8 -0
- package/dist/hybrid/workers/postmortem-review-llm.js +398 -0
- package/dist/hybrid/workers/postmortem-review-llm.js.map +1 -0
- package/dist/hybrid/workers/postmortem-review.d.ts +2 -0
- package/dist/hybrid/workers/postmortem-review.js +66 -0
- package/dist/hybrid/workers/postmortem-review.js.map +1 -0
- package/dist/install/claude-code-doctor.d.ts +1 -0
- package/dist/install/claude-code-doctor.js +20 -4
- package/dist/install/claude-code-doctor.js.map +1 -1
- package/dist/install/claude-code-installer.js +50 -1
- package/dist/install/claude-code-installer.js.map +1 -1
- package/dist/install/codex-cli.d.ts +15 -0
- package/dist/install/codex-cli.js +55 -3
- package/dist/install/codex-cli.js.map +1 -1
- package/dist/install/codex-installer.d.ts +7 -0
- package/dist/install/codex-installer.js +22 -0
- package/dist/install/codex-installer.js.map +1 -1
- package/dist/install/openclaw-cli.d.ts +11 -0
- package/dist/install/openclaw-cli.js.map +1 -1
- package/dist/install/openclaw-installer.d.ts +12 -7
- package/dist/install/openclaw-installer.js +197 -46
- package/dist/install/openclaw-installer.js.map +1 -1
- package/dist/interaction/service.d.ts +15 -0
- package/dist/interaction/service.js +189 -31
- package/dist/interaction/service.js.map +1 -1
- package/dist/plugin/hooks/before-prompt-build.d.ts +1 -0
- package/dist/plugin/hooks/before-prompt-build.js +4 -1
- package/dist/plugin/hooks/before-prompt-build.js.map +1 -1
- package/dist/plugin/openclaw-install-state.d.ts +39 -0
- package/dist/plugin/openclaw-install-state.js +24 -0
- package/dist/plugin/openclaw-install-state.js.map +1 -0
- package/dist/plugin/openclaw-plugin.d.ts +125 -0
- package/dist/plugin/openclaw-plugin.js +18 -7
- package/dist/plugin/openclaw-plugin.js.map +1 -1
- package/dist/plugin/openclaw-routine-interaction.d.ts +2 -1
- package/dist/plugin/openclaw-routine-interaction.js +12 -7
- package/dist/plugin/openclaw-routine-interaction.js.map +1 -1
- package/dist/plugin/openclaw-runtime-defaults.d.ts +16 -0
- package/dist/plugin/openclaw-runtime-defaults.js +16 -0
- package/dist/plugin/openclaw-runtime-defaults.js.map +1 -0
- package/dist/runtime/service.d.ts +34 -5
- package/dist/runtime/service.js +474 -49
- package/dist/runtime/service.js.map +1 -1
- package/dist/store/sqlite/db.js +28 -0
- package/dist/store/sqlite/db.js.map +1 -1
- package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.d.ts +11 -0
- package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.js +76 -0
- package/dist/store/sqlite/repositories/hybrid-invocation-trace-repo.js.map +1 -0
- package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.d.ts +11 -0
- package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.js +73 -0
- package/dist/store/sqlite/repositories/hybrid-review-artifact-repo.js.map +1 -0
- package/dist/store/sqlite/repositories/input-record-repo.d.ts +1 -0
- package/dist/store/sqlite/repositories/input-record-repo.js +13 -0
- package/dist/store/sqlite/repositories/input-record-repo.js.map +1 -1
- package/dist/store/sqlite/repositories/node-repo.d.ts +4 -0
- package/dist/store/sqlite/repositories/node-repo.js +54 -6
- package/dist/store/sqlite/repositories/node-repo.js.map +1 -1
- package/dist/store/sqlite/schema.sql +40 -0
- package/dist/store/vector/embeddings.js +26 -8
- package/dist/store/vector/embeddings.js.map +1 -1
- package/dist/types/domain.d.ts +151 -2
- package/dist/types/plugin.d.ts +2 -1
- package/docs/releases/v0.1.3.md +3 -2
- package/docs/releases/v0.2.0.md +85 -0
- package/docs/releases/v0.2.1.md +21 -0
- package/docs/user-guide.md +44 -13
- package/openclaw.plugin.json +81 -1
- package/package.json +11 -2
- package/plugins/claude-code-experienceengine/.claude-plugin/plugin.json +1 -1
- package/plugins/claude-code-experienceengine/scripts/install-deps.sh +1 -1
package/README.md
CHANGED
|
@@ -1,39 +1,95 @@
|
|
|
1
1
|
# ExperienceEngine
|
|
2
2
|
|
|
3
|
-
[
|
|
3
|
+
English | [简体中文](./README.zh-CN.md)
|
|
4
4
|
|
|
5
|
-
ExperienceEngine is a
|
|
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
|
-
|
|
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
|
+
- it opens the DB before running the migration, then wastes turns retrying the wrong path
|
|
16
|
+
|
|
17
|
+
With ExperienceEngine:
|
|
18
|
+
- before tool use, it injects one short constraint like: `Run the migration before opening the DB connection`
|
|
19
|
+
- the host agent avoids the same failed path instead of rediscovering it from scratch
|
|
20
|
+
- after the task, ExperienceEngine usually updates that guidance automatically from the real outcome
|
|
21
|
+
- if the guidance later starts harming similar tasks, ExperienceEngine can cool, quarantine, or retire it
|
|
22
|
+
|
|
23
|
+
Task flow: `task signals -> distilled experience -> retrieval -> short intervention -> feedback -> governance`
|
|
24
|
+
|
|
25
|
+
<details>
|
|
26
|
+
<summary>Example host transcript</summary>
|
|
27
|
+
|
|
28
|
+
User: Fix the SQLite startup failure in this repo.
|
|
29
|
+
|
|
30
|
+
Host agent: ExperienceEngine found a prior successful fix pattern in this repo: `Run the migration before opening the DB connection.` I’ll apply the migration first, then retry startup.
|
|
31
|
+
|
|
32
|
+
User: Why did that ExperienceEngine hint match?
|
|
33
|
+
|
|
34
|
+
Host agent: It matched a prior task in this repo with the same SQLite startup pattern and a successful migration-first fix.
|
|
35
|
+
|
|
36
|
+
User: So ExperienceEngine is trying to keep me off the same bad path?
|
|
37
|
+
|
|
38
|
+
Host agent: Yes. It reused a repo-local success pattern before the next tool call, and it will usually score the outcome automatically after this run.
|
|
39
|
+
|
|
40
|
+
</details>
|
|
41
|
+
|
|
42
|
+

|
|
43
|
+
|
|
44
|
+
## Quick Start
|
|
45
|
+
|
|
46
|
+
Fastest host-specific install paths:
|
|
8
47
|
|
|
9
|
-
Supported hosts today:
|
|
10
48
|
- `OpenClaw`
|
|
11
|
-
- `
|
|
49
|
+
- `openclaw plugins install @alan512/experienceengine`
|
|
50
|
+
- `openclaw gateway restart`
|
|
51
|
+
- `ee init`
|
|
12
52
|
- `Codex`
|
|
53
|
+
- `ee install codex`
|
|
54
|
+
- `ee init`
|
|
55
|
+
- `Claude Code`
|
|
56
|
+
- `/plugin marketplace add https://github.com/Alan-512/ExperienceEngine.git`
|
|
57
|
+
- `/plugin install experienceengine@experienceengine`
|
|
58
|
+
- `ee init`
|
|
13
59
|
|
|
14
|
-
|
|
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
|
|
60
|
+
`ee init` initializes shared ExperienceEngine state after the host-specific installation step.
|
|
18
61
|
|
|
19
|
-
|
|
62
|
+
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
63
|
|
|
21
|
-
|
|
64
|
+
## Who It's For
|
|
22
65
|
|
|
23
|
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
26
|
-
-
|
|
66
|
+
Use ExperienceEngine if:
|
|
67
|
+
- you use coding agents repeatedly in similar repos or workflows
|
|
68
|
+
- you want **small, intervention-focused guidance**, not general memory recall
|
|
69
|
+
- you want to know whether reused experience actually **helped or harmed**
|
|
70
|
+
- you want stale guidance to cool down or retire instead of accumulating forever
|
|
27
71
|
|
|
28
|
-
|
|
29
|
-
-
|
|
30
|
-
-
|
|
31
|
-
-
|
|
32
|
-
-
|
|
72
|
+
Do not use ExperienceEngine if:
|
|
73
|
+
- you only want a personal note-taking memory
|
|
74
|
+
- you want generic document RAG
|
|
75
|
+
- you rarely repeat workflows
|
|
76
|
+
- you want the system to remember everything by default
|
|
33
77
|
|
|
34
|
-
|
|
78
|
+
## Host Support Matrix
|
|
79
|
+
|
|
80
|
+
| Host | Install path | Routine interaction | Maturity |
|
|
81
|
+
|---|---|---|---|
|
|
82
|
+
| `OpenClaw` | native plugin install | host-native | most complete today |
|
|
83
|
+
| `Claude Code` | marketplace plugin, with `ee install claude-code` fallback | MCP + plugin hooks | supported |
|
|
84
|
+
| `Codex` | `ee install codex`, with native MCP fallback | MCP-native | supported |
|
|
85
|
+
|
|
86
|
+
## Why It Exists
|
|
35
87
|
|
|
36
|
-
|
|
88
|
+
Coding agents often repeat the same mistakes because prior execution experience is not reused in a governed way.
|
|
89
|
+
|
|
90
|
+
ExperienceEngine is designed for intervention governance, not general memory accumulation.
|
|
91
|
+
|
|
92
|
+
## Why Not Memory / RAG
|
|
37
93
|
|
|
38
94
|
| Question | Memory Systems | ExperienceEngine |
|
|
39
95
|
|---|---|---|
|
|
@@ -42,51 +98,99 @@ ExperienceEngine is designed for that gap. It does not try to remember everythin
|
|
|
42
98
|
| Track whether a recalled item helped or harmed | Usually no | Yes, per intervention |
|
|
43
99
|
| Retire stale or harmful guidance automatically | Usually no | Yes, cooling and retirement are built in |
|
|
44
100
|
| Keep context small and intervention-focused | Not the main goal | Yes, it injects short task-specific guidance |
|
|
101
|
+
| Generic document lookup | Common fit | Not the primary job |
|
|
102
|
+
|
|
103
|
+
## Why It Is Not Just Another Memory Layer
|
|
104
|
+
|
|
105
|
+
ExperienceEngine is not trying to remember more things than the host. Its core job is to govern whether learned guidance should keep affecting future tasks.
|
|
106
|
+
|
|
107
|
+
- most learning work happens after the task, so the current task does not need to wait for the full experience pipeline
|
|
108
|
+
- each learned node moves through a lifecycle such as `candidate`, `active`, `cooling`, and `retired`
|
|
109
|
+
- delivery is governed separately from storage, so harmful guidance can be cooled, quarantined, or removed from normal live injection
|
|
110
|
+
- posttask review can revise whether a hint actually helped, harmed, or stayed uncertain
|
|
111
|
+
- delivery decisions are persisted even when no hint is shipped, so skipped turns can still be explained later
|
|
112
|
+
- high-match same-repo experience can move out of conservative delivery after successful reuse, while cross-repo reuse stays cautious unless there is stronger evidence
|
|
113
|
+
- the product goal is production-safe reuse, not maximum recall
|
|
45
114
|
|
|
46
115
|
## Where It Sits In The Agent Loop
|
|
47
116
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
117
|
+
At a high level, ExperienceEngine operates around the agent loop like this:
|
|
118
|
+
|
|
119
|
+
- `User task`
|
|
120
|
+
- `before_prompt_build`: retrieve and inject matching experience
|
|
121
|
+
- `agent reasoning + tools`: capture failures, retries, corrections, and outcomes
|
|
122
|
+
- `task finalization`: distill new candidates into reusable experience
|
|
123
|
+
- `helped / harmed feedback`: promote, cool, or retire nodes
|
|
55
124
|
|
|
56
125
|
ExperienceEngine works at the context layer. It does not modify the host model's weights.
|
|
57
126
|
|
|
58
127
|
## Experience Lifecycle
|
|
59
128
|
|
|
60
|
-
|
|
61
|
-
task signals
|
|
62
|
-
-> candidate
|
|
63
|
-
-> active
|
|
64
|
-
-> cooling
|
|
65
|
-
-> retired
|
|
66
|
-
```
|
|
129
|
+
`task signals -> candidate -> active -> cooling -> retired`
|
|
67
130
|
|
|
68
131
|
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
132
|
|
|
70
|
-
## What You Can
|
|
133
|
+
## What You Can Do Today
|
|
134
|
+
|
|
135
|
+
- reuse short guidance from similar coding work
|
|
136
|
+
- review why a hint matched or why nothing injected
|
|
137
|
+
- let ExperienceEngine automatically reinforce, cool, quarantine, or retire guidance from real task outcomes
|
|
138
|
+
- override the last intervention as helpful or harmful when the automatic judgment needs correction
|
|
139
|
+
- inspect active, cooling, quarantined, and retired experience
|
|
140
|
+
- run across `OpenClaw`, `Claude Code`, and `Codex`
|
|
141
|
+
|
|
142
|
+
### Under The Hood
|
|
71
143
|
|
|
72
|
-
Already available in the repository:
|
|
73
|
-
- host integration for `OpenClaw`, `Claude Code`, and `Codex`
|
|
74
144
|
- MCP-native interaction surfaces plus CLI/operator fallback
|
|
75
|
-
-
|
|
76
|
-
|
|
77
|
-
- Gemini `gemini-embedding-001`
|
|
78
|
-
- Jina `jina-embeddings-v3`
|
|
79
|
-
- managed local embedding fallback
|
|
80
|
-
- legacy hash-based fallback
|
|
145
|
+
- semantic retrieval with API and local fallback
|
|
146
|
+
- deterministic match scorecards that separate same-repo confidence from broader cross-repo reuse
|
|
81
147
|
- host-agent driven inspection and feedback, with CLI fallback commands such as `ee inspect --last`, `ee helped`, and `ee harmed`
|
|
82
148
|
|
|
83
149
|
For a more detailed explanation of what ExperienceEngine records and how an experience node is structured, see:
|
|
84
150
|
|
|
85
151
|
- [Experience Model Overview](./docs/development/experience-model.md)
|
|
86
152
|
|
|
87
|
-
##
|
|
153
|
+
## Current Status
|
|
154
|
+
|
|
155
|
+
- Stable: core experience lifecycle, inspect/helped/harmed loop, host integrations, CLI/operator fallback
|
|
156
|
+
- Good path today: `OpenClaw` native plugin install
|
|
157
|
+
- Evolving: retrieval tuning, provider strategy, advanced host UX
|
|
158
|
+
- If you want the smoothest first experience today, start with `OpenClaw`.
|
|
159
|
+
|
|
160
|
+
## What First Success Looks Like
|
|
161
|
+
|
|
162
|
+
After installation and initialization, the first visible signs of value are:
|
|
163
|
+
|
|
164
|
+
- a repeated task avoids a previously known bad path instead of rediscovering it
|
|
165
|
+
- ExperienceEngine injects only a short repo-relevant constraint instead of bloating the prompt
|
|
166
|
+
- the host can explain why that hint matched or why nothing was injected
|
|
167
|
+
- the task outcome usually updates future delivery automatically
|
|
168
|
+
- `ee inspect --last` shows the recent intervention and related node state
|
|
169
|
+
|
|
170
|
+
## Prerequisites
|
|
171
|
+
|
|
172
|
+
Before installing an adapter, make sure the host CLI already works on this machine:
|
|
173
|
+
|
|
174
|
+
- `openclaw` for the OpenClaw plugin/runtime integration
|
|
175
|
+
- `claude` for the Claude Code adapter
|
|
176
|
+
- `codex` for the Codex adapter
|
|
88
177
|
|
|
89
|
-
ExperienceEngine
|
|
178
|
+
**ExperienceEngine does not install those host CLIs for you.** It wires itself into an already working host environment.
|
|
179
|
+
|
|
180
|
+
OpenClaw notes:
|
|
181
|
+
- requires a working OpenClaw installation with native plugin support
|
|
182
|
+
- the documented OpenClaw path assumes `openclaw plugins install` and `openclaw gateway restart` are available
|
|
183
|
+
- OpenClaw now uses the shared background learning loop by default
|
|
184
|
+
- OpenClaw still keeps async hybrid posttask review disabled by default; `ee status` and `ee doctor openclaw` show that explicitly
|
|
185
|
+
|
|
186
|
+
General package requirement:
|
|
187
|
+
- Node.js `>=20` is required for the published package
|
|
188
|
+
|
|
189
|
+
## Full Setup and Operator Details
|
|
190
|
+
|
|
191
|
+
### Full Setup by Host
|
|
192
|
+
|
|
193
|
+
ExperienceEngine no longer treats the `ee` CLI as the universal first-install entrypoint across all hosts.
|
|
90
194
|
|
|
91
195
|
Install ExperienceEngine through the host setup flow for the host you want to use:
|
|
92
196
|
|
|
@@ -99,7 +203,7 @@ Install ExperienceEngine through the host setup flow for the host you want to us
|
|
|
99
203
|
- EE-managed Codex setup:
|
|
100
204
|
- `ee install codex`
|
|
101
205
|
- native/manual fallback:
|
|
102
|
-
-
|
|
206
|
+
- see the advanced example below if you need direct MCP wiring
|
|
103
207
|
- after either path, start a new Codex session in the repo so the MCP wiring and `AGENTS.md` instruction block are picked up
|
|
104
208
|
- `Claude Code`
|
|
105
209
|
- host-native marketplace install:
|
|
@@ -110,49 +214,62 @@ Install ExperienceEngine through the host setup flow for the host you want to us
|
|
|
110
214
|
- `ee install claude-code` remains the operator fallback when you need direct hooks + MCP wiring outside the marketplace flow
|
|
111
215
|
- after installation, start a new Claude Code session so the plugin hooks and bundled MCP config are loaded
|
|
112
216
|
|
|
113
|
-
Across all three hosts, the intended
|
|
217
|
+
Across all three hosts, the intended flow is the same:
|
|
114
218
|
|
|
115
219
|
1. install ExperienceEngine through the host-specific setup path
|
|
116
220
|
2. initialize shared ExperienceEngine state with `ee init`
|
|
117
221
|
3. restart or open a fresh host session until the repo is `Ready`
|
|
118
|
-
4. keep routine
|
|
222
|
+
4. keep routine inspection and feedback inside the host when supported
|
|
119
223
|
5. use `ee` as the operator fallback for validation, repair, and deeper inspection
|
|
120
224
|
|
|
121
|
-
|
|
225
|
+
### Shared Initialization
|
|
122
226
|
|
|
123
|
-
|
|
124
|
-
- routine interaction should feel similar wherever the host supports it
|
|
125
|
-
- CLI remains the explicit fallback and operator surface
|
|
227
|
+
`ee init` is shared-product initialization, not host-specific setup.
|
|
126
228
|
|
|
127
|
-
|
|
229
|
+
- Run it once after your first host installation to configure:
|
|
230
|
+
- distillation provider/model/auth
|
|
231
|
+
- embedding mode/provider
|
|
232
|
+
- any shared provider secrets
|
|
233
|
+
- Later host installations reuse the same ExperienceEngine home, settings, and shared secrets.
|
|
128
234
|
|
|
129
|
-
|
|
130
|
-
- `Installed`
|
|
131
|
-
- `Initialized`
|
|
132
|
-
- `Ready`
|
|
133
|
-
- `Value state`
|
|
134
|
-
- `Warming up`
|
|
135
|
-
- `First value reached`
|
|
235
|
+
After installation, ExperienceEngine should orient the user toward the next setup step:
|
|
136
236
|
|
|
137
|
-
|
|
237
|
+
- if host wiring is in place, the product is at least `Installed`
|
|
238
|
+
- after shared state is configured with `ee init`, the product is `Initialized`
|
|
239
|
+
- once the host or repo has reloaded correctly for real work, the product is `Ready`
|
|
240
|
+
|
|
241
|
+
Minimal shared initialization example:
|
|
242
|
+
|
|
243
|
+
1. `ee init distillation --provider openai --model gpt-4.1-mini --auth-mode api_key`
|
|
244
|
+
2. `ee init secret OPENAI_API_KEY <your-api-key>`
|
|
245
|
+
3. `ee init embedding --mode api --api-provider openai --model text-embedding-3-small`
|
|
246
|
+
4. `ee init show`
|
|
247
|
+
|
|
248
|
+
If you prefer Gemini or Jina for embeddings, use the same `ee init embedding` flow with the matching provider and model.
|
|
249
|
+
|
|
250
|
+
### Routine Use vs Operator Use
|
|
251
|
+
|
|
252
|
+
For routine use, ask the host agent naturally for ExperienceEngine state first. Automatic outcome attribution is the default path; manual feedback is mainly there when you want to correct that judgment.
|
|
138
253
|
|
|
139
|
-
|
|
254
|
+
Examples:
|
|
140
255
|
|
|
141
256
|
- "What did ExperienceEngine just inject?"
|
|
142
257
|
- "Why did that ExperienceEngine hint match?"
|
|
258
|
+
- "Why didn't ExperienceEngine inject anything just now?"
|
|
143
259
|
- "Mark the last ExperienceEngine intervention as helpful or harmful."
|
|
144
260
|
|
|
145
|
-
|
|
261
|
+
In normal use, you should not need to manually score every intervention. ExperienceEngine is designed to learn from real task outcomes automatically, while still letting you override the result when the automatic judgment is wrong.
|
|
262
|
+
|
|
263
|
+
OpenClaw also supports these additional readiness and recent-silence questions in-session:
|
|
146
264
|
|
|
147
265
|
- "Is ExperienceEngine ready here?"
|
|
148
266
|
- "Is ExperienceEngine still warming up in this repo?"
|
|
149
267
|
- "Why didn't ExperienceEngine inject anything just now?"
|
|
150
268
|
|
|
151
269
|
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
270
|
Use CLI fallback whenever the host-side path is unavailable or you need explicit operator control.
|
|
154
271
|
|
|
155
|
-
Use the `ee` CLI
|
|
272
|
+
Use the `ee` CLI when you need explicit operator validation or troubleshooting:
|
|
156
273
|
|
|
157
274
|
```bash
|
|
158
275
|
ee init
|
|
@@ -161,76 +278,36 @@ ee status
|
|
|
161
278
|
ee maintenance embedding-smoke
|
|
162
279
|
```
|
|
163
280
|
|
|
164
|
-
|
|
281
|
+
### Readiness and Value States
|
|
165
282
|
|
|
166
|
-
|
|
167
|
-
- distillation provider/model/auth
|
|
168
|
-
- embedding mode/provider
|
|
169
|
-
- any shared provider secrets
|
|
170
|
-
- Later host installations reuse the same ExperienceEngine home, settings, and shared secrets.
|
|
283
|
+
ExperienceEngine treats onboarding and value as two separate layers:
|
|
171
284
|
|
|
172
|
-
|
|
285
|
+
- `Setup state`
|
|
286
|
+
- `Installed`
|
|
287
|
+
- `Initialized`
|
|
288
|
+
- `Ready`
|
|
289
|
+
- `Value state`
|
|
290
|
+
- `Warming up`
|
|
291
|
+
- `First value reached`
|
|
173
292
|
|
|
174
|
-
|
|
175
|
-
- after shared state is configured with `ee init`, the product is `Initialized`
|
|
176
|
-
- once the host or repo has reloaded correctly for real work, the product is `Ready`
|
|
293
|
+
These are not one linear ladder. A repo can already be `Ready` while still `Warming up`.
|
|
177
294
|
|
|
178
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.
|
|
179
296
|
|
|
180
|
-
Minimal shared initialization example:
|
|
181
|
-
|
|
182
|
-
```bash
|
|
183
|
-
ee init distillation --provider openai --model gpt-4.1-mini --auth-mode api_key
|
|
184
|
-
ee init secret OPENAI_API_KEY <your-api-key>
|
|
185
|
-
ee init embedding --mode api --api-provider openai --model text-embedding-3-small
|
|
186
|
-
ee init show
|
|
187
|
-
```
|
|
188
|
-
|
|
189
|
-
If you prefer Gemini or Jina for embeddings, use the same `ee init embedding` flow with the matching provider and model.
|
|
190
|
-
|
|
191
|
-
## Prerequisites
|
|
192
|
-
|
|
193
|
-
Before installing an adapter, make sure the host CLI already works on this machine:
|
|
194
|
-
|
|
195
|
-
- `openclaw` for the OpenClaw plugin/runtime integration
|
|
196
|
-
- `claude` for the Claude Code adapter
|
|
197
|
-
- `codex` for the Codex adapter
|
|
198
|
-
|
|
199
|
-
ExperienceEngine does not install those host CLIs for you. It wires itself into an already working host environment.
|
|
200
|
-
|
|
201
297
|
## Installation Model
|
|
202
298
|
|
|
203
|
-
ExperienceEngine
|
|
204
|
-
|
|
205
|
-
-
|
|
206
|
-
-
|
|
207
|
-
|
|
208
|
-
That means the user-facing concepts stay stable even though the host integrations differ:
|
|
209
|
-
|
|
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
|
|
219
|
-
|
|
220
|
-
Once installation is complete, the host agent remains the primary interaction surface.
|
|
299
|
+
ExperienceEngine separates:
|
|
300
|
+
- host installation
|
|
301
|
+
- shared initialization
|
|
302
|
+
- operator workflows
|
|
221
303
|
|
|
222
|
-
|
|
304
|
+
The host remains the primary interaction surface.
|
|
305
|
+
`ee` remains the explicit operator surface for setup, validation, repair, status, and maintenance.
|
|
306
|
+
For Codex, `ee status` and `ee doctor codex` also report whether the `ee` CLI fallback is available on `PATH`. Codex MCP wiring can still work when the CLI fallback is missing, but commands such as `ee inspect --last` need either a PATH-visible `ee` binary or an explicit package invocation.
|
|
223
307
|
|
|
224
|
-
-
|
|
225
|
-
- health checks
|
|
226
|
-
- repair guidance
|
|
227
|
-
- status inspection
|
|
228
|
-
- learning and intervention feedback
|
|
308
|
+
## Advanced Per-Host Commands (Operator / Development Only)
|
|
229
309
|
|
|
230
|
-
|
|
231
|
-
`ee doctor <host>` is the explicit validation and troubleshooting view.
|
|
232
|
-
|
|
233
|
-
## Advanced Per-Host Commands
|
|
310
|
+
Most users can ignore this section and use the host-specific setup flow above.
|
|
234
311
|
|
|
235
312
|
If you need explicit per-host control as an operator or while developing the product, these commands still exist:
|
|
236
313
|
|
|
@@ -240,6 +317,15 @@ ee install claude-code
|
|
|
240
317
|
ee install codex
|
|
241
318
|
```
|
|
242
319
|
|
|
320
|
+
<details>
|
|
321
|
+
<summary>Native/manual Codex MCP fallback example</summary>
|
|
322
|
+
|
|
323
|
+
```bash
|
|
324
|
+
codex mcp add experienceengine --env EXPERIENCE_ENGINE_HOME=$HOME/.experienceengine -- npx -y @alan512/experienceengine codex-mcp-server
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
</details>
|
|
328
|
+
|
|
243
329
|
Notes:
|
|
244
330
|
- `OpenClaw` uses plugin/runtime integration (not `src/adapters/`) and CLI fallback for management.
|
|
245
331
|
- `Claude Code` installs both hooks and the shared ExperienceEngine MCP server.
|
|
@@ -269,10 +355,7 @@ That managed state includes:
|
|
|
269
355
|
Current default behavior:
|
|
270
356
|
|
|
271
357
|
- `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
|
|
358
|
+
- provider priority: OpenAI -> Gemini -> Jina
|
|
276
359
|
- if no API provider is available, ExperienceEngine falls back to the managed local embedding model
|
|
277
360
|
|
|
278
361
|
Useful environment variables:
|