From jaan-to
Computes composite quality score from test results, security audits, dev detection, and PR review outputs to determine review depth.
npx claudepluginhub parhumm/jaan-to --plugin jaan-toThis skill is limited to using the following tools:
> Aggregate upstream quality signals into a composite score with routing recommendation.
Creates isolated Git worktrees for feature branches with prioritized directory selection, gitignore safety checks, auto project setup for Node/Python/Rust/Go, and baseline verification.
Executes implementation plans in current session by dispatching fresh subagents per independent task, with two-stage reviews: spec compliance then code quality.
Dispatches parallel agents to independently tackle 2+ tasks like separate test failures or subsystems without shared state or dependencies.
Aggregate upstream quality signals into a composite score with routing recommendation.
$JAAN_LEARN_DIR/jaan-to-qa-quality-gate.learn.md - Past lessons (loaded in Pre-Execution)$JAAN_TEMPLATES_DIR/jaan-to-qa-quality-gate.template.md - Output template${CLAUDE_PLUGIN_ROOT}/docs/extending/language-protocol.md - Language resolution protocolUpstream Outputs: $ARGUMENTS
Accepts 1-4 paths to upstream skill outputs:
At least 1 path is required. Missing signals are treated as null (not measured).
MANDATORY -- Read and execute ALL steps in: ${CLAUDE_PLUGIN_ROOT}/docs/extending/pre-execution-protocol.md
Skill name: qa-quality-gate
Execute: Step 0 (Init Guard) -> A (Load Lessons) -> B (Resolve Template) -> C (Offer Template Seeding)
Read and apply language protocol: ${CLAUDE_PLUGIN_ROOT}/docs/extending/language-protocol.md
Override field for this skill: language_qa-quality-gate
megathink
Use reasoning for:
For each provided path:
null if tool unavailable)Present signal inventory:
QUALITY SIGNALS
-------------------------------------------------------------
Signal Source Value Status
---------------------- ---------------- ----- ------
Static analysis detect-dev {val} {available/null}
Test pass rate + coverage qa-test-run {val} {available/null}
Mutation score qa-test-mutate {val} {available/null}
Security scan sec-audit-remediate {val} {available/null}
Code complexity detect-dev {val} {available/null}
Diff size/scope backend-pr-review {val} {available/null}
Available signals: {count}/6
Convert each signal to 0-1 scale:
| Signal | Raw Value | Normalization |
|---|---|---|
| Static analysis | pass/fail + finding count | 1.0 (pass, 0 findings) to 0.0 (fail, many criticals) |
| Test pass rate + coverage | pass rate %, coverage % | (pass_rate * 0.6 + coverage * 0.4) / 100 |
| Mutation score | percentage or null | score / 100, or null |
| Security scan | severity counts | 1.0 (no findings) to 0.0 (critical findings) |
| Code complexity | cyclomatic/cognitive | 1.0 (low) to 0.0 (very high) |
| Diff size/scope | lines changed, files | 1.0 (small) to 0.5 (large) |
jaan-to/config/settings.yaml):qa_quality_gate:
weights:
static_analysis: 0.20
test_pass_coverage: 0.25
mutation_score: 0.15
security_scan: 0.20
code_complexity: 0.10
diff_size: 0.10
When a signal is null (not measured), redistribute its weight proportionally across remaining non-null signals.
Example: if mutation score is null (weight 0.15):
1 / 0.85Formula: adjusted_weight[i] = original_weight[i] / sum_of_non_null_weights
Report: "Score based on {N}/6 available signals."
composite = sum(normalized_signal[i] * adjusted_weight[i]) for all non-null signals
If 3 or more signals score below 0.6 after normalization, skip remaining signal computation and route directly to "full human review". This avoids unnecessary computation when the outcome is already determined.
When a previous quality gate output exists for the same feature/PR, compare composite scores. If |current - previous| < 0.05, report "no significant change" and carry forward the previous routing recommendation. This prevents redundant reviews on minor score fluctuations.
| Score | Recommendation | Action |
|---|---|---|
| > 0.85 | "Recommend auto-approve -- all quality signals strong" | Lightweight review sufficient |
| 0.6-0.85 | "Recommend lightweight review -- AI-annotated concerns attached" | Focus on flagged areas |
| < 0.6 | "Recommend full human review -- significant quality signals flagged" | Comprehensive review needed |
Present composite score and recommendation:
QUALITY GATE RESULTS
-------------------------------------------------------------
Composite Score: {score} (based on {N}/6 signals)
Signal Breakdown:
Static Analysis (0.20): {normalized} -> weighted {contribution}
Test Pass + Coverage (0.25): {normalized} -> weighted {contribution}
Mutation Score (0.15): {normalized or "null (excluded)"} -> weighted {contribution}
Security Scan (0.20): {normalized} -> weighted {contribution}
Code Complexity (0.10): {normalized} -> weighted {contribution}
Diff Size (0.10): {normalized} -> weighted {contribution}
Recommendation: {routing recommendation text}
Null Signals: {list of null signals with reason}
Use AskUserQuestion:
This gate does NOT auto-approve. Human decision is final.
source "${CLAUDE_PLUGIN_ROOT}/scripts/lib/id-generator.sh"
SUBDOMAIN_DIR="$JAAN_OUTPUTS_DIR/qa/quality-gate"
mkdir -p "$SUBDOMAIN_DIR"
NEXT_ID=$(generate_next_id "$SUBDOMAIN_DIR")
Template:
Quality gate for {project/feature}: composite score {score} based on {N}/6 signals.
{recommendation}. Key concerns: {top 2-3 lowest signals}.
{null_signals_note if any}.
Path: $JAAN_OUTPUTS_DIR/qa/quality-gate/${NEXT_ID}-${slug}/
Main file: {id}-{slug}.md
Sections:
source "${CLAUDE_PLUGIN_ROOT}/scripts/lib/index-updater.sh"
add_to_index \
"$SUBDOMAIN_DIR/README.md" \
"$NEXT_ID" \
"${NEXT_ID}-${slug}" \
"{Project/Feature} Quality Gate" \
"{Executive Summary}"
Use AskUserQuestion:
If "Learn from this": Run /jaan-to:learn-add qa-quality-gate "{feedback}"
$JAAN_OUTPUTS_DIR/qa/quality-gate/{id}-{slug}/