slack-ask
Skill1 starsChanged 3 months agoMITView on GitHub
Ask the user a question over Slack and block until they reply. Use during automated/unattended procedures when you need human input or a decision and the user is away from the terminal.
In this repository39 other files it gives its agents.
- arch-mapSkill
- ask-meSkill
- autodevSkill
- codebase-designSkill
- code-reviewSkill
- context-barSkill
- contractSkill
- copilot-reviewSkill
- crapSkill
- deep-research-consolidateSkill
- deep-research-promptSkill
- domain-modelingSkill
- drop-reviewSkill
- fleet-reviewSkill
- framing-decisionsSkill
- grillingSkill
- grill-meSkill
- grill-with-docsSkill
- handoffSkill
- herdrSkill
- implementSkill
- mergedSkill
- meta-analysisSkill
- mutation-testSkill
- obsidian-vaultSkill
- paper-outlineSkill
- probeSkill
- prSkill
- setup-matt-pocock-skillsSkill
- show-meSkill
- slack-notifySkill
- sparSkill
- sync-matt-pocock-skillsSkill
- tddSkill
- to-specSkill
- triageSkill
- writing-for-agentsSkill
- writing-git-commitsSkill
- writing-great-skillsSkill
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 3 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Use this when a procedure needs input from the user but they may not be watching the terminal.
- Very specific: line 40
Identify context: Run hostname and note the current working directory so the user knows *which machine / which task* is asking.
- Very specific: line 70
Call slack_read_thread with channel_id = the $CC_SLACK_CHANNEL id and message_ts = <ts>.
- Very specific: line 72
Look for the last message whose user is $CC_SLACK_USER and whose ts is greater than the root ts.
- Distinctive: line 74
If found → that text is the answer.
- Very specific: line 75
If not found → start the next backgrounded sleep per the table and repeat.
- Distinctive: line 76
Keep going at the 30-min cadence until answered, or stop after an overall budget (default ~4 h) and report a timeout to the user.
- Very specific: line 90
If the answer is ambiguous, ask a follow-up in the same thread (pass the root ts again) rather than starting a new message.
- Very specific: line 92
Never treat your own/bot messages as the answer — filter strictly on user == $CC_SLACK_USER.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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
slack-ask — bidirectional human-in-the-loop over Slack
Use this when a procedure needs input from the user but they may not be watching
the terminal. You post a question to Slack as a bot, the user replies in
the thread, and you read that reply back via the connector and continue.
Because you only watch the thread you created, the reply is routed to this CC
instance even if other instances on other machines are also asking. (Posting as
the bot rather than via the claude.ai connector is why Slack actually notifies —
see slack-notify for the full rationale.)
Config
- Channel: the id in
$CC_SLACK_CHANNEL(e.g.C0123456789; find yours in Slack via channel name → About → Copy channel ID). The helper requires it and exits withERRwhen unset — wiring in SETUP.md. - Send helper:
$HOME/.claude/bin/cc-slack-post.py "<message>" [thread_ts]— posts as the bot (reads the bot token from~/.claude/.slack-bot-token), printsOKthen the messagets. It's allowlisted in settings.json, so it runs without a permission prompt (unattended-safe). The command may use$HOME, but the~/.claude/settings.jsonallow-rule must use the literal absolute helper path. Thread replies are always broadcast to the channel (reply_broadcast, i.e. "Also send to channel") — the helper sets this automatically. Plain thread replies trigger no Slack alert, so without the broadcast the user never learns a message is pending. Never post a thread reply through any other mechanism (e.g. an MCP send tool) without the equivalent broadcast flag. - Human user id: the id in
$CC_SLACK_USER(e.g.U0123456789; find yours in Slack under Profile → ⋮ → Copy member ID). Only a reply from that user (not the bot, not yourself) counts as the answer. If$CC_SLACK_USERis unset, stop and say so — the same way the send helper refuses an unset channel. Accepting whoever replies first is not the fallback.
Procedure
- Identify context. Run
hostnameand note the current working directory so the user knows which machine / which task is asking. - Post the question as the bot and capture the thread root
ts. Run the helper via Bash (mind shell quoting; the message uses Slack mrkdwn —*bold*,_italic_,`code`,\nfor newlines):
The first output line is$HOME/.claude/bin/cc-slack-post.py "❓ *<machine>* needs input — \`<task>\` <cwd> <your question, with concrete options if it's a choice> _Reply in this thread._"OK; the second line is the thread rootts— keep it, it's your routing key. (If it printsERR …, report it and stop; common causes: token file missing, or the bot isn't in the channel.) Wait for a reply (polling loop with backoff). Foreground
sleepis blocked in this harness, so wait by running a backgrounded Bash command (sleep <N>withrun_in_background: true). When it completes you are re-invoked; then check for the reply. Track elapsed time to pick the interval:Elapsed since you posted Sleep between polls 0–5 min sleep 30(every 30s)5–65 min sleep 900(every 15 min)65 min onward sleep 1800(every 30 min)On each wake:
- Call
slack_read_threadwithchannel_id= the$CC_SLACK_CHANNELid andmessage_ts = <ts>. - Look for the last message whose
useris$CC_SLACK_USERand whosetsis greater than the rootts. - If found → that text is the answer. Go to step 4.
- If not found → start the next backgrounded
sleepper the table and repeat. - Keep going at the 30-min cadence until answered, or stop after an overall budget (default ~4 h) and report a timeout to the user.
Note: background-task completion events are NOT the user's reply — only a
slack_read_threadmessage from$CC_SLACK_USERcounts.- Call
- Acknowledge and continue. Post a short threaded confirmation by passing
the root
tsas the second arg, then use the answer to proceed:$HOME/.claude/bin/cc-slack-post.py "✅ Got it — continuing." "<ts>"
Notes
- If the answer is ambiguous, ask a follow-up in the same thread (pass the
root
tsagain) rather than starting a new message. - Never treat your own/bot messages as the answer — filter strictly on
user == $CC_SLACK_USER. - For a one-way notification that needs no reply, use the
slack-notifyskill.
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.

