Skip to content

docs: clarify NIP-66 methodology, data sourcing, and known gaps#46

Open
alltheseas wants to merge 2 commits intomainfrom
docs/nip66-methodology
Open

docs: clarify NIP-66 methodology, data sourcing, and known gaps#46
alltheseas wants to merge 2 commits intomainfrom
docs/nip66-methodology

Conversation

@alltheseas
Copy link
Contributor

@alltheseas alltheseas commented Mar 13, 2026

Summary

Addresses documentation gaps surfaced by developer feedback on the NIP-66 relay liveness filtering recommendation. Developers reading the existing docs couldn't answer basic questions about the approach — this PR closes those gaps.

Gaps closed

  • Data sourcing — explains kind 30166 events vs HTTP API, strict vs liveness modes, and how production integrations (NDK, Applesauce) differ from the benchmark tool
  • Provider independence — clarifies there is no nostr.watch dependency; kind 30166 is a replaceable event any monitor can publish
  • Tor/.onion handling — documents two distinct concerns: .onion URLs (already preserved) and clearnet relays accessed through Tor (known gap — liveness data reflects clearnet path, not Tor exit-node reachability)
  • Safety guardrails — documents all six graceful-degradation guardrails with code references
  • Benchmark context — explicitly states these are protocol-level measurements, not client-specific results
  • Reproduction methodology — adds NIP-66 A/B comparison section to Benchmark-recreation.md with run-nip66-comparison.sh instructions

Files changed

  • IMPLEMENTATION-GUIDE.md — FAQ-style subsections under the existing NIP-66 section
  • Benchmark-recreation.md — NIP-66 liveness comparison methodology subsection
  • README.md — one-line benchmark context clarification

Test plan

  • Verify all code references (file paths, line-level claims) match actual source
  • Verify NIP-66 spec quotes match NIP-66
  • Confirm links to NIP66-COMPARISON-REPORT.md and NIP66-FOLLOW-COUNT-ANALYSIS.md resolve correctly

🤖 Generated with Claude Code

Summary by CodeRabbit

Release Notes

  • Documentation
    • Enhanced documentation on NIP-66 liveness filtering with benchmark mode details (strict and liveness modes)
    • Added comprehensive guidance on data sources, relay filtering methodology, and usage examples
    • Updated relay filtering description with protocol-level benchmark references

Address documentation gaps surfaced by developer feedback on the NIP-66
PR. Adds FAQ-style subsections to the implementation guide covering data
sourcing (events vs HTTP), provider independence, Tor/.onion handling
(including the clearnet-monitor-vs-Tor-path gap), safety guardrails, and
liveness/strict mode differences. Adds NIP-66 A/B comparison methodology
to the benchmark recreation guide. Clarifies benchmark context in README.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 13, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: e53bf8f5-14a2-4e68-9c85-7e8098200753

📥 Commits

Reviewing files that changed from the base of the PR and between e38b3f9 and 6dbdd50.

📒 Files selected for processing (3)
  • Benchmark-recreation.md
  • IMPLEMENTATION-GUIDE.md
  • README.md

📝 Walkthrough

Walkthrough

This PR adds comprehensive documentation about NIP-66 liveness comparison and pre-filtering across three documentation files, detailing the --nip66-filter flag, two filtering modes (strict and liveness), data sources, usage examples, and implementation considerations. No functional code changes are included.

Changes

Cohort / File(s) Summary
NIP-66 Liveness Documentation
Benchmark-recreation.md, IMPLEMENTATION-GUIDE.md
Added detailed sections explaining NIP-66 pre-filtering modes (strict/liveness), data sources (30166 relay monitor events and HTTP API), Tor/onion considerations, safety guardrails, and usage examples with scripts and commands. Content includes benchmark methodology references and UI latency handling patterns.
Dead Relay Filtering Reference
README.md
Updated "Dead relay filtering" description with protocol-level benchmark reference and methodology link.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Poem

🐰 A rabbit hops through docs with care,
NIP-66 filters here and there,
Liveness modes both strict and free,
Now all the relay truth can see!

🚥 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 directly and accurately summarizes the main change: clarifying NIP-66 methodology, data sourcing, and known gaps, which is precisely what the PR documentation changes accomplish.
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/nip66-methodology
📝 Coding Plan
  • Generate coding plan for human review comments

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.

Dead relays are dead regardless of network path. Tor-default clients
(e.g. Amethyst) benefit MORE from NIP-66 filtering because Tor timeouts
are 2-3x longer — eliminating dead relays before connection avoids
30-90s Tor-routed timeouts to servers that will never respond.

Replaces incorrect "skip NIP-66 in Tor mode" advice with "apply
unconditionally; use local health tracking for the Tor-exit-blocking
blind spot."

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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