Append run log
SkillCloud & infraUse when a completed agent run must be recorded as durable, queryable evidence. Appends one entry to the JSONL run log under an ISO date guard, prunes expired entries, and updates the last-run pointer. Don''t use for remote, credential, publish, deploy, or irreversible changes.
Available today. Use it from your connected AI after setup.
No other account needed.
Connect ahel once, and every AI you use reads what you have installed.
Then ask your AI: use the Append run log skill
What this skill tells your AI
The instructions your AI receives, as published by outlinedriven/outline-driven-development in .devin/skills/append-run-log/SKILL.md and read by ahel’s review.
Contract
| Field | Bound contract |
|---|---|
| Trigger | A completed agent run must be recorded as durable, queryable evidence. |
| Authority | Reversible local: writes only the run log by appending; prior entries are never rewritten; rollback is version control. No remote mutation. |
| Side effect | Appends one entry to the append-only JSONL run log under an ISO-only date guard, prunes entries older than the declared retention window, and updates the last-run pointer. |
| Done | Exactly one entry exists per run with a unique run id, malformed lines are ignored rather than corrupting the log, and aggregate metrics are derivable from the log alone. |
Inputs
run_id: must be supplied, non-empty, and unique within the log.started_atandended_at: must be supplied as ISO 8601 UTC timestamps (YYYY-MM-DDTHH:mm:ssZ). The entry date guard is derived fromended_at.metrics: must be supplied as a JSON object of run measurements (for example, duration, token count, model, outcome). Aggregates are computed from these fields alone.log_path: must be supplied; path to the append-only JSONL run log.last_run_pointer_path: must be supplied; path to the last-run pointer file.retention_window: optional; an ISO 8601 duration or day count. When omitted, no pruning is performed.
Procedure
- Validate inputs at the trust boundary before any mutation:
run_idis non-empty;started_atandended_atparse as ISO 8601 UTC andended_atis not beforestarted_at;metricsis a JSON object. Reject any timestamp that is not ISO-only. Scan the log for an existing line whose parsedrun_idequals the supplied one; if found, stop withrejected-duplicateand do not mutate. Done when: inputs parse and no duplicaterun_idexists. - Bound scope: open
log_pathin append-only mode. Do not read-modify-write or rewrite any prior line. Done when:log_pathis open in append-only mode. - Compose one JSONL entry as a single line:
run_id,started_at,ended_at,metrics, anddateset to the ISO date portion ofended_atas the date guard. Done when: the entry is a single line with all fields and metrics sufficient to derive aggregates. - Append the entry as exactly one line terminated by a newline, then flush. No other line is altered. Done when: exactly one line with this
run_idexists in the log. - If
retention_windowis supplied, compute the cutoff from the current UTC date minus the window. Delete whole lines whosedateprecedes the cutoff. Never alter the content of a surviving line; deletion is the only mutation permitted on prior entries. Done when: expired lines are deleted and surviving lines are unaltered. - Update the last-run pointer at
last_run_pointer_pathto an object containing the newrun_idandended_at. Done when: the pointer contains the newrun_idandended_at.
Failure and recovery
rejected-invalid-input: a required input is missing, a timestamp is not ISO-only, ormetricsis not a JSON object. No mutation occurs. Report the rejected field and stop.rejected-duplicate: a line with the samerun_idalready exists. No mutation occurs. Report the existing entry and stop; never append a second entry for one run.malformed-existing-line: a prior line fails to parse as JSON or lacks required fields. Ignore it for aggregation and duplicate checks; never rewrite or delete it unless it is pruned by the retention window. It must not corrupt the log.partial-write: if an interrupted append leaves a line that fails the parse check, treat it as a malformed line (ignored), do not rewrite it, and re-append the intended entry only if no line with thisrun_idparses correctly.- Rollback rule: append-only. Validation failures before step 4 leave the log untouched. After a successful append, prior entries are never rolled back; only retention pruning may delete expired lines.
- Blocked result: if the done predicate cannot hold because the log is unwritable or the pointer path is unwritable, report
blockedwith the failing path and the unrecorded entry; do not claim the run is recorded.
Output
One new JSONL line in the run log, an updated last-run pointer, and any retention-pruned expired lines. Terminal classification is one of recorded, rejected-duplicate, rejected-invalid-input, or blocked. On recorded, aggregate metrics are derivable from the log alone.
Signals
- GitHub stars
- 52
- Forks
- 9
- Last commit
- Sep 2026
Advanced
- Catalog kind
- skill
- Gateway key
append-run-log- Source
- github.com/outlinedriven/outline-driven-development