[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75KAMQFC4WHQR3FZRHNFSXM":3,"skill-same:01M75KAMQFC4WHQR3FZRHNFSXM":66},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":39,"commitSha":40,"skillDirectory":41,"forksCount":14,"repositoryHtmlUrl":42,"repositoryHomepageUrl":6,"ownerHtmlUrl":43,"ownerBlogUrl":44,"ownerDescription":45,"updatedAt":46,"install":47,"resources":59},"01M75KAMQFC4WHQR3FZRHNFSXM","citation-fixer",null,"Audit and fix citation formatting across brain pages. Ensures every fact has\nan inline [Source: ...] citation matching the standard format. Extended in\nv0.25.1: scans for broken tweet\u002Fpost references that lack actual URLs and\nresolves them via the host's X \u002F Twitter API integration.","cheRoma\u002Fgbrain-link-chat","cheRoma","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F265356812?v=4","01M75JVGAJEZK04E1THSDHYVNK","Roman Cherepanov","01M75JVGB5SWY40H959C3QXRAQ",0,"MIT","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Fplugin\u002Fskills\u002Fcitation-fixer\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: citation-fixer\nversion: 1.1.0\ndescription: |\n  Audit and fix citation formatting across brain pages. Ensures every fact has\n  an inline [Source: ...] citation matching the standard format. Extended in\n  v0.25.1: scans for broken tweet\u002Fpost references that lack actual URLs and\n  resolves them via the host's X \u002F Twitter API integration.\ntriggers:\n  - \"fix citations\"\n  - \"fix broken citations\"\n  - \"citation audit\"\n  - \"check citations\"\n  - \"citation fixer\"\ntools:\n  - search\n  - get_page\n  - put_page\n  - list_pages\nmutating: true\nwhen_to_use: \"Use when the user asks: \\\"fix citations\\\", \\\"fix broken citations\\\", \\\"citation audit\\\", \\\"check citations\\\", \\\"citation fixer\\\".\"\n---\n\n# Citation Fixer Skill\n\n> **Convention:** see [conventions\u002Fquality.md](..\u002Fconventions\u002Fquality.md) for\n> the canonical citation format every fix should match.\n>\n> **Output rule:** all links MUST be deterministic (built from API data,\n> not composed by LLM). See [_output-rules.md](..\u002F_output-rules.md).\n\n## Contract\n\nThis skill guarantees:\n\n- Every brain page is scanned for citation compliance.\n- Missing citations are flagged with specific location.\n- Malformed citations are fixed to match the standard format.\n- **(v0.25.1)** Tweet \u002F post references without URLs are resolved via\n  X API and patched with deterministic `https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Cid>`\n  links.\n- Results reported with counts (scanned, fixed, remaining).\n\n## Phases\n\n1. **Scan pages.** List pages and read each one, checking for inline\n   `[Source: ...]` citations.\n2. **Identify issues:**\n   - Facts without any citation\n   - Citations missing date\n   - Citations missing source type\n   - Citations with wrong format\n   - **(v0.25.1)** Tweet references without `x.com` URLs\n3. **Fix format issues.** Rewrite malformed citations to match\n   `conventions\u002Fquality.md`.\n4. **(v0.25.1) Resolve tweet references** via the X API integration.\n5. **Report results.** Count: pages scanned, citations found, issues\n   fixed, tweets resolved, remaining gaps.\n\n## Tweet resolution pipeline (v0.25.1 extension)\n\nFor each broken tweet reference, follow this chain. The actual API call\ngoes through whatever X integration the host has configured (typical\nshape: a recipe under `recipes\u002Fx-api\u002F` with handle \u002F search-all\nendpoints).\n\n### Step 1: Identify broken references\n\nScan the page for patterns that indicate tweet references without URLs:\n\n- Contains words like `tweeted`, `posted`, `said on X`, `RT`, `retweet`,\n  `X post`\n- Contains quoted text that looks like a tweet (short, punchy, often\n  starts with a quote)\n- Has `[Source: ... X\u002FTwitter ...]` without an `x.com` URL\n- References engagement metrics (likes, impressions) without a link\n\n### Step 2: Extract searchable content\n\nFrom each broken reference, extract:\n\n- The **handle** (if mentioned: `@\u003Cusername>`)\n- The **quoted text** (if available)\n- The **approximate date** (often present in surrounding timeline entries)\n\n### Step 3: Search for the actual tweet\n\nUse the host's X API integration. Query patterns:\n\n```\n# Handle + quoted text:\nfrom:\u003Chandle> \"\u003Cexact quote fragment>\"\n\n# Quoted text only:\n\"\u003Cexact quote fragment>\"\n\n# Original of a retweet:\n\"\u003Cexact quote>\" -is:retweet\n```\n\n### Step 4: Verify and extract metadata\n\nOnce a candidate is found:\n\n- Confirm the text matches the quoted fragment.\n- Pull the tweet id, author handle, engagement metrics (likes \u002F RTs \u002F\n  impressions).\n- Construct the URL: `https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Ctweet_id>`.\n\n### Step 5: Patch the brain page\n\nReplace the broken citation with a proper one:\n\n**Before:**\n\n```\n\"\u003Cquote fragment>\" [Source: \u003Csome hand-wavy attribution>]\n```\n\n**After:**\n\n```\n\"\u003Cfull verified quote>\" — \u003CN> likes, \u003CN> RTs, \u003CN> impressions\n[Source: [X\u002F\u003Chandle>, YYYY-MM-DD](https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Ctweet_id>)]\n```\n\n## Batch mode\n\nWhen sweeping many pages:\n\n### Find candidate pages\n\n```bash\n# Pages mentioning tweets but with no x.com links\nfor f in $(find . -name \"*.md\" -not -path \".\u002Fnode_modules\u002F*\"); do\n  refs=$(grep -ci \"tweet\\|posted\\|x post\\|RT\\|retweet\\|said on X\" \"$f\")\n  links=$(grep -c \"x.com\u002F.*\u002Fstatus\u002F\" \"$f\")\n  if [ \"$refs\" -gt 2 ] && [ \"$links\" -eq 0 ]; then\n    echo \"$f\"\n  fi\ndone\n```\n\n### Priority order\n\n1. Recently created \u002F updated pages — fresh broken refs are easiest to\n   resolve while context is fresh.\n2. High-traffic pages (frequent reads \u002F writes from other skills).\n3. Everything else — bulk cleanup over time.\n\n### Rate limiting\n\n- X API: respect the host's tier limits; don't hammer.\n- Target ~50 pages per batch run.\n- 1-3 API calls per page (search + verify).\n- Batch-commit every 10-20 pages so a partial failure doesn't lose\n  progress.\n\n## Output format\n\n```\nCitation Audit Report\n=====================\nPages scanned:        N\nCitations found:      N\nIssues fixed:         N\nTweet links resolved: N\nRemaining gaps:       N (pages with uncitable facts)\n```\n\n## When it fails\n\nFollow the [agent operator protocol](..\u002Fconventions\u002Fagent-operator-protocol.md) for any gbrain error `code`, exit code, `[AGENT]` block or notice block. Specific to this skill:\n\n- `put_page` returns `revision_conflict` mid-batch: re-read that page, re-apply only the citation fix, and continue; never overwrite with the copy you read earlier.\n- `get_page` returns `page_not_found` for a cited source: mark the citation unresolvable in the report instead of rewriting it to a guessed slug.\n- A batch commit is interrupted: already-committed pages stay fixed; resume from the last committed page rather than starting over.\n\n## Anti-Patterns\n\n- ❌ Inventing citations for facts that have no source. Flag them.\n- ❌ Removing facts that lack citations (flag them; don't delete).\n- ❌ Fixing citations without reading the full page context.\n- ❌ Batch-fixing without checking quality on a sample first\n  (see `conventions\u002Ftest-before-bulk.md`).\n- ❌ Composing tweet URLs by guessing the tweet id. Always go through\n  the X API; deterministic links only.\n\n## Integration\n\nThis skill can be called:\n\n- **Manually** — \"fix citations on this page\"\n- **As a batch cron** — weekly sweep of pages with broken refs\n- **By other skills** — `enrich` or `media-ingest` can call citation-fixer\n  before commit to validate output\n\n## Metrics\n\nIf running as a recurring batch, track state in a small JSON file under\n`~\u002F.gbrain\u002Fcitation-fixer-state.json`:\n\n```json\n{\n  \"last_run\": \"2026-04-15T...\",\n  \"pages_scanned\": 0,\n  \"citations_fixed\": 0,\n  \"tweet_links_resolved\": 0,\n  \"citations_unresolvable\": 0,\n  \"pages_remaining\": 1424\n}\n```\n\n\n## Output Format\n\nThe skill's output shape is documented inline in the body sections above (see \"Output\", \"Brain page format\", or equivalent). The literal section header here exists for the conformance test (`test\u002Fskills-conformance.test.ts`).\n","# Citation Fixer Skill\n\n> **Convention:** see [conventions\u002Fquality.md](..\u002Fconventions\u002Fquality.md) for\n> the canonical citation format every fix should match.\n>\n> **Output rule:** all links MUST be deterministic (built from API data,\n> not composed by LLM). See [_output-rules.md](..\u002F_output-rules.md).\n\n## Contract\n\nThis skill guarantees:\n\n- Every brain page is scanned for citation compliance.\n- Missing citations are flagged with specific location.\n- Malformed citations are fixed to match the standard format.\n- **(v0.25.1)** Tweet \u002F post references without URLs are resolved via\n  X API and patched with deterministic `https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Cid>`\n  links.\n- Results reported with counts (scanned, fixed, remaining).\n\n## Phases\n\n1. **Scan pages.** List pages and read each one, checking for inline\n   `[Source: ...]` citations.\n2. **Identify issues:**\n   - Facts without any citation\n   - Citations missing date\n   - Citations missing source type\n   - Citations with wrong format\n   - **(v0.25.1)** Tweet references without `x.com` URLs\n3. **Fix format issues.** Rewrite malformed citations to match\n   `conventions\u002Fquality.md`.\n4. **(v0.25.1) Resolve tweet references** via the X API integration.\n5. **Report results.** Count: pages scanned, citations found, issues\n   fixed, tweets resolved, remaining gaps.\n\n## Tweet resolution pipeline (v0.25.1 extension)\n\nFor each broken tweet reference, follow this chain. The actual API call\ngoes through whatever X integration the host has configured (typical\nshape: a recipe under `recipes\u002Fx-api\u002F` with handle \u002F search-all\nendpoints).\n\n### Step 1: Identify broken references\n\nScan the page for patterns that indicate tweet references without URLs:\n\n- Contains words like `tweeted`, `posted`, `said on X`, `RT`, `retweet`,\n  `X post`\n- Contains quoted text that looks like a tweet (short, punchy, often\n  starts with a quote)\n- Has `[Source: ... X\u002FTwitter ...]` without an `x.com` URL\n- References engagement metrics (likes, impressions) without a link\n\n### Step 2: Extract searchable content\n\nFrom each broken reference, extract:\n\n- The **handle** (if mentioned: `@\u003Cusername>`)\n- The **quoted text** (if available)\n- The **approximate date** (often present in surrounding timeline entries)\n\n### Step 3: Search for the actual tweet\n\nUse the host's X API integration. Query patterns:\n\n```\n# Handle + quoted text:\nfrom:\u003Chandle> \"\u003Cexact quote fragment>\"\n\n# Quoted text only:\n\"\u003Cexact quote fragment>\"\n\n# Original of a retweet:\n\"\u003Cexact quote>\" -is:retweet\n```\n\n### Step 4: Verify and extract metadata\n\nOnce a candidate is found:\n\n- Confirm the text matches the quoted fragment.\n- Pull the tweet id, author handle, engagement metrics (likes \u002F RTs \u002F\n  impressions).\n- Construct the URL: `https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Ctweet_id>`.\n\n### Step 5: Patch the brain page\n\nReplace the broken citation with a proper one:\n\n**Before:**\n\n```\n\"\u003Cquote fragment>\" [Source: \u003Csome hand-wavy attribution>]\n```\n\n**After:**\n\n```\n\"\u003Cfull verified quote>\" — \u003CN> likes, \u003CN> RTs, \u003CN> impressions\n[Source: [X\u002F\u003Chandle>, YYYY-MM-DD](https:\u002F\u002Fx.com\u002F\u003Chandle>\u002Fstatus\u002F\u003Ctweet_id>)]\n```\n\n## Batch mode\n\nWhen sweeping many pages:\n\n### Find candidate pages\n\n```bash\n# Pages mentioning tweets but with no x.com links\nfor f in $(find . -name \"*.md\" -not -path \".\u002Fnode_modules\u002F*\"); do\n  refs=$(grep -ci \"tweet\\|posted\\|x post\\|RT\\|retweet\\|said on X\" \"$f\")\n  links=$(grep -c \"x.com\u002F.*\u002Fstatus\u002F\" \"$f\")\n  if [ \"$refs\" -gt 2 ] && [ \"$links\" -eq 0 ]; then\n    echo \"$f\"\n  fi\ndone\n```\n\n### Priority order\n\n1. Recently created \u002F updated pages — fresh broken refs are easiest to\n   resolve while context is fresh.\n2. High-traffic pages (frequent reads \u002F writes from other skills).\n3. Everything else — bulk cleanup over time.\n\n### Rate limiting\n\n- X API: respect the host's tier limits; don't hammer.\n- Target ~50 pages per batch run.\n- 1-3 API calls per page (search + verify).\n- Batch-commit every 10-20 pages so a partial failure doesn't lose\n  progress.\n\n## Output format\n\n```\nCitation Audit Report\n=====================\nPages scanned:        N\nCitations found:      N\nIssues fixed:         N\nTweet links resolved: N\nRemaining gaps:       N (pages with uncitable facts)\n```\n\n## When it fails\n\nFollow the [agent operator protocol](..\u002Fconventions\u002Fagent-operator-protocol.md) for any gbrain error `code`, exit code, `[AGENT]` block or notice block. Specific to this skill:\n\n- `put_page` returns `revision_conflict` mid-batch: re-read that page, re-apply only the citation fix, and continue; never overwrite with the copy you read earlier.\n- `get_page` returns `page_not_found` for a cited source: mark the citation unresolvable in the report instead of rewriting it to a guessed slug.\n- A batch commit is interrupted: already-committed pages stay fixed; resume from the last committed page rather than starting over.\n\n## Anti-Patterns\n\n- ❌ Inventing citations for facts that have no source. Flag them.\n- ❌ Removing facts that lack citations (flag them; don't delete).\n- ❌ Fixing citations without reading the full page context.\n- ❌ Batch-fixing without checking quality on a sample first\n  (see `conventions\u002Ftest-before-bulk.md`).\n- ❌ Composing tweet URLs by guessing the tweet id. Always go through\n  the X API; deterministic links only.\n\n## Integration\n\nThis skill can be called:\n\n- **Manually** — \"fix citations on this page\"\n- **As a batch cron** — weekly sweep of pages with broken refs\n- **By other skills** — `enrich` or `media-ingest` can call citation-fixer\n  before commit to validate output\n\n## Metrics\n\nIf running as a recurring batch, track state in a small JSON file under\n`~\u002F.gbrain\u002Fcitation-fixer-state.json`:\n\n```json\n{\n  \"last_run\": \"2026-04-15T...\",\n  \"pages_scanned\": 0,\n  \"citations_fixed\": 0,\n  \"tweet_links_resolved\": 0,\n  \"citations_unresolvable\": 0,\n  \"pages_remaining\": 1424\n}\n```\n\n\n## Output Format\n\nThe skill's output shape is documented inline in the body sections above (see \"Output\", \"Brain page format\", or equivalent). The literal section header here exists for the conformance test (`test\u002Fskills-conformance.test.ts`).\n",{"name":5,"tools":24,"version":29,"mutating":30,"triggers":31,"description":37,"when_to_use":38},[25,26,27,28],"search","get_page","put_page","list_pages","1.1.0",true,[32,33,34,35,36],"fix citations","fix broken citations","citation audit","check citations","citation fixer","Audit and fix citation formatting across brain pages. Ensures every fact has\nan inline [Source: ...] citation matching the standard format. Extended in\nv0.25.1: scans for broken tweet\u002Fpost references that lack actual URLs and\nresolves them via the host's X \u002F Twitter API integration.\n","Use when the user asks: \"fix citations\", \"fix broken citations\", \"citation audit\", \"check citations\", \"citation fixer\".","feat\u002Flink-chat-distiller","b7935e119783c2f35d6d182ede452faf32de675c","plugin\u002Fskills\u002Fcitation-fixer","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat","https:\u002F\u002Fgithub.com\u002FcheRoma","https:\u002F\u002Fostov.dev","Engineer and founder of Ostov. Websites, Telegram apps, business automation and ERP\u002FCRM integrations.","2026-11-12 20:40:42",{"source":8,"skillName":5,"commands":48,"prompt":58,"zipAvailable":30},[49,52,55],{"tool":50,"command":51},"npx","npx skills add cheRoma\u002Fgbrain-link-chat --skill citation-fixer",{"tool":53,"command":54},"bunx","bunx skills add cheRoma\u002Fgbrain-link-chat --skill citation-fixer",{"tool":56,"command":57},"pnpm","pnpm dlx skills add cheRoma\u002Fgbrain-link-chat --skill citation-fixer","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Fplugin\u002Fskills\u002Fcitation-fixer\u002FSKILL.md",[60],{"path":61,"resourceType":62,"resourceTypeDesc":63,"sizeBytes":64,"sourceHtmlUrl":65},"routing-eval.jsonl","OTHER","其他",585,"https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Fplugin\u002Fskills\u002Fcitation-fixer\u002Frouting-eval.jsonl",[67,73,79,86,93,100],{"skillNo":68,"name":69,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":19},"01M75M5HR90P229V66Q4Q1GM0W","query-helper","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fquery-helper\u002FSKILL.md",[],[],{"skillNo":74,"name":75,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":19},"01M75M5GZ1WQB7NHR07QV38YB8","broken","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fbroken\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":19},"01M75M5FDJV3M4GP71SKD31P33","brain-ops","Read, enrich, and write brain pages with source attribution.","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fbrain-ops\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":19},"01M75M5DYW3WBGDC6M90YMC843","meeting-prep","Build a briefing before you meet someone, from their recent threads, open loops and what they care about.","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog-query\u002Fskills\u002Fmeeting-prep\u002FSKILL.md",[],[],{"skillNo":94,"name":95,"nameZh":6,"description":96,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":19},"01M75M5CJZX22MV7XKJQYEMC9Y","inbox-zero","Triage the inbox into replies, delegations and archives.","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog-query\u002Fskills\u002Finbox-zero\u002FSKILL.md",[],[],{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":106,"publishedAt":19},"01M75M5B953478ACM9X3MPAX3P","deal-memo","Draft an investment memo from the deal pages and the founder history already in the brain.","https:\u002F\u002Fgithub.com\u002FcheRoma\u002Fgbrain-link-chat\u002Fblob\u002Ffeat\u002Flink-chat-distiller\u002Ftest\u002Ffixtures\u002Fskill-catalog-query\u002Fskills\u002Fdeal-memo\u002FSKILL.md",[],[]]