pm-preflight
Validate environment before any PM skill runs. Checks sqlite3, database, schema. Hard stop on failure — no fallbacks.
What this skill does
# PM Preflight — Dependency Guardian
Runs before ANY other PM skill. Validates the environment is ready. If it fails, STOP. No fallbacks. No workarounds.
## Invocation
```
/pm-preflight
```
Called automatically by `/pm` before dispatching. Can also be run standalone to verify setup.
## Check 1: sqlite3 Available
```bash
which sqlite3 || python3 -c "import sqlite3; print('python3-sqlite3')"
```
**If neither works:**
```
STOP: sqlite3 is not available on this system.
Install it:
macOS: brew install sqlite3
Ubuntu: sudo apt-get install sqlite3
Alpine: apk add sqlite
Python: sqlite3 module is built-in — use python3 instead of sqlite3 CLI
Cannot proceed without SQLite. PM skills MUST NOT write directly to markdown,
JSON, CSV, or any other format as a workaround.
```
Present this message to the user and STOP. Do not attempt alternative approaches.
## Check 2: Database Directory
```bash
ls .claude/db/ 2>/dev/null || mkdir -p .claude/db
```
## Check 3: Schema Initialized
```bash
sqlite3 .claude/db/marketing.sqlite ".tables" 2>/dev/null | grep -q epics
```
If `epics` table is missing, run the PM schema migration:
1. Check if competitive-intel base tables exist (`our_products`, `tags`). If not, warn user to initialize competitive-intel first.
2. Check if feature-tracker tables exist (`product_features`). If not, run feature-tracker schema.sql first.
3. Run [schema.sql](schema.sql) to add PM tables (epics, requirements, iterators, etc.)
4. Handle ALTER TABLE for existing tables — add columns if missing:
```sql
-- Check and add columns to product_features
SELECT COUNT(*) FROM pragma_table_info('product_features') WHERE name = 'epic_id';
-- If 0: ALTER TABLE product_features ADD COLUMN epic_id TEXT REFERENCES epics(id);
SELECT COUNT(*) FROM pragma_table_info('product_features') WHERE name = 'base_version';
-- If 0: ALTER TABLE product_features ADD COLUMN base_version INTEGER NOT NULL DEFAULT 1;
-- Check and add columns to product_feature_tests
SELECT COUNT(*) FROM pragma_table_info('product_feature_tests') WHERE name = 'requirement_id';
-- If 0: ALTER TABLE product_feature_tests ADD COLUMN requirement_id TEXT REFERENCES requirements(id);
SELECT COUNT(*) FROM pragma_table_info('product_feature_tests') WHERE name = 'base_version';
-- If 0: ALTER TABLE product_feature_tests ADD COLUMN base_version INTEGER NOT NULL DEFAULT 1;
```
## Check 4: Schema Version
```sql
SELECT version FROM schema_versions WHERE skill = 'pm';
```
Compare against expected version. If mismatch, run migration steps for the gap.
## Output on Success
```
PM Preflight: OK
sqlite3: /usr/bin/sqlite3
database: .claude/db/marketing.sqlite
schema: pm v1
tables: epics, requirements, iterators, iterator_values (+ existing)
```
## Rules
1. **Hard stop on any failure.** No fallbacks. No markdown workarounds.
2. **Only skill that runs DDL.** All CREATE TABLE and ALTER TABLE happen here.
3. **Idempotent.** Safe to run multiple times — uses IF NOT EXISTS and column checks.
4. **Never deletes data.** Only adds tables and columns.
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.