ktg-plugin-marketplace/plugins/linkedin-studio/hooks/prompts/topic-rotation-gate.md
Kjell Tore Guttormsen b6bb61246b refactor(linkedin)!: rename plugin linkedin-thought-leadership → linkedin-studio (v3.0.0)
BREAKING CHANGE: the marketplace slug, the agent namespace
(linkedin-studio:<agent>), and the runtime state-file path
(~/.claude/linkedin-studio.local.md) all change. Reinstall required;
existing state migrated in place (post metrics, streak, history preserved).
The /linkedin:* commands are unchanged — the command namespace is set
per-command in frontmatter and was always independent of the plugin slug.
Functionality is byte-identical to v2.4.0; this release is pure identity.

- dir + manifests: plugins/linkedin-studio + plugin.json + root marketplace.json
- agent namespace updated in commands/newsletter.md (only functional invoker)
- state path updated in 4 hook scripts + topic-rotation prompt + state template
- catch-all skill dir renamed skills/linkedin-studio (5 functional skills unchanged)
- docs + version bump to 3.0.0 across README badge, CHANGELOG, root README/CLAUDE.md
- historical records (CHANGELOG past entries, docs/ build artifacts,
  config-audit v5.0.0 snapshots) intentionally retain the old slug

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-29 11:32:02 +02:00

2.5 KiB

LINKEDIN TOPIC ROTATION GATE: If the file being written/edited is LinkedIn content (a post draft, article, or content file — NOT config files, state files, scripts, documentation, JSON, or plan files), check topic diversity before proceeding.

Step 1: Read State Read ~/.claude/linkedin-studio.local.md and extract:

  • last_post_topic — the pillar of the most recent post
  • expertise_areas — the user's 5 content pillars
  • ## Recent Posts section — post history with topic_area tags

Step 2: Identify Current Pillar Determine which expertise_area the current post best matches. Use semantic matching — the post doesn't need to use the exact pillar name, but its core topic should clearly map to one of the 5 expertise_areas.

Step 3: Run Checks

If fewer than 3 posts exist in the last 14 days, skip all checks (insufficient data for meaningful rotation analysis).

Check 1 — Back-to-back repetition: If the current post's pillar matches last_post_topic, flag:

"TOPIC ROTATION WARNING: This post covers the same pillar ([pillar]) as your last post. Consider switching to an underrepresented pillar for better audience diversity and algorithmic reach."

Check 2 — 14-day balance: Count posts per pillar from the ## Recent Posts section (last 14 days only). If any single pillar accounts for more than 50% of posts in that window, flag:

"PILLAR BALANCE WARNING: [pillar] has [X] of [Y] posts ([Z]%) in the last 14 days. LinkedIn's algorithm rewards topic consistency across your niche, but over-concentration on one pillar signals narrowing expertise."

Check 3 — Off-topic: If the current post does not match ANY of the 5 expertise_areas, flag:

"OFF-TOPIC WARNING: This post doesn't align with any of your 5 expertise areas. Off-pillar posts weaken your 360Brew topical authority signal. Consider reframing to connect with [closest pillar]."

Step 4: Suggest Alternatives If any check flagged, suggest 2-3 underrepresented pillars with context:

"Underrepresented pillars to consider:

  • [Pillar A] — last posted [X] days ago ([N] posts in 14 days)
  • [Pillar B] — last posted [Y] days ago ([M] posts in 14 days)
  • [Pillar C] — last posted [Z] days ago ([P] posts in 14 days)"

This is a WARN-ONLY hook. Do not block content creation. Present the warning and let the user decide whether to adjust.

Skip this check if the file is a config file, state file (.local.md), script, hook, JSON, plan file, documentation, or any non-content file. Only apply to LinkedIn post drafts and articles.