# Linkedin Hook Extractor

Reverse-engineer the hook formula from a viral LinkedIn post URL.

- Repository: https://github.com/sergebulaev/linkedin-skills (5474 stars)
- Category: Writing
- License: MIT
- Last updated: 2026-10-27
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add sergebulaev/linkedin-skills --skill linkedin-hook-extractor -g -a claude-code -y`
Codex: `npx skills add sergebulaev/linkedin-skills --skill linkedin-hook-extractor -g -a codex -y`
Cursor: `npx skills add sergebulaev/linkedin-skills --skill linkedin-hook-extractor -g -a cursor -y`
Gemini CLI: `npx skills add sergebulaev/linkedin-skills --skill linkedin-hook-extractor -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add sergebulaev/linkedin-skills`

## Description

Reverse-engineer the hook formula from a viral LinkedIn post URL. Returns which of the 20 canonical 2026 formulas it uses (anaphora, R.I.P., year-pivot, time-anchor, curiosity-gap, contrarian, comment-gate, emotional cold-open, named-gratitude, and 11 more), why it worked, and a blank template. Use to learn from a competitor's post, not to write your own (use linkedin-post-writer).

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# LinkedIn Hook Extractor

Paste a viral LinkedIn post URL. Get back: which hook formula it uses, the exact structure, why it worked, and a blank template mapped to your topic.

## When to use

- User finds a viral post they want to study
- User wants to replicate a specific creator's pattern
- Before `linkedin-post-writer` to seed a draft with a proven structure

## Input

A LinkedIn post URL (any type: activity, share, ugcPost).

## Output

- **Formula identified** (F1-F20 from `../../references/hook-formulas.md`) with confidence score
- **Structural breakdown:**
  - Hook lines (first 210 chars)
  - Body architecture (sections + what each does)
  - Close pattern
  - Reaction-triggering devices (numbers, named entities, vulnerabilities)
- **Why it worked** psychologically
- **Blank template** filled with slot markers matched to the original, ready for the user's voice
- **Cautions:** anything in the original post that would fail 2026 audit (em dashes above the cap, AI vocab, outdated tactics), plus the 2026 reach-note flags from `../../references/hook-formulas.md`: a question as line 1, a "Here's what/how" or "Stop X, start Y" opener, a "The result?" / "Plot twist:" bridge, an unpaid curiosity gap, "comment X to get Y" bait, or announced candor with no dated fact. A viral source post may have used these; the template should not copy them.

## Steps

1. **Parse URL.** `lib.url_parser.parse_linkedin_url` → `post_urn`.
2. **Fetch post body.** If `APIFY_TOKEN` is set, call `lib.ApifyClient.fetch_post(url)`. Otherwise ask the user to paste the text.

The rest: https://github.com/sergebulaev/linkedin-skills/blob/HEAD/.codex-marketplace/linkedin-skills/skills/linkedin-hook-extractor/SKILL.md
