Skip to content

feat(commitment-tree): add cv_net to the stored note item for OVK recovery - #761

Merged
QuantumExplorer merged 6 commits into
developfrom
claude/xenodochial-thompson-53e87d
Jun 8, 2026
Merged

feat(commitment-tree): add cv_net to the stored note item for OVK recovery#761
QuantumExplorer merged 6 commits into
developfrom
claude/xenodochial-thompson-53e87d

Conversation

@QuantumExplorer

@QuantumExplorer QuantumExplorer commented Jun 8, 2026

Copy link
Copy Markdown
Member

Summary

Dash Platform's shielded pool stores each Orchard note's scanning data in the commitment-tree item so light wallets can retrieve it. The item held cmx ‖ rho ‖ payload but omitted the note's value commitment cv_net (32 bytes). cv_net is required for outgoing-note (OVK) recovery — it is an input to Orchard's derive_ock(ovk, cv, cmx, epk) key that decrypts out_ciphertext, and it cannot be recomputed from the note.

This inserts cv_net as a new unencrypted protocol-level field between rho and the ciphertext payload, exactly as rho already sits between cmx and the payload:

old: cmx(32) ‖ rho(32) ‖ payload                 (280 B for DashMemo)
new: cmx(32) ‖ rho(32) ‖ cv_net(32) ‖ payload    (312 B for DashMemo)

API changes (grovedb-commitment-tree)

  • CommitmentTree::append / append_raw gain a cv_net: [u8; 32] param.
  • append_many_raw entries become (cmx, rho, cv_net, payload) 4-tuples.
  • The 216-byte ciphertext payload-size check is unchanged; cv_net is validated by its [u8; 32] type.
  • Threaded through grovedb's commitment_tree_insert{,_raw}, the batch op GroveOp::CommitmentTreeInsert (gains cv_net), op builders, batch execution, and estimated costs.

Safety: the Orchard anchor is unchanged

The Sinsemilla frontier (commitment_frontier) is deliberately untouched — it only ever sees cmx and produces the Orchard anchor. cv_net never enters it. For any fixed cmx sequence the anchor (against which existing zk spend proofs verify cmx-membership) is byte-for-byte identical.

New tests lock this in:

  • append_does_not_change_sinsemilla_anchor — for a fixed cmx vector, asserts the tree root equals (a) a pure CommitmentFrontier built from cmx-only, and (b) a hard-coded pinned anchor constant.
  • append_preserves_cv_net_and_ciphertext_at_fixed_offsets — round-trips a note, asserting cv_net at [64..96] and the ciphertext deserializing from [96..].

Client side

No change needed — the client ShardTree (memory + sqlite) stores only cmx for witness generation and does not mirror the note item, so there is no client-side layout to update. Verified.

⚠️ Breaking

The BulkAppendTree (item-data) state root changes, so consumers must rebuild state — there is no in-place migration. The Orchard anchor is unchanged. Platform's shielded pool is pre-release, so this is acceptable.

Verification

  • cargo test -p grovedb-commitment-tree --features server,sqlite → 110 passed, 0 failed
  • grovedb commitment-tree integration tests (incl. batch / proof / delete) → all green
  • cargo build --workspace --all-targets + server-gated bench → clean
  • cargo fmt --check → clean

🤖 Generated with Claude Code

Summary by CodeRabbit

Release Notes

  • New Features

    • Commitment tree entries now include an additional value commitment field, increasing record size from 280 to 312 bytes per entry.
  • Documentation

    • Updated commitment tree technical documentation across multiple language versions to reflect the new field addition in operation signatures and data layouts.

…overy

The shielded-pool note item stored cmx ‖ rho ‖ payload, omitting the note's
value commitment cv_net. cv_net (32 bytes) is required for outgoing-note (OVK)
recovery — it is an input to Orchard's derive_ock(ovk, cv, cmx, epk) key that
decrypts out_ciphertext, and it cannot be recomputed from the note.

Insert cv_net as a new unencrypted protocol-level field between rho and the
ciphertext payload, exactly as rho already sits between cmx and the payload:

  new item = cmx(32) ‖ rho(32) ‖ cv_net(32) ‖ payload   (312 B for DashMemo)

API changes (grovedb-commitment-tree):
- CommitmentTree::append / append_raw gain a cv_net: [u8; 32] param.
- append_many_raw entries become (cmx, rho, cv_net, payload) 4-tuples.
- Item layout, payload-size check, and docs updated. The 216-byte ciphertext
  check is unchanged; cv_net is validated by its [u8; 32] type.

The Sinsemilla frontier (commitment_frontier) is deliberately untouched: it only
ever sees cmx and produces the Orchard anchor. cv_net never enters it, so for any
fixed cmx sequence the anchor — against which existing zk spend proofs verify
cmx-membership — is byte-for-byte identical. A new pinned-anchor test locks this
in, alongside a cv_net round-trip test (cv_net at [64..96], ciphertext from [96..]).

Threaded through grovedb's CommitmentTree ops + batch op (GroveOp::
CommitmentTreeInsert gains cv_net), op builders, execution, and estimated costs.

BREAKING: the BulkAppendTree (item-data) state root changes, so consumers must
rebuild state — no in-place migration. The Orchard anchor is unchanged. Platform's
shielded pool is pre-release, so this is acceptable.

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

coderabbitai Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Warning

Review limit reached

@QuantumExplorer, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 16 minutes and 56 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d5699569-36ef-44e1-9188-bcb0b74e2a55

📥 Commits

Reviewing files that changed from the base of the PR and between 1b908b8 and 1982b65.

📒 Files selected for processing (7)
  • docs/book/translations/ar/src/element-system.md
  • docs/book/translations/cs/src/quantum-cryptography.md
  • docs/book/translations/fr/src/element-system.md
  • docs/book/translations/id/src/quantum-cryptography.md
  • docs/book/translations/pl/src/quantum-cryptography.md
  • docs/book/translations/pt/src/element-system.md
  • docs/book/translations/pt/src/quantum-cryptography.md
📝 Walkthrough

Walkthrough

Docs, APIs, and implementation now carry cv_net through CommitmentTree insert, batch preprocessing, stored-record layout, retrieval, and test coverage. The persisted record size and offsets change, and all documented examples are updated to the new field order.

Changes

CommitmentTree cv_net propagation

Layer / File(s) Summary
Public surface and docs contracts
docs/book/src/*, docs/book/translations/*/src/batch-operations.md, docs/book/translations/*/src/element-system.md
CommitmentTreeInsert and commitment_tree_insert descriptions add cv_net, and the translated docs mirror the same field and parameter updates.
Storage layout and record reads
docs/book/src/commitment-tree.md, docs/book/src/quantum-cryptography.md, docs/book/translations/*/src/commitment-tree.md, docs/book/translations/*/src/quantum-cryptography.md
The stored CommitmentTree record layout adds cv_net, DashMemo sizing changes to 312 bytes, and read/decrypt/proof descriptions are updated to the new tuple shapes.
Append path and batch preprocessing
grovedb/src/operations/commitment_tree.rs, grovedb/src/batch/mod.rs, grovedb/src/batch/estimated_costs/*, grovedb/src/tests/batch_*
The insert path and batch execution now pass cv_net through append_raw, GroveOp::CommitmentTreeInsert, and related cost/test coverage.
CommitmentTree core library
grovedb-commitment-tree/src/commitment_tree/mod.rs, grovedb-commitment-tree/src/lib.rs, grovedb-commitment-tree/benches/seeding.rs
The commitment-tree crate introduces CommitmentEntry, expands append APIs to require cv_net, and updates the bench seeding data shape.
CommitmentTree tests
grovedb-commitment-tree/src/commitment_tree/tests.rs, grovedb/src/tests/commitment_tree_tests.rs, grovedb/src/tests/proof_coverage_tests.rs
CommitmentTree tests add deterministic cv_net helpers, update append call sites, and validate the expanded stored-byte layout and proof expectations.

Sequence Diagram(s)

sequenceDiagram
  participant GroveDb
  participant CommitmentTree
  participant BulkAppendTree
  participant CommitmentFrontier
  GroveDb->>CommitmentTree: commitment_tree_insert(..., cv_net, ...)
  CommitmentTree->>BulkAppendTree: append cmx||rho||cv_net||ciphertext
  CommitmentTree->>CommitmentFrontier: append cmx
  CommitmentFrontier-->>GroveDb: updated anchor/root
Loading

Estimated Code Review Effort

🎯 5 (Critical) | ⏱️ ~90+ minutes

Possibly related PRs

  • dashpay/grovedb#751: Both PRs touch the CommitmentTree batch append path and append_many_raw-style leaf handling in grovedb-commitment-tree/src/commitment_tree/mod.rs.
  • dashpay/grovedb#638: Both PRs modify the CommitmentTree preprocessing and batching flow in grovedb/src/operations/commitment_tree.rs and related batch execution paths.

Suggested reviewers

  • shumkov

Poem

A bunny hops by moonlit byte,
With cv_net tucked in tight and right.
The tree grew leaves, the anchors sang,
And buffer keys went clap and clang.
🐇✨

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/xenodochial-thompson-53e87d

@QuantumExplorer QuantumExplorer left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Reviewed

Sync the mdBook English source with the cv_net addition:

- commitment-tree.md: stored-record layout (280 → 312 B, cv_net at offset 64),
  field-by-field breakdown for cv_net (incl. the OVK/ock derivation rationale),
  insert/append API signatures, batch op variant + constructors, get_value /
  preprocessing / proof-item layouts, size-comparison and trial-decryption flow.
- element-system.md: note-data layout + commitment_tree_insert signature.
- batch-operations.md: GroveOp::CommitmentTreeInsert variant fields.
- quantum-cryptography.md: stored-record read + post-quantum size estimates
  rebased on the 312-byte record.

Docs-only; English source. Translations were intentionally left untouched.

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

thepastaclaw commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

✅ Review complete (commit c2c5729)

@thepastaclaw thepastaclaw left a comment

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.

Code Review

The PR correctly threads cv_net through the Rust implementation and tests without an in-scope blocking correctness issue. Two in-scope suggestions remain: the checked-in translated book pages still document the old 280-byte layout, and the new raw batch API exposes three adjacent [u8; 32] fields that can be silently misordered by callers.

🟡 2 suggestion(s)

1 additional finding(s) omitted (not in diff).

🤖 Prompt for all review comments with AI agents
These findings are from an automated code review. Verify each finding against the current code and only fix it if needed.

In `docs/book/translations/es/src/commitment-tree.md`:
- [SUGGESTION] docs/book/translations/es/src/commitment-tree.md:521-536: Update translated commitment-tree docs for the new record layout
  The English commitment-tree page now documents the stored item as `cmx || rho || cv_net || payload`, with `cv_net` at `[64..96]` and DashMemo records totaling 312 bytes, but the checked-in translated books still publish the old 280-byte layout and place `epk_bytes` at offset 64. These translation directories are built by the book CI, and the same stale API examples/layout text appears across the translated `commitment-tree.md` files, so non-English docs would tell consumers to deserialize the ciphertext from the wrong offset and omit the `cv_net` field required for OVK recovery. Update or regenerate the translated commitment-tree pages as part of this layout/API change.

In `grovedb-commitment-tree/src/commitment_tree/mod.rs`:
- [SUGGESTION] grovedb-commitment-tree/src/commitment_tree/mod.rs:397-402: Use a named raw entry type for batched commitment inserts
  `append_many_raw` now accepts entries as `([u8; 32], [u8; 32], [u8; 32], Vec<u8>)`, which puts `cmx`, `rho`, and `cv_net` next to each other with identical Rust types. A caller that swaps `rho` and `cv_net` will still compile and still produce an internally consistent tree, but the stored metadata will be wrong for nullifier association and OVK recovery. A small named raw-entry struct, or domain newtypes for these 32-byte fields, would make the new public batch boundary preserve the protocol meaning instead of relying on tuple position.

Comment thread grovedb-commitment-tree/src/commitment_tree/mod.rs Outdated
QuantumExplorer and others added 2 commits June 9, 2026 00:35
Address review feedback (thepastaclaw): the batch API took entries as
`([u8; 32], [u8; 32], [u8; 32], Vec<u8>)`, putting the three type-identical
32-byte protocol fields (cmx, rho, cv_net) adjacent and positional. A caller
that transposed rho and cv_net would still compile and build an internally
consistent tree while silently corrupting nullifier association and OVK
recovery.

Replace the tuple with a named `CommitmentEntry { cmx, rho, cv_net, payload }`
struct so the public batch boundary preserves protocol meaning by field name
rather than tuple position. Update `append_many_raw`, re-export the struct,
and update the bench + crate-test callers.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Address review feedback (thepastaclaw): the checked-in translated books still
documented the old 280-byte item layout (epk_bytes at offset 64), so non-English
readers would deserialize the ciphertext from the wrong offset and miss the
cv_net field required for OVK recovery.

Apply the same language-neutral corrections made to the English source across
all 16 translations (commitment-tree, element-system, batch-operations,
quantum-cryptography): stored-record layout/offset tables (280 → 312 B, cv_net
at [64..96]), API signatures, the GroveOp::CommitmentTreeInsert variant + op
constructors, record-read flows, size-comparison totals, and the post-quantum
size box. The byte offsets, code blocks, layout strings, and signatures are
byte-identical English across translations; translated explanatory prose (the
new cv_net field description) is left for the localization pass.

All 16 translated books build cleanly via build-translations.sh.

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

Copy link
Copy Markdown
Member Author

This is Claude — both in-scope suggestions from the review are addressed:

1. Named raw entry type for batched inserts (dc63c88f)
append_many_raw no longer takes a bare ([u8; 32], [u8; 32], [u8; 32], Vec<u8>) tuple. It now takes CommitmentEntry { cmx, rho, cv_net, payload } (re-exported from the crate root), so the three adjacent, type-identical 32-byte protocol fields are named at the public batch boundary — a rho/cv_net transposition can no longer compile silently. Bench + crate tests updated; 109/109 crate tests pass.

2. Stale translated commitment-tree docs (1b908b8f)
Synced the cv_net layout into all 16 translated books, not just commitment-tree.md but also element-system.md, batch-operations.md, and quantum-cryptography.md. The byte-offset tables (280 → 312 B, cv_net at [64..96]), API signatures, the GroveOp::CommitmentTreeInsert variant + op constructors, record-read flows, size-comparison totals, and the post-quantum size box are all corrected — these are byte-identical English across translations, so no consumer is told to deserialize from the wrong offset anymore. The new explanatory prose for the cv_net field is left in English-only for the localization pass (the translated prose is otherwise unchanged). All 16 translated books build cleanly via build-translations.sh.

The third finding was flagged as "not in diff," so I have not acted on it — happy to look if you can point me at it.

Branch tip is now 1b908b8f.

@coderabbitai coderabbitai Bot left a comment

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.

Actionable comments posted: 8

Caution

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

⚠️ Outside diff range comments (6)
docs/book/translations/es/src/commitment-tree.md (2)

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

Update stored-value tuple to include cv_net.

Line 406 still documents cmx || rho || carga util; it should include cv_net to match the new record format (cmx || rho || cv_net || payload).

🤖 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 `@docs/book/translations/es/src/commitment-tree.md` at line 406, Update the
documented stored-value tuple text to reflect the new record format by including
cv_net: change the phrase listing "cmx || rho || carga util" to "cmx || rho ||
cv_net || payload" (or the Spanish equivalent "cmx || rho || cv_net || carga
útil") so the documentation matches the updated stored-value tuple fields
(`cmx`, `rho`, `cv_net`, `payload`).

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

V1 proof item tuple is stale (missing cv_net).

Line 876 still says cmx || rho || carga util; this conflicts with the updated stored-record contract and can mislead proof consumers.

🤖 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 `@docs/book/translations/es/src/commitment-tree.md` at line 876, The line
listing V1 proof item tuple is outdated: replace "cmx || rho || carga util" with
the full tuple including the new field "cv_net" (e.g., "cmx || rho || carga util
|| cv_net") so the documentation matches the updated stored-record contract and
avoids misleading proof consumers.
docs/book/translations/fr/src/commitment-tree.md (2)

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

V1 item tuple must include cv_net.

Line 878 documents cmx || rho || charge utile, which now conflicts with the record schema used elsewhere in this chapter.

🤖 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 `@docs/book/translations/fr/src/commitment-tree.md` at line 878, The
documentation line listing tuple fields is missing the required `cv_net` field
for V1 item tuples; update the sentence that currently reads "cmx || rho ||
charge utile" to include `cv_net` (e.g., "cmx || rho || cv_net || charge utile")
so it matches the record schema used elsewhere in this chapter and the V1 item
tuple definition.

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

Stored value description is outdated (missing cv_net).

Line 405 still says cmx || rho || charge utile; it should be cmx || rho || cv_net || payload to match the updated storage format.

🤖 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 `@docs/book/translations/fr/src/commitment-tree.md` at line 405, Update the
stored-value description phrase so it reflects the new storage format: replace
the fragment "cmx || rho || charge utile" with "cmx || rho || cv_net || payload"
(or in French "cmx || rho || cv_net || charge utile") so the documentation now
lists cmx, rho, cv_net and payload explicitly; locate the sentence containing
the symbols cmx, rho and charge utile in commitment-tree.md and adjust the
wording accordingly.
docs/book/translations/id/src/quantum-cryptography.md (1)

278-283: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Align hybrid-size column header with the documented 1,432-byte layout.

The table header uses Hibrid (1.400 B), but this section defines hybrid records as 1,432 bytes (Lines 262 and 272). Please make the header consistent to avoid calculation ambiguity.

Suggested doc fix
-| Notes | Saat ini (312 B) | Hibrid (1.400 B) | Delta |
+| Notes | Saat ini (312 B) | Hibrid (1.432 B) | Delta |
🤖 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 `@docs/book/translations/id/src/quantum-cryptography.md` around lines 278 -
283, The table header currently reads "Hibrid (1.400 B)" but hybrid records are
defined elsewhere as 1,432 bytes; update the header text to "Hibrid (1.432 B)"
and then verify and correct the table values (columns for Hibrid and Delta) so
they reflect calculations using 1,432 bytes per record; look for the table row
containing "| 100.000 | 26,7 MB | 133 MB | +106 MB |" and the header text
"Hibrid (1.400 B)" to make the edits.
docs/book/translations/vi/src/commitment-tree.md (1)

365-370: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

GroveOp::CommitmentTreeInsert snippet is missing cv_net field.

This block still documents { cmx, rho, payload }, but the same file now uses constructors and preprocess tuples that require cv_net, so the API description is inconsistent.

Suggested doc fix
 GroveOp::CommitmentTreeInsert {
     cmx: [u8; 32],      // cam kết note đã trích xuất
     rho: [u8; 32],      // nullifier của note đã chi tiêu
+    cv_net: [u8; 32],   // value commitment (for outgoing/OVK recovery)
     payload: Vec<u8>,    // ciphertext tuần tự hóa (216 byte cho DashMemo)
 }
🤖 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 `@docs/book/translations/vi/src/commitment-tree.md` around lines 365 - 370, The
documentation for GroveOp::CommitmentTreeInsert is missing the cv_net field;
update the snippet and surrounding docs to include cv_net (e.g., add "cv_net:
[u8; 32]" to the documented structure) so it matches the constructors and
preprocess tuples that expect cv_net; ensure any explanatory text references
cv_net's purpose consistently with the code paths that construct
GroveOp::CommitmentTreeInsert.
🤖 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 `@docs/book/translations/ar/src/element-system.md`:
- Around line 287-291: Reword the awkward Arabic phrase around "يتدفق كتجزئة
Merk الابن" to a more idiomatic construction in the architecture bullet: keep
the same technical references (BulkAppendTree, Platform, Sinsemilla, GroveDB)
but replace that fragment with a clearer phrasing such as "يُمثّل كتجزئة ابن في
تسلسل تجزئة GroveDB" or "يُخزّن/يُمرّر كتجزئة ابن عبر تسلسل تجزئة GroveDB" so
the sentence reads smoothly and preserves the intended meaning.

In `@docs/book/translations/cs/src/quantum-cryptography.md`:
- Line 277: Update the table header string that currently reads "| Notes |
Soucasne (312 B) | Hybridni (1 400 B) | Delta |" to match the computed per-note
value "1,432 bytes" used elsewhere (and in the diagram); change "Hybridni (1 400
B)" to "Hybridni (1 432 B)" so the displayed header aligns with the computed
1,432 B value.

In `@docs/book/translations/fr/src/element-system.md`:
- Line 287: The sentence "Les données réelles des notes (`cmx || rho || cv_net
|| ciphertext`) sont stockées via un **BulkAppendTree**" uses an inconsistent
apostrophe character in the prose; update the prose to use the document's
standard French apostrophe (typographic right single quote ’) while leaving the
code span (`cmx || rho || cv_net || ciphertext`) and the bold token
(**BulkAppendTree**) unchanged so only the surrounding plain-text apostrophe
characters are normalized.

In `@docs/book/translations/pl/src/quantum-cryptography.md`:
- Line 279: The storage table header currently shows "Hybrydowe (1 400 B)" while
the content uses "1,432 bytes" in the same section; pick one canonical
representation (either "1 432 B" to match Polish spacing or "1,432 bytes") and
update the header string "Hybrydowe (1 400 B)" and the two in-section
occurrences of "1,432 bytes" so they all match exactly, keeping the chosen
numeric value and formatting consistent across the table and surrounding text.

In `@docs/book/translations/pt/src/element-system.md`:
- Line 289: Fix the Portuguese accenting: update the sentence containing
"Ancoras historicas sao rastreadas pela Platform em uma arvore provavel
separada" by correcting "arvore" to "árvore" (and, if present, consider adding
accents to other words like "Ancoras" -> "Âncoras" and "historicas" ->
"históricas" for full correctness) so the line reads with proper accents.

In `@docs/book/translations/pt/src/quantum-cryptography.md`:
- Line 285: Update the table header string "Notas | Atual (312 B) | Híbrido
(1.400 B) | Delta" so the hybrid size matches the rest of the section: replace
"Híbrido (1.400 B)" with "Híbrido (1.432 B)" (to match the "1,432 bytes" value
and the totals/deltas). Ensure any other occurrences of "1.400 B" in this
section are updated to "1.432 B" for consistency.

In `@docs/book/translations/vi/src/quantum-cryptography.md`:
- Around line 219-223: The table's "Lai (1,432 B)" column and the "Chênh lệch"
column must be recomputed to use exactly 1,432 bytes per note: for each row
compute hybrid_size = count * 1,432 bytes, convert to human-readable units (use
same units style as existing rows: MB for ~10^6, GB for ~10^9, round to two
decimal places or match existing precision), then set delta = hybrid_size -
current_size (show as +/− and use same unit as hybrid column); update the three
rows for counts 100,000, 1,000,000, and 10,000,000 accordingly so the table is
internally consistent and formatted like the other rows.

In `@docs/book/translations/zh/src/quantum-cryptography.md`:
- Around line 255-259: The storage-size table in the markdown (the rows starting
with "| 票据数量 | 当前(312 B)...") mixes decimal MB/GB labels with values that appear
to be binary MiB/GiB; update the table so units are consistent: either relabel
the headers to "MiB/GiB" if the numbers are binary, or recompute each cell to
decimal "MB/GB" (e.g., use 1 MB = 1,000,000 B) and replace the values
accordingly; ensure the header text "(312 B)" and the column headings reflect
the chosen unit system so readers aren’t misled.

---

Outside diff comments:
In `@docs/book/translations/es/src/commitment-tree.md`:
- Line 406: Update the documented stored-value tuple text to reflect the new
record format by including cv_net: change the phrase listing "cmx || rho ||
carga util" to "cmx || rho || cv_net || payload" (or the Spanish equivalent "cmx
|| rho || cv_net || carga útil") so the documentation matches the updated
stored-value tuple fields (`cmx`, `rho`, `cv_net`, `payload`).
- Line 876: The line listing V1 proof item tuple is outdated: replace "cmx ||
rho || carga util" with the full tuple including the new field "cv_net" (e.g.,
"cmx || rho || carga util || cv_net") so the documentation matches the updated
stored-record contract and avoids misleading proof consumers.

In `@docs/book/translations/fr/src/commitment-tree.md`:
- Line 878: The documentation line listing tuple fields is missing the required
`cv_net` field for V1 item tuples; update the sentence that currently reads "cmx
|| rho || charge utile" to include `cv_net` (e.g., "cmx || rho || cv_net ||
charge utile") so it matches the record schema used elsewhere in this chapter
and the V1 item tuple definition.
- Line 405: Update the stored-value description phrase so it reflects the new
storage format: replace the fragment "cmx || rho || charge utile" with "cmx ||
rho || cv_net || payload" (or in French "cmx || rho || cv_net || charge utile")
so the documentation now lists cmx, rho, cv_net and payload explicitly; locate
the sentence containing the symbols cmx, rho and charge utile in
commitment-tree.md and adjust the wording accordingly.

In `@docs/book/translations/id/src/quantum-cryptography.md`:
- Around line 278-283: The table header currently reads "Hibrid (1.400 B)" but
hybrid records are defined elsewhere as 1,432 bytes; update the header text to
"Hibrid (1.432 B)" and then verify and correct the table values (columns for
Hibrid and Delta) so they reflect calculations using 1,432 bytes per record;
look for the table row containing "| 100.000 | 26,7 MB | 133 MB | +106 MB |" and
the header text "Hibrid (1.400 B)" to make the edits.

In `@docs/book/translations/vi/src/commitment-tree.md`:
- Around line 365-370: The documentation for GroveOp::CommitmentTreeInsert is
missing the cv_net field; update the snippet and surrounding docs to include
cv_net (e.g., add "cv_net: [u8; 32]" to the documented structure) so it matches
the constructors and preprocess tuples that expect cv_net; ensure any
explanatory text references cv_net's purpose consistently with the code paths
that construct GroveOp::CommitmentTreeInsert.
🪄 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: defaults

Review profile: CHILL

Plan: Pro

Run ID: a299aa78-17b3-4aab-855f-eced5f663fc2

📥 Commits

Reviewing files that changed from the base of the PR and between 40521b8 and 1b908b8.

📒 Files selected for processing (81)
  • docs/book/src/batch-operations.md
  • docs/book/src/commitment-tree.md
  • docs/book/src/element-system.md
  • docs/book/src/quantum-cryptography.md
  • docs/book/translations/ar/src/batch-operations.md
  • docs/book/translations/ar/src/commitment-tree.md
  • docs/book/translations/ar/src/element-system.md
  • docs/book/translations/ar/src/quantum-cryptography.md
  • docs/book/translations/cs/src/batch-operations.md
  • docs/book/translations/cs/src/commitment-tree.md
  • docs/book/translations/cs/src/element-system.md
  • docs/book/translations/cs/src/quantum-cryptography.md
  • docs/book/translations/de/src/batch-operations.md
  • docs/book/translations/de/src/commitment-tree.md
  • docs/book/translations/de/src/element-system.md
  • docs/book/translations/de/src/quantum-cryptography.md
  • docs/book/translations/es/src/batch-operations.md
  • docs/book/translations/es/src/commitment-tree.md
  • docs/book/translations/es/src/element-system.md
  • docs/book/translations/es/src/quantum-cryptography.md
  • docs/book/translations/fr/src/batch-operations.md
  • docs/book/translations/fr/src/commitment-tree.md
  • docs/book/translations/fr/src/element-system.md
  • docs/book/translations/fr/src/quantum-cryptography.md
  • docs/book/translations/id/src/batch-operations.md
  • docs/book/translations/id/src/commitment-tree.md
  • docs/book/translations/id/src/element-system.md
  • docs/book/translations/id/src/quantum-cryptography.md
  • docs/book/translations/it/src/batch-operations.md
  • docs/book/translations/it/src/commitment-tree.md
  • docs/book/translations/it/src/element-system.md
  • docs/book/translations/it/src/quantum-cryptography.md
  • docs/book/translations/ja/src/batch-operations.md
  • docs/book/translations/ja/src/commitment-tree.md
  • docs/book/translations/ja/src/element-system.md
  • docs/book/translations/ja/src/quantum-cryptography.md
  • docs/book/translations/ko/src/batch-operations.md
  • docs/book/translations/ko/src/commitment-tree.md
  • docs/book/translations/ko/src/element-system.md
  • docs/book/translations/ko/src/quantum-cryptography.md
  • docs/book/translations/pl/src/batch-operations.md
  • docs/book/translations/pl/src/commitment-tree.md
  • docs/book/translations/pl/src/element-system.md
  • docs/book/translations/pl/src/quantum-cryptography.md
  • docs/book/translations/pt/src/batch-operations.md
  • docs/book/translations/pt/src/commitment-tree.md
  • docs/book/translations/pt/src/element-system.md
  • docs/book/translations/pt/src/quantum-cryptography.md
  • docs/book/translations/ru/src/batch-operations.md
  • docs/book/translations/ru/src/commitment-tree.md
  • docs/book/translations/ru/src/element-system.md
  • docs/book/translations/ru/src/quantum-cryptography.md
  • docs/book/translations/th/src/batch-operations.md
  • docs/book/translations/th/src/commitment-tree.md
  • docs/book/translations/th/src/element-system.md
  • docs/book/translations/th/src/quantum-cryptography.md
  • docs/book/translations/tr/src/batch-operations.md
  • docs/book/translations/tr/src/commitment-tree.md
  • docs/book/translations/tr/src/element-system.md
  • docs/book/translations/tr/src/quantum-cryptography.md
  • docs/book/translations/vi/src/batch-operations.md
  • docs/book/translations/vi/src/commitment-tree.md
  • docs/book/translations/vi/src/element-system.md
  • docs/book/translations/vi/src/quantum-cryptography.md
  • docs/book/translations/zh/src/batch-operations.md
  • docs/book/translations/zh/src/commitment-tree.md
  • docs/book/translations/zh/src/element-system.md
  • docs/book/translations/zh/src/quantum-cryptography.md
  • grovedb-commitment-tree/benches/seeding.rs
  • grovedb-commitment-tree/src/commitment_tree/mod.rs
  • grovedb-commitment-tree/src/commitment_tree/tests.rs
  • grovedb-commitment-tree/src/lib.rs
  • grovedb/src/batch/estimated_costs/average_case_costs.rs
  • grovedb/src/batch/estimated_costs/worst_case_costs.rs
  • grovedb/src/batch/mod.rs
  • grovedb/src/operations/commitment_tree.rs
  • grovedb/src/tests/batch_delete_tree_tests.rs
  • grovedb/src/tests/batch_rejection_tests.rs
  • grovedb/src/tests/batch_unit_tests.rs
  • grovedb/src/tests/commitment_tree_tests.rs
  • grovedb/src/tests/proof_coverage_tests.rs

Comment thread docs/book/translations/ar/src/element-system.md
Comment thread docs/book/translations/cs/src/quantum-cryptography.md Outdated
Comment thread docs/book/translations/fr/src/element-system.md
Comment thread docs/book/translations/pl/src/quantum-cryptography.md Outdated
Comment thread docs/book/translations/pt/src/element-system.md Outdated
Comment thread docs/book/translations/pt/src/quantum-cryptography.md Outdated
Comment thread docs/book/translations/vi/src/quantum-cryptography.md
Comment thread docs/book/translations/zh/src/quantum-cryptography.md
QuantumExplorer and others added 2 commits June 9, 2026 01:04
Address CodeRabbit: the quantum-cryptography post-quantum scale table in cs, id,
pl, and pt still showed the pre-cv_net hybrid size (1 400 / 1.400 B) and the old
storage estimates (26,7 MB / 133 MB / 267 MB / 2,67 GB), because these locales
use space/period thousands separators and comma decimals that the comma-format
replacements didn't match. Recompute the hybrid header to 1 432 / 1.432 B and the
three rows to the 312-byte/1,432-byte values, keeping each locale's number format.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Address CodeRabbit language findings on element-system.md:
- ar: reword the awkward "يتدفق كتجزئة Merk الابن" to the clearer
  "يُمرَّر كتجزئة العقدة الابن في Merk".
- pt: restore diacritics on the historical-anchors bullet
  (Âncoras históricas são … árvore provável).
- fr: normalize prose apostrophes to the typographic ’ (U+2019) throughout
  the file for internal consistency; code spans left untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@QuantumExplorer
QuantumExplorer merged commit 5eafc9e into develop Jun 8, 2026
8 of 11 checks passed
@QuantumExplorer
QuantumExplorer deleted the claude/xenodochial-thompson-53e87d branch June 8, 2026 23:27
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.

2 participants