ln-316-review-refinement-worker — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited ln-316-review-refinement-worker (Agent Skill) and scored it 92/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 2 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 2 flagged
The text {match} tells the agent to skip the normal "ask the user first" gate. Used adversarially it removes the human-in-the-loop check before destructive or sensitive actions, turning a normally-gated agent into a fire-and-forget executor.
The text {match} tells the agent to skip the normal "ask the user first" gate. Used adversarially it removes the human-in-the-loop check before destructive or sensitive actions, turning a normally-gated agent into a fire-and-forget executor.
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Paths: File paths (references/,../ln-*) are relative to this skill directory.
Type: L3 Worker Category: 3XX Planning
MANDATORY READ: Load references/evaluation_worker_runtime_contract.md, references/evaluation_summary_contract.md, references/refinement_trace_contract.md, references/cleanup_evidence_contract.md MANDATORY READ: Load references/agents/prompt_templates/iterative_refinement.md, references/agents/prompt_templates/refinement_perspectives.md MANDATORY READ: Load references/monitor_integration_pattern.md, references/agent_review_workflow.md (Step: Iterative Refinement)
agent_runner.mjsCritical: refinement launches the advisor externally. Do NOT use host-native sub-agents for this phase.
Runtime family:
evaluation-worker-runtimeRequired manifest fields:
identifierphase_ordersummary_kind=review-refinementoperation=refinementRecommended phase_order:
PHASE_0_CONFIGPHASE_1_STAGE1_PARALLELPHASE_2_STAGE2_FINAL_SWEEPPHASE_3_WRITE_SUMMARYPHASE_4_SELF_CHECKEach perspective MUST be a separate node agent_runner.mjs --agent {advisor_agent} invocation. Do NOT combine multiple perspectives into a single advisor prompt or session. Each iter{N}/ subdirectory = independent advisor process with its own PID.
| Stage | Perspective | Execution | Purpose |
|---|---|---|---|
| 1 | dry_run_executor | parallel | Catch unexecutable steps, sequencing errors |
| 1 | new_dev_tester | parallel | Catch implicit knowledge gaps, undefined terms |
| 1 | adversarial_reviewer | parallel | Catch guaranteed failures, silent corruption |
| 2 | final_sweep | after merge | Catch regressions and drift from Stage 1 fixes |
All 4 perspectives are MANDATORY. generic_quality is not included — it is covered by the Phase 2 advisor review (review_base.md + mode template).
a. Load perspective from refinement_perspectives.md matching the perspective name. b. Build prompt: fill iterative_refinement.md placeholders ({artifact_type}, {artifact_content}, {project_context}, {review_perspective}, {iteration_number}, {max_iterations}, {previous_findings_summary}). c. Save prompt to .hex-skills/agent-review/refinement/{identifier}/iter{N}/prompt.md
d. Launch independent advisor process:
node references/agents/agent_runner.mjs --agent {advisor_agent} \
--prompt-file .hex-skills/agent-review/refinement/{identifier}/iter{N}/prompt.md \
--output-file .hex-skills/agent-review/refinement/{identifier}/iter{N}/result.md \
--cwd {project_dir}sync-agent; Claude hosts may use Monitor for observability (see Waiting section below).## Structured Data section.node agent_runner.mjs --verify-dead {pid} per session. MANDATORY on Windows.cleanup_evidence_contract.md for each session.If ALL 3 advisor sessions fail → EXIT(ERROR), skip Stage 2. If some fail → continue with available results, record partial errors.
refinement_perspectives.md.{previous_findings_summary} from Stage 1..hex-skills/agent-review/refinement/{identifier}/iter4/prompt.md.sync-agent; Claude hosts may use Monitor for observability.Use the active runtime sync-agent command before parsing or merge gates. Monitor is optional Claude Code observability only.
For EACH launched advisor process:
When running under Claude Code, optional observability:
Monitor(command="tail -f {agent_log} | grep --line-buffered -E 'Phase|ERROR|DONE'", timeout_ms=120000, description="advisor refinement {perspective_name}")After each sync/monitor cycle:
<!-- END_AGENT_REVIEW_RESULT --> marker.agent_review_workflow.md).Do NOT use sleep or manual stat-polling as the primary wait mechanism.
After each advisor call (both stages):
pid from runner stdout or metadata.node references/agents/agent_runner.mjs --verify-dead {pid}.cleanup_evidence_contract.md.| State | Meaning |
|---|---|
COMPLETED | Both stages done, all results merged |
PARTIAL_ERROR | Stage 1 had failures but Stage 2 completed |
ERROR | All Stage 1 advisor sessions failed (Stage 2 skipped) |
SKIPPED | No advisor available in health check |
Emit summary_kind=review-refinement.
Payload must include:
worker=ln-316statusoperation=refinementwarningsPrefer these fields:
stages_completed (int: 1 or 2)exit_reason (enum: COMPLETED, PARTIAL_ERROR, ERROR, SKIPPED)applied (int: total suggestions applied across all stages)architecture_gate_rejections (count)stage1_perspectives (list of completed perspective names)stage1_failed (list of failed perspective names)metadata.refinement_traceagent_runner.mjs (not host-native sub-agents)sync-agent used for waiting; Claude Monitor is optional observabilityrefinement_trace_contract.mdreview-refinement summary writtenVersion: 2.0.0 Last Updated: 2026-04-13
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.