aboutsummaryrefslogtreecommitdiff
path: root/.ai/workflows/wrap-it-up.org
Commit message (Collapse)AuthorAgeFilesLines
* docs(ai): require an epoch on the tail of helper-agent idsCraig Jennings6 days1-1/+1
| | | | | | A helper agent's session-context file is .ai/session-context.d/<id>.org. A bare, reused id like "codex" makes the next run resolve to the previous run's leftover anchor, which it then mistakes for a crash to recover or clobbers. That bit on 2026-06-13: a codex run left codex.org for the next session to clean up. The fix is a convention, not a resolver change. The spawner appends an epoch on the tail (host.project.runtime.<epoch>) so each run gets a fresh anchor. The epoch can't be minted inside session-context-path, since that resolver runs many times per session and must return the same path each call. I documented it in protocols.org, the wrap-up recommended-shape note, and the resolver header.
* feat(workflows): add inbox-zero for routing the roam inbox by projectCraig Jennings7 days1-0/+10
| | | | | | | | The global roam inbox (~/org/roam/inbox.org) is one shared capture file every project can see, and nothing routed its items to the project that owns them. inbox-zero claims the items prefixed for the current project, files them into that project's todo.org per the process-inbox discipline, and removes them from the shared inbox. Foreign-prefixed and unowned items stay. Every scan reports the total item count plus how many appear related to this project. This v1 is single-destination: it routes by explicit <project>: prefix only. The domain-aware mode that would guess every item's owner and empty the whole inbox in one run is deferred until the multi-project need is concrete. Wired into both session ends so each project touches the inbox twice a session: startup surfaces a read-only count and offer, wrap-up Step 3 sweeps the claimed set before the cleanup scripts so imported tasks ride the wrap commit. INDEX carries the trigger phrases.
* feat(workflows): wrap-up promotes to the KB and records the usage receiptCraig Jennings10 days1-0/+13
| | | | Phase 3 of the agent KB spec. Step 1 of wrap-it-up gains a promotion check against knowledge-base.md's inclusion criteria, and every Summary now ends with a "KB: promoted N / consulted yes-no" line — the single grep-able input to the spec's 30-day success-metrics checkpoint. The validation checklist enforces the line.
* fix(workflows): commit template-sync churn deterministicallyCraig Jennings2026-05-311-0/+41
| | | | | | | | Phase A's startup rsync copies template updates from rulesets into each project's .ai/, but nothing committed that churn, so it accumulated across sessions and eventually blocked Phase A.0's auto-fast-forward (git won't ff a dirty tree). Two projects hit it the same day. I added a Step 4.0 to wrap-it-up.org that commits the churn as its own chore commit before the session-work commit, guarded so it only auto-commits synced .ai paths matching rulesets canonical byte-for-byte and surfaces anything that doesn't. startup.org Phase C now surfaces leftover churn at session start as the crashed-session safety net. Both skip the rulesets repo, where .ai/ is a committed mirror. I also moved four misplaced PROPERTIES drawers in todo.org (DONE tasks) from after the resolution prose to immediately under the CLOSED line, so org parses them as real drawers.
* feat(session-context): resolve the active path per AI_AGENT_IDCraig Jennings2026-05-301-2/+8
| | | | | | A single .ai/session-context.org races when two agents share a project: each agent's writes clobber the other's session log. I added .ai/scripts/session-context-path, which resolves the active path from AI_AGENT_ID: unset gives the legacy .ai/session-context.org singleton (so every existing one-agent session is unchanged), set gives .ai/session-context.d/<id>.org with the id sanitized to filename-safe characters. This is Codex's Phase 1 slice from the runtime-neutral spec: the race fix on its own, no broader refactor. startup.org's existence check and wrap-it-up.org's rename now resolve through the helper, each with a singleton fallback so older checkouts that haven't synced the script still work. Wrap folds the agent id into the archive name so two agents wrapping in the same minute don't collide. protocols.org documents the rule. Verified with 5 bats cases and a two-agent simulation showing distinct paths per id.
* fix(wrap-it-up): inbox sanity check exempts lint-followups.orgCraig Jennings2026-05-291-4/+11
| | | | | | | | | | | | | | | | The inbox sanity check I added in 8424e8f counted lint-followups.org as unprocessed, which surfaced as a false alarm during this session's wrap-up. lint-org writes its judgment items into inbox/lint-followups.org earlier in the same wrap-up workflow by design. The file is a pipeline artifact for the next morning's daily-prep, not a handoff that needs the value gate. The find filter now excludes .gitkeep, lint-followups.org, and PROCESSED-* prefixes. The Validation Checklist line names the same expected-artifacts list explicitly. Smoke test: post-fix count is 0 in the rulesets project (where lint-org just wrote 5 judgment items into inbox/lint-followups.org).
* docs(wrap-it-up): add inbox sanity check + checklist lineCraig Jennings2026-05-291-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | Wrap-up never knew about the inbox. After process-inbox.org landed today as the formal workflow for handoff intake, wrap-it-up.org needs to surface inbox/ when it's non-empty so the wrap doesn't silently defer handoffs to next session. This commit adds a new Inbox sanity check sub-step under Step 3 (project hygiene). The check runs find inbox -maxdepth 1 -type f filtered to skip .gitkeep and PROCESSED-* prefixes. A non-zero count surfaces with the file list and a recommendation to run process-inbox.org or explicitly defer each item. A zero count or no inbox/ directory makes the check a silent no-op. It also adds one line to the Validation Checklist: inbox is empty (excluding .gitkeep and PROCESSED-* prefixes), OR each remaining item has an explicit deferral logged in the valediction. This is the only integration gap surfaced today. The other gaps considered (LAST_INBOX_PROCESS marker stamp, sync-check, make status) didn't justify wrap-up changes. The marker is process-inbox's own responsibility. sync-check is project-specific to rulesets. make status doesn't generalize across projects.
* docs(workflows): document GitHub-family assumption in wrap-it-up Step 3.5Craig Jennings2026-05-221-1/+5
| | | | | | Step 3.5's Linear ticket-state sweep uses gh to find the merged PR for a Dev-Review ticket, which assumes a GitHub-family host. That holds today because DeepSat, the only Linear-using project, lives on GHE where gh talks to the API. I added a note flagging the assumption rather than rewriting the step to be provider-agnostic. A future Linear project on GitLab, Gitea, or Bitbucket would need a different PR lookup, but none exists yet, so documenting the boundary beats building for a host we don't have.
* docs(workflows): swap wrap-up date-coverage scan for task-review health checkCraig Jennings2026-05-201-23/+10
| | | | | | | | The date-coverage scan flagged every open [#A]/[#B] task with no DEADLINE or SCHEDULED, on the assumption that high-priority work needs a date. That assumption is wrong (research and watch-list tasks are legitimately dateless), so the scan generated dismiss-or-paper-over cleanup at every wrap-up. The replacement watches the daily task-review habit instead. It calls task-review-staleness.sh todo.org 30 and, when the count is non-zero, writes one summary line to the follow-ups file: N top-level tasks unreviewed for >30 days. There's no per-task dump, because the per-task walk is the review habit's job. Staleness, not datelessness, is the signal worth surfacing. The change lands in both the canonical workflow and the project mirror.
* chore(ai): sync lint-org and wrap-it-up from claude-templatesCraig Jennings2026-05-161-8/+24
| | | | | | | | | | Project .ai/ mirror catches up to two canonical updates already in claude-templates/: - lint-org cj-comment block suppression (3fb4c80). The =#+begin_src cj: ...= annotation pattern triggered three lint categories (suspicious-language, empty-header-argument, wrong-header-argument) as false positives at todo.org:16 and todo.org:1291. lint-org.el now recognizes the opener and skips all three on those lines. - LINT_ORG_FOLLOWUPS default flipped to =./inbox/lint-followups.org= (684891d). The previous hardcoded default routed every project's wrap-up findings into the work project's inbox. Phase A startup rsync brought both into the project mirror this morning; bundled into one chore commit since neither delta is project-specific work.
* docs(workflows): generalize wrap-it-up push parentheticalCraig Jennings2026-05-161-1/+1
| | | | | | The Step 4 "Push to all remotes" parenthetical singled out "github.com + cjennings.net mirrors" as the canonical case. Accurate for rulesets and a few other repos, misleading for the rest. Most projects have git.cjennings.net as their sole remote, and DeepSat lives on deepsat.ghe.com. The push loop itself (for r in $(git remote)) is already remote-agnostic; the prose just needed to catch up. New wording covers both the mirror case and the different-audience-per-remote case without naming any specific host.
* docs(workflow): add date-coverage scan to the wrap-up flowCraig Jennings2026-05-141-0/+33
| | | | | | | | | | New sub-step under Step 3 surfaces [#A] and [#B] tasks in todo.org that have neither DEADLINE: nor SCHEDULED: directly under the heading. Candidates land in the same lint-followups.org the next morning's daily-prep merges in, so the operator reviews them at the start of the day instead of discovering the drift later. Why both timestamp shapes matter: DEADLINE is external (RFP cutoffs, partner-announced dates, regulatory). SCHEDULED is social (a commitment to surface to the team). The asymmetry drives the promotion rule — DEADLINE inside 7 days auto-promotes to [#A], SCHEDULED passing surfaces for re-eval without auto-promoting. High-priority work carrying neither is suspicious; the scan flags it, the operator decides whether to add a date, drop the priority, or confirm no-date-by-intent. Inline awk does the scan (no new script). Output appends to the follow-ups file under a dated heading; if no candidates, no append. Conservative: surfaces every candidate, expects false positives to be cheap dismissals. Counterpart to the DEADLINE-vs-SCHEDULED practice section just added to todo.org's '* Work Priority' header on the work side.
* chore(ai): sync lint-org script and wrap-it-up from claude-templatesCraig Jennings2026-05-141-0/+33
| | | | | | | Byte-identical pull of .ai/scripts/lint-org.el, .ai/scripts/tests/test-lint-org.el, and the new Step 3 lint section in .ai/workflows/wrap-it-up.org. Upstream: claude-templates 138f35f (feat) and 4eba98c (docs).
* feat(todo-cleanup): add --sync-child-priority mode for drifted childrenCraig Jennings2026-05-141-1/+25
| | | | | | | | | | When a parent task in todo.org gets reprioritized, its children frequently keep their original (lower) priority cookies, which then mismatches the parent's new importance. The new mode walks every heading with a priority cookie and bumps any direct child whose own cookie is lower (D ranks below A in org's default scheme). Down-only: parents are never bumped up to a child's priority. Priority-less parents and priority-less children are both left alone — sync does not invent priorities. Children opt out by carrying the :no-sync: literal tag, useful for Follow-up:/Spike: sub-tasks that are deliberately deprioritized. The tag match is literal regex against the heading line rather than going through org-get-tags, because org's default tag character class excludes hyphens — :no-sync: would not be parsed as a real tag in batch mode without a custom org-tag-re. org-map-entries visits headings in document order, so a multi-level chain [#A] → [#B] → [#D] collapses to the top priority in one pass: the middle bumps to [#A] before the walk reaches the leaf. wrap-it-up.org Step 3 now invokes --sync-child-priority after --archive-done. --check-child-priority is the report-only alias (--sync-child-priority --check) for previewing before applying. Default cadence is auto-apply, same as --archive-done.
* chore(ai): sync triage-intake workflow from claude-templatesCraig Jennings2026-05-111-2/+0
| | | | New on-demand triage-intake workflow. It scans every inbox source (the three mail accounts, Slack, Linear, open PRs, both calendars, recent todo.org edits), surfaces what moved, runs the Linear Dev-Review sweep, and marks all unread INBOX mail plus every touched Slack conversation read. Also registered in INDEX.org, and the stale triage-intake reference dropped from wrap-it-up.org.
* docs(workflows): run todo-cleanup --archive-done in wrap-upCraig Jennings2026-05-111-3/+21
| | | | The wrap-up flow already runs the hygiene pass on todo.org; it now also runs --archive-done, which relocates completed level-2 subtrees from "Open Work" to "Resolved". Both passes are idempotent and skip cleanly when the file lacks the named sections, and any moves land in the wrap-up commit's diff for review before push.
* docs(workflows): require every worktree leftover to be resolved at wrapCraig Jennings2026-05-111-4/+35
| | | | Replace the old "intentional carryover" default in wrap-it-up.org. End every session with an empty `git status`: classify each leftover as a runtime artifact, a forgotten change, or pre-existing dirt, apply a concrete resolution unless the user explicitly defers, and log any deferral in the valediction so the next session knows it was a choice, not a miss.
* feat(wrap-it-up): add Linear Dev-Review sweep stepCraig Jennings2026-05-081-2/+23
| | | | Sweep Dev-Review tickets assigned to Craig before the wrap-up commit. Any whose linked PR has merged gets proposed for Done (chores, refactors, test backfills, dead-code removal) or PM Acceptance (real fixes or features users can verify). Tickets stuck in Dev Review after the PR merges hide real in-progress work. The step is idempotent and skips when Linear is not in use.
* chore(skills): remove humanizer (superseded by voice)Craig Jennings2026-05-071-1/+1
| | | | | | | | I deleted humanizer/SKILL.md now that all three callers (commits.md, respond-to-cj-comments.md, start-work.md) invoke /voice instead. The 25 humanizer patterns live on as patterns 1-25 in voice/SKILL.md. Same source (Wikipedia's Signs of AI writing), same prose, same examples — just renumbered alongside the universal good-writing additions and the personal-only patterns. I also updated .ai/notes.org and .ai/workflows/wrap-it-up.org to reference /voice personal instead of the old humanizer + manual-passes flow. The wrap-it-up change landed upstream in claude-templates first so it survives the next startup rsync. todo.org gets the matching update: the voice TODO is marked DONE with a "Built and shipped" timestamp, the publish-mode terminology is renamed to personal-mode throughout, the V1 scope checklist is ticked, the open questions are resolved with the answers we landed on during implementation, and the migration section records the delete-not-alias decision.
* chore(ai): initialize project notes and Claude tooling surfacesCraig Jennings2026-05-061-0/+235
Replace the seed notes.org with project-specific context (layout, install modes, task tracker location, recent inflection point). Bring in the synced template surfaces (protocols, workflows, scripts, references, retrospectives, someday-maybe) as tracked content for this content/documentation project.