Claude 60bf3ead82 feat: Add intelligent relay selection for thread replies
Implements smart relay selection strategy for publishing thread replies that ensures maximum visibility:

**New Relay Selection Logic:**
1. Author's write/outbox relays (so followers see the reply)
2. Participants' read/inbox relays (so they see mentions/replies)
3. Relays where root event was seen (where thread is active)
4. Deduplication, health filtering, and configurable limits

**New Function: `selectRelaysForThreadReply`**
- Located in src/services/relay-selection.ts
- Intelligently combines relay hints from multiple sources
- Prioritizes author's outbox relays when limiting
- Limits participant processing to avoid excessive connections
- Filters unhealthy/dead relays using liveness service
- Configurable maxRelays (default 8) and maxParticipantRelays (default 5)

**ThreadComposer Integration:**
- Replaces empty relay array with smart selection
- Passes active user pubkey, thread participants, and root event
- Ensures replies reach both author's followers and thread participants

**Comprehensive Test Coverage:**
- 7 new tests covering all relay selection scenarios
- Tests for author outbox, participant inbox, seen-at relays
- Tests for limits, prioritization, and edge cases
- All 936 tests passing

This ensures thread replies are published to the right relays for maximum discoverability while respecting the NIP-65 outbox/inbox model.
2026-01-17 20:25:10 +00:00
2025-12-18 15:46:02 +01:00
👶
2025-12-09 16:26:31 +01:00
2025-12-19 12:49:29 +01:00
2025-12-13 15:06:05 +01:00
2025-12-10 13:00:39 +01:00
2025-12-22 20:40:16 +00:00
2025-12-20 14:25:40 +01:00
2026-01-14 19:24:37 +01:00
👶
2025-12-09 16:26:31 +01:00
👶
2025-12-09 16:26:31 +01:00
👶
2025-12-09 16:26:31 +01:00
2025-12-14 16:50:16 +01:00

Grimoire

A Nostr protocol explorer and developer tool with a tiling window manager interface.

Features

  • Tiling Windows - Each window is a Nostr "app" (profile viewer, event feed, NIP docs, etc.)
  • Command Palette - Unix-style commands via Cmd+K to open apps and navigate
  • Multi-workspace - Virtual desktops with independent layouts
  • Real-time - Reactive event subscriptions with automatic updates

Stack

React 19, TypeScript, Vite, TailwindCSS, Jotai, Dexie, Applesauce

Getting Started

npm install
npm run dev

Scripts

Command Description
npm run dev Start dev server
npm run build Build for production
npm test Run tests in watch mode
npm run lint Lint code
npm run format Format code

License

MIT

Description
No description provided
Readme MIT 14 MiB
Languages
TypeScript 98.9%
CSS 0.8%
JavaScript 0.3%