insert-wiki

Use when capturing a single URL (X tweet, LinkedIn post, HN thread, short blog, news article, GitHub gist or issue) as a small persistent markdown entry the user can re-read later for motivation or grep across future sessions. Verbatim body + author + tags + a one-line "Why I saved this" hook. Writes to docs/wikis/YYYY-MM-DD-<slug>.md. WebFetch by default; CDP via Playwright MCP for login-walled hosts (x.com, twitter.com, linkedin.com). Redirects YouTube / arXiv / GitHub repo URLs to their specialized skills. Triggers: "insert wiki", "add to wiki", "insert this", "save this tweet", "capture this post", "add this to my wiki", "remember this link", "https://x.com/", "https://twitter.com/", "https://linkedin.com/posts/"

10 stars

Best use case

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

Use when capturing a single URL (X tweet, LinkedIn post, HN thread, short blog, news article, GitHub gist or issue) as a small persistent markdown entry the user can re-read later for motivation or grep across future sessions. Verbatim body + author + tags + a one-line "Why I saved this" hook. Writes to docs/wikis/YYYY-MM-DD-<slug>.md. WebFetch by default; CDP via Playwright MCP for login-walled hosts (x.com, twitter.com, linkedin.com). Redirects YouTube / arXiv / GitHub repo URLs to their specialized skills. Triggers: "insert wiki", "add to wiki", "insert this", "save this tweet", "capture this post", "add this to my wiki", "remember this link", "https://x.com/", "https://twitter.com/", "https://linkedin.com/posts/"

Teams using insert-wiki 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/insert-wiki/SKILL.md --create-dirs "https://raw.githubusercontent.com/dongzhuoyao/tao-research-skills/main/skills/research/insert-wiki/SKILL.md"

Manual Installation

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

How insert-wiki Compares

Feature / Agentinsert-wikiStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Use when capturing a single URL (X tweet, LinkedIn post, HN thread, short blog, news article, GitHub gist or issue) as a small persistent markdown entry the user can re-read later for motivation or grep across future sessions. Verbatim body + author + tags + a one-line "Why I saved this" hook. Writes to docs/wikis/YYYY-MM-DD-<slug>.md. WebFetch by default; CDP via Playwright MCP for login-walled hosts (x.com, twitter.com, linkedin.com). Redirects YouTube / arXiv / GitHub repo URLs to their specialized skills. Triggers: "insert wiki", "add to wiki", "insert this", "save this tweet", "capture this post", "add this to my wiki", "remember this link", "https://x.com/", "https://twitter.com/", "https://linkedin.com/posts/"

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

# Insert Wiki

## When to Use

- Capturing a single URL as a small commonplace-book entry: X tweet, LinkedIn post, HN thread, short blog post, news article, GitHub gist or single issue
- Building up a personal wiki under `docs/wikis/` that you can come back to for motivation or grep across future sessions
- Any prompt that pastes a URL with intent like "insert", "add to wiki", "save this", "remember this", "capture this"

Not for:
- YouTube videos → use `youtube-wiki` (richer, timestamped output under `docs/videos/`)
- arXiv papers → use `arxiv-latex-reader`
- GitHub repository roots → use `github-reader`
- Long-form technical blog posts where you want a faithful figure-aware digest → use `blog-reader`
- PDFs → use `pdf-reader`

When the URL matches one of the specialized cases above, **stop and hand off** — do not internally dispatch.

## Output

A single markdown file at `docs/wikis/YYYY-MM-DD-<slug>.md`:

```markdown
---
source: <url>
author: "@handle" | "Author Name"
posted: YYYY-MM-DD          # omit if unknown
captured: YYYY-MM-DD          # today
host: x.com | linkedin.com | <domain>
kind: tweet | thread | blog | article | post
tags: [tag-1, tag-2]          # 2-4, lowercase-kebab
---

# <Title or first ~8 words of body>

**Source**: [<short-display-url>](<url>) · **By** <author> · **Captured** YYYY-MM-DD

> <verbatim body — full tweet, or full thread joined with blank `>` lines>

**Why I saved this**: <1-2 sentences, or `<add motivation hook>` placeholder>
```

The entry is a door back to the source plus a small motivation hook — not a digest. Keep it short on purpose. If you find yourself writing a TL;DR or a key-points list, the wrong skill is loaded; route to `blog-reader` or `youtube-wiki` instead.

## Pipeline

```
┌───────────────────────────────┐
│ 1. Classify host              │  redirect → specialized skill if matched
└──────────┬────────────────────┘  CDP for login-walled hosts
           ▼                       WebFetch for the rest
┌───────────────────────────────┐
│ 2. Fetch                      │  raw text + author + posted date
└──────────┬────────────────────┘
           ▼
┌───────────────────────────────┐
│ 3. Derive slug                │  <handle>-<first-5-words> | <title-first-5>
└──────────┬────────────────────┘
           ▼
┌───────────────────────────────┐
│ 4. Compose entry              │  frontmatter + verbatim body + hook
└──────────┬────────────────────┘
           ▼
┌───────────────────────────────┐
│ 5. Write + verify             │  4-check verification (see below)
└──────────┬────────────────────┘
           ▼
   docs/wikis/YYYY-MM-DD-<slug>.md
```

## Step 1 — Classify the host

Parse the URL and route:

| Host pattern | Action |
|---|---|
| `x.com/<handle>/status/<id>`, `twitter.com/<handle>/status/<id>` | Go to Step 2 via **CDP** |
| `linkedin.com/posts/...`, `linkedin.com/pulse/...` | Go to Step 2 via **CDP** |
| `youtu.be/<id>`, `youtube.com/watch?v=<id>` | **Stop.** "This is a YouTube URL — invoke `youtube-wiki` instead. It produces a richer, timestamped digest under `docs/videos/`." |
| `arxiv.org/abs/<id>`, `arxiv.org/pdf/<id>` | **Stop.** "Use `arxiv-latex-reader` for arXiv papers." |
| `github.com/<owner>/<repo>` (repo root, no path beyond) | **Stop.** "Use `github-reader` for GitHub repositories." |
| `github.com/<owner>/<repo>/issues/...`, `gist.github.com/...` | Go to Step 2 via **WebFetch** |
| Anything else | Go to Step 2 via **WebFetch** |

## Step 2 — Fetch

### 2a. CDP path (login-walled hosts)

Use Playwright MCP browser tools (already wired to the user's authenticated Chrome session on port 9222, profile `chrome-debug-v2`).

```
playwright__browser_navigate(url=<url>)
playwright__browser_snapshot()
```

From the snapshot extract:
- Tweet / post body text (verbatim, preserve line breaks)
- Author display name + handle
- Posted timestamp (often in a `<time datetime="...">` attribute → convert to `YYYY-MM-DD`)
- For X threads: walk the thread by collecting all tweets from the same author posted in reply chain, in order
- Embedded images: capture URL + alt text, render as `[image: <alt>](<url>)`

If CDP is unreachable (browser closed, port 9222 not bound, navigation fails), **stop and surface**:

```
Chrome CDP unavailable on 9222. Start it with:
  /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome \
    --remote-debugging-port=9222 --user-data-dir="$HOME/chrome-debug-v2"
Then re-run. If logged out, invoke /login-cdp first.
```

**Do not fall back to WebFetch** for login-walled hosts — it will capture a login wall and silently call it the post. Per the repo's no-silent-fallbacks rule.

### 2b. WebFetch path (everything else)

Plain `WebFetch` against the URL. From the returned content extract:
- Main body text (the article / post / issue, not nav or footer)
- Author (from byline, `meta` tags, or HN post header)
- Posted date (best-effort; omit `posted:` from frontmatter if not findable — don't invent)
- Page title

If WebFetch returns an empty body, an obvious login wall, or a paywall stub: **stop and surface** the specific failure. Don't paper over it.

## Step 3 — Derive the slug

Filename: `docs/wikis/YYYY-MM-DD-<slug>.md` where `YYYY-MM-DD` is today's date.

| Source type | Slug recipe |
|---|---|
| X tweet | `<handle>-<first-5-words-of-tweet>` |
| LinkedIn post | `<handle-or-author-last-name>-<first-5-words>` |
| Generic web page | `<first-5-words-of-page-title>` |
| HN thread | `hn-<first-5-words-of-title>` |
| GitHub gist | `gist-<owner>-<first-5-words-of-description>` |

Normalize: lowercase, kebab-case, strip emoji and punctuation, collapse repeated `-`, max 50 chars. Examples:
- `2026-05-11-techshiba-fastest-way-to-learn-agents.md`
- `2026-05-11-paulg-the-best-essays-are-rewrites.md`
- `2026-05-11-hn-show-hn-a-typed-jq-replacement.md`

**Collision**: if the slug already exists at the same date, append `-2`, `-3`. Never overwrite.

## Step 4 — Compose the entry

Fill the template (see "Output" above). Rules:

- **Body must be verbatim.** A tweet is so short that paraphrase is misquote. Preserve line breaks, emoji, and capitalization. Only filler artifacts injected by the scraper (e.g. literal "Show this thread" UI strings) may be stripped.
- **Threads**: each tweet on its own blockquote paragraph, separated by a blank `>` line. Maintain order.
- **Embedded media**: inline `[image: <alt or caption>](<url>)`. Do not download.
- **Author**: prefer `"@handle"` for social hosts, `"Author Name"` for blogs. Quote the value in YAML to keep the `@` safe.
- **Tags**: pick 2-4 lowercase-kebab tokens drawn from the content (e.g. `motivation`, `agentic-eng`, `taste`, `hpc`). These are the grep handles for future sessions.
- **`Why I saved this`**: draft a 1-2 sentence hook synthesizing (a) what the post says and (b) any framing the user gave when handing you the URL (e.g. "I want motivation from this", "this captures taste"). If the user said nothing beyond "insert this", write the literal placeholder `<add motivation hook>` rather than fabricating motivation that wasn't theirs.

## Step 5 — Write + verify

Write the file with `Write`, then run all four checks:

```bash
# 1. File exists at expected path
test -f docs/wikis/YYYY-MM-DD-<slug>.md

# 2. Frontmatter has the required fields
head -20 docs/wikis/YYYY-MM-DD-<slug>.md | grep -E '^(source|author|captured|host|kind|tags):'

# 3. Body contains a verbatim blockquote
grep -E '^> ' docs/wikis/YYYY-MM-DD-<slug>.md

# 4. Motivation hook line present
grep -F 'Why I saved this' docs/wikis/YYYY-MM-DD-<slug>.md
```

Any failure → stop, surface which check failed, do not report success.

Report the relative path of the new file so the user can open it.

## Anti-Patterns

- **Paraphrasing the captured body.** Verbatim only — even when the post is grammatically loose or has typos.
- **Inventing the "Why I saved this" hook.** If the user gave no framing, leave the `<add motivation hook>` placeholder. Don't fabricate motivation.
- **Silent fallback to WebFetch on `x.com` / `linkedin.com`.** Login-walled hosts must use CDP; if CDP is down, hard stop with the startup command.
- **Auto-running `youtube-wiki` / `arxiv-latex-reader` / `github-reader` internally.** When the URL matches a specialized skill's host, tell the user to invoke that skill. Don't couple skills via shell-out.
- **Downloading attachments.** Reference inline (`[image: ...](url)`); no media files in the repo.
- **Overwriting an existing wiki entry.** Append `-2` / `-3` to the slug.
- **Forgetting the date prefix** on the filename — breaks chronological sort and grep-by-date.
- **Heavy multi-section digest** for a 280-char tweet. If you're writing a TL;DR or a People-mentioned table, the wrong skill is loaded — route to `blog-reader` or `youtube-wiki`.
- **Inventing the `posted:` date** when the source doesn't expose it. Omit the field instead.
- **Unquoted `@handle` in YAML.** YAML treats `@` specially at the start of a scalar — always wrap the author value in double quotes.

## Example Invocation

```
Insert this tweet: https://x.com/TechShiba/status/2053440457934262776
```

Expected outcome: `docs/wikis/2026-05-11-techshiba-<first-words>.md` written, frontmatter parses, verbatim tweet body in a blockquote, motivation hook either drafted from context or left as `<add motivation hook>`, all four verification checks pass.

```
Insert https://youtu.be/abc123
```

Expected outcome: **stop**, with: "This is a YouTube URL — invoke `youtube-wiki` instead. It produces a richer, timestamped digest under `docs/videos/`."

## See Also

- `youtube-wiki` — Specialized skill for YouTube videos. Insert-wiki redirects YouTube URLs here.
- `blog-reader` — For long-form technical blog posts that warrant a full figure-aware digest. Insert-wiki is the lightweight cousin for short posts.
- `arxiv-latex-reader` — For arXiv papers. Insert-wiki redirects arXiv URLs here.
- `pdf-reader` — For PDFs. Insert-wiki does not handle PDFs.
- `github-reader` — For GitHub repository roots. Insert-wiki handles only gists and individual issues.
- `login-cdp` — Refresh authenticated CDP sessions when X / LinkedIn capture fails because the session expired.
- `github-cli` — Patterns for `gh api` when capturing GitHub issues without WebFetch flakiness.

Related Skills

youtube-wiki

10
from dongzhuoyao/tao-research-skills

Use when reading a YouTube video (especially an AI/ML interview, podcast, or technical talk) and producing a faithful, timestamped wiki entry the user can return to weeks later. Fetches the transcript via yt-dlp, sections by chapters or LLM-detected topics, summarizes per-section with parallel subagents, preserves verbatim quotes with speaker attribution, and runs a coverage test against the raw transcript. Triggers: "youtube wiki", "video wiki", "summarize this youtube", "watch this interview", "read this talk", "digest this video", "https://youtu.be/", "https://www.youtube.com/watch"

ml-ablation-design

10
from dongzhuoyao/tao-research-skills

Use when designing ablation studies to compare model components, loss functions, or architectural choices. Covers synthetic data experiments, variant loops, production metrics, and W&B grouping. Triggers: "ablation", "ablation study", "variant comparison", "controlled experiment", "synthetic data experiment"

gpu-training-acceleration

10
from dongzhuoyao/tao-research-skills

Use when optimizing PyTorch training speed or memory on CUDA GPUs — global flags, torch.compile, fused optimizers, mixed precision, gradient checkpointing, kernel fusion, memory layout, or latent-space training. Applies to any PyTorch training workload. Triggers: "torch.compile", "TF32", "fused optimizer", "mixed precision", "bf16", "fp16", "gradient checkpointing", "Triton kernel", "CUDA flags", "GPU slow", "GPU memory"

genai-evaluation-metrics

10
from dongzhuoyao/tao-research-skills

Use when evaluating generative models — choosing metrics (FID, IS, KID, sFID, FDD, FVD, PRDC, LPIPS, SSIM, AuthPct, Vendi), setting up online or offline evaluation, feature extractor selection, distributed computation, memory management during sampling. Triggers: "FID", "IS", "KID", "inception score", "frechet", "LPIPS", "SSIM", "evaluation metrics", "generative evaluation", "FVD"

pdf-reader

10
from dongzhuoyao/tao-research-skills

Use when reading PDF papers, reports, or long documents where text, figures, and tables must all be captured and chunk-summarized without truncation. Converts PDF to a markdown + paper_content.json workspace, extracts figures and tables as standalone files, then delegates to arxiv-latex-reader's progressive two-layer reading (section index + on-demand deep reads). Triggers: "read pdf", "pdf to markdown", "summarize pdf", "pdf paper", "extract figures from pdf", "extract tables from pdf", "marker pdf", "pymupdf", "docling", "paper digest", "pdf reader"

idea-feasibility

10
from dongzhuoyao/tao-research-skills

Use when evaluating whether a research or product idea is actually feasible — buildable, evaluable, and de-risked by available checkpoints, code, datasets, and GPU budget. Normalizes the idea, gathers primary-source evidence (arXiv, GitHub, project pages, model hosts), scores it against four mandatory hard gates, and emits a verdict + falsifiable MVP. Triggers: "idea feasibility", "is this idea feasible", "feasibility check", "can we do this", "is this practical", "worth pursuing", "评估想法可行性", "可行性分析", "这个 idea 能做吗", "这个想法靠谱吗"

idea-explore

10
from dongzhuoyao/tao-research-skills

Use when proposing new research ideas grounded in a seed paper or method — surfaces the gaps that the citation cone hasn't filled, the drawbacks the community already complains about in the official repo's GitHub issues, and the adjacent angles the literature suggests. Orchestrates followup-analysis (already-done exclusion), GitHub-issue mining (known drawbacks), and academic-deep-research (adjacent literature) into a ranked candidate-ideas report. Triggers: "idea explore", "idea-explore", "propose ideas", "explore ideas", "new directions", "research gaps", "what's missing", "build on this paper", "探索想法", "提出新想法", "研究空白"

idea-box

10
from dongzhuoyao/tao-research-skills

Use when promoting an idea from a fleeting thought into a tracked artifact with a lifecycle. Defines a per-idea on-disk directory (./idea_box/<slug>/) and a hard-gated state machine (explored → feasible/blocked → building → built/killed) that the existing reader/evaluator skills (idea-feasibility, ml-ablation-design, academic-deep-research, followup-analysis, arxiv-latex-reader, pdf-reader, github-reader, blog-reader) plug into. Public repo ships only the convention; idea data lives in the user's private idea-box repo. Triggers: "idea box", "idea-box", "new idea", "advance idea", "list ideas", "kill idea", "想法箱", "新想法", "推进想法", "列出想法"

github-reader

10
from dongzhuoyao/tao-research-skills

Use when reading a GitHub repository (especially a research code release with an accompanying paper) and producing a faithful digest that covers the implementation logic, the main insight, and the key reported results. Research-first with graceful fallback for non-paper repos. Handles arXiv link detection and delegates paper reading to arxiv-latex-reader / pdf-reader. Triggers: "read repo", "read this github", "analyze github", "digest repo", "github reader", "extract from github", "summarize this codebase", "read this code", "https://github.com/"

blog-reader

10
from dongzhuoyao/tao-research-skills

Use when reading a long technical blog post (ML research, engineering deep-dives, Distill/Lil'Log-style posts) and producing a faithful, figure-aware summary. Handles context-over-limit via section-based chunking, captures important figures via multimodal Read, and runs a coverage test to catch missing information. Triggers: "read this blog", "summarize this post", "read blog", "digest this article", "long blog post", "read this article", "blog summary", "distill post", "summarize url", "chunk and summarize"

arxiv-latex-reader

10
from dongzhuoyao/tao-research-skills

Use when reading large arxiv papers without context overflow. Progressive two-layer reading: index all sections (~2k tokens), then deep-read on demand. Never truncates. Triggers: "read paper", "paper sections", "section index", "progressive reading", "paper_content.json", "section summary"

academic-deep-research

10
from dongzhuoyao/tao-research-skills

Use when evaluating academic papers or surveying a research topic. Gathers venue, citations, GitHub stats, social buzz, reproducibility, and author signals to produce a scored markdown report. Triggers: "evaluate paper", "paper review", "research survey", "literature review", "is this paper good", "find papers on", "compare papers", "paper impact"