Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Ansible health check discovers host issues → fix one by one (write ops require human approval) → re-inspect → repeat until all healthy → generate HTML report
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-10 | ✗→✓ | ▲ Improved | 88% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 39% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 108% | 0% |
| case-09 | ✗→✓ | ▲ Improved | 7% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 58% | 0% |
| Name | Type | Required | Description | |------|------|----------|-------------| | inventory | string | No | Path to Ansible inventory file, defaults to ansible/inventory.ini | | playbook | string | No | Path to health check playbook, defaults to ansible/health_check.yml |
Before starting execution, initialize task_context.json:
json{ "task_id": "<task_id from input>", "current_step": 0, "current_step_id": null, "status": "running", "steps": { "inspect": "pending", "fix_loop": "pending", "generate_report": "pending" }, "updated_at": "<ISO timestamp>" }
Update this file after each step completes. On error, set step status to "failed" and overall status to "failed".
Type: script Description: Run Ansible playbook to inspect all hosts and generate an issue list
Execute the following command:
bashansible-playbook -i {inventory} {playbook} 2>&1 mv /tmp/host_issues.json host_issues.json
After completing this step, update task_context.json:
current_step_id to "inspect"steps.inspect to "completed"Type: loop Description: Fix loop: each iteration picks the most critical issue, produces a remediation plan, waits for human approval on write operations, executes the fix, then re-inspects all hosts. Repeats until no issues remain or max iterations reached.
Goal: host_issues.json has total_issues equal to 0 (all hosts healthy, no issues found) Max Iterations: 10
> This step executes as a loop. The body steps repeat until the goal is met or max iterations reached.
Type: inline Description: Select the single most critical issue from host_issues.json
Execution: Follow these instructions:
Read host_issues.json and schemas/selected_issue.schema.json.
Pick the SINGLE most critical issue using this priority order:
Write the selected issue to selected_issue.json following the schema.
If host_issues.json has total_issues == 0, write {"done": true} instead.
Output Files
selected_issue.jsonType: agent Description: Analyze the selected issue and create a concrete remediation plan (no execution)
Execution: Launch an independent agent with the following prompt file:
Read selected_issue.json and schemas/pending_action.schema.json.
STEP 1 — Investigate: SSH to the target host and check the actual situation. Understand the root cause before writing any plan. Do NOT guess or write generic commands.
STEP 2 — Plan: Based on your findings, write a concrete remediation plan to pending_action.json following the schema.
Do NOT execute anything. Only investigate and write the JSON file. If selected_issue.json contains {"done": true}, write {"done": true} to pending_action.json instead.
Output Files
pending_action.jsonType: inline Description: Human approval gate — present the remediation plan and wait for confirmation before executing
Execution: Follow these instructions:
Read pending_action.json.
If it contains {"done": true}, skip this step.
Otherwise, PRESENT the remediation plan from pending_action.json to the human:
Present the host, issue, risk level, and commands from pending_action.json.
Type "approve" to execute, or "reject" to skip this issue.
WAIT for the human to respond. Do NOT proceed without explicit approval. If approved, copy pending_action.json to approved_action.json. If rejected, write skip_action.json with {"status": "rejected", "reason": "rejected by human"}.
Type: agent Description: Execute the approved remediation
Execution: Launch an independent agent with the following prompt file:
Check for approved_action.json. If it exists, read it.
If skip_action.json exists instead, do NOT execute — write execute_result.json following schemas/execute_result.schema.json with status "skipped".
Execute the remediation: SSH into the target host and run the commands listed in approved_action.json.
Rules:
If pending_action.json had {"done": true}, write {"status": "all_done"} to execute_result.json.
Output Files
execute_result.jsonType: script Description: Re-run inspection to refresh the issue list
Execution: Execute the following command:
bashansible-playbook -i {inventory} {playbook} 2>&1 mv /tmp/host_issues.json host_issues.json
Output Files
host_issues.jsonAfter all body steps complete, evaluate:
Goal: host_issues.json has total_issues equal to 0 (all hosts healthy, no issues found)
Append a summary to iteration_history after each iteration.
After completing this step, update task_context.json:
current_step_id to "fix_loop"steps.fix_loop to "completed"Type: agent Description: Generate a polished HTML inspection and remediation report
Launch an independent agent with the following prompt file:
Dispatch instruction:
Read the final host_issues.json to get the current health status. Also read all execute_result.json files from the workspace to understand what was fixed.
Generate a single, self-contained, beautiful HTML report: health_report.html
The report should include:
commands executed, and before/after comparison
Design requirements:
Agent workflow:
After completing this step, update task_context.json:
current_step_id to "generate_report"steps.generate_report to "completed"Other measured skills in the registry, with their headline benchmark lift.