grok-cli
Skill113 starsChanged 5 months agoApache-2.0View on GitHub
Run Grok CLI headless for real-time X/Twitter and news research. Use when the user says "use grok", "ask grok", "dig into twitter/x", "latest on...", or when fresh data past the training cutoff is needed.
- Pipes a download into a shell
4 other projects use a version of this.
Adopted by
Most recently taken up by
- rookiewu417/claude-skillstheir own version, first seen Oct 25, 2026
- SnowyLake/snowy-agent-skillstheir own version, first seen Oct 20, 2026
- SnowyLake/SnowySkillstheir own version, first seen Oct 20, 2026
- scarletkc/agentstheir own version, first seen Sep 11, 2026
Other versions4 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 4
- scarletkc/agents★ 227same name
- SnowyLake/snowy-agent-skills★ 4same name
- SnowyLake/SnowySkills★ 4same name
- rookiewu417/claude-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- design-explorationSkill
- opencode-memorySkill
- x-algorithmSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 13
When this skill triggers, run the command right away.
- Distinctive: line 51
Ask for concrete output: handles, URLs, quotes, dates, sentiment — not vague summaries.
- Very specific: line 54
Keep <your question> as a single double-quoted string.
≈ “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
grok-cli — fresh info via the Grok CLI
grok is xAI's installed CLI (~/.grok/bin/grok, already authenticated). Use it as a sub-agent to fetch real-time info: X/Twitter chatter and news beyond this model's knowledge. It is slow but live.
Do this immediately
When this skill triggers, run the command right away. Do not run --help, --version, which grok, or any discovery — it works, the recipe below is verified.
The one command (copy, fill the prompt)
grok -p "<your question>" -m grok-build --yolo --max-turns 8 --disallowed-tools web_fetch --output-format json | jq -r '.text'That is the whole interface. Only the <your question> changes.
-m grok-builduses the Grok model (not the composer model).--yoloauto-approves grok's tools (required headless, or it hangs).--disallowed-tools web_fetchforces grok ontoweb_search(xAI live search). This is the key fix: withweb_fetchenabled grok loops on X/news URLs and never returns.--max-turns 8caps it so it can't loop forever.jq -r '.text'returns just the answer. Drop| jq ...ifjqis missing and read the JSONtextfield yourself.
Timing (important)
A live search takes ~1–3 minutes. Set the Bash timeout to 300000 ms (5 min) and wait. Do not assume it failed. If you may keep working meanwhile, run it in the background and poll later.
Prompt templates
Dig deep into X/Twitter — be explicit, ask for specifics:
grok -p "Search X/Twitter for the latest discussion about <TOPIC> (last 24-72h). Surface 5-8 specific posts: @handle, a one-line summary, and the post URL. Quote standout lines. Then give prevailing sentiment, the most influential accounts driving it, and any emerging angle. Be specific, no filler." \
-m grok-build --yolo --max-turns 10 --disallowed-tools web_fetch --output-format json | jq -r '.text'News / live web research:
grok -p "What's the latest on <TOPIC> as of this week? Give 3-5 key developments, each one line with a source link, then a 2-sentence takeaway." \
-m grok-build --yolo --max-turns 8 --disallowed-tools web_fetch --output-format json | jq -r '.text'Good prompting
- Ask for concrete output: handles, URLs, quotes, dates, sentiment — not vague summaries.
- State the time window ("last 48h", "this week").
- One focused question per call. For a different angle, make a second call.
- Keep
<your question>as a single double-quoted string; escape inner quotes or use single quotes inside.
Follow-ups (same grok session)
Capture the session id, then continue for cheaper, context-aware follow-ups:
SID=$(grok -p "<first question>" -m grok-build --yolo --max-turns 8 --disallowed-tools web_fetch --output-format json | jq -r '.sessionId')
grok -p "<follow-up>" --resume "$SID" -m grok-build --yolo --max-turns 8 --disallowed-tools web_fetch --output-format json | jq -r '.text'After you get results
Treat grok's output as a fresh source: summarize it for the user and keep the source links/@handles so they can verify. Note it's live data (may be noisy or unverified). If it returns empty or errors, retry once with a tighter prompt or a longer timeout before giving up.
Notes
- This skill uses
-m grok-build(the Grok model).grok-composer-2.5-fastis the CLI default but the composer model is not what we want here. - For richer general web research (not X-specific), prefer the existing Exa tooling per global rules; reach for
grokwhen you specifically want X/Twitter or want xAI's live take. - Requires the
grokCLI installed and authenticated (curl -fsSL https://x.ai/cli/install.sh | bash, thengrok login) andjqon PATH.
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.

