Reverse-engineer the hook from a viral X tweet or thread URL
X hook extractor

Reverse-engineer the hook from a viral X (Twitter) tweet or thread URL. Identifies which of the 10 canonical 2026 X formulas it uses (one-liner contrarian, data-point, build-in-public, quote-tweet, mini-list, relatable cold-open,…
--- name: x-hook-extractor description: "Reverse-engineer the hook from a viral X (Twitter) tweet or thread URL. Identifies which of the 10 canonical 2026 X formulas it uses (one-liner contrarian, data-point, build-in-public, quote-tweet, mini-list, relatable cold-open, listicle-thread, story thread, curiosity-gap, how-I teardown), explains why it worked, and returns a blank template mapped to your topic with its primary goal. Use to learn from a tweet you admire. Not for writing your own (use x-post-writer or x-thread-builder)." --- # X Hook Extractor Paste a viral tweet or thread URL. Get back: which hook formula it uses, the exact structure, why it worked, and a blank template you can fill with your own voice. ## When to use - User finds a viral tweet or thread they want to study - User wants to replicate a specific creator's pattern - Before `x-post-writer` or `x-thread-builder`, to seed a draft with a proven shape ## Input
Overview
Paste a viral tweet or thread URL. Get back: which hook formula it uses, the exact structure, why it worked, and a blank template you can fill with your own voice.
What you get
- Formula identified(X1-X10 from ../../references/hook-formulas.md) with a
- Containersingle tweet vs thread, and why that container fit the idea
- Structural breakdown
- The hook line (and for a thread, how tweet 1 opens the loop)
- Body architecture (per-tweet roles for a thread)
- The close (what earns the repost or bookmark)
Manual install (npx, ZIP)
npx skills add sergebulaev/x-skills --skill x-hook-extractor -g -a claude-codemkdir -p ~/.claude/skills && curl -sL https://codeload.github.com/sergebulaev/x-skills/tar.gz/061109fdcb0b \
| tar -xz -C ~/.claude/skills --strip-components=4 x-skills-061109fdcb0b/.codex-marketplace/x-skills/skills/x-hook-extractorNew-Item -ItemType Directory -Force "$HOME\.claude\skills" | Out-Null; Invoke-WebRequest "https://m.agentalley.io/zip/33cb612ed98d90e41f2f/x-hook-extractor.zip" -OutFile "$env:TEMP\x-hook-extractor.zip"; Expand-Archive "$env:TEMP\x-hook-extractor.zip" -DestinationPath "$HOME\.claude\skills" -ForceConnects with Agent Alley MCP · agentalley.io/mcp
Files included
SKILL.md3.8 KBreferences/2 files · 6.2 KB
Read the files here
sergebulaev/
Shared references1SKILL.md reads these from elsewhere in the repo. Not in the ZIP.
Get them on GitHub ↗Show the full text84 lines
X Hook Extractor
Paste a viral tweet or thread URL. Get back: which hook formula it uses, the exact structure, why it worked, and a blank template you can fill with your own voice.
When to use
- User finds a viral tweet or thread they want to study
- User wants to replicate a specific creator's pattern
- Before
x-post-writerorx-thread-builder, to seed a draft with a proven shape
Input
An X tweet or thread URL (x.com or twitter.com, /status/<id>). For a thread,
the URL of the first tweet is best.
Output
- Formula identified (X1-X10 from
../../references/hook-formulas.md) with a confidence score - Container: single tweet vs thread, and why that container fit the idea
- Structural breakdown:
- The hook line (and for a thread, how tweet 1 opens the loop)
- Body architecture (per-tweet roles for a thread)
- The close (what earns the repost or bookmark)
- Reaction-triggering devices (numbers, named entities, the open loop)
- Primary goal the original chased (replies / reposts / likes / bookmarks)
- Why it worked psychologically and algorithmically
- Blank template with
{slot}markers matched to the original, ready for the user's topic - Cautions: anything in the original that would fail a 2026 audit (more than one em dash in a tweet, an AI-vocab cluster, 3+ hashtags, link in tweet 1)
Steps
- Parse the URL.
lib.url_parser.parse_x_url(url)returnshandle,tweet_id,url_type. - Get the text. This bundle has no built-in tweet reader, so ask the user to paste the tweet or the full thread text. (If they later wire an Apify tweet actor, read it automatically.)
- Detect the container. One self-contained tweet, or a multi-tweet thread.
- Classify against the 11 formulas using features:
- Single tweet: a flat contrarian claim (X1)? one hard number (X2)? a personal metric/confession (X3)? a quote tweet adding a layer (X4)? a one-line-per- item list (X5)? a relatable shared moment (X6)?
- Thread: a numbered teaching promise (X7)? a story starting at the tension (X8)? a surprising result with the mechanism withheld (X9)? a first-person "how I" teardown (X10)?
- Score confidence. If two formulas fit, return the top 2 with fit scores.
- Extract structure. Label each part by its role. For a thread, map tweet 1 (the loop), the front-loaded payoff, the body beats, and the closer.
- Name the primary goal the original optimized for.
- Generate a blank template with
{slot}markers matched to the original shape and the user's topic. - Audit the source. Flag any AI tells in the original so the user does not copy them.
Example
See references/examples.md for worked teardowns.
Formulas reference
See ../../references/hook-formulas.md for the 11 canonical X formulas with full
skeletons and goal tags.
Files
SKILL.md- this filereferences/classification-rules.md- feature extraction + scoring heuristicsreferences/examples.md- worked teardowns (single tweet and thread)
Related skills
x-post-writer- use the extracted single-tweet template to draft your ownx-thread-builder- use the extracted thread templatex-humanizer --mode audit- audit your draft before shipping
| 1 | |
| 2 | name x-hook-extractor |
| 3 | description "Reverse-engineer the hook from a viral X (Twitter) tweet or thread URL. Identifies which of the 10 canonical 2026 X formulas it uses (one-liner contrarian, data-point, build-in-public, quote-tweet, mini-list, relatable cold-open, listicle-thread, story thread, curiosity-gap, how-I teardown), explains why it worked, and returns a blank template mapped to your topic with its primary goal. Use to learn from a tweet you admire. Not for writing your own (use x-post-writer or x-thread-builder)." |
| 4 | |
| 5 | |
| 6 | # X Hook Extractor |
| 7 | |
| 8 | Paste a viral tweet or thread URL. Get back: which hook formula it uses, the |
| 9 | exact structure, why it worked, and a blank template you can fill with your own |
| 10 | voice. |
| 11 | |
| 12 | ## When to use |
| 13 | |
| 14 | User finds a viral tweet or thread they want to study |
| 15 | User wants to replicate a specific creator's pattern |
| 16 | Before `x-post-writer` or `x-thread-builder`, to seed a draft with a proven shape |
| 17 | |
| 18 | ## Input |
| 19 | |
| 20 | An X tweet or thread URL (x.com or twitter.com, `/status/<id>`). For a thread, |
| 21 | the URL of the first tweet is best. |
| 22 | |
| 23 | ## Output |
| 24 | |
| 25 | **Formula identified** (X1-X10 from `../../references/hook-formulas.md`) with a |
| 26 | confidence score |
| 27 | **Container:** single tweet vs thread, and why that container fit the idea |
| 28 | **Structural breakdown:** |
| 29 | The hook line (and for a thread, how tweet 1 opens the loop) |
| 30 | Body architecture (per-tweet roles for a thread) |
| 31 | The close (what earns the repost or bookmark) |
| 32 | Reaction-triggering devices (numbers, named entities, the open loop) |
| 33 | **Primary goal** the original chased (replies / reposts / likes / bookmarks) |
| 34 | **Why it worked** psychologically and algorithmically |
| 35 | **Blank template** with `{slot}` markers matched to the original, ready for the |
| 36 | user's topic |
| 37 | **Cautions:** anything in the original that would fail a 2026 audit (more |
| 38 | than one em dash in a tweet, an AI-vocab cluster, 3+ hashtags, link in tweet 1) |
| 39 | |
| 40 | ## Steps |
| 41 | |
| 42 | **Parse the URL.** `lib.url_parser.parse_x_url(url)` returns `handle`, |
| 43 | `tweet_id`, `url_type`. |
| 44 | **Get the text.** This bundle has no built-in tweet reader, so ask the user to |
| 45 | paste the tweet or the full thread text. (If they later wire an Apify tweet |
| 46 | actor, read it automatically.) |
| 47 | **Detect the container.** One self-contained tweet, or a multi-tweet thread. |
| 48 | **Classify against the 11 formulas** using features: |
| 49 | Single tweet: a flat contrarian claim (X1)? one hard number (X2)? a personal |
| 50 | metric/confession (X3)? a quote tweet adding a layer (X4)? a one-line-per- |
| 51 | item list (X5)? a relatable shared moment (X6)? |
| 52 | Thread: a numbered teaching promise (X7)? a story starting at the tension |
| 53 | (X8)? a surprising result with the mechanism withheld (X9)? a first-person |
| 54 | "how I" teardown (X10)? |
| 55 | **Score confidence.** If two formulas fit, return the top 2 with fit scores. |
| 56 | **Extract structure.** Label each part by its role. For a thread, map tweet 1 |
| 57 | (the loop), the front-loaded payoff, the body beats, and the closer. |
| 58 | **Name the primary goal** the original optimized for. |
| 59 | **Generate a blank template** with `{slot}` markers matched to the original |
| 60 | shape and the user's topic. |
| 61 | **Audit the source.** Flag any AI tells in the original so the user does not |
| 62 | copy them. |
| 63 | |
| 64 | ## Example |
| 65 | |
| 66 | See `references/examples.md` for worked teardowns. |
| 67 | |
| 68 | ## Formulas reference |
| 69 | |
| 70 | See `../../references/hook-formulas.md` for the 11 canonical X formulas with full |
| 71 | skeletons and goal tags. |
| 72 | |
| 73 | ## Files |
| 74 | |
| 75 | `SKILL.md` - this file |
| 76 | `references/classification-rules.md` - feature extraction + scoring heuristics |
| 77 | `references/examples.md` - worked teardowns (single tweet and thread) |
| 78 | |
| 79 | ## Related skills |
| 80 | |
| 81 | `x-post-writer` - use the extracted single-tweet template to draft your own |
| 82 | `x-thread-builder` - use the extracted thread template |
| 83 | `x-humanizer --mode audit` - audit your draft before shipping |
| 84 |
Details
- Updated
- Sep 17, 2026
- License
- MIT
- Stars on the repo
- ★ 95
- Checked
- Source
- sergebulaev/x-skills ↗
- Creator
- sergebulaev · 77 listings
Similar skills
See all →
SkillResearch what people actually say about any topicSTEP 0: STALE-CLONE SELF-CHECK — RUN BEFORE READING BELOW
SkillScrapes social platforms, business dataApify
Skill微信公众号长文增长闭环 ——
SkillSearch and retrieve content from Twitter/XTwitter/X Skill
SkillSays 'YouTube script', 'video script'🎬 YouTube Script: Writing retention-optimized video script...
SkillAgent Reach — 互联网能力路由器More from sergebulaev
SkillBy density per paragraph, not per wordAI Tells — Complete Blacklist (V3, 2026-09)
SkillFifteen rules from the linkedin-humanizer packageAI-Tell Rules: Tier-Classified Reference
SkillPattern data from MagicPost LinkedIn analysisEmoji Patterns — AI vs. Human
SkillRead your Instagram niche and profile from real dataInstagram Audience Insights
SkillDraft an Instagram caption with the hook in the first 125Instagram Caption Writer
SkillPlan an Instagram carousel slide by slide, up to 10 slidesInstagram Carousel Planner