mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-12 02:02:13 +03:00
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.