Skip to content

refactor(countl2hh)!: ASAPv1 only — drop the native shim, add a golden - #175

Open
GordonYuanyc wants to merge 2 commits into
mainfrom
asapv1-only/countl2hh
Open

GordonYuanyc wants to merge 2 commits into
mainfrom
asapv1-only/countl2hh

Conversation

@GordonYuanyc

Copy link
Copy Markdown
Collaborator

Part of the ASAPv1-only series: one PR per sketch group, each off main. This one removes CountL2HH's native MessagePackCodec shim; ASAPv1 (0x19 0x00) is its only format, and it gets its first golden.

Removed

  • message_pack_format::native::countsketch_topk (the MessagePackCodec impl for CountL2HH). Nothing in the repo called it. CountL2HH had no proto message and no portable type.

Added

  • Golden count_l2hh_2x4_seed7 (pushed to sketchlib-golden-bytes; submodule bumped): a 2x4 sketch at seed index 7 with counts [[127,128,65535,-32768],[-32,-33,i32::MIN,i64::MIN]] and l2 [65536, i64::MAX] (the saturation value), so every msgpack integer family appears. Built through CountL2HH's named serde form (no hashing; serialize_to_bytes re-checks the spec rules). Checked in both directions; the reviewer hand-decoded it against spec §3.19.
  • The ASAPv1 docs no longer state a fixture count; they defer to the golden README.

Verification (rustc 1.99)

cargo fmt --check; clippy -D warnings for all four CI feature sets; RUSTDOCFLAGS="-D warnings" cargo doc; gen-proto drift clean; asapv1_golden, --lib -- l2hh, conformance_kit -- l2hh. Implemented and reviewed by separate agents; review findings are addressed in the second commit.

🤖 Generated with Claude Code

GordonYuanyc and others added 2 commits October 2, 2026 01:04
…SAPv1 golden

Removes `message_pack_format::native::countsketch_topk`, CountL2HH's
`MessagePackCodec` pass-through; `serialize_to_bytes` /
`deserialize_from_bytes` emit the same ASAPv1 bytes. CountL2HH has no proto
message and no portable type.

Bumps `asapv1_golden` to the commit adding `count_l2hh_2x4_seed7`, built from
the sketch's serde form with signed cells across the msgpack integer widths,
`l2` accumulators set apart from the cells, and seed index 7, and adds the
golden test. Docs defer the fixture coverage to the golden README.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bumps `asapv1_golden` to the commit regenerating `count_l2hh_2x4_seed7` with
an int16 cell and a uint32 `l2` accumulator, so the cells and accumulators
reach all ten integer families. Drops the claim that `sketchlib-go` mirrors
every fixture from the spec.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant