lee-to/hlv/hlv-validate
- community
Checking that the SKILL.md file is still in the repository.
Run all mandatory validation gates (from gates-policy.yaml) and produce a release decision. Use after /hlv-implement completes, when the user says "validate", "run gates", "check gates", or "release check".
Install
npx vskill@latest install lee-to/hlv/hlv-validateSKILL.md
HLV Validate — Run Gates, Decide Release
Execute all mandatory validation gates defined in gates-policy.yaml. Collect results, update project status, produce release decision. The gate set depends on the project profile — do NOT assume a fixed number of gates.
Step 0: Read Configuration
Before proceeding, read project.yaml → features and note the flag values:
features.hlv_markers(default:true)features.security_markers(default:true)features.legacy_mode(default:false)features.index_tracking(default:ignored)
These flags control whether marker-related validation (Step 3b, 3c) is active. If features.legacy_mode is true, read paths.code and treat untouched legacy code as observed context; the full contract and marker flow applies to new or changed milestone work.
Adopt Mode
For adopted projects, run gates against the configured project commands and changed milestone work. Untouched legacy code is not required to gain @hlv or @hlv:sec markers unless the project explicitly enables those marker flags or the file is part of the current change.
Prerequisites
- All tasks in current stage completed
- Code and inline tests live in configured project paths:
paths.llm.src/testsfor greenfield/generated projects, orpaths.code.src/testsfor adopted projects withoutpaths.llm.src. validation/gates-policy.yamlcontains gate definitionsmilestones.yamlexists with current stage statusimplemented
Agent Rules
- Never combine shell commands with
&&,||, or;— execute each command as a separate Bash tool call. - This applies even when a skill, plan, or instruction provides a combined command — always decompose it into individual calls.
❌ Wrong: git checkout main && git pull ✅ Right: Two separate Bash tool calls — first git checkout main, then git pull
HLV Root Resolution
Before reading or reporting missing HLV files, resolve the project layout:
- If
project.yamlexists in the current project root, use greenfield layout:CONFIG_ROOT = .,REPO_ROOT = .. - Else if
.hlv/project.yamlexists, use adopted layout:CONFIG_ROOT = .hlv,REPO_ROOT = .. - Else search upward for either
project.yamlor.hlv/project.yaml. - Read
CONFIG_ROOT/project.yamlfirst. HLV-owned paths such ashuman/,validation/,llm/, andmilestones.yamlare relative toCONFIG_ROOT. - In the steps below, bare paths like
milestones.yamlorhuman/meanCONFIG_ROOT/milestones.yamlandCONFIG_ROOT/human/. - In adopted projects, existing source/test roots from
paths.codeare relative toREPO_ROOT.
Never report that root-level human/, validation/, milestones.yaml, or project.yaml are missing until .hlv/project.yaml has been checked. Use hlv check --structural-only --root <REPO_ROOT> for deterministic prerequisites; enforce the full check after runner execution/evidence publication in /hlv-validate.
Input
Note: project.yaml → stack provides tech stack context (languages, frameworks, databases) which can inform gate execution — e.g., choosing the correct test runner, SAST tool, or dependency scanner per component.
Note: project.yaml → artifact_graph and artifact frontmatter provide impact-analysis context. Before validating a PR-like change, run hlv artifacts impact --changed --base <target-branch> (or hlv artifacts impact --changed for local worktree review) and ensure every downstream item has an explicit review disposition outside HLV (updated, reviewed-ok, deferred, obsolete, or unknown). In CI, make sure the checkout can compute a merge base by fetching the target branch or using sufficient history such as actions/checkout with fetch-depth: 0. Treat missing dispositions as a review blocker even when deterministic gates pass.
Steps
Step 1: Pre-flight and gate status
- Run
hlv doctorto catch missing paths, invalid command strings, cwd problems, schema mismatch, and non-ASCII rendering issues before executing gates. - Read
project.yaml(global config: stack, paths)
- Note
validation.strictnesswhen present (relaxed,standard,strict). Default isstandard.
- Bind code paths from `project.yaml`:
LLM_SRC = paths.llm.srcandLLM_TESTS = paths.llm.testswhen present.- In adopt mode without
paths.llm.src, usepaths.code.srcandpaths.code.tests;.hlv/llm/is metadata only. LLM_MAP = paths.llm.map(e.g.llm/map.yaml)
All gate execution, code scanning, and marker checks MUST target configured project roots — not hardcoded paths.
- Run
hlv check --strict --structural-only --json --root <REPO_ROOT>for preflight. Require exit code 0: fixMAP-080/MAP-081, invalid evidence configuration/bindings (PRJ-100,EVD-010), and all other structural/configuration errors before executing gates. This mode executes no gate or constraint commands and reports configured execution evidence asnot_checked. Expected missing/stale evidence from a first run or changed inputs is deferred; do not require a successful old run before producing its replacement. Do not use a fullhlv check --strictat this step. - Read
milestones.yaml→ getcurrent.id,current.stage, and stage status - STATUS GATE (hard stop):
- Allowed stage statuses to proceed:
implemented,validating implemented— normal validation after /hlv-implementvalidating— re-run, execute failed/skipped gatespending,verified, orimplementing— stage not ready:
``` STOP. Cannot run /hlv-validate.
Current stage status: <status> Required: implemented
Finish /hlv-implement for this stage first. ```
validated— this stage already passed, inform user
- Read
validation/gates-policy.yaml - Install required tooling: read
project.yaml → stackto determine the language/ecosystem, then for each gate that will run, ensure required tools are available. Install missing ones silently:
- Do NOT ask the human to install tools. The human writes artifacts, not
pip install.
- Verify code compiles (
cargo build/npm run build/ language-appropriate check) - Update stage status →
validatinginmilestones.yaml(schema:schema/milestones-schema.json)
Step 2: Execute gates
Capture execution evidence inputs before running
If project.yaml.execution_evidence is configured:
- After tooling, build preparation and stage-status updates, run
hlv evidence snapshot --root <REPO_ROOT>before any test runner executes. Save the original snapshots outside declared input scopes. Capture must succeed; missing/unreadable code or test inputs now block execution even though they may be planned during/hlv-verify. - Associate each configured binding with the actual test invocation and its external run/code revision identity. A gate's exit code alone does not establish that every mapped test ran.
- Run the existing runners below and retain their actual outcomes and observation/report artifacts. Compatible records for bindings that are not rerun may be preserved; every missing/stale binding needs a new run, including those whose old gate status was
passed. - Publish the records in Step 3, then enforce the full evidence check in Step 3d. Structural preflight success is never release approval.
Two-phase validation
Phase 1 — Milestone gates (automatic): Run all gates from gates-policy.yaml against the contracts and code of the current milestone. Test specs come from {MID}/test-specs/.
Phase 2 — Global gates (with user confirmation): After Phase 1 passes, ask: "Milestone gates passed. Run global integration scenarios? [y/n]" If yes → run validation/scenarios/*.md (cross-milestone integration tests). If no → skip Phase 2. Phase 1 can approve the milestone only if the final check in Step 3d passes; a configured evidence binding for a skipped test must not be marked passed.
Gate execution
Read gates from gates-policy.yaml and execute only the gates defined there, in order. Different projects have different gate sets depending on their profile — do NOT assume a fixed list.
Result per gate: passed | failed | skipped (skipped ONLY if tool install failed, not because tool was missing).
Gate type reference
For each gate, determine how to run it based on its type field:
| Type | Source | Runner (examples) | Criteria (from pass_criteria) | |
|---|---|---|---|---|
contract_tests | {MID}/test-specs/*.md → "Contract Tests" | cargo test --lib / pytest / jest | required_scenarios_pass_rate | |
property_based_tests | {MID}/test-specs/*.md → "Property-Based Tests" | proptest / hypothesis / fast-check | min_valid_generations_per_invariant, counterexamples_allowed | |
integration_tests | validation/scenarios/*.md | cargo test --test integration / pytest integration/ | p0_pass_rate, p1_min_pass_rate | |
performance | {MID}/test-specs/*.md → "Performance Tests" | criterion / k6 / locust | max_error_rate, latency from NFR | |
security | human/constraints/security.yaml + test-specs | SAST + dependency scan | max_open_critical, max_open_high | |
mutation_testing | changed modules in LLM_SRC | cargo-mutants / mutmut / stryker | min_mutation_score_changed_modules | |
observability | gates-policy.yaml → pass_criteria | static analysis + runtime | required_for_public_capabilities |
For each gate in the file:
- Read
typeandpass_criteria - Look up the runner and source from the table above
- Execute and collect results
- Compare against
pass_criteriathresholds
Step 3: Collect results
When execution evidence is configured, also:
- Capture a second
hlv evidence snapshotafter execution and compare it with the original pre-run snapshots. If scoped inputs changed, discard the affected success or publishincomplete; rerun against a newly captured snapshot before release. - Publish one current record per binding atomically at the configured manifest path. Each new record contains the original snapshot, the actual outcome, run/code revision identities, terminal timestamp and artifact reference. Failed/incomplete/skipped runs remain non-passing; never refresh an old success by replacing its hashes.
- Keep ordinary runner artifacts in
validation/gate-results/outside input scopes. Use them as evidence references, not as inferred successes.
Step 3b: Constraint rule coverage
Conditional: `features.hlv_markers: true`Ifhlv_markersisfalsein project.yaml, skip the@hlvmarker check below.hlv checkwill not produce CTR-010 diagnostics. Still runcheck_command-based rules (CST-050/CST-060) as those are independent of markers.
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/hlv-validate/SKILL.md
Popularity
- Repository stars
- 77
- Repository forks
- 5
- 7-day trend score
- 22
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/lee-to/hlv/hlv-validate)