Skip to content

feat: ce-datascience 40-skill release with workflow navigator and competitive ports - #1

Merged
sajor2000 merged 37 commits into
mainfrom
feat/ce-datascience-fork
Apr 29, 2026
Merged

sajor2000 merged 37 commits into
mainfrom
feat/ce-datascience-fork

Conversation

@sajor2000

Copy link
Copy Markdown
Owner

Summary

  • 7 new skills bringing the plugin from 33 to 40 skills
  • Root README rewritten with full attribution to upstream CE, BMAD, and Superpowers
  • LICENSE updated to dual copyright (Rojas 2026 + Every/Kieran 2025)

New skills

Skill Source What it does
/ce-workflow New Lifecycle navigator — detects project type (observational/RCT/prediction/bioinformatics/technical), language, and data layer; shows ordered skill sequence with progress detection and next-step recommendation
/ce-verify New (inspired by Superpowers) Mid-workflow analysis verification gate — 7 checks (sample size, leakage, effect direction, missing data, PHI, figure quality, reproducibility)
/ce-optimize Ported from CE Metric-driven optimization loops adapted for DS — cross-validation guardrails, leakage detection, mlflow/wandb integration, SAP alignment check
/ce-resolve-pr-feedback Ported from CE PR review feedback resolution with methodology review triggers (estimand, sample size, sensitivity analysis)

Previously unlisted skills now surfaced in README

Skill Why it was hidden
/ce-research-question PICO hardening skill existed but wasn't in any README table
/ce-clif CLIF profile skill was auto-activating but not documented as user-invocable
ce-language-detect Internal skill, now counted (37 → 40 with the 4 new additions)

Attribution

Root README now clearly separates:

  • What came from upstream (CE core workflow, review architecture, CLI infrastructure)
  • What is new in this fork (20+ biomedical skills, 20+ domain agents, 16 checklists, CLIF profile, SAP dual-mode)
  • Influences (BMAD scale-adaptive planning, Superpowers verification gates)

Test plan

  • bun test — 773/773 pass
  • bun test tests/frontmatter.test.ts — 272/272 pass (all 40 skills valid)
  • bun run release:validate — 55 agents, 40 skills, manifests in parity
  • No compound-engineering references in ported skill paths (was 9, now 0)
  • Manual: /ce-workflow in a fresh project shows correct lifecycle card
  • Manual: /ce-verify runs 7 checks against analysis outputs
  • Manual: /ce-optimize respects CV splits and leakage guard

🤖 Generated with Claude Code

sajor2000 and others added 30 commits April 28, 2026 03:18
Rename plugins/compound-engineering to plugins/ce-datascience. Remove 18
software-engineering agents (Rails, Swift, TypeScript, Figma, database
migration, CLI readiness, etc.) and 19 software-engineering skills
(DHH Rails, frontend design, test browser/xcode, polish-beta, demo-reel,
etc.). Update all marketplace manifests (Claude, Cursor, Codex) with new
name, description, and data-science keywords. Rewrite README.md and
AGENTS.md for data science audience. Update release-please config to
reference new plugin path. Remove coding-tutor from marketplace manifests.
Batch-replace compound-engineering references across plugin files.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…nce-fork

# Conflicts:
#	plugins/ce-datascience/skills/ce-setup/SKILL.md
#	plugins/ce-datascience/skills/ce-setup/references/config-template.yaml
#	plugins/ce-datascience/skills/ce-setup/scripts/check-health
…ity review agents

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… vs technical planning

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…d terminology

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… and PICO/PECO framing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…nce-fork

# Conflicts:
#	plugins/ce-datascience/skills/ce-compound-refresh/references/schema.yaml
#	plugins/ce-datascience/skills/ce-compound-refresh/references/yaml-schema.md
#	plugins/ce-datascience/skills/ce-compound/SKILL.md
#	plugins/ce-datascience/skills/ce-compound/references/schema.yaml
#	plugins/ce-datascience/skills/ce-compound/references/yaml-schema.md
…nce-fork

# Conflicts:
#	plugins/ce-datascience/skills/ce-brainstorm/SKILL.md
#	plugins/ce-datascience/skills/ce-brainstorm/references/handoff.md
#	plugins/ce-datascience/skills/ce-brainstorm/references/requirements-capture.md
Adds SAP coverage tracking per invocation (references/sap-tracking.md),
stack-profile-aware code scaffolding with R+tidyverse and Python+pandas
golden paths (references/scaffolding-templates.md), and STROBE checklist
reference (22-item observational study reporting guideline).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Creates CONSORT 25-item RCT checklist with Schulz et al. 2010 citation,
reporting-checklist-reviewer agent (opt-in, auto-infers STROBE/CONSORT
from SAP study_type), and SAP-drift-detector agent (structural + semantic
tiers). Enriches STROBE checklist with von Elm et al. 2007 citations.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ch for data science

Creates ce-r-code-reviewer (tidyverse/base consistency, dplyr, ggplot2,
data.table, purrr patterns) and ce-python-ds-reviewer (pandas anti-patterns,
vectorization, sklearn pipelines, data leakage detection). Rewrites
persona-catalog.md and SKILL.md dispatch tables to replace software-eng
reviewers with statistical, language-specific, and cross-cutting conditionals.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…iewer entries

Adds ce-methods-reviewer, ce-multiplicity-reviewer, ce-reproducibility-reviewer,
ce-reporting-checklist-reviewer, ce-sap-drift-detector, ce-r-code-reviewer,
ce-python-ds-reviewer to README. Splits review agents into Statistical Review
and Code Quality Review sections.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… with provenance tracking

Adds full reporting guideline coverage across all study types:
- 8 primary checklist files: PRISMA, STARD, CARE, COREQ, ARRIVE, CHEERS (new) + STROBE/CONSORT (existing)
- 8 AI extension checklist files: REFORMS, TRIPOD+AI, CLAIM, SPIRIT-AI, CONSORT-AI, DEAL, CHART, PDSQI-9
- Guideline routing map (study_type + ai_involvement -> applicable checklists)
- SAP template expanded with 7 new study_type values, ai_involvement, guidelines_selected, and SAP-11 section
- ce-reporting-checklist-reviewer upgraded to routing-map-driven 16-guideline dispatch
- Study metadata schema and template covering dataset_split, llm_provenance, software_provenance
- Append-only compliance report format with COMPLETE/INCOMPLETE/WAIVED tracking
- Enforcement findings: P0 for missing classification, P1 for missing ML/LLM provenance
- Metadata completeness checks integrated into SAP tracking and reproducibility reviewer

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…rebrand

- Rebrand all compound-engineering references to ce-datascience across src/, tests/, .github/, scripts/
- Add ce-r-pipeline-reviewer agent (dplyr logic, ggplot2 accessibility, survival analysis, mixed models)
- Enhance ce-reproducibility-reviewer with R-specific checks (stale renv.lock, CRAN snapshot, parallel RNG, knitr cache)
- Add R project scaffolding (renv init, .Rprofile, DESCRIPTION, targets pipeline golden path)
- Expand stack profile: environment_manager, r_project_type, 10 R statistical packages
- Add R-specific brainstorm rigor probes (data format, package ecosystem, table formatting, power analysis)
- Add R build/test detection to shipping workflow (devtools::test, R CMD check, tar_check, lintr)
- Add R CI patterns reference (r-lib/actions, Rocker Docker, renv restore, caching)
- Create ce-literature-search skill with PyPaperBot integration (PICO/PECO queries, DOI lookup)
- Create ce-mcp-server skill with 6 MCP tool definitions
- Wire ce-r-pipeline-reviewer into code review dispatch table
- Update agent count 40→41, skill count 16→18, add 1 MCP server

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Move mcp_server/ into skills/ce-mcp-server/ so the local stdio MCP server
travels with the skill during Codex/Pi installs. Updates .mcp.json args
path and PLUGIN_ROOT resolution to match the new layout.

Fix dead GitHub clone URL in install.ts and plugin-path.ts to point at
sajor2000/ce-datascience instead of the upstream repo that never existed
under EveryInc.

Update Codex/Pi managed-block markers to 'CE DataScience' with backward
compat (still detect/clean old 'Compound Engineering' markers). Add a
post-install note when Codex MCP servers are present but skills weren't
included via --include-skills. Update package.json identity and CLI bin
name to ce-datascience-plugin.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Phase 1 - test green-up (193 fails -> 0 fails):

- Update Codex/Pi marker assertions to match new 'CE DataScience' /
  'CE DATASCIENCE PI TOOL MAP' managed-block markers.
- Mirror literature_pattern enum into ce-compound-refresh schema.yaml
  to match ce-compound (schema-drift contract).
- Delete out-of-scope test files for skills the data-science fork
  intentionally drops: ce-polish-beta-* (4 files), ce-demo-reel,
  ce-release-notes-helper, ce-session-{inventory,extract}, and
  ce-work-beta pipeline-review contract.
- Replace JS/Rails reviewer expectations in review-skill-contract with
  the data-science reviewer set (r-code, r-pipeline, python-ds,
  kieran-python). Drop the ce-data-migration-expert and lfg / ce-work-beta
  contract tests that referenced removed skills. Relax the anchored-rubric
  regex to accept both 'suppress' and 'do not report' phrasings.
- Add ce-r-pipeline-reviewer entry to persona-catalog.md and prepend
  'Conditional code-review persona' to the DS reviewer descriptions so
  they pass the structured findings contract.
- Tighten legacy-cleanup test to drop ce-work-beta references and use
  ce-work in the legacy-workflow case.
- Fix opencode-writer pre-namespacing test to seed the legacy manifest
  at the correct LEGACY_MANAGED_SEGMENT path (compound-engineering).
- Pass pluginName: 'ce-datascience' in pi-writer mcporter backup test
  so resolveManagedSegment resolves to the new namespaced path.

Phase 2 - source hygiene:

- Replace upstream EveryInc/{compound-engineering,ce-datascience}-plugin
  URLs in CHANGELOG.md (top-level + plugin) with sajor2000/ce-datascience
  so historical changelog links don't 404.

Result: bun test 659/659 pass (was 678/871 with 193 fails).
release:validate clean (41 agents, 18 skills, 1 MCP server).

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…wave register/lock)

Add data lifecycle building blocks for the realistic, non-linear DS workflow:

- ce-data-qa skill: 16-check QA gate (QA-1..QA-16) with GO/NO-GO emit,
  CONSORT/STROBE flow, missingness-pattern catalog, PI sign-off block,
  pipeline mode for headless invocation
- ce-data-mapping-reviewer agent: 8 finding categories covering codebook /
  SAP / extract mapping (missing variables, name drift across waves, type
  drift, unit mismatches, level set drift, derived variable formulae,
  PHI leak in codebook, stale codebook entries) with 5-anchor confidence
- data_wave_register MCP tool: SHA256 hash, .ce-datascience/data-state.yaml,
  current_wave tracking, unique extract_id enforcement
- data_lock MCP tool: refuses without qa_report_path, parses GO/NO-GO,
  records sap_version_at_lock, immutability semantics
- stack-profile additions: data_root (PHI-aware), blinding_state
- ce-setup steps 7b and 7c collect the new fields

All 665 tests still pass.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…er, blinding-state awareness)

Add SAP-amendment lifecycle building blocks:

- sap_amend MCP tool: in-place SAP edit + sap-amendments.md log with prior
  text / new text / reason / person / timestamp + auto version bump
- sap_create now refuses without power_analysis (most-skipped section that
  breaks downstream review)
- ce-sap-amendment-reviewer agent: 8 finding categories (no log entry,
  primary endpoint after lock, inclusion change after enrollment closed,
  method change after data peek, blank reason, code drift after amend,
  power calc after enrollment, repeated same-section amendments) with
  5-anchor confidence and timestamp comparison against data-state.yaml
- ce-sap-drift-detector now flags blinding state violations: inferential
  code on the assignment variable while config declares blinded state

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Add review/submission/revision building blocks:

- ce-code-review: phase-aware dispatch via phase:<name> arg or stack_profile
  blinding_state inference. Phase values: blinded-eda, confirmatory, revision,
  pilot, general. Refuses inferential code on assignment variable during
  blinded-eda; bumps SAP drift to P0 during confirmatory; requires sap_amend
  log for any primary endpoint change during revision.
- ce-freeze skill: tags submission commit, snapshots SAP version + locked
  wave hash + env lock files + rendered manuscript into submissions/<tag>/
  with manifest.yaml and RECOVER.md. Refuses if data is unlocked or worktree
  dirty. Never copies the data itself (PHI safety).
- ce-revise skill: structured revision-round workflow. Per-query status
  (analysis-change | manuscript-only | rebuttal | wontfix), enforces SAP
  amendment paired with each analysis-change, builds response-to-reviewers
  document, freezes a new round tag.
- ce-phi-leak-reviewer agent: scans for 18 HIPAA Safe Harbor identifiers
  + quasi-identifier combinations across data files, codebooks, notebooks,
  manuscripts, figure captions, and rendered output. data_root-aware (in-repo
  vs off-repo) with stricter scope when data lives in the tree.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
… reviewers + tabular SAP companion

Round out the realistic DS workflow with pilot/handoff and reviewer coverage:

- ce-pilot skill: sandboxed feasibility/methods-development sub-project with
  SAP-lite, separate data-state, phase=pilot review dispatch, structured
  handoff document listing what transfers vs what is pilot-only, and
  cross-contamination check before close
- ce-compound: deterministic dedup fingerprint key
  (problem_type::component::root-cause-slug) computed during assembly so the
  same lesson surfacing across studies updates the existing doc instead of
  duplicating; schema gains 'fingerprint' and 'last_updated' fields
- ce-work: parallel-safety check now includes SAP-section ownership; two
  units touching the same SAP-N.M downgrade to serial dispatch to keep the
  SAP-to-code mapping deterministic
- ce-targets-pipeline-reviewer agent: 12 finding categories for targets
  framework (hidden file deps, format hints, branching drift, seed leaks,
  config drift between _targets.R and _targets.yaml)
- ce-quarto-render-reviewer agent: 14 finding categories for Quarto/RMarkdown
  (committed _book/ output, cache traps, params declared/consumed mismatch,
  bibliography paths, fig-cap/fig-alt accessibility, format mismatches)

Also adds the tabular SAP companion that mirrors real stats-team output:

- ce-sap-tabular skill: generates 5-table artifact (overview, outputs,
  variables, file 1 long sample, file 2 wide sample) as CSVs plus single
  multi-sheet .xlsx workbook (when openpyxl available). Each row is
  audit-grade: filename + subfolder + cohort scope + analysis section +
  contents + role in pooled analysis + interpretation (pre-registered
  expected direction)
- references/output-catalog-template.md: controlled vocabulary of artifact
  types (DIAGNOSTIC / TABLE / MODEL / FIGURE) with canonical filenames per
  category and required column sets for *_coefs.csv and *_re_variance.csv
- references/section-prefixes.md: A<N>_ prefix + subfolder layout
  (diagnostics/, tables/, models/a<N>/, figures/a<N>/) + SITE_<id>_
  runtime-only prefix convention
- references/variable-categories.md: controlled vocabulary for the variable
  catalog (Outcome/Exposure/Patient Characteristic/Clinical Characteristic/
  Cluster/ID/Derivation Helper)
- scripts/generate-tabular-sap.py: openpyxl renderer with section-banner
  highlighting and frozen header rows
- example CSVs sourced from the SBT-validation real-world SAP

Cross-links:
- ce-plan SAP template: SAP-12 (Output Catalog) and SAP-13 (Variable Catalog)
  point at the tabular companion
- ce-work: when analysis/sap-tables/02-outputs.csv exists, the task list is
  seeded from the catalog with one task per artifact; --match-sap-tabular
  enforces 1:1 catalog-to-output coverage at ship time

README updated with the 5 new skills and 5 new reviewer agents. Plugin now
ships 23 skills, 46 agents, 1 MCP server. release:validate passes; 689/689
tests pass; ce-compound-refresh schema mirrored to satisfy drift test.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…bearing parts

After auditing against CE original, the new workflow scaffolding had drifted
into multi-stakeholder regulatory ceremony that solo and small-team users
have to work around. This commit cuts the ceremony, keeps the gates that
actually catch real bugs, and folds adjacent reviewers together.

Cuts:
- ce-revise skill: revision rounds + per-query state machine + structured
  response-to-reviewers document. Reality: a markdown table tracked in the
  ce-work task list does the job. (-1 skill, -159 lines)
- ce-pilot skill: sandboxed feasibility runs with handoff document and
  cross-contamination check. Reality: pilots/<name>/ as a folder
  convention is enough. (-1 skill, -140 lines)
- ce-freeze skill -> scripts/freeze-submission.sh: the freeze logic is
  ~100 lines of bash (tag commit + write manifest yaml). The skill version
  was 151 lines of SKILL.md plus a 61-line schema. Same outcome, no
  ceremony. (-1 skill, -212 lines, +97 line script)
- ce-sap-amendment-reviewer agent: 8 finding categories merged down to
  the 3 that actually matter (no log entry / primary endpoint after lock /
  code drift after amendment) and folded into ce-sap-drift-detector. The
  remaining 5 findings were either policy-level (PI sign-off mechanics)
  or duplicated drift-detector behavior. (-1 agent, +20 lines in drift
  detector)

Opt-in (no longer auto-dispatched):
- ce-targets-pipeline-reviewer: targets is one specific R framework; users
  who aren't on it shouldn't pay context cost. Now requires explicit opt-in
  via reviewers: list in stack profile.
- ce-quarto-render-reviewer: same rationale. Quarto is dominant but not
  universal; opt-in via stack profile.

Phase flag simplification:
- ce-code-review: phase: now accepts blinded-eda | confirmatory | general.
  Dropped revision (ce-revise gone) and pilot (ce-pilot gone). The
  blinded-eda block on inferential-code-against-assignment-variable stays;
  that's the high-value gate.

Net:
- Skills: 23 -> 20
- Agents: 46 -> 45
- New SKILL.md lines (this round): 712 -> ~250
- release:validate: green (20 skills, 45 agents, 1 MCP server)
- bun test: 675/675 pass

What survives (the load-bearing parts):
- ce-data-qa skill: 16-check QA gate with GO/NO-GO emit
- ce-sap-tabular skill: SBTSAP-style 5-table catalog
- ce-data-mapping-reviewer + ce-phi-leak-reviewer agents
- data_wave_register + data_lock + sap_amend MCP tools
- data_root + blinding_state stack-profile fields
- phase-aware ce-code-review (blinded-eda enforced)
- ce-sap-drift-detector with amendment + blinding-state coverage
- Tabular SAP catalog seeds ce-work task list
- ce-compound deterministic dedup fingerprints

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Goal: typing /ce-code-review just works -- no flags, no opt-in syntax, no
config knobs. The dispatch table is short enough that the LLM gets it right
and reinforced by each agent's own description: frontmatter, the way CE
original does it.

Three drifts removed:

1. Opt-in syntax for ce-targets-pipeline-reviewer / ce-quarto-render-reviewer
   dropped. They now spawn automatically when their trigger files appear in
   the diff (_targets.R / .qmd / etc.), same pattern as every other reviewer.
   No 'reviewers: [...]' list to maintain in the stack profile.

2. The phase: argument flag dropped. Blinding-state awareness is now an
   automatic single paragraph: read stack_profile.blinding_state; if blinded,
   refuse ce-methods-reviewer and ce-multiplicity-reviewer and emit a P0
   block when inferential code references the assignment variable. Otherwise
   proceed normally. Nothing for the user to type.

3. The --match-sap-tabular flag in ce-work dropped. The skill auto-detects
   analysis/sap-tables/02-outputs.csv and seeds tasks from it when present;
   when absent, behavior reverts to the prose SAP tracking. Same outcome,
   no syntax to learn.

Dispatch table consolidated:

The four prose dispatch tables (always-on / statistical / language-specific
/ cross-cutting -- ~80 lines) collapsed to one short two-column table:
'agent | spawn when...'. 18 reviewers, one row each, each with a short
mechanical selector phrase. Same shape as CE original.

The persona-catalog.md reference file restructured to mirror the same short
table; selection-rules prose trimmed.

Net: -90 / +50 lines across 4 files. No new files, no scripts, no tests
added. release:validate green (20 skills, 45 agents, 1 MCP server). bun
test 675/675 pass.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…A+B)

Adds 13 skills and 10 agents to make ce-datascience bespoke for biostats /
ML-AI in biomedicine / bioinformatics / EHR-administrative data, mapped to
the academic paper lifecycle: data -> SAP -> peer methods (PubMed) ->
checklist match -> data QA -> SAP -> sprints with human audit.

Phase A skills (lifecycle scaffolding):
- /ce-pubmed              PubMed/MEDLINE search via NCBI E-utilities with MeSH
                          expansion and structured result tables
- /ce-method-extract      Extract structured statistical methods from a PubMed
                          result set into a comparison table for SAP justification
- /ce-cohort-build        Define a study cohort using OMOP concept sets / ICD /
                          CPT / LOINC code lists with vocabulary version pinning;
                          outputs SQL, JSON spec, and CONSORT-flow waterfall
- /ce-checklist-match     Pick the right reporting checklist (CONSORT / STROBE /
                          TRIPOD+AI / etc) at PLAN time, before SAP drafting
- /ce-power               Compute sample size with sensitivity sweep across
                          plausible effect sizes; produces R or Python script
                          and a SAP-ready paragraph
- /ce-sprint              Open or close an auditable sprint -- bounded scope,
                          named human reviewer, planned outputs from the SAP
                          tabular catalog, audit gate at close

Phase A agents:
- ce-data-leakage-reviewer       Target leakage, train-test contamination,
                                 look-ahead bias, normalization fit on test set,
                                 subject-in-both-splits
- ce-omop-mapping-reviewer       OMOP CDM correctness -- vocab version pinning,
                                 valid-window honoring, descendant inclusion,
                                 era vs occurrence, observation_period
- ce-bioinfo-pipeline-reviewer   Snakemake / Nextflow / CWL / Bioconductor --
                                 env pinning, reference pinning, sample-sheet
                                 validation, output checksums, caching traps
- ce-fairness-reviewer           Subgroup performance auditing for clinical
                                 prediction models (sex / race / age / site /
                                 payer) against TRIPOD+AI and FDA AI/ML
- ce-sprint-audit-reviewer       Audits a sprint's planned-vs-actual outputs,
                                 scope discipline, and reproducibility re-run;
                                 dispatched only by /ce-sprint close

Phase B skills (lifecycle artifacts):
- /ce-bioinfo-qc          Sequencing / omics data QA gate: FastQC / MultiQC /
                          sample swap detection / batch-effect screen for FASTQ,
                          BAM, count matrices, methylation arrays
- /ce-prereg              Generate a pre-registration form for OSF /
                          ClinicalTrials.gov / PROSPERO / AsPredicted from the
                          locked SAP
- /ce-model-card          Generate a Mitchell-style model card with overall +
                          subgroup performance and ethical considerations
- /ce-effect-size         Pool effect-size estimates from prior literature
                          (random-effects REML) into a defensible assumption
                          for /ce-power
- /ce-genome-build        Pin genome build (GRCh37 / GRCh38 / T2T) and
                          annotation version (GENCODE / Ensembl); audit every
                          output for build consistency
- /ce-phenotype-validate  Validate an EHR-derived phenotype algorithm against
                          a chart-review gold standard; PPV / NPV / sensitivity /
                          specificity with Wilson 95% CIs overall and by subgroup
- /ce-ml-experiment-track Wire up ML experiment tracking (mlflow / wandb / dvc /
                          offline-YAML); generate boilerplate, configure backend,
                          define required-log schema

Phase B agents:
- ce-calibration-reviewer            Calibration plot, intercept/slope, Brier,
                                     ICI, decision-curve analysis -- catches the
                                     AUC-only TRIPOD+AI gap
- ce-omics-batch-reviewer            Batch-condition confound detection in
                                     differential expression / methylation /
                                     proteomics; flags blind ComBat / RUV / SVA
- ce-concept-drift-reviewer          Vocabulary drift across time -- ICD-9-to-10
                                     transition, CPT yearly updates, SNOMED
                                     concept_id deprecation, vocab refresh drift
- ce-administrative-data-reviewer    Claims-data idiosyncrasies -- continuous
                                     enrollment, look-back, claims truncation,
                                     payer mix, NDC-to-RxNorm, claims-vs-
                                     clinical disconnect
- ce-causal-inference-reviewer       DAG specification, confounder set,
                                     time-zero alignment, positivity, estimand,
                                     sensitivity analyses for IPTW / matching /
                                     MSM / g-computation / DR / IV / RDD / DiD /
                                     target-trial emulation

Frictionless dispatch preserved:

The 10 new conditional reviewers are added as 10 short rows to the existing
ce-code-review SKILL.md table -- each with one-line spawn condition. No new
flags, no opt-in syntax. ce-sprint-audit-reviewer is the only one not
selected by code-review (only /ce-sprint close dispatches it).

Each new skill is a single typed /command with zero required flags, mirroring
CE-original. Each new agent's frontmatter description: encodes the same
spawn condition that appears in the dispatch table.

Net: 23 new files (13 skill SKILL.md + 10 agent .agent.md) + 35 reference
files for skill-specific content. release:validate green (33 skills,
55 agents, 1 MCP server). bun test 747/747 pass.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…+B skills

Tighten the 13 biomedical-lifecycle skill descriptions to follow skill-creator
conventions (third-person, explicit 'Use whenever the user mentions...' trigger
keywords) so dispatch is deterministic. Add bundled scripts that wrap the
canonical tool of record for each domain, replacing prose-only workflows with
runnable references the skill points at via progressive disclosure:

- ce-pubmed:             scripts/pubmed_search.py        biopython.Entrez (auto rate-limit + retry)
- ce-phenotype-validate: scripts/validate_phenotype.py   PPV/NPV/sens/spec with Wilson 95% CIs
- ce-cohort-build:       scripts/concept_set_to_capr.R   OHDSI Capr concept-set + ATLAS JSON
- ce-power:              scripts/pmsampsize_runner.R     Riley 2018 four-criterion sample size
- ce-effect-size:        scripts/pool_effects.R          meta::metagen REML + 95% PI + forest
- ce-sprint:             scripts/sprint.py               sprint-log.yaml audit-trail state machine
- ce-genome-build:       scripts/audit_build.py          BAM/VCF/GTF cross-build mismatch audit

747/747 tests pass; release:validate green at 33 skills, 55 agents.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
The 13 Phase A+B biomedical skills were great in isolation but did not talk
to each other. Skills emitted handoff signals (__CE_PUBMED_RESULTS__,
__CE_EFFECT_SIZE__, __CE_SPRINT__, etc.) that no other skill consumed, and
the upstream entry points (ce-ideate, ce-plan, ce-work, ce-code-review)
had no idea the biomedical skills existed.

This commit fixes the plumbing so the lifecycle actually closes:

  /ce-ideate (biomedical mode) -> /ce-research-question -> /ce-pubmed ->
  /ce-method-extract -> /ce-checklist-match -> /ce-cohort-build ->
  /ce-data-qa -> /ce-effect-size -> /ce-power -> /ce-plan SAP ->
  /ce-sap-tabular -> /ce-sprint open -> /ce-work -> /ce-code-review ->
  /ce-sprint close -> (loop or /ce-compound)

Edits to existing workflow skills:

- ce-ideate: Phase 0.3 grows a Decision 0 that routes biomedical research
  questions to a new biomedical-research mode with 6 frames calibrated
  for biostat work (PICO, FINER, equipoise, target-trial reframing,
  reporting-checklist anchoring, prior-art landscape) instead of the
  software frames. Adds references/biomedical-frames.md.

- ce-plan: SAP-Phase 3 step 2 now scans chat context and analysis/ for
  upstream __CE_*__ signals from /ce-pubmed, /ce-method-extract,
  /ce-checklist-match, /ce-cohort-build, /ce-data-qa,
  /ce-phenotype-validate, /ce-effect-size, /ce-power, and uses each
  signal's output file as the authoritative input for its SAP section.
  Missing signals become explicit <!-- GAP --> markers.

- ce-work: Phase 1 step 1 now reads analysis/sprint-log.yaml. When a
  sprint is open, the sprint scope is enforced as a hard scope filter
  on edits and a banner is printed before the task list.

- ce-code-review: Stage 3 conditional row for ce-reporting-checklist-reviewer
  now reads reporting_checklist as a non-null string (e.g., 'STROBE')
  rather than the legacy boolean, and passes the value to the reviewer
  as the checklist identifier.

- ce-checklist-match: writes the canonical reporting_checklist (string) +
  reporting_checklist_extensions (list) shape; emits unified
  __CE_CHECKLIST__ signal for /ce-plan and /ce-code-review to read.

- ce-sprint: scripts/sprint.py close action emits a machine-parseable
  __CE_SPRINT_AUDIT_DISPATCH__ line so the orchestrator actually fires
  ce-sprint-audit-reviewer (the description claimed this; the script
  did not). On a failing audit, the sprint flips back to open.

- ce-cohort-build: names the seam to /ce-data-qa explicitly; emits
  unified __CE_COHORT__ signal.

- ce-data-qa: prerequisites now point at /ce-cohort-build; emits unified
  __CE_DATA_QA__ envelope alongside the legacy GO/NO-GO lines.

- ce-power: __CE_POWER__ envelope normalized to match what /ce-plan
  expects in its signal lookup table.

New skill:

- /ce-research-question (~500 lines including 3 reference files):
  hardens a fuzzy clinical question into a structured PICO + FINER
  + suggested PubMed query + suggested checklist stored at
  analysis/research-question.yaml. Sits between /ce-ideate biomedical
  mode and /ce-pubmed. Output is structured data the rest of the
  lifecycle reads as input; complements /ce-brainstorm rather than
  duplicating it.

Plugin now ships 34 skills and 55 agents.

Validation:
  bun run release:validate -> green (34 skills, 55 agents, 1 MCP)
  bun test                 -> 751/751

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
… context

Previously the biomedical skills emitted handoff signals that consumers
did not parse, used drifting key shapes (__CE_DATA_QA__ wrote
blockers/warns; /ce-plan looked for issues; __CE_POWER__ had two
incompatible shapes; __CE_EFFECT_SIZE__ narrative mode dropped the
keys consumers expected), and the description-driven dispatch promised
composition that the SKILL bodies did not deliver. Sprint-log path
collided across two writers. The audit-reviewer Task() dispatch was
gestural, not literal.

Edit A — Lock the signal envelope contract:
- /ce-plan SAP table updated to the actual emitter shapes; every key
  documented with type, optional/required, null semantics
- pmsampsize_runner.R: design= replaces type=; total= replaces n=
- pool_effects.R narrative mode now emits same key set as REML mode
  with point=null ci=null i2=null mode=narrative
- ce-cohort-build emits yaml= alongside waterfall=
- ce-phenotype-validate body matches the script (name=, yaml=, report=)

Edit B — Wire downstream consumers to read upstream signals (the part
that makes 'slash commands compose with current context' actually
true):
- /ce-pubmed step 0 scans __CE_RESEARCH_QUESTION__; uses
  suggested_pubmed_query if no <query terms> arg
- /ce-checklist-match step 0 pre-fills design / population / primary
  checklist from /ce-research-question yaml
- /ce-cohort-build step 0 seeds cohort criteria from pico.population
  + pico.intervention_or_exposure + pico.outcome
- /ce-method-extract step 0 picks up the CSV from __CE_PUBMED_RESULTS__
  when no path arg given
- /ce-effect-size step 0 picks up methods CSV from __CE_METHOD_EXTRACT__
- /ce-power step 0 anchors --effect-size to __CE_EFFECT_SIZE__ point=
  in REML mode; refuses silent fallback in narrative mode

Edit C — Sprint-log path collision: standardize on
analysis/sprint-log.yaml (top-level audit trail, one file per
project; the script already wrote here). Per-sprint summary closeouts
remain at analysis/sprints/<name>/summary.md as a separate artifact.

Edit D — Sprint-audit dispatch made literal: the Task() invocation in
/ce-sprint close is now a copy-pasteable template with subagent_type,
description, prompt body, and a JSON return contract, replacing the
prior 'fire the Task tool with the parameters from the dispatch line'
that models would not reliably synthesize.

Edit E — Skill-creator descriptions tightened: /ce-data-qa,
/ce-sap-tabular, /ce-checklist-match now follow the trigger-rich
'Use whenever the user mentions ...' shape with explicit keywords so
auto-dispatch fires from natural-language requests.

Validation:
  bun run release:validate -> green (34 skills, 55 agents, 1 MCP)
  bun test                 -> 751/751

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
…u.com)

Adds ce-clif skill that auto-activates whenever the session is operating
against a CLIF (Common Longitudinal ICU data Format) consortium repo, the
mCIDE schema, the clif-icu.com website, or any project derived from
clif-consortium/project-template. Codifies CLIF rules so the rest of the
ce-* lifecycle stops treating CLIF data like a generic Parquet dataset:

- Parquet-only storage (no CSV / Feather for CLIF tables)
- Timezone-aware UTC for *_dttm columns
- VARCHAR patient_id / hospitalization_id (no integer casts)
- mCIDE-allow-listed values for every *_category column
- Project layout enforced (code/, config/, outlier-thresholds/, output/, renv/)
- Three-script architecture from WORKFLOW.md (QC -> cohort -> analysis)
- HIPAA / no-PHI rules for output/
- Protected paths (mCIDE/, ddl/, outlier-handling/, reference_ranges/,
  WORKFLOW.md) require explicit POC sign-off; the POC table mirrors
  the upstream README

Wires __CE_CLIF__ active=true into the lifecycle so ce-cohort-build,
ce-data-qa, ce-plan, ce-checklist-match, ce-code-review, and ce-work all
switch to CLIF behavior when the signal is in chat context.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
sajor2000 and others added 7 commits April 28, 2026 21:10
…dance

Per Anthropic skill-authoring best practices, SKILL.md bodies should stay
under 500 lines and detailed content should live in one-level-deep
references with a table of contents on files >100 lines.

Splits applied:
- ce-plan (926 -> 507 lines): extracted SAP-mode workflow,
  Phase 1 context-gathering detail, and the implementation-mode plan
  templates into references/sap-mode-workflow.md, phase1-context-gathering.md,
  and plan-template.md (each with TOC).
- ce-compound (564 -> 439): extracted What-It-Captures / Preconditions /
  What-It-Creates / Common-Mistakes / Success-Output / Compounding-Philosophy
  into references/reference-material.md.
- ce-compound-refresh (679 -> 497): extracted Phase 1.75 Document-Set
  Analysis, Phase 3 Ask-for-Decisions, and Phase 5 Commit-Changes into
  three references with TOCs.

ce-code-review (856 lines) is intentionally not split this round: its
contract tests (tests/review-skill-contract.test.ts) assert verbatim
phrases must remain in SKILL.md, and splitting would require coordinated
test updates beyond the scope of this audit.

Validation: bun run release:validate green (55 agents, 35 skills),
bun test green (755/755).

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Refresh the CLIF profile to the latest tagged data-dictionary release and
inject canonical Python and R code patterns drawn directly from the
upstream consortium repos.

Changes:
- ce-clif/SKILL.md: default `version=2.1.1` (was `<2.0.0|2.1.0>`); document
  v2.2.0/v3.0.0 as opt-in WIP. Add "Code recipes" section that routes by
  __CE_LANG__ to the new clifpy / R-template recipe references.
- ce-clif/references/clif-rules.md: pin v2.1.1 source notes; replace dead
  data-dictionary URL with the v2.1.1 GitHub release tag; add clifpy
  (PyPI: pip install clifpy) and CLIF-Project-Template links to §12.
- ce-clif/references/mcide-vocab.md: retitle v2.1.1, add 17-entry TOC
  (Anthropic guidance: TOC on >100-line refs); add "Coming in v2.2.0"
  preview section + refresh-policy note.
- ce-clif/references/clifpy-recipes.md (new, 9-section TOC): canonical
  Python recipes — ClifOrchestrator quick-start, validate_all, SOFA scores,
  hourly wide dataset, vitals outlier handling, encounter stitching, DQA,
  unit conversion for medications, MDRO/Charlson flags. Sourced verbatim
  from clifpy's examples/ directory.
- ce-clif/references/r-template-recipes.md (new, 10-section TOC): canonical
  R recipes — repo layout, renv bootstrap, config/config.json shape,
  utils/config.R + utils/outlier_handler.R pattern, numbered template
  scripts (cohort_id, QC, outlier handling, analysis), arrow::open_dataset
  reads. Sourced from CLIF-Project-Template's code/templates/R/.
- ce-cohort-build/SKILL.md, ce-data-qa/SKILL.md, ce-work/SKILL.md: 1-line
  pointers from CLIF stanzas to the lang-specific recipe files so analysts
  use the consortium's tested implementations rather than rolling their own.

Validation: bun run release:validate (55 agents, 35 skills), bun test
(755/755).

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Add a new ce-language-detect skill with weighted repository-signal rules for python/r/both/unknown and wire __CE_LANG__ into CLIF consumers. ce-setup now runs language auto-detection (no language prompt), persists language_detect metadata, and emits __CE_LANG__ for downstream skills.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Add 4 new skills:
- ce-workflow: lifecycle navigator for 5 project types (observational,
  RCT, prediction/ML, bioinformatics, technical) with language and
  data-layer routing
- ce-verify: mid-workflow analysis verification gate (sample size,
  leakage, effect direction, missing data, PHI, figure quality,
  reproducibility) — inspired by Superpowers' verification-before-
  completion pattern
- ce-optimize: ported from CE with DS adaptations (cross-validation
  guardrails, leakage detection, mlflow integration, SAP alignment)
- ce-resolve-pr-feedback: ported from CE with methodology review
  triggers (estimand, sample size, sensitivity analysis)

Surface 3 previously unlisted skills in plugin README:
- ce-research-question (PICO hardening)
- ce-clif (ICU consortium profile)
- ce-language-detect (internal, counted but not tabled)

Rewrite root README for the ce-datascience fork with:
- Full attribution to Kieran Klaassen / Every (upstream CE plugin)
- BMAD and Superpowers influence acknowledgment
- Data scientist workflow examples (observational, prediction, CLIF)
- Language support table (Python Jupyter/Marimo, R)
- Data layer support table (OMOP, CLIF, admin claims, bioinformatics)
- Reporting guidelines coverage (16 checklists)
- Clear separation of upstream vs new work

Update LICENSE to dual copyright (Rojas 2026 + Every 2025).

Plugin: 40 skills, 55 agents. All 773 tests pass.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Replace the marketplace /install-plugin command (doesn't work for
self-hosted repos) with clear step-by-step instructions for all 6
supported platforms: Claude Code (--plugin-dir + alias), Codex, Pi
(with extension prerequisites), Gemini CLI, OpenCode, and Kiro.

Add updating instructions (git pull + bun install).

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…olete

Verified against github.com/Common-Longitudinal-ICU-data-Format/CLIF/releases:
- v2.1.1 remains the latest stable release (Jan 2026)
- v2.2.0 is marked OBSOLETE on GitHub, replaced by v3.0.0
- v3.0.0 is a pre-release (Mar 2026, multimodal extension)

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
RECORD: 13 items supplementing STROBE for studies using routinely-
collected health data (EHR, claims, registries). Covers data source
description, code list documentation, linkage quality, data cleaning,
misclassification sensitivity analyses, and data access statements.
Reference: Benchimol et al. PLoS Med 2015. PMID: 26440803.

RECORD-PE: 11 items extending RECORD for pharmacoepidemiology studies.
Covers drug exposure definition (prescribing vs dispensing vs admin),
dose/duration measurement, comparator selection, and PE-specific biases
(immortal time, confounding by indication, protopathic bias, healthy
user). Reference: Langan et al. BMJ 2018. PMID: 30429167.

Both were already referenced in ce-checklist-match routing map but had
no backing checklist files. Closes the P0 items from issue #2.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
@sajor2000
sajor2000 merged commit 8777c24 into main Apr 29, 2026
2 checks passed
@sajor2000
sajor2000 deleted the feat/ce-datascience-fork branch April 29, 2026 18:55
sajor2000 added a commit that referenced this pull request Oct 21, 2026
Gaps #3, #5, #7, #10 closed (PRs #150, #151, #153, #154); #1, #6, #8
tracked as issues #141, #144, #146 with scoping; #9 wontfix as #147.

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant