ktg-plugin-marketplace/plugins/linkedin-thought-leadership/config/edition-state.template.json
Kjell Tore Guttormsen 4ed9717627 feat(linkedin): v2.2.0 — harden longform gates from 2nd production run
Implements the 6-change spec from the Seres-serien production
(linkedin-plugin-endringsspec.md). All acceptance criteria met.

1. Avoid-patterns (modell-/navne-katalog, completeness-over-reader-action,
   self-referential overhead openings) → longform-quality-rules.md (rule 1+3)
   + user-profile.template.md.
2. Persona gate now BLOCKING with explicit hard-fail list (primær mistet meg /
   doesn't own action / sjargong-mur / modell-navne-katalog → BLOCK;
   "JA med store forbehold" = NEI) → persona-reviewer.md + personas.template.md.
3. Fact-check declared orthogonal to narrative strength + post-cutoff
   web-search mandate + high-frequency-error checklist → fact-checker.md.
4. NEW agent voice-scrubber.md (Opus) — de-AI scrub + Norwegian-chronicle
   voice-drift; gold standard = approved Norwegian editions, NOT the English
   post corpus. Wired into newsletter.md Step 4.
5. Operator gates = render+annotate rounds (build-html.mjs to file://) as
   primary flow, AskUserQuestion as receipt/fallback → newsletter.md 2.5+3a.
6. Edition state reconciled with STATE.md (ONE-system). edition-HANDOVER
   template deleted; narrative to <serie>/STATE.md, machine data
   (factcheckLog, personaSweep, immutableRules) to edition-state.json.

Agents 14 to 15; commands unchanged (24). Backward-compatible (additive
state-shape only). Docs updated across all three levels + CHANGELOG.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-28 20:50:56 +02:00

48 lines
3.1 KiB
JSON

{
"_doc": {
"purpose": "Schema for edition-state.json — deterministic resumption state for a newsletter edition in production. Holds the current phase + per-article status so /linkedin:newsletter (Step 0) can resume exactly where a prior session stopped.",
"decision": "G — production state lives in the serie-mappe (e.g. /Users/ktg/repos/maskinrommet/serier/<slug>/linkedin/edition-state.json), NOT in the plugin. This file is the schema-defining TEMPLATE only; copy + fill it in the serie-mappe when producing an edition.",
"complements": "edition-config.json (static: calendar, freshness, captions) and <serie>/STATE.md (human-readable narrative state, overwritten each phase per the ONE-system continuity rule — there is no edition-HANDOVER.md). edition-state.json is the machine-readable companion: deterministic resumption + the durable fact-check log, immutable rules, and persona verdicts that the old HANDOVER §4/§5 used to carry.",
"lifecycle": "/linkedin:newsletter reads this in Step 0 and rewrites it at every phase transition. Article keys mirror edition-config.json (zero-padded strings: \"01\", \"02\", ..., or \"samle\").",
"phases": [
"load-context — read <serie>/STATE.md, voice profile, persona library, series brief (Step 0)",
"brief-calibration — angle, voice, audience personas, key points, leader-takeaway (Step 1)",
"research — parallel scoped mandates → verified notes, triangulation (Step 2)",
"skeleton-pitch — five-line skeleton (premise/problem/recommendation/payoff/forward) + section pitches, operator gate + persona-skjelett-sweep BEFORE prose (Step 2.5)",
"spine-prose — one paragraph per section against the gated skeleton, operator gate BEFORE full expansion (Step 3a)",
"draft — full prose expansion against the gated spine; may span sessions (Step 3b)",
"consistency-quality — threads, premise→conclusion arc, AI-slop removal, formatting dose (Step 4)",
"factcheck-sweep — risk-sorted, guilty-until-disproven, verification log (Step 5)",
"persona-sweep-prelock — reader jury, primary wins, convergence to clean YES (Step 6)",
"annotation — optional annotatable review HTML for a manual pass (Step 7)",
"lock-delivery — LOCK → POST.html all-in-one-place deliverable (Step 8)",
"hook-conversion-gate — persona gate on distribution text post-lock: would YOU click? (Step 9)",
"scheduling — register edition in plugin queue/state for native LinkedIn scheduling (Step 10)"
],
"articleStatusValues": ["pending", "in-progress", "locked", "scheduled"]
},
"schemaVersion": 1,
"series": {
"slug": "<series-slug>",
"title": "<Series title>"
},
"currentArticle": "01",
"currentPhase": "load-context",
"updatedAt": "<ISO-8601 timestamp>",
"articles": {
"01": {
"title": "<Article 1 title>",
"phase": "load-context",
"status": "pending",
"immutableRules": null,
"factcheckLog": null,
"personaSweep": {
"skeleton": null,
"resonance": null,
"conversion": null
},
"locked": false,
"scheduled": null
}
}
}