agentera 3.0.0-dev.25 → 3.0.0-dev.26

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 (270) hide show
  1. package/README.md +16 -20
  2. package/bundle/CHANGELOG.md +15 -25
  3. package/bundle/README.md +13 -34
  4. package/bundle/UPGRADE.md +71 -165
  5. package/bundle/references/adapters/package-manifest-interface-model.yaml +40 -241
  6. package/bundle/references/adapters/package-registry.yaml +0 -145
  7. package/bundle/references/adapters/package-surface-characterization.md +13 -38
  8. package/bundle/references/adapters/runtime-lifecycle-adapters.yaml +5 -219
  9. package/bundle/references/adapters/runtime-lifecycle-authority.yaml +2 -29
  10. package/bundle/references/adapters/runtime-lifecycle-operation-contract.yaml +1 -1
  11. package/bundle/references/artifacts/state-storage-authority.yaml +43 -447
  12. package/bundle/references/cli/agent-ready-state-contract.yaml +9 -9
  13. package/bundle/references/cli/app-lifecycle-vocabulary.yaml +3 -4
  14. package/bundle/references/cli/bundle-skill-vocabulary.yaml +9 -18
  15. package/bundle/references/cli/capability-tool-classification.yaml +2 -2
  16. package/bundle/references/cli/prime-consumer-compatibility.yaml +28 -98
  17. package/bundle/references/cli/routing-execution-vocabulary.yaml +4 -22
  18. package/bundle/references/cli/upgrade-repair-wording.md +8 -28
  19. package/bundle/references/cli/v3-handoff-manifest.schema.yaml +2 -3
  20. package/bundle/references/cli/vocabulary.md +18 -23
  21. package/bundle/references/meta/documentation-inventory.md +1 -1
  22. package/bundle/skills/agentera/schemas/artifacts/docs.yaml +3 -11
  23. package/bundle/skills/agentera/schemas/artifacts/plan.yaml +1 -1
  24. package/dist/cli/capabilityContext/bespoke.js +8 -2
  25. package/dist/cli/capabilityContext/bespoke.js.map +1 -1
  26. package/dist/cli/capabilityContext/closeout.js +3 -3
  27. package/dist/cli/capabilityContext/closeout.js.map +1 -1
  28. package/dist/cli/capabilityContext/evidence.js +52 -40
  29. package/dist/cli/capabilityContext/evidence.js.map +1 -1
  30. package/dist/cli/capabilityContext/startup.js +1 -1
  31. package/dist/cli/capabilityContext/startup.js.map +1 -1
  32. package/dist/cli/commands/doctor.js +6 -64
  33. package/dist/cli/commands/doctor.js.map +1 -1
  34. package/dist/cli/commands/durability.js +12 -48
  35. package/dist/cli/commands/durability.js.map +1 -1
  36. package/dist/cli/commands/prime/briefOrientation.js +2 -19
  37. package/dist/cli/commands/prime/briefOrientation.js.map +1 -1
  38. package/dist/cli/commands/prime/bundleStatus.js +8 -2
  39. package/dist/cli/commands/prime/bundleStatus.js.map +1 -1
  40. package/dist/cli/commands/prime/collectEntityOrientation.js +27 -14
  41. package/dist/cli/commands/prime/collectEntityOrientation.js.map +1 -1
  42. package/dist/cli/commands/prime/collectOrientationState.js +31 -52
  43. package/dist/cli/commands/prime/collectOrientationState.js.map +1 -1
  44. package/dist/cli/commands/prime/orientationOutput.js +3 -11
  45. package/dist/cli/commands/prime/orientationOutput.js.map +1 -1
  46. package/dist/cli/commands/prime.js +0 -5
  47. package/dist/cli/commands/prime.js.map +1 -1
  48. package/dist/cli/commands/query.js +17 -49
  49. package/dist/cli/commands/query.js.map +1 -1
  50. package/dist/cli/commands/schema.js +19 -78
  51. package/dist/cli/commands/schema.js.map +1 -1
  52. package/dist/cli/commands/state/decisions.js +11 -57
  53. package/dist/cli/commands/state/decisions.js.map +1 -1
  54. package/dist/cli/commands/state/docs.js +56 -120
  55. package/dist/cli/commands/state/docs.js.map +1 -1
  56. package/dist/cli/commands/state/experimentRecords.js +22 -121
  57. package/dist/cli/commands/state/experimentRecords.js.map +1 -1
  58. package/dist/cli/commands/state/experiments.js +9 -75
  59. package/dist/cli/commands/state/experiments.js.map +1 -1
  60. package/dist/cli/commands/state/get.js +62 -143
  61. package/dist/cli/commands/state/get.js.map +1 -1
  62. package/dist/cli/commands/state/health.js +9 -123
  63. package/dist/cli/commands/state/health.js.map +1 -1
  64. package/dist/cli/commands/state/index.js +2 -2
  65. package/dist/cli/commands/state/index.js.map +1 -1
  66. package/dist/cli/commands/state/list.js +20 -36
  67. package/dist/cli/commands/state/list.js.map +1 -1
  68. package/dist/cli/commands/state/objective.js +19 -86
  69. package/dist/cli/commands/state/objective.js.map +1 -1
  70. package/dist/cli/commands/state/plan.js +9 -388
  71. package/dist/cli/commands/state/plan.js.map +1 -1
  72. package/dist/cli/commands/state/planTasks.js +58 -93
  73. package/dist/cli/commands/state/planTasks.js.map +1 -1
  74. package/dist/cli/commands/state/plans.js +13 -40
  75. package/dist/cli/commands/state/plans.js.map +1 -1
  76. package/dist/cli/commands/state/progress.js +10 -55
  77. package/dist/cli/commands/state/progress.js.map +1 -1
  78. package/dist/cli/commands/state/todo.js +24 -133
  79. package/dist/cli/commands/state/todo.js.map +1 -1
  80. package/dist/cli/commands/state/write.js +11 -33
  81. package/dist/cli/commands/state/write.js.map +1 -1
  82. package/dist/cli/commands/upgrade.js +48 -18
  83. package/dist/cli/commands/upgrade.js.map +1 -1
  84. package/dist/cli/commands/upgradeVerify.js +21 -15
  85. package/dist/cli/commands/upgradeVerify.js.map +1 -1
  86. package/dist/cli/commands/validate.js +1 -9
  87. package/dist/cli/commands/validate.js.map +1 -1
  88. package/dist/cli/dispatch/check.js +5 -12
  89. package/dist/cli/dispatch/check.js.map +1 -1
  90. package/dist/cli/dispatch/index.js +30 -29
  91. package/dist/cli/dispatch/index.js.map +1 -1
  92. package/dist/cli/dispatch/lifecycle.js +23 -40
  93. package/dist/cli/dispatch/lifecycle.js.map +1 -1
  94. package/dist/cli/help.js +20 -100
  95. package/dist/cli/help.js.map +1 -1
  96. package/dist/cli/migrationRequired.js +22 -19
  97. package/dist/cli/migrationRequired.js.map +1 -1
  98. package/dist/cli/orientation/attention.js +1 -97
  99. package/dist/cli/orientation/attention.js.map +1 -1
  100. package/dist/cli/stateQuery.js +1 -2
  101. package/dist/cli/stateQuery.js.map +1 -1
  102. package/dist/core/skillIdentity.js +24 -0
  103. package/dist/core/skillIdentity.js.map +1 -0
  104. package/dist/hooks/common.js +1 -1
  105. package/dist/hooks/common.js.map +1 -1
  106. package/dist/hooks/compaction/status.js +2 -1
  107. package/dist/hooks/compaction/status.js.map +1 -1
  108. package/dist/hooks/cursorSessionStart.js +4 -25
  109. package/dist/hooks/cursorSessionStart.js.map +1 -1
  110. package/dist/hooks/projectHookInput.js +26 -0
  111. package/dist/hooks/projectHookInput.js.map +1 -0
  112. package/dist/hooks/sessionStart.js +23 -239
  113. package/dist/hooks/sessionStart.js.map +1 -1
  114. package/dist/hooks/sessionStop.js +4 -12
  115. package/dist/hooks/sessionStop.js.map +1 -1
  116. package/dist/hooks/validateArtifact/traversal.js +1 -1
  117. package/dist/hooks/validateArtifact/traversal.js.map +1 -1
  118. package/dist/registries/artifactRegistry.js +2 -1
  119. package/dist/registries/artifactRegistry.js.map +1 -1
  120. package/dist/registries/packageRegistry.js +57 -231
  121. package/dist/registries/packageRegistry.js.map +1 -1
  122. package/dist/release/releaseMetadata.js +1 -13
  123. package/dist/release/releaseMetadata.js.map +1 -1
  124. package/dist/runtime/lifecycleAdapterContract.js +4 -4
  125. package/dist/runtime/lifecycleAdapterContract.js.map +1 -1
  126. package/dist/runtime/lifecycleAdapters.js +14 -2
  127. package/dist/runtime/lifecycleAdapters.js.map +1 -1
  128. package/dist/runtime/lifecycleAuthority.js +5 -43
  129. package/dist/runtime/lifecycleAuthority.js.map +1 -1
  130. package/dist/runtime/lifecycleOperationContract.js +3 -2
  131. package/dist/runtime/lifecycleOperationContract.js.map +1 -1
  132. package/dist/runtime/lifecyclePublication.js +21 -0
  133. package/dist/runtime/lifecyclePublication.js.map +1 -1
  134. package/dist/setup/opencode.js +20 -12
  135. package/dist/setup/opencode.js.map +1 -1
  136. package/dist/setup/sharedSkill.js +46 -0
  137. package/dist/setup/sharedSkill.js.map +1 -0
  138. package/dist/setup/smokeChecks.js +16 -43
  139. package/dist/setup/smokeChecks.js.map +1 -1
  140. package/dist/state/decisionEntities.js +7 -4
  141. package/dist/state/decisionEntities.js.map +1 -1
  142. package/dist/state/durability.js +4 -240
  143. package/dist/state/durability.js.map +1 -1
  144. package/dist/state/entityCutover.js +90 -186
  145. package/dist/state/entityCutover.js.map +1 -1
  146. package/dist/state/entityStorage.js +27 -8
  147. package/dist/state/entityStorage.js.map +1 -1
  148. package/dist/state/healthEntities.js +7 -4
  149. package/dist/state/healthEntities.js.map +1 -1
  150. package/dist/state/objectiveExperimentEntities.js +7 -5
  151. package/dist/state/objectiveExperimentEntities.js.map +1 -1
  152. package/dist/state/planEntities.js +14 -10
  153. package/dist/state/planEntities.js.map +1 -1
  154. package/dist/state/progressEntities.js +4 -2
  155. package/dist/state/progressEntities.js.map +1 -1
  156. package/dist/state/startupProjection.js +3 -2
  157. package/dist/state/startupProjection.js.map +1 -1
  158. package/dist/state/stateMode.js +7 -0
  159. package/dist/state/stateMode.js.map +1 -1
  160. package/dist/state/todoDocsEntities.js +6 -4
  161. package/dist/state/todoDocsEntities.js.map +1 -1
  162. package/dist/state/write/explain.js +1 -9
  163. package/dist/state/write/explain.js.map +1 -1
  164. package/dist/state/write/transaction.js +22 -532
  165. package/dist/state/write/transaction.js.map +1 -1
  166. package/dist/upgrade/appContentRefresh.js +43 -28
  167. package/dist/upgrade/appContentRefresh.js.map +1 -1
  168. package/dist/upgrade/doctor.js +5 -1
  169. package/dist/upgrade/doctor.js.map +1 -1
  170. package/dist/upgrade/installedHooksRetirement.js +46 -39
  171. package/dist/upgrade/installedHooksRetirement.js.map +1 -1
  172. package/dist/upgrade/legacyAgentCleanup.js +132 -32
  173. package/dist/upgrade/legacyAgentCleanup.js.map +1 -1
  174. package/dist/upgrade/lifecycleUpgrade.js +65 -378
  175. package/dist/upgrade/lifecycleUpgrade.js.map +1 -1
  176. package/dist/upgrade/migrateArtifactsV2ToV3.js +151 -52
  177. package/dist/upgrade/migrateArtifactsV2ToV3.js.map +1 -1
  178. package/dist/upgrade/migrationPublication.js +123 -0
  179. package/dist/upgrade/migrationPublication.js.map +1 -0
  180. package/dist/upgrade/projectIntegration.js +46 -113
  181. package/dist/upgrade/projectIntegration.js.map +1 -1
  182. package/dist/upgrade/projectIntegrationDecision.js +6 -96
  183. package/dist/upgrade/projectIntegrationDecision.js.map +1 -1
  184. package/dist/upgrade/runtimeMigration.js +222 -402
  185. package/dist/upgrade/runtimeMigration.js.map +1 -1
  186. package/dist/upgrade/upgradeCommands.js +5 -4
  187. package/dist/upgrade/upgradeCommands.js.map +1 -1
  188. package/dist/upgrade/upgradeLock.js +73 -41
  189. package/dist/upgrade/upgradeLock.js.map +1 -1
  190. package/dist/upgrade/upgradeOrchestrator.js +91 -158
  191. package/dist/upgrade/upgradeOrchestrator.js.map +1 -1
  192. package/dist/upgrade/v3CapabilitySurface.js +2 -2
  193. package/dist/validate/appHomeContract.js +0 -4
  194. package/dist/validate/appHomeContract.js.map +1 -1
  195. package/package.json +7 -5
  196. package/bundle/.codex-plugin/plugin.json +0 -92
  197. package/bundle/.cursor/agents/agentera.md +0 -7
  198. package/bundle/.cursor/hooks.json +0 -32
  199. package/bundle/.cursor-plugin/plugin.json +0 -34
  200. package/bundle/.github/hooks/postToolUse.json +0 -9
  201. package/bundle/.github/hooks/preToolUse.json +0 -8
  202. package/bundle/.github/hooks/sessionEnd.json +0 -8
  203. package/bundle/.github/hooks/sessionStart.json +0 -8
  204. package/bundle/.github/plugin/plugin.json +0 -7
  205. package/bundle/.opencode/agents/agentera.md +0 -12
  206. package/bundle/.opencode/commands/agentera.md +0 -5
  207. package/bundle/.opencode/package.json +0 -31
  208. package/bundle/.opencode/plugins/agentera.js +0 -820
  209. package/bundle/agents/openai.yaml +0 -87
  210. package/bundle/hooks/codex-hooks.json +0 -31
  211. package/bundle/hooks/codex-plugin-hooks.json +0 -31
  212. package/bundle/plugin.json +0 -13
  213. package/bundle/references/adapters/cursor.md +0 -224
  214. package/bundle/references/adapters/opencode.md +0 -529
  215. package/bundle/references/adapters/runtime-adapter-characterization.md +0 -44
  216. package/bundle/references/adapters/runtime-adapter-interface-model.yaml +0 -200
  217. package/bundle/references/adapters/runtime-adapter-registry.yaml +0 -387
  218. package/bundle/references/adapters/runtime-feature-parity.md +0 -129
  219. package/dist/cli/commands/backfill.js +0 -231
  220. package/dist/cli/commands/backfill.js.map +0 -1
  221. package/dist/cli/commands/migrate.js +0 -681
  222. package/dist/cli/commands/migrate.js.map +0 -1
  223. package/dist/registries/runtimeAdapterRegistry.js +0 -324
  224. package/dist/registries/runtimeAdapterRegistry.js.map +0 -1
  225. package/dist/setup/copilot.js +0 -227
  226. package/dist/setup/copilot.js.map +0 -1
  227. package/dist/setup/cursor.js +0 -129
  228. package/dist/setup/cursor.js.map +0 -1
  229. package/dist/setup/cursorSurfaces.js +0 -67
  230. package/dist/setup/cursorSurfaces.js.map +0 -1
  231. package/dist/setup/doctor/core.js +0 -296
  232. package/dist/setup/doctor/core.js.map +0 -1
  233. package/dist/setup/doctor/diagnostics.js +0 -201
  234. package/dist/setup/doctor/diagnostics.js.map +0 -1
  235. package/dist/setup/doctor/opencode.js +0 -301
  236. package/dist/setup/doctor/opencode.js.map +0 -1
  237. package/dist/setup/doctor/report.js +0 -425
  238. package/dist/setup/doctor/report.js.map +0 -1
  239. package/dist/setup/doctor.js +0 -10
  240. package/dist/setup/doctor.js.map +0 -1
  241. package/dist/state/gitBackfill.js +0 -561
  242. package/dist/state/gitBackfill.js.map +0 -1
  243. package/dist/state/gitBackfillAuthority.js +0 -141
  244. package/dist/state/gitBackfillAuthority.js.map +0 -1
  245. package/dist/state/gitBackfillHistory.js +0 -278
  246. package/dist/state/gitBackfillHistory.js.map +0 -1
  247. package/dist/state/gitBackfillOutput.js +0 -209
  248. package/dist/state/gitBackfillOutput.js.map +0 -1
  249. package/dist/state/legacyMigration.js +0 -516
  250. package/dist/state/legacyMigration.js.map +0 -1
  251. package/dist/state/legacyMigrationParser.js +0 -489
  252. package/dist/state/legacyMigrationParser.js.map +0 -1
  253. package/dist/state/migrationAuthority.js +0 -413
  254. package/dist/state/migrationAuthority.js.map +0 -1
  255. package/dist/state/migrationEnrichment.js +0 -35
  256. package/dist/state/migrationEnrichment.js.map +0 -1
  257. package/dist/state/projectionRecovery.js +0 -458
  258. package/dist/state/projectionRecovery.js.map +0 -1
  259. package/dist/upgrade/migrateArtifactsV1ToV2.js +0 -568
  260. package/dist/upgrade/migrateArtifactsV1ToV2.js.map +0 -1
  261. package/dist/validate/lifecycleAdapters/legacyPythonParity.js +0 -93
  262. package/dist/validate/lifecycleAdapters/legacyPythonParity.js.map +0 -1
  263. package/dist/validate/lifecycleAdapters/lifecycleMain.js +0 -154
  264. package/dist/validate/lifecycleAdapters/lifecycleMain.js.map +0 -1
  265. package/dist/validate/lifecycleAdapters/nodeFormChecks.js +0 -481
  266. package/dist/validate/lifecycleAdapters/nodeFormChecks.js.map +0 -1
  267. package/dist/validate/lifecycleAdapters/shared.js +0 -198
  268. package/dist/validate/lifecycleAdapters/shared.js.map +0 -1
  269. package/dist/validate/lifecycleAdapters.js +0 -10
  270. package/dist/validate/lifecycleAdapters.js.map +0 -1
@@ -1,529 +0,0 @@
1
- # OpenCode Adapter
2
-
3
- Maps agentera's host adapter contract (SPEC.md Section 21) and session corpus contract (SPEC.md Section 22) to OpenCode's specific mechanisms. A developer reading only this document can implement portable-core agentera support and a profile-compatible session corpus in OpenCode without reading any skill entry file source code.
4
-
5
- ---
6
-
7
- ## Implementation Status
8
-
9
- Status: production reference (formerly design document).
10
-
11
- | Component | Status | Location |
12
- |-----------|--------|----------|
13
- | Hook plugin | Shipped | `.opencode/plugins/agentera.js` |
14
- | Package-loadable plugin metadata | Shipped | `.opencode/package.json` `main`/`exports` |
15
- | Bare `hej` router | Shipped | `.opencode/plugins/agentera.js` `chat.message` |
16
- | Eval runner support | Shipped | `scripts/eval_skills.py --runtime opencode` |
17
- | Skill install | Documented below | `npx skills add jgabor/agentera -g -a opencode --skill agentera -y` |
18
- | Profile path | Documented below | `~/.config/opencode/profile/PROFILE.md` |
19
-
20
- Routes exact bare text /agentera through chat.message to the bundled Agentera dashboard path. The public docs page omits this hook, but `packages/plugin/src/index.ts` defines `"chat.message"` on the exported `Hooks` interface.
21
-
22
- The plugin was promoted from `references/adapters/opencode-plugin.js` to `.opencode/plugins/agentera.js` and is now the production local-file location. Install it with:
23
-
24
- ```bash
25
- cp .opencode/plugins/agentera.js ~/.config/opencode/plugins/
26
- ```
27
-
28
- `.opencode/package.json` exposes the same file through `main` and `exports` so
29
- OpenCode can also load the adapter as an npm-style plugin package. The package
30
- manifest is not a suite version authority; `.opencode/plugins/agentera.js`
31
- continues to carry the `AGENTERA_VERSION` marker used by release checks.
32
-
33
- ---
34
-
35
- ## Section 21: Host Adapter Capability Mapping
36
-
37
- ### Skill discovery (Required)
38
-
39
- **What agentera requires**: A mechanism to find and load SKILL.md files so the runtime can present available skills to the user.
40
-
41
- **OpenCode mechanism**: OpenCode discovers skills from multiple directory conventions, walking up from the current working directory to the git worktree root.
42
-
43
- OpenCode skill search paths:
44
-
45
- | Location | Scope |
46
- |----------|-------|
47
- | `.opencode/skills/<name>/SKILL.md` | Project-local |
48
- | `.claude/skills/<name>/SKILL.md` | Project-local (Claude Code compatibility) |
49
- | `.agents/skills/<name>/SKILL.md` | Project-local (agent-compatible) |
50
- | `~/.config/opencode/skills/<name>/SKILL.md` | Global |
51
- | `~/.claude/skills/<name>/SKILL.md` | Global (Claude Code compatibility) |
52
- | `~/.agents/skills/<name>/SKILL.md` | Global (agent-compatible) |
53
-
54
- **Adapter approach**: Install agentera's active `skills/agentera/` directory into one of the recognized skill directories. The recommended approach:
55
-
56
- - Global install: `npx skills add jgabor/agentera -g -a opencode --skill agentera -y`
57
- - Project install: symlink or copy `skills/agentera/` into `.opencode/skills/agentera/` or `.agents/skills/agentera/`
58
-
59
- Each Agentera skill entry file contains YAML frontmatter with `name` and `description`, which matches OpenCode's frontmatter requirements exactly. The OpenCode plugin adds one prompt transformation: when the complete user message is exactly bare text `/agentera`, `chat.message` rewrites it to load the bundled `agentera` skill and route through the `agentera prime` dashboard path. The match is exact except for OpenCode's CLI-added single trailing newline transport artifact, and does not apply to `/agentera plan`, `/agentera status`, attachments, or other message parts.
60
-
61
- **OpenCode frontmatter validation** requires: `name` (1-64 chars, lowercase alphanumeric with single hyphens), `description` (1-1024 chars). Agentera entry point names are lowercase, matching the validation regex `^[a-z0-9]+(-[a-z0-9]+)*$`.
62
-
63
- **Skill loading**: OpenCode loads skills on-demand via a native `skill` tool. Agents see available skills listed in the tool description and load full content by calling `skill({ name: "agentera" })`. Agentera works unmodified: it is loaded into the agent's context when invoked.
64
-
65
- **Gap**: None. OpenCode skill discovery supports `.opencode/`, `.claude/`
66
- compatibility, and `.agents/` paths. Agentera skills install cleanly.
67
-
68
- ### Artifact resolution (Required)
69
-
70
- **What agentera requires**: Ability to read and write files at paths specified by DOCS.md or the default layout (project root + `.agentera/`).
71
-
72
- **OpenCode mechanism**: Direct filesystem access. OpenCode agents have full file read/write capabilities through their `read`, `write`, and `edit` tools. The runtime places no restrictions on which paths an agent can access beyond what the host OS enforces.
73
-
74
- **Adapter approach**: No adapter code needed. The default agentera layout (VISION.md, TODO.md, CHANGELOG.md at root; everything else in `.agentera/`) works directly. DOCS.md path overrides are also filesystem paths and resolve normally.
75
-
76
- **Gap**: None. Artifact resolution is pure filesystem access, identical between runtimes.
77
-
78
- ### Profile path (Required)
79
-
80
- **What agentera requires**: A global configuration directory where PROFILE.md lives, readable by all skills that consume the generated profile artifact.
81
-
82
- **OpenCode mechanism**: Global configuration lives in `~/.config/opencode/`. This path is consistent across platforms (Linux and macOS). Managed/admin settings on macOS use `/Library/Application Support/opencode/`, but user-level global config is always `~/.config/opencode/`.
83
-
84
- **Adapter approach**: Place PROFILE.md at `~/.config/opencode/profile/PROFILE.md` (or `~/.config/opencode/PROFILE.md` for simplicity). Update the profile-path references:
85
-
86
- - Skills reference `$AGENTERA_PROFILE_DIR/PROFILE.md` (default: `$XDG_DATA_HOME/agentera/PROFILE.md`) with `<!-- platform: profile-path -->` annotations
87
- - The OpenCode adapter substitutes `~/.config/opencode/profile/PROFILE.md`
88
- - Profile writes to this path when generating the profile
89
-
90
- **Concrete substitution**: In contract.md files, the annotated line:
91
-
92
- ```
93
- Read PROFILE.md from the profile-determined profile path (`$AGENTERA_PROFILE_DIR/PROFILE.md`, defaulting to `$XDG_DATA_HOME/agentera/PROFILE.md` on Linux). <!-- platform: profile-path -->
94
- ```
95
-
96
- becomes in the OpenCode context:
97
-
98
- ```
99
- Read PROFILE.md from the runtime-provided profile path (Section 21). In OpenCode, this resolves to `~/.config/opencode/profile/PROFILE.md`.
100
- ```
101
-
102
- **Gap**: None. The path convention is straightforward. The XDG-compliant location is well-established.
103
-
104
- ### Sub-agent dispatch (Capability-gated)
105
-
106
- **What agentera requires**: Ability to spawn subordinate agents with workspace isolation for parallel implementation tasks.
107
-
108
- **OpenCode mechanism**: OpenCode has a built-in subagent system:
109
-
110
- 1. **Subagents via Task tool**: Primary agents can invoke subagents (e.g., `@general`, `@explore`) using the Task tool. These run in child sessions within the same project. Custom subagents can be defined via JSON config or markdown files in `.opencode/agents/` or `~/.config/opencode/agents/`.
111
-
112
- 2. **Git worktree isolation (manual)**: OpenCode does not include a built-in worktree primitive. Workspace isolation can be achieved by using standard `git worktree` commands before dispatching subagents, then merging branches after completion.
113
-
114
- **Adapter approach**: Map agentera's worktree isolation to one of two strategies:
115
-
116
- **Strategy A: Single agent dispatch (D73)**
117
-
118
- - A single Agentera primary agent (`agentera.md`) in `.opencode/agents/`
119
- - The agent loads the Agentera skill for routing, runs `agentera prime --context <capability> --format json` to fetch instructions, then dispatches to a built-in `general` subagent
120
- - Descriptor frontmatter uses `description` and `mode: primary` with broad `permission` (write+bash allow)
121
- - Agentera ownership is recorded in a body comment marker
122
- - The OpenCode plugin copies the agent descriptor to `~/.config/opencode/agents/` on startup
123
- - The orchestrating skill (build, orchestrate) uses `@agentera` to invoke work
124
- - Limitation: runs in the same working tree, not isolated. Suitable for non-destructive work.
125
-
126
- **Strategy B: Manual git worktree (full isolation parity)**
127
-
128
- - Create a git worktree via `git worktree add` before dispatching
129
- - Dispatch a subagent into the worktree directory
130
- - Merge the branch and clean up the worktree after completion
131
- - Provides true parallel implementation with independent branches
132
- - Requires explicit orchestration in the skill workflow
133
-
134
- **Concrete mapping for build Step 5 dispatch**:
135
-
136
- ```
137
- # Runtime-neutral requirement
138
- Spawn an implementation agent in an isolated worktree
139
-
140
- # OpenCode Strategy A
141
- Invoke the Agentera agent (@agentera) with the implementation plan
142
-
143
- # OpenCode Strategy B
144
- git worktree add ../worktree-branch branch-name
145
- Dispatch @agentera with cwd set to ../worktree-branch
146
- After completion: git merge, git worktree remove
147
- ```
148
-
149
- **Gap**: Strategy A lacks workspace isolation (same working tree). Strategy B requires manual git worktree orchestration in the skill workflow. Agentera v2 ships managed descriptors, so the remaining gap is isolation, not descriptor availability.
150
-
151
- ### Eval mechanism (Capability-gated)
152
-
153
- **What agentera requires**: Ability to invoke a skill against a prompt and capture the output for behavioral verification.
154
-
155
- **OpenCode mechanism**: OpenCode supports non-interactive execution via CLI:
156
-
157
- ```bash
158
- opencode run "Run one autonomous development cycle."
159
- ```
160
-
161
- This pipes a prompt to OpenCode and returns the agent's response. The output format is text by default, but structured JSON is available:
162
-
163
- ```bash
164
- # Text output (default)
165
- opencode run "Explain closures in JavaScript"
166
-
167
- # Raw JSON event stream
168
- opencode run --format json "Explain closures in JavaScript"
169
- ```
170
-
171
- The `--format json` flag produces a raw JSON event stream. Each event is a
172
- separate JSON object representing a message part, tool call, or status update.
173
-
174
- For long-running sessions, OpenCode's server mode provides an HTTP API with the same structured output:
175
-
176
- ```bash
177
- opencode serve --port 4096
178
- # Then POST to the API with session creation and message sending
179
- ```
180
-
181
- **Adapter approach**: The eval runner invokes `opencode run --format json`
182
- directly and parses OpenCode's event schema. The dispatch wrapper:
183
-
184
- ```python
185
- def dispatch_opencode(skill_name: str, prompt: str) -> dict:
186
- result = subprocess.run(
187
- ["opencode", "run", "--format", "json", prompt],
188
- capture_output=True, text=True, timeout=120
189
- )
190
- return {"output": result.stdout, "exit_code": result.returncode}
191
- ```
192
-
193
- **Gap**: Minimal. `opencode run --format json` provides structured JSON events.
194
- The eval runner uses a dedicated OpenCode parser. For smoke tests, text output
195
- with exit-code checking is also sufficient.
196
-
197
- ### Hook lifecycle (Optional but recommended)
198
-
199
- **What agentera requires**: Callbacks at session start, session stop, before tool use for hard-gated artifact validation, and after tool use for validation warnings.
200
-
201
- **OpenCode mechanism**: OpenCode provides a rich plugin event system. Session lifecycle events arrive through the generic `event` hook as `event.type` payload values. The documented plugin example branches on `event.type === "session.idle"` inside `event`, and the local `@opencode-ai/plugin` types expose `event?: ({ event }) => Promise<void>`. The plugin source `packages/plugin/src/index.ts` also exposes `"chat.message"` and `"experimental.session.compacting"` on the exported `Hooks` interface.
202
-
203
- | Agentera hook | OpenCode event | Notes |
204
- |---------------|----------------|-------|
205
- | SessionStart | `event` hook with `event.type === "session.created"` | Observation only unless a supported context-injection hook is also used |
206
- | Stop | `event` hook with `event.type === "session.idle"` | Fires when a session reaches idle state |
207
- | Exact bare `/agentera` | `chat.message` | Rewrites only the complete text message `/agentera` so the bundled `agentera` skill owns the dashboard path |
208
- | PreToolUse | `tool.execute.before` | Blocks invalid reconstructable artifact candidates by throwing an error |
209
- | PostToolUse | `tool.execute.after` | Fires after every tool execution |
210
- | Compaction context | `experimental.session.compacting` | Appends bounded Agentera state from `agentera prime --format json` |
211
-
212
- OpenCode plugins subscribe to session events by exporting one generic `event` hook:
213
-
214
- ```javascript
215
- export const AgenteraPlugin = async ({ project, client, $, directory, worktree }) => {
216
- return {
217
- event: async ({ event }) => {
218
- if (event.type === "session.idle") {
219
- // Stop equivalent: persist session bookmark
220
- }
221
-
222
- if (event.type === "session.created") {
223
- // SessionStart observation point.
224
- }
225
- },
226
- "tool.execute.before": async (input, output) => {
227
- // PreToolUse equivalent: deny invalid reconstructable artifact candidates
228
- },
229
- "tool.execute.after": async (input, output) => {
230
- // PostToolUse equivalent: report validation warnings
231
- },
232
- "chat.message": async (input, output) => {
233
- // Exact bare /agentera prompt rewrite.
234
- },
235
- "experimental.session.compacting": async (input, output) => {
236
- // Append bounded Agentera CLI state context.
237
- }
238
- }
239
- }
240
- ```
241
-
242
- **Adapter approach**: Implement agentera's three hooks as an OpenCode plugin in `.opencode/plugins/agentera.js`:
243
-
244
- Install-root semantics used by the plugin are contract-bound to `scripts/install_root.py` and `.agentera/install_root_interface_model.yaml`. OpenCode still keeps one temporary adapter-local compatibility exception for older manual `~/.agents/skills/agentera` installs; new install-root behavior should change the shared Module/fixture first, not add more JavaScript-local root identity rules.
245
-
246
- OpenCode runtime facts are owned by the RuntimeAdapter registry at `references/adapters/runtime-adapter-registry.yaml` and loaded through `scripts/runtime_adapter_registry.py`. This reference describes the OpenCode adapter behavior, but registry-owned values such as event support, artifact-validation claims, config targets, diagnostic labels, and documentation claims must be validated against the registry rather than changed here as an independent source. The install-root Module must keep package manifest registry and package metadata consolidation work outside its scope.
247
-
248
- Registry parity claims: Blocks invalid reconstructable artifact candidates. Routes exact bare text /agentera through chat.message to the bundled Agentera dashboard path.
249
-
250
- 1. **SessionStart** (`event.type === "session.created"`): Observe session creation through the event hook. Session-start context preload remains deferred because no supported model-context injection path is verified for this adapter. Do not attach dead preload code to event observation alone.
251
-
252
- 2. **PreToolUse** (`tool.execute.before`): When `write` or `edit` args expose a path plus candidate content or exact replacement evidence, validate the candidate through `hooks/validate_artifact.py`. Throw an error to block invalid artifact content before mutation. Sparse payloads and `apply_patch` `patchText` without reconstructed full content are allowed rather than guessed.
253
-
254
- 3. **Exact bare `/agentera`** (`chat.message`): If the incoming user message has exactly one meaningful text part and that text is exactly `/agentera` after removing only OpenCode's CLI-added single trailing newline transport artifact, replace that text with an Agentera routing prompt that preserves the original-message fact and instructs the agent to run `agentera prime` instead of replying with a generic greeting. This is intentionally not a broad greeting detector.
255
-
256
- 4. **PostToolUse** (`tool.execute.after`): After `write` or `edit`, run the shared artifact validator for warnings. This is advisory because the mutation already happened.
257
-
258
- 5. **Compaction context** (`experimental.session.compacting`): Before OpenCode compacts a session, append a bounded Agentera project-state summary generated by `agentera prime --format json`. This hook is CLI-first by design and does not read `.agentera` artifacts directly.
259
-
260
- 6. **Stop** (`event.type === "session.idle"`): Append a runtime-local bookmark entry under the Agentera data directory capturing artifact changes for next-session continuity.
261
-
262
- **Adapter note**: OpenCode plugins run in-process (JavaScript/TypeScript), not as separate Python scripts. Shared Agentera validators are invoked through `uv run` so their inline script metadata can resolve dependencies consistently:
263
-
264
- ```javascript
265
- const result = await $`uv run /path/to/hooks/validate_artifact.py`.quiet()
266
- ```
267
-
268
- This keeps the plugin thin while matching the packaged Python script contract.
269
-
270
- ---
271
-
272
- ## Section 22: Session Corpus Mapping
273
-
274
- Profilera mines five canonical record types from host session data. This section maps each record type to OpenCode's data sources.
275
-
276
- ### memory_entry (retired historical-import extension)
277
-
278
- **Agentera contract**: This retired-source record type is not part of the
279
- portable active corpus. It may appear only in explicitly consented historical
280
- imports and remains excluded from default analytics.
281
-
282
- **OpenCode source**: OpenCode does not have a built-in memory system. The memory_entry extension does not apply.
283
-
284
- **Gap**: None. memory_entry is not a portable requirement. OpenCode adapters need not implement it.
285
-
286
- ### instruction_document
287
-
288
- **Agentera contract**: Global or project-scoped instruction files the host exposes to agents.
289
-
290
- **OpenCode source**: OpenCode has explicit support for instruction documents at multiple levels:
291
-
292
- | Source | Scope | Notes |
293
- |--------|-------|-------|
294
- | `~/.config/opencode/AGENTS.md` | Global | Personal rules applied across all sessions |
295
- | `<project>/AGENTS.md` | Project | Project-specific rules, committed to git |
296
- | `<project>/CLAUDE.md` | Project | Claude Code compatibility (fallback if no AGENTS.md) |
297
- | `opencode.json` `instructions` | Configurable | Explicit list of paths and glob patterns |
298
- | Remote URLs in `instructions` | Configurable | Web-hosted instruction files |
299
-
300
- **Adapter extraction**: Straightforward. Read each instruction source and produce an instruction_document record:
301
-
302
- ```python
303
- {
304
- "source_id": f"opencode:instruction:{scope}:{name}",
305
- "timestamp": iso_now,
306
- "project_id": project_id,
307
- "source_kind": "instruction_document",
308
- "runtime": "opencode",
309
- "adapter_version": "1.0.0",
310
- "doc_type": "agents_md",
311
- "name": name,
312
- "content": file_content,
313
- "scope": scope # "global" or "project"
314
- }
315
- ```
316
-
317
- **Gap**: None. OpenCode supports remote URLs, glob patterns, and explicit config.
318
-
319
- ### history_prompt
320
-
321
- **Agentera contract**: Decision-rich prompts from the host's command history.
322
-
323
- **OpenCode source**: OpenCode stores session data in its internal database. Sessions are accessible via the SDK:
324
-
325
- ```typescript
326
- // OpenCode SDK session access
327
- const sessions = await client.session.list()
328
- const messages = await client.session.messages({ path: { id: session.id } })
329
- ```
330
-
331
- The SDK exposes message history with timestamps, project context, and session metadata.
332
-
333
- **Adapter extraction**:
334
-
335
- 1. Enumerate sessions via `opencode session list --format json`
336
- 2. Export each session via `opencode export [sessionID]`
337
- 3. Filter for user-originated messages from the export JSON
338
- 4. Apply the shared decision-pattern classifier to label prompts as `"decision"`, `"correction"`, or `"question"`
339
- 5. Produce history_prompt records with session and project metadata
340
-
341
- ```python
342
- {
343
- "source_id": f"opencode:history:{session_id}:{message_index}",
344
- "timestamp": message_timestamp,
345
- "project_id": project_id,
346
- "session_id": session_id,
347
- "source_kind": "history_prompt",
348
- "runtime": "opencode",
349
- "adapter_version": "1.0.0",
350
- "prompt": user_message_text,
351
- "signal_type": classify_signal(user_message_text)
352
- }
353
- ```
354
-
355
- **Gap**: Reduced. OpenCode provides CLI-based session data access via two mechanisms:
356
-
357
- 1. `opencode session list --format json`: Lists sessions with metadata (timestamps, project, title).
358
- 2. `opencode export [sessionID]`: Exports full session data (messages, tool calls, metadata) as JSON.
359
-
360
- The `opencode export` output is a JSON dump of the session, which can be parsed to extract user prompts, classify signal types, and produce history_prompt records without requiring SDK access. The adapter can shell out to `opencode session list --format json` to enumerate sessions, then `opencode export <id>` for each.
361
-
362
- The SDK approach remains preferable for programmatic integration (e.g., as an OpenCode plugin), but CLI-based extraction is viable for the initial port. This source family no longer needs to be deferred.
363
-
364
- ### conversation_turn
365
-
366
- **Agentera contract**: Normalized user or assistant turns from host conversation sessions.
367
-
368
- **OpenCode source**: Same session data as history_prompt, but capturing the full user-assistant exchange pairs.
369
-
370
- **Adapter extraction**:
371
-
372
- 1. Enumerate sessions via `opencode session list --format json`
373
- 2. Export each session via `opencode export [sessionID]`
374
- 3. Extract paired user-assistant turns from the export JSON
375
- 4. Classify user turns by signal type (decision, correction, question)
376
- 5. Include preceding_context for turns that respond to assistant proposals
377
-
378
- ```python
379
- {
380
- "source_id": f"opencode:turn:{session_id}:{turn_index}",
381
- "timestamp": turn_timestamp,
382
- "project_id": project_id,
383
- "session_id": session_id,
384
- "source_kind": "conversation_turn",
385
- "runtime": "opencode",
386
- "adapter_version": "1.0.0",
387
- "actor": "user" or "assistant",
388
- "content": turn_text,
389
- "preceding_context": prior_assistant_proposal, # for user turns
390
- "signal_type": signal_classification
391
- }
392
- ```
393
-
394
- **Gap**: Same as history_prompt: reduced. `opencode export [sessionID]` provides full session JSON including paired user-assistant turns. CLI-based extraction is viable for the initial port.
395
-
396
- ### project_config_signal
397
-
398
- **Agentera contract**: Recurring configuration or toolchain patterns associated with a project.
399
-
400
- **OpenCode source**: OpenCode projects are standard filesystem directories. Config files are accessible via direct file reads.
401
-
402
- **Adapter extraction**: Scan the project root for known config types:
403
-
404
- - `package.json`, `go.mod`, `Cargo.toml`, `pyproject.toml`
405
- - `.golangci.yml`, `tsconfig.json`, `ruff.toml`
406
- - `Makefile`, `magefile.go`, `justfile`, `taskfile.yaml`
407
-
408
- No runtime-specific adaptation is needed; the config scan is runtime-agnostic.
409
-
410
- ```python
411
- {
412
- "source_id": f"opencode:config:{project_id}:{config_type}",
413
- "timestamp": iso_now,
414
- "project_id": project_id,
415
- "project_path": project_path,
416
- "source_kind": "project_config_signal",
417
- "runtime": "opencode",
418
- "adapter_version": "1.0.0",
419
- "config_type": config_type,
420
- "file_path": relative_path,
421
- "signals": extracted_key_values
422
- }
423
- ```
424
-
425
- **Gap**: None. Filesystem-based extraction is runtime-agnostic.
426
-
427
- ---
428
-
429
- ## Source family availability
430
-
431
- Summary of which corpus families the OpenCode adapter can produce:
432
-
433
- | Family | Record types | Available? | Mechanism |
434
- |--------|-------------|------------|-----------|
435
- | Crystallized decisions | instruction_document | Yes | AGENTS.md files (global and project), instructions config |
436
- | Decision history | history_prompt | Yes (CLI) | `opencode session list --format json` enumerates sessions; `opencode export [sessionID]` provides full message JSON for prompt extraction |
437
- | Conversation exchanges | conversation_turn | Yes (CLI) | `opencode export [sessionID]` provides full session JSON with paired user-assistant turns |
438
- | Config patterns | project_config_signal | Yes | Direct filesystem scan |
439
-
440
- **Initial port profile mode**: Full. All four source families are available via included OpenCode functionality. Crystallized decisions come from AGENTS.md files and instructions config. Decision history and conversation exchanges come from `opencode export` CLI output. Config patterns come from direct filesystem scan.
441
-
442
- ---
443
-
444
- ## Installation
445
-
446
- Install the OpenCode-targeted Agentera suite with the skills installer:
447
-
448
- ```bash
449
- npx skills add jgabor/agentera -g -a opencode --skill agentera -y
450
- ```
451
-
452
- Do not add `--skill '*'` for OpenCode. The `-a opencode` target selects the supported OpenCode skill surface without selecting every agent. The OpenCode plugin is a separate hook and command adapter; it does not install skills by itself.
453
-
454
- ### Manual global fallback
455
-
456
- OpenCode discovers skills at `skills/*/SKILL.md` one level under its search directories. Because Agentera's active skill is nested at `skills/agentera/SKILL.md` within the repo, cloning the whole repo into a search directory would place it two levels deep and OpenCode would not find it. If the installer is unavailable, link the active skill directory directly.
457
-
458
- ```bash
459
- mkdir -p ~/.config/opencode/skills
460
- ln -s ~/git/agentera/skills/agentera ~/.config/opencode/skills/agentera
461
- ```
462
-
463
- OpenCode discovers the active skill from `~/.config/opencode/skills/agentera/SKILL.md`.
464
-
465
- ### Project install
466
-
467
- ```bash
468
- mkdir -p .opencode/skills
469
- ln -s /path/to/agentera/skills/agentera .opencode/skills/agentera
470
- ```
471
-
472
- Or use `.agents/skills/` for the same effect (agent-compatible search path).
473
-
474
- ### Configuration
475
-
476
- No `opencode.json` configuration is required. Skills are discovered and loaded automatically.
477
-
478
- Optional: configure skill permissions if you want to gate certain skills:
479
-
480
- ```json
481
- {
482
- "permission": {
483
- "skill": {
484
- "*": "allow"
485
- }
486
- }
487
- }
488
- ```
489
-
490
- ### Hook plugin (optional)
491
-
492
- For artifact validation and session continuity, install the agentera hook plugin:
493
-
494
- ```bash
495
- cp .opencode/plugins/agentera.js ~/.config/opencode/plugins/
496
- ```
497
-
498
- ### Install health and managed surfaces
499
-
500
- Installer update status and Agentera app validation are separate checks. `npx skills update -g -y` can report a current package while the managed app is still unhealthy, for example when a support file is missing or a skill path is broken. Agentera validation checks the app home and managed app for shared files and references; installer update status only reflects package-manager state.
501
-
502
- OpenCode repair is ownership-gated. Managed slash commands include `agentera_managed: true` frontmatter, and the command directory stores `.agentera-version`. Repair may overwrite missing or stale managed command files. Same-name command files without that marker are user-owned collisions and must be skipped, not overwritten. Managed skill-path repair follows the same rule: repair Agentera-created OpenCode skill links or directories, preserve user-owned paths, and report skipped collisions.
503
-
504
- `scripts/setup_doctor.py` is diagnostic-only for OpenCode. It reports the plugin file, `AGENTERA_HOME` or documented default app homes, and invalid managed app roots, but it does not mutate OpenCode config or repair OpenCode skills.
505
-
506
- ---
507
-
508
- ## Remaining gaps
509
-
510
- | Gap | Impact | Mitigation |
511
- |-----|--------|------------|
512
- | Sub-agent dispatch lacks built-in worktree isolation | build/orchestrate run in same working tree | Strategy A (Task tool) for initial port; manual `git worktree` commands for full isolation |
513
- | `opencode run --format json` uses an OpenCode-specific event schema | Eval runner needs a dedicated parser | Use the OpenCode parser module in eval_skills.py; event stream structure is straightforward |
514
- | Session history requires JSON event schema mapping | history_prompt and conversation_turn need export parser | `opencode export [sessionID]` provides full session JSON; adapter parses the export output |
515
- | Python scripts require Python runtime | Hook plugin calls Python via shell | Python is already a prerequisite for agentera scripts |
516
-
517
- ---
518
-
519
- ## Validation
520
-
521
- To verify the adapter is sufficient, check each acceptance criterion from PLAN.md Task 4:
522
-
523
- 1. **Each of the six host capabilities is mapped**: Yes. Skill discovery, artifact resolution, and profile path have direct OpenCode equivalents with no gaps. Sub-agent dispatch maps to the Task tool (with manual git worktree as an alternative). Eval mechanism maps to `opencode run --format json`. Hook lifecycle maps to the plugin event system.
524
-
525
- 2. **Session Corpus Contract is mapped per record type**: Yes. All four portable record types are mapped. instruction_document and project_config_signal have immediate extraction paths. history_prompt and conversation_turn are extractable via `opencode export` CLI output. The retired historical-import extension does not apply to OpenCode.
526
-
527
- 3. **A developer can implement OpenCode support without reading skill entry file source**: Yes. This document specifies the adapter mapping, installation steps, extraction logic, and remaining gaps independently.
528
-
529
- 4. **Every required capability and normalized corpus source family is addressed**: Yes. All six capabilities and all five record types are addressed, with explicit availability status and implementation paths for each.
@@ -1,44 +0,0 @@
1
- # Runtime adapter characterization
2
-
3
- The executable lifecycle contract is split deliberately:
4
-
5
- - `runtime-lifecycle-authority.yaml` owns active identities, surfaces, evidence,
6
- support-floor rules, the Cursor alias, and retired inputs;
7
- - `runtime-lifecycle-adapters.yaml` owns the common eight-category adapter
8
- claims and declared Agentera-managed resources;
9
- - `runtime-lifecycle-operation-contract.yaml` owns operation and ownership
10
- semantics;
11
- - `runtime-retired-resources.yaml` owns bounded legacy cleanup;
12
- - `runtime-adapter-registry.yaml` retains host-event and behavioral parity facts
13
- and must match the lifecycle authority's four identities.
14
-
15
- ## Characterized identities
16
-
17
- | Runtime ID | Required host surface | Additional surface | Lifecycle source highlights |
18
- | --- | --- | --- | --- |
19
- | `opencode` | OpenCode host | — | plugin and single Agentera agent |
20
- | `codex` | Codex CLI | — | plugin hooks, copied hooks, capability TOML agents |
21
- | `cursor` | Cursor Agent CLI | Cursor IDE when observed | IDE plugin, hooks, and Agentera descriptor |
22
- | `copilot` | GitHub Copilot CLI | — | plugin manifests and lifecycle hooks |
23
-
24
- The inactive `cursor-agent` spelling identifies the Cursor CLI binary/source
25
- product only. Claude is absent from adapter records and can appear only in the
26
- retired cleanup or explicit historical-import contracts.
27
-
28
- ## Diagnosis and remediation
29
-
30
- Every adapter reports `skills`, `plugins`, `hooks`, `agents`, `configuration`,
31
- `enablement`, `trust`, and `native_actions`. Evidence is read-only. Trust is
32
- never inferred. Managed repair is planned through the shared operation engine;
33
- native and user-owned work is returned as `action_required`.
34
-
35
- Preview has no side effects. Apply requires declared destinations and matching
36
- ownership-journal evidence, uses secure directory-relative publication on
37
- Linux, continues independent operations after failure, and converges on retry.
38
-
39
- ## Validation
40
-
41
- `agentera check validate lifecycle-adapters` rejects identity drift, missing
42
- runtime/category/surface claims, unsafe destinations, unverified mandatory
43
- skills, missing package manifests, unbundled lifecycle sources, version drift,
44
- retired Claude manifests, and stale runtime-specific hook claims.