@awebai/oats 0.22.19 → 0.23.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +54 -20
- package/bin/oats.mjs +24 -10
- package/capabilities/oats-okf/agents/memory-harvest/AGENTS.md +18 -24
- package/capabilities/oats-okf/agents/memory-harvest/soul.yaml +2 -2
- package/capabilities/oats-okf/bin/oats-okf.mjs +105 -517
- package/capabilities/oats-okf/injects/okf.md +32 -67
- package/capabilities/oats-okf/lib/config.mjs +112 -0
- package/capabilities/oats-okf/lib/inspection.mjs +96 -0
- package/capabilities/oats-okf/lib/io.mjs +103 -0
- package/capabilities/oats-okf/lib/migration.mjs +116 -0
- package/capabilities/oats-okf/lib/sources.mjs +238 -0
- package/capabilities/oats-okf/lib/stores.mjs +331 -0
- package/capabilities/oats-okf/lib/worker.mjs +352 -0
- package/capabilities/oats-okf/oats.json +23 -7
- package/capabilities/oats-okf/schemas/okf-base.schema.json +46 -0
- package/capabilities/oats-okf/schemas/okf-bindings.schema.json +112 -0
- package/capabilities/oats-okf/schemas/okf-soul.schema.json +37 -0
- package/capabilities/oats-okf/skills/memory-harvest/SKILL.md +263 -140
- package/capabilities/oats-okf/skills/okf/SKILL.md +13 -4
- package/docs/capabilities.md +14 -3
- package/docs/configuration.md +11 -1
- package/docs/design/2026-09-08-expert-assisted-deployment-proposal.md +558 -0
- package/docs/design/2026-09-13-knowledge-and-memory-direction.md +744 -0
- package/docs/design/2026-09-13-knowledge-implementation.md +127 -0
- package/docs/design/2026-09-13-knowledge-location-contract.md +340 -0
- package/docs/design/okf-mirror-provenance.md +105 -0
- package/docs/design/package-runtime-api.md +177 -3
- package/docs/desktop-cli-api.md +60 -11
- package/docs/execution-targets.md +16 -0
- package/docs/first-team-demo.md +6 -1
- package/docs/first-team.md +151 -115
- package/docs/integrations.md +42 -42
- package/docs/knowledge-capability-authoring.md +101 -0
- package/docs/knowledge-migration.md +138 -0
- package/docs/knowledge-reference/acceptance.md +108 -0
- package/docs/knowledge-reference/adoption.md +61 -0
- package/docs/knowledge-reference/harvester.md +107 -0
- package/docs/knowledge-reference/model.md +84 -0
- package/docs/knowledge-reference/package-craft.md +126 -0
- package/docs/knowledge-reference/provider-mapping.md +77 -0
- package/docs/knowledge-reference/reader-capture.md +87 -0
- package/docs/knowledge-theory.md +20 -6
- package/docs/knowledge.md +316 -129
- package/docs/layers.md +65 -69
- package/docs/migration-from-oas.md +7 -1
- package/docs/oats-config.schema.json +5 -2
- package/docs/packages.md +26 -2
- package/docs/release-notes/v0.23.0.md +93 -0
- package/docs/release-notes/v0.23.1.md +97 -0
- package/docs/schedules.md +42 -3
- package/docs/souls-and-instances.md +72 -49
- package/injects/work-directory.md +18 -0
- package/lib/core.mjs +279 -56
- package/lib/schedule.mjs +12 -2
- package/package-catalog.json +6 -1
- package/package.json +2 -2
- package/packages/record/README.md +19 -0
- package/packages/record/bin/capture.mjs +96 -48
- package/packages/record/bin/recall.mjs +17 -11
- package/packages/record/bin/record-native-start.mjs +11 -0
- package/packages/record/lib/capture-cc.mjs +82 -27
- package/packages/record/lib/capture-lock.mjs +15 -2
- package/packages/record/lib/formats.mjs +108 -21
- package/packages/record/lib/native-history.mjs +87 -0
- package/packages/record/lib/session-roots.mjs +90 -0
- package/packages/record/lib/session-snapshot.mjs +61 -0
- package/packages/record/lib/sessions-for-home.mjs +88 -56
- package/skills/oats/SKILL.md +3 -1
- package/capabilities/oats-okf/lib/harvest-branch.mjs +0 -43
|
@@ -81,7 +81,7 @@ this contract remains authoritative).
|
|
|
81
81
|
2. **Spawn** — `oats spawn <agent> ... --json` with the EXISTING flags:
|
|
82
82
|
`--purpose <slug>` (deterministic derived naming
|
|
83
83
|
`<agent>-<purpose>`; no raw instance-name authority), `--parent`,
|
|
84
|
-
`--repo`, `--work attached|worktree|checkout|workspace`, `--work-dir`,
|
|
84
|
+
`--repo`, `--work attached|worktree|checkout|workspace|directory`, `--work-dir`,
|
|
85
85
|
`--branch`, `--model`, `--task`/`--task-file` (owner-only tempfiles:
|
|
86
86
|
mode 0600, removed on every outcome). Existing validation and error codes
|
|
87
87
|
(`E_BAD_ARGS`, `E_PARENT_NOT_FOUND`, `E_SPAWN_FAILED`, ...) are part of
|
|
@@ -96,8 +96,8 @@ this contract remains authoritative).
|
|
|
96
96
|
read their settings (e.g. oats.okf's `harvest-model`) from `OATS_SETTINGS`;
|
|
97
97
|
there is NO public resolved-config read command.
|
|
98
98
|
4. **Consumer rules**: a package command executes the CLI at the exact
|
|
99
|
-
absolute path the dispatcher provides in the
|
|
100
|
-
variable (
|
|
99
|
+
absolute path the dispatcher or lifecycle runner provides in the
|
|
100
|
+
**`OATS_CLI_BIN`** environment variable (beside `OATS_SETTINGS`), via
|
|
101
101
|
`execFile` on that path — **never** by resolving `oats` from `PATH` and
|
|
102
102
|
never through a shell: PATH is not a trusted runtime boundary, and package
|
|
103
103
|
commands run in worktrees where it can be shadowed. The consumer parses
|
|
@@ -109,6 +109,180 @@ Error codes are part of the contract: `E_USAGE`, `E_BAD_ARGS`,
|
|
|
109
109
|
`E_RELATIVE_NOT_FOUND`, `E_RELATIVE_AMBIGUOUS`, `E_CAPABILITY_BLOCKED`,
|
|
110
110
|
`E_CAPABILITY_INACTIVE`.
|
|
111
111
|
|
|
112
|
+
### Directory execution for capability workers
|
|
113
|
+
|
|
114
|
+
A worker may explicitly select `work: directory` in its packaged `soul.yaml`,
|
|
115
|
+
pass `--work directory` to spawn, or use `spawnInstance(..., {work: "directory"})`.
|
|
116
|
+
This is a generic execution mode, independent of any knowledge provider.
|
|
117
|
+
Consumers using it must declare the directory-mode release as their
|
|
118
|
+
`compatibility.oats` floor, not the older boundary-v1 floor alone.
|
|
119
|
+
|
|
120
|
+
- `repo` / `--repo` is an **existing config context directory** in this mode,
|
|
121
|
+
not a Git requirement or an edit target. Relative paths resolve from the
|
|
122
|
+
agents root's parent; absent a selector it defaults to that deployment scope.
|
|
123
|
+
The CLI does not substitute its ambient Git checkout. A configured workspace
|
|
124
|
+
can discover and spawn declared package agents before it has an `agents/` or
|
|
125
|
+
`local-agents/` directory. Laptop config alone does not declare a deployment.
|
|
126
|
+
- `<home>/work` is a new, owned directory, not a symlink and not a fake Git
|
|
127
|
+
repository. The kernel creates no branch, copies no source tree, and does not
|
|
128
|
+
require Git in a non-Git deployment. Git-owned deployment placement still
|
|
129
|
+
requires readable Git metadata to establish the canonical home location.
|
|
130
|
+
- `--work-dir` / `workDir` and `--branch` / `branch` are contradictory and
|
|
131
|
+
rejected with `E_BAD_ARGS`, even if empty or inherited from a caller bug.
|
|
132
|
+
Directory execution never takes ownership of a caller-selected filesystem
|
|
133
|
+
path. Existing modes retain their Git/context requirements and semantics;
|
|
134
|
+
failed Git operations never implicitly fall back to directory execution.
|
|
135
|
+
- Canonical `AGENTS.md` / `CLAUDE.md`, skill composition, provider trust,
|
|
136
|
+
lifecycle hooks, frozen launch recipes, runtime preflight and no-launch
|
|
137
|
+
metadata are unchanged. Hooks receive `OATS_WORK=directory`, an empty
|
|
138
|
+
`OATS_BRANCH`, and the context in `OATS_REPO` / `OATS_CONTEXT` at spawn.
|
|
139
|
+
Worktree-only setup scripts are not run in this mode.
|
|
140
|
+
- Retirement authenticates directory ownership against the independent spawn
|
|
141
|
+
baseline. Nonempty execution work is preserved in verified recovery custody
|
|
142
|
+
(`workRecovery.path/work`, with home bytes under `home/`) before removal;
|
|
143
|
+
post-hook changes produce another verified snapshot. No work is designated
|
|
144
|
+
disposable in this initial mode, including hook-created work. Symlinks inside
|
|
145
|
+
work are copied as links, never followed; an exchanged work-root symlink,
|
|
146
|
+
unsupported filesystem entry, or unverifiable copy fails closed. Recovery is
|
|
147
|
+
not provider delivery or publication, and retains the existing single-host,
|
|
148
|
+
quiesced-runtime safety model rather than a hostile-filesystem atomicity claim.
|
|
149
|
+
|
|
150
|
+
### Lifecycle and scheduled-command context
|
|
151
|
+
|
|
152
|
+
Lifecycle hooks receive `OATS_CLI_BIN` as the real, absolute `bin/oats.mjs`
|
|
153
|
+
path belonging to the **running kernel**. This is authored by
|
|
154
|
+
`runLifecycleHooks` itself, including direct core callers; neither ambient
|
|
155
|
+
`OATS_CLI_BIN` nor a caller's `extraEnv.OATS_CLI_BIN` can override it. Spawn
|
|
156
|
+
hooks also receive the known agents root as `OATS_ROOT`, rather than an empty
|
|
157
|
+
value or the ambient caller's root.
|
|
158
|
+
|
|
159
|
+
Scheduled command execution starts without the invoking instance's identity:
|
|
160
|
+
`OATS_INSTANCE`, `OATS_INSTANCE_HOME`, legacy `OATS_HOME`, the `PI_AGENT_*`
|
|
161
|
+
aliases and `PI_AGENTS_ROOT`, plus kernel-authored soul, root, context, work,
|
|
162
|
+
team, capability, operation, settings and lifecycle metadata are removed.
|
|
163
|
+
The command's explicit cwd and selectors (for example `--soul`) determine
|
|
164
|
+
its dispatch; a scheduler invoked from another home must not select that
|
|
165
|
+
home's frozen capabilities/settings. Host configuration (`HOME`,
|
|
166
|
+
`OATS_HOME_DIR`, package catalog configuration) and ordinary credentials are
|
|
167
|
+
preserved. No job schema or knowledge-provider policy is implied by this
|
|
168
|
+
isolation.
|
|
169
|
+
|
|
170
|
+
### Native record capture result
|
|
171
|
+
|
|
172
|
+
`oats capture --home <dir>` (also `turn-record capture --home <dir>` and the
|
|
173
|
+
standalone `capture.mjs`) answers **native JSON**, not a Desktop schema-v1
|
|
174
|
+
`{ok,result}` envelope. Do not add `--json`: `--home` already selects JSON.
|
|
175
|
+
Diagnostics go to stderr, including lock contention without `--quiet`.
|
|
176
|
+
Existing home/owner/appended/session boundary fields remain; the outcome adds:
|
|
177
|
+
|
|
178
|
+
- `status`: `complete`, `skipped`, `held`, `incomplete`, or `failed` (failure
|
|
179
|
+
takes priority, then skip/held/incomplete).
|
|
180
|
+
- `complete`: true only for a performed pass with no holds, incomplete source
|
|
181
|
+
records, unattributed candidates or reported errors.
|
|
182
|
+
An unchanged performed pass may be complete with `appended: 0`.
|
|
183
|
+
- `skipped`: true when another pass owns the capture lock. `lock` then carries
|
|
184
|
+
holder/liveness/recovery details; no capture or indexing was performed.
|
|
185
|
+
- `held`: count of sessions the underlying pass held pending a timestamp.
|
|
186
|
+
- `incomplete`: count of source files with pending torn, oversized, invalid
|
|
187
|
+
UTF-8 or otherwise incomplete records; later complete input can recover.
|
|
188
|
+
- `issues`: optional metadata-only diagnostics identifying source paths and
|
|
189
|
+
reasons; no record bodies are embedded. `unattributed` candidates also make
|
|
190
|
+
the pass incomplete rather than silently certifying missing source evidence.
|
|
191
|
+
- `failed`: zero on success, nonzero for a capture/read/index/lock-release
|
|
192
|
+
failure; `error` describes the failure. `appended: null` on a thrown failure
|
|
193
|
+
means the number appended before the failure is unknown, not zero.
|
|
194
|
+
- `ignored`: count excluded by configured privacy rules, distinct from a
|
|
195
|
+
whole-pass skip. Home capture pins exactly attributed source files; sharing
|
|
196
|
+
a Codex day directory does not authorize capturing unrelated records.
|
|
197
|
+
|
|
198
|
+
Lock skips, held sessions and incomplete input retain exit status 0 (background reconciliation
|
|
199
|
+
must stay nonfatal on contention); errors and failed lock release exit 1.
|
|
200
|
+
Previously captured visible boundaries may still be returned on a skipped or
|
|
201
|
+
held pass. They are **not** evidence that final capture ran. Consumers requiring
|
|
202
|
+
a final pass must check `complete === true`, not exit status or the presence of
|
|
203
|
+
boundaries alone; older results lacking that field cannot certify a pass.
|
|
204
|
+
|
|
205
|
+
**Snapshot boundary:** completion describes a performed pass over the exact
|
|
206
|
+
attributed source files, not a promise about future appends. Discovery carries
|
|
207
|
+
an open-descriptor-derived identity and content witness through capture-lock
|
|
208
|
+
acquisition. Capture stages bytes from one descriptor and validates that witness
|
|
209
|
+
and source stability **before appending**: replacement, truncation and prefix
|
|
210
|
+
rewrites fail without appending the replacement's bytes. Same-inode append
|
|
211
|
+
growth is allowed only when the witnessed prefix is unchanged. Discovery/read
|
|
212
|
+
failures and files disappearing during the pass fail closed; pending trailing
|
|
213
|
+
records and unattributed candidates cannot certify completion. A retirement
|
|
214
|
+
consumer must first quiesce its writers and then preserve the captured evidence
|
|
215
|
+
under its own durable-input protocol. `complete:true` alone does not mean a
|
|
216
|
+
harvest was delivered or that a consumer stored those inputs. Configured privacy
|
|
217
|
+
exclusions remain exclusions, not an invitation to copy excluded source bytes.
|
|
218
|
+
|
|
219
|
+
**Native roots:** managed `--home` capture uses independent execution history,
|
|
220
|
+
not the observer's environment or the latest relaunch recipe. New scaffolds
|
|
221
|
+
initialize `<instances>/.oats-native-record/<sha256(canonical-home)>/history.json`.
|
|
222
|
+
Each managed spawn/start/restart writes a separate pending receipt before
|
|
223
|
+
backend dispatch. Inside the backend shell, under the exact environment prefix
|
|
224
|
+
and cwd that will exec the harness, the native recorder atomically replaces
|
|
225
|
+
that receipt with the effective absolute **record locations** and runtime. Only
|
|
226
|
+
these allowlisted locations, home, start id/time and custody state are saved;
|
|
227
|
+
no environment map, credential reference value, task or argv is persisted.
|
|
228
|
+
The saved `instance.json` command/recipe remains a relaunch **template**, not
|
|
229
|
+
execution evidence: use `oats session start`, not a manual shell replay of it.
|
|
230
|
+
|
|
231
|
+
Location rules at execution are `CLAUDE_CONFIG_DIR/projects` (default exactly
|
|
232
|
+
`$HOME/.claude/projects`), `PI_CODING_AGENT_DIR/sessions` (default
|
|
233
|
+
`$HOME/.pi/agent/sessions`), and `CODEX_HOME/sessions` (default
|
|
234
|
+
`$HOME/.codex/sessions`). Pi's `--session-dir` wins over
|
|
235
|
+
`PI_CODING_AGENT_SESSION_DIR`, which wins over its agent-dir location; Pi tilde
|
|
236
|
+
paths expand against the effective HOME. Relative paths resolve from the source
|
|
237
|
+
home. Existing symlinks resolve at recording time, including existing ancestors
|
|
238
|
+
of not-yet-created roots. Inherited overrides and resolved `fromEnv` location
|
|
239
|
+
inputs are thereby retained **after backend shell startup**, independently of
|
|
240
|
+
later observer/config/reference changes. The recorder runs before the native
|
|
241
|
+
exec; unsupported explicit Pi `--session` or a receipt write failure refuses
|
|
242
|
+
that exec and leaves pending custody, rather than claiming a default root.
|
|
243
|
+
Wrappers must preserve this native storage contract: arbitrary scripts which
|
|
244
|
+
change storage internally cannot be inferred from their executable name.
|
|
245
|
+
|
|
246
|
+
History is never replaced by a newer runtime selection, truncated with the
|
|
247
|
+
bounded restart log, or deleted with the source home. Capture unions all
|
|
248
|
+
historically recorded locations for each runtime and still attributes every
|
|
249
|
+
file by its own cwd. Missing/unreadable historical roots, unreadable/invalid
|
|
250
|
+
receipts, and pending/unfinished launches fail closed. A newly scaffolded home
|
|
251
|
+
with no managed launches has an authoritative empty managed-launch inventory.
|
|
252
|
+
A legacy home without that scaffold authority cannot acquire proof of its
|
|
253
|
+
**earlier** roots merely by restarting: later starts retain new locations but
|
|
254
|
+
its history remains incomplete. Do not remove pending/history receipts just
|
|
255
|
+
to get a green capture; recovery requires establishing the source inventory.
|
|
256
|
+
|
|
257
|
+
Standalone fixtures and explicit legacy inventories can opt into
|
|
258
|
+
`capture --home <dir> --current-roots` (`sourceRoots: "current-env"` in JSON),
|
|
259
|
+
or use `sessionsForHome(home, {roots: {cc: [...], pi: [...], codex: [...]}})`.
|
|
260
|
+
Explicit API roots exclude unspecified formats, and every supplied root must
|
|
261
|
+
exist. The CLI fallback uses current environment plus recorded hook/config
|
|
262
|
+
location overrides; `fromEnv` resolves from that **current** base environment.
|
|
263
|
+
Its `complete:true` certifies only that chosen observer-time inventory, **not**
|
|
264
|
+
all historical roots; do not enable it implicitly for final-capture consumers.
|
|
265
|
+
Normal managed reports say `sourceRoots: "launch-history"`. Background capture
|
|
266
|
+
without `--home` retains observer-time discovery (including `.claude*` profiles)
|
|
267
|
+
and optional absent native defaults. Neither fallback introduces knowledge
|
|
268
|
+
policy into the kernel.
|
|
269
|
+
|
|
270
|
+
**Claude children:** discovery also enumerates the native
|
|
271
|
+
`<project>/<sessionId>/subagents/*.jsonl` layout, including children whose parent
|
|
272
|
+
transcript is absent. Each child requires its own cwd attribution; neither its
|
|
273
|
+
parent's cwd nor its directory supplies missing attribution. Child streams use
|
|
274
|
+
`cc.<sessionId>.<child-file-stem>` (threads
|
|
275
|
+
`cc:session:<sessionId>.<child-file-stem>`) so identical child filenames under
|
|
276
|
+
different sessions cannot collide. Complete native lines are preserved verbatim;
|
|
277
|
+
torn, unstamped or unattributed child evidence blocks certification, and child
|
|
278
|
+
read/discovery failures fail the pass. Ignore rules run before child opens and
|
|
279
|
+
can match its path, filename, qualified id, native child id or parent session id.
|
|
280
|
+
|
|
281
|
+
**Piped recall:** native `oats recall` JSON responses drain stdout before process
|
|
282
|
+
termination, including large thread windows and individual `--show` records.
|
|
283
|
+
Consumers must still bound their own reads/buffers (use `--ids-only` for sizing);
|
|
284
|
+
a successful producer does not imply an unbounded consumer buffer.
|
|
285
|
+
|
|
112
286
|
### Consumer fixture
|
|
113
287
|
|
|
114
288
|
The engine ships a consumer fixture driving the full oats.okf pattern
|
package/docs/desktop-cli-api.md
CHANGED
|
@@ -18,7 +18,8 @@ prints exactly one JSON object on stdout:
|
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
`version` is the installed package's exact semver (e.g. `0.20.0`).
|
|
21
|
-
Desktop 0.
|
|
21
|
+
Desktop 0.23 accepts `desktopApi === 1` and semver `>=0.22.0 <0.24.0`
|
|
22
|
+
(the earlier Desktop 0.22 band was `>=0.22.0 <0.23.0`).
|
|
22
23
|
|
|
23
24
|
Optional features are negotiated from the probe's `features` array. Starting
|
|
24
25
|
an existing home requires `session-start`; named launch configurations and
|
|
@@ -113,7 +114,7 @@ See [launch configuration syntax](configuration.md) and
|
|
|
113
114
|
| `instance` | string | new instance name |
|
|
114
115
|
| `agent` | string | soul/agent name |
|
|
115
116
|
| `home` | string | absolute instance home path |
|
|
116
|
-
| `work` | string | work mode (worktree/checkout/attached/workspace) |
|
|
117
|
+
| `work` | string | work mode (worktree/checkout/attached/workspace/directory) |
|
|
117
118
|
| `branch` | string \| null | work branch when applicable |
|
|
118
119
|
| `launched` | boolean | whether a tmux window was started |
|
|
119
120
|
| `warnings` | string[] | non-fatal warnings (always an array) |
|
|
@@ -138,18 +139,66 @@ subcommand), `E_CAPABILITY_INACTIVE`, `E_CAPABILITY_BLOCKED` (untrusted),
|
|
|
138
139
|
`E_CAPABILITY_BROKEN`, `E_DUPLICATE_NAMESPACE`, `E_CONFIG_BROKEN` — all still
|
|
139
140
|
exactly one stdout envelope with a nonzero exit.
|
|
140
141
|
|
|
141
|
-
###
|
|
142
|
+
### Knowledge operations and OKF v2
|
|
142
143
|
|
|
143
|
-
|
|
144
|
+
Discover provider-declared operations rather than assuming a particular memory
|
|
145
|
+
format. The knowledge capability's version owns its result shape; CLI API v1
|
|
146
|
+
does not freeze the old OKF v1 `harvest: spawned|skipped` body for every provider.
|
|
147
|
+
See [knowledge](knowledge.md) for the prepared OKF 2.0.0 version scope.
|
|
148
|
+
|
|
149
|
+
```bash
|
|
150
|
+
oats operation run knowledge:inspect --home /absolute/source-home --json
|
|
151
|
+
oats operation run knowledge:harvest --home /absolute/source-home --json
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
The operation runner preserves the provider view/action through the ordinary
|
|
155
|
+
operations contract. Direct `oats okf inspect` returns the standard JSON-v1
|
|
156
|
+
success/error envelope. Its result includes:
|
|
157
|
+
|
|
158
|
+
- `summary`, durable `source`, frozen `owns`, `reads`, `bases`;
|
|
159
|
+
- `acceptedView` (the registered snapshot, not a fresh read), `status` with
|
|
160
|
+
capture/processing/delivery/acceptance receipts, and `scheduler` diagnostics;
|
|
161
|
+
- `liveMemory: {available, reason, observedAt}` and labeled `documents`.
|
|
162
|
+
|
|
163
|
+
Live Markdown documents are `Working state (STATE.md)`, `Log (log.md)` and
|
|
164
|
+
sorted `Pending note: <relative-name>`, including nested notes. Missing files
|
|
165
|
+
are omitted; durable receipts follow as a text document. Only a live source
|
|
166
|
+
whose pointer/metadata still matches may supply live memory. Retired, missing,
|
|
167
|
+
reused or unverified homes return durable documents and explicit unavailability.
|
|
168
|
+
Unsafe live documents fail instead of returning a partial success. Inspection is
|
|
169
|
+
read-only and does not capture, refresh, schedule or launch a model.
|
|
170
|
+
|
|
171
|
+
The explicit preview limit is **256 KiB per document**, with `truncated: true`
|
|
172
|
+
and original `bytes` for larger files. Smaller files are byte-exact. The complete
|
|
173
|
+
JSON envelope drains stdout; consumers must not clip it at a small output-buffer
|
|
174
|
+
limit. Provider `read` returns full Markdown, not this inspection preview.
|
|
175
|
+
|
|
176
|
+
After the home disappears, operate from durable deployment context:
|
|
177
|
+
|
|
178
|
+
```bash
|
|
179
|
+
oats okf inspect --source /absolute/state/sources/UUID/source.json --soul domain-expert --json
|
|
180
|
+
oats okf refresh --source /absolute/state/sources/UUID/source.json --soul domain-expert --json
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
Every descriptor-selected read/refresh creates its new view under that source's
|
|
184
|
+
state directory, not the invoking repository or a replacement home.
|
|
185
|
+
|
|
186
|
+
Direct `oats okf harvest --json` captures notes and record and requests an
|
|
187
|
+
independent directory worker. Representative result shapes (not exhaustive):
|
|
188
|
+
|
|
189
|
+
```json
|
|
190
|
+
{"status":"running","run":"<run-id>","instance":"<worker-instance>","home":"/absolute/worker-home"}
|
|
191
|
+
```
|
|
144
192
|
|
|
145
193
|
```json
|
|
146
|
-
{"
|
|
147
|
-
{"harvest":"skipped","reason":"no pending notes"}
|
|
194
|
+
{"status":"empty","processed":true}
|
|
148
195
|
```
|
|
149
196
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
197
|
+
An explicit `--no-launch` request can return `status: "ready"` without starting
|
|
198
|
+
a model; existing runs report their current status without starting duplicates.
|
|
199
|
+
Nonzero errors use the ordinary JSON-v1 error envelope. `running`/`ready` are not
|
|
200
|
+
successful knowledge delivery. Inspect and reconcile provider receipts; never
|
|
201
|
+
infer acceptance from a launch or from a worker disappearing.
|
|
154
202
|
|
|
155
|
-
|
|
203
|
+
Kernel envelope/dispatch tests live in `test/cli-json-contract.test.mjs`;
|
|
204
|
+
provider-specific behavior is qualified against the exported OKF runtime.
|
|
@@ -148,6 +148,22 @@ and never silently applies a new model to an
|
|
|
148
148
|
already-running harness. A never-launched legacy Herdr home without a saved
|
|
149
149
|
server endpoint requires that endpoint to be configured before it can start;
|
|
150
150
|
it does not fall back to tmux.
|
|
151
|
+
Directory-mode starts and restarts also authenticate the home and owned work
|
|
152
|
+
root against the independent spawn receipt (mode, canonical home, device/inode
|
|
153
|
+
identities). Checks run before resolving mutable home contents, after **each**
|
|
154
|
+
launch hook/preparation and immediately before backend observations, stops,
|
|
155
|
+
allocations and launch-state writes. A missing/file/symlink/exchanged root or
|
|
156
|
+
mode disagreement fails with `E_WORK_INSPECTION_FAILED`; substituted targets
|
|
157
|
+
are neither followed for launch nor removed for lock cleanup. Restore the
|
|
158
|
+
original owned roots before retrying; pending receipts remain with them.
|
|
159
|
+
These pathname checks are not OS-level exclusion against a concurrent hostile
|
|
160
|
+
filesystem mutation between validation and use.
|
|
161
|
+
|
|
162
|
+
Managed execution also records independent native transcript-location history;
|
|
163
|
+
the recipe remains a template, not provenance. See
|
|
164
|
+
[Native roots](design/package-runtime-api.md)
|
|
165
|
+
for the exact source and standalone-fallback semantics.
|
|
166
|
+
|
|
151
167
|
The start opens a new harness conversation on the instance's `TASK.md`; the
|
|
152
168
|
instance resumes its work from its own `STATE.md`, as the knowledge protocol
|
|
153
169
|
prescribes.
|
package/docs/first-team-demo.md
CHANGED
|
@@ -4,6 +4,10 @@ On 2026-09-05 we installed the published OATS artifacts and used Pi and
|
|
|
4
4
|
Claude Code workers to fix issues found during a fresh review. The first
|
|
5
5
|
team's work was release preparation in this repository.
|
|
6
6
|
|
|
7
|
+
> **Historical v1 qualification.** The results below remain evidence for the
|
|
8
|
+
> named versions, not the prepared v2 runtime. Current setup, external ownership
|
|
9
|
+
> and independent delivery are in [the first-team guide](first-team.md).
|
|
10
|
+
|
|
7
11
|
## The setup
|
|
8
12
|
|
|
9
13
|
| Component | Qualified value |
|
|
@@ -82,6 +86,7 @@ The run found first-use problems that unit tests alone had not resolved:
|
|
|
82
86
|
- A combined workspace roster did not make the workspace a spawn scope for
|
|
83
87
|
every child repository. Commands select the owning repository explicitly.
|
|
84
88
|
|
|
85
|
-
The [first-team guide](first-team.md)
|
|
89
|
+
The [first-team guide](first-team.md) now describes the prepared v2 setup;
|
|
90
|
+
these historical v1 outcomes are not v2 acceptance evidence. The
|
|
86
91
|
package owners are responsible for improving their defaults; the kernel
|
|
87
92
|
continues to resolve capabilities through the same replaceable contracts.
|