Commit Graph

13 Commits

Author SHA1 Message Date
Claude
f700acfa24 feat(bot): Output only commands, no explanations
- ONLY the command, nothing else
- Multiple commands: one per line
- NO explanations, NO descriptions
- Simpler, cleaner output

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 13:03:04 +00:00
Claude
8df39e94da fix(bot): P tag is zaps only, not reactions
- Clarify P tag (uppercase) is ZAPS ONLY
- Reactions use p-tag (lowercase) to mention content author
- Fixed REACTION QUERIES to use -p for "reactions to my content"
- Added "reactions by someone" example using -a

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 13:02:22 +00:00
Claude
653bd78700 fix(bot): Clarify critical distinction between -a, -p, and --tag P
CRITICAL DISTINCTIONS now clearly stated:
- -a, --author = WHO SIGNED the event (cryptographic author)
- -p = WHO IS MENTIONED via p-tag (tagged pubkey, NOT author)
- --tag P = WHO IS MARKED AS AUTHOR in P-tag (original content author)

Also:
- Added TAG FILTERING section explaining k, P, e, p tags
- Added REACTION QUERIES section with proper examples
- Clarified zap receipts are SIGNED by LNURL servers

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 13:01:01 +00:00
Claude
9fb56820f1 feat(bot): Add $me and $contacts examples for zap P tag queries
- Zaps I received: req -k 9735 -p $me
- Zaps to my content: req -k 9735 --tag P $me
- Zaps to content by people I follow: req -k 9735 --tag P $contacts

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:57:27 +00:00
Claude
7c97f7bd57 fix(bot): Clarify P tag for zap original author in system prompt
- Explain p=recipient (gets sats) vs P=original author distinction
- Add example for filtering zaps by original content author
- Note that both tags are queryable via -p (case-insensitive)

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:55:37 +00:00
Claude
a5edc3cee0 feat(bot): Improve system prompt with k-tag and zap query guidance
- Add --tag option for generic tag filtering
- Document k-tag filtering for reactions, zaps, comments
- Clarify zap queries: -p is recipient, -a is LNURL server
- Distinguish comments (kind 1111) from note replies (kind 1)
- Add examples for filtering by referenced event kind

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:51:54 +00:00
Claude
ad6566d2a5 feat(bot): Add NIP-42 AUTH and NIP-29 join request support
- Handle AUTH challenges from group relay using onauth callback
- Send kind 9021 join request when connecting to group
- Use direct Relay connection instead of SimplePool for group relay
- Properly close relay connection on shutdown

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:48:42 +00:00
Claude
4da0de89a0 feat(bot): Simplify system prompt for concise plain-text responses
- Remove markdown formatting instructions
- Remove relay recommendations
- Remove follow-up question suggestions
- Remove non-existent @kind syntax reference
- Focus on short, direct answers with just the command and explanation
- Plain text output suitable for posting directly to group chat

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:44:57 +00:00
Claude
749dfc6233 feat(bot): Enhance system prompt with comprehensive REQ documentation
- Reorganize filter flags into logical sections (event selection, tags, time, display)
- Add filter limitations section explaining what REQ cannot do
- Add common query patterns with practical examples
- Include NIP-05 resolution alias (@nip05)
- Add guidance on when to use the lookup tools
- Better structure for response guidelines

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:39:30 +00:00
Claude
0584d669b8 feat(bot): Add test-assistant script for testing LLM in isolation
Adds npm run assistant "question" command to test the LLM processing
without needing the Nostr connection.

Also:
- Add proper API key validation with clear error message
- Add debug logging (DEBUG=1) for troubleshooting

Usage:
  export ANTHROPIC_API_KEY=sk-ant-...
  npm run assistant "how do I see what my contacts are zapping"

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:33:19 +00:00
Claude
5e806d08e8 feat(bot): Publish profile to discovery relays on startup
Bot now publishes a kind 0 profile event with name "sancho" and about
"a grimoire assistant" to discovery relays when starting up.

Discovery relays:
- relay.damus.io
- nos.lol
- relay.nostr.band
- purplepag.es
- The group relay

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:29:52 +00:00
Claude
5d5d7e3cb6 chore(bot): Add package-lock.json
https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:27:02 +00:00
Claude
93d9157b40 feat(bot): Add Grimoire REQ Assistant bot
Adds a Nostr bot that listens for mentions in NIP-29 group chats and
helps users craft REQ queries for the Nostr protocol.

Features:
- Listens for @mentions in groups.0xchat.com'NkeVhXuWHGKKJCpn
- Uses Claude (via pi-ai SDK) to understand user questions
- Provides REQ command suggestions with explanations
- Tools to look up event kinds, NIPs, and their relationships

Stack: TypeScript, nostr-tools, @mariozechner/pi-ai

https://claude.ai/code/session_01X4HWkMGrghBv2RfY89L5Lz
2026-02-03 12:26:21 +00:00