Skip to content

Add execution harness and adapters (stubs) - Milestone 4 - #24

Merged
hyperpolymath merged 1 commit into
mainfrom
feat/milestone4-execution-harness
Sep 19, 2026
Merged

hyperpolymath merged 1 commit into
mainfrom
feat/milestone4-execution-harness

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Milestone 4 — Execution harness

Implements src/analysis/Execution.jl with abstract AnalysisAdapter, RAdapter, JuliaAdapter, ExecutionDiagnostics, ExecutionManifest, ExecutionResult, self_diagnostics, safe_self_healing, prepare_analysis_table (declared transform, offset, zero_policy, epistemic filtering, Advanced validation, hard-stop DANGER banner), run_analysis stub (full manifest hash chain).

Tests: test/unit/test_execution.jl covers CLR pseudocount=1 epsilon=1e-6 drop vs impute, adapter mismatch, DANGER banners.

Board: https://github.com/users/hyperpolymath/projects/45

@coderabbitai

coderabbitai Bot commented Sep 19, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: e85ac36b-2b54-48c0-b571-36c31d966f2a

📥 Commits

Reviewing files that changed from the base of the PR and between 4ea9ed0 and c998c1a.

📒 Files selected for processing (4)
  • src/MetaManifold.jl
  • src/analysis/Execution.jl
  • test/runtests.jl
  • test/unit/test_execution.jl
 _________________________________________________________
< This PR is 10% code and 90% emotional support comments. >
 ---------------------------------------------------------
  \
   \   (\__/)
       (•ㅅ•)
       /   づ

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sonarqubecloud

Copy link
Copy Markdown

@hyperpolymath
hyperpolymath merged commit 5f078f7 into main Sep 19, 2026
1 of 4 checks passed
@hyperpolymath
hyperpolymath deleted the feat/milestone4-execution-harness branch September 19, 2026 00:56
hyperpolymath added a commit that referenced this pull request Oct 18, 2026
Implement #37. analysis.differential.dispersion chooses where nb_glm's
per-taxon dispersion theta comes from. The default glm_nb keeps MASS::
glm.nb's maximum-likelihood theta per taxon, so #24's results are unchanged.
The alternative glmGamPoi fits one glmGamPoi::glm_gp over all taxa passing
min_prevalence, reads its overdispersion_shrinkage_list$dispersion_trend,
and refits each taxon through MASS::negative.binomial(theta = 1/trend), so
the inference is still a Wald test of the group coefficient at fixed scale
1. The trend is plugged in as fixed: its estimation uncertainty is not
propagated, and this is not glmGamPoi's quasi-likelihood test.

A glm_gp fit error or a trend of the wrong length fails every taxon; a zero
or invalid trend marks only its own taxon as a boundary or failed fit, with
NB Wald statistics withheld at the Poisson boundary. Missing glmGamPoi
raises GlmGamPoiUnavailable (HTTP 503 on the analysis route), never a
silent fallback to maximum-likelihood theta. glmGamPoi is refused for
clr_welch.

Config saves publish one validated YAML document: the method/dispersion
pair is checked across the affected study/group/run cascade before a single
atomic write, PATCH bodies apply all-or-nothing, and DELETEs re-validate
the value they reveal. The frontend offers the dispersion enum in method
settings, and the tests compare both dispersion paths against direct MASS
and glmGamPoi calls in R, failing (not skipping) in CI when glmGamPoi is
missing.

Closes #37.

Signed-off-by: Jonathan D.A. Jewell <6759885+hyperpolymath@users.noreply.github.com>
hyperpolymath added a commit that referenced this pull request Oct 18, 2026
Implement #37. analysis.differential.dispersion chooses the fits and the
test for nb_glm. The default glm_nb keeps MASS::glm.nb with its
maximum-likelihood theta per taxon and a Wald test of the group
coefficient, so #24's results are unchanged. The alternative glmGamPoi
fits one glmGamPoi::glm_gp over the taxa passing min_prevalence with
overdispersion shrinkage and reports glmGamPoi::test_de's quasi-likelihood
F-test of the group contrast -- its own published inference -- with the
returned log2 fold changes and their standard errors converted to the
natural-log scale so every method reports one effect scale. The reported
dispersion is the inverse of the shrunken quasi-likelihood dispersion the
test used.

A glm_gp or test_de error fails every taxon; a zero shrunken dispersion
marks only its own taxon as a Poisson boundary and withholds inference
there, and an unusable dispersion fails only its own taxon. Missing
glmGamPoi raises GlmGamPoiUnavailable (HTTP 503 on the analysis route),
never a silent fallback to another estimator or test. glmGamPoi is
refused for clr_welch; the pair rule lives in DifferentialConfig and is
reported at analysis time, while the config routes keep their ordinary
per-key validation with the dispersion spellings registered alongside the
other enums. The frontend offers the dispersion enum in method settings,
and the tests compare the glmGamPoi path against direct glm_gp + test_de
calls in R -- p-values, F statistics and log fold changes -- failing (not
skipping) in CI when glmGamPoi is missing.

Closes #37.

Signed-off-by: Jonathan D.A. Jewell <6759885+hyperpolymath@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