Skip to content

Docs: correct API-reference drift, stale comments, and changelog#102

Merged
RyanCodrai merged 3 commits into
mainfrom
docs-fix-api-drift
Jun 9, 2026
Merged

Docs: correct API-reference drift, stale comments, and changelog#102
RyanCodrai merged 3 commits into
mainfrom
docs-fix-api-drift

Conversation

@RyanCodrai

Copy link
Copy Markdown
Owner

Addresses #101 (and more found in a full doc sweep). Docs-only / comments-only — no code behavior change.

User-facing docs

README.md

  • Python persistence example used the non-existent .tq extension → .tv.
  • Rust snippets called TurboQuantIndex::new / IdMapIndex::new (both return Result) and used the value directly — wouldn't compile. Added .unwrap() to match the crate's own doctests.

docs/api.md

  • bit_width documented as {2, 4}; the core accepts {2, 3, 4}.
  • File-format diagrams were stale (described the pre-magic v1 layout). .tv now carries a TVPI magic + version 3 + per-vector scales + a TQ+ trailer; .tvim is version 3 (was documented as 1, which the loader now rejects). Updated both diagrams and the surrounding notes.

docs/integrations/llama_index.md

  • Filter docs were inverted: NOT, ANY, ALL, and TEXT_MATCH_INSENSITIVE are all implemented (doc claimed they raise NotImplementedError), and TEXT_MATCH is case-sensitive (doc said case-insensitive). Corrected the operator/condition lists and the semantics note. Documented that an intra-batch duplicate node_id raises (vs the langchain/haystack keep-last behavior).

docs/integrations/agno.md

  • "Every public method has an async counterpart" was false; listed the methods that actually have async variants and the sync-only ones.

Code comments

  • search.rs module doc claimed only "AVX2 on x86"; it actually has an AVX-512BW kernel selected at runtime with an AVX2 fallback (+ scalar fallback). Also corrected an AVX-512 comment that named a never-called avx2_block_epilogue helper.
  • llama_index.py from_persist_dir docstring said the side-car uses .pkl; it is .nodes.json.
  • dump_state.rs example referenced benchmarks/rabitq_poc/poc_apples_to_apples.py, removed in Remove benchmarks/rabitq_poc research scratch #97; reworded generically.

CHANGELOG

Validation

  • cargo test -p turbovec --doc passes.
  • cargo build -p turbovec --examples compiles clean.
  • All doc links/images resolve; full public-API doc coverage confirmed.

Reported by @gabrielemidulla (#101); remaining items surfaced in a two-pass doc/comment audit.

🤖 Generated with Claude Code

RyanCodrai and others added 3 commits June 9, 2026 21:02
A doc audit against the current source surfaced several drifts. All
docs-only; no code behavior change.

README.md:
- Python persistence example used the non-existent .tq extension → .tv.
- Rust snippets called TurboQuantIndex::new / IdMapIndex::new (both
  return Result) and used the value directly — wouldn't compile. Added
  .unwrap() to mirror the crate's own doctest examples.

docs/api.md:
- bit_width documented as {2, 4}; the core accepts {2, 3, 4}.
- File-format diagrams were stale (described the pre-magic v1 layout):
  .tv now carries a TVPI magic + version 3 + per-vector scales + a TQ+
  trailer; .tvim is version 3 (was documented as 1, which the loader now
  rejects). Updated both diagrams and the surrounding notes.

docs/integrations/llama_index.md:
- Filter docs were inverted: NOT, ANY, ALL, and TEXT_MATCH_INSENSITIVE
  are all implemented (doc claimed they raise NotImplementedError), and
  TEXT_MATCH is case-sensitive (doc said case-insensitive). Corrected the
  operator/condition lists and the semantics note.
- Documented that an intra-batch duplicate node_id raises (vs the
  langchain/haystack keep-last behavior).

docs/integrations/agno.md:
- 'Every public method has an async counterpart' was false; listed the
  methods that actually have async variants and noted the sync-only ones.

Reported by @gabrielemidulla (#101); remaining items found in a full
doc sweep.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Follow-up to the API-reference drift pass — same docs-only nature, now in
source comments:

- search.rs module doc claimed only 'AVX2 on x86'; it actually has an
  AVX-512BW kernel selected at runtime with an AVX2 fallback (plus a
  scalar fallback for other targets). Updated the module doc.
- search.rs AVX-512BW comment described a shared 'avx2_block_epilogue'
  helper that is never called; the real path flushes per batch via
  avx2_batch_flush_to_fa and finishes with avx2_post_flush_heap_update.
- llama_index.py from_persist_dir docstring said the side-car uses '.pkl';
  it is actually '.nodes.json'.
- dump_state.rs example referenced benchmarks/rabitq_poc/poc_apples_to_apples.py,
  which was removed in #97; reworded to describe the example generically.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…pare link

Add an [Unreleased] entry documenting the two merged integration fixes
(intra-batch duplicate-id orphaning #90, upsert delete-before-validate
#89), and repoint the stale [Unreleased] compare link from py-v0.4.2 to
the current v0.8.0 tag.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@RyanCodrai RyanCodrai merged commit 16f2173 into main Jun 9, 2026
6 checks passed
@RyanCodrai RyanCodrai deleted the docs-fix-api-drift branch June 9, 2026 20:44
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