xai-grok

Use xAI Grok API with Agent Tools for real-time web and X (Twitter) search and synthesis. Requires XAI_API_KEY.

Best use case

xai-grok is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Use xAI Grok API with Agent Tools for real-time web and X (Twitter) search and synthesis. Requires XAI_API_KEY.

Teams using xai-grok should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/xai-grok/SKILL.md --create-dirs "https://raw.githubusercontent.com/closedloop-technologies/awesome-deep-researchers/main/.claude/skills/xai-grok/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/xai-grok/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How xai-grok Compares

Feature / Agentxai-grokStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Use xAI Grok API with Agent Tools for real-time web and X (Twitter) search and synthesis. Requires XAI_API_KEY.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# xAI Grok Research Skill

This skill utilizes the xAI Grok API and its Agent Tools for autonomous research, including real-time web and X platform search.

## Setup

1.  **Dependencies:** Requires the `xai-sdk`.
    ```bash
    pip install xai-sdk python-dotenv
    ```

2.  **API Key Configuration:** The skill requires the `XAI_API_KEY`.

    ```bash
    # If the script fails due to a missing key, run the following:
    echo "It seems the xAI API key is not set up."
    read -p "Enter your xAI API key: " GROK_KEY
    echo "XAI_API_KEY=$GROK_KEY" >> .env
    if [ -f .gitignore ] && ! grep -q ".env" .gitignore; then echo ".env" >> .gitignore; fi
    echo "API key saved to .env."
    ```

## Usage

Use the `scripts/grok_research.py` script. Grok will autonomously use the enabled tools.

### Command

```bash
python3 scripts/grok_research.py --query "<query>" [--model <model_name>] [--web-search] [--x-search]
```

### Parameters

* `--query` (Required): The research query.
* `--model` (Optional): Defaults to `grok-4.1-fast-reasoning` (optimized for tools).
* `--web-search` (Optional): Enable web search tool.
* `--x-search` (Optional): Enable X (Twitter) search tool.

### Example

```bash
python3 scripts/grok_research.py --query "What is the current public sentiment and news coverage on the latest AI regulations?" --web-search --x-search
```

## Output

The script streams the agent's thought process (to stderr) for visibility and outputs the final synthesized answer (to stdout) with citations.

Related Skills

tavily-search

7
from closedloop-technologies/awesome-deep-researchers

Use Tavily Search API for optimized, real-time web search results for RAG. Requires TAVILY_API_KEY.

stanford-storm

7
from closedloop-technologies/awesome-deep-researchers

Run Stanford STORM (knowledge-storm) to generate comprehensive, Wikipedia-style articles with citations. Requires LLM and Search API keys (Bing or You.com).

smolagents

7
from closedloop-technologies/awesome-deep-researchers

Use Hugging Face Smolagents framework for code-based agentic research with tool support. Supports multiple LLM providers and web search.

perplexity-sonar

7
from closedloop-technologies/awesome-deep-researchers

Use Perplexity Sonar API for real-time, citation-backed answers. Ideal for up-to-date information and quick synthesis. Requires PERPLEXITY_API_KEY

openai-deep-research

7
from closedloop-technologies/awesome-deep-researchers

Use OpenAI's Deep Research API (o3 / o4 models) to automate multi-step, citation-backed research workflows.

langchain-deep-research

7
from closedloop-technologies/awesome-deep-researchers

Run LangChain Open Deep Research agent for iterative web research and comprehensive reports. Requires LLM API keys and search API (e.g., OPENAI_API_KEY, TAVILY_API_KEY).

jina-ai

7
from closedloop-technologies/awesome-deep-researchers

Use Jina AI APIs for converting URLs to LLM-friendly Markdown (Reader) and searching the web (Search).

gpt-researcher

7
from closedloop-technologies/awesome-deep-researchers

Run the GPT Researcher autonomous agent to generate comprehensive deep research reports. Requires LLM and Search API keys (e.g., OPENAI_API_KEY, TAVILY_API_KEY).

exa-research

7
from closedloop-technologies/awesome-deep-researchers

Use Exa AI for neural search, content retrieval, and automated deep research. Requires EXA_API_KEY.

grok-research

3891
from openclaw/skills

Crypto research via Grok model's real-time X/Twitter knowledge. Forwards the user's query as-is to Grok API — no prompt injection, no context bloat. Use when: (1) user asks to research a token's narrative/story/sentiment, (2) user says "调研", "research", "grok research", "查一下叙事", "帮我看看这个币", (3) user wants to know what CT is saying about a token/project. NOT for: price analysis, on-chain data, or trading execution.

grok-scraper

3891
from openclaw/skills

Execute queries to Grok AI via Playwright browser automation without requiring an X API KEY. Use when the user wants to "ask Grok", search X for real-time info, or specifically requests to use Grok for free without API billing.

grok-imagine

3891
from openclaw/skills

Generate images and videos using xAI Grok Imagine Extended. Text-to-image, image editing, text-to-video, image-to-video. Use when: user asks to generate, create, or draw an image, or create/animate a video. NOT for: image analysis/understanding (use the image tool instead). Triggers: generate image, create image, draw, grok imagine, make a picture, text to image, generate video, animate, text to video.