Keeping coding-agent work coherent across sessions
A coding agent can leave behind a convincing summary while the actual work is still waiting on review. I built Personal Worklog to keep task state, ownership and the next action explicit when work continues across sessions.
This is my personal infrastructure. It is not a battle-tested team product, and I have not established a measured productivity gain from it.
The problem
Agent sessions end, restart and lose context. A new session needs to know which task it owns, which repository and pull request are relevant, and whether the next move belongs to an agent or a person. Recovering that from a long narrative is easy to get wrong.
I designed and implemented a CLI with a hosted application and Postgres-backed state. The tool keeps a timeline of findings and decisions, but active tasks have their own structured state and ordered work items. A written account of what happened cannot silently substitute for an unfinished task.
Make ownership explicit
Tasks use session claims with expiry and heartbeat renewal. Creating a task claims it for that session. Commands that change a task require the current session to hold the active claim, and an active claim cannot be taken over through the ordinary force option.
These are advisory leases for cooperating agents. They govern mutations through Worklog; they do not lock a repository or prevent an agent from editing a file outside the tool. Keeping that limit visible matters when deciding what coordination guarantees the system actually provides.
A stale claim can be reclaimed, with guidance to read the recent task context before editing. That context includes the open items, linked references, wait state and recent audit events. The handoff command produces a compact version for the next session.
Represent who needs to act next
Waiting for CI is different from waiting for a human decision. Worklog records the reason and derives the next actor rather than asking an agent to infer ownership from prose.
A human wait requires an open linked human todo. Review and QA waits require a pull request reference and an explicit indication that the handoff was sent or was unnecessary. These checks make it harder to park a task without leaving an actionable path forward.
Closing a task also has a constraint: open items must be completed or cancelled, unless an explicit override records a reason. Historical findings can still be attached to closed work, while newly discovered actions belong in a follow-up task.
Keep recall separate from task truth
Semantic search helps retrieve previous findings. Structured task records remain the source for current ownership and work state. Search can help a session understand a decision without being asked to determine whether a task is done.
I also separated private working notes from material intended for reports or public artifacts. Audience flags make the intended use explicit. They still require care at the point of publication; a useful internal note is not automatically suitable public copy.
What I would validate before broader use
The important checks are behavioral: two sessions attempting to claim the same task, a session disappearing before releasing it, a human wait without an actionable request, and a closeout with unfinished items. Those cases need to preserve a clear next action and leave an inspectable history.
The implementation gives me explicit commands for resuming, handing off and closing work. Broader adoption would need evidence about concurrent use, recovery behavior and the cost of maintaining task state. A coordination tool earns its place only if it saves more reconstruction than it asks people and agents to record.