polyvoice 0.6.5__tar.gz
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.
- polyvoice-0.6.5/.cargo/config.toml +10 -0
- polyvoice-0.6.5/.coad/GOAL_CONTRACT.template +52 -0
- polyvoice-0.6.5/.coad/HANDOFF.template +52 -0
- polyvoice-0.6.5/.coad/INTEGRATION.template +39 -0
- polyvoice-0.6.5/.coad/LEDGER.md +46 -0
- polyvoice-0.6.5/.coad/PROOF.template +33 -0
- polyvoice-0.6.5/.coad/README.md +18 -0
- polyvoice-0.6.5/.coad/REVIEW.template +42 -0
- polyvoice-0.6.5/.coad/TASK_CONTRACT.template +48 -0
- polyvoice-0.6.5/.coad/WRITE_LEASE.template +74 -0
- polyvoice-0.6.5/.coad/completed/HANDOFF.record +57 -0
- polyvoice-0.6.5/.coad/completed/LEASE_DER.record +39 -0
- polyvoice-0.6.5/.coad/completed/MIGRATION_LEASE.record +36 -0
- polyvoice-0.6.5/.coad/completed/PROOF.record +42 -0
- polyvoice-0.6.5/.coad/completed/REVIEW.record +19 -0
- polyvoice-0.6.5/.coad/completed/TASK_DER_BENCH_UNIFICATION.record +78 -0
- polyvoice-0.6.5/.github/workflows/ci.yml +274 -0
- polyvoice-0.6.5/.github/workflows/fuzz.yml +26 -0
- polyvoice-0.6.5/.github/workflows/python.yml +35 -0
- polyvoice-0.6.5/.github/workflows/release.yml +106 -0
- polyvoice-0.6.5/.gitignore +63 -0
- polyvoice-0.6.5/AGENTS.md +162 -0
- polyvoice-0.6.5/AGENT_FLOW.md +83 -0
- polyvoice-0.6.5/CHANGELOG.md +520 -0
- polyvoice-0.6.5/COAD_PROJECT_STANDARD.md +142 -0
- polyvoice-0.6.5/CONTRIBUTING.md +60 -0
- polyvoice-0.6.5/Cargo.lock +3011 -0
- polyvoice-0.6.5/Cargo.toml +146 -0
- polyvoice-0.6.5/LICENSE +21 -0
- polyvoice-0.6.5/PKG-INFO +177 -0
- polyvoice-0.6.5/PRODUCTION-READINESS.md +177 -0
- polyvoice-0.6.5/README.md +161 -0
- polyvoice-0.6.5/VERSION +1 -0
- polyvoice-0.6.5/benches/der_ami.rs +57 -0
- polyvoice-0.6.5/benchmarks/README.md +104 -0
- polyvoice-0.6.5/benchmarks/results/ami-test-single-20260516.json +49 -0
- polyvoice-0.6.5/benchmarks/results/voxconverse-test-10files-20260516.json +175 -0
- polyvoice-0.6.5/benchmarks/results/voxconverse-test-3-20260516.json +34 -0
- polyvoice-0.6.5/benchmarks/results/voxconverse_kmeans_232files_2026-05-21.json +2092 -0
- polyvoice-0.6.5/docs/API.md +182 -0
- polyvoice-0.6.5/docs/FORMALISM.md +78 -0
- polyvoice-0.6.5/docs/GLOSSARY.md +29 -0
- polyvoice-0.6.5/docs/MIGRATING-FROM-0.5.md +116 -0
- polyvoice-0.6.5/docs/PIPELINE.md +47 -0
- polyvoice-0.6.5/docs/SEVERITY.md +39 -0
- polyvoice-0.6.5/docs/assets/demo.gif +0 -0
- polyvoice-0.6.5/docs/security/audit-2026-05-08.md +243 -0
- polyvoice-0.6.5/docs/strategy/2026-05-07-diarization-competitor-analysis.md +95 -0
- polyvoice-0.6.5/docs/strategy/2026-05-07-perfect-diarization-roadmap.md +343 -0
- polyvoice-0.6.5/docs/strategy/2026-05-07-perfect-diarization-spec.md +289 -0
- polyvoice-0.6.5/docs/strategy/dead-code-cleanup-plan.md +224 -0
- polyvoice-0.6.5/docs/strategy/m5-quantization-notes.md +133 -0
- polyvoice-0.6.5/docs/strategy/model-signing-plan.md +400 -0
- polyvoice-0.6.5/docs/strategy/python-wheel-validation.md +151 -0
- polyvoice-0.6.5/examples/ffi_usage.c +53 -0
- polyvoice-0.6.5/examples/hybrid_benchmark.rs +182 -0
- polyvoice-0.6.5/include/polyvoice.h +56 -0
- polyvoice-0.6.5/models/.gitkeep +0 -0
- polyvoice-0.6.5/models/cam_pp_fp32.onnx.minisig +4 -0
- polyvoice-0.6.5/models/ecapa_tdnn.onnx.minisig +4 -0
- polyvoice-0.6.5/models/ecapa_tdnn_mel.onnx.minisig +4 -0
- polyvoice-0.6.5/models/ecapa_tdnn_mel_v2.onnx.minisig +4 -0
- polyvoice-0.6.5/models/ecapa_tdnn_mel_v3.onnx.minisig +4 -0
- polyvoice-0.6.5/models/int8/.gitkeep +0 -0
- polyvoice-0.6.5/models/int8/cam_pp_int8.onnx.minisig +4 -0
- polyvoice-0.6.5/models/int8/powerset_int8.onnx.minisig +4 -0
- polyvoice-0.6.5/models/int8/resnet34_int8.onnx.minisig +4 -0
- polyvoice-0.6.5/models/powerset_fp32.onnx.minisig +4 -0
- polyvoice-0.6.5/models/signing.pub +2 -0
- polyvoice-0.6.5/models/silero_vad.onnx.minisig +4 -0
- polyvoice-0.6.5/models/wespeaker_resnet34.onnx.minisig +4 -0
- polyvoice-0.6.5/polyvoice/__init__.py +6 -0
- polyvoice-0.6.5/proptest-regressions/bin/polyvoice.txt +8 -0
- polyvoice-0.6.5/proptest-regressions/window/mod.txt +8 -0
- polyvoice-0.6.5/pyproject.toml +28 -0
- polyvoice-0.6.5/python/.gitignore +8 -0
- polyvoice-0.6.5/python/Cargo.lock +1455 -0
- polyvoice-0.6.5/python/Cargo.toml +14 -0
- polyvoice-0.6.5/python/README.md +161 -0
- polyvoice-0.6.5/python/requirements-dev.txt +17 -0
- polyvoice-0.6.5/python/src/lib.rs +100 -0
- polyvoice-0.6.5/python/tests/test_pipeline.py +106 -0
- polyvoice-0.6.5/python/tests/test_quantize_smoke.py +91 -0
- polyvoice-0.6.5/python/tests/test_smoke.py +15 -0
- polyvoice-0.6.5/python/tests/test_validate_smoke.py +51 -0
- polyvoice-0.6.5/scripts/download-ami-test-single.sh +48 -0
- polyvoice-0.6.5/scripts/download-ami-test.sh +94 -0
- polyvoice-0.6.5/scripts/download-models.sh +29 -0
- polyvoice-0.6.5/scripts/download-voxceleb1-subset.sh +67 -0
- polyvoice-0.6.5/scripts/download-voxconverse-dev.sh +69 -0
- polyvoice-0.6.5/scripts/download-voxconverse-test.sh +86 -0
- polyvoice-0.6.5/scripts/extract-voxconverse-hf.py +29 -0
- polyvoice-0.6.5/scripts/quantize-models.sh +96 -0
- polyvoice-0.6.5/scripts/quantize_models.py +217 -0
- polyvoice-0.6.5/scripts/release-check.sh +31 -0
- polyvoice-0.6.5/scripts/release-gate.sh +130 -0
- polyvoice-0.6.5/scripts/run-der-baseline.sh +19 -0
- polyvoice-0.6.5/scripts/sign-models.sh +133 -0
- polyvoice-0.6.5/scripts/validate-int8.sh +85 -0
- polyvoice-0.6.5/scripts/validate_int8.py +406 -0
- polyvoice-0.6.5/src/ahc/MODULE_CONTRACT.md +92 -0
- polyvoice-0.6.5/src/ahc/README.md +32 -0
- polyvoice-0.6.5/src/ahc/TODO.md +17 -0
- polyvoice-0.6.5/src/ahc/mod.rs +275 -0
- polyvoice-0.6.5/src/bin/MODULE_CONTRACT.md +109 -0
- polyvoice-0.6.5/src/bin/README.md +43 -0
- polyvoice-0.6.5/src/bin/TODO.md +16 -0
- polyvoice-0.6.5/src/bin/polyvoice-bench.rs +343 -0
- polyvoice-0.6.5/src/bin/polyvoice.rs +304 -0
- polyvoice-0.6.5/src/cluster/MODULE_CONTRACT.md +85 -0
- polyvoice-0.6.5/src/cluster/README.md +30 -0
- polyvoice-0.6.5/src/cluster/TODO.md +13 -0
- polyvoice-0.6.5/src/cluster/mod.rs +349 -0
- polyvoice-0.6.5/src/clusterer/MODULE_CONTRACT.md +109 -0
- polyvoice-0.6.5/src/clusterer/README.md +35 -0
- polyvoice-0.6.5/src/clusterer/TODO.md +14 -0
- polyvoice-0.6.5/src/clusterer/mod.rs +488 -0
- polyvoice-0.6.5/src/der/MODULE_CONTRACT.md +143 -0
- polyvoice-0.6.5/src/der/README.md +50 -0
- polyvoice-0.6.5/src/der/TODO.md +22 -0
- polyvoice-0.6.5/src/der/mod.rs +328 -0
- polyvoice-0.6.5/src/ecapa/MODULE_CONTRACT.md +95 -0
- polyvoice-0.6.5/src/ecapa/README.md +31 -0
- polyvoice-0.6.5/src/ecapa/TODO.md +15 -0
- polyvoice-0.6.5/src/ecapa/mod.rs +173 -0
- polyvoice-0.6.5/src/embedder/MODULE_CONTRACT.md +147 -0
- polyvoice-0.6.5/src/embedder/README.md +39 -0
- polyvoice-0.6.5/src/embedder/TODO.md +14 -0
- polyvoice-0.6.5/src/embedder/mod.rs +509 -0
- polyvoice-0.6.5/src/embedding/MODULE_CONTRACT.md +105 -0
- polyvoice-0.6.5/src/embedding/README.md +30 -0
- polyvoice-0.6.5/src/embedding/TODO.md +13 -0
- polyvoice-0.6.5/src/embedding/mod.rs +98 -0
- polyvoice-0.6.5/src/features/MODULE_CONTRACT.md +95 -0
- polyvoice-0.6.5/src/features/README.md +30 -0
- polyvoice-0.6.5/src/features/TODO.md +14 -0
- polyvoice-0.6.5/src/features/mod.rs +344 -0
- polyvoice-0.6.5/src/ffi/MODULE_CONTRACT.md +126 -0
- polyvoice-0.6.5/src/ffi/README.md +35 -0
- polyvoice-0.6.5/src/ffi/TODO.md +16 -0
- polyvoice-0.6.5/src/ffi/mod.rs +217 -0
- polyvoice-0.6.5/src/kmeans/MODULE_CONTRACT.md +100 -0
- polyvoice-0.6.5/src/kmeans/README.md +28 -0
- polyvoice-0.6.5/src/kmeans/TODO.md +13 -0
- polyvoice-0.6.5/src/kmeans/mod.rs +305 -0
- polyvoice-0.6.5/src/lib.rs +126 -0
- polyvoice-0.6.5/src/models/MODULE_CONTRACT.md +150 -0
- polyvoice-0.6.5/src/models/README.md +39 -0
- polyvoice-0.6.5/src/models/TODO.md +14 -0
- polyvoice-0.6.5/src/models/download.rs +335 -0
- polyvoice-0.6.5/src/models/manifest.rs +219 -0
- polyvoice-0.6.5/src/models/manifest.toml +111 -0
- polyvoice-0.6.5/src/models/mod.rs +365 -0
- polyvoice-0.6.5/src/models/signing.pub.base64 +1 -0
- polyvoice-0.6.5/src/models/verify.rs +196 -0
- polyvoice-0.6.5/src/onnx/MODULE_CONTRACT.md +105 -0
- polyvoice-0.6.5/src/onnx/README.md +31 -0
- polyvoice-0.6.5/src/onnx/TODO.md +11 -0
- polyvoice-0.6.5/src/onnx/mod.rs +298 -0
- polyvoice-0.6.5/src/overlap/MODULE_CONTRACT.md +89 -0
- polyvoice-0.6.5/src/overlap/README.md +28 -0
- polyvoice-0.6.5/src/overlap/TODO.md +11 -0
- polyvoice-0.6.5/src/overlap/mod.rs +185 -0
- polyvoice-0.6.5/src/pipeline/MODULE_CONTRACT.md +125 -0
- polyvoice-0.6.5/src/pipeline/README.md +33 -0
- polyvoice-0.6.5/src/pipeline/TODO.md +14 -0
- polyvoice-0.6.5/src/pipeline/mod.rs +197 -0
- polyvoice-0.6.5/src/pipeline_v2/builder.rs +338 -0
- polyvoice-0.6.5/src/pipeline_v2/config.rs +122 -0
- polyvoice-0.6.5/src/pipeline_v2/hybrid.rs +392 -0
- polyvoice-0.6.5/src/pipeline_v2/mocks.rs +102 -0
- polyvoice-0.6.5/src/pipeline_v2/mod.rs +335 -0
- polyvoice-0.6.5/src/resegmentation/MODULE_CONTRACT.md +111 -0
- polyvoice-0.6.5/src/resegmentation/README.md +33 -0
- polyvoice-0.6.5/src/resegmentation/TODO.md +13 -0
- polyvoice-0.6.5/src/resegmentation/mod.rs +752 -0
- polyvoice-0.6.5/src/rttm/MODULE_CONTRACT.md +138 -0
- polyvoice-0.6.5/src/rttm/README.md +32 -0
- polyvoice-0.6.5/src/rttm/TODO.md +11 -0
- polyvoice-0.6.5/src/rttm/mod.rs +257 -0
- polyvoice-0.6.5/src/segmentation/MODULE_CONTRACT.md +142 -0
- polyvoice-0.6.5/src/segmentation/README.md +36 -0
- polyvoice-0.6.5/src/segmentation/TODO.md +14 -0
- polyvoice-0.6.5/src/segmentation/aggregator.rs +642 -0
- polyvoice-0.6.5/src/segmentation/decoder.rs +253 -0
- polyvoice-0.6.5/src/segmentation/hungarian.rs +172 -0
- polyvoice-0.6.5/src/segmentation/mod.rs +170 -0
- polyvoice-0.6.5/src/segmentation/powerset.rs +212 -0
- polyvoice-0.6.5/src/silero_vad/MODULE_CONTRACT.md +92 -0
- polyvoice-0.6.5/src/silero_vad/README.md +29 -0
- polyvoice-0.6.5/src/silero_vad/TODO.md +11 -0
- polyvoice-0.6.5/src/silero_vad/mod.rs +144 -0
- polyvoice-0.6.5/src/spectral/MODULE_CONTRACT.md +81 -0
- polyvoice-0.6.5/src/spectral/README.md +29 -0
- polyvoice-0.6.5/src/spectral/TODO.md +11 -0
- polyvoice-0.6.5/src/spectral/mod.rs +312 -0
- polyvoice-0.6.5/src/streaming/MODULE_CONTRACT.md +102 -0
- polyvoice-0.6.5/src/streaming/README.md +34 -0
- polyvoice-0.6.5/src/streaming/TODO.md +13 -0
- polyvoice-0.6.5/src/streaming/mod.rs +355 -0
- polyvoice-0.6.5/src/types/MODULE_CONTRACT.md +154 -0
- polyvoice-0.6.5/src/types/README.md +36 -0
- polyvoice-0.6.5/src/types/TODO.md +14 -0
- polyvoice-0.6.5/src/types/mod.rs +526 -0
- polyvoice-0.6.5/src/utils/MODULE_CONTRACT.md +133 -0
- polyvoice-0.6.5/src/utils/README.md +29 -0
- polyvoice-0.6.5/src/utils/TODO.md +18 -0
- polyvoice-0.6.5/src/utils/mod.rs +215 -0
- polyvoice-0.6.5/src/vad/MODULE_CONTRACT.md +132 -0
- polyvoice-0.6.5/src/vad/README.md +33 -0
- polyvoice-0.6.5/src/vad/TODO.md +13 -0
- polyvoice-0.6.5/src/vad/mod.rs +288 -0
- polyvoice-0.6.5/src/wav/MODULE_CONTRACT.md +86 -0
- polyvoice-0.6.5/src/wav/README.md +28 -0
- polyvoice-0.6.5/src/wav/TODO.md +11 -0
- polyvoice-0.6.5/src/wav/mod.rs +106 -0
- polyvoice-0.6.5/src/window/MODULE_CONTRACT.md +86 -0
- polyvoice-0.6.5/src/window/README.md +29 -0
- polyvoice-0.6.5/src/window/TODO.md +11 -0
- polyvoice-0.6.5/src/window/mod.rs +324 -0
- polyvoice-0.6.5/tests/chaos_test.rs +284 -0
- polyvoice-0.6.5/tests/cli_smoke_test.rs +113 -0
- polyvoice-0.6.5/tests/clusterer_test.rs +59 -0
- polyvoice-0.6.5/tests/der_ami_baseline_test.rs +59 -0
- polyvoice-0.6.5/tests/der_baseline.json +123 -0
- polyvoice-0.6.5/tests/der_baseline_test.rs +87 -0
- polyvoice-0.6.5/tests/der_regression_test.rs +206 -0
- polyvoice-0.6.5/tests/der_v2_baseline_test.rs +143 -0
- polyvoice-0.6.5/tests/e2e_smoke_test.rs +124 -0
- polyvoice-0.6.5/tests/embedder_test.rs +64 -0
- polyvoice-0.6.5/tests/ffi_memory.py +153 -0
- polyvoice-0.6.5/tests/ffi_smoke_test.rs +33 -0
- polyvoice-0.6.5/tests/hybrid_diagnostics.rs +515 -0
- polyvoice-0.6.5/tests/hybrid_embedder_sweep.rs +116 -0
- polyvoice-0.6.5/tests/hybrid_voxconverse_full.rs +133 -0
- polyvoice-0.6.5/tests/hybrid_window_sweep.rs +93 -0
- polyvoice-0.6.5/tests/loom_pool.rs +147 -0
- polyvoice-0.6.5/tests/m5_manifest_smoke_test.rs +119 -0
- polyvoice-0.6.5/tests/miri_resegmentation.rs +99 -0
- polyvoice-0.6.5/tests/perf_regression_test.rs +171 -0
- polyvoice-0.6.5/tests/pipeline_v2_aorju.rs +88 -0
- polyvoice-0.6.5/tests/pipeline_v2_debug.rs +390 -0
- polyvoice-0.6.5/tests/pipeline_v2_hybrid_test.rs +485 -0
- polyvoice-0.6.5/tests/pipeline_v2_integration.rs +131 -0
- polyvoice-0.6.5/tests/pipeline_v2_longform_debug.rs +232 -0
- polyvoice-0.6.5/tests/pipeline_v2_vs_hybrid.rs +108 -0
- polyvoice-0.6.5/tests/property_ahc_test.proptest-regressions +7 -0
- polyvoice-0.6.5/tests/property_ahc_test.rs +75 -0
- polyvoice-0.6.5/tests/property_der_test.proptest-regressions +7 -0
- polyvoice-0.6.5/tests/property_der_test.rs +74 -0
- polyvoice-0.6.5/tests/property_kmeans_test.proptest-regressions +7 -0
- polyvoice-0.6.5/tests/property_kmeans_test.rs +45 -0
- polyvoice-0.6.5/tests/property_types_test.proptest-regressions +7 -0
- polyvoice-0.6.5/tests/property_types_test.rs +61 -0
- polyvoice-0.6.5/tests/property_utils_test.rs +67 -0
- polyvoice-0.6.5/tests/registry_test.rs +48 -0
- polyvoice-0.6.5/tests/resegmentation_test.rs +328 -0
- polyvoice-0.6.5/tests/segmenter_test.rs +73 -0
- polyvoice-0.6.5/tests/test_ahc.rs +66 -0
- polyvoice-0.6.5/tests/test_wav.rs +64 -0
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: goal_contract
|
|
4
|
+
goal_id:
|
|
5
|
+
objective:
|
|
6
|
+
status: proposed
|
|
7
|
+
risk: medium
|
|
8
|
+
goal_class: feature
|
|
9
|
+
delivery:
|
|
10
|
+
max_parallel_agents: 3
|
|
11
|
+
allow_external_side_effects: false
|
|
12
|
+
require_contract_updates: true
|
|
13
|
+
budget:
|
|
14
|
+
time:
|
|
15
|
+
tokens:
|
|
16
|
+
cost:
|
|
17
|
+
readiness_oracle:
|
|
18
|
+
type: test_suite
|
|
19
|
+
claim: All tests pass and coad check passes
|
|
20
|
+
required_proof:
|
|
21
|
+
- cargo test
|
|
22
|
+
- coad check .
|
|
23
|
+
decomposition:
|
|
24
|
+
strategy: module_owned
|
|
25
|
+
tasks:
|
|
26
|
+
- <task-id>
|
|
27
|
+
contracts:
|
|
28
|
+
modules:
|
|
29
|
+
- <module>
|
|
30
|
+
tasks:
|
|
31
|
+
- <task-contract-path>
|
|
32
|
+
proofs:
|
|
33
|
+
- <proof-contract-path>
|
|
34
|
+
reviews:
|
|
35
|
+
- <review-contract-path>
|
|
36
|
+
integration:
|
|
37
|
+
- <integration-contract-path>
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
# Goal: <goal-id>
|
|
41
|
+
|
|
42
|
+
## Intent
|
|
43
|
+
|
|
44
|
+
Explain the user-visible outcome and constraints.
|
|
45
|
+
|
|
46
|
+
## Readiness Oracle
|
|
47
|
+
|
|
48
|
+
Explain what proves the goal is ready.
|
|
49
|
+
|
|
50
|
+
## Decomposition Notes
|
|
51
|
+
|
|
52
|
+
Explain why the task split is safe for orchestration.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: handoff_contract
|
|
4
|
+
task_id:
|
|
5
|
+
status: complete
|
|
6
|
+
changed_files: []
|
|
7
|
+
proof_results: []
|
|
8
|
+
contract_updates: []
|
|
9
|
+
decisions: []
|
|
10
|
+
known_gaps: []
|
|
11
|
+
follow_up_tasks: []
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# Handoff: <task-id>
|
|
15
|
+
|
|
16
|
+
## Summary
|
|
17
|
+
|
|
18
|
+
Briefly state what changed and why.
|
|
19
|
+
|
|
20
|
+
## Evidence
|
|
21
|
+
|
|
22
|
+
List proof results and artifact paths.
|
|
23
|
+
|
|
24
|
+
## Next Work
|
|
25
|
+
|
|
26
|
+
List follow-up task contracts or state `none`.
|
|
27
|
+
|
|
28
|
+
## Template
|
|
29
|
+
|
|
30
|
+
```markdown
|
|
31
|
+
Module: src/<module>
|
|
32
|
+
Workcell: leaf
|
|
33
|
+
Write scope:
|
|
34
|
+
- src/<module>/mod.rs
|
|
35
|
+
- src/<module>/TODO.md
|
|
36
|
+
nChanged files:
|
|
37
|
+
- src/<module>/mod.rs
|
|
38
|
+
Contracts/context updated:
|
|
39
|
+
- src/<module>/TODO.md (marked task done)
|
|
40
|
+
Surfaces changed:
|
|
41
|
+
- <none | name of changed surface>
|
|
42
|
+
Consumers affected:
|
|
43
|
+
- <none | list affected consumers>
|
|
44
|
+
Invariants checked:
|
|
45
|
+
- <invariant-id>: <result>
|
|
46
|
+
Proof run:
|
|
47
|
+
- <command>: <result>
|
|
48
|
+
Known gaps:
|
|
49
|
+
- <none | list gaps>
|
|
50
|
+
Recommended next step:
|
|
51
|
+
- <action>
|
|
52
|
+
```
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: integration_contract
|
|
4
|
+
integration_id:
|
|
5
|
+
baseline: main
|
|
6
|
+
policy:
|
|
7
|
+
require_clean_history: true
|
|
8
|
+
require_signed_commits: false
|
|
9
|
+
tasks: []
|
|
10
|
+
merge_order: []
|
|
11
|
+
required_before_integration:
|
|
12
|
+
- all task proof contracts pass
|
|
13
|
+
- all blocking review findings resolved
|
|
14
|
+
- no write-scope conflicts remain
|
|
15
|
+
final_verification:
|
|
16
|
+
- cargo test
|
|
17
|
+
- cargo clippy --all-targets --all-features -- -D warnings
|
|
18
|
+
- coad check .
|
|
19
|
+
release_evidence:
|
|
20
|
+
required:
|
|
21
|
+
- final_diff
|
|
22
|
+
- final_test_output
|
|
23
|
+
- contract_drift_report
|
|
24
|
+
terminal_statuses:
|
|
25
|
+
- ready
|
|
26
|
+
- not_ready
|
|
27
|
+
- blocked
|
|
28
|
+
- failed
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
# Integration: <integration-id>
|
|
32
|
+
|
|
33
|
+
## Plan
|
|
34
|
+
|
|
35
|
+
Describe integration order, conflict handling, and final proof.
|
|
36
|
+
|
|
37
|
+
## Terminal Status
|
|
38
|
+
|
|
39
|
+
State final readiness and evidence.
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# COAD Execution Ledger — polyvoice
|
|
2
|
+
|
|
3
|
+
> Level 4 artifact: completed agent work is recorded here with proof evidence.
|
|
4
|
+
|
|
5
|
+
## Ledger Format
|
|
6
|
+
|
|
7
|
+
```markdown
|
|
8
|
+
| Date | Task ID | Owner | Module(s) | Change Class | Proof | Status |
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Entries
|
|
12
|
+
|
|
13
|
+
| Date | Task ID | Owner | Module(s) | Change Class | Proof | Status |
|
|
14
|
+
|------|---------|-------|-----------|--------------|-------|--------|
|
|
15
|
+
| 2026-05-16 | der-bench-unification-001 | agent-alpha | src/der, benches/der_ami | internal_refactor | bench-compiles, bench-runs | completed |
|
|
16
|
+
|
|
17
|
+
### 2026-05-16 — der-bench-unification-001
|
|
18
|
+
|
|
19
|
+
**Objective**: Remove duplicate DER implementation from `benches/der_ami.rs` and
|
|
20
|
+
replace with `polyvoice::der::compute_der_from_rttm`.
|
|
21
|
+
|
|
22
|
+
**Changed files**:
|
|
23
|
+
- `benches/der_ami.rs`
|
|
24
|
+
- `src/der/TODO.md`
|
|
25
|
+
|
|
26
|
+
**Proof artifacts**:
|
|
27
|
+
- `cargo check --bench der_ami` — compiles
|
|
28
|
+
- `cargo bench --bench der_ami -- --sample-size 10` — assertions pass
|
|
29
|
+
- perfect hypothesis DER = 0.0%
|
|
30
|
+
- confused hypothesis DER = 27.8%
|
|
31
|
+
|
|
32
|
+
**Contract updates**:
|
|
33
|
+
- `src/der/TODO.md` — item moved from Known Gaps to done
|
|
34
|
+
|
|
35
|
+
**Handoff**: `.coad/completed/HANDOFF.record`
|
|
36
|
+
**Review**: `.coad/completed/REVIEW.record`
|
|
37
|
+
**Proof**: `.coad/completed/PROOF.record`
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
|
|
41
|
+
## Ledger Rules
|
|
42
|
+
|
|
43
|
+
1. Every completed Level 3 task is appended to this ledger.
|
|
44
|
+
2. Proof artifacts must be reproducible (commands, not chat claims).
|
|
45
|
+
3. If a task is reverted, add a reversal entry with reference to original.
|
|
46
|
+
4. The ledger is append-only; do not delete historical entries.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: proof_contract
|
|
4
|
+
proof_id:
|
|
5
|
+
claim: <claim being proven>
|
|
6
|
+
required:
|
|
7
|
+
- kind: unit-test
|
|
8
|
+
target:
|
|
9
|
+
command:
|
|
10
|
+
blocks_readiness: true
|
|
11
|
+
accepted_missing: []
|
|
12
|
+
artifacts: []
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# Proof: <proof-id>
|
|
16
|
+
|
|
17
|
+
## Claim
|
|
18
|
+
|
|
19
|
+
State the exact claim this proof accepts or rejects.
|
|
20
|
+
|
|
21
|
+
## Evidence
|
|
22
|
+
|
|
23
|
+
List command outputs, artifact paths, review reports, or manual verification records.
|
|
24
|
+
|
|
25
|
+
## Example
|
|
26
|
+
|
|
27
|
+
```
|
|
28
|
+
Claim: DER of identical ref/hyp is exactly 0.
|
|
29
|
+
Evidence:
|
|
30
|
+
- cargo test --test property_der_test::der_identical_ref_hyp_is_zero
|
|
31
|
+
test der_identical_ref_hyp_is_zero ... ok
|
|
32
|
+
- 1000 proptest cases passed
|
|
33
|
+
```
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# .coad/
|
|
2
|
+
|
|
3
|
+
COAD orchestration contracts and templates for polyvoice.
|
|
4
|
+
|
|
5
|
+
This directory contains reusable templates for coordinated agent work:
|
|
6
|
+
- **TASK_CONTRACT.md** — scoped work assignment for a leaf workcell
|
|
7
|
+
- **PROOF.md** — evidence that a claim holds
|
|
8
|
+
- **HANDOFF.md** — transfer of completed work between agents
|
|
9
|
+
- **REVIEW.md** — structured review of a task
|
|
10
|
+
- **INTEGRATION.md** — multi-task integration plan
|
|
11
|
+
- **GOAL_CONTRACT.md** — top-level goal decomposition
|
|
12
|
+
- **WRITE_LEASE.md** — temporary write authority for a workcell
|
|
13
|
+
|
|
14
|
+
Usage: copy the relevant template, fill in the fields, and place it in the
|
|
15
|
+
workcell directory or in `.coad/active/` during coordinated work.
|
|
16
|
+
|
|
17
|
+
See `COAD_PROJECT_STANDARD.md` for adoption levels and `AGENT_FLOW.md` for
|
|
18
|
+
the agent protocol.
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: review_contract
|
|
4
|
+
review_id:
|
|
5
|
+
target_task:
|
|
6
|
+
required_reviewers:
|
|
7
|
+
- role: composite_orchestrator
|
|
8
|
+
scope: module boundary + cross-module impact
|
|
9
|
+
findings:
|
|
10
|
+
severity_levels:
|
|
11
|
+
- blocker
|
|
12
|
+
- high
|
|
13
|
+
- medium
|
|
14
|
+
- low
|
|
15
|
+
acceptance:
|
|
16
|
+
blocks_on:
|
|
17
|
+
- blocker
|
|
18
|
+
- high
|
|
19
|
+
requires_no_unresolved_questions: true
|
|
20
|
+
outputs:
|
|
21
|
+
- review_report
|
|
22
|
+
- follow_up_task_contracts
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Review: <review-id>
|
|
26
|
+
|
|
27
|
+
## Checklist
|
|
28
|
+
|
|
29
|
+
1. Does the change stay inside declared module ownership?
|
|
30
|
+
2. Did it alter public or internal surfaces?
|
|
31
|
+
3. Are consumers updated or explicitly unaffected?
|
|
32
|
+
4. Are invariants preserved?
|
|
33
|
+
5. Is proof strong enough for the change class?
|
|
34
|
+
6. Did module context change when the module changed?
|
|
35
|
+
|
|
36
|
+
## Findings
|
|
37
|
+
|
|
38
|
+
List findings first, ordered by severity.
|
|
39
|
+
|
|
40
|
+
## Outcome
|
|
41
|
+
|
|
42
|
+
State `pass`, `blocked`, or `pass_with_known_gaps`.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: task_contract
|
|
4
|
+
task_id:
|
|
5
|
+
objective:
|
|
6
|
+
owner_role: leaf_write_agent
|
|
7
|
+
status: pending
|
|
8
|
+
risk: low
|
|
9
|
+
change_class: internal_refactor
|
|
10
|
+
modules:
|
|
11
|
+
- <affected module>
|
|
12
|
+
read_scope:
|
|
13
|
+
- <files to read>
|
|
14
|
+
write_scope:
|
|
15
|
+
- <files to edit>
|
|
16
|
+
dependencies: []
|
|
17
|
+
allowed_mutations:
|
|
18
|
+
- <safe changes>
|
|
19
|
+
forbidden_mutations:
|
|
20
|
+
- <changes that require escalation>
|
|
21
|
+
acceptance:
|
|
22
|
+
- <criteria for done>
|
|
23
|
+
proof:
|
|
24
|
+
required:
|
|
25
|
+
- proof_id:
|
|
26
|
+
kind: unit-test
|
|
27
|
+
target:
|
|
28
|
+
command:
|
|
29
|
+
handoff:
|
|
30
|
+
required_fields:
|
|
31
|
+
- changed_files
|
|
32
|
+
- proof_results
|
|
33
|
+
- contract_updates
|
|
34
|
+
- known_gaps
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
# Task: <task-id>
|
|
38
|
+
|
|
39
|
+
## Context
|
|
40
|
+
|
|
41
|
+
Explain only what the worker needs to execute this task safely.
|
|
42
|
+
Reference the relevant `MODULE_CONTRACT.md`, `README.md`, and `TODO.md`.
|
|
43
|
+
|
|
44
|
+
## Exit Criteria
|
|
45
|
+
|
|
46
|
+
- **complete**: All acceptance criteria met, proof commands pass, contracts updated.
|
|
47
|
+
- **blocked**: External dependency or unclear ownership — escalate to orchestrator.
|
|
48
|
+
- **not_ready**: Preconditions not satisfied — do not start work.
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: write_lease
|
|
4
|
+
lease_id:
|
|
5
|
+
workcell:
|
|
6
|
+
module:
|
|
7
|
+
type: leaf
|
|
8
|
+
owner:
|
|
9
|
+
agent_id:
|
|
10
|
+
role: leaf_write_agent
|
|
11
|
+
task:
|
|
12
|
+
objective:
|
|
13
|
+
affected_surfaces: []
|
|
14
|
+
invariants_touched: []
|
|
15
|
+
read_scope:
|
|
16
|
+
- <list files/modules agent may read for context>
|
|
17
|
+
write_scope:
|
|
18
|
+
- <list files agent may mutate>
|
|
19
|
+
expiry:
|
|
20
|
+
condition: <completion | timeout | human_cancellation>
|
|
21
|
+
deadline: <ISO 8601 or relative>
|
|
22
|
+
proof_required:
|
|
23
|
+
- <command or check that must pass before handoff>
|
|
24
|
+
parent_orchestrator:
|
|
25
|
+
agent_id:
|
|
26
|
+
escalation_path: <how to escalate conflicts>
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# Write Lease
|
|
30
|
+
|
|
31
|
+
## Rules
|
|
32
|
+
|
|
33
|
+
1. One leaf workcell → one active write lease at a time.
|
|
34
|
+
2. The owner may only mutate files in `write_scope`.
|
|
35
|
+
3. The owner must preserve all invariants listed in the workcell contract.
|
|
36
|
+
4. Before expiry, the owner must run all `proof_required` commands.
|
|
37
|
+
5. Read-only agents may work in parallel without a lease.
|
|
38
|
+
6. Cross-workcell changes require a migration lease from the parent orchestrator.
|
|
39
|
+
|
|
40
|
+
## Example
|
|
41
|
+
|
|
42
|
+
```yaml
|
|
43
|
+
lease_id: fix-der-collar-001
|
|
44
|
+
workcell:
|
|
45
|
+
module: src/der
|
|
46
|
+
type: leaf
|
|
47
|
+
owner:
|
|
48
|
+
agent_id: agent-alpha
|
|
49
|
+
role: leaf_write_agent
|
|
50
|
+
task:
|
|
51
|
+
objective: Fix collar boundary handling for 0.0s edge case
|
|
52
|
+
affected_surfaces:
|
|
53
|
+
- build_collar_mask
|
|
54
|
+
invariants_touched:
|
|
55
|
+
- collar-reduces-der
|
|
56
|
+
read_scope:
|
|
57
|
+
- src/der/mod.rs
|
|
58
|
+
- src/der/MODULE_CONTRACT.md
|
|
59
|
+
- src/der/README.md
|
|
60
|
+
- src/der/TODO.md
|
|
61
|
+
- tests/der_baseline_test.rs
|
|
62
|
+
write_scope:
|
|
63
|
+
- src/der/mod.rs
|
|
64
|
+
- src/der/TODO.md
|
|
65
|
+
expiry:
|
|
66
|
+
condition: completion
|
|
67
|
+
deadline: "2026-05-17T12:00:00Z"
|
|
68
|
+
proof_required:
|
|
69
|
+
- cargo test --lib der
|
|
70
|
+
- cargo test --test property_der_test
|
|
71
|
+
parent_orchestrator:
|
|
72
|
+
agent_id: agent-lead
|
|
73
|
+
escalation_path: "Ping in #polyvoice-dev or open migration lease"
|
|
74
|
+
```
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Handoff: der-bench-unification-001
|
|
2
|
+
|
|
3
|
+
## Summary
|
|
4
|
+
|
|
5
|
+
Removed duplicate DER implementation from `benches/der_ami.rs` and replaced it
|
|
6
|
+
with `polyvoice::der::compute_der_from_rttm`. Added a helper `to_speaker_turns`
|
|
7
|
+
to map bench hypothesis tuples to `SpeakerTurn`s.
|
|
8
|
+
|
|
9
|
+
## Evidence
|
|
10
|
+
|
|
11
|
+
- `cargo check --bench der_ami` — compiles cleanly.
|
|
12
|
+
- `cargo bench --bench der_ami -- --sample-size 10` — assertions pass:
|
|
13
|
+
- perfect hypothesis DER = 0.0% (< 5%)
|
|
14
|
+
- confused hypothesis DER = 27.8% (> 10%)
|
|
15
|
+
- benchmark throughput: ~48 µs/iteration
|
|
16
|
+
|
|
17
|
+
## Changed Files
|
|
18
|
+
|
|
19
|
+
- `benches/der_ami.rs` — removed local `compute_der`, added `to_speaker_turns`,
|
|
20
|
+
uses `polyvoice::der::compute_der_from_rttm`
|
|
21
|
+
- `src/der/TODO.md` — marked bench unification as done
|
|
22
|
+
|
|
23
|
+
## Contracts/Context Updated
|
|
24
|
+
|
|
25
|
+
- `src/der/TODO.md` — moved item from Known Gaps to Current (done)
|
|
26
|
+
|
|
27
|
+
## Surfaces Changed
|
|
28
|
+
|
|
29
|
+
- `benches/der_ami.rs` internal surface only (no public API changes)
|
|
30
|
+
|
|
31
|
+
## Consumers Affected
|
|
32
|
+
|
|
33
|
+
- None (bench is a build target, not a library consumer)
|
|
34
|
+
|
|
35
|
+
## Invariants Checked
|
|
36
|
+
|
|
37
|
+
- `der-range`: DER results remain in [0, 1]
|
|
38
|
+
- `identical-zero`: perfect hypothesis → DER ≈ 0
|
|
39
|
+
- `collar-reduces-der`: bench still exercises collar logic via `compute_der_from_rttm`
|
|
40
|
+
|
|
41
|
+
## Proof Run
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
cargo check --bench der_ami # OK
|
|
45
|
+
cargo bench --bench der_ami -- --sample-size 10 # OK
|
|
46
|
+
coad check . # OK
|
|
47
|
+
cargo test --lib # 62 passed
|
|
48
|
+
cargo clippy --all-targets --all-features -- -D warnings # OK
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Known Gaps
|
|
52
|
+
|
|
53
|
+
- None for this task.
|
|
54
|
+
|
|
55
|
+
## Recommended Next Step
|
|
56
|
+
|
|
57
|
+
Archive this handoff record to `.coad/completed/` after review.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: write_lease
|
|
4
|
+
lease_id: lease-der-bench-001
|
|
5
|
+
workcell:
|
|
6
|
+
module: src/der
|
|
7
|
+
type: leaf
|
|
8
|
+
owner:
|
|
9
|
+
agent_id: agent-alpha
|
|
10
|
+
role: leaf_write_agent
|
|
11
|
+
task:
|
|
12
|
+
objective: Update src/der TODO to reflect bench unification work
|
|
13
|
+
affected_surfaces:
|
|
14
|
+
- src/der/TODO.md
|
|
15
|
+
invariants_touched: []
|
|
16
|
+
read_scope:
|
|
17
|
+
- src/der/mod.rs
|
|
18
|
+
- src/der/MODULE_CONTRACT.md
|
|
19
|
+
- src/der/README.md
|
|
20
|
+
- src/der/TODO.md
|
|
21
|
+
write_scope:
|
|
22
|
+
- src/der/TODO.md
|
|
23
|
+
expiry:
|
|
24
|
+
condition: completion
|
|
25
|
+
deadline: "2026-05-16T22:00:00Z"
|
|
26
|
+
proof_required:
|
|
27
|
+
- coad check .
|
|
28
|
+
parent_orchestrator:
|
|
29
|
+
agent_id: agent-lead
|
|
30
|
+
escalation_path: "Ping in #polyvoice-dev or open migration lease"
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
# Write Lease: src/der
|
|
34
|
+
|
|
35
|
+
## Rules
|
|
36
|
+
|
|
37
|
+
1. Only mutate `src/der/TODO.md`.
|
|
38
|
+
2. Do not change `src/der/mod.rs` or any public surfaces.
|
|
39
|
+
3. Run `coad check .` before handoff.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: migration_lease
|
|
4
|
+
migration_id: mig-der-bench-001
|
|
5
|
+
objective: >
|
|
6
|
+
Cross-workcell change: benches/der_ami.rs uses src/der public surface.
|
|
7
|
+
Requires temporary write access to bench file while respecting src/der
|
|
8
|
+
invariants.
|
|
9
|
+
affected_workcells:
|
|
10
|
+
- module: src/der
|
|
11
|
+
reason: Consumer proof verification (bench still passes).
|
|
12
|
+
- module: benches/der_ami
|
|
13
|
+
reason: Implementation file being refactored.
|
|
14
|
+
temporary_write_scope:
|
|
15
|
+
- benches/der_ami.rs
|
|
16
|
+
paused_child_work:
|
|
17
|
+
- none
|
|
18
|
+
proof_required:
|
|
19
|
+
- cargo check --bench der_ami
|
|
20
|
+
- cargo bench --bench der_ami
|
|
21
|
+
integration_owner: agent-lead
|
|
22
|
+
approved_by: agent-lead
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Migration Lease: DER bench unification
|
|
26
|
+
|
|
27
|
+
## Justification
|
|
28
|
+
|
|
29
|
+
Ordinary leaf-local work is insufficient because the change replaces a
|
|
30
|
+
private bench implementation with a public cross-module surface call.
|
|
31
|
+
The bench file is not a leaf workcell but is a consumer of src/der.
|
|
32
|
+
|
|
33
|
+
## Rollback Plan
|
|
34
|
+
|
|
35
|
+
If bench assertions fail after the change, revert to original
|
|
36
|
+
benches/der_ami.rs and escalate to src/der owner for behavior review.
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# Proof: der-bench-unification-001
|
|
2
|
+
|
|
3
|
+
## Claim
|
|
4
|
+
|
|
5
|
+
`benches/der_ami.rs` no longer contains a duplicate DER implementation and
|
|
6
|
+
successfully uses `polyvoice::der::compute_der_from_rttm` while preserving
|
|
7
|
+
all bench assertions.
|
|
8
|
+
|
|
9
|
+
## Evidence
|
|
10
|
+
|
|
11
|
+
### Static Check: Compilation
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
$ cargo check --bench der_ami
|
|
15
|
+
Finished `dev` profile [unoptimized + debuginfo] target(s) in 4.21s
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
### Benchmark: Assertions Pass
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
$ cargo bench --bench der_ami -- --sample-size 10
|
|
22
|
+
Synthetic DER (perfect): 0.0%
|
|
23
|
+
Synthetic DER (confused): 27.8%
|
|
24
|
+
der_synthetic time: [47.741 µs 47.981 µs 48.157 µs]
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### Repository Validation
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
$ coad check .
|
|
31
|
+
coad check: pass
|
|
32
|
+
|
|
33
|
+
$ cargo test --lib
|
|
34
|
+
test result: ok. 62 passed; 0 failed; 0 ignored
|
|
35
|
+
|
|
36
|
+
$ cargo clippy --all-targets --all-features -- -D warnings
|
|
37
|
+
Finished `dev` profile [unoptimized + debuginfo] target(s)
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Verdict
|
|
41
|
+
|
|
42
|
+
Claim **accepted**. Bench unification is complete and verified.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Review: der-bench-unification-001
|
|
2
|
+
|
|
3
|
+
## Checklist
|
|
4
|
+
|
|
5
|
+
1. ✅ Change stays inside declared scope (benches/der_ami.rs + src/der/TODO.md)
|
|
6
|
+
2. ✅ No public surfaces altered
|
|
7
|
+
3. ✅ Consumers unaffected (bench is not a library consumer)
|
|
8
|
+
4. ✅ Invariants preserved (DER semantics unchanged)
|
|
9
|
+
5. ✅ Proof strong enough (compiles + bench assertions pass)
|
|
10
|
+
6. ✅ Module context updated (TODO.md marked done)
|
|
11
|
+
|
|
12
|
+
## Findings
|
|
13
|
+
|
|
14
|
+
- **low**: Consider adding a dedicated `criterion` bench for `compute_der` in
|
|
15
|
+
isolation (micro-benchmark on synthetic data) as noted in `src/der/TODO.md`.
|
|
16
|
+
|
|
17
|
+
## Outcome
|
|
18
|
+
|
|
19
|
+
**pass**
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
kind: task_contract
|
|
4
|
+
task_id: der-bench-unification-001
|
|
5
|
+
objective: >
|
|
6
|
+
Remove duplicate DER implementation from benches/der_ami.rs and replace it
|
|
7
|
+
with polyvoice::der::compute_der_from_rttm. Eliminates maintenance risk
|
|
8
|
+
from divergent DER logic.
|
|
9
|
+
owner_role: leaf_write_agent
|
|
10
|
+
status: in_progress
|
|
11
|
+
risk: low
|
|
12
|
+
change_class: internal_refactor
|
|
13
|
+
modules:
|
|
14
|
+
- src/der
|
|
15
|
+
- benches/der_ami
|
|
16
|
+
read_scope:
|
|
17
|
+
- src/der/mod.rs
|
|
18
|
+
- src/der/MODULE_CONTRACT.md
|
|
19
|
+
- src/der/TODO.md
|
|
20
|
+
- src/der/README.md
|
|
21
|
+
- benches/der_ami.rs
|
|
22
|
+
- src/types/mod.rs
|
|
23
|
+
write_scope:
|
|
24
|
+
- benches/der_ami.rs
|
|
25
|
+
- src/der/TODO.md
|
|
26
|
+
dependencies:
|
|
27
|
+
- src/types (SpeakerTurn, SpeakerId, TimeRange data shapes)
|
|
28
|
+
- src/der (compute_der_from_rttm public surface)
|
|
29
|
+
allowed_mutations:
|
|
30
|
+
- Replace local compute_der in bench with crate call.
|
|
31
|
+
- Add use statements for polyvoice types in bench.
|
|
32
|
+
- Update src/der/TODO.md to mark task done.
|
|
33
|
+
forbidden_mutations:
|
|
34
|
+
- Changing compute_der_from_rttm signature or behavior.
|
|
35
|
+
- Changing bench assertions or thresholds.
|
|
36
|
+
- Modifying src/der/mod.rs implementation.
|
|
37
|
+
acceptance:
|
|
38
|
+
- benches/der_ami.rs no longer contains a local compute_der function.
|
|
39
|
+
- bench still compiles: cargo bench --bench der_ami compiles.
|
|
40
|
+
- bench assertions still pass on synthetic data.
|
|
41
|
+
- coad check . passes.
|
|
42
|
+
proof:
|
|
43
|
+
required:
|
|
44
|
+
- proof_id: bench-compiles
|
|
45
|
+
kind: static-check
|
|
46
|
+
target: benches/der_ami.rs
|
|
47
|
+
command: cargo check --bench der_ami
|
|
48
|
+
- proof_id: bench-runs
|
|
49
|
+
kind: benchmark
|
|
50
|
+
target: benches/der_ami.rs
|
|
51
|
+
command: cargo bench --bench der_ami
|
|
52
|
+
handoff:
|
|
53
|
+
required_fields:
|
|
54
|
+
- changed_files
|
|
55
|
+
- proof_results
|
|
56
|
+
- contract_updates
|
|
57
|
+
- known_gaps
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
# Task: Unify DER computation in benchmark
|
|
61
|
+
|
|
62
|
+
## Context
|
|
63
|
+
|
|
64
|
+
`benches/der_ami.rs` maintains its own simplified 100ms-resolution DER impl.
|
|
65
|
+
This diverges from `src/der/mod.rs` and is a maintenance risk (tracked in
|
|
66
|
+
`src/der/TODO.md` Known Gaps and `docs/strategy/dead-code-cleanup-plan.md`).
|
|
67
|
+
|
|
68
|
+
`src/der::compute_der_from_rttm` accepts `&[(f64, f64, &str)]` for reference
|
|
69
|
+
and `&[SpeakerTurn]` for hypothesis — compatible with bench data after a
|
|
70
|
+
lightweight mapping of hypothesis tuples to SpeakerTurns.
|
|
71
|
+
|
|
72
|
+
## Exit Criteria
|
|
73
|
+
|
|
74
|
+
- **complete**: Local compute_der removed, bench uses crate function,
|
|
75
|
+
assertions pass, TODO updated.
|
|
76
|
+
- **blocked**: If compute_der_from_rttm behavior differs enough to break
|
|
77
|
+
bench assertions — escalate to src/der owner for invariant review.
|
|
78
|
+
- **not_ready**: If src/der contract or tests are failing — do not start.
|