Skip to content

Docs/update dispute chat#35

Merged
Catrya merged 3 commits intomainfrom
docs/update-dispute-chat
Mar 9, 2026
Merged

Docs/update dispute chat#35
Catrya merged 3 commits intomainfrom
docs/update-dispute-chat

Conversation

@Catrya
Copy link
Copy Markdown
Member

@Catrya Catrya commented Mar 9, 2026

  • Update dispute chat documentation to reflect the current shared key encryption scheme between user and admin
  • Fix mdbook build failure caused by external links in SUMMARY.md
  • Reorder chapters to place peer-to-peer chat before disputes.

Summary by CodeRabbit

  • Documentation
    • Streamlined documentation structure by removing duplicate links and reorganizing chat references.
    • Updated dispute messaging procedures and shared key management documentation.
    • Added user guide and node setup reference links.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 9, 2026

Walkthrough

The PR updates the protocol documentation, restructuring the dispute chat setup from a generic Gift Wrap messaging flow to an ECDH-based admin-shared key system per dispute, while reordering documentation links and adding external references to the overview section.

Changes

Cohort / File(s) Summary
Documentation Links
src/SUMMARY.md, src/overview.md
Removed external documentation links from SUMMARY.md and reordered Peer-to-peer Chat entry; added "See also" section to overview.md with three external resource links.
Dispute Chat Protocol
src/dispute_chat.md
Reframed dispute chat from generic Gift Wrap messaging to independent ECDH-derived admin-shared keys per dispute; introduced admin-took-dispute flow; updated message wrapping to use kind 1059 Gift Wrap with peer envelope; changed subscription model from receiving to subscribing with pubkey filtering.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested reviewers

  • grunch

Poem

🐰 The docs now dance with ECDH grace,
Admin keys in every dispute space,
Gift-wrapped messages, secured with care,
A protocol redesign, refined and fair! 🔐

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Docs/update dispute chat' is partially related to the changeset. While it accurately describes the main update to dispute_chat.md, it omits equally significant changes: removing external links from SUMMARY.md to fix a build failure and reordering chapters.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs/update-dispute-chat

Tip

Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs).
Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Catrya Catrya requested a review from grunch March 9, 2026 21:46
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
src/dispute_chat.md (1)

3-3: Consider clarifying "encryption scheme" vs "key derivation."

The phrase "same shared key encryption scheme" could be more precise. While both use the same NIP-59 wrapping and NIP-44 encryption, the key derivation partners differ fundamentally (peer-to-peer vs party-to-admin). Consider rewording for clarity:

"The dispute chat uses the same NIP-59 wrapping and NIP-44 encryption as the Peer-to-peer Chat, but instead of computing a shared key between buyer and seller, each party computes an independent shared key with the admin who took the dispute."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/dispute_chat.md` at line 3, Replace the ambiguous phrase "same shared key
encryption scheme" in src/dispute_chat.md with a precise wording that names the
standards and clarifies the key-derivation difference; specifically change the
sentence to: "The dispute chat uses the same NIP-59 wrapping and NIP-44
encryption as the [Peer-to-peer Chat](./chat.md), but instead of computing a
shared key between buyer and seller, each party computes an independent shared
key with the admin who took the dispute." This updates the description in the
dispute chat paragraph to explicitly reference NIP-59 and NIP-44 and to state
that key derivation is party-to-admin rather than peer-to-peer.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/dispute_chat.md`:
- Around line 29-37: The markdown code blocks showing the ECDH computation lack
language specifiers causing MD040 lint failures; update both code fences
surrounding "Shared Key = ECDH(tradeKey.private, adminPubkey)" and "Shared Key =
ECDH(adminPrivateKey, tradeKey.public)" to include a language tag (e.g.,
```text) so the blocks render correctly and satisfy linting rules, ensuring the
fences before and after each expression are changed to ```text and ```
respectively.

---

Nitpick comments:
In `@src/dispute_chat.md`:
- Line 3: Replace the ambiguous phrase "same shared key encryption scheme" in
src/dispute_chat.md with a precise wording that names the standards and
clarifies the key-derivation difference; specifically change the sentence to:
"The dispute chat uses the same NIP-59 wrapping and NIP-44 encryption as the
[Peer-to-peer Chat](./chat.md), but instead of computing a shared key between
buyer and seller, each party computes an independent shared key with the admin
who took the dispute." This updates the description in the dispute chat
paragraph to explicitly reference NIP-59 and NIP-44 and to state that key
derivation is party-to-admin rather than peer-to-peer.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 5265c545-615f-4358-bd33-a488669f8771

📥 Commits

Reviewing files that changed from the base of the PR and between 8157c1c and be8e459.

📒 Files selected for processing (3)
  • src/SUMMARY.md
  • src/dispute_chat.md
  • src/overview.md

Comment thread src/dispute_chat.md
@Catrya Catrya merged commit 5652fb0 into main Mar 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant