@awebai/oats 0.24.0 → 0.24.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/README.md +224 -394
  2. package/bin/oats.mjs +192 -13
  3. package/capabilities/oats-aweb/bin/oats-aweb-binding.mjs +11 -0
  4. package/capabilities/oats-aweb/bin/oats-aweb.mjs +26 -0
  5. package/capabilities/oats-aweb/lib/binding-wire.mjs +214 -0
  6. package/capabilities/oats-aweb/lib/captured-execution.mjs +91 -0
  7. package/capabilities/oats-aweb/lib/captured-native.mjs +91 -0
  8. package/capabilities/oats-aweb/lib/invocation-shape.mjs +135 -0
  9. package/capabilities/oats-aweb/lib/portable-binding.mjs +146 -0
  10. package/capabilities/oats-aweb/lib/session-readiness.mjs +56 -0
  11. package/capabilities/oats-aweb/oats.json +12 -3
  12. package/capabilities/oats-okf/lib/captured-worker.mjs +12 -4
  13. package/capabilities/oats-okf/oats.json +1 -1
  14. package/docs/capabilities.md +4 -0
  15. package/docs/design/2026-09-20-redesign-program-board.md +83 -0
  16. package/docs/design/2026-09-20-workspace-and-portable-adoption-plan.md +287 -0
  17. package/docs/design/2026-09-20-workspace-onboarding-public.md +124 -0
  18. package/docs/design/README.md +42 -0
  19. package/docs/first-team.md +43 -1
  20. package/docs/knowledge-theory.md +353 -111
  21. package/docs/knowledge.md +10 -1
  22. package/docs/layers.md +89 -354
  23. package/docs/official-marketplace.md +84 -0
  24. package/docs/packages.md +15 -7
  25. package/docs/release-notes/v0.24.1.md +17 -0
  26. package/docs/release-notes/v0.24.2.md +21 -0
  27. package/docs/souls-and-instances.md +45 -7
  28. package/docs/workspace-adoption.md +314 -0
  29. package/docs/workspaces.md +154 -0
  30. package/injects/oats-portable.md +8 -5
  31. package/lib/core.mjs +89 -17
  32. package/lib/portable-onboarding.mjs +19 -0
  33. package/lib/prepared-resources.mjs +1 -1
  34. package/lib/provider-binding-broker.mjs +6 -1
  35. package/lib/setup-expert-source.mjs +76 -0
  36. package/package-catalog.json +9 -5
  37. package/package.json +3 -1
  38. package/skills/oats-config/SKILL.md +4 -5
  39. package/skills/oats-portable/SKILL.md +1 -2
  40. package/skills/oats-portable-artifacts/SKILL.md +2 -2
  41. package/souls/oats-setup-expert/AGENTS.md +60 -0
  42. package/souls/oats-setup-expert/soul.yaml +14 -0
  43. package/skills/oats-portable-setup/SKILL.md +0 -69
@@ -0,0 +1,21 @@
1
+ # OATS v0.24.2 — `oats onboard`, official capabilities in a soul's definition, aweb 1.11.0 pairing
2
+
3
+ Kernel/Pi/Desktop **0.24.2**. Publication is not deployment: every operator still installs, approves and qualifies locally.
4
+
5
+ ## What changed
6
+
7
+ - **`oats onboard [--dir <deployment>] [--workspace <git:source[@rev]>] [--force-existing] [--json]`** — bootstrap a deployment with an **`oats-setup-expert`** soul that holds `oats.core` and `oats.setup`. Acquires the official `oats.framework` package through the existing engine (resources-only guard before commit, no catalog auto-trust), activates exactly those two capabilities for that soul, writes its definition with both pinned at the acquired immutable commit, and **prints** the spawn command — it never launches a model. Classic local bootstrap, not captured preparation. `oats setup` (record capture setup) is unchanged.
8
+ - **Soul creation declares `oats.core` explicitly.** `oats create` and new local souls write `requires.capabilities.oats.core` resolved from the official catalog; `--no-oats-core` opts out; nothing is invented when the catalog has no entry. When a soul declares `oats.core` or `oats.setup`, the kernel composes **neither** the legacy kernel skills (`oats`, `oats-config`, `oats-packages`) nor the `kernel:oats` injection — the capability's skills are the operational curriculum. Souls without it keep legacy behavior; `oats doctor` prints an informational line.
9
+ - **Official capabilities.** `oats.framework` **1.1.1** (tag `oats-framework/v1.1.1`) exports `oats.core` (`oats-operate`, `oats-souls`, "you run on OATS" briefing), `oats.setup` (`oats-config`, `oats-packages`, `oats-workspace-setup` — now documenting the operator request shape) and `oats.knowledge-theory`. Listed in the official catalog with capability aliases.
10
+ - **Retained inspection projects `launchSelection`** (`{runtime, model}` or `null`) for the primary from the verified retained record; provider binding codecs receive the same-kernel `OATS_CLI_BIN` after the environment scrub. These are what a provider `check` needs to be truthful about the primary's profile.
11
+ - **aweb 1.11.0 pairing.** The catalog and all framework soul editions pin `oats.aweb@v1.11.0`, which adds the portable binding interface (floor `>=0.24.2`). Its `check` qualifies HOME-route operational custody only: explicit private team, `delivery: session`, an input-capable Claude/Codex primary. A strict-Pi print primary reports `needs-configuration`; the requirement is never dropped.
12
+ - **Six framework soul editions** exported and imported by `oats-workspace.yaml`: the five knowledge-owning experts (`oats-expert`, `oats-kernel-expert`, `oats-desktop-expert`, `market-research-expert`, `oats-assistant`) at `caa341f3` and `oats-setup-expert` at `0aad753c`. All six declare `oats.core` from the repository's own payload.
13
+ - Baseline hygiene: golden fixtures use a genuinely empty catalog; the package check lazy-loads dev validators so syntax-only lanes work without `node_modules`.
14
+
15
+ ## Second-operator gate
16
+
17
+ An independent operator on a fresh machine adopted the shared definition from public sources through `inspect` → `prepare` → approvals with 0.24.1: the whole graph (including `oats.core`/`oats.setup`) resolved and materialized; preparation stopped at aweb 1.10.3 as declared. Five usability seams were recorded (request-file mismatch between `inspect`/`prepare`, raw ENOENT on an absent deployment, `trust --dir` rejecting lock v3, `--artifact-set` missing from help, unattributed provider problems). **They are not fixed in this cut**; see the [program board](../design/2026-09-20-redesign-program-board.md).
18
+
19
+ ## Not in this cut
20
+
21
+ Desktop marketplace view / soul creation UI, legacy `agents/` roster and in-soul knowledge decommission (after the fresh-reader proof against the public `oats-knowledge`), Pi session-input support.
@@ -1,8 +1,19 @@
1
1
  # Souls and instances
2
2
 
3
- Souls and instances are the two layers the OATS kernel owns. A soul is the
4
- expert. An instance is a named incarnation of that expert, with its own ID,
5
- home, worktree, and lifecycle. It is not the same thing as one chat session.
3
+ Souls and instances are the two layers the OATS kernel owns. A soul defines a
4
+ reusable specialisation. An instance is a named working incarnation, with its own
5
+ ID, home, work view and lifecycle—not necessarily one task or chat session.
6
+
7
+ An instance may be ephemeral, such as a developer or reviewer doing bounded work,
8
+ or long-running, carrying planning, investigation and domain understanding across
9
+ many tasks. Lifetime does not itself change the soul's identity. See the
10
+ [canonical knowledge and specialisation model](knowledge-theory.md) for how skills,
11
+ shared knowledge, working context and state differ.
12
+
13
+ This operational guide includes the configuration-based soul and lifecycle forms.
14
+ Portable source definitions and captured lifecycle have their own versioned scope;
15
+ see the [0.24 release notes](release-notes/v0.24.0.md) rather than assuming every
16
+ legacy example below applies to a captured instance.
6
17
 
7
18
  ## Soul anatomy
8
19
 
@@ -43,12 +54,39 @@ in a soul bundle; see [knowledge](knowledge.md) for its prepared version scope.
43
54
  Future integrations may add expert-specific artifacts such as rule files or
44
55
  runtime-specific guidance, while keeping `AGENTS.md` canonical.
45
56
 
57
+ ## OATS operational knowledge is a capability
58
+
59
+ New souls declare `requires.capabilities.oats.core` with a Git source resolved
60
+ from the official package catalog. `oats create` and new local-soul scaffolds
61
+ write that requirement; `--no-oats-core` explicitly omits it. If the catalog has
62
+ no published revision yet, creation reports `needs-configuration` (also in JSON
63
+ `notes`) and leaves the requirement absent rather than inventing a source.
64
+ Declaring a capability is not acquiring, activating or approving it: those remain
65
+ normal deployment/preparation steps. The Desktop server currently has no
66
+ soul-creation endpoint; `oats soul set` edits existing definitions only.
67
+
68
+ The dependency is visible and removable in `soul.yaml`. Updating an existing
69
+ local soul preserves its requirements—including a deliberate removal—rather
70
+ than applying the creation default again. For the one-release transition,
71
+ a declaration of **either `oats.core` or `oats.setup`** suppresses the entire
72
+ legacy kernel operational skill list (`oats`, `oats-config`, `oats-packages`)
73
+ and `kernel:oats` injection. This also prevents setup's moved skill names from
74
+ colliding with the kernel copies; no skill override is needed for this case.
75
+ Without either declaration, legacy composition is unchanged.
76
+ `oats doctor --soul <name>` reports an absent `oats.core` as an informational
77
+ deprecation notice, not an error. Instance-boundary, work-mode and
78
+ configuration-declared briefings remain kernel-owned. Existing captured records
79
+ keep their retained resources; this does not migrate them or retire the kernel
80
+ skill files yet.
81
+
46
82
  ## Instance anatomy
47
83
 
48
- An instance is transient, but it is not a single chat session. It is the
49
- identity of one instantiated soul while that work is alive. Several sessions,
50
- compactions, restarts, or model switches can happen inside the same instance
51
- before it is retired.
84
+ An instance has a lifecycle, but need not be short-lived. It is the identity of
85
+ one instantiated soul while its assignment is alive. Supported session continuations,
86
+ compactions and restarts can preserve that continuity. Model or harness changes must
87
+ follow the selected execution profile; they are not permission to reinterpret a
88
+ captured recipe. Retirement should account for valuable context and unfinished work,
89
+ not assume an experienced instance is cheap to replace.
52
90
 
53
91
  An instance has a home directory, a task, and a worktree when the work mode
54
92
  needs one. Its runtime setup is composed from the canonical soul plus
@@ -0,0 +1,314 @@
1
+ # Adopt the OATS development workspace
2
+
3
+ OATS hosts the shared `oats-workspace.yaml`. Its separate `oats.yaml` advertises
4
+ source-complete exports and declares its own reciprocal membership. `oats-dev`
5
+ remains a development-capability repository, including `oats.review`; membership
6
+ neither activates that package nor replaces its existing configuration templates.
7
+
8
+ This guide covers the shared repository graph and portable expert source editions,
9
+ beginning with **the existing oats-expert**. Source publication is not a live
10
+ five-role roster or curated knowledge cutover, a shared runtime, private-team
11
+ enrollment or Desktop feature parity.
12
+ The [phase plan](design/2026-09-20-workspace-and-portable-adoption-plan.md) and
13
+ [knowledge model](knowledge-theory.md) retain those separate boundaries.
14
+
15
+ ## The five framework experts
16
+
17
+ The indexed source editions are `oats-expert`, `oats-kernel-expert`,
18
+ `oats-desktop-expert`, `market-research-expert` and `oats-assistant`. Each declares
19
+ `owns` for its own same-named node and `reads` for the other four through logical
20
+ store `oats`, preserving the reviewed owner UUIDs. These are knowledge-routing and
21
+ context declarations, not access grants or proof of accepted knowledge. The parallel
22
+ `souls/` editions neither replace the legacy `agents/` roster nor adopt the curated
23
+ KB or change live instances; actual adoption still needs compatible providers and
24
+ explicit bindings. All five now explicitly declare `oats.core` under
25
+ `requires.capabilities`, with `source: repo:oats-package`. This retains the complete
26
+ package from the same reviewed source revision.
27
+
28
+ The dependency is visible and removable in the authored definition, not a change
29
+ to existing captured records. An edited edition needs its own reviewed publication
30
+ and import update; changing today's source does not rewrite an older pinned import.
31
+
32
+ ## Shared versus local
33
+
34
+ | Git-shared declaration | Operator-local input or evidence |
35
+ | --- | --- |
36
+ | Workspace membership candidates and reviewed source import pins | Local source access and qualified repository observations |
37
+ | A repository's backlink and real package/soul export paths | Working checkout mappings and the explicitly chosen work target |
38
+ | Intrinsic capability requirements and logical knowledge interests | Provider settings, explicit store binding, private human/team choices |
39
+ | Complete immutable instructions and skill resources | Native harness/model/auth, backend endpoint, home and durable state |
40
+ | A reviewed source revision | Exact executable approval, current readiness and deployment acceptance |
41
+
42
+ No machine paths, credentials, private team identifiers, accepted-store locator or
43
+ owner registry belongs in the public workspace. Knowledge publication and acceptance
44
+ (S7) remain separate; no ready knowledge export is advertised. Preserve the parked
45
+ roster/curation and every old home, lock, source, pending job, history and worktree.
46
+
47
+ ## Planned onboarding: OATS Soul Setup (D3)
48
+
49
+ **The D3 onboarding flow remains pending.** It will create and instantiate
50
+ `oats-setup-expert`, declaring both `oats.core` and `oats.setup` from the
51
+ [official marketplace](official-marketplace.md). Those capabilities are now
52
+ published in `oats.framework` 1.1.0 and listed; the separate setup-expert edition
53
+ and onboarding entry point do not become available merely by listing the package.
54
+ This flow was not shipped in the 0.24.0 or 0.24.1 kernel releases.
55
+
56
+ - The setup expert will help the operator adopt repositories, select capabilities
57
+ and carry out the normal prepare/approve/scaffold/start steps. It bypasses no
58
+ executable approval, provider readiness, identity or permission boundary.
59
+ - Every soul created by that flow will declare `requires.capabilities.oats.core`
60
+ and its source explicitly. The operator can remove or replace that dependency
61
+ by editing the authored definition, not a captured record; the kernel will not
62
+ silently reinsert an absent one.
63
+ - The CLI/Desktop entry point still requires separate implementation and review.
64
+ Do not invent a workspace init/adopt command, create a setup soul from this
65
+ sketch, or treat a listed package as installed. Existing instances and retained
66
+ resources are not rewritten by the plan.
67
+
68
+ ## Stage two: published experts and pinned imports
69
+
70
+ - `oats-workspace.yaml` explicitly admits `oats` and the six intended capability
71
+ repositories: `oats-dev`, `oats-okf`, `oats-aweb`, `oats-authoring`, `oats-jira`
72
+ and `oats-linear`. It activates no additional capability; tasks default to none.
73
+ - `oats.yaml` exports all five `souls/<name>` editions above and the actual package
74
+ roots `oats-package` (`oats.framework`) and `capabilities/oats-authoring`, not
75
+ the npm root as a fictitious OATS distribution. Its workspace backlink names
76
+ the same framework repository.
77
+ - The editions are parallel to, not replacements for, the live `agents/` roster.
78
+ Each contains canonical instructions, `CLAUDE.md -> AGENTS.md`, and its reviewed
79
+ private procedures where applicable. No durable KB is copied into them; legacy
80
+ roster cutover remains deferred until S7 knowledge publication.
81
+ - Each edition preserves its knowledge owner, owned node and four cross-reads.
82
+ Store `oats` requires the explicit `stores.oats` binding; no publisher writer,
83
+ production store or grants are supplied. An acceptance fixture is parent-owned
84
+ and cannot be counted as production knowledge adoption.
85
+ - Knowledge **oats.okf@2.1.1** and messaging **oats.aweb@1.11.0** are explicit hard
86
+ requirements, not optional defaults. They are published starting revisions,
87
+ **not proof that their combined bindings/runtime profile is ready**. The provider
88
+ owner supplies that evidence and any subsequently reviewed compatible revision.
89
+ Do not replace either requirement with none or erase a read edge to launch.
90
+
91
+ At these starting pins, the provider boundary is concrete:
92
+
93
+ - Published OKF2.1.1 supports `inherit: stores.oats`, normalized to
94
+ `/bindings/knowledge/stores/oats`. The explicit `destination: oats` preserves
95
+ routing; omitting it would instead require `write.default`. No new schema,
96
+ owner or production locator is needed for this declaration.
97
+ - aweb 1.10.3 (`24efa6f9`) has no portable binding interface; **aweb 1.11.0**
98
+ (`v1.11.0`, OATS >=0.24.2) adds it and the five editions now pin it. Its `check`
99
+ qualifies only an input-capable Claude/Codex primary with an explicit private team
100
+ and `delivery: session`; strict-Pi print reports `needs-configuration`. Status is on
101
+ the [program board](design/2026-09-20-redesign-program-board.md). Qualification
102
+ is HOME-route operational custody only: not human/native-principal delegation,
103
+ private grants, broker delivery or model consumption.
104
+ - Published OKF2.1.1 accepts retained Claude/Codex helpers with the complete approved
105
+ capability closure and native-default model intent. Strict Pi still requires an
106
+ explicit model and the sole-OKF profile; Pi plus messaging remains unqualified.
107
+ This provider release alone is not combined-profile acceptance. Do not silently
108
+ switch runtimes, force a model, or drop capabilities.
109
+
110
+ These are explicit readiness holds, not reasons to weaken the source. Parent must
111
+ select reviewed compatible provider revisions and update the source pin deliberately
112
+ before claiming an operational pilot; metadata-only repository indexes change none
113
+ of these runtime facts.
114
+
115
+ Stage one used an empty imports list until source publication. Stage two is now
116
+ committed: all five imports pin **`caa341f34009e37006567419a983d5a743037a79`**, the
117
+ published edition revision containing explicit core requirements and the package.
118
+ The later workspace commit `375b9f42` added those imports. Live source inspection
119
+ against published main resolved all five as `ready-for-preparation`; this is
120
+ metadata readiness, not provider binding, approval, enrollment or a running pilot.
121
+
122
+ ## Preserve source-before-import publication order
123
+
124
+ 1. Publish complete, reviewed source editions before pinning them. The current
125
+ source is `caa341f34009e37006567419a983d5a743037a79`; future revisions must likewise
126
+ exist before their workspace import update. Never use an invented SHA, a mutable
127
+ branch or an unreviewed local candidate as the accepted source.
128
+ 2. In each of the six repositories, review a root `oats.yaml` against its actual
129
+ source head and actual `oats-package/oats-package.json`. The declaration is:
130
+
131
+ ```yaml
132
+ schemaVersion: 1
133
+ workspace:
134
+ source: git:github.com/awebai/oats
135
+ exports:
136
+ packages:
137
+ - path: oats-package
138
+ ```
139
+
140
+ Preserve payloads, versions, old tags and legacy templates. This does not
141
+ activate oats.dev, messaging or either optional task integration. Indexes are
142
+ published on `main` in all six capability repositories (oats-okf, oats-aweb,
143
+ oats-authoring, oats-jira, oats-dev, oats-linear); their publication proceeded
144
+ separately from the framework's own source imports.
145
+ 3. A subsequent workspace commit pins the published source, never itself or a
146
+ future commit. The current first import is:
147
+
148
+ ```yaml
149
+ imports:
150
+ - source: git:github.com/awebai/oats
151
+ soul: souls/oats-expert
152
+ revision: caa341f34009e37006567419a983d5a743037a79
153
+ alias: oats-expert
154
+ ```
155
+
156
+ The [actual workspace](../oats-workspace.yaml) contains all five imports at that
157
+ same revision; this excerpt is not a replacement for the full list. The layout
158
+ test now checks stage-two imports and source-document declarations. Do not
159
+ change stable export paths or owners merely because the workspace advances.
160
+ 4. Qualify reciprocal admission at the now-published observations. A missing
161
+ backlink, a fork's copied file or a stale workspace observation is not membership.
162
+ Cross-repository indexes may land separately; until both sides exist, report the
163
+ specific unqualified member rather than claim the whole graph is ready.
164
+
165
+ Membership selectors and backlinks omit `revision` deliberately: the repository
166
+ adapter observes the hosting provider's actual default branch, not a guessed
167
+ `main`. Within one preparation, observations are frozen. In particular, the
168
+ framework's self-member and workspace backlink must resolve to the **same commit**.
169
+ A separately pinned older workspace with backlinks resolving to a later head is
170
+ correctly stale; choose a fresh coherent observation, never rewrite an old retained
171
+ record. Imports have their own immutable source revision and need not track each
172
+ new workspace metadata commit.
173
+
174
+ Importing the exported soul directly does **not** follow the publisher's workspace
175
+ as adopter policy. A different workspace, or an explicitly standalone operator,
176
+ may consume it without membership in the OATS development workspace.
177
+
178
+ ## Inspect source metadata before preparation
179
+
180
+ The public source inspector ships in [OATS 0.24.1](release-notes/v0.24.1.md),
181
+ following PR24 integration. Use an installed CLI containing that implementation.
182
+ It is **not supported by the original 0.24.0 release**: that older inspect route
183
+ can ignore the request flag and consult ambient classic configuration. Do not
184
+ infer command availability from a capability's version floor or today's catalog.
185
+
186
+ ```sh
187
+ oats inspect --request /absolute/inspection.json --json
188
+ ```
189
+
190
+ With the stage-two imports published, the authored inspection input can use the
191
+ same repository for workspace, member and source:
192
+
193
+ ```json
194
+ {
195
+ "deployment": "/operator/deployments/oats-pilot",
196
+ "workTarget": "/operator/projects/oats",
197
+ "source": "oats-expert",
198
+ "origin": {
199
+ "kind": "operator",
200
+ "document": {"kind": "operator", "id": "workspace-adoption"},
201
+ "pointer": "/source"
202
+ },
203
+ "workspace": {
204
+ "source": "git:github.com/awebai/oats",
205
+ "origin": {
206
+ "kind": "operator",
207
+ "document": {"kind": "operator", "id": "workspace-adoption"},
208
+ "pointer": "/workspace"
209
+ }
210
+ },
211
+ "member": {
212
+ "source": "git:github.com/awebai/oats",
213
+ "origin": {
214
+ "kind": "operator",
215
+ "document": {"kind": "operator", "id": "workspace-adoption"},
216
+ "pointer": "/member"
217
+ }
218
+ }
219
+ }
220
+ ```
221
+
222
+ The paths are operator-selected examples, not host defaults or new grants.
223
+ Independent adoption uses the full source/soul/revision/alias reference and an
224
+ explicit standalone context instead of workspace/member. Do not mix this inspect
225
+ mode with current-context flags or captured deployment/resolution selectors.
226
+
227
+ The result is **non-authorizing metadata**, not provider readiness: even `ok:true`
228
+ may carry `needs-configuration` or `separate-deployment-required`. A
229
+ `ready-for-preparation` observation still has no approval or enrollment effect.
230
+ Provider payloads and opaque adoption values are deliberately omitted. Preserve
231
+ the original authored inputs; neither the result nor its inspection request is a
232
+ preparation request or an issued mutation witness. In particular, `workTarget`
233
+ and inspection catalog wrappers are not accepted preparation fields.
234
+
235
+ The inspector owns transient repository scratch but writes no deployment state.
236
+ Missing paths need explicit operator provisioning and reinspection, not automatic
237
+ repair. Observing a project work target does not change the separate captured H/work
238
+ placement. Existing retained inspect remains the later exact-record inspection.
239
+
240
+ ## Prepare a fresh local pilot only after the profile is qualified
241
+
242
+ Use the selected installed compatible CLI. Do not turn this source check into a
243
+ global install, a daemon start or a model/GUI test on another operator's machine.
244
+ Keep native HOME/profile/auth and explicit permission choices; no credential copy
245
+ or empty profile. Knowledge, messaging and tasks have distinct authority contracts.
246
+
247
+ Before preparing, the integration lead must supply:
248
+
249
+ - The published workspace/source observations and an explicit fresh physical
250
+ deployment/home placement. Do not copy old locks, retained records or identities.
251
+ - An operator-owned nonsecret request with `workspace` (its source and origin),
252
+ `source: "oats-expert"` (or another published expert alias), and `mode: "directory"`.
253
+ Standalone callers instead give the complete `{source,soul,revision,alias}`
254
+ reference and an explicit standalone context; they do not inherit this workspace.
255
+ - Explicit provider-specific settings and bindings. OKF preparation needs selected
256
+ absolute `bindings-file` and `state-dir`, `harvest-runtime`, and the `stores.oats`
257
+ binding; an omitted `harvest-model` preserves native-default intent. The parent-owned
258
+ acceptance fixture must supply an accepted node registry supporting the preserved
259
+ owner **and all four read nodes**. This is not accepted production KB publication;
260
+ Git destinations remain PR-only.
261
+ - Actual messaging human/context inputs and the pilot's explicit **`delivery: session`**
262
+ setting (aweb's default is channel). Supply it in the complete supported
263
+ `operator.policy.messaging` selection: capability, matching selected source and
264
+ `settings: {delivery: session}`. Retain host requirements, session `ifInstalled`
265
+ minimums and any selected authoring requirements. Selecting session delivery neither
266
+ makes a strict-Pi print primary input-capable nor supplies captured wake authority.
267
+ - A qualified primary/helper runtime/model/resource profile. Capture the intended
268
+ helper selection in `helperLaunches["oats.okf:memory-harvest"]`, not the legacy
269
+ `souls.memory-harvest` configuration. Do not replace retained intent to fit an easier
270
+ runtime profile. An old default-OKF-only learning gate does not qualify a combined
271
+ aweb profile. If provider or kernel support is missing, stop at that typed result;
272
+ do not bypass it with a legacy route, a dropped capability or a fabricated identity.
273
+
274
+ The existing public routes are stepwise (D/R/H are returned or explicitly approved
275
+ values, not names inferred from cwd):
276
+
277
+ ```sh
278
+ oats prepare --request /absolute/operator-preparation.json --json
279
+ # Review returned exact artifacts/problems; approve only explicitly authorized code.
280
+ oats trust <capability-id> --deployment "$D" --artifact-set "$ARTIFACT_SET" --json
281
+ oats prepare --request /absolute/operator-preparation.json --json
282
+ oats inspect --deployment "$D" --resolution "$R" --composition --json
283
+ oats spawn oats-expert --deployment "$D" --resolution "$R" --home "$H" --no-launch --json
284
+ oats session start --deployment "$D" --resolution "$R" --home "$H" \
285
+ --request /absolute/approved-native-request.json --json
286
+ ```
287
+
288
+ Do not mix other preparation flags into request-file mode. A needs-configuration or
289
+ approval result is not a ready instance. A scaffold materializes resources and may
290
+ run approved hooks; it is not a message exchange or model session. Actual dispatch,
291
+ continuation, native capture, messaging and learning require the integration owner's
292
+ qualified profile and receipts. OATS 0.24.1 adds captured custody checks to the
293
+ existing HOME-only session inspect/input route; it does not supply the missing
294
+ messaging adapter or qualify every lifecycle route. Verify wake/input/retirement
295
+ support for the exact route and runtime. A stopped-home observation is not delivery
296
+ or retirement authority, and a messaging profile cannot pass on start-only evidence.
297
+ Do not bypass custody with a legacy fallback or remove the messaging requirement.
298
+ Consult the current installed public help and the provider's supported commands;
299
+ this guide introduces no new CLI grammar. The source inspector above is a separate
300
+ implementation dependency, not a change to the existing prepare request contract.
301
+
302
+ ## Local checks and limits
303
+
304
+ `node --test test/workspace-repository-layout.test.mjs` checks the actual declarations
305
+ against the shipped codecs/schemas, required providers and owner/read mapping, and
306
+ contained source resources. An isolated native-Git fixture exercises source-before-
307
+ import publication, host-default observations, reciprocal/self admission, refusal of
308
+ missing/stale backlinks, and independent public source projection. Fixture member
309
+ indexes are not evidence that the six real repositories are already published.
310
+
311
+ Source and metadata checks do not enroll users, initialize the phase-2 store, register
312
+ production writers or qualify private messaging. Parent alone coordinates publication,
313
+ local operator approval and actual adoption. Full Desktop parity follows usable
314
+ infrastructure adoption, not merely source metadata passing validation.
@@ -0,0 +1,154 @@
1
+ # Workspaces, repositories and portable souls
2
+
3
+ A **workspace definition** describes a shared agent setup in Git. A **local deployment** is one operator's realization of it. A **portable soul** declares its role, requirements and software sources independently of either operator's directory layout.
4
+
5
+ This is the current OATS architecture. Start here for the model, then use [first-team onboarding](first-team.md) and the version-scoped [configuration](configuration.md) and [packages](packages.md) guides for operations. The [0.24 release notes](release-notes/v0.24.0.md) distinguish shipped foundations from unqualified profiles; an accepted architecture is not proof that every capability is ready.
6
+
7
+ ## Four independent things
8
+
9
+ | Thing | What it decides | What it does not imply |
10
+ |---|---|---|
11
+ | Workspace | Intended repository membership, shared defaults, source imports and provider declarations | Installed software, executable approval, messaging enrollment or a shared live session |
12
+ | Source repository | The soul/package/store definitions it actually exports | Membership of every consumer in the publisher's workspace |
13
+ | Local deployment | Local mappings, retained artifacts/resolutions, operator inputs and execution state | Permission to change source requirements or copy another operator's credentials |
14
+ | Work target | Where an instance is assigned to work | Where its soul must be published, where knowledge must live or which team it joins |
15
+
16
+ A workspace needs no OATS account, registry or OATS-operated control plane. Git hosting, messaging and model providers retain their own access and authentication requirements.
17
+
18
+ ## The three declaration files
19
+
20
+ ### `oats-workspace.yaml` — the shared workspace
21
+
22
+ The workspace names intended members and may provide defaults, knowledge-store declarations, team aliases, catalogs and external soul imports. Omitted lists admit or activate nothing.
23
+
24
+ A workspace is a role, not a requirement for a separate repository. It can live in a dedicated repository or beside project code. For OATS development, the selected home is the `oats` framework repository; `oats-dev` remains a development-capability repository.
25
+
26
+ This schematic example uses placeholder sources, not a runnable published team:
27
+
28
+ ```yaml
29
+ schemaVersion: 1
30
+ name: example-development
31
+ members:
32
+ - source: git:github.com/example/service
33
+ imports:
34
+ - source: git:github.com/example/experts
35
+ soul: souls/domain-expert
36
+ revision: reviewed-source-ref
37
+ alias: domain-expert
38
+ ```
39
+
40
+ Use actual reviewed source revisions when preparing work. When a repository reference omits its optional revision, discovery observes the hosting provider's intended default branch; it must not guess `main` or silently reuse unrelated local branch state.
41
+
42
+ ### `oats.yaml` — a repository's advertised exports
43
+
44
+ A repository advertises the souls, package roots and provider-owned knowledge declarations it actually supplies. A member also points back to its workspace:
45
+
46
+ ```yaml
47
+ schemaVersion: 1
48
+ workspace:
49
+ source: git:github.com/example/workspace
50
+ exports:
51
+ souls:
52
+ - path: souls/domain-expert
53
+ definition: souls/domain-expert/soul.yaml
54
+ packages:
55
+ - path: oats-package
56
+ ```
57
+
58
+ Only include exports that exist at the selected revision. A repository need not export every kind. A package export identifies a real directory containing `oats-package.json`; it is not an arbitrary npm package directory.
59
+
60
+ `oats-workspace.yaml` and `oats.yaml` may coexist. If the workspace host also participates as a member, it is explicitly admitted and has a matching backlink just like another member.
61
+
62
+ ### `soul.yaml` — a source-complete specialist
63
+
64
+ A portable soul is an authored definition, not a dependency on whatever happens to be installed on its publisher's machine. It contains canonical `AGENTS.md`, a relative `CLAUDE.md` alias, its reviewed skill/resource closure and a versioned declaration.
65
+
66
+ For example, this declaration excerpt requires a particular knowledge capability **and names where it comes from**:
67
+
68
+ ```yaml
69
+ schemaVersion: 1
70
+ name: domain-expert
71
+ requires:
72
+ knowledge:
73
+ capability: oats.okf
74
+ source: git:github.com/awebai/oats-okf@v2.1.1#oats-package
75
+ ```
76
+
77
+ This illustrates software selection, not complete OKF provisioning: the chosen capability also needs its own valid knowledge declaration, bindings and accepted base.
78
+
79
+ - `requires` expresses hard requirements. A fundamental provider can be required by presence or as a concrete capability/source selection.
80
+ - `defaults` supplies choices that remain rebindable within those requirements.
81
+ - Additive capabilities are named under `requires.capabilities` or `defaults.capabilities`; each concrete selection has a `source`, with optional provider-owned settings.
82
+ - `git:` selects versioned software from a repository/package root. `repo:` refers to a contained path in the declaring source repository, not the caller's working directory. `path:` is an explicitly authorised local development choice, not a remotely portable ambient fallback.
83
+ - Capability IDs alone do not establish software origin. An old `from: installed` config entry is not a substitute for a portable source declaration.
84
+ - A source may contain authored knowledge snapshots or resources, but retained artifacts are not writable knowledge stores. Learning locations and procedures belong to the selected capability.
85
+
86
+ See the [soul schema](soul.schema.json) and [declaration contract](design/2026-09-15-portable-declarations.md). Classic fields such as `kind`, `type` and a machine-local `repo` are not portable declaration fields; do not relabel an old file without validating it.
87
+
88
+ ## Membership and adoption are different
89
+
90
+ **Repository membership is reciprocal:** the workspace admits the repository and the repository's `oats.yaml` points back to that workspace. Both observations must have compatible identity, access context and revision evidence. A copied backlink, neighbouring folder or URL is not admission.
91
+
92
+ **Source adoption is by reference:** an import identifies `source`, exported `soul` path, `revision` and a local `alias`. It may carry supported adoption choices. Importing does not create an adopter-maintained copy of the soul or automatically follow the publisher's workspace backlink.
93
+
94
+ A team can therefore use a public expert without joining its publisher's organization. One source can serve several workspaces or an explicit standalone context, with different legitimate work targets and knowledge bindings.
95
+
96
+ Publish source/export revisions before pinning imports to them. Do not use invented future SHAs or require two repositories to contain each other's not-yet-created commit IDs.
97
+
98
+ ## How requirements and defaults meet
99
+
100
+ The kernel uses one resolver:
101
+
102
+ - Workspace defaults establish shared fallback choices.
103
+ - The soul's own defaults can specialise them.
104
+ - Explicit adoption/operator choices select supported alternatives or supply missing inputs.
105
+ - Hard source requirements remain constraints; a conflicting override is an error, not a reason to discard the requirement.
106
+
107
+ Provider-owned declarations remain opaque to the kernel until the selected provider interprets them through its contract. There is no portable repository-level capability policy tier silently inherited from the publisher, and no mandatory agent-type hierarchy replacing a soul's own requirements.
108
+
109
+ Repository briefing/worktree setup remains work-target behavior with its own supported authority. Merely placing a repository `AGENTS.md` nearby does not guarantee it is composed into every harness's instructions.
110
+
111
+ ## From a definition to a running instance
112
+
113
+ 1. Select an explicit workspace or standalone context, source reference, deployment location and work target.
114
+ 2. Observe actual source identities/revisions and check requested reciprocal membership.
115
+ 3. Resolve requirements, defaults and operator inputs; retain the selected source and software closure.
116
+ 4. Review and approve exact executable artifacts before provider code runs.
117
+ 5. Obtain honest provider readiness and a retained resolution; missing configuration or unsupported behavior remains visible.
118
+ 6. Scaffold and start through the supported captured lifecycle. Preserve the exact source/resources and evidence needed for continuation.
119
+
120
+ An existing instance does not silently adopt a new upstream commit, changed workspace default or different curriculum. Updates prepare new choices deliberately; required knowledge refresh and native credential rotation are separate from rewriting its retained software.
121
+
122
+ A successful lookup is not execution, an accepted dispatch is not completed work, and a declared knowledge destination is not accepted learning.
123
+
124
+ ## What each operator shares or keeps local
125
+
126
+ Share reviewed definitions, relevant nonsecret configuration/provenance, published source references and accepted knowledge through their chosen Git repositories. Keep credentials, private runtime evidence, instance homes and machine-specific realization local. A messaging roster does not replicate any of these.
127
+
128
+ An adopted package config template is an editable local snapshot, not live inheritance from the package. Updating the kernel or package does not rewrite it, migrate a knowledge base or update a running instance's loaded instructions.
129
+
130
+ ## Compatibility and current readiness
131
+
132
+ Classic `oats-config.yaml` scopes, `oats init`, `oats use`, local `agents/` lookup and lock-v2 package restore still have their own supported contracts. They are not renamed portable workspace commands. See [configuration](configuration.md) and [packages](packages.md) for that compatibility surface; do not apply classic lifecycle commands blindly to captured instances.
133
+
134
+ At the documented0.24 baseline, workspace/declaration/retained-execution foundations are shipped. The released `oats.aweb`1.10.3 package lacks the captured provider-binding interface, so its legacy messaging success does not qualify a new captured profile requiring it. Capability adaptation is implementation work, not a YAML setting that can honestly turn readiness green. Follow current [release scope](release-notes/v0.24.0.md) and the provider's actual version/readiness rather than removing requirements.
135
+
136
+ The project's [adoption plan](design/2026-09-20-workspace-and-portable-adoption-plan.md) puts workspace/source adoption first, centralised knowledge and five experts second, and full Desktop parity afterward.
137
+
138
+ ## How a soul knows OATS (accepted direction, not yet shipped)
139
+
140
+ An agent's knowledge of OATS itself — how to check status, spawn and retire, find other souls — is ordinary capability content, not kernel magic:
141
+
142
+ - **`oats.core`** carries day-to-day operation (skills `oats-operate`, `oats-souls`, the "you run on OATS" briefing). Every soul gets it **by default at creation, written explicitly into its definition**; you can remove or replace it.
143
+ - **`oats.setup`** carries deployment/workspace configuration and package knowledge ("OATS Soul Setup"). Onboarding a workspace creates and starts an **`oats-setup-expert`** soul with both, which then adopts repositories and creates the team's other souls.
144
+ - The **official marketplace** is the reviewed package list in the `oats` repository; a package becomes official through an approved PR to that list, and official packages are discoverable from the CLI and Desktop. Discoverable is not installed; installed is not approved.
145
+
146
+ At the0.24 baseline these skills still ship inside the kernel. Work packages D1–D4 of the [adoption plan](design/2026-09-20-workspace-and-portable-adoption-plan.md) track the move.
147
+
148
+ ## Related references
149
+
150
+ - [Souls and instances](souls-and-instances.md)
151
+ - [Capability contracts](layers.md) and [capability authoring/distribution](capabilities.md)
152
+ - [Knowledge model](knowledge-theory.md) and [version-scoped operations](knowledge.md)
153
+ - [Workspace schema](oats-workspace.schema.json) and [repository export schema](oats-member.schema.json)
154
+ - [Design/contract navigation](design/README.md)
@@ -7,11 +7,14 @@ settings, provider bindings, and executable resources come from that exact
7
7
  configuration cascade, package lock, similarly named capability, or source path.
8
8
 
9
9
  Load **oats-portable** before invoking or reasoning about captured OATS commands.
10
- Load **oats-portable-setup** for fresh by-reference preparation and explicit
11
- source/workspace/deployment/work/team choices. Load **oats-portable-artifacts**
12
- for exact retained inspection and approval. Do not load the legacy **oats**,
10
+ Load **oats-portable-artifacts** for exact retained inspection and approval. Do not load the legacy **oats**,
13
11
  **oats-config**, or **oats-packages** procedures to fill a captured input.
12
+ If this retained composition includes **oats.core**, its **oats-operate** and
13
+ **oats-souls** skills are capability resources, not implicit kernel additions.
14
+ Use only the resources actually included; a missing capability is not permission
15
+ to fetch or substitute a current version.
14
16
 
15
- Captured start/restart/wake/retire, managed launch/runtime and non-directory work
16
- are not yet public. If a command is unsupported or retained authority is missing,
17
+ Captured start/restart use exact retained launch inputs and supported native
18
+ endpoints. Captured wake/retire, unqualified runtime contributions and non-directory
19
+ work remain held. If a command is unsupported or retained authority is missing,
17
20
  stop and report it; never remove selectors or fall back to ambient configuration.