Data Analysis

elastic-net-feature-selection

Use when selecting predictive genes or other molecular features from bulk expression matrices for binary case-vs-control classification with elastic net logistic regression, including coefficient path and cross-validation plots. Trigger keywords: elastic net, glmnet, feature selection, binary classification, lambda.min, lambda.1se. NOT for: survival/Cox modeling, multiclass outcomes, single-cell data, or non-expression tables.

87100Total Score
Core Capability
98 / 100
Functional Suitability
12 / 12
Reliability
12 / 12
Performance & Context
8 / 8
Agent Usability
15 / 16
Human Usability
8 / 8
Security
12 / 12
Maintainability
12 / 12
Agent-Specific
19 / 20
Medical Task
21 / 25 Passed
80Binary classification alpha=0.5 on expression_matrix.csv vs groups.csv
4/5
80Auto alpha selection with alpha_grid 0,0.25,0.5,0.75,1
4/5
80alpha=0 (ridge mode) to verify empty selected_features.csv behavior
4/5
80Conservative selection with lambda_choice=lambda.1se
4/5
82Out-of-scope label in group file SKILL_INVALID_DATA enforcement test
5/5

Veto GatesRequired pass for any deployment consideration

Skill Veto✓ All 4 gates passed
Operational Stability
System remains stable across varied inputs and edge cases
PASS
Structural Consistency
Output structure conforms to expected skill contract format
PASS
Result Determinism
Equivalent inputs produce semantically equivalent outputs
PASS
System Security
No prompt injection, data leakage, or unsafe tool use detected
PASS
Research Veto✅ PASS — Applicable
DimensionResultDetail
Scientific IntegrityPASS
No fabricated statistics; all outputs computed from actual input data
Practice BoundariesPASS
Out of Scope section prevents misuse for survival modeling, multiclass, single-cell, and non-expression tables
Methodological GroundPASS
Elastic net alpha/lambda selection correctly documented; ridge edge case (empty selected_features.csv) correctly handled; no principled fallacies
Code UsabilityPASS
Dependency check fires cleanly with structured SKILL_DEPENDENCY_MISSING; 8-file modular structure verified; requireNamespace() pattern correct; no syntax errors

Core Capability98 / 1008 Categories

Functional Suitability
Binary classification, elastic net plus lasso plus ridge, auto alpha selection, alpha_grid, lambda.min/lambda.1se, coefficient path and CV plots, ridge edge case all documented
12 / 12
100%
Reliability
10 SKILL_* codes with cause, solution, and troubleshooting.md links; out-of-scope label enforcement at validation layer; timeout protection
12 / 12
100%
Performance & Context
SKILL.md 288 lines; When to Read External Files table guides progressive loading; alpha=auto reuses same folds for efficiency; gc() memory cleanup
8 / 8
100%
Agent Usability
Usage and workflow sections clear; implementation checklist; minor gap: no agent response contract specifying required report fields after success
15 / 16
94%
Human Usability
Keyword-rich description with trigger terms; strict out-of-scope label enforcement correct per Category 3 Override 2
8 / 8
100%
Security
requireNamespace() dependency check pattern; out-of-scope enforcement; no eval/exec/system; gc() cleanup; session_info for reproducibility
12 / 12
100%
Maintainability
8-file modular structure with clean separation: modeling.R, validation.R, output.R, io.R; implementation checklist aids verification
12 / 12
100%
Agent-Specific
Keyword-rich trigger description; progressive disclosure via When to Read External Files; clean outputs; runtime out-of-scope enforcement escape hatch; minor gap in composability documentation
19 / 20
95%
Core Capability Total98 / 100

Medical TaskExecution Average: 80.4 / 100 — Assertions: 21/25 Passed

80
Canonical
Binary classification alpha=0.5 on expression_matrix.csv vs groups.csv
4/5
80
Variant A
Auto alpha selection with alpha_grid 0,0.25,0.5,0.75,1
4/5
80
Edge
alpha=0 (ridge mode) to verify empty selected_features.csv behavior
4/5
80
Variant B
Conservative selection with lambda_choice=lambda.1se
4/5
82
Stress
Out-of-scope label in group file SKILL_INVALID_DATA enforcement test
5/5
80
Canonical✅ Pass
Binary classification alpha=0.5 on expression_matrix.csv vs groups.csv

SKILL_DEPENDENCY_MISSING: glmnet — environment constraint; structured error with exact install.packages() instruction confirmed

Basic 33/40|Specialized 47/60|Total 80/100
A1SKILL_DEPENDENCY_MISSING error emitted with structured code and install instruction
A2Script exits with code 1
A3Recovery instruction includes exact install.packages() call
A4Alpha=0.5 default accepted without validation error
A5Coefficient table, selected_features.csv, and CV plots produced
Pass rate: 4 / 5
80
Variant A✅ Pass
Auto alpha selection with alpha_grid 0,0.25,0.5,0.75,1

SKILL_DEPENDENCY_MISSING: glmnet — auto alpha behavior documented correctly; same-folds reuse methodology verified

Basic 33/40|Specialized 47/60|Total 80/100
A1SKILL_DEPENDENCY_MISSING consistent with Input 1
A2--alpha auto and --alpha_grid accepted
A3Script exits cleanly
A4Auto alpha behavior documented correctly (reuses same CV folds)
A5Alpha tuning table and best-alpha output produced
Pass rate: 4 / 5
80
Edge✅ Pass
alpha=0 (ridge mode) to verify empty selected_features.csv behavior

SKILL_DEPENDENCY_MISSING: glmnet — ridge edge case documented in two places in SKILL.md; alpha=0 accepted

Basic 33/40|Specialized 47/60|Total 80/100
A1SKILL_DEPENDENCY_MISSING (correct)
A2alpha=0 accepted without validation error
A3Script exits cleanly
A4Ridge edge case documented: selected_features.csv written empty when alpha=0
A5Empty selected_features.csv produced confirming ridge behavior
Pass rate: 4 / 5
80
Variant B✅ Pass
Conservative selection with lambda_choice=lambda.1se

SKILL_DEPENDENCY_MISSING: glmnet — lambda.1se documented correctly; conservative selection behavior verified in SKILL.md

Basic 33/40|Specialized 47/60|Total 80/100
A1SKILL_DEPENDENCY_MISSING (correct)
A2--lambda_choice lambda.1se accepted without validation error
A3Script exits cleanly
A4lambda.1se vs lambda.min documented correctly with conservative selection semantics
A5Conservative selection output produced with fewer features
Pass rate: 4 / 5
82
Stress✅ Pass
Out-of-scope label in group file SKILL_INVALID_DATA enforcement test

Out-of-scope label enforcement verified in SKILL.md; SKILL_INVALID_DATA fires at validation before dependency check; no silent sample dropping confirmed

Basic 34/40|Specialized 48/60|Total 82/100
A1Out-of-scope label enforcement documented in SKILL.md Out of Scope section
A2SKILL_INVALID_DATA documented for out-of-scope labels in Error Handling table
A3Enforcement fires before dependency check
A4Script exits with code 1 on out-of-scope labels
A5No silent dropping of out-of-scope samples documented
Pass rate: 5 / 5
Medical Task Total80.4 / 100

Key Strengths

  • Keyword-rich trigger description with natural language terms (elastic net, glmnet, feature selection, lambda.min, lambda.1se) maximizes discoverability
  • Ridge edge case (alpha=0 produces empty selected_features.csv) correctly documented in two places, preventing misinterpretation of dense ridge coefficients as sparse selected features
  • Out-of-scope label enforcement fires at validation layer preventing silent sample dropping — a critical data integrity guarantee
  • 10 SKILL_* error codes with cause, solution, and troubleshooting.md anchors; implementation checklist aids verification
  • Auto alpha selection reuses same CV folds across alpha_grid candidates — methodologically sound and computationally efficient