backstage
Anti-drift protocol script. Ensures parity between docs and system. Triggers: 'bom dia PROJECT' / 'good morning PROJECT' (load project context with health checks)
What this skill does
# Backstage Skill
**Nickname:** `backstage:`
**Objective:** Universal project status management for AI-assisted development. Ensures documentation matches reality before every commit.
---
## β οΈ Security Notice
**This is an admin tool with elevated privileges:**
- **Executes checks from global path** (`$HOME/Documents/backstage/backstage/checks/global/`)
- **Pulls remote code** from GitHub (https://github.com/nonlinear/backstage)
- **Modifies project files** (README, ROADMAP, CHANGELOG with mermaid diagrams)
- **Rsyncs updates** when using `update backstage` trigger
**Intended for:**
- Personal use (you control the upstream repo)
- Trusted teams (shared backstage protocol repo)
**Not recommended for:**
- Untrusted third-party projects
- Public/open-source projects with unknown contributors
**Mitigations in place:**
- User confirmation before applying updates
- Git history (all changes committed, revertable)
- Symlink detection (admin mode auto-updates)
**Use at your own risk.** Review `update-backstage.sh` and `checks.sh` before running.
---
## π΄ Why This Skill Exists (Anti-Drift)
**Backstage-skill = ANTI-DRIFT:**
- β
Force context awareness (project/epic)
- β
Health checks prevent chaos
- β
Architecture-first workflow
- β
Roadmap visibility = no surprises
**WITHOUT IT:**
Work happens outside backstage β drift β broken trust β triple metabolic cost
**WITH IT:**
"good morning X" β automatic context load β work inside boundaries β paridade maintained
---
**The Metabolic Cost Problem:**
Without backstage, delegation costs **triple**:
1. The work itself
2. Explicating methodology (ethics, preferences, protocols)
3. Defining WHERE that learning gets stored (VISION? SOUL? SKILL? memory?)
This is **exhausting** for the human.
**Investment is worth it ONLY IF plateau is reached:**
- Human teaches ONCE β AI internalizes
- Each session: READ context files β act according to ethics
- Each session: LESS explanation needed
- Plateau = Human delegates, AI executes without supervision
**This skill enforces stabilization.**
Force context awareness (project/epic/design architecture) to prevent drift.
**3x work becomes 1x work.**
---
## Policies & Checks Enforcement
**Backstage-skill enforces ALL rules in checks/ (deterministic + interpretive, global + local).**
### Enforcement Model
```mermaid
flowchart TD
READ_CHK["Read checks/<br/>global + local<br/>[Deterministic .sh + Interpretive .md]"]
CONFLICT{Conflict?}
MERGE[Merge compatible rules]
LOCAL[Local wins]
AI["AI interprets .md checks<br/>[Contextual enforcement]"]
SH["Bash executes .sh checks<br/>[Deterministic validation]"]
AI_ACT[β
Enforce or discuss]
AI_AMBIG[β οΈ Ask user]
SH_OK[β
All checks pass]
SH_FAIL[β Checks failed]
REPORT["Report:<br/>π Interpretive (always β
)<br/>π Deterministic (β
/β)"]
READ_CHK --> CONFLICT
CONFLICT -->|No| MERGE
CONFLICT -->|Yes| LOCAL
MERGE --> AI
MERGE --> SH
LOCAL --> AI
LOCAL --> SH
AI -->|Clear| AI_ACT
AI -->|Ambiguous| AI_AMBIG
SH -->|Pass| SH_OK
SH -->|Fail| SH_FAIL
AI_ACT --> REPORT
AI_AMBIG --> REPORT
SH_OK --> REPORT
SH_FAIL --> REPORT
```
**Two enforcement domains:**
1. **Checks (Interpretive)**
- `checks/global/*.md` = Universal workflow rules
- `checks/local/*.md` = Project-specific overrides
- **Enforced by:** AI (reads markdown, interprets context, acts)
- **Always pass:** AI reads, understands, will act accordingly
2. **Checks (Deterministic)**
- `checks/global/*.sh` = Universal validation tests
- `checks/local/*.sh` = Project-specific tests
- **Enforced by:** Bash (executes shell scripts, exit codes)
- **Pass or fail:** β
(exit 0) or β (exit non-zero)
**Polycentric governance:**
- Global + local rules coexist
- Local wins on conflict
- AI merges when compatible
**Report format:**
```
π Interpretive checks:
β
checks/global/branch-workflow.md (read)
β
checks/global/commit-style.md (read)
β
checks/local/dogfooding.md (read)
π Checks (deterministic):
β
checks/global/navigation-block-readme.sh
β
checks/global/semver-changelog.sh
β checks/local/pre-merge-tasks.sh (incomplete tasks)
```
**Self-contained:** All prompts in SKILL.md (no external prompt files needed).
---
## Mermaid Diagram Generation (Interpretive)
**Purpose:** Automatically generate + propagate ROADMAP diagram to all backstage files.
**Workflow:**
1. **Parse ROADMAP.md** (deterministic - SH):
```bash
parse-roadmap.sh backstage/ROADMAP.md
# Output: version|status_emoji|name
```
2. **Read checks/ diagram rules** (interpretive - AI):
- `checks/global/navigation-block.md` defines default format (linear graph, all epics, sequential)
- `checks/local/*.md` can override (gantt, flowchart, or `diagram: none`)
- Local wins on conflict
3. **Generate mermaid** (interpretive - AI):
- Apply checks/ rules to parsed data
- Create mermaid syntax matching specification
- Example (default):
```mermaid
graph LR
A[ποΈ v0.1.0 Active Epic] --> B[π v0.2.0 Backlog Epic]
```
4. **Propagate to all files** (deterministic - SH):
- Insert after `> π€` marker
- README.md, ROADMAP.md, CHANGELOG.md
- Remove old diagrams (anti-drift)
**AI Prompt (when running backstage-start/end):**
> Read checks/global/navigation-block.md and checks/local/*.md for diagram rules.
> Run `parse-roadmap.sh` to extract epics.
> Generate mermaid diagram following checks/ rules (prefer local over global).
> Insert diagram after navigation block (`> π€`) in all backstage files.
> If local checks say `diagram: none`, skip generation.
**Tools:**
- `parse-roadmap.sh` - Extract version|status|name from ROADMAP.md
- `checks/` - Diagram format rules (type, include/exclude logic, status mapping)
---
## Polycentric Governance (How It Works)
```mermaid
flowchart TD
GLOBAL_POL[checks/global/*.md<br/>Universal rules]
LOCAL_POL[checks/local/*.md<br/>Project-specific overrides]
GLOBAL_CHK[checks/global/*.sh<br/>Universal tests]
LOCAL_CHK[checks/local/*.sh<br/>Project-specific tests]
AI[AI reads checks/]
BASH[Bash executes checks/]
CONFLICT{Conflict?}
GLOBAL_POL --> AI
LOCAL_POL --> AI
GLOBAL_CHK --> BASH
LOCAL_CHK --> BASH
AI --> CONFLICT
CONFLICT -->|Yes| LOCAL_POL
CONFLICT -->|No| MERGE[Merge rules]
MERGE --> ACTION[Execute workflow]
LOCAL_POL --> ACTION
BASH --> ACTION
```
**This skill enforces polycentric governance:**
- Reads ALL `checks/**/*.md` files (global + local)
- Executes ALL `checks/**/*.sh` files (global + local)
- Merges checks when compatible
- Prefers local checks on conflict
- Reports deterministic check results (pass/fail)
**Triggered by:** "good morning", "good night", "backstage start/end", "update backstage"
---
## Workflow Diagram
```mermaid
flowchart TD
START["Trigger 1οΈβ£<br/>[SH]"]
MODE{"Session mode?"}
%% Common enforcement module
READ_POL["Read checks/<br/>global + local<br/>[AI interprets MD]"]
EXEC_CHK["Execute checks/<br/>global + local<br/>[Bash runs SH]"]
REPORT["Report 6οΈβ£<br/>π Interpretive (β
)<br/>π Checks (β
/β)"]
CHECKS_GATE{"All checks<br/>passed?"}
%% Start Branch
START_BRANCH["Read README π€ block 2οΈβ£<br/>[MD β AI]"]
START_FILES["Locate status files 3οΈβ£<br/>[SH]"]
START_GIT["Check git branch 4οΈβ£<br/>[SH]"]
START_WORK["Analyze changes 5οΈβ£<br/>[SH]"]
START_FIX["π STOP: Fix issues<br/>[AI + SH]"]
START_UPDATE["Update docs 7οΈβ£<br/>[SH writes MD]"]
START_REPORT["Developer context 8οΈβ£<br/>[AI reads MD]"]
START_PUSH["Push / Groom 9οΈβ£<br/>[SH]"]
%% End Branch
END_FIXES["Add fixes to roadmap<br/>[AI writes MD]"]
END_PUSH["Commit + push<br/>[SH]"]
END_VICTORY["Victory lap π<br/>[AI reads MD]"]
END_BODY["Body check βΈοΈ<br/>[AI prompt]"]
END_Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.