#183·YuE

SheetSage2's rhythm grid cannot encode an in-beat tuplet (triplet / swing); YuE2 also fails to preserve tested tuplet conditioning

Author: Now-HowCreated Sep 15, 2026Updated Sep 15, 2026

issue-tuplet-demo.zip

Summary

SheetSage2 quantises melody onsets to a sub-beat division of 4 (notation_sheetsage2.py: SUBBEAT_DIVISION = 4; _build_grid uses np.linspace(start, end, SUBBEAT_DIVISION + 1)[:-1]). Three-in-the-space-of-two therefore has no representable position: an in-beat triplet's ⅓ and ⅔ are snapped to the nearest quarter of the beat. This affects swing, shuffle, blues, most jazz/gospel eighth-note feel, and hip-hop triplet flows. It is not a compound-meter bug (6/8, 9/8, 12/8 are supported and detected) — the gap is the tuplet inside a beat.

Evidence 1 — transcriber (deterministic, verifiable without our audio)

Three synthetic stimuli with the same tempo (100 BPM), key (A minor), pitch sequence, and bass grid; the swung version places and accents the off-beat according to a 2:1 swing (off-beat at exactly ⅔ of the beat, a true triplet position — it also carries the amplitude/duration a swung note naturally has). Reading the model's own melody_full.lab decode (not our tooling):

stimulus detected meter onset placement
straight eighths 4/4 (2/4 on some seeds) subbeats 0 and 2 — exact
swung (offbeat at ⅔) 4/4 offbeat placed at exactly ¾ (subbeat 3) — identical across 3 reruns of the same input
6/8 (compound) 3/4 on a thin synthetic cue; real 6/8 recordings → M:6/8 eighths preserved

The swung beat is decoded as dotted-eighth + sixteenth: an onset at 0.667 of the beat → 0.750; the 2:1 triplet swing becomes a 3:1 dotted rhythm. The straight control is undistorted. Deterministic: reproducible across three runs of this controlled stimulus.

Evidence 2 — generator (qualitative)

YuE2 accepts standard ABC tuplet syntax ((3ceg, (3:2:2c2g) as ordinary BPE text and renders without error. But in controlled cot=full renders it does not reflect the notated subdivision: a triplet plan (3 notes/beat) and a matched straight plan (2 notes/beat) produced the same onset density (ratio ≈ 1.1, not the ≈ 1.5 the notes imply), and a valid (3:2:2 swing plan did not produce a detectable swung-placement signature (measured with an analyzer first calibrated to recover ½-vs-⅔ placement from synthetic ground truth). cot=full also over-runs plan length substantially. We present this as corroborating/qualitative; the transcriber result above is the hard one.

What this is not (to save triage time)

  • Not a compound-meter bug — 6/8/9/8/12/8 are in the meter vocabulary and detected on real audio.
  • Not a missing token — YuE2's ABC is BPE text; (3 already round-trips through the tokenizer. No vocab change is needed; the gap is the training distribution (and the notation serializer/validator, which rejects tuplets).
  • Not (yet) a rubato/micro-timing request — that's a separate, harder problem, out of scope here.

Minimal reproduction

  1. Transcribe a swung input (or a synth click with the offbeat at ⅔) with --task full; read melody_full.lab. The decoded onset can only occupy the quarter-beat grid; for this controlled ⅔ stimulus it lands at ¾ (subbeat 3), not ⅔.
  2. (Optional) Render a (3/(3:2:2 score with YuE2 cot=full, separate the stem, and compare onset placement to a matched straight plan.

Attached (issue-tuplet-demo.zip): the two stimuli (.wav + .mp3), SheetSage2's own decoded melody_full.lab for each, the tracked beat.lab, and the generator. The swung .lab shows the ¾ landing directly — the off-beat is at 0.4425 / 0.590 = 0.750 (sub-beat 3), decoded as a dotted-eighth + sixteenth, while the straight control's off-beat is at 0.295 / 0.590 = 0.500. No need to run anything. Happy to also share the YuE2 bypass driver and the calibrated placement analyzer if useful.

Suggested fix (staged; architecture-compatible)

  1. Meter/beat detection — let it propose triple/compound readings; swing is often just straight eighths in 12/8, and the notes already survive when a compound meter is chosen (cheapest lever).
  2. Sub-beat grid — move SUBBEAT_DIVISION to 12 (LCM of 3 and 4 → sixteenths and triplets on one lattice), or go continuous. The grid semantics are learned, so this needs retraining on tuplet-annotated targets, not just a constant change.
  3. YuE2 — fine-tune on ABC containing (3 tuplet syntax (no vocabulary change — (3 is already valid BPE text), and add tuplet handling to the notation serializer/validator. Fine-tuning carries the usual regression risk; it is architecture-compatible, not free.

Acceptance test

Transcribe → render → re-transcribe a shuffle blues. If the round-trip still reads as straight/dotted eighths, the triplet is still being flattened. (Test compound-meter recognition separately, since that path already works.)

Thanks for open-sourcing all of this — the score-conditioned design is what made the limitation precisely diagnosable in the first place.

Source: multimodal-art-projection/YuE