okengine 0.10.2 → 0.10.3

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 (57) hide show
  1. package/package.json +1 -1
  2. package/site/content/docs/ai/mcp.mdx +0 -1
  3. package/site/content/docs/elements/ai.mdx +0 -6
  4. package/site/content/docs/elements/channel.mdx +0 -6
  5. package/site/content/docs/elements/clock.mdx +0 -6
  6. package/site/content/docs/elements/flow.mdx +0 -7
  7. package/site/content/docs/elements/gate.mdx +0 -6
  8. package/site/content/docs/elements/signal.mdx +0 -6
  9. package/site/content/docs/elements/store.mdx +8 -15
  10. package/site/content/docs/elements/vault.mdx +0 -6
  11. package/site/content/docs/get-started/basic-usage.mdx +0 -6
  12. package/site/content/docs/get-started/why.mdx +1 -2
  13. package/site/content/docs/index.mdx +0 -1
  14. package/site/content/docs/meta.json +0 -1
  15. package/site/content/docs/reference/fx.mdx +3 -3
  16. package/src/cli/ai-setup/ai-setup.test.ts +3 -1
  17. package/src/cli/build.ts +7 -8
  18. package/src/cli/dev.test.ts +88 -1
  19. package/src/cli/dev.ts +15 -13
  20. package/src/cli/doctor.ts +98 -5
  21. package/src/cli/load-config.images.test.ts +31 -1
  22. package/src/cli/load-config.ts +2 -2
  23. package/src/cli/safe-defaults.test.ts +1 -1
  24. package/src/compiler/extract.ts +12 -0
  25. package/src/compiler/fixtures/skyport/oke.config.ts +4 -2
  26. package/src/compiler/generate-adopt.ts +27 -1
  27. package/src/config/driver-defaults.test.ts +122 -0
  28. package/src/config/driver-defaults.ts +186 -0
  29. package/src/config/index.ts +97 -7
  30. package/src/docker/images-config.test.ts +168 -0
  31. package/src/kernel/boot-bind/channel.ts +12 -4
  32. package/src/kernel/boot-bind/clock.ts +3 -3
  33. package/src/kernel/boot-bind/gate.ts +7 -4
  34. package/src/kernel/boot-bind/journal.ts +3 -3
  35. package/src/kernel/boot-bind/signal.ts +3 -1
  36. package/src/kernel/boot-bind/store.test.ts +19 -0
  37. package/src/kernel/boot-bind/store.ts +24 -9
  38. package/src/kernel/boot-bind/vault.ts +3 -3
  39. package/site/content/docs/console/access.mdx +0 -29
  40. package/site/content/docs/console/ai.mdx +0 -35
  41. package/site/content/docs/console/architecture.mdx +0 -35
  42. package/site/content/docs/console/channels.mdx +0 -37
  43. package/site/content/docs/console/clock.mdx +0 -51
  44. package/site/content/docs/console/flows.mdx +0 -31
  45. package/site/content/docs/console/gates.mdx +0 -73
  46. package/site/content/docs/console/index.mdx +0 -54
  47. package/site/content/docs/console/manifest-diff.mdx +0 -34
  48. package/site/content/docs/console/meta.json +0 -24
  49. package/site/content/docs/console/overview.mdx +0 -40
  50. package/site/content/docs/console/plugins.mdx +0 -41
  51. package/site/content/docs/console/privacy.mdx +0 -32
  52. package/site/content/docs/console/runs.mdx +0 -50
  53. package/site/content/docs/console/signals.mdx +0 -40
  54. package/site/content/docs/console/store.mdx +0 -32
  55. package/site/content/docs/console/tenancy.mdx +0 -32
  56. package/site/content/docs/console/traces.mdx +0 -38
  57. package/site/content/docs/console/vault.mdx +0 -41
@@ -1,73 +0,0 @@
1
- ---
2
- title: "Gates"
3
- description: "Permission inquiry, rate counters, and continuous audit of unguarded vs explicitly public flows."
4
- icon: "Shield"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- The Gates panel answers **who may do what** without dumping a giant roles×permissions matrix as
9
- the home screen. Inquire from a principal or from a flow; the simulator shows the chain in
10
- evaluation order.
11
-
12
- <Callout title="The one rule">
13
- Refuse the giant roles×permissions matrix as the entry point — inquire from principal or from
14
- flow.
15
- </Callout>
16
-
17
- ## What this panel shows
18
-
19
- <Cards>
20
- <Card title="Simulator" description="Gate chain in evaluation order — where a denial stopped." />
21
- <Card
22
- title="Unguarded vs public"
23
- description="Empty chain (missing posture) vs gate.public (intentional)."
24
- />
25
- <Card title="Deploy diff" description="Permission widening caught from Manifest Diff." />
26
- <Card
27
- title="Plane separation"
28
- description="Operator holding an application scope is a violation."
29
- />
30
- </Cards>
31
-
32
- ## Unguarded vs explicit public
33
-
34
- | Flag | Meaning |
35
- | --------------- | ---------------------------------------------------------------------------- |
36
- | Unguarded | User-plane flow with an **empty** gate chain — missing auth posture |
37
- | Explicit public | Chain includes the reserved `public` sentinel (`gate.public` on the trigger) |
38
-
39
- App boot fails on unguarded HTTP triggers (`GateBootError`) unless `env === "test"` and
40
- `gate: { unguardedHttp: "allow" }`. Prefer fixing the flow: attach a policy, or attach
41
- `gate.public` when the surface is intentionally open.
42
-
43
- App authors configure Gate under `oke({ gate: { policies, auth, unguardedHttp } })` — see
44
- [Gate](/docs/elements/gate). Builtin `/auth/*` Flows from `gate.auth` are audited the same way.
45
-
46
- ## Catalog
47
-
48
- Policies, rates, and `/auth/*` Bindings from the Manifest — inquire and audit, not a live
49
- rate editor. Rate `overridable` is a catalog flag; schedule edits live under
50
- [Clock](/docs/console/clock).
51
-
52
- <Cards>
53
- <Card title="Dev" description="full catalog + simulator" />
54
- <Card title="Prod" description="same inquire surface; no silent ungated HTTP" />
55
- </Cards>
56
-
57
- ## Learn more
58
-
59
- - [Gate](/docs/elements/gate) — policies, rate limits, `gate.auth`, posture
60
- - [Plugins](/docs/plugins) — plugged sign-in method plugins
61
- - [Access](/docs/console/access) — roles and API keys
62
-
63
- ## Next
64
-
65
- <Cards>
66
- <Card title="Gate" description="Declare policies and auth." href="/docs/elements/gate" />
67
- <Card title="Access" description="Roles and API keys." href="/docs/console/access" />
68
- <Card
69
- title="Overview"
70
- description="Console panels from the Manifest."
71
- href="/docs/console/overview"
72
- />
73
- </Cards>
@@ -1,54 +0,0 @@
1
- ---
2
- title: "Console"
3
- description: "Manifest-derived operator panels on :6533 — health, elements, traces, access, and more."
4
- icon: "LayoutDashboard"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- The Console is derived from your Manifest. Each panel answers one operator question.
9
-
10
- ## Pages
11
-
12
- <Cards>
13
- <Card
14
- title="Overview"
15
- description="Is the system healthy right now?"
16
- href="/docs/console/overview"
17
- />
18
- <Card
19
- title="Flows"
20
- description="What exists; call it; read its contract."
21
- href="/docs/console/flows"
22
- />
23
- <Card title="Signals" description="Queue depth, in-flight, DLQ." href="/docs/console/signals" />
24
- <Card title="Store" description="Browse sql/kv/files/index." href="/docs/console/store" />
25
- <Card title="Clock" description="Crons, sleeps, journal." href="/docs/console/clock" />
26
- <Card
27
- title="Gates"
28
- description="Permission matrix and rate counters."
29
- href="/docs/console/gates"
30
- />
31
- <Card title="Vault" description="Secret contracts and rotation." href="/docs/console/vault" />
32
- <Card
33
- title="Channels"
34
- description="Templates, receipts, opt-outs."
35
- href="/docs/console/channels"
36
- />
37
- <Card title="AI" description="Prompts, evals, cost, agents." href="/docs/console/ai" />
38
- <Card title="Architecture" description="How it all connects." href="/docs/console/architecture" />
39
- <Card title="Traces" description="One timeline across effects." href="/docs/console/traces" />
40
- <Card title="Runs" description="Wide events per execution." href="/docs/console/runs" />
41
- <Card
42
- title="Manifest Diff"
43
- description="Blast radius of a deploy."
44
- href="/docs/console/manifest-diff"
45
- />
46
- <Card title="Access" description="Identities, roles, API keys." href="/docs/console/access" />
47
- <Card title="Plugins" description="Installed plugins and panels." href="/docs/console/plugins" />
48
- <Card title="Privacy" description="Where PII lives (conditional)." href="/docs/console/privacy" />
49
- <Card
50
- title="Tenancy"
51
- description="Per-tenant usage (conditional)."
52
- href="/docs/console/tenancy"
53
- />
54
- </Cards>
@@ -1,34 +0,0 @@
1
- ---
2
- title: "Manifest Diff"
3
- description: "Blast radius of a deploy: new effects, widened permissions."
4
- icon: "Diff"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **blast radius of a deploy: new effects, widened permissions**
9
-
10
- <Callout title="Governing rule">
11
- Compares meaning rather than lines — behaviour change, sorted by blast radius.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card title="Contract breaking" description="Existing clients will fail." />
18
- <Card
19
- title="Permission widening"
20
- description="Attack surface grew — gate removed or scope widened."
21
- />
22
- <Card title="Effect widening" description="New write, external effect, or secret read." />
23
- <Card
24
- title="CI gate"
25
- description="Blocks undeclared breaks; intended breaks need `breaking: true`."
26
- />
27
- </Cards>
28
-
29
- ## Catalog
30
-
31
- <Cards>
32
- <Card title="Dev" description="✓" />
33
- <Card title="Prod" description="✓" />
34
- </Cards>
@@ -1,24 +0,0 @@
1
- {
2
- "title": "Console",
3
- "icon": "LayoutDashboard",
4
- "pages": [
5
- "index",
6
- "overview",
7
- "flows",
8
- "signals",
9
- "store",
10
- "clock",
11
- "gates",
12
- "vault",
13
- "channels",
14
- "ai",
15
- "architecture",
16
- "traces",
17
- "runs",
18
- "manifest-diff",
19
- "access",
20
- "plugins",
21
- "privacy",
22
- "tenancy"
23
- ]
24
- }
@@ -1,40 +0,0 @@
1
- ---
2
- title: "Overview"
3
- description: "Is the system healthy right now?"
4
- icon: "Activity"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **is the system healthy right now?**
9
-
10
- <Callout title="Governing rule">
11
- Built on declared objectives — burn rate and ranked findings, not a wall of charts nobody reads.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card
18
- title="Declared SLOs"
19
- description="Objectives enter the Manifest; lowering a target is a reviewable code change."
20
- />
21
- <Card
22
- title="Burn rate"
23
- description="Error rate over tolerable rate — pages and investigates with clear thresholds."
24
- />
25
- <Card
26
- title="Journeys"
27
- description="Causal paths, not service lists — impossible compositions rejected at compile."
28
- />
29
- <Card
30
- title="Ranked findings"
31
- description="Union of panel findings: user harm first, then irreversibility, then trend."
32
- />
33
- </Cards>
34
-
35
- ## Catalog
36
-
37
- <Cards>
38
- <Card title="Dev" description="✓" />
39
- <Card title="Prod" description="✓" />
40
- </Cards>
@@ -1,41 +0,0 @@
1
- ---
2
- title: "Plugins"
3
- description: "Installed plugins and their contributed panels."
4
- icon: "Puzzle"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **installed plugins and their contributed panels**
9
-
10
- <Callout title="Governing rule">
11
- Scope is the attachment point — `app.plug()` / `unit.plug()` / `flow.plug()`. The Console never
12
- installs anything.
13
- </Callout>
14
-
15
- ## What this panel shows
16
-
17
- <Cards>
18
- <Card
19
- title="Origin × state"
20
- description="Core / Local / Community; state derived from code, not a flag."
21
- />
22
- <Card
23
- title="Declares vs intercepts"
24
- description="Boot contributions vs per-request hooks with measured cost."
25
- />
26
- <Card
27
- title="Supply chain"
28
- description="No lifecycle scripts; capability widening hits Manifest Diff."
29
- />
30
- <Card
31
- title="Install path"
32
- description="Shows state and hands you the command — no browser install."
33
- />
34
- </Cards>
35
-
36
- ## Catalog
37
-
38
- <Cards>
39
- <Card title="Dev" description="✓" />
40
- <Card title="Prod" description="✓" />
41
- </Cards>
@@ -1,32 +0,0 @@
1
- ---
2
- title: "Privacy"
3
- description: "Where PII lives, who touches it, export/erase (conditional)."
4
- icon: "EyeOff"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **where PII lives, who touches it, export/erase**
9
-
10
- <Callout title="Governing rule">
11
- Conditional panel — appears when the privacy plugin is plugged. Catalog row is the durable
12
- reference.
13
- </Callout>
14
-
15
- ## What this panel shows
16
-
17
- <Cards>
18
- <Card title="PII map" description="Where personal data lives and who touches it." />
19
- <Card title="Export / erase" description="`oke privacy export|erase --subject` across stores." />
20
- </Cards>
21
-
22
- ## Catalog
23
-
24
- <Cards>
25
- <Card title="Dev" description="✓" />
26
- <Card title="Prod" description="✓" />
27
- </Cards>
28
-
29
- <Callout title="Conditional">
30
- This panel appears when the optional core plugin is plugged. There is no separate detailed
31
- subsection beyond the catalog row.
32
- </Callout>
@@ -1,50 +0,0 @@
1
- ---
2
- title: "Runs"
3
- description: "Wide events — one record per flow execution."
4
- icon: "Play"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **wide events — one record per flow execution, queried by dimension**
9
-
10
- <Callout title="Governing rule">
11
- One flow execution = one wide event = one span. Analysis by dimension, not a text search box.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card
18
- title="Wide events"
19
- description="Dimensions from effects — no manual instrumentation tax."
20
- />
21
- <Card
22
- title="Error patterns"
23
- description="Failed runs in the lookback window, grouped by error code."
24
- />
25
- <Card
26
- title="Outlier explanation"
27
- description="Compare all dimensions between slow and baseline populations."
28
- />
29
- <Card
30
- title="Storage tiers"
31
- description="Default Parquet + DuckDB; optional postgres / clickhouse."
32
- />
33
- <Card
34
- title="Lifecycle"
35
- description="Retain by default; redaction and crypto-shredding for compliance."
36
- />
37
- </Cards>
38
-
39
- Use **Since** (`5m` · `1h` · `24h` · all time) to bound the population. Error patterns count
40
- `error_code` occurrences in that window — the same store Traces and Overview read.
41
-
42
- Local replay: `oke replay --request-id <runId>` re-invokes from the stored input snapshot
43
- (dry-run when the ledger has `send` / `ask`).
44
-
45
- ## Catalog
46
-
47
- <Cards>
48
- <Card title="Dev" description="✓" />
49
- <Card title="Prod" description="✓" />
50
- </Cards>
@@ -1,40 +0,0 @@
1
- ---
2
- title: "Signals"
3
- description: "Queue depth, in-flight, DLQ, live monitors, orphaned config."
4
- icon: "Radio"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **queue depth, in-flight, DLQ, live monitors, orphaned config**
9
-
10
- <Callout title="Governing rule">
11
- One list grouped by delivery physics — not three tabs that re-split the element.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card title="once" description="Pending, in-flight (leased), DLQ, retry policy." />
18
- <Card title="broadcast" description="Per-subscriber lag and targeted replay." />
19
- <Card
20
- title="live"
21
- description="Connection count, throughput, newest-50 payload monitor (full history still retained)."
22
- />
23
- <Card
24
- title="DLQ repair"
25
- description="Schema form, typed errors, causal chain, dry-run bulk replay."
26
- />
27
- <Card
28
- title="Orphaned"
29
- description="Config still listed after the declaration left code — messages kept; dry-run refused."
30
- />
31
- </Cards>
32
-
33
- Dry-run is refused for orphaned signals and for signals with no Manifest consumer — unknown handler shapes are not invoked unsafely. Restore the `signal(…)` declaration (and a consumer) before replaying DLQ rows. Lease / at-least-once physics live on [Signal](/docs/elements/signal).
34
-
35
- ## Catalog
36
-
37
- <Cards>
38
- <Card title="Dev" description="full" />
39
- <Card title="Prod" description="replay/purge per gates" />
40
- </Cards>
@@ -1,32 +0,0 @@
1
- ---
2
- title: "Store"
3
- description: "Browse sql/kv/files/index; cache keys; replica lag."
4
- icon: "Database"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **browse sql/kv/files/index; cache keys; replica lag**
9
-
10
- <Callout title="Governing rule">
11
- The most dangerous panel in production — gates, tenant isolation, PII masking, and audit on the
12
- data path.
13
- </Callout>
14
-
15
- ## What this panel shows
16
-
17
- <Cards>
18
- <Card title="Four facets" description="sql · kv · files · index with adaptive detail." />
19
- <Card title="PII masking" description="Follows schema classification, including raw SQL." />
20
- <Card title="Cache keys" description="Which read produced a key; which write invalidates it." />
21
- <Card
22
- title="Direct edit warning"
23
- description="Names what will not happen — not a silent row patch."
24
- />
25
- </Cards>
26
-
27
- ## Catalog
28
-
29
- <Cards>
30
- <Card title="Dev" description="full + Studio link" />
31
- <Card title="Prod" description="masked, gated, audited" />
32
- </Cards>
@@ -1,32 +0,0 @@
1
- ---
2
- title: "Tenancy"
3
- description: "Per-tenant usage, limits, isolation checks (conditional)."
4
- icon: "Building2"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **per-tenant usage, limits, isolation checks**
9
-
10
- <Callout title="Governing rule">
11
- Conditional panel — appears when the tenancy plugin is plugged. Catalog row is the durable
12
- reference.
13
- </Callout>
14
-
15
- ## What this panel shows
16
-
17
- <Cards>
18
- <Card title="Usage &amp; limits" description="Per-tenant usage and configured limits." />
19
- <Card title="Isolation" description="Checks that tenant boundaries hold." />
20
- </Cards>
21
-
22
- ## Catalog
23
-
24
- <Cards>
25
- <Card title="Dev" description="✓" />
26
- <Card title="Prod" description="✓" />
27
- </Cards>
28
-
29
- <Callout title="Conditional">
30
- This panel appears when the optional core plugin is plugged. There is no separate detailed
31
- subsection beyond the catalog row.
32
- </Callout>
@@ -1,38 +0,0 @@
1
- ---
2
- title: "Traces"
3
- description: "One timeline across http → store → signal → durable steps."
4
- icon: "Route"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **one timeline across http → store → signal → durable steps**
9
-
10
- <Callout title="Governing rule">
11
- Folded time across async boundaries — a seven-day sleep is not 99.99% empty waterfall.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card title="Causal chain" description="Join parent/child across emit boundaries." />
18
- <Card title="Effect tiers" description="Spans coloured by the same vocabulary as Flows." />
19
- <Card
20
- title="Filter by effect"
21
- description="Everything that wrote a table, sent mail, or cost more than X."
22
- />
23
- <Card
24
- title="Why slow / why fail"
25
- description="Critical path highlight; open on the failing span."
26
- />
27
- </Cards>
28
-
29
- Chains use `WideEvent.parentId`: producers stamp it on `fx.emit` / `fx.call`;
30
- consumers record it on their run. Per-effect timing comes from the ledger
31
- (`timestamp` + `duration`) — not a second instrumentation API.
32
-
33
- ## Catalog
34
-
35
- <Cards>
36
- <Card title="Dev" description="✓" />
37
- <Card title="Prod" description="✓" />
38
- </Cards>
@@ -1,41 +0,0 @@
1
- ---
2
- title: "Vault"
3
- description: "Secret contracts, who can read each, rotation due."
4
- icon: "KeyRound"
5
- source: "docs/spec/console.md"
6
- ---
7
-
8
- Answers: **secret contracts, who can read each, rotation due**
9
-
10
- <Callout title="Governing rule">
11
- Secrets are write-only — the panel can set and rotate; it can never reveal.
12
- </Callout>
13
-
14
- ## What this panel shows
15
-
16
- <Cards>
17
- <Card
18
- title="Contracts"
19
- description="Optional description as the human title; technical key stays visible."
20
- />
21
- <Card
22
- title="Fingerprints"
23
- description="Salted hash per environment — rotation and drift without exposure."
24
- />
25
- <Card
26
- title="Resolution chain"
27
- description="Which source won: env, files, vault driver, or fallback."
28
- />
29
- <Card title="Who can read" description="Derived from effects that declare `fx.vault`." />
30
- <Card
31
- title="Rotation blast radius"
32
- description="In-flight durable runs that wake with a new key."
33
- />
34
- </Cards>
35
-
36
- ## Catalog
37
-
38
- <Cards>
39
- <Card title="Dev" description="full" />
40
- <Card title="Prod" description="set/rotate only, never reveal" />
41
- </Cards>