x-research
X/Twitter research via xAI Grok API with x_search tool. Digests, thread analysis, trending topics, custom search. Designed for finding Telegram post ideas…
от artwist-polyakov★ 242 звезды на GitHub
Установить x-research в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
x-research
Research X/Twitter via xAI Grok API. Grok's x_search tool searches X in real-time and returns synthesized analysis with citations.
Перед запуском
Перед любым запуском скриптов создай рабочую копию скилла в /home/claude/x-research и работай уже из неё:
sh scripts/prepare_runtime.sh
cd /home/claude/x-research
prepare_runtime.sh копирует скилл и, если есть config/.env, нормализует его через sed -i: некавыченные значения с пробелами оборачиваются в кавычки в рабочей копии. Не выводи содержимое .env в ответ; при ошибке формата подскажи пользователю, какие строки нужно заключить в кавычки.
Config
Get an xAI API key at console.x.ai, then:
cp config/.env.example config/.env
Edit config/.env: paste your key into XAI_API_KEY, configure accounts and topics.
Quote any value that contains spaces so the file stays shell-compatible. Шаг подготовки также чинит некавыченные значения с пробелами в скопированном .env.
Without .env: skill works with explicit --accounts, --query, --topics.
With .env: digests and trending ready out of the box.
Category registry (same pattern as telegram-channel-parser):
X_CATEGORIES=ai,crypto # available categories
X_DEFAULT_CATEGORY=ai # default for "digest" without specifying
X_ACCOUNTS_AI_LABEL="AI & ML"
X_ACCOUNTS_AI=elonmusk,sama,AndrewYNg
X_TOPICS_AI=AI,LLM,GPT,Claude,agents,AGI
Agent algorithm for digest/trending:
- Read
config/.env - Parse
X_CATEGORIESto get available categories - For each:
X_ACCOUNTS_<ID>= handles,X_TOPICS_<ID>= topics,X_ACCOUNTS_<ID>_LABEL= name - Match user request to category label or use
X_DEFAULT_CATEGORY - Pass to script via
--accounts/--topics
Priority: --accounts/--topics explicit > category from .env > agent asks.
Details: config/README.md.
Philosophy
- Live-first — every call makes a fresh API request. Real-time data, never stale.
- Artifact store — each run saves an immutable snapshot in
cache/runs/. Use--prefer-cacheto reuse. - Structured output — digest/trending/search return JSON with individual items for machine consumption.
- Context hygiene — stdout limited to 30 lines. Full data in artifact file.
- Config-driven model — model set in
.env, auto-fallback if unavailable.
Workflow
Digest of subscribed accounts
# Default category from .env
bash scripts/digest.sh --period today
# Specific category
bash scripts/digest.sh --category crypto --period week
# Explicit accounts (no .env needed)
bash scripts/digest.sh --accounts "elonmusk,sama" --period today
Returns: structured items (author, date, summary, engagement, URL, topic) + Telegram post ideas.
Analyze a post/thread/topic
# By description
bash scripts/analyze.sh --query "Elon Musk's thread about open source AI"
# By URL
bash scripts/analyze.sh --url "https://x.com/elonmusk/status/123456" --query "context about the post"
# With time period
bash scripts/analyze.sh --query "debate about AI regulation" --period week
Returns: main thesis, key arguments, community reaction, sentiment, interesting findings, Telegram post angles.
Trending topics
# Default topics from .env
bash scripts/trending.sh --period today
# Specific topics
bash scripts/trending.sh --topics "Bitcoin,Ethereum,DeFi" --period today
# Category
bash scripts/trending.sh --category ai --period week
Returns: structured items (topic, summary, sentiment, key voices, engagement) + Telegram post ideas.
Custom search
# Free search
bash scripts/search.sh --query "Claude 4 reactions" --period week
# Search within specific accounts
bash scripts/search.sh --query "AI safety" --accounts "sama,ylecun" --period today
Returns: structured items + narrative summary + Telegram post ideas.
Reuse previous results
# Read last digest without making an API call
bash scripts/digest.sh --category ai --period today --prefer-cache
# Find artifact manually
bash scripts/find_latest.sh --script digest --category ai --period today
Scripts
bash scripts/<script>.sh [params]
| Script | Description | Key params |
|---|---|---|
digest.sh |
Digest of subscribed accounts | --category, --accounts, --period |
analyze.sh |
Deep analysis of post/thread/topic | --query, --url, --period |
trending.sh |
Trending topics by interests | --category, --topics, --period |
search.sh |
Custom search query | --query, --accounts, --period |
find_latest.sh |
Find latest cached artifact | --script, --category, --query, --period |
Common parameters
| Param | Required | Default | Description |
|---|---|---|---|
--accounts |
no | from .env | X handles, comma-separated (without @) |
--category |
no | from .env | Category I |
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- .gitignore
- config/.env.example
- config/README.md
- references/API_REFERENCE.md
- scripts/analyze.sh
- scripts/common.sh
- scripts/digest.sh
- scripts/find_latest.sh
- scripts/prepare_runtime.sh
- scripts/sanitize_env.sh
- scripts/search.sh
- scripts/trending.sh
FAQ
Что делает скилл x-research?
X/Twitter research via xAI Grok API with x_search tool. Digests, thread analysis, trending topics, custom search. Designed for finding Telegram post ideas from X discussions. Triggers: x research, twitter research, x digest, twitter digest, что в твиттере, дайджест твиттера, тренды x, trending x, analyze tweet, анализ твита, x search, поиск в твиттере.
Как установить скилл x-research?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл x-research запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
skill-creator
AnthropicCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
discernment-nudge
AnthropicAfter you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
data-consolidate
AnthropicJoins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
inspection-to-capa
AnthropicRuns the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…