Skip to content

[DOC] Adding API guides for core cuVS types#2117

Merged
rapids-bot[bot] merged 11 commits into
NVIDIA:release/26.06from
cjnolet:codex/fern-docs-release-26.06
May 27, 2026
Merged

[DOC] Adding API guides for core cuVS types#2117
rapids-bot[bot] merged 11 commits into
NVIDIA:release/26.06from
cjnolet:codex/fern-docs-release-26.06

Conversation

@cjnolet

@cjnolet cjnolet commented May 21, 2026

Copy link
Copy Markdown
Contributor

Adding several new pages to the API guides for core cuvs types-

  1. Memory management (with RMM)
  2. Multi-dimensional arrays
  3. Multi-GPU
  4. Resources

@copy-pr-bot

copy-pr-bot Bot commented May 21, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@cjnolet cjnolet changed the base branch from main to release/26.06 May 21, 2026 20:54
@cjnolet cjnolet force-pushed the codex/fern-docs-release-26.06 branch from 8663294 to c76e5fe Compare May 21, 2026 20:58
@cjnolet cjnolet marked this pull request as ready for review May 21, 2026 20:59
@cjnolet cjnolet requested a review from a team as a code owner May 21, 2026 20:59
@cjnolet cjnolet added doc Improvements or additions to documentation non-breaking Introduces a non-breaking change labels May 21, 2026
@cjnolet cjnolet moved this to In Progress in Unstructured Data Processing May 21, 2026
@cjnolet cjnolet self-assigned this May 21, 2026
@coderabbitai

coderabbitai Bot commented May 21, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds a Core Types nav and landing page; introduces Core Types guides (Memory Management, Multi-dimensional Arrays, Multi‑GPU, Resources); converts many relative doc links to absolute site routes; standardizes branding to “NVIDIA cuVS”; and adds index-extension, multi‑GPU, and Java resource-scoped examples plus API doc clarifications.

Changes

Documentation site reorganization and new guides

Layer / File(s) Summary
Navigation config and Core Types landing
fern/docs.yml, fern/pages/core_types.md
Navigation adds a Core Types section under the API Guide and a landing page linking to Array Types, Memory Management, Multi‑GPU, and Resources.
Memory Management guide
fern/pages/other/memory_management.md
New guide describing RMM-backed memory pools, device/pinned/managed allocations, multi-language examples, pool sizing, and practical rules.
Multi-dimensional arrays guide
fern/pages/other/multidimensional_arrays.md
New guide describing row-major conventions, per-language array representations, API usage examples, output ownership, and C++ view vs owning array guidance.
Multi-GPU guide
fern/pages/other/multi_gpu.md
New guide describing RAFT-based multi‑GPU coordination, NCCL communicator patterns, single-node and multi-node examples, and setup guidance.
Resources guide
fern/pages/other/resources.md
New guide documenting cuVS resources: creation/reuse, synchronization, thread-safety, application streams, stream pools, workspace resources, and practical guidance with multi-language examples.
API and user guide reorganization
fern/pages/api_guide.md, fern/pages/user_guide.md
Added Core Types subsection and converted clustering/indexing/preprocessing/other API links to absolute /user-guide/... routes; added Dynamic Batching in Other APIs.
Index extension documentation & Java updates
fern/pages/neighbors/*.md, fern/pages/cluster/kmeans.md
Added “Extending an index” sections with cross-language examples (IVF‑Flat, IVF‑PQ, CAGRA, Multi‑GPU), added K‑Means multi‑GPU example, and updated Java snippets to nested try-with-resources and CuVSMatrix/ resource-scoped patterns.
API parameter documentation
fern/pages/cpp_api/cpp-api-cluster-kmeans.md
Documented new cluster::kmeans::params::init_size, clarified streaming_batch_size, and expanded multi‑GPU dispatch behavior for cluster::kmeans::fit.
Benchmarking and cuVS Bench updates
fern/pages/benchmarking_guide.md, fern/pages/cuvs_bench/*.md
Converted cuVS Bench links to absolute routes, added Docker nightly description and tag links, clarified dependency/setup/build instructions, and updated datasets/backends navigation.
Developer guidelines and coding conventions
fern/pages/*_guidelines.md, fern/pages/user_guide/abi_stability.md
Updated C/C++/Java/Python guidelines and ABI stability guide to use “NVIDIA cuVS” phrasing, added C++ dense-array guidance, and adjusted internal links to absolute routes.
Site-wide link migration and branding
fern/pages/*.md (many files)
Converted many relative markdown links to absolute site routes (e.g., /user-guide/..., /getting-started/...) and standardized product branding to “NVIDIA cuVS” across pages.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

  • rapidsai/cuvs#2067: Related Fern docs migration and site config updates that integrate generated API pages with the docs structure.

Suggested reviewers

  • bdice
  • divyegala
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
fern/pages/neighbors/bruteforce.md (1)

343-347: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Close loadedIndex with try-with-resources.

loadedIndex is created but not closed in this example. Since this wrapper owns native resources, the example should model deterministic cleanup.

Suggested fix
-  try (FileInputStream input = new FileInputStream("/tmp/cuvs-bruteforce.bin")) {
-    BruteForceIndex loadedIndex =
-        BruteForceIndex.newBuilder(resources)
-            .from(input)
-            .build();
-  }
+  try (FileInputStream input = new FileInputStream("/tmp/cuvs-bruteforce.bin");
+      BruteForceIndex loadedIndex =
+          BruteForceIndex.newBuilder(resources)
+              .from(input)
+              .build()) {
+    // Use loadedIndex.
+  }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/neighbors/bruteforce.md` around lines 343 - 347, BruteForceIndex
loaded via BruteForceIndex.newBuilder(resources).from(input).build() is not
closed; update the example to use try-with-resources to ensure deterministic
cleanup of native resources by declaring loadedIndex in a try(...) block (e.g.,
try (BruteForceIndex loadedIndex =
BruteForceIndex.newBuilder(resources).from(input).build()) { ... }) so
loadedIndex.close() is invoked automatically.
fern/pages/cuvs_bench/running.md (1)

152-153: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Align algorithm argument text with the command example.

Line 152 lists cuvs_cagra,hnswlib, but the actual Docker command above uses cuvs_cagra,cuvs_ivf_pq. Keep these consistent to avoid copy/paste confusion.

Proposed doc fix
-| `"--algorithms cuvs_cagra,hnswlib --batch-size 10 -k 10"` | Arguments passed to the benchmark run script. |
+| `"--algorithms cuvs_cagra,cuvs_ivf_pq --batch-size 10 -k 10"` | Arguments passed to the benchmark run script. |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cuvs_bench/running.md` around lines 152 - 153, The algorithms list
in the example table row (`"--algorithms cuvs_cagra,hnswlib --batch-size 10 -k
10"`) is inconsistent with the Docker command above that uses
`cuvs_cagra,cuvs_ivf_pq`; update the table entry to match the command example
(replace `hnswlib` with `cuvs_ivf_pq`) so the `--algorithms` argument string and
the earlier Docker invocation are identical, ensuring `--algorithms
cuvs_cagra,cuvs_ivf_pq --batch-size 10 -k 10` appears in the table.
fern/pages/neighbors/cagra.md (1)

684-688: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix undefined Java variable in HNSW query example.

Line 687 passes queries to .withQueryVectors(...), but queries is not declared in the snippet scope.

Proposed doc fix
-      HnswQuery query =
-          new HnswQuery.Builder(resources)
-              .withTopK(10)
-              .withSearchParams(searchParams)
-              .withQueryVectors(queries)
-              .build();
+      try (CuVSMatrix queryVectors = loadQueryMatrix()) {
+        HnswQuery query =
+            new HnswQuery.Builder(resources)
+                .withTopK(10)
+                .withSearchParams(searchParams)
+                .withQueryVectors(queryVectors)
+                .build();
+      }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/neighbors/cagra.md` around lines 684 - 688, The snippet passes an
undeclared variable queries into HnswQuery.Builder.withQueryVectors(...); fix by
either declaring and initializing a queries variable of the correct type before
building the query (e.g., a float[][] or List<float[]> depending on surrounding
code) or by replacing queries with the existing variable name that holds the
query vectors in this snippet; update the code around
HnswQuery.Builder(...).withQueryVectors(...) to reference a properly defined
variable so HnswQuery.Builder and withQueryVectors have a valid argument.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@fern/pages/cuvs_bench/install.md`:
- Around line 47-48: Update the link text for the CPU-only image entry in the
Markdown to use the hyphenated compound adjective "CPU-only" instead of "CPU
only"; specifically modify the second bullet string "NVIDIA cuVS bench CPU only
images" to "NVIDIA cuVS bench CPU-only images" in the install.md content so the
displayed link text is correct.

In `@fern/pages/integrations.md`:
- Around line 71-73: Replace the incorrect vendor heading and any mentions of
"Everpure" in this section with "Pure Storage": update the heading "###
Everpure" to "### Pure Storage" and change the link text "Everpure FlashBlade"
to "Pure Storage FlashBlade" (or just "FlashBlade") so the vendor name matches
the linked product/domain; verify there are no other stray "Everpure"
occurrences in this block and adjust them accordingly.

In `@fern/pages/other/pairwise_distances.md`:
- Line 120: The Markdown link to K-selection contains a typo in the path
("other-ap-is") and will 404; update the link in pairwise_distances.md (the
sentence referencing K-selection) to use the correct route segment (replace
"other-ap-is" with "other-apis") so the link becomes
/user-guide/api-guides/other-apis/k-selection.

In `@fern/pages/other/resources.md`:
- Around line 37-43: The example leaks resources when cuvsStreamSync(resources)
fails because it returns immediately without calling cuvsResourcesDestroy;
update the error path so that on any failure after cuvsResourcesCreate (e.g.,
cuvsStreamSync returning non-CUVS_SUCCESS) you call
cuvsResourcesDestroy(resources) before returning (or use a single cleanup/exit
path—e.g., a result variable and a final cleanup block/goto) and handle/report
any destroy errors while ensuring resources is always cleaned up.

In `@fern/pages/user_guide/abi_stability.md`:
- Line 34: Replace the incorrect article in the sentence that reads "A NVIDIA
cuVS version such as `26.04` means the release was made in April 2026." with "An
NVIDIA cuVS version such as `26.04` means the release was made in April 2026." —
update the text in the ABI stability paragraph (the sentence containing "NVIDIA
cuVS version such as `26.04`") to use "An" instead of "A".

---

Outside diff comments:
In `@fern/pages/cuvs_bench/running.md`:
- Around line 152-153: The algorithms list in the example table row
(`"--algorithms cuvs_cagra,hnswlib --batch-size 10 -k 10"`) is inconsistent with
the Docker command above that uses `cuvs_cagra,cuvs_ivf_pq`; update the table
entry to match the command example (replace `hnswlib` with `cuvs_ivf_pq`) so the
`--algorithms` argument string and the earlier Docker invocation are identical,
ensuring `--algorithms cuvs_cagra,cuvs_ivf_pq --batch-size 10 -k 10` appears in
the table.

In `@fern/pages/neighbors/bruteforce.md`:
- Around line 343-347: BruteForceIndex loaded via
BruteForceIndex.newBuilder(resources).from(input).build() is not closed; update
the example to use try-with-resources to ensure deterministic cleanup of native
resources by declaring loadedIndex in a try(...) block (e.g., try
(BruteForceIndex loadedIndex =
BruteForceIndex.newBuilder(resources).from(input).build()) { ... }) so
loadedIndex.close() is invoked automatically.

In `@fern/pages/neighbors/cagra.md`:
- Around line 684-688: The snippet passes an undeclared variable queries into
HnswQuery.Builder.withQueryVectors(...); fix by either declaring and
initializing a queries variable of the correct type before building the query
(e.g., a float[][] or List<float[]> depending on surrounding code) or by
replacing queries with the existing variable name that holds the query vectors
in this snippet; update the code around
HnswQuery.Builder(...).withQueryVectors(...) to reference a properly defined
variable so HnswQuery.Builder and withQueryVectors have a valid argument.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 68f54759-cd96-494b-8542-a66ae871c25c

📥 Commits

Reviewing files that changed from the base of the PR and between 10368de and c76e5fe.

📒 Files selected for processing (67)
  • fern/docs.yml
  • fern/pages/advanced_topics.md
  • fern/pages/api_basics.md
  • fern/pages/api_guide.md
  • fern/pages/api_interoperability.md
  • fern/pages/benchmarking_guide.md
  • fern/pages/build.md
  • fern/pages/c_guidelines.md
  • fern/pages/cluster/index.md
  • fern/pages/cluster/kmeans.md
  • fern/pages/clustering.md
  • fern/pages/coding_guidelines.md
  • fern/pages/comparing_indexes.md
  • fern/pages/contributing.md
  • fern/pages/core_types.md
  • fern/pages/cpp_api/cpp-api-cluster-kmeans.md
  • fern/pages/cpp_guidelines.md
  • fern/pages/cuvs_bench/datasets.md
  • fern/pages/cuvs_bench/index.md
  • fern/pages/cuvs_bench/install.md
  • fern/pages/cuvs_bench/introduction.md
  • fern/pages/cuvs_bench/param_tuning.md
  • fern/pages/cuvs_bench/pluggable_backend.md
  • fern/pages/cuvs_bench/running.md
  • fern/pages/cuvs_bench/wiki_all_dataset.md
  • fern/pages/developer_guide.md
  • fern/pages/getting_started.md
  • fern/pages/index.md
  • fern/pages/installation/go.md
  • fern/pages/installation/java.md
  • fern/pages/installation/rust.md
  • fern/pages/integrations.md
  • fern/pages/introduction.md
  • fern/pages/java_guidelines.md
  • fern/pages/jit_compilation.md
  • fern/pages/jit_lto_guide.md
  • fern/pages/neighbors/all_neighbors.md
  • fern/pages/neighbors/bruteforce.md
  • fern/pages/neighbors/cagra.md
  • fern/pages/neighbors/ivfflat.md
  • fern/pages/neighbors/ivfpq.md
  • fern/pages/neighbors/multi_gpu.md
  • fern/pages/neighbors/neighbors.md
  • fern/pages/neighbors/nn_descent.md
  • fern/pages/neighbors/scann.md
  • fern/pages/neighbors/vamana.md
  • fern/pages/other/index.md
  • fern/pages/other/memory_management.md
  • fern/pages/other/multi_gpu.md
  • fern/pages/other/multidimensional_arrays.md
  • fern/pages/other/pairwise_distances.md
  • fern/pages/other/resources.md
  • fern/pages/preprocessing/index.md
  • fern/pages/preprocessing/product_quantization.md
  • fern/pages/preprocessing/scalar_quantizer.md
  • fern/pages/preprocessing/spectral_embedding.md
  • fern/pages/python_guidelines.md
  • fern/pages/quantization.md
  • fern/pages/references.md
  • fern/pages/tuning_guide.md
  • fern/pages/use_cases.md
  • fern/pages/user_guide.md
  • fern/pages/user_guide/abi_stability.md
  • fern/pages/user_guide/integration_patterns.md
  • fern/pages/vector_databases_vs_vector_search.md
  • fern/pages/what_is_vector_search.md
  • fern/pages/working_with_ann_indexes.md

Comment on lines +47 to +48
- [NVIDIA cuVS bench images](https://hub.docker.com/r/rapidsai/cuvs-bench/tags)
- [NVIDIA cuVS bench CPU only images](https://hub.docker.com/r/rapidsai/cuvs-bench-cpu/tags)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Use hyphenated “CPU-only” in link text.

Line 48 should use “CPU-only” for correct compound adjective style.

Proposed doc fix
-- [NVIDIA cuVS bench CPU only images](https://hub.docker.com/r/rapidsai/cuvs-bench-cpu/tags)
+- [NVIDIA cuVS bench CPU-only images](https://hub.docker.com/r/rapidsai/cuvs-bench-cpu/tags)
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- [NVIDIA cuVS bench images](https://hub.docker.com/r/rapidsai/cuvs-bench/tags)
- [NVIDIA cuVS bench CPU only images](https://hub.docker.com/r/rapidsai/cuvs-bench-cpu/tags)
- [NVIDIA cuVS bench images](https://hub.docker.com/r/rapidsai/cuvs-bench/tags)
- [NVIDIA cuVS bench CPU-only images](https://hub.docker.com/r/rapidsai/cuvs-bench-cpu/tags)
🧰 Tools
🪛 LanguageTool

[grammar] ~48-~48: Use a hyphen to join words.
Context: ...uvs-bench/tags) - [NVIDIA cuVS bench CPU only images](https://hub.docker.com/r/ra...

(QB_NEW_EN_HYPHEN)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cuvs_bench/install.md` around lines 47 - 48, Update the link text
for the CPU-only image entry in the Markdown to use the hyphenated compound
adjective "CPU-only" instead of "CPU only"; specifically modify the second
bullet string "NVIDIA cuVS bench CPU only images" to "NVIDIA cuVS bench CPU-only
images" in the install.md content so the displayed link text is correct.

Comment thread fern/pages/integrations.md
### Selecting nearest neighbors

Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](select_k.md) to keep the best values from each query row.
Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](/user-guide/api-guides/other-ap-is/k-selection) to keep the best values from each query row.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix likely broken K-selection route typo.

Line 120 links to /user-guide/api-guides/other-ap-is/k-selection, but other-ap-is appears to be a typo and will likely 404.

Proposed fix
-Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](/user-guide/api-guides/other-ap-is/k-selection) to keep the best values from each query row.
+Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](/user-guide/api-guides/other-apis/k-selection) to keep the best values from each query row.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](/user-guide/api-guides/other-ap-is/k-selection) to keep the best values from each query row.
Pairwise distance often feeds a selection step. Compute the full matrix when it fits in memory, then use [K-selection](/user-guide/api-guides/other-apis/k-selection) to keep the best values from each query row.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/other/pairwise_distances.md` at line 120, The Markdown link to
K-selection contains a typo in the path ("other-ap-is") and will 404; update the
link in pairwise_distances.md (the sentence referencing K-selection) to use the
correct route segment (replace "other-ap-is" with "other-apis") so the link
becomes /user-guide/api-guides/other-apis/k-selection.

Comment on lines +37 to +43
if (cuvsResourcesCreate(&resources) != CUVS_SUCCESS) { return 1; }

// Pass resources to cuVS C APIs, such as index build and search calls.

if (cuvsStreamSync(resources) != CUVS_SUCCESS) { return 1; }
if (cuvsResourcesDestroy(resources) != CUVS_SUCCESS) { return 1; }

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Avoid leak on error path in the C example.

If cuvsStreamSync(resources) fails, the example returns early without destroying resources.

Suggested fix
-  if (cuvsResourcesCreate(&resources) != CUVS_SUCCESS) { return 1; }
+  if (cuvsResourcesCreate(&resources) != CUVS_SUCCESS) { return 1; }

   // Pass resources to cuVS C APIs, such as index build and search calls.

-  if (cuvsStreamSync(resources) != CUVS_SUCCESS) { return 1; }
-  if (cuvsResourcesDestroy(resources) != CUVS_SUCCESS) { return 1; }
+  if (cuvsStreamSync(resources) != CUVS_SUCCESS) {
+    cuvsResourcesDestroy(resources);
+    return 1;
+  }
+  if (cuvsResourcesDestroy(resources) != CUVS_SUCCESS) { return 1; }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
if (cuvsResourcesCreate(&resources) != CUVS_SUCCESS) { return 1; }
// Pass resources to cuVS C APIs, such as index build and search calls.
if (cuvsStreamSync(resources) != CUVS_SUCCESS) { return 1; }
if (cuvsResourcesDestroy(resources) != CUVS_SUCCESS) { return 1; }
if (cuvsResourcesCreate(&resources) != CUVS_SUCCESS) { return 1; }
// Pass resources to cuVS C APIs, such as index build and search calls.
if (cuvsStreamSync(resources) != CUVS_SUCCESS) {
cuvsResourcesDestroy(resources);
return 1;
}
if (cuvsResourcesDestroy(resources) != CUVS_SUCCESS) { return 1; }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/other/resources.md` around lines 37 - 43, The example leaks
resources when cuvsStreamSync(resources) fails because it returns immediately
without calling cuvsResourcesDestroy; update the error path so that on any
failure after cuvsResourcesCreate (e.g., cuvsStreamSync returning
non-CUVS_SUCCESS) you call cuvsResourcesDestroy(resources) before returning (or
use a single cleanup/exit path—e.g., a result variable and a final cleanup
block/goto) and handle/report any destroy errors while ensuring resources is
always cleaned up.

Comment thread fern/pages/user_guide/abi_stability.md Outdated
@cjnolet

cjnolet commented May 21, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test d2e5e4e


The C, Java, Rust, and Go examples change the current device resource through the NVIDIA cuVS C API. This has process-wide effect for the current device, so configure it before allocating long-lived objects and reset it only after those objects are destroyed.

### Allocating device memory

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Intentional to not have Java, Rust, and Go examples here?


Most users do not allocate raw buffers directly. NVIDIA cuVS APIs typically accept matrices, tensors, or language-native array wrappers, and those objects allocate through the active RMM resource underneath.

### Allocating pinned host memory

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one only has C and CPP. Maybe we can add a note about why other languages don't support this yet.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm really trying to limit the potential for small details that don't end up getting updated as the docs evolve. The tabbed languages in the code examples should make the supported languages pretty clear (for eg. we shouldn't need to explicitly state in every code example that one or more languages is not supported because it should be assumed).

Comment thread fern/pages/other/memory_management.md Outdated
Comment thread fern/pages/other/multi_gpu.md Outdated
Comment thread fern/pages/other/multi_gpu.md Outdated
Comment thread fern/pages/other/multi_gpu.md
Comment thread fern/pages/other/multi_gpu.md Outdated
Comment thread fern/pages/other/multi_gpu.md Outdated
Comment thread fern/pages/other/multidimensional_arrays.md Outdated
@cjnolet

cjnolet commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test ba2cd45

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 11

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
fern/scripts/generate_api_reference.py (1)

3867-3871: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Store full member declarations in plain struct parsing.

At Line 3870, saving only c_type in DoxygenEntry.signature breaks later type recovery when a field name matches the type basename (e.g., search_params search_params), producing malformed rendered types downstream.

Suggested fix
         member = DoxygenEntry(
             kind="member",
             name=name,
-            signature=c_type or declaration,
+            signature=declaration,
             summary="",
             source=entry.source,
             line=entry.line,
         )
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/scripts/generate_api_reference.py` around lines 3867 - 3871, When
constructing the DoxygenEntry for plain struct members, don’t set signature to
only c_type; store the full member declaration so downstream type recovery can
distinguish a field named the same as its type. Update the DoxygenEntry creation
where member = DoxygenEntry(...) to use the complete declaration (the existing
declaration variable) for signature (or concatenate declaration and c_type if
necessary) instead of just c_type, keeping name as-is so functions/methods like
DoxygenEntry.signature, the declaration variable, and c_type are consistent for
later type rendering.
🧹 Nitpick comments (15)
fern/pages/cpp_api/cpp-api-common-types-copy-serialization-and-utility-apis.md (1)

7-8: 💤 Low value

Consider adding an h2 section heading.

The document jumps from the h1 title directly to h3 subsections. Adding an h2 heading (e.g., "## RAFT Utilities" or "## Core Utilities") before the first h3 would improve document structure and follow markdown best practices.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@fern/pages/cpp_api/cpp-api-common-types-copy-serialization-and-utility-apis.md`
around lines 7 - 8, The document currently jumps from the h1 title to h3
headings like "### raft::copy"; add a new h2 section heading (for example "##
RAFT Utilities" or "## Core Utilities") immediately before the first h3 (the
"### raft::copy" anchor) to improve structure and follow Markdown hierarchy;
ensure the new h2 precedes other h3 subsections so headings descend H1 -> H2 ->
H3.
fern/pages/cpp_api/cpp-api-common-types-errors-and-logging.md (1)

9-10: 💤 Low value

Consider adding an h2 section heading.

The document jumps from the h1 title directly to h3 subsections. Adding an h2 heading (e.g., "## Error Handling" or "## Error Handling and Logging APIs") before the first h3 would improve document structure and follow markdown best practices.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-errors-and-logging.md` around lines 9
- 10, The document jumps from the top-level title straight to "###
raft::exception"; add an H2 section heading such as "## Error Handling" or "##
Error Handling and Logging APIs" immediately before the "### raft::exception"
subsection so the structure follows h1 → h2 → h3 hierarchy and improves
navigation; update the area around the "### raft::exception" anchor (a
id="raft-exception") to insert the new H2 heading while keeping the anchor and
subsequent "raft::exception" H3 unchanged.
fern/pages/c_api/c-api-neighbors-tiered-index.md (1)

167-167: ⚡ Quick win

Consider breaking the long description into structured bullet points.

This follows the same pattern as the brute force API documentation and would benefit from the same structured formatting for clarity.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/c_api/c-api-neighbors-tiered-index.md` at line 167, Split the long
single-line description for TieredIndex into structured bullet points mirroring
the brute force API style: add a short intro sentence referencing TieredIndex
and DLManagedTensor, then a "Supported devices" bullet listing DLDeviceType
values (kDLCUDA, kDLCUDAHost, kDLCUDAManaged, kDLCPU) and an "Acceptable data
types" bullet with two sub-bullets for the float formats (kDLDataType.code ==
kDLFloat and bits == 32; kDLDataType.code == kDLFloat and bits == 16); update
the text mentioning DLManagedTensor and DLDeviceType to use these bullets so the
information is clearer and consistent with the brute force docs.
fern/pages/c_api/c-api-neighbors-brute-force.md (2)

73-73: ⚡ Quick win

Consider breaking the long description into structured bullet points.

The current description is a dense run-on sentence that lists multiple constraints without clear separation. Consider reformatting for better readability.

📝 Suggested formatting improvement
-Build a BRUTEFORCE index with a `DLManagedTensor` which has underlying `DLDeviceType` equal to `kDLCUDA`, `kDLCUDAHost`, `kDLCUDAManaged`, or `kDLCPU`. Also, acceptable underlying types are: 1. `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32` 2. `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 16`
+Build a BRUTEFORCE index with a `DLManagedTensor`.
+
+**Requirements:**
+- Underlying `DLDeviceType` must be `kDLCUDA`, `kDLCUDAHost`, `kDLCUDAManaged`, or `kDLCPU`
+- Acceptable data types:
+  1. `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32`
+  2. `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 16`
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/c_api/c-api-neighbors-brute-force.md` at line 73, Split the long
run-on sentence into a short intro plus structured bullet-like lines: state that
the function builds a BRUTEFORCE index from a DLManagedTensor, then list allowed
DLDeviceType values (kDLCUDA, kDLCUDAHost, kDLCUDAManaged, kDLCPU) on one line
and list acceptable data-type conditions on separate lines (kDLDataType.code ==
kDLFloat with bits == 32, and kDLDataType.code == kDLFloat with bits == 16) so
the constraints for DLManagedTensor, DLDeviceType, and kDLDataType are clearly
separated and easy to scan.

102-102: ⚡ Quick win

Consider breaking the long description into structured bullet points.

Similar to the build function, this description would benefit from clearer structure to separate device type constraints, type matching requirements, and input/output type specifications.

📝 Suggested formatting improvement
-Search a BRUTEFORCE index with a `DLManagedTensor` which has underlying `DLDeviceType` equal to `kDLCUDA`, `kDLCUDAHost`, `kDLCUDAManaged`. It is also important to note that the BRUTEFORCE index must have been built with the same type of `queries`, such that `index.dtype.code == queries.dl_tensor.dtype.code` Types for input are: 1. `queries`: `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32` or `kDLDataType.bits = 16` 2. `neighbors`: `kDLDataType.code == kDLUInt` and `kDLDataType.bits = 32` 3. `distances`: `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32`
+Search a BRUTEFORCE index with a `DLManagedTensor`.
+
+**Requirements:**
+- Underlying `DLDeviceType` must be `kDLCUDA`, `kDLCUDAHost`, or `kDLCUDAManaged`
+- Index and queries must have matching types: `index.dtype.code == queries.dl_tensor.dtype.code`
+
+**Input/output types:**
+1. `queries`: `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32` or `16`
+2. `neighbors`: `kDLDataType.code == kDLUInt` and `kDLDataType.bits = 32`
+3. `distances`: `kDLDataType.code == kDLFloat` and `kDLDataType.bits = 32`
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/c_api/c-api-neighbors-brute-force.md` at line 102, Split the long
single-paragraph description into clear bullet points: one bullet listing
allowed DLDeviceType values (DLManagedTensor with DLDeviceType == kDLCUDA,
kDLCUDAHost, kDLCUDAManaged), one bullet clarifying the requirement that the
BRUTEFORCE index must be built with the same query dtype (compare
index.dtype.code == queries.dl_tensor.dtype.code), and a final bullet (or
sub-bullets) enumerating input/output data-type constraints for queries,
neighbors, and distances (queries: kDLDataType.code == kDLFloat with
kDLDataType.bits == 32 or 16; neighbors: kDLDataType.code == kDLUInt and
kDLDataType.bits == 32; distances: kDLDataType.code == kDLFloat and
kDLDataType.bits == 32), using the symbols DLManagedTensor, queries, neighbors,
distances, and the kDL* constants to keep references clear.
fern/pages/cpp_api/cpp-api-distance-distance.md (1)

144-144: 💤 Low value

Minor: Awkward phrasing combining note and usage example.

Lines 144, 175, 206, 237, 268, and 299 combine "Note: Only contiguous row- or column-major layouts supported currently." with "Usage example:" on a single line, which reads awkwardly. Consider separating these or removing the trailing "Usage example:" if no example follows.

Also applies to: 175-175, 206-206, 237-237, 268-268, 299-299

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-distance-distance.md` at line 144, The line
containing the sentence "Note: Only contiguous row- or column-major layouts
supported currently. Usage example:" reads awkwardly; update each occurrence so
the note and the "Usage example:" marker are separated (e.g., put the note on
its own sentence/line and follow with a separate "Usage example:" heading) or
remove the trailing "Usage example:" if there is no example following it; ensure
you update all occurrences of that exact sentence in
cpp-api-distance-distance.md so the note is clear and properly separated from
the usage marker.
fern/pages/cpp_api/cpp-api-common-types-owning-array-factories.md (1)

5-8: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title directly to h3 subsections, skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-owning-array-factories.md` around
lines 5 - 8, The document currently jumps from the H1 "Owning Array Factories"
directly to H3 entries like "raft::make_device_matrix"; insert an H2
intermediary (e.g., "Overview" or "Factories") between the H1 and the existing
H3s to restore proper heading hierarchy and accessibility, update the section
anchor if needed (reference: raft::make_device_matrix) and ensure the new H2
appears before the existing H3 subsections.
fern/pages/cpp_api/cpp-api-common-types-dense-array-views.md (1)

5-10: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title "Dense Array Views" directly to an h3 subsection "raft::mdspan", skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility. For example, you could add an h2 "Core View Types" or "Multi-dimensional Views" before the first h3.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-dense-array-views.md` around lines 5
- 10, Add an h2 heading between the H1 "Dense Array Views" and the existing H3
"raft::mdspan" to provide an intermediate section (e.g., "Core View Types" or
"Multi-dimensional Views"); update the markdown so the new heading is a level-2
(##) line placed before the anchor/section for raft::mdspan, and ensure any
nearby anchors or links still point correctly to the raft::mdspan subsection.
fern/pages/cpp_api/cpp-api-common-types-execution-resources.md (1)

5-10: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title directly to h3 subsections, skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-execution-resources.md` around lines
5 - 10, Add an intermediate h2 heading beneath the main h1 "Execution Resources"
to avoid jumping straight to h3s; insert a descriptive h2 (for example
"Overview" or "Execution resources overview") directly before the existing "###
raft::resources" anchor so the document hierarchy is H1 -> H2 -> H3, ensuring
the section about raft::resources remains unchanged.
fern/pages/cpp_api/cpp-api-common-types-dense-view-factories.md (1)

5-8: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title directly to h3 subsections, skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-dense-view-factories.md` around lines
5 - 8, Add an intermediate h2 heading between the h1 "Dense View Factories" and
the existing h3 subsections (e.g., a descriptive h2 like "Factory Functions" or
"Overview of Dense View Factories") to restore proper heading hierarchy; update
the markdown near the h1 and before the "raft::make_device_matrix_view" section
so the page goes H1 -> H2 -> H3 and ensure the new h2 is semantically
appropriate for the group of functions such as raft::make_device_matrix_view.
fern/pages/c_api/c-api-neighbors-ivf-pq.md (1)

505-505: 💤 Low value

Consider hyphenating compound modifier.

The phrase "PQ encoded vectors" uses a compound modifier that typically should be hyphenated when preceding a noun: "PQ-encoded vectors".

✏️ Proposed wording
-Unpack `n_rows` consecutive PQ encoded vectors of a single list (cluster) in the compressed index starting at given `offset`, not expanded to one code per byte. Each code in the output buffer occupies ceildiv(index.pq_dim() * index.pq_bits(), 8) bytes.
+Unpack `n_rows` consecutive PQ-encoded vectors of a single list (cluster) in the compressed index starting at given `offset`, not expanded to one code per byte. Each code in the output buffer occupies ceildiv(index.pq_dim() * index.pq_bits(), 8) bytes.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/c_api/c-api-neighbors-ivf-pq.md` at line 505, Change the compound
modifier "PQ encoded vectors" to "PQ-encoded vectors" in the documentation line
that starts "Unpack `n_rows` consecutive PQ encoded vectors of a single list
(cluster)..." so it reads "Unpack `n_rows` consecutive PQ-encoded vectors...";
keep the rest of the sentence intact (including references to `offset`,
`index.pq_dim()` and `index.pq_bits()`).
fern/pages/cpp_api/cpp-api-common-types-layouts-and-extents.md (1)

5-10: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title directly to h3 subsections, skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-layouts-and-extents.md` around lines
5 - 10, The document jumps from the H1 "Layouts and Extents" straight to H3
anchors like "raft::row_major"; add an H2 heading (e.g., "Overview" or "Layouts
and Extents — Overview") immediately after the H1 and before the <a
id="raft-row-major"></a> anchor so the structure becomes H1 → H2 → H3 and
improves accessibility and TOC generation; update surrounding text to briefly
introduce raft layout and extent types under the new H2.
fern/pages/cpp_api/cpp-api-common-types-owning-dense-arrays.md (1)

5-10: ⚡ Quick win

Consider adding an h2 section heading.

The page jumps from the h1 title directly to h3 subsections, skipping the h2 level. Adding an intermediate h2 heading would improve document structure and accessibility.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-owning-dense-arrays.md` around lines
5 - 10, Add an intermediate h2 heading between the existing H1 "Owning Dense
Arrays" and the H3 "raft::mdarray" to restore proper heading hierarchy; update
the markdown near the top of the file (around the H1 and the "raft::mdarray"
subsection) to insert a descriptive H2 such as "Overview" or "Contents" so the
structure becomes H1 -> H2 -> H3 (raft::mdarray).
fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md (1)

10-10: ⚡ Quick win

Consider using h2 headings for top-level API entities.

The heading jumps from h1 (line 5) to h3, which may cause issues with documentation generators and table-of-contents navigation. Consider using ## raft::device_csr_matrix instead.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md` at line 10,
The heading for the top-level API entity "raft::device_csr_matrix" is currently
an h3 ("### raft::device_csr_matrix") and should be promoted to an h2 to
maintain proper heading hierarchy; update the heading to "##
raft::device_csr_matrix" (and scan other top-level API entities in this file to
ensure they also use h2 instead of h3 where appropriate) so documentation
generators and TOC navigation work correctly.
fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md (1)

60-60: ⚡ Quick win

Consider breaking the description into paragraphs.

The description for neighbors::dynamic_batching::index is a single long paragraph that mixes the main description with usage examples and priority queue discussion. The bold markers __Usage example__ and __Priority queues__ suggest these should be separate paragraphs or subsections for better readability.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md` at line 60, Split
the single long paragraph describing neighbors::dynamic_batching::index into
multiple paragraphs/subsections: keep the main concept and
lightweight/shared-pointer design in the first paragraph, move the
priority/queue behavior and search_params::dispatch_timeout_ms aggregation into
a separate "Priority queues" paragraph, and put the example about constructing
one batching index per priority class into a distinct "Usage example" paragraph;
ensure references to the dynamic batching index and
search_params::dispatch_timeout_ms remain intact so readers can locate the
details.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@fern/pages/c_api/c-api-neighbors-vamana.md`:
- Around line 175-177: The paragraph is incomplete: either finish the supported
distance metrics list and/or add the missing L2 usage example. Update the Vamana
section to (a) list supported metrics explicitly (e.g., "L2, Cosine,
InnerProduct") near the mention of distance metrics and (b) insert a short L2
usage example showing how to configure the index_params struct (e.g., setting
metric to L2 and degree/robustPrune parameters) and call the index build
function for Vamana; reference the existing symbols "index_params struct" and
the Vamana/Build (or buildIndex) operation so reviewers can find where to add
the example. If a usage example isn't desired, remove the fragment "- L2 Usage
example:" entirely and reword the sentence to complete the metrics list.

In `@fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md`:
- Line 34: The function signature uses the wrong type name: replace the
incorrect NNZType with the template parameter NZType in the initialize_sparsity
declaration and any other occurrences (e.g., the second signature on the page),
so the method signature reads initialize_sparsity(NZType nnz); and update the
parameter table entry to refer to NZType instead of NNZType; look for the
template declaration typename NZType and ensure all usages match that symbol.
- Line 153: The method signature initialize_sparsity currently uses the wrong
type name NNZType; change it to match the template parameter NZType used earlier
(e.g., void initialize_sparsity(NZType nnz)) and update any other occurrences
(including the other instance at line ~160) to use NZType; also update the
parameter table to list NZType consistently instead of NNZType so the template
parameter name is uniform across the file.
- Line 282: Update the `nnz` parameter documentation to state that it is
optional and that its default value is 0; specifically, change the `nnz` row
(the table entry `nnz | NZType`) to say something like "Optional; number of
nonzero entries when known, defaults to 0 (unknown/unspecified)". Apply the same
change for both occurrences referenced by the function signatures that use `nnz
= 0` so the docs match the signatures.

In `@fern/pages/cpp_api/cpp-api-distance-grammian.md`:
- Line 16: Fix the spelling in the documentation string that currently reads
"inner probucts": change "probucts" to "products" in the sentence describing the
Gram matrix (the line containing "A Gram matrix is the Hermitian matrix of inner
probucts G_ik = <x_i, x_k>" / symbol G_ik) so it reads "inner products".

In `@fern/pages/cpp_api/cpp-api-neighbors-composite-index.md`:
- Line 16: The line ends with a dangling "Usage example:" but no example is
provided; either remove the "Usage example:" label or add a short concrete
example that demonstrates setting a stream pool on the input raft::resource for
a composite index search. To fix, update the paragraph for the composite index
description (reference: composite index and raft::resource) by either deleting
the "Usage example:" text or appending a concise usage snippet that shows
constructing an input raft::resource with a non-null stream_pool and invoking
the composite index search API so readers see how to enable parallel search
across sub-indices.

In `@fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md`:
- Line 60: Fix the typo in the documentation where "bach" is used instead of
"batch": update the phrase "prioritize one bach over the other" to "prioritize
one batch over the other" in the paragraph discussing Priority queues; ensure
the surrounding text mentioning the batcher, the single pool of queues, and
search_params::dispatch_timeout_ms remains unchanged so the explanation about
dispatch_timeout_ms aggregation and batching semantics is preserved.

In `@fern/pages/cpp_api/cpp-api-neighbors-ivf-pq.md`:
- Around line 1612-1613: Fix the two typos in the transform parameter docs:
change "populaterd" to "populated" in the `output_labels` description and remove
the extra closing bracket in the `output_dataset` shape expression so it reads a
device matrix view [n_rows, ceildiv(index.pq_dim() * index.pq_bits(), 8)] that
will get populated with the pq-encoded dataset; update the `output_labels` and
`output_dataset` lines accordingly (references: `output_labels`,
`output_dataset`, and `index.pq_dim()` / `index.pq_bits()`).

In `@fern/pages/cpp_api/cpp-api-neighbors-nn-descent.md`:
- Line 135: Update the compound adjective "user allocated" to "user-allocated"
in the constructor description that currently reads "user allocated host memory
knn-graph" so it becomes "user-allocated host memory knn-graph"; locate the
sentence in the nn-descent index constructor documentation (the paragraph
describing the knn-graph as "a dense raft::host_matrix and dimensions are
(n_rows, n_cols)") and apply the hyphen to the compound adjective.

In `@fern/pages/cpp_api/cpp-api-neighbors-vamana.md`:
- Line 336: Fix the spelling error "iserts" -> "inserts" wherever it appears in
the Vamana build description; specifically replace the phrase "iteratively
iserts batches of nodes" (and the same misspelling occurrences in subsequent
paragraphs) with "iteratively inserts batches of nodes" so the documentation for
the Vamana insertion-based algorithm reads correctly.

In `@fern/scripts/generate_api_reference.py`:
- Around line 3258-3263: The current if not line_text branch unconditionally
clears state and skips lines, causing blank lines inside Doxygen detail blocks
to be lost; change this so that when active_detail is True you preserve a
separator instead of dropping the line—append a blank-line marker (e.g., an
empty string or '\n') into the detail accumulation buffer used by the Doxygen
detail parser (referencing variables line_text, active_detail and the detail
buffer/collector in the same function in generate_api_reference.py) and
continue; for other states (active_param, active_summary, active_returns) keep
the existing behavior of resetting/continuing.

---

Outside diff comments:
In `@fern/scripts/generate_api_reference.py`:
- Around line 3867-3871: When constructing the DoxygenEntry for plain struct
members, don’t set signature to only c_type; store the full member declaration
so downstream type recovery can distinguish a field named the same as its type.
Update the DoxygenEntry creation where member = DoxygenEntry(...) to use the
complete declaration (the existing declaration variable) for signature (or
concatenate declaration and c_type if necessary) instead of just c_type, keeping
name as-is so functions/methods like DoxygenEntry.signature, the declaration
variable, and c_type are consistent for later type rendering.

---

Nitpick comments:
In `@fern/pages/c_api/c-api-neighbors-brute-force.md`:
- Line 73: Split the long run-on sentence into a short intro plus structured
bullet-like lines: state that the function builds a BRUTEFORCE index from a
DLManagedTensor, then list allowed DLDeviceType values (kDLCUDA, kDLCUDAHost,
kDLCUDAManaged, kDLCPU) on one line and list acceptable data-type conditions on
separate lines (kDLDataType.code == kDLFloat with bits == 32, and
kDLDataType.code == kDLFloat with bits == 16) so the constraints for
DLManagedTensor, DLDeviceType, and kDLDataType are clearly separated and easy to
scan.
- Line 102: Split the long single-paragraph description into clear bullet
points: one bullet listing allowed DLDeviceType values (DLManagedTensor with
DLDeviceType == kDLCUDA, kDLCUDAHost, kDLCUDAManaged), one bullet clarifying the
requirement that the BRUTEFORCE index must be built with the same query dtype
(compare index.dtype.code == queries.dl_tensor.dtype.code), and a final bullet
(or sub-bullets) enumerating input/output data-type constraints for queries,
neighbors, and distances (queries: kDLDataType.code == kDLFloat with
kDLDataType.bits == 32 or 16; neighbors: kDLDataType.code == kDLUInt and
kDLDataType.bits == 32; distances: kDLDataType.code == kDLFloat and
kDLDataType.bits == 32), using the symbols DLManagedTensor, queries, neighbors,
distances, and the kDL* constants to keep references clear.

In `@fern/pages/c_api/c-api-neighbors-ivf-pq.md`:
- Line 505: Change the compound modifier "PQ encoded vectors" to "PQ-encoded
vectors" in the documentation line that starts "Unpack `n_rows` consecutive PQ
encoded vectors of a single list (cluster)..." so it reads "Unpack `n_rows`
consecutive PQ-encoded vectors..."; keep the rest of the sentence intact
(including references to `offset`, `index.pq_dim()` and `index.pq_bits()`).

In `@fern/pages/c_api/c-api-neighbors-tiered-index.md`:
- Line 167: Split the long single-line description for TieredIndex into
structured bullet points mirroring the brute force API style: add a short intro
sentence referencing TieredIndex and DLManagedTensor, then a "Supported devices"
bullet listing DLDeviceType values (kDLCUDA, kDLCUDAHost, kDLCUDAManaged,
kDLCPU) and an "Acceptable data types" bullet with two sub-bullets for the float
formats (kDLDataType.code == kDLFloat and bits == 32; kDLDataType.code ==
kDLFloat and bits == 16); update the text mentioning DLManagedTensor and
DLDeviceType to use these bullets so the information is clearer and consistent
with the brute force docs.

In
`@fern/pages/cpp_api/cpp-api-common-types-copy-serialization-and-utility-apis.md`:
- Around line 7-8: The document currently jumps from the h1 title to h3 headings
like "### raft::copy"; add a new h2 section heading (for example "## RAFT
Utilities" or "## Core Utilities") immediately before the first h3 (the "###
raft::copy" anchor) to improve structure and follow Markdown hierarchy; ensure
the new h2 precedes other h3 subsections so headings descend H1 -> H2 -> H3.

In `@fern/pages/cpp_api/cpp-api-common-types-dense-array-views.md`:
- Around line 5-10: Add an h2 heading between the H1 "Dense Array Views" and the
existing H3 "raft::mdspan" to provide an intermediate section (e.g., "Core View
Types" or "Multi-dimensional Views"); update the markdown so the new heading is
a level-2 (##) line placed before the anchor/section for raft::mdspan, and
ensure any nearby anchors or links still point correctly to the raft::mdspan
subsection.

In `@fern/pages/cpp_api/cpp-api-common-types-dense-view-factories.md`:
- Around line 5-8: Add an intermediate h2 heading between the h1 "Dense View
Factories" and the existing h3 subsections (e.g., a descriptive h2 like "Factory
Functions" or "Overview of Dense View Factories") to restore proper heading
hierarchy; update the markdown near the h1 and before the
"raft::make_device_matrix_view" section so the page goes H1 -> H2 -> H3 and
ensure the new h2 is semantically appropriate for the group of functions such as
raft::make_device_matrix_view.

In `@fern/pages/cpp_api/cpp-api-common-types-errors-and-logging.md`:
- Around line 9-10: The document jumps from the top-level title straight to "###
raft::exception"; add an H2 section heading such as "## Error Handling" or "##
Error Handling and Logging APIs" immediately before the "### raft::exception"
subsection so the structure follows h1 → h2 → h3 hierarchy and improves
navigation; update the area around the "### raft::exception" anchor (a
id="raft-exception") to insert the new H2 heading while keeping the anchor and
subsequent "raft::exception" H3 unchanged.

In `@fern/pages/cpp_api/cpp-api-common-types-execution-resources.md`:
- Around line 5-10: Add an intermediate h2 heading beneath the main h1
"Execution Resources" to avoid jumping straight to h3s; insert a descriptive h2
(for example "Overview" or "Execution resources overview") directly before the
existing "### raft::resources" anchor so the document hierarchy is H1 -> H2 ->
H3, ensuring the section about raft::resources remains unchanged.

In `@fern/pages/cpp_api/cpp-api-common-types-layouts-and-extents.md`:
- Around line 5-10: The document jumps from the H1 "Layouts and Extents"
straight to H3 anchors like "raft::row_major"; add an H2 heading (e.g.,
"Overview" or "Layouts and Extents — Overview") immediately after the H1 and
before the <a id="raft-row-major"></a> anchor so the structure becomes H1 → H2 →
H3 and improves accessibility and TOC generation; update surrounding text to
briefly introduce raft layout and extent types under the new H2.

In `@fern/pages/cpp_api/cpp-api-common-types-owning-array-factories.md`:
- Around line 5-8: The document currently jumps from the H1 "Owning Array
Factories" directly to H3 entries like "raft::make_device_matrix"; insert an H2
intermediary (e.g., "Overview" or "Factories") between the H1 and the existing
H3s to restore proper heading hierarchy and accessibility, update the section
anchor if needed (reference: raft::make_device_matrix) and ensure the new H2
appears before the existing H3 subsections.

In `@fern/pages/cpp_api/cpp-api-common-types-owning-dense-arrays.md`:
- Around line 5-10: Add an intermediate h2 heading between the existing H1
"Owning Dense Arrays" and the H3 "raft::mdarray" to restore proper heading
hierarchy; update the markdown near the top of the file (around the H1 and the
"raft::mdarray" subsection) to insert a descriptive H2 such as "Overview" or
"Contents" so the structure becomes H1 -> H2 -> H3 (raft::mdarray).

In `@fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md`:
- Line 10: The heading for the top-level API entity "raft::device_csr_matrix" is
currently an h3 ("### raft::device_csr_matrix") and should be promoted to an h2
to maintain proper heading hierarchy; update the heading to "##
raft::device_csr_matrix" (and scan other top-level API entities in this file to
ensure they also use h2 instead of h3 where appropriate) so documentation
generators and TOC navigation work correctly.

In `@fern/pages/cpp_api/cpp-api-distance-distance.md`:
- Line 144: The line containing the sentence "Note: Only contiguous row- or
column-major layouts supported currently. Usage example:" reads awkwardly;
update each occurrence so the note and the "Usage example:" marker are separated
(e.g., put the note on its own sentence/line and follow with a separate "Usage
example:" heading) or remove the trailing "Usage example:" if there is no
example following it; ensure you update all occurrences of that exact sentence
in cpp-api-distance-distance.md so the note is clear and properly separated from
the usage marker.

In `@fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md`:
- Line 60: Split the single long paragraph describing
neighbors::dynamic_batching::index into multiple paragraphs/subsections: keep
the main concept and lightweight/shared-pointer design in the first paragraph,
move the priority/queue behavior and search_params::dispatch_timeout_ms
aggregation into a separate "Priority queues" paragraph, and put the example
about constructing one batching index per priority class into a distinct "Usage
example" paragraph; ensure references to the dynamic batching index and
search_params::dispatch_timeout_ms remain intact so readers can locate the
details.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: b722d2de-48ef-411c-9d9f-06e6cddfd180

📥 Commits

Reviewing files that changed from the base of the PR and between f1bfe59 and 67c7c85.

📒 Files selected for processing (100)
  • fern/docs.yml
  • fern/pages/api_guide.md
  • fern/pages/c_api/c-api-cluster-kmeans.md
  • fern/pages/c_api/c-api-core-c-api.md
  • fern/pages/c_api/c-api-distance-distance.md
  • fern/pages/c_api/c-api-neighbors-all-neighbors.md
  • fern/pages/c_api/c-api-neighbors-brute-force.md
  • fern/pages/c_api/c-api-neighbors-cagra.md
  • fern/pages/c_api/c-api-neighbors-common.md
  • fern/pages/c_api/c-api-neighbors-hnsw.md
  • fern/pages/c_api/c-api-neighbors-ivf-flat.md
  • fern/pages/c_api/c-api-neighbors-ivf-pq.md
  • fern/pages/c_api/c-api-neighbors-mg-cagra.md
  • fern/pages/c_api/c-api-neighbors-mg-common.md
  • fern/pages/c_api/c-api-neighbors-mg-ivf-flat.md
  • fern/pages/c_api/c-api-neighbors-mg-ivf-pq.md
  • fern/pages/c_api/c-api-neighbors-nn-descent.md
  • fern/pages/c_api/c-api-neighbors-tiered-index.md
  • fern/pages/c_api/c-api-neighbors-vamana.md
  • fern/pages/c_api/c-api-preprocessing-pca.md
  • fern/pages/c_api/c-api-preprocessing-quantize-binary.md
  • fern/pages/c_api/c-api-preprocessing-quantize-pq.md
  • fern/pages/c_api/c-api-preprocessing-quantize-scalar.md
  • fern/pages/c_api/index.md
  • fern/pages/core_types.md
  • fern/pages/cpp_api/cpp-api-cluster-agglomerative.md
  • fern/pages/cpp_api/cpp-api-cluster-kmeans.md
  • fern/pages/cpp_api/cpp-api-cluster-spectral.md
  • fern/pages/cpp_api/cpp-api-common-types-copy-serialization-and-utility-apis.md
  • fern/pages/cpp_api/cpp-api-common-types-dense-array-views.md
  • fern/pages/cpp_api/cpp-api-common-types-dense-view-factories.md
  • fern/pages/cpp_api/cpp-api-common-types-errors-and-logging.md
  • fern/pages/cpp_api/cpp-api-common-types-execution-resources.md
  • fern/pages/cpp_api/cpp-api-common-types-layouts-and-extents.md
  • fern/pages/cpp_api/cpp-api-common-types-owning-array-factories.md
  • fern/pages/cpp_api/cpp-api-common-types-owning-dense-arrays.md
  • fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md
  • fern/pages/cpp_api/cpp-api-common-types.md
  • fern/pages/cpp_api/cpp-api-distance-distance.md
  • fern/pages/cpp_api/cpp-api-distance-grammian.md
  • fern/pages/cpp_api/cpp-api-neighbors-all-neighbors.md
  • fern/pages/cpp_api/cpp-api-neighbors-ball-cover.md
  • fern/pages/cpp_api/cpp-api-neighbors-brute-force.md
  • fern/pages/cpp_api/cpp-api-neighbors-cagra.md
  • fern/pages/cpp_api/cpp-api-neighbors-common.md
  • fern/pages/cpp_api/cpp-api-neighbors-composite-index.md
  • fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md
  • fern/pages/cpp_api/cpp-api-neighbors-epsilon-neighborhood.md
  • fern/pages/cpp_api/cpp-api-neighbors-hnsw.md
  • fern/pages/cpp_api/cpp-api-neighbors-ivf-flat.md
  • fern/pages/cpp_api/cpp-api-neighbors-ivf-pq.md
  • fern/pages/cpp_api/cpp-api-neighbors-nn-descent.md
  • fern/pages/cpp_api/cpp-api-neighbors-refine.md
  • fern/pages/cpp_api/cpp-api-neighbors-scann.md
  • fern/pages/cpp_api/cpp-api-neighbors-tiered-index.md
  • fern/pages/cpp_api/cpp-api-neighbors-vamana.md
  • fern/pages/cpp_api/cpp-api-preprocessing-pca.md
  • fern/pages/cpp_api/cpp-api-preprocessing-quantize-binary.md
  • fern/pages/cpp_api/cpp-api-preprocessing-quantize-pq.md
  • fern/pages/cpp_api/cpp-api-preprocessing-quantize-scalar.md
  • fern/pages/cpp_api/cpp-api-preprocessing-spectral-embedding.md
  • fern/pages/cpp_api/cpp-api-selection-select-k.md
  • fern/pages/cpp_api/cpp-api-stats-silhouette-score.md
  • fern/pages/cpp_api/cpp-api-stats-trustworthiness-score.md
  • fern/pages/cpp_api/cpp-api-util-cutlass-utils.md
  • fern/pages/cpp_api/cpp-api-util-file-io.md
  • fern/pages/cpp_api/index.md
  • fern/pages/go_api/go-api-brute-force.md
  • fern/pages/go_api/go-api-cagra.md
  • fern/pages/go_api/go-api-cuvs.md
  • fern/pages/go_api/go-api-ivf-flat.md
  • fern/pages/go_api/go-api-ivf-pq.md
  • fern/pages/go_api/index.md
  • fern/pages/index.md
  • fern/pages/java_api/index.md
  • fern/pages/other/multidimensional_arrays.md
  • fern/pages/other/sparse_arrays.md
  • fern/pages/rust_api/index.md
  • fern/pages/rust_api/rust-api-cuvs-brute-force.md
  • fern/pages/rust_api/rust-api-cuvs-cagra-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-cagra-index.md
  • fern/pages/rust_api/rust-api-cuvs-cagra-search-params.md
  • fern/pages/rust_api/rust-api-cuvs-cagra.md
  • fern/pages/rust_api/rust-api-cuvs-cluster-kmeans-params.md
  • fern/pages/rust_api/rust-api-cuvs-cluster-kmeans.md
  • fern/pages/rust_api/rust-api-cuvs-distance.md
  • fern/pages/rust_api/rust-api-cuvs-dlpack.md
  • fern/pages/rust_api/rust-api-cuvs-error.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-index.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-search-params.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-pq-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-pq-index.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-pq-search-params.md
  • fern/pages/rust_api/rust-api-cuvs-resources.md
  • fern/pages/rust_api/rust-api-cuvs-vamana-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-vamana-index.md
  • fern/pages/rust_api/rust-api-cuvs.md
  • fern/pages/user_guide.md
  • fern/scripts/generate_api_reference.py
💤 Files with no reviewable changes (1)
  • fern/pages/other/sparse_arrays.md
✅ Files skipped from review due to trivial changes (48)
  • fern/pages/cpp_api/cpp-api-neighbors-epsilon-neighborhood.md
  • fern/pages/c_api/c-api-distance-distance.md
  • fern/pages/cpp_api/cpp-api-neighbors-tiered-index.md
  • fern/pages/cpp_api/cpp-api-common-types.md
  • fern/pages/go_api/go-api-brute-force.md
  • fern/pages/c_api/c-api-neighbors-common.md
  • fern/pages/cpp_api/cpp-api-util-cutlass-utils.md
  • fern/pages/rust_api/index.md
  • fern/pages/cpp_api/cpp-api-stats-trustworthiness-score.md
  • fern/pages/c_api/c-api-neighbors-mg-common.md
  • fern/pages/cpp_api/cpp-api-selection-select-k.md
  • fern/pages/go_api/go-api-ivf-pq.md
  • fern/pages/cpp_api/cpp-api-util-file-io.md
  • fern/pages/rust_api/rust-api-cuvs-error.md
  • fern/pages/c_api/c-api-neighbors-mg-ivf-pq.md
  • fern/pages/go_api/go-api-ivf-flat.md
  • fern/pages/java_api/index.md
  • fern/pages/cpp_api/index.md
  • fern/pages/rust_api/rust-api-cuvs-cluster-kmeans.md
  • fern/pages/c_api/c-api-neighbors-all-neighbors.md
  • fern/pages/c_api/c-api-preprocessing-quantize-binary.md
  • fern/pages/go_api/go-api-cuvs.md
  • fern/pages/rust_api/rust-api-cuvs-brute-force.md
  • fern/pages/go_api/index.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-index.md
  • fern/pages/c_api/c-api-neighbors-ivf-flat.md
  • fern/pages/cpp_api/cpp-api-preprocessing-quantize-scalar.md
  • fern/pages/index.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-distance.md
  • fern/pages/rust_api/rust-api-cuvs-vamana-index-params.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-pq-index.md
  • fern/pages/cpp_api/cpp-api-stats-silhouette-score.md
  • fern/pages/api_guide.md
  • fern/pages/rust_api/rust-api-cuvs-resources.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-pq-search-params.md
  • fern/pages/rust_api/rust-api-cuvs-dlpack.md
  • fern/pages/c_api/c-api-neighbors-nn-descent.md
  • fern/pages/cpp_api/cpp-api-neighbors-refine.md
  • fern/pages/go_api/go-api-cagra.md
  • fern/pages/cpp_api/cpp-api-neighbors-brute-force.md
  • fern/pages/cpp_api/cpp-api-neighbors-all-neighbors.md
  • fern/pages/rust_api/rust-api-cuvs-ivf-flat-search-params.md
  • fern/pages/c_api/index.md
  • fern/pages/rust_api/rust-api-cuvs-cluster-kmeans-params.md
  • fern/pages/rust_api/rust-api-cuvs-cagra-index.md
  • fern/pages/cpp_api/cpp-api-cluster-agglomerative.md
  • fern/pages/rust_api/rust-api-cuvs-cagra-index-params.md
🚧 Files skipped from review as they are similar to previous changes (3)
  • fern/pages/core_types.md
  • fern/pages/user_guide.md
  • fern/pages/other/multidimensional_arrays.md

Comment thread fern/pages/c_api/c-api-neighbors-vamana.md Outdated
Comment thread fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md
Comment thread fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md
Comment thread fern/pages/cpp_api/cpp-api-common-types-sparse-array-types.md
Comment thread fern/pages/cpp_api/cpp-api-distance-grammian.md Outdated
Comment thread fern/pages/cpp_api/cpp-api-neighbors-dynamic-batching.md Outdated
Comment thread fern/pages/cpp_api/cpp-api-neighbors-ivf-pq.md
Comment thread fern/pages/cpp_api/cpp-api-neighbors-nn-descent.md
Comment thread fern/pages/cpp_api/cpp-api-neighbors-vamana.md Outdated
Comment thread fern/scripts/generate_api_reference.py
@cjnolet

cjnolet commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test d26722c

@cjnolet

cjnolet commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test 0983050

@cjnolet

cjnolet commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

/merge

@rapids-bot rapids-bot Bot merged commit 31bc597 into NVIDIA:release/26.06 May 27, 2026
56 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Unstructured Data Processing May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc Improvements or additions to documentation non-breaking Introduces a non-breaking change

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants