Repository navigation
test(analysis): govern real YouTube known-stem benchmark #828
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
seonghobae
wants to merge
47
commits into
develop
Choose a base branch
from
feature/youtube-known-stem-e2e
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from 4 commits
Commits
Show all changes
47 commits
Select commit
Hold shift + click to select a range
6e937a3
test(analysis): add governed YouTube known-stem benchmark
seonghobae 1458f70
docs(quality): record exact-head live failure
seonghobae bab2bb9
docs(governance): canonicalize review evidence
seonghobae 92f0da6
docs(governance): define exact-head review evidence
seonghobae 3947f63
fix(security): verify benchmark runtime artifacts
seonghobae 59e5396
fix(separation): complete known-stem review hardening
seonghobae e1cb409
fix(security): restrict checkpoint deserialization
seonghobae e37b456
fix(policy): address exact-head review findings
seonghobae c4a30b5
fix(policy): enforce GFM security-note boundaries
seonghobae 189d722
docs: enforce known-stem design authority
seonghobae 7b64f0a
test(docs): make expected trace messages explicit
seonghobae 50f6ddc
test(youtube): require authorization evidence before live access
seonghobae 0f07408
docs(youtube): specify authorization preflight contract
seonghobae 1310cbb
fix(harness): use cross-platform Python launcher
seonghobae 93fdbe7
fix(harness): run Python checks portably
seonghobae 8e34c0e
fix(harness): use a cross-platform Python launcher
seonghobae c82d315
ci: retrigger exact-head review after stale blocker dismissal
seonghobae b91f219
fix(security): reject YouTube output path traversal
seonghobae da64185
test(security): cover YouTube output directory guard
seonghobae 5decba5
docs(changelog): record YouTube output directory guard
seonghobae 901e8e5
fix(youtube): bind downloads to an allowed output root
seonghobae dcbac8e
test(youtube): cover allowed output root containment
seonghobae 8b2deaa
test(analysis): cover YouTube output guard failures
seonghobae 7ba3c74
test(analysis): align YouTube CLI output-root contract
seonghobae 0ddb17d
chore(deps): defer shared security baseline to #783
seonghobae 8df6457
docs(changelog): defer shared npm remediation to #783
seonghobae b7fa59a
chore(ci): stage one-shot #828 baseline cleanup
seonghobae db4713f
chore(ci): satisfy checkout default-branch guard
seonghobae 5584ad7
test(supply-chain): defer shared npm floor to #783
github-actions[bot] 27b9fc0
chore(ci): reestablish exact-head verification
seonghobae 4695465
docs(analysis): lock rehearsal metric authority for the known-stem slice
seonghobae 24a420f
test(analysis): lock rehearsal metric admission policy
seonghobae 9331b40
test(analysis): require Acc1+Acc2 together and admit Chiu beat F-measure
seonghobae b76ce8d
merge(develop): inherit protected npm, PDF.js, and Undici baseline
seonghobae 92cf8e4
merge(develop): inherit first playable range without changing MIR policy
seonghobae d50a578
test(analysis): close htdemucs cache-descriptor coverage gap
seonghobae b2da2b4
test(analysis): isolate temporal CLI probe from stem separation
seonghobae 5b4dd43
style(analysis): restore test file final newline
seonghobae 0ba16b1
docs(analysis): trace macOS separation process boundary
seonghobae 3c23b12
test(analysis): require local-only UMX-HQ candidate contract
seonghobae b02ac12
test(analysis): add strict offline UMX-HQ reference evaluator
seonghobae 7c1acf8
fix(analysis): preserve failure truth and constrained reference trust
seonghobae 69a6d58
chore(analysis): align UMX reference formatting and source pin
seonghobae f8de90f
fix(analysis): contain malformed feature cache acquisition errors
seonghobae 2115ce8
test(analysis): preserve portable fixtures and cue rejection coverage
seonghobae 4f93f95
fix(analysis): validate CLI intake before private temporal work
seonghobae a00da6a
fix(analysis): stop reflecting unknown request keys and type-check re…
seonghobae File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| # BandScope Product Requirements Document | ||
|
|
||
| Status: Active authority | ||
| Last updated: 2026-08-09 | ||
|
|
||
| ## Product outcome | ||
|
|
||
| BandScope turns a legally accessible song into a local-first, editable rehearsal view: form, | ||
| role-specific harmony and range, groove and entry cues, separated stem previews, confidence, and | ||
| rehearsal priority. It serves band leaders and players who need actionable preparation without a | ||
| DAW or notation-grade transcription workflow. | ||
|
|
||
| The current conversation adds one essential proof obligation: BandScope must demonstrate that its | ||
| production YouTube intake and production separator improve a real, known source rather than merely | ||
| returning plausible-looking arrays or synthetic demo output. | ||
|
coderabbitai[bot] marked this conversation as resolved.
Outdated
|
||
|
|
||
| This is a bounded source-separation slice of GitHub issue #770, not completion of its broader | ||
| harmony, beat/tempo, structure, range, cue, confidence, public-corpus, private-corpus, manifest, | ||
| CPU/GPU, and report requirements. | ||
|
|
||
| ## Users and jobs | ||
|
|
||
| - A band leader imports an authorized public YouTube track and needs trustworthy separated material | ||
| for assigning and checking rehearsal parts. | ||
| - A player needs a local stem preview and an honest confidence/failure state, not a silent fallback | ||
| to the original mixture. | ||
| - A maintainer needs reproducible evidence that model, downloader, fixture, and quality thresholds | ||
| still work together after dependency, model, or platform changes. | ||
| - A release owner needs evidence that external-media rights, model provenance, security boundaries, | ||
| and failure recovery are controlled. | ||
|
|
||
| ## Product requirements | ||
|
|
||
| | ID | Requirement | Acceptance evidence | Status | | ||
| |---|---|---|---| | ||
| | PRD-KS-001 | Exercise the production YouTube download boundary with a real public mix whose creator-published source contains a known stem. | Live test calls `download_youtube_audio()` and validates the exact video ID. | `active_branch` | | ||
| | PRD-KS-002 | Exercise the real production source separator, not a mock, FFT profile, or generated-only mixture. | Live test calls `AudioStemSeparator.separate()` and receives canonical vocals/bass/drums/other arrays. | `active_branch` | | ||
| | PRD-KS-003 | Measure improvement against ground truth with an independently defined metric. | Zero-mean SI-SDR improvement is at least the provisional +0.5 dB sentinel over the downloaded mix; an authorized YouTube baseline is still required before release blocking. | `active_branch` | | ||
| | PRD-KS-004 | Verify semantic stem assignment. | Vocal SI-SDR exceeds the best incorrectly named stem by at least 3.0 dB. | `active_branch` | | ||
| | PRD-KS-005 | Detect fixture drift instead of blaming the model. | The downloaded mix is aligned to a separately pinned creator master with duration drift ≤ 1.0 s and correlation ≥ 0.90; that lag is composed once with the master-to-vocal lag before inference. | `active_branch` | | ||
| | PRD-KS-006 | Keep normal CI deterministic while preserving a real integration proof. | Metric, alignment, integrity, redirect, path, cleanup, and failure tests run offline; live access is explicit opt-in and fail-closed. | `active_branch` | | ||
| | PRD-KS-007 | Respect content and platform restrictions. | No cookies, account login, paywall, DRM, geo, or anti-bot bypass; operator records authorization before live use. | `active_branch` | | ||
| | PRD-KS-008 | Keep downloaded media ephemeral and private. | Test-owned directory is removed on success and failure; raw audio, full paths, URLs, tokens, and cookies are not logged or retained. | `active_branch` | | ||
| | PRD-KS-009 | Make release quality evidence reviewable. | Exact commit, model identity, fixture hashes, platform, command, outcome, and numeric scores are retained as a bounded CI/operator artifact. | `planned` | | ||
| | PRD-KS-010 | Fail safely when the live ecosystem is unavailable. | Download/model/integrity/drift failures are distinct, do not become passes, and do not block unrelated development work. | `active_branch` | | ||
|
|
||
| ## Scope and non-goals | ||
|
|
||
| The first fixture makes a quantitative claim only for the vocal stem of Brad Sucks' *Making Me | ||
| Nervous*. The reference is a dry, loop-oriented vocal stem, so a separately pinned finished master | ||
| establishes YouTube asset identity. It does not prove four-stem quality, all genres, all YouTube transcodes, perceptual quality, | ||
| or notation accuracy. The benchmark is a quality sentinel, not a general downloader, media archive, | ||
| model-training dataset, or legal opinion. | ||
|
|
||
| BandScope must not retain user media in hosted telemetry or introduce a relational benchmark | ||
| database merely to satisfy documentation conventions. Results remain ephemeral until a separate | ||
| audited evidence-retention requirement is accepted. | ||
|
|
||
| ## Failure experience | ||
|
|
||
| The user-facing product must explain whether import, model availability, decode, or separation | ||
| failed and offer local-file fallback without exposing raw provider errors or sensitive paths. The | ||
| benchmark itself must retain stable diagnostic codes and numeric scores; it must never silently skip | ||
| after explicit opt-in. | ||
|
|
||
| ## Release acceptance | ||
|
|
||
| The known-stem lane becomes blocking for a release only after all of the following exist: | ||
|
|
||
| 1. documented authorization for the chosen live access mode; | ||
| 2. full-hash pre-load verification of the exact model artifact; | ||
| 3. at least one recorded passing supported-platform run on the exact release candidate; | ||
| 4. thresholds calibrated on an authorized YouTube candidate and a drift/flake triage owner; | ||
| 5. ordinary CI, security, coverage, packaging, SBOM, review, and provenance gates pass. | ||
|
|
||
| Until then, the deterministic offline contract is required and live evidence is advisory but must | ||
| fail closed when deliberately invoked. | ||
|
|
||
| ## Ownership and rollout | ||
|
|
||
| The analysis-engine owner owns metrics, fixture integrity, alignment, separator integration, and | ||
| failure taxonomy. Release engineering owns model/tool inventory and retained evidence. Repository | ||
| governance owns rights/platform authorization and the decision to make live execution scheduled or | ||
| blocking. Rollout proceeds from local opt-in, to controlled release-candidate evidence, to a | ||
| blocking lane only through a superseding ADR. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| # BandScope Documentation Authority | ||
|
|
||
| ## Canonical set | ||
|
|
||
| BandScope decisions must be reconstructable from this repository without chat history. Use these | ||
| documents as the non-duplicative authority graph: | ||
|
|
||
| - Product intent and acceptance outcomes: `docs/PRD.md` | ||
| - Technical contracts and quality gates: `docs/TRD.md` | ||
| - System boundaries and ownership: `ARCHITECTURE.md` | ||
| - Architecture, UML, deployment, and logical artifact diagrams: | ||
| `docs/architecture/diagrams.md` | ||
| - Decision status and supersession: `docs/adr/README.md` | ||
| - Current documentation sufficiency and known gaps: `docs/documentation-coverage-matrix.md` | ||
| - Real-audio MIR accuracy definitions, claim boundaries, and Issue #770 roadmap: | ||
| `docs/doctoring/real-audio-accuracy-acceptance.md` | ||
| - Live known-stem operator procedure and evidence: | ||
| `docs/engineering/youtube-known-stem-validation.md` | ||
| - Security source: `docs/security/app-security.md` | ||
| - Release and rollback controls: `docs/release/release-policy.md` and | ||
| `docs/operations/deploy-runbook.md` | ||
|
|
||
| ## Status vocabulary | ||
|
|
||
| - `implemented_on_develop`: present on the protected default branch. | ||
| - `active_branch`: implemented on an unmerged branch; not shipped. | ||
| - `planned`: approved or proposed work without an implementation. | ||
| - `research_only`: evidence or experiment with no product commitment. | ||
| - `out_of_scope`: an explicit non-goal. | ||
|
|
||
| Documents must use these labels when current and future behavior could otherwise be confused. A PR | ||
| body, chat transcript, or old implementation plan is evidence, not a replacement for the canonical | ||
| set. | ||
|
|
||
| ## Change rule | ||
|
|
||
| Every material product, model, API, workflow, persistence, security, or release change must update | ||
| the affected canonical document or state why no documentation change is required. ADRs supersede | ||
| earlier decisions; they are not silently rewritten. `scripts/checks/verify_docs.py` enforces the | ||
| presence and cross-links of this authority graph. |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.