agentleFS
HypercubedHypercubed/Agent-Knowledge-Starter-Kit/.agents/skills/task-closeout/SKILL.md

task-closeout

Skill7 starsChanged 2 months agoMITView on GitHub

Capture the current task into a structured temporary session bundle under `.agents/sessions/` so a learning agent can later distill durable repo knowledge. Use for completed, blocked, or abandoned tasks with meaningful changes, debugging, validation, or reusable lessons.

2 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions2 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 2

    1. linchpin/skills★ 1same name
    2. Sequela02/canasta★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository8 other files it gives its agents.

The file

Show its rules and text

We split this skill into the rules it gives an agent

23 rules. About 0 are common, 6 are distinctive, and 17 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 17

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Create a temporary handoff packet for later learning extraction.

    line 10
  2. Very specific:

    Follow Skill initialization and Procedure below.

    line 12
  3. Very specific:

    Run this once per target repo after the skill files are present under .agents/skills/task-closeout/ (for example after copying only that …

    line 16
  4. Very specific:

    If .agents/sessions/README.md is missing, create it from bootstrap/sessions/README.md in this skill folder.

    line 22
  5. Very specific:

    Ensure .agents/.gitignore exists.

    line 24
  6. Very specific:

    If .agents/.gitignore already exists, merge these two lines if they are absent.

    line 31
  7. Very specific:

    If the repo does not track .agents/.gitignore and the user relies on the repo root .gitignore, ensure equivalent patterns exist there: …

    line 33
  8. Very specific:

    Do not create durable knowledge files (AGENTS.md, docs/, playbooks/) as part of this skill.

    line 35
  9. Very specific:

    Write inside the repo to .agents/sessions/<session-folder>/.

    line 39
  10. Very specific:

    Do not update .agents/AGENTS.md or any other durable repo knowledge file.

    line 60
  11. Very specific:

    Never modify anything under openspec/ during closeout of an in-flight change.

    line 62
  12. Very specific:

    Do not edit files under .agents/skills/ during closeout.

    line 63
  13. Very specific:

    Treat the whole maintainer conversation as in-scope for active-task.md and learning-candidate.md unless the user explicitly limits closeout …

    line 64
  14. Distinctive:

    Do not write narrative summaries longer than necessary.

    line 65
  15. Distinctive:

    Prefer concise bullet lists.

    line 66
  16. Very specific:

    Create a session folder using the pattern YYYYMMDD-HHMMSS-short-topic.

    line 72
  17. Distinctive:

    Keep one task-closeout bundle per session folder.

    line 73
  18. Very specific:

    Write summary.json with status, metadata, repo_id, task_id, openspec_change (when applicable), and optional agent identifiers when …

    line 79
  19. Very specific:

    Treat agent and agent_session_id independently: record either one when available.

    line 90
  20. Distinctive:

    Do not invent session IDs or require manual lookup outside the agent/tool's supported session history.

    line 91
  21. Very specific:

    Use a deterministic, sortable folder name such as YYYYMMDD-HHMMSS-short-topic.

    line 95
  22. Distinctive:

    Keep the slug short, lowercase, and tied to the task goal.

    line 96
  23. Very specific:

    Do not treat the folder name as the canonical task identity.

    line 98

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Task Closeout

Goal

Create a temporary handoff packet for later learning extraction.

Follow Skill initialization and Procedure below. Required filenames, summary.json expectations (including openspec_change), and write scope are in CONTRACT.md.

Skill initialization (before first closeout)

Run this once per target repo after the skill files are present under .agents/skills/task-closeout/ (for example after copying only that skill folder or after an npx/package install drops it there). Idempotent: safe to repeat.

  1. Resolve the repo root (the directory that contains .git/ in normal layouts).
  2. Ensure .agents/sessions/ exists.
  3. If .agents/sessions/README.md is missing, create it from bootstrap/sessions/README.md in this skill folder.
  4. Ensure .agents/.gitignore exists. If it is missing, create it with exactly:

    sessions/*
    !sessions/README.md

    If .agents/.gitignore already exists, merge these two lines if they are absent; do not remove unrelated ignore rules.

  5. If the repo does not track .agents/.gitignore and the user relies on the repo root .gitignore, ensure equivalent patterns exist there: .agents/sessions/* and !.agents/sessions/README.md.

Do not create durable knowledge files (AGENTS.md, docs/, playbooks/) as part of this skill; those are owned by learning-distill initialization or a full kit merge.

Output location

Write inside the repo to .agents/sessions/<session-folder>/.

The session folder name is a sortable storage label. The canonical task/session identifier is the task_id field inside the bundle's summary.json.

Required outputs

  • summary.json
  • active-task.md
  • learning-candidate.md
  • changed-files.txt
  • validation.txt

Example bundle

Filled-in reference files live under .agents/skills/task-closeout/example/task-bundle/ when this skill is installed under .agents/skills/task-closeout/.

Rules

  • Record only observable facts in active-task.md.
  • Record only candidate lessons in learning-candidate.md.
  • Distinguish clearly between what failed, what worked, and what is only a hypothesis.
  • Do not update .agents/AGENTS.md or any other durable repo knowledge file.
  • Record the associated OpenSpec change, if any, in summary.json under openspec_change (the change name from openspec/changes/<name>/). Omit the field when the session touched no OpenSpec change.
  • Never modify anything under openspec/ during closeout of an in-flight change; spec updates happen at /opsx:archive time, not closeout time.
  • Do not edit files under .agents/skills/ during closeout. Capture proposed skill or MAINTENANCE.md edits as text in the bundle; learning-distill applies kit-wide skill changes.
  • Treat the whole maintainer conversation as in-scope for active-task.md and learning-candidate.md unless the user explicitly limits closeout to one subtask (mistakes, reversals, and corrections—not only the last git diff).
  • Do not write narrative summaries longer than necessary.
  • Prefer concise bullet lists.

Procedure

  1. Determine or create repo_id.
  2. Determine or create task_id.
  3. Create a session folder using the pattern YYYYMMDD-HHMMSS-short-topic.
  4. Keep one task-closeout bundle per session folder.
  5. Collect changed files.
  6. Collect commands run and validation results.
  7. Re-read the full session (or transcript) before drafting bundle prose so notes and lessons are not scoped to the final edit only.
  8. Write active-task.md.
  9. Write learning-candidate.md.
  10. Write summary.json with status, metadata, repo_id, task_id, openspec_change (when applicable), and optional agent identifiers when available.
  11. Mark the session bundle ready for distillation.

Optional agent metadata

Record agent provenance whenever the active tool can supply it. Record session provenance whenever the active tool can supply a stable session identifier.

  • In summary.json, add agent when the active agent/tool identity is known.
  • In summary.json, add agent_session_id when the active agent/tool exposes a stable session ID.
  • In active-task.md, add an Agent section when the agent/tool identity is known.
  • In active-task.md, add an Agent Session ID section when the active agent/tool exposes a stable session ID.
  • Treat agent and agent_session_id independently: record either one when available; omit only the specific field/section that is unavailable.
  • Do not invent session IDs or require manual lookup outside the agent/tool's supported session history.

Session folder naming

  • Use a deterministic, sortable folder name such as YYYYMMDD-HHMMSS-short-topic.
  • Keep the slug short, lowercase, and tied to the task goal.
  • Reuse the same session folder only for the single task-closeout bundle it was created for.
  • Do not treat the folder name as the canonical task identity; use the task_id field in summary.json.

active-task.md sections

  • Task ID
  • Agent (optional)
  • Agent Session ID (optional)
  • Goal
  • Outcome
  • Files Changed
  • Commands Run
  • Validation
  • Remaining Work
  • Notes

learning-candidate.md sections

  • Task
  • What failed
  • What worked
  • Reusable pattern
  • Candidate AGENTS update
  • Candidate troubleshooting note
  • Candidate repo decision
  • Candidate playbook
  • Spec updates deferred to archive time (change name + what to fold in)
  • Confidence

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.