search-threads
Skill14 starsChanged 5 months agoApache-2.0View on GitHub
Search threads with filters. Supports filters like role:planner, type:Decision, after:2024-01, thread:topic-name, status:OPEN
In this repository6 other files it gives its agents.
- find-relatedSkill
- recallSkill
- threadsSkill
- update-agent-contextSkill
- watercooler-healthSkill
- watercooler-onboardingSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 36
All non-filter tokens are joined with spaces to form the query text
- Distinctive: line 43
No query text → search with filters only (empty query string)
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Search Threads with Filters
Search: $ARGUMENTS
Filter Syntax
Parse these filters from arguments:
role:X- Filter by role (planner, implementer, critic, tester, pm, scribe)type:X- Filter by entry type (Note, Plan, Decision, PR, Closure)after:DATE/before:DATE- Time range (ISO format: 2024-01-15)thread:X- Specific thread topicstatus:X- Thread status (OPEN, CLOSED)agent:X- Filter by agent nameor:(flag, no value) - Use OR token matching instead of AND (see below)- Remaining text becomes the search query
Token matching default is AND. Multi-keyword queries like
"decided committed resolved"require ALL tokens present in the same entry — this often returns 0 hits. Addor:to use OR matching: any token qualifies. Useor:whenever searching for any of several keywords.
Parsing Rules
- Split
$ARGUMENTSon whitespace into tokens - A token is a filter if it matches
^(role|type|after|before|thread|status|agent):[^\s]+$ - The
or:token (no value) setsquery_operator="OR"— consume it as a flag, not query text - The filter key is everything before the first
:, the value is everything after - All non-filter tokens are joined with spaces to form the query text
Edge Cases
role:planner:advanced→ key=role, value=planner:advanced(first colon splits)- Multiple values for same key → last one wins
- Empty value (
role:) → ignore, treat entire token as query text - No query text → search with filters only (empty query string)
Steps
- Parse arguments into filters and query text using rules above.
- Load MCP tool:
ToolSearch: select:mcp__watercooler__watercooler_search Execute search with parsed query and filters. Pass each filter as its own named parameter — omit any filter param that was not explicitly parsed from the arguments. Do NOT use a
filters={}dict (no such parameter exists):# Example: only role was given mcp__watercooler__watercooler_search( query="config", mode="entries", role="planner" ) # Example: multiple filters mcp__watercooler__watercooler_search( query="", mode="entries", role="planner", entry_type="Decision" ) # Example: thread + status filters mcp__watercooler__watercooler_search( query="", mode="entries", thread_topic="mcp-migration", thread_status="OPEN" ) # Example: no filters, just query text mcp__watercooler__watercooler_search( query="config migration", mode="entries" ) # Example: OR mode — any of several keywords (use when or: flag is set) mcp__watercooler__watercooler_search( query="decided resolved committed opted agreed chosen", query_operator="OR", mode="entries" )Filter parameter mapping:
role:X→role="X"type:X→entry_type="X"thread:X→thread_topic="X"status:X→thread_status="X"agent:X→agent="X"after:DATE→start_time="DATE"before:DATE→end_time="DATE"
- Present results:
- Show matching entries with context
- Include entry metadata (role, type, timestamp)
- Link to full entries for deeper reading
- Handle empty results:
- Suggest relaxing filters
- Try alternative search terms
Example Invocations
/search-threads role:planner config- Planner entries about config/search-threads type:Decision after:2024-01- Recent decisions/search-threads thread:mcp-migration status:OPEN- Search in specific thread/search-threads agent:Claude architecture- Claude's architecture discussions
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

