Repository navigation
Search swarm
clippa/swarm.py is the search clippa story (#84) and investigate check use: many
small searches at once, each free to follow up on what it finds. It is library code, not a command.
A planner (Sonnet) turns the goal (a story brief, a lead) into up to 16 first tasks; workers (Haiku,
8 at a time) each run one tool in code and read its numbered results: YouTube search (bounded to
the run's week, month or year, approximate dates), a YouTube channel's uploads and streams, a Kick
channel's VODs, an Odysee channel, Reddit and the web (Brave), an archive subject's transcripts and
our own streams' segments. Each worker marks the results that fit (strong or maybe) and proposes up to 3 follow-ups (a clip channel
that keeps covering it, another person, a quote to search). The coordinator merges findings by
platform id, queues follow-ups it hasn't seen as the next round, and stops at [swarm] max_rounds, max_tasks, budget_usd or max_wall_s. A channel task lists up to channel_depth
videos, keeps the run's dates and passes the 20 whose titles fit the goal best. Model output never
becomes a fetch: a finding is one of the tool's own results, a follow-up must parse as its kind
(a query, a supported platform's channel, an archive on file), and targets asking for anyone's
whereabouts or private details are dropped. The trail is the caller's swarm.json (every task,
its parent, results, findings, cost); a rerun resumes it. A 30-task run on Jer's Huck story found
109 results (44 strong) across Kick, YouTube clip channels, Odysee, Reddit and the web for ~$0.03.
The swarm needs ANTHROPIC_API_KEY
and yt-dlp (with deno, as for pre-shows). Its web and Reddit searches use the same Brave key; Kick,
Odysee and YouTube listings need no key. YouTube searches run from this machine's IP, so a bot
check here affects them too. Per-source request rates are [swarm] rates.
Home · Getting started · clippa doctor · These pages are built from docs/wiki/ in the repo, so edits made here are overwritten: how to edit them
Run it
- Overview
- Getting started
- Roles and services
- Configuration
- Pipeline
- Review
- Reviewing
- War room
- Clippa messenger
- Scheduling and uploads
- Costs
- Checkup
- Audit
- Backups
Install
- Install
- Install checklist
- Kitsu
- Discord app
- YouTube sign-in
- Windows
- macOS
- Transcribe on Modal
- NAS recorder
- NAS hub
- Claude on the NAS
- Phone access
- Model providers
- Adding a show
- YouTube channel
Features
- Pre-shows
- Fetching VODs
- Speakers
- Faces
- Covers
- Cast library
- B-roll
- Clip art
- Weekly issue
- X posts
- TikTok
- News watcher
- Character pieces
- Documentaries
Research
Working on Clippa