@synapsor/runner 1.5.3 → 1.6.0

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 (69) hide show
  1. package/CHANGELOG.md +82 -2
  2. package/README.md +131 -130
  3. package/dist/authoring.mjs +405 -9
  4. package/dist/cli.d.ts.map +1 -1
  5. package/dist/local-ui.d.ts +2 -0
  6. package/dist/local-ui.d.ts.map +1 -1
  7. package/dist/runner.mjs +19532 -14246
  8. package/dist/runtime.mjs +10856 -8495
  9. package/dist/shadow.mjs +101 -1
  10. package/docs/README.md +14 -6
  11. package/docs/aggregate-reads.md +22 -0
  12. package/docs/auto-boundary-and-scoped-explore.md +338 -0
  13. package/docs/capability-authoring.md +36 -1
  14. package/docs/cloud-mode.md +18 -0
  15. package/docs/conformance.md +16 -0
  16. package/docs/current-scope.md +55 -28
  17. package/docs/cursor-plugin.md +20 -3
  18. package/docs/database-enforced-scope.md +8 -0
  19. package/docs/dsl-reference.md +123 -4
  20. package/docs/getting-started-own-database.md +42 -35
  21. package/docs/guarded-crud-writeback.md +10 -1
  22. package/docs/http-mcp.md +222 -207
  23. package/docs/limitations.md +33 -9
  24. package/docs/local-mode.md +5 -2
  25. package/docs/mcp-client-setup.md +24 -11
  26. package/docs/mcp-clients.md +10 -4
  27. package/docs/openai-agents-sdk.md +16 -2
  28. package/docs/production.md +72 -7
  29. package/docs/release-notes.md +77 -3
  30. package/docs/runner-bundles.md +7 -2
  31. package/docs/runner-config-reference.md +96 -6
  32. package/docs/running-a-runner-fleet.md +42 -13
  33. package/docs/schema-api-candidates.md +28 -1
  34. package/docs/security-boundary.md +38 -3
  35. package/docs/store-lifecycle.md +93 -5
  36. package/docs/troubleshooting-first-run.md +98 -0
  37. package/examples/auto-boundary-churn/README.md +23 -0
  38. package/examples/auto-boundary-churn/app/page.tsx +8 -0
  39. package/examples/auto-boundary-churn/docker-compose.yml +16 -0
  40. package/examples/auto-boundary-churn/package.json +18 -0
  41. package/examples/auto-boundary-churn/prisma/schema.prisma +36 -0
  42. package/examples/auto-boundary-churn/seed/postgres.sql +126 -0
  43. package/examples/openai-agents-http/README.md +10 -4
  44. package/examples/openai-agents-http/agent.py +2 -2
  45. package/examples/runner-fleet/Dockerfile +7 -2
  46. package/examples/runner-fleet/README.md +11 -7
  47. package/examples/runner-fleet/docker-compose.yml +4 -4
  48. package/examples/runner-fleet/mint-dev-token.mjs +1 -1
  49. package/examples/runner-fleet/start-tls-runner.sh +21 -0
  50. package/examples/runner-fleet/synapsor.runner.json +27 -1
  51. package/examples/support-plan-credit/README.md +6 -1
  52. package/examples/support-plan-credit/mcp-client-examples/generic-streamable-http.json +4 -1
  53. package/examples/support-plan-credit/mcp-client-examples/openai-agents-streamable-http.ts +4 -0
  54. package/examples/support-plan-credit/synapsor.contract.json +0 -3
  55. package/fixtures/compatibility/published-1.5.4/manifest.json +76 -0
  56. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/aggregate-read.synapsor.sql +21 -0
  57. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/billing-late-fee.synapsor.sql +56 -0
  58. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/bounded-set-multi-term.synapsor.sql +30 -0
  59. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/principal-row-scope.synapsor.sql +23 -0
  60. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/aggregate-read/contract.json +119 -0
  61. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/approval-quorum/contract.json +44 -0
  62. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/bounded-set-threats/contract.json +115 -0
  63. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/principal-row-scope/contract.json +78 -0
  64. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/proposal-capability/contract.json +101 -0
  65. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/reversible-change-sets/contract.json +98 -0
  66. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/valid/basic-read.contract.json +60 -0
  67. package/llms.txt +37 -0
  68. package/package.json +7 -4
  69. package/schemas/synapsor.runner.schema.json +98 -1
package/CHANGELOG.md CHANGED
@@ -1,6 +1,86 @@
1
1
  # Changelog
2
2
 
3
- ## 1.5.3 (prepared, not published)
3
+ ## 1.6.0 (prepared, not published)
4
+
5
+ ### Connect, Explore, Protect
6
+
7
+ - Adds deterministic whole-schema Auto Boundary drafting from database
8
+ metadata, statically parsed Prisma/Drizzle schemas, OpenAPI documents, and
9
+ existing Synapsor definitions. It executes no adopter code, samples no source
10
+ rows before activation, uses no LLM, and emits only disabled public DSL,
11
+ canonical JSON, tests, review evidence, and a generation lock.
12
+ - Adds a secured local Workbench review for trusted tenant/principal scope,
13
+ visible and kept-out fields, typed filters, aggregate-safe measures,
14
+ `count_distinct`, reviewed dimensions and time buckets, one-hop
15
+ relationships, cohort suppression, privacy/query budgets, and exact
16
+ role/grant/RLS posture. Activation binds every decision to one immutable
17
+ digest.
18
+ - Adds authoring-only Scoped Explore through exactly `app.describe_data` and
19
+ `app.explore_data`. Row and PM-style aggregate plans contain no SQL or
20
+ arbitrary identifiers, run with verified read-only credentials and enforced
21
+ read-only transactions, and retain only normalized redacted audit metadata.
22
+ - Adds a deliberately small aggregate grammar for counts, reviewed distinct
23
+ identifiers, sums/averages, categorical dimensions, day/week/month buckets,
24
+ bounded comparisons and top-N, optional proven many-to-one relationships,
25
+ cohort suppression, and durable extraction/differencing/rate budgets.
26
+ - Adds Protect This Query. Workbench freezes a successful plan into public
27
+ `.synapsor.sql`, canonical `protected_read` authority, positive/deny/scope/
28
+ suppression/drift tests, and a disabled named capability. Human exact-digest
29
+ activation removes broad Explore while preserving the named production tool.
30
+ - Adds lock-bound schema/role/grant/ownership/RLS/compiler/Spec drift checks.
31
+ Additive schema fields receive no authority; breaking generated-authority
32
+ drift fails closed until regeneration and review.
33
+ - Preserves published 1.x contracts, exact legacy normalization/digests,
34
+ established CLI selectors and automation, active tools, TypeScript authoring,
35
+ manual/headless operation, guarded writes, Data PRs, app-owned executors, and
36
+ deployments without generation locks through packed compatibility fixtures.
37
+ - Prepares `@synapsor/runner@1.6.0`, `@synapsor/dsl@1.5.0`, and
38
+ `@synapsor/spec@1.5.0`. Nothing is published, tagged, pushed, or released by
39
+ this change.
40
+
41
+ ## 1.5.4 (published 2026-07-22)
42
+
43
+ ### Networked MCP authentication hardening
44
+
45
+ - Defines explicit local-loopback, remote single-tenant, and shared multi-tenant
46
+ HTTP security profiles while preserving zero-configuration local stdio.
47
+ - Refuses non-loopback cleartext listeners before bind unless the operator
48
+ explicitly selects a trusted TLS proxy or authenticated break-glass posture.
49
+ Runner-owned TLS and optional mTLS remain supported.
50
+ - Hardens opaque endpoint tokens with environment-only provisioning, production
51
+ entropy checks, constant-time comparison, one bounded previous-token rotation
52
+ slot, and per-session credential pinning. Opaque tokens remain service access
53
+ credentials, not tenant or user identity.
54
+ - Requires verified signed identity for shared deployments. Runner validates
55
+ algorithm, signature, issuer, audience/resource, time, scope, tenant, and
56
+ principal on every request, including requests for existing MCP sessions.
57
+ - Adds RFC 9728 protected-resource metadata and standards-correct Bearer
58
+ challenges for external authorization servers. Runner remains a protected
59
+ resource and does not issue passwords, access tokens, or refresh tokens.
60
+ - Adds exact Origin and Host policy, bounded headers/bodies/connections/sessions,
61
+ TLS preflight, bounded public-only JWKS handling, and safe overload responses.
62
+ - Expands `doctor`, help, client generators, fleet examples, and deployment docs
63
+ so operators can distinguish TLS, Bearer presentation, opaque tokens, JWTs,
64
+ MCP session IDs, trusted context, database scope, and operator authority
65
+ without printing credential values.
66
+ - Adds read-only, no-ID-first `lifecycle` inspection across local SQLite and
67
+ shared PostgreSQL runtime stores. Latest, filtered business-object lookup, and
68
+ proposal/evidence/replay/job/intent/receipt/audit handles resolve one typed,
69
+ redacted proposal-to-receipt/replay timeline without creating jobs, leases,
70
+ source calls, or Cloud synchronization.
71
+ - Makes UPDATE conflict guarding exact by default in the SQL-like DSL.
72
+ Omitting `CONFLICT GUARD <column>` now fails. The explicit legacy
73
+ `CONFLICT GUARD WEAK ROW HASH ACKNOWLEDGED` form is limited to ordinary
74
+ single-row source-DB UPDATE and warns that projection hashing can miss outside
75
+ changes.
76
+ - Preserves canonical `SESSION` for implementations with a real typed session
77
+ boundary while making Runner fail closed with
78
+ `SESSION_BINDING_UNSUPPORTED`. Runner-targeted DSL validation, contract load,
79
+ lint/explain, and runtime no longer allow an environment fallback.
80
+ - Published `@synapsor/runner@1.5.4` and `@synapsor/dsl@1.4.4`;
81
+ `@synapsor/spec@1.4.2` and the Cloud CLI remain unchanged.
82
+
83
+ ## 1.5.3 (published 2026-07-21)
4
84
 
5
85
  ### Intent to Safe Action
6
86
 
@@ -26,7 +106,7 @@
26
106
  publishes an honest alternatives guide, and adds a deterministic 36-second
27
107
  support-plan-credit cut backed by real PostgreSQL proposal, receipt, retry,
28
108
  and stale-conflict evidence.
29
- - Prepares only `@synapsor/runner@1.5.3`; `@synapsor/spec@1.4.2`,
109
+ - Published only `@synapsor/runner@1.5.3`; `@synapsor/spec@1.4.2`,
30
110
  `@synapsor/dsl@1.4.3`, and the Cloud CLI remain unchanged.
31
111
 
32
112
  ## 1.5.2 (prepared, not published)
package/README.md CHANGED
@@ -21,8 +21,7 @@ No database, Docker, config, MCP client, LLM, or account is required:
21
21
  npx -y @synapsor/runner try --prove
22
22
  ```
23
23
 
24
- The four-second product measurement begins after package resolution. A cold
25
- `npx` download is recorded separately because registry and network time vary.
24
+ Timing begins after package resolution; cold `npx` download time varies.
26
25
 
27
26
  The embedded synthetic source requests a $55 waiver and proves:
28
27
 
@@ -34,116 +33,152 @@ Restart-safe retry: yes; duplicate mutations: 0
34
33
  Stale apply refused: yes
35
34
  ```
36
35
 
37
- Review happens outside the model-facing tools. The command stores inspectable
38
- state under `./.synapsor/try/`; it teaches the boundary and does not claim to
39
- test your database connection. `demo --quick` remains a noninteractive compatibility alias.
36
+ Review happens outside model-facing tools. State is stored under
37
+ `./.synapsor/try/`; this proves the boundary, not your database connection.
38
+ `demo --quick` remains a noninteractive compatibility alias.
40
39
 
41
- ## Protect One Action In Your Application
40
+ ## Audit An Existing MCP Server
41
+
42
+ Audit a typical raw-SQL MCP server without launching or calling one:
43
+
44
+ ```bash
45
+ npx -y @synapsor/runner audit --example dangerous-db-mcp
46
+ ```
47
+
48
+ Audit your own tool manifest, remote `tools/list`, or stdio server:
49
+
50
+ ```bash
51
+ npx -y @synapsor/runner audit ./tools-list.json
52
+ ```
53
+
54
+ It flags raw SQL, arbitrary identifiers, model-controlled authority, and
55
+ model-facing writeback without calling business tools. See [MCP Database Risk
56
+ Review](docs/mcp-audit.md) and the [alternatives
57
+ guide](docs/alternatives.md).
58
+
59
+ ## Connect Your Staging Application
42
60
 
43
- Start with a staging database and a read-only credential. Runner inspects
44
- metadata, creates one reviewed read boundary, and opens the secured localhost
45
- Workbench:
61
+ Use a dedicated SELECT-only, non-owner staging credential. Runner combines the
62
+ whole database schema with statically parsed Prisma, Drizzle, OpenAPI, and
63
+ existing Synapsor definitions. It does not execute adopter code, sample source
64
+ rows, or use an LLM:
46
65
 
47
66
  ```bash
48
67
  npm install -g @synapsor/runner
49
68
  export DATABASE_URL="postgresql://runner_reader:REPLACE_ME@db.example.com:5432/app?sslmode=require"
69
+ export SYNAPSOR_TENANT_ID="acme"
70
+ export SYNAPSOR_PRINCIPAL="developer-1"
50
71
  synapsor-runner start --from-env DATABASE_URL --schema public
51
72
  ```
52
73
 
53
- Describe one business action. This creates an inert TypeScript draft; it does
54
- not add a tool or change the active contract:
74
+ A fresh project opens the secured localhost Workbench and emits disabled DSL,
75
+ canonical JSON, tests, review evidence, and a generation lock. Review scope,
76
+ fields, aggregate members, relationships, privacy budgets, profile, and exact
77
+ role/RLS posture, then activate the exact digest. Existing tools stay unchanged.
78
+
79
+ ## Ask Your First Real Question In Cursor
80
+
81
+ After activation, let Runner add only the local authoring entry to this Cursor
82
+ project:
55
83
 
56
84
  ```bash
57
- synapsor-runner start \
58
- --action plan_credit \
59
- --description "Propose one reviewed customer plan credit" \
60
- --based-on support.inspect_customer
85
+ synapsor-runner mcp install cursor \
86
+ --project \
87
+ --authoring \
88
+ --project-root . \
89
+ --yes
61
90
  ```
62
91
 
63
- Add the reviewed tools to the current Cursor project:
92
+ Cursor sees exactly two temporary tools:
64
93
 
65
- ```bash
66
- synapsor-runner mcp install cursor --project \
67
- --config ./synapsor.runner.json \
68
- --store ./.synapsor/local.db
94
+ ```text
95
+ app.describe_data
96
+ app.explore_data
69
97
  ```
70
98
 
71
- In Cursor, use the Workbench's exact prompt. The checked-in project
72
- instructions require the coding agent to draft and validate the action while
73
- leaving effect review and activation to you. Once activated, a request such as
74
- "give CUS-3001 a $25 plan credit" can only create a semantic proposal:
99
+ Ask a bounded question such as:
75
100
 
76
101
  ```text
77
- Data PR wrp_...
78
- Action support.propose_plan_credit on CUS-3001
79
- Effect plan_credit_cents: 0 -> 2500
80
- Source unchanged before approval: Yes
102
+ Which reviewed regions and reason categories contributed most to the increase
103
+ in churned accounts by week?
81
104
  ```
82
105
 
83
- Review the exact effect in the secured Workbench, select **Approve outside
84
- MCP**, then run the displayed guarded apply command from a trusted terminal.
85
- The agent has no approval or commit tool. Runner rechecks scope, policy, row
86
- version, bounds, and idempotency before returning a receipt; a retry cannot
87
- duplicate the mutation and a stale proposal conflicts.
106
+ Runner accepts a typed plan, not SQL. It validates every member against the
107
+ activated digest, injects trusted scope, and runs a read-only transaction.
108
+ Small cohorts are suppressed and durable budgets limit repeated differencing.
109
+ This is descriptive analysis, not proof of causation.
88
110
 
89
- See the [own-database guide](docs/getting-started-own-database.md) for the full
90
- staging path and [Cursor plugin guide](docs/cursor-plugin.md) for
91
- `/synapsor-protect` and the plugin boundary.
111
+ Scoped Explore is local authoring only. Missing/unknown/production profiles,
112
+ write-capable or owner credentials, stale generation locks, remote/shared HTTP,
113
+ and non-loopback runtimes never advertise these tools.
92
114
 
93
- ## Audit An Existing MCP Server
115
+ ## Protect This Query
94
116
 
95
- Audit a typical raw-SQL MCP server without launching or calling one:
117
+ Choose the useful result in Workbench. No opaque ID needs to be copied. Runner
118
+ freezes the reviewed shape into public DSL, canonical JSON, and tests under
119
+ `synapsor/protected/drafts/`. The named capability starts disabled and requires
120
+ exact-digest human activation outside MCP.
121
+
122
+ After activation, Scoped Explore is disabled. Update Cursor to the production
123
+ config:
96
124
 
97
125
  ```bash
98
- npx -y @synapsor/runner audit --example dangerous-db-mcp
126
+ synapsor-runner mcp install cursor \
127
+ --project \
128
+ --config ./synapsor.runner.json \
129
+ --store ./.synapsor/local.db \
130
+ --yes
99
131
  ```
100
132
 
101
- Audit your own tool manifest, remote `tools/list`, or stdio server:
133
+ Production exposes the protected named capability, not `app.explore_data`.
134
+ Read the complete [Auto Boundary, Scoped Explore, And Protect
135
+ guide](docs/auto-boundary-and-scoped-explore.md).
136
+
137
+ ## Create An Exact Data PR
138
+
139
+ For a write, describe one business action. This creates an inert TypeScript
140
+ draft; it does not add a tool or change the active contract:
102
141
 
103
142
  ```bash
104
- npx -y @synapsor/runner audit ./tools-list.json
143
+ synapsor-runner start \
144
+ --action plan_credit \
145
+ --description "Propose one reviewed customer plan credit" \
146
+ --based-on support.inspect_customer
105
147
  ```
106
148
 
107
- It flags raw SQL, arbitrary identifiers, model-controlled authority,
108
- model-facing approval/writeback, and missing conflict or idempotency signals.
109
- It does not call business tools. See [MCP Database Risk
110
- Review](docs/mcp-audit.md) for local manifests, selected-server checks, CI,
111
- SARIF, evidence labels, and limits. You may not need Runner: use the
112
- [alternatives guide](docs/alternatives.md) to compare direct read-only access,
113
- hand-built tools, and this reviewed boundary.
114
-
115
- ## Safety Model
149
+ Once a human activates that exact action digest, an agent request can create
150
+ only a semantic proposal:
116
151
 
117
152
  ```text
118
- AI agent or MCP client
119
- |
120
- | reviewed semantic tool
121
- v
122
- +--------------------------------+
123
- | Synapsor Runner MCP |
124
- | trusted tenant/principal scope |
125
- | evidence + query audit |
126
- | proposals, not direct writes |
127
- +--------------------------------+
128
- |
129
- | scoped read / approved guarded writeback
130
- v
131
- +--------------------------------+
132
- | Your Postgres or MySQL |
133
- | source of truth |
134
- +--------------------------------+
135
-
136
- Local SQLite ledger:
137
- evidence -> proposal -> approval -> receipt -> replay
153
+ Data PR wrp_...
154
+ Action support.propose_plan_credit on CUS-3001
155
+ Effect plan_credit_cents: 0 -> 2500
156
+ Source unchanged before approval: Yes
157
+ ```
158
+
159
+ Approve in Workbench outside MCP; a trusted operator or worker commits. Runner
160
+ supports guarded single-row INSERT/UPDATE/DELETE, fixed-predicate bounded
161
+ UPDATE/DELETE, and exact-review batch INSERT. Rich transactions and external
162
+ effects use app-owned executors.
163
+
164
+ Runner rechecks scope, policy, row version, bounds, idempotency, and affected
165
+ rows before returning a receipt. A retry cannot duplicate the mutation and a
166
+ stale proposal conflicts. Inspect the latest lifecycle without copying an ID:
167
+
168
+ ```bash
169
+ synapsor-runner lifecycle --details --store ./.synapsor/local.db
138
170
  ```
139
171
 
140
- The model can inspect scoped data and propose an exact change. It cannot call
141
- approval, apply, or revert tools. A human or trusted operator approves outside
142
- MCP, then Runner performs a guarded write or routes the proposal to an
143
- app-owned executor.
172
+ See the [own-database guide](docs/getting-started-own-database.md),
173
+ [Cursor plugin guide](docs/cursor-plugin.md), and
174
+ [store lifecycle guide](docs/store-lifecycle.md) for the complete paths.
175
+
176
+ ## Safety Model
144
177
 
145
- Contracts fix trusted context, fields, bounds, transitions, and approvals;
146
- evidence, query audit, receipts, and replay preserve the lifecycle. Runner does
178
+ Contracts fix trusted context, fields, bounds, transitions, and approval.
179
+ Model-facing tools can inspect scoped data and propose exact changes, but cannot
180
+ approve, apply, or revert. A trusted operator/worker performs guarded writeback;
181
+ the ledger links evidence, proposal, decision, receipt, and replay. Runner does
147
182
  not make raw SQL or prompt-injection-prone clients safe.
148
183
 
149
184
  ## Choose An Isolation Mode
@@ -155,60 +190,31 @@ not make raw SQL or prompt-injection-prone clients safe.
155
190
  | `postgres_rls` | PostgreSQL also checks transaction-bound tenant/principal scope. Arbitrary trusted-context or credential control remains outside this guarantee. |
156
191
  | `tenant_bound` | Authenticated context selects a restricted per-tenant credential or process. |
157
192
 
158
- Stdio commonly trusts process environment; shared HTTP must use verified signed
159
- claims. Model arguments, query parameters, and arbitrary tenant headers are
160
- never trusted. MySQL has no native RLS; use restricted views or tenant
161
- credentials. See [Database scope] and the
193
+ Use stdio; no socket opens. HTTP requires authentication; non-loopback
194
+ listeners require TLS or an explicit trusted TLS proxy. Shared services require
195
+ signed claims. Model-controlled input and MCP session IDs never establish
196
+ identity. See [HTTP MCP].
197
+ MySQL has no native RLS; use restricted views or tenant credentials. See
198
+ [Database scope] and the
162
199
  [build-vs-adopt guide](docs/why-synapsor-vs-app-guardrails.md).
163
200
 
164
- ## Connect A Staging Database
165
-
166
- The setup above stores environment-variable names, not connection strings, and
167
- never falls back to synthetic data if inspection fails. Keep staging, database
168
- permissions, restricted views, and RLS underneath Runner. Bind trusted tenant
169
- and principal values in the launching process, then review the exact field and
170
- tool surface before connecting Cursor.
171
-
172
- The [complete own-database guide](docs/getting-started-own-database.md) covers
173
- validation, scoped reads, disabled Prisma/Drizzle/OpenAPI candidates, guarded
174
- single-row writes, and app-owned executors. Use the [host compatibility
175
- matrix](docs/host-compatibility.md) for accurately tested client behavior.
176
-
177
201
  ## Review And Prove Your Contract
178
202
 
179
- Before serving, use `contract explain`, `contract lint --strict`, and `contract
180
- test` for reviewer-readable boundaries and allow/deny/redaction cases. The
181
- built-in language server supplies diagnostics, completion, hover, and formatting for
182
- `.synapsor.sql` and legacy `.synapsor` files. See [Contract
183
- Review](docs/contract-review.md) and [Contract
184
- Testing](docs/contract-testing.md).
185
-
186
- Runner also supports reviewed [aggregate reads](docs/aggregate-reads.md),
187
- tenant-scoped tamper-evident [ledger reports](docs/compliance-reports.md), and
188
- opt-in [graduated-trust recommendations](docs/graduated-trust.md). Aggregate
189
- tools return one scalar and no source rows. Graduated trust is disabled by
190
- default, remains operator-only, and can export a reviewable artifact but never
191
- activate it.
203
+ Use `contract explain`, `contract lint --strict`, and `contract test`; the
204
+ language server handles `.synapsor.sql` and legacy `.synapsor`. See [Contract
205
+ Review](docs/contract-review.md), [Contract Testing](docs/contract-testing.md),
206
+ and the [own-database guide](docs/getting-started-own-database.md).
192
207
 
193
208
  ## Trust And Verification
194
209
 
195
210
  Start with the **[Threat Model](THREAT_MODEL.md)**. It defines protected assets,
196
211
  trust boundaries, covered threats, non-goals, and required operator controls.
197
212
 
198
- - [Conformance fixtures](docs/conformance.md) prove trusted context, scoped
199
- reads, kept-out fields, proposal boundaries, approval, receipts, and replay
200
- behavior rather than only validating JSON shape.
201
- - `contract test` lets adopters encode the same boundary checks for their own
202
- synthetic fixtures; it never invokes an LLM and refuses remote live targets
203
- by default.
204
- - MCP proposal, evidence, and replay handles are references rather than bearer
205
- authority: resource reads re-check the owning tenant and principal against
206
- the current trusted session.
207
- - `test:principal-scope`, `test:live-apply`, `test:guarded-crud`,
208
- `test:bounded-set`, and `test:reversible` prove cross-principal denial,
209
- no pre-approval mutation, guarded writes, idempotent retry, conflicts,
210
- bounded atomic sets, receipts, and reviewed compensation on disposable
211
- PostgreSQL/MySQL fixtures.
213
+ [Conformance fixtures](docs/conformance.md) and `contract test` cover trusted
214
+ scope, kept-out fields, proposals, approval, receipts, and replay. Resource
215
+ handles re-check tenant/principal rather than acting as bearer authority. Live
216
+ gates cover principal denial, no pre-approval mutation, idempotency, conflict,
217
+ bounded sets, and compensation on disposable databases.
212
218
 
213
219
  Runner is a narrow agent/database safety boundary, not a replacement for
214
220
  least-privilege database access, host security, or application authorization.
@@ -216,6 +222,7 @@ See [Security Boundary](docs/security-boundary.md) and
216
222
  [Current Limitations](docs/limitations.md).
217
223
 
218
224
  [Database scope]: docs/database-enforced-scope.md
225
+ [HTTP MCP]: docs/http-mcp.md
219
226
 
220
227
  ## Operate The Approval Loop
221
228
 
@@ -242,16 +249,10 @@ and the [Runner Config Reference](docs/runner-config-reference.md).
242
249
 
243
250
  ## OSS And Cloud
244
251
 
245
- Synapsor Runner works by itself for local, single-node, and bounded small-fleet
246
- deployments: your database remains the source of truth and Runner stores review
247
- artifacts in the default local SQLite ledger or an opt-in shared Postgres
248
- runtime store.
249
- Synapsor Cloud adds a shared contract registry, immutable versions,
250
- source-scoped Runner connections, downloadable bundles, a human approval
251
- inbox, durable leased writeback jobs, and a redacted shared activity/receipt
252
- chronology. Database credentials and guarded execution remain local. See [Cloud
253
- Mode](docs/cloud-mode.md) for the design-partner path and [OSS Runner vs
254
- Synapsor Cloud](docs/oss-vs-cloud.md) for the detailed boundary.
252
+ Runner works alone with local SQLite or an opt-in shared Postgres ledger.
253
+ Synapsor Cloud adds shared registry, approval, leased jobs, and redacted
254
+ activity/receipt chronology; credentials and guarded execution stay local. See
255
+ [Cloud Mode](docs/cloud-mode.md) and [OSS vs Cloud](docs/oss-vs-cloud.md).
255
256
 
256
257
  `synapsor-runner` owns the local MCP/database boundary. `synapsor` from
257
258
  `@synapsor/cli` manages Cloud review and audit. Both Cloud push commands use