Skip to content

Commit 05e8f0f

Browse files
avrabeclaude
andauthored
docs: DSLTrans cutoff analysis + Forge protocol + v0.9.x milestone draft (#215)
Three docs-only deliverables wrapping the v0.9.x cycle: - docs/research/cutoff-theorem-modal-filtering.md applies Lucio's Cutoff Theorem (arXiv 2604.18792) to spar's modal filter, derives K_filter = 1 + max(C, E), gives a discharge plan (Kani / proptest), and is honest about where the theorem does NOT apply (negatives, cartesian-product SOM enumeration, fixed-point downstream passes, mode reachability). - docs/research/forge-replication-protocol.md + the forge-replication/ scaffold (descriptor.sexp, descriptor.aadl, tasks.json with 24 paired tasks, run_trial.sh, empty RESULTS.md) mirror Jin et al. (arXiv 2604.13108) for a self-target replication on spar. Pre-registration discipline; no numbers reported. - docs/blog/v0.9.x-milestone.md recaps v0.9.0..v0.9.3 (MCP + spar-insight; gPTP epsilon + frame quantization; RTA->WCTT coupling, Context_Switch_Time, sensitivity, ARINC severity; piecewise-affine arrival curves + PMOO/LUDB) and previews the v0.10.x trace-topology rollout (4 parsers, 5 checks, v1 contract URL). Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 1bcfcfd commit 05e8f0f

8 files changed

Lines changed: 1641 additions & 0 deletions

File tree

docs/blog/v0.9.x-milestone.md

Lines changed: 290 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,290 @@
1+
# v0.9.x milestone: NC kernel honesty, RTA→WCTT coupling, and a peek at v0.10.0 trace-topology
2+
3+
Status: **draft** — milestone wrap-up for the v0.9.x cycle.
4+
Last update: 2026-05-10.
5+
Audience: spar users tracking releases, OEMs comparing against
6+
commercial NC arms, anyone hunting the v0.10.0 trace-topology
7+
foundation.
8+
9+
> **Why care.** Between 2026-04-29 (v0.9.0) and 2026-05-10 (v0.9.3),
10+
> spar grew an MCP server, a runtime-trace assistant, and four
11+
> reviewer-driven tightness passes on the Network-Calculus kernel.
12+
> The output is byte-identical to v0.8.1 when the new properties are
13+
> unset — every change is opt-in or only flips a previously
14+
> optimistic bound. End-state: 2,900+ tests across 19 crates, 131
15+
> predeclared properties, four Lean theorem-statement skeletons
16+
> filed for v1.0.0 discharge, and the v0.10.0 trace-topology
17+
> foundation merged with four runtime-artefact parsers in tree.
18+
19+
---
20+
21+
## What landed in v0.9.x
22+
23+
Four releases, each with a sharp focus.
24+
25+
### v0.9.0 — MCP + spar-insight
26+
27+
(see [CHANGELOG.md](../../CHANGELOG.md#090--2026-04-29))
28+
29+
LLM agents got first-class access to the move-oracle via a JSON-RPC
30+
2.0 MCP server (`spar mcp serve`, or the standalone `spar-mcp`
31+
binary). Three tools, all `readOnlyHint: true` and
32+
`idempotentHint: true`:
33+
34+
- `spar.verify_move` — single hypothetical-rebinding check.
35+
- `spar.enumerate_moves` — design-space exploration with
36+
multi-objective ranking (`max-response | total-load |
37+
total-power | total-weight | balanced`).
38+
- `spar.check_chain` — end-to-end latency breakdown for a flow
39+
chain.
40+
41+
The deterministic-apply path stays CLI-exclusive by design: there is
42+
no `spar.apply_move` over MCP, ever. LLM agents propose, spar
43+
verifies deterministically, the apply path is replayable from the
44+
command line. The certification chain stays inside spar.
45+
46+
`spar-insight` (Track G) shipped alongside as the runtime-trace
47+
discrepancy assistant. Five rules on probe-point CTF traces from
48+
Zephyr: `WcetViolated`, `BcetUnderestimated`, `MeanDrift`,
49+
`MissingProbe`, `UnobservedProbe`. Binary CTF and ITM/SWO ingest
50+
deferred to a v0.9.x follow-up.
51+
52+
### v0.9.1 — NC kernel soundness (Tier-2 reviewer items)
53+
54+
(see [CHANGELOG.md](../../CHANGELOG.md#091--2026-04-29))
55+
56+
The v0.8.1 TSN bounds were *technically optimistic* in two ways. PR
57+
[#186](https://github.com/pulseengine/spar/pull/186) closed both:
58+
59+
- **gPTP sync-error ε.** The new `Spar_TSN::Sync_Error` property
60+
feeds the TAS dispatch in `wctt.rs`: ε subtracts from the
61+
effective open time and inflates the worst-case gate latency.
62+
Without ε, a frame could miss its window by ε in silicon — an
63+
unsound NC reading.
64+
- **Atomic-frame quantization.** `wctt.rs` now adds
65+
`ceil(max_frame_bytes · 8e12 / link_rate_bps)` ps per hop on the
66+
TAS and FIFO/Priority arms. Bytes-level NC under-counts by up to
67+
one MTU per hop because frames are atomic.
68+
69+
Both changes are byte-identical to v0.8.1 when the new properties
70+
are unset (ε = 0, default `Max_Frame_Size`). Users who calibrated
71+
against v0.8.1 numbers will see ≈ +12.144 µs per 1 Gbps hop with
72+
1518 B MTU — the `WcttFrameQuantization` Info diagnostic flags
73+
exactly where.
74+
75+
### v0.9.2 — Honesty + tightness, sensitivity, ARINC severity
76+
77+
(see [CHANGELOG.md](../../CHANGELOG.md#092--2026-05-03))
78+
79+
Six PRs. The highlights for users:
80+
81+
- **RTA→WCTT release-jitter coupling
82+
([#199](https://github.com/pulseengine/spar/pull/199)).** When a
83+
stream source declares `Timing_Properties::Dispatch_Jitter`,
84+
that J is now treated as ingress release-jitter and inflates the
85+
arrival burst σ by `ρ·J` bytes. Single biggest credibility lift
86+
in the v0.9.x cycle — closes the reviewer's NC top-5 item #4.
87+
- **WCTT sensitivity output
88+
([#196](https://github.com/pulseengine/spar/pull/196)).** Every
89+
`WcttBound` Info is now followed by a `WcttSensitivity` Info
90+
carrying worst-hop partial derivatives
91+
`∂σ_self / ∂ρ_competing / ∂T_link`. Pure post-processing on the
92+
closed-form. Reviewer NC top-5 item #13: cheapest workflow win,
93+
turns spar from judge into design partner.
94+
- **Context_Switch_Time in RTA recurrence
95+
([#198](https://github.com/pulseengine/spar/pull/198)).** v0.8.x
96+
emitted a STPA-REQ-022 advisory if `Context_Switch_Time` was
97+
unset, then quietly used B=0 when it was set. Now the value
98+
inflates each thread's WCET by `2 × Context_Switch_Time` per
99+
Buttazzo §7 (one preemption-in + one preemption-out).
100+
- **CBS user-tunable Hi/Lo Credit
101+
([#195](https://github.com/pulseengine/spar/pull/195)).** v0.8.1
102+
hardcoded both credits to `Max_Frame_Size`. Real Qcc/YANG configs
103+
carry these per traffic class; now they are honoured.
104+
- **ARINC-PARTITION-ISOLATION promoted to Error.** Per DO-297
105+
spatial-isolation invariant. New `--allow
106+
arinc-partition-isolation` for legitimate IMA bypasses.
107+
108+
Tier A reviewer items #5/#6/#8/#9/#13 closed in one release.
109+
110+
### v0.9.3 — Piecewise-affine arrival curves + PMOO/LUDB
111+
112+
(see [CHANGELOG.md](../../CHANGELOG.md#093--2026-05-10))
113+
114+
Two PRs, both reviewer NC top-5 closeouts:
115+
116+
- **Piecewise-affine arrival curves
117+
([#204](https://github.com/pulseengine/spar/pull/204)).** New
118+
`PiecewiseAffineArrivalCurve` alongside the affine form.
119+
Multi-leaky-bucket `(σ₁, ρ₁) ∧ (σ₂, ρ₂) ∧ …` exactly captures
120+
"burst of N frames at line rate, then sustained at 100 Mbps" —
121+
the canonical T-SPEC pattern in real ADAS/TSN traffic. Operators
122+
take the min over buckets, which is the mathematically tight
123+
choice. Reviewer NC top-5 item #1.
124+
- **PMOO/LUDB tree-shaped multiplexing
125+
([#203](https://github.com/pulseengine/spar/pull/203)).** New
126+
`ludb_bound(tagged, competing, services)` for the
127+
zonal/automotive pattern. Numerical confirmation: **27.4 %
128+
tighter than SFA** on a 3-hop / 3-competing test, **23.7 %
129+
tighter** on 5-source zonal aggregation. Closes the "spar says
130+
31.7 ms vs RTaW says 8 ms" credibility gap on tree topologies.
131+
Reviewer NC top-5 item #2.
132+
133+
That makes 5/5 reviewer NC top-5 items closed across v0.9.1 / v0.9.2
134+
/ v0.9.3. The post-v0.9.0 reviewer narrative is now: NC arm has
135+
parity with RTaW-Pegase on the workloads where bounds matter most.
136+
137+
---
138+
139+
## DSLTrans-style cutoff analysis on modal filtering
140+
141+
Lucio's recent Cutoff Theorem (arXiv
142+
[2604.18792](https://arxiv.org/abs/2604.18792)) proves that bounded
143+
model checking is *complete* for a precise DSLTrans fragment plus
144+
positive existence / traceability properties — turning an
145+
otherwise-infinite search into a finite computable bound. The
146+
benchmark line in that paper is sharp: 552 properties proved, 345
147+
counterexamples, 2 undecided across 29 transformations.
148+
149+
We asked: does this apply to spar's **modal filtering** pass — the
150+
helpers in `crates/spar-analysis/src/modal.rs` that project a
151+
`SystemInstance` to the components and connections active in a given
152+
System Operational Mode?
153+
154+
Short answer: **yes for the positive case, no for the rest.** The
155+
filter is non-recursive, has no negation in matchers, and is
156+
layered (component filter and connection filter are independent),
157+
so it fits the fragment. For the property *"every element declared
158+
`in modes (s)` is preserved in the SOM-projection"*, the cutoff
159+
bound is concrete and small:
160+
161+
```
162+
K_filter = 1 + max(C, E)
163+
```
164+
165+
where `C` is the largest `in_modes` list on any component and `E`
166+
the same for any connection. On `test-data/parser/modes_test.aadl`
167+
that gives **K = 3** — three mode-name labels per element suffice to
168+
exhaust the filter's behavioural equivalence classes.
169+
170+
The theorem does **not** apply to: negative properties ("no inactive
171+
connection appears"); the cartesian-product SOM enumeration itself
172+
(`|SOMs| = ∏ |modes(c)|` is exponential in the input, not a
173+
verification artefact); fixed-point downstream passes (RTA
174+
recurrence, WCTT chain compose); and mode reachability (a graph
175+
reachability problem, deliberately exported to NuSMV via
176+
`mode_reachability::export_smv`).
177+
178+
Full analysis with discharge plan (Kani harness vs capped proptest):
179+
[`docs/research/cutoff-theorem-modal-filtering.md`](../research/cutoff-theorem-modal-filtering.md).
180+
181+
---
182+
183+
## Forge-style navigation evidence — protocol shipped, trials pending
184+
185+
Jin et al. (arXiv
186+
[2604.13108](https://arxiv.org/abs/2604.13108)) reported that
187+
conditioning an LLM agent with an architecture descriptor reduces
188+
navigation steps by **33–44 %** (Wilcoxon p=0.009, Cohen's d=0.92)
189+
on a controlled 24-task × 4-condition benchmark. Auto-generated
190+
descriptors hit 100 % accuracy vs 80 % blind on a separate 15-task
191+
artefact-vs-process arm. S-expressions detected all structural
192+
completeness errors where JSON failed atomically and YAML silently
193+
corrupted ~50 % of errors.
194+
195+
We mirror Jin's protocol on spar itself: 24 paired tasks, two arms
196+
(C0: no descriptor; C1: with `descriptor.sexp`), Wilcoxon
197+
signed-rank with α=0.05. The scaffolding is in tree:
198+
199+
- `docs/research/forge-replication/descriptor.sexp` — S-expression
200+
descriptor of the spar workspace.
201+
- `docs/research/forge-replication/tasks.json` — 24 code-localization
202+
tasks pinned to commit `bad85e6`.
203+
- `docs/research/forge-replication/run_trial.sh` — bash trial runner
204+
that drives `claude --print --output-format stream-json` and
205+
scores transcripts.
206+
- `docs/research/forge-replication/RESULTS.md` — empty results
207+
template with pre-registration prompts.
208+
209+
We have not run trials. Numbers will land in `RESULTS.md` once the
210+
user (or a community contributor) drives the scaffolding. The
211+
protocol document is honest about deviations from Jin's setup
212+
(self-target confound, hand-curated descriptor, no field-study arm).
213+
Pre-registration is the discipline; we record it in `RESULTS.md`
214+
before any trial fires.
215+
216+
Full protocol:
217+
[`docs/research/forge-replication-protocol.md`](../research/forge-replication-protocol.md).
218+
219+
---
220+
221+
## What's next: v0.10.0 trace-topology
222+
223+
(design:
224+
[`docs/designs/v0.10.0-trace-topology.md`](../designs/v0.10.0-trace-topology.md))
225+
226+
v0.10.0 ships the foundation for `spar trace topology`: the
227+
runtime/declared reconciler that asks *"does the AADL declaration
228+
match the wire?"* on a real OEM deployment.
229+
230+
Four parsers, all now landed:
231+
232+
- **PCAPNG FrameSource**
233+
([#210](https://github.com/pulseengine/spar/pull/210)) — Tier 1
234+
L2 frame ingest from `tcpdump -w` / Wireshark captures.
235+
- **LLDP JSON TopologySource**
236+
([#208](https://github.com/pulseengine/spar/pull/208)) — neighbor
237+
adjacency from `lldpctl -f json`.
238+
- **Qcc YANG ConfigSource** — TSN switch config from
239+
NETCONF/RESTCONF.
240+
- **gPTP JSON PtpTimeSource**
241+
([#211](https://github.com/pulseengine/spar/pull/211)) —
242+
per-port ε from gPTP logs.
243+
244+
Five deterministic checks on the parsed-vs-declared diff:
245+
246+
- `IdentityUnknown` — runtime saw an identity (MAC,
247+
chassis-id/port-id, stream-handle, multicast group) the AADL
248+
didn't declare.
249+
- `TopologyMissingWiring` — LLDP saw an adjacency without a
250+
corresponding AADL `bus access` connection.
251+
- `ConfigDrift``Spar_TSN::Gate_Control_List` (and 7 sibling
252+
properties) on the wire disagree with the declaration.
253+
- `GptpOutOfBudget` — observed ε exceeds the declared
254+
`Spar_TSN::Sync_Error`. This is the soundness guard for v0.9.1's
255+
TAS bounds: if it fires, the WCTT readings were optimistic.
256+
- `BinaryMismatch` — running image digest disagrees with the
257+
declared one.
258+
259+
Output: SARIF 2.1.0 + a signed in-toto v1.0 attestation. Predicate
260+
URL (the integration anchor for rivet, witness, and OEM internal
261+
certification kits):
262+
263+
```
264+
https://pulseengine.eu/spar-trace-topology/v1
265+
```
266+
267+
Phasing: v0.10.0 = foundation + parsers; v0.11.0 = engine + SARIF;
268+
v1.0 = signed attestation. Estimated total scope ~2 weeks per the
269+
external reviewer's v1 spec.
270+
271+
---
272+
273+
## Call to action
274+
275+
- **Repo.** [pulseengine/spar](https://github.com/pulseengine/spar).
276+
- **v0.10.0 design doc.**
277+
[`docs/designs/v0.10.0-trace-topology.md`](../designs/v0.10.0-trace-topology.md).
278+
- **Forge-trial contributors welcome.** The scaffold in
279+
`docs/research/forge-replication/` is ready to run. If you have
280+
cycles to drive 48 paired trials (24 × 2 arms) on a fresh agent,
281+
please file the results.csv + transcripts as a PR against
282+
`docs/research/forge-replication/RESULTS.md`.
283+
- **NC reviewer items.** Five of the post-v0.9.0 top-5 closed; the
284+
follow-up list (multi-grouping LUDB LP, full RTA→WCTT
285+
auto-propagation, `Interrupt_Overhead` per ISR firing) is logged
286+
in the CHANGELOG's "Deferred" sections.
287+
288+
Track the v0.10.x trace-topology rollout via the
289+
[milestone](https://github.com/pulseengine/spar/milestones) and the
290+
five-check reconciler engine landing in v0.11.0.

0 commit comments

Comments
 (0)