@synapsor/runner 1.4.121 → 1.4.123
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/CHANGELOG.md +42 -0
- package/README.md +25 -15
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/runner.mjs +2855 -347
- package/docs/README.md +1 -0
- package/docs/capability-authoring.md +59 -1
- package/docs/cloud-cli.md +248 -0
- package/docs/cloud-mode.md +88 -6
- package/docs/cloud-push.md +22 -5
- package/docs/conformance.md +6 -0
- package/docs/contract-review.md +33 -0
- package/docs/contract-testing.md +30 -1
- package/docs/dsl-reference.md +11 -0
- package/docs/hosted-cloud-linked-verification.md +97 -0
- package/docs/oss-vs-cloud.md +13 -6
- package/docs/release-notes.md +48 -0
- package/docs/rfcs/007-trusted-principal-row-scope.md +75 -0
- package/docs/runner-bundles.md +24 -0
- package/docs/running-a-runner-fleet.md +8 -0
- package/docs/security-boundary.md +19 -2
- package/examples/runner-fleet/seed/mysql.sql +5 -1
- package/examples/runner-fleet/seed/postgres.sql +5 -1
- package/examples/support-plan-credit/README.md +8 -6
- package/fixtures/contracts/capability-surface-fitness.contract.json +190 -0
- package/fixtures/dsl/principal-row-scope.synapsor.sql +23 -0
- package/fixtures/protocol/MANIFEST.json +10 -10
- package/package.json +1 -1
- package/schemas/change-set.v1.schema.json +14 -0
- package/schemas/change-set.v2.schema.json +14 -0
- package/schemas/change-set.v3.schema.json +2 -0
- package/schemas/compensation-change-set.v1.schema.json +3 -2
- package/schemas/inverse-descriptor.v1.schema.json +2 -0
- package/schemas/synapsor.contract-tests.schema.json +11 -1
- package/schemas/writeback-job.v1.schema.json +14 -0
- package/schemas/writeback-job.v2.schema.json +14 -0
- package/schemas/writeback-job.v3.schema.json +2 -0
- package/schemas/writeback-job.v4.schema.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,47 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.4.123 (prepared, not published)
|
|
4
|
+
|
|
5
|
+
### Advisory capability-surface fitness lint
|
|
6
|
+
|
|
7
|
+
- Adds deterministic `contract lint` advisories for generic query-like string
|
|
8
|
+
arguments, more than eight capabilities on one normalized target,
|
|
9
|
+
non-business-operation names, and structurally near-duplicate capabilities.
|
|
10
|
+
- Keeps canonical validation, compilation, MCP serving, and runtime enforcement
|
|
11
|
+
unchanged. Advisories succeed by default; explicit `--strict` or
|
|
12
|
+
`--fail-on warning` remains the opt-in CI policy gate.
|
|
13
|
+
- Adds stable structured details and surface metrics to JSON/SARIF output, plus
|
|
14
|
+
a concise text summary. No database connection, environment value, source
|
|
15
|
+
row, or probabilistic classifier is involved.
|
|
16
|
+
- Stages only `@synapsor/runner@1.4.123`; `@synapsor/spec@1.4.2`,
|
|
17
|
+
`@synapsor/dsl@1.4.3`, and `@synapsor/cli@0.1.0-beta.1` are unchanged.
|
|
18
|
+
|
|
19
|
+
## 1.4.122 (2026-07-16)
|
|
20
|
+
|
|
21
|
+
### Trusted principal row scope and Cloud-linked governance
|
|
22
|
+
|
|
23
|
+
- Adds a canonical reviewer-fixed principal row scope that is always
|
|
24
|
+
AND-composed with tenant scope and resolved only from a required trusted
|
|
25
|
+
context binding. Missing or invalid principal authority fails closed.
|
|
26
|
+
- Enforces the bound principal predicate in PostgreSQL and MySQL reads,
|
|
27
|
+
proposals, aggregates, guarded CRUD, bounded sets, executor envelopes,
|
|
28
|
+
receipts, replay, and reviewed compensation. Same-tenant cross-principal
|
|
29
|
+
access uses the same generic miss as cross-tenant or absent rows.
|
|
30
|
+
- Preserves the scope through DSL parse/format/compile, Spec validation and
|
|
31
|
+
digesting, config normalization, protocol jobs, C++/Cloud round trips,
|
|
32
|
+
contract explanation/testing, and scoped evidence/proposal/resource handles.
|
|
33
|
+
- Adds explicit `local_only` and `cloud_linked` authority behavior. Cloud-linked
|
|
34
|
+
proposals use a durable idempotent outbox, metadata-only evidence residency,
|
|
35
|
+
Cloud-governed approval/leasing, terminal-state reconciliation, and no local
|
|
36
|
+
approval/apply fallback while Cloud is unavailable.
|
|
37
|
+
- Separates contract-registry human/service credentials from Runner machine
|
|
38
|
+
tokens. Cloud push no longer accepts secrets through command arguments or a
|
|
39
|
+
Runner-token fallback.
|
|
40
|
+
- Introduces the separately packable `@synapsor/cli@0.1.0-beta.1` Cloud client;
|
|
41
|
+
`synapsor-runner` remains the local MCP/database enforcement boundary.
|
|
42
|
+
- Published `@synapsor/spec@1.4.2`, `@synapsor/dsl@1.4.3`, and
|
|
43
|
+
`@synapsor/runner@1.4.122`.
|
|
44
|
+
|
|
3
45
|
## 1.4.121 (prepared, not published)
|
|
4
46
|
|
|
5
47
|
### Contract trust surface and bounded-set parser correctness
|
package/README.md
CHANGED
|
@@ -14,9 +14,8 @@ surface.
|
|
|
14
14
|
|
|
15
15
|
## Prove It In 60 Seconds
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
seconds and touch nothing but a local fixture file.
|
|
17
|
+
Path: **audit** MCP risk, **demo** the boundary, then **connect** staging. The
|
|
18
|
+
first two commands touch only a local fixture.
|
|
20
19
|
|
|
21
20
|
First, inspect the risk in a typical raw-SQL database MCP server. This works
|
|
22
21
|
even if you never adopt Runner:
|
|
@@ -25,18 +24,16 @@ even if you never adopt Runner:
|
|
|
25
24
|
npx -y @synapsor/runner audit --example dangerous-db-mcp
|
|
26
25
|
```
|
|
27
26
|
|
|
28
|
-
|
|
29
|
-
`tools/list` endpoint, or stdio MCP server:
|
|
27
|
+
Audit your own tool manifest, remote `tools/list`, or stdio server:
|
|
30
28
|
|
|
31
29
|
```bash
|
|
32
30
|
npx -y @synapsor/runner audit ./tools-list.json
|
|
33
31
|
```
|
|
34
32
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
Review](docs/mcp-audit.md) for remote, stdio, JSON, and Markdown workflows.
|
|
33
|
+
It flags raw SQL, arbitrary identifiers, model-controlled authority,
|
|
34
|
+
model-facing approval/writeback, and missing conflict or idempotency signals.
|
|
35
|
+
It does not call business tools. See [MCP Database Risk
|
|
36
|
+
Review](docs/mcp-audit.md) for supported workflows and limits.
|
|
40
37
|
|
|
41
38
|
Then see the proposal, approval boundary, evidence, and replay loop. It needs no
|
|
42
39
|
database, Docker, config file, MCP client, or Synapsor account:
|
|
@@ -169,8 +166,8 @@ compensation.
|
|
|
169
166
|
## Review And Prove Your Contract
|
|
170
167
|
|
|
171
168
|
Before serving a contract, use `contract explain` for a reviewer-readable
|
|
172
|
-
boundary, `contract lint --strict` for deterministic CI checks,
|
|
173
|
-
test` for adopter-owned allow/deny/redaction cases. The built-in language
|
|
169
|
+
boundary, `contract lint --strict` for deterministic surface-fitness CI checks,
|
|
170
|
+
and `contract test` for adopter-owned allow/deny/redaction cases. The built-in language
|
|
174
171
|
server supplies diagnostics, completion, hover, and formatting for
|
|
175
172
|
`.synapsor.sql` and legacy `.synapsor` files. See [Contract
|
|
176
173
|
Review](docs/contract-review.md) and [Contract
|
|
@@ -197,6 +194,10 @@ trust boundaries, covered threats, non-goals, and required operator controls.
|
|
|
197
194
|
- MCP proposal, evidence, and replay handles are references rather than bearer
|
|
198
195
|
authority: resource reads re-check the owning tenant and principal against
|
|
199
196
|
the current trusted session.
|
|
197
|
+
- Same-tenant owner/assignee isolation uses a reviewed
|
|
198
|
+
[`PRINCIPAL SCOPE KEY`](docs/capability-authoring.md#same-tenant-principal-row-scope)
|
|
199
|
+
composed with mandatory tenant scope; `test:principal-scope` proves generic
|
|
200
|
+
cross-principal denial and evidence-handle isolation on Postgres and MySQL.
|
|
200
201
|
- `test:live-apply`, `test:guarded-crud`, `test:bounded-set`, and
|
|
201
202
|
`test:reversible` run disposable PostgreSQL/MySQL scenarios. They prove no
|
|
202
203
|
pre-approval mutation, guarded single-row CRUD, idempotent retry,
|
|
@@ -229,6 +230,7 @@ and [Small Runner Fleets](docs/running-a-runner-fleet.md).
|
|
|
229
230
|
| `@synapsor/runner` | CLI, MCP runtime, local ledger, proposals, approval, guarded writeback, replay, and MCP audit. |
|
|
230
231
|
| `@synapsor/spec` | Canonical portable contracts for contexts, capabilities, workflows, evidence, proposals, receipts, and replay. |
|
|
231
232
|
| `@synapsor/dsl` | SQL-like authoring that compiles contexts, capabilities, and workflow declarations into canonical contract JSON. |
|
|
233
|
+
| `@synapsor/cli` | Synapsor Cloud administration, contract governance, human review, Runner connections, and shared audit records. |
|
|
232
234
|
|
|
233
235
|
Runner executes locally. The spec is shared by Runner and Cloud/C++; the DSL
|
|
234
236
|
is its reviewable source format. Start with [Capability
|
|
@@ -248,12 +250,20 @@ deployments: your database remains the source of truth and Runner stores review
|
|
|
248
250
|
artifacts in the default local SQLite ledger or an opt-in shared Postgres
|
|
249
251
|
runtime store.
|
|
250
252
|
Synapsor Cloud adds a shared contract registry, immutable versions,
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
253
|
+
source-scoped Runner connections, downloadable bundles, a human approval
|
|
254
|
+
inbox, durable leased writeback jobs, and a redacted shared activity/receipt
|
|
255
|
+
chronology. Database credentials and guarded execution remain local. See [Cloud
|
|
256
|
+
Mode](docs/cloud-mode.md) for the design-partner path and [OSS Runner vs
|
|
257
|
+
Synapsor Cloud](docs/oss-vs-cloud.md) for the detailed boundary.
|
|
258
|
+
|
|
259
|
+
`synapsor-runner` owns the local MCP/database boundary. `synapsor` from
|
|
260
|
+
`@synapsor/cli` manages Cloud review and audit. Both Cloud push commands use
|
|
261
|
+
the same contract digest and scoped service-key API. See the [Cloud CLI
|
|
262
|
+
guide](https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/cloud-cli.md).
|
|
254
263
|
|
|
255
264
|
## Next Steps
|
|
256
265
|
|
|
266
|
+
- Follow the [step-by-step Synapsor Tutorial](https://github.com/sandeshtiwari/Synapsor-Tutorial).
|
|
257
267
|
- Run the [`support-plan-credit` flagship example](examples/support-plan-credit).
|
|
258
268
|
- Connect [Claude, Cursor, OpenAI Agents SDK, or another MCP client](docs/mcp-clients.md).
|
|
259
269
|
- Author and [push a validated contract to Cloud](docs/cloud-push.md).
|
package/dist/cli.d.ts
CHANGED
|
@@ -14,6 +14,9 @@ export declare function runInitWizard(args: string[], options?: {
|
|
|
14
14
|
stdout?: Pick<NodeJS.WriteStream, "write">;
|
|
15
15
|
}): Promise<number>;
|
|
16
16
|
export declare function resolveSqlWriteDatabaseUrl(job: WritebackJob, configPath: string, env: NodeJS.ProcessEnv): Promise<string>;
|
|
17
|
+
export declare function verifyLocalWritebackAuthority(job: WritebackJob, configPath: string, storePath?: string, options?: {
|
|
18
|
+
cloudApproved?: boolean;
|
|
19
|
+
}): Promise<void>;
|
|
17
20
|
export declare function reconciliationSupportedOutcome(observation: ReconciliationObservation): "applied" | "conflict" | "failed";
|
|
18
21
|
export declare function reconciliationReceipt(intent: StoredWritebackIntent, observation: ReconciliationObservation, outcome: "applied" | "conflict" | "failed", runnerId: string, reason: string): ExecutionReceiptV2 | ExecutionReceiptV3 | ExecutionReceiptV4;
|
|
19
22
|
export {};
|
package/dist/cli.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAYA,OAAO,
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAYA,OAAO,EAAkU,KAAK,WAAW,EAA0H,MAAM,6BAA6B,CAAC;AAIvf,OAAO,EAkBL,KAAK,qBAAqB,EAK3B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAgI,KAAK,kBAAkB,EAAE,KAAK,kBAAkB,EAAE,KAAK,kBAAkB,EAAqG,KAAK,YAAY,EAAwB,MAAM,2BAA2B,CAAC;AAEhY,OAAO,EAQL,KAAK,gBAAgB,EAEtB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAWL,KAAK,yBAAyB,EAG/B,MAAM,8BAA8B,CAAC;AA8UtC,wBAA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