Research Assistant
Process Bear notes tagged 「待整理」: extract topics, find matching GIFs, insert them, then remove the tag.
Workflow
- Fetch pending notes — run
scripts/process_notes.sh listto get all notes with the 待整理 tag. - For each note, run
scripts/enrich_note.sh <note-id>which:- Reads the note content via
grizzly open-note - Extracts key topic phrases (first H1, bold terms, or first sentence)
- Searches for a relevant GIF via Tenor API (falls back to Giphy)
- Appends the GIF as a markdown image at the end of the note
- Removes the 待整理 tag and adds 已整理 tag
- Reads the note content via
- Report — summarize how many notes were enriched and any failures.
Requirements
- Bear app running on macOS
grizzlyCLI installed (go install github.com/tylerwince/grizzly/cmd/grizzly@latest)- Bear token at
~/.config/grizzly/token TENOR_API_KEYorGIPHY_API_KEYenv var (free tier works)
Scripts
scripts/process_notes.sh list— list note IDs with 待整理 tagscripts/enrich_note.sh <note-id>— enrich a single note with a GIF