Commit Graph

1 Commits

Author SHA1 Message Date
Egor
2a3adca1cb feat(compression-core): initial workspace with stable API + tokenizer golden tests
Scaffold the standalone Rust compression core (no OmniRoute deps):
- crates/core-api: stable traits (TokenCounter, Compressor) + types
  (Message, Encoding, CompressionConfig/Result) — the contract for all
  adapters (N-API, sidecar, CLI)
- crates/tokenizer: tiktoken-rs cl100k_base + o200k_base port
- crates/tests: golden tests reading fixtures/ (byte-equality vs JS)
- crates/bench: criterion harness (21.4ms vs JS 37.9ms on large input)
- crates/ffi: empty N-API adapter placeholder (integration phase)
- scripts/generate-fixtures.ts: JS reference output (source of truth)
- scripts/verify-golden.ts: regen + run golden tests
- fixtures/: 13 tokenizer samples incl. 405K-char stress case

Golden status: 100% match JS vs Rust on all fixtures.
2026-07-31 16:15:09 +03:00