A drop-in skill that lets a coding agent (Claude Code, Codex, etc.) search the Banodoco Discord message feed — a public, read-only PostgREST mirror of the Banodoco server. Banodoco is where a lot of the practitioners working on generative video & image tooling (Wan, Wan Animate, VACE, LTX, ComfyUI, Kijai's nodes, SCAIL, InfiniteTalk, training, etc.) actually talk to each other. This skill teaches your agent how to query it.
The endpoint exposes the same data the Discord shows — public messages, attributed by display name. Be respectful when surfacing tips and credit authors.
Hivemind v2 upgrades the raw message feed into a unified knowledge corpus
with a read path (public PostgREST against unified_feed) and a locked write
path (Supabase edge function). The corpus combines:
- Messages — the original Discord message feed (v1)
- Resources — articles, transcripts, ComfyUI workflows, blog posts
- Distillations — curated Q&A pairs with cited sources, submitted by agents and reviewed by humans
Everything is searchable: the pack's search executor queries the raw corpus
tables (message_feed, external_resources, distillations) in parallel
with per-token ILIKE predicates and ranks the merge client-side — the
unified_feed UNION view is used only for kind-scoped single-row fetches
(get_item), never for text search (its derived-view scan blows the anon
role's 3s statement budget → HTTP 500 / SQLSTATE 57014). Distillations make
the corpus self-improving: every researched answer becomes a permanent,
findable entry for the next person.
git clone https://github.com/banodoco/hivemind /tmp/hivemind-skill-tmp \
&& mkdir -p ~/.claude/skills \
&& rm -rf ~/.claude/skills/hivemind \
&& cp -r /tmp/hivemind-skill-tmp/skill ~/.claude/skills/hivemind \
&& rm -rf /tmp/hivemind-skill-tmp \
&& echo "Installed. Restart Claude Code, then try: /hivemind"Or run bash install.sh from a clone of this repo.
python3 -m astrid packs install https://github.com/banodoco/hivemind.gitThe pack exposes seven executors: hivemind.search, hivemind.get_item,
hivemind.refresh_media, hivemind.contribute, hivemind.ingest_article,
hivemind.ingest_workflow, hivemind.ingest_youtube. See AGENTS.md for the
agent guide.
(Requires Astrid with external Python-executor pack support, 2026-06-04+.)
Copy skill/SKILL.md into your AGENTS.md (or equivalent instruction
file) — the content is self-contained with endpoint, schema, query patterns,
and the full contribute API.
The repo root is a Python package (hivemind), stdlib-only. Install
editable so edits to the clone are live:
pip install -e .
pyenv rehash # only if you use pyenv — exposes the hivemind-search shimThen, from any directory:
python3 -m hivemind.executors.search.run --query "wan animate" --limit 10
hivemind-search --query "lora" --channel wan_chatter --limit 20 # console script
python3 -c "import hivemind" # package importThe console script mirrors python3 executors/search/run.py exactly
(same flags, same JSON/stdout contract, same stderr paging hints).
One repo, three products — the Astrid pack is contractually pinned to the
repo root (astrid packs install <git-url> requires pack.yaml in a
directory whose name equals the pack id, and the clone is named hivemind):
| entry | belongs to | what it is |
|---|---|---|
skill/SKILL.md |
all agents | The canonical playbook — installed as the Claude skill, discovered by Astrid, copy-paste for anything else |
pack.yaml, executors/, AGENTS.md, __init__.py |
Astrid pack | Manifest, seven stdlib-only executors, agent guide, package marker for hivemind.executors.* imports |
schema/, supabase/ |
backend | The corpus DDL and the contribute edge function (the only write path) |
scripts/ |
ops | Contributor-key issuance |
tests/ |
dev | 309 Python unit tests (mocked HTTP) + deno tests under supabase/ |
install.sh, assets/ |
repo | Claude-skill installer, mascot |
DESIGN.md |
docs | Architecture: layers, flywheel, deferred decisions |
.astridignore |
Astrid pack | Keeps backend/assets/tests out of installed pack copies |
- The endpoint URL + the public anon key (safe to commit — it's the publishable key, RLS makes it read-only).
- The
unified_feedview: messages + resources + distillations in one table (use kind-scoped for single-row fetches — NOT for text search). - Per-token
ilikesearch over the raw tables (message_feedcontent,external_resourcestitle/body,distillationsquestion/answer/conditions), client-ranked and merged. - Get single items by kind + id with full citation context.
- A taxonomy of which Discord channels are high-signal (
daily_summaries,wan_chatter,wan_comfyui,ltx_chatter,comfyui,*_resources) vs. background noise. - A short list of power-users to weight (Kijai, Ablejones, djbfilmz, 42hub, BNDC the summary bot).
- PostgREST query patterns the agent can use directly:
ilikesubstring search,in.(…)channel filtering, repeated-key AND,or=(…)for spelling variants, author + time filtering. - Gotchas — most importantly that
fts(full-text search) times out on this table, so useilikeonly.
POST /functions/v1/contribute— the single write entrypoint.- Auth via
X-Contributor-Key: hm_<64 hex>header (SHA-256 checked against thecontributorstable, revoked keys rejected). - Two actions:
add_resource— submit articles, transcripts, workflows.submit_distillation— submit Q&A with ≥1 cited source. Duplicate detection viapg_trgmsimilarity (>0.6 threshold),supersedes_idfor replacing outdated answers.
- Status forced to
pendingby the edge function; curators promote toapproved. - Responses: 201 (created), 400 (validation), 401 (unauthorized), 409 (duplicate), 500 (internal error).
- Search distillations first on the user's question.
- Hit → relay the answer with its cites.
- Miss → research raw messages/resources, answer the human, then submit a cited distillation.
- The next person who asks gets it immediately.
Before submitting, check:
- The question is generalizable (not a one-off personal request).
- You did real research effort (surfaced sources, compared answers).
- You have at least one cite.
- If a similar question exists, supersede it rather than duplicating.
curl -s -X POST "$SUPABASE_URL/functions/v1/contribute" \
-H "Content-Type: application/json" \
-H "X-Contributor-Key: hm_$(cat ~/.hivemind/key)" \
-d '{
"action": "submit_distillation",
"data": {
"question": "What is the best upscale model for anime-style Wan output?",
"answer": "4x-UltraSharp with 50% blend on original, then a second GFPGAN pass.",
"confidence": "high",
"conditions": "for anime-style video, 1080p target",
"cites": [
{"item_kind": "message", "item_id": 88123},
{"item_kind": "resource", "item_id": 17}
]
}
}'| Executor | CLI | Description |
|---|---|---|
search |
python3 executors/search/run.py --query "..." |
Per-token ilike search over raw tables, client-ranked; never unified_feed |
Filters: --kinds message|workflow|distillation (or a mix), --sources,
--since, --channel <name>, --author <name> (messages only), and
--thread <snowflake> (index-backed thread surface). Ordering: --sort relevance (default — score, then recency) or --sort recent
(created_at desc, then score). The relevance score: +5 per distinctive
token in title/question, +3 in body/answer/conditions, +4 approved
distillation, +3 parseable workflow, +2 exact phrase. Page any query with
--limit N --offset M. Ergonomics: every response carries count, total
(ranked-pool extent), has_more, page, pages, and next_offset —
when has_more is true, the next page is exactly
--offset <next_offset> on the same command, so agents never reconstruct
the offset. A human summary goes to stderr so stdout stays pure JSON:
Showing 11-20 of 114 results (page 2 of 12) - next: --limit 10 --offset 20.
total is the ranked pool bounded by the per-scope fetch (exact corpus
counts would need the slow Prefer: count=exact, which the transport never
sends). The ranking is deterministic while the corpus is unchanged, so page
N is stable across calls. Examples:
python3 executors/search/run.py --query "wan animate" --limit 10 # first page, all kinds
python3 executors/search/run.py --query "wan animate" --limit 10 --offset 10 # second page
python3 executors/search/run.py --query "lora" --channel wan_chatter --limit 20 # channel filter
python3 executors/search/run.py --query "lora" --author Kijai --limit 20 # author filter
python3 executors/search/run.py --query "context" --thread 1175229360781938718 # thread filter| get_item | python3 executors/get_item/run.py --kind distillation --id 42 | Full untruncated row with citation context |
| refresh_media | python3 executors/refresh_media/run.py --message-id 1512127379039060118 | Refresh expiring Discord CDN attachment URLs |
| contribute | python3 executors/contribute/run.py --type resource ... | Submit resources or distillations via edge function |
| ingest_article | python3 executors/ingest_article/run.py --url https://... | Extract HTML text → submit as resource |
| ingest_workflow | python3 executors/ingest_workflow/run.py --path workflow.json | Parse ComfyUI JSON → extract models → submit |
| ingest_youtube | python3 executors/ingest_youtube/run.py --url https://... | yt-dlp captions → submit transcript resource |
All executors are stdlib-only Python. See AGENTS.md for usage guidance and
DESIGN.md for architecture details.
Hivemind is for querying the live public message feed from an agent. If you want to train on the full archive or grab the whole dataset directly, use the Hugging Face dataset:
https://huggingface.co/datasets/Banodoco/discord-archive
That dataset contains the exported Discord archive with opted-out authors excluded.
- "What does Banodoco say about Wan Animate best practices?"
- "Search Banodoco for SCAIL vs Wan Animate"
- "What settings has Kijai recommended for the lightx2v LoRA?"
- "Find me workflows for long-video context windows in Wan"
- "What did people say about LTX 2.3 last week?"
GET https://ujlwuvkrxlvoswwkerdf.supabase.co/rest/v1/message_feed
Header: apikey: sb_publishable_O38oPBafrBoFrpi_rlWJvA_UJrulFsx
The unified_feed view is at the same base (kind-scoped single-row fetches
only — see the search-executor note above):
GET https://ujlwuvkrxlvoswwkerdf.supabase.co/rest/v1/unified_feed
Smoke-test a raw search surface (per-token OR on message content — the fast
shape; order=created_at.desc bounds the pool):
curl -s "https://ujlwuvkrxlvoswwkerdf.supabase.co/rest/v1/message_feed?select=message_id,content,author_name,channel_name,created_at&limit=5&order=created_at.desc&or=(content.ilike.*wan*,content.ilike.*animate*)" \
-H "apikey: sb_publishable_O38oPBafrBoFrpi_rlWJvA_UJrulFsx" | python3 -m json.tool- hivemind/SKILL.md — full raw query playbook: channel map, power users, search snippets, trend questions, caveats.
- AGENTS.md — agent guide: when to use each executor, flywheel loop, key constraints.
- DESIGN.md — architecture, schema design, lifecycle, deferred work, design decisions.
- skill/SKILL.md — Astrid skill documentation: read/write paths, contribute API, curl examples.
MIT. The data the endpoint serves is public Discord content authored by Banodoco members — credit them when you surface their tips.
