Problem Statement
Studio exposes Swift and Rust runtime choices and attempts a reference-runtime parity comparison after a run. However, the public automated test surface is not yet a broad parity corpus. Rust currently has a very small unit-test surface, while Swift has much broader simulator tests.
Proposed Solution
Add a checked-in parity corpus and script:
- fixture circuits for Gaussian, loss, thermal, measurement, feedback, QEC, and supported Fock/hybrid paths,
- expected tolerance windows per metric,
- Swift and Rust execution for every supported fixture,
- JSON diff output for mean photon number, final state summary, measurement count, QEC metrics, backend used, and provenance,
- CI job that runs the fast subset on every PR.
Acceptance Criteria
scripts/runtime-parity-suite.sh --runtime both exists and produces machine-readable output.
- Parity failures identify fixture, metric, expected tolerance, and actual delta.
- Unsupported runtime/backend combinations are explicit skips, not silent passes.
- Rust and Swift version metadata is included in the parity report.
- Studio can reuse the same parity comparison model.
Validation
cargo test -p schrosim-core
bash scripts/swift-test.sh
bash scripts/runtime-parity-suite.sh --runtime both
Evidence
core-swift/Sources/schrosim-studio/CLIService.swift
core-swift/Sources/schrosim-cli/main.swift
core-rust/schrosim-core/src/main.rs
docs/examples/
Problem Statement
Studio exposes Swift and Rust runtime choices and attempts a reference-runtime parity comparison after a run. However, the public automated test surface is not yet a broad parity corpus. Rust currently has a very small unit-test surface, while Swift has much broader simulator tests.
Proposed Solution
Add a checked-in parity corpus and script:
Acceptance Criteria
scripts/runtime-parity-suite.sh --runtime bothexists and produces machine-readable output.Validation
cargo test -p schrosim-core bash scripts/swift-test.sh bash scripts/runtime-parity-suite.sh --runtime bothEvidence
core-swift/Sources/schrosim-studio/CLIService.swiftcore-swift/Sources/schrosim-cli/main.swiftcore-rust/schrosim-core/src/main.rsdocs/examples/