Skip to content

agents: add conversation-done skill - #4150

Merged
rickeylev merged 2 commits into
bazel-contrib:mainfrom
rickeylev:create_agent_cleanup_skill
Sep 4, 2026
Merged

agents: add conversation-done skill#4150
rickeylev merged 2 commits into
bazel-contrib:mainfrom
rickeylev:create_agent_cleanup_skill

Conversation

@rickeylev

Copy link
Copy Markdown
Collaborator

Agent workflows create substantial disk and process overhead outside
the conversation directory, including Bazel server processes, output
bases, git worktrees, and feature branches. Without automated cleanup,
these resources accumulate across tasks.

Add the conversation-done skill and an async cleanup engine to safely
reclaim these resources when a conversation finishes. The tool shuts
down active Bazel servers, deletes matching output bases, and prunes
git worktrees and branches while enforcing safeguards for main repos,
canonical branches, and upstream remotes.

Provide an agent skill and async script to clean up external workspace
resources (Bazel output bases, Git worktrees, and local/remote branches)
when an agent conversation concludes.

Add the `conversation-done` skill with an async Python engine that shuts
down Bazel servers, removes output bases, prunes Git worktrees, and
removes feature branches while protecting canonical repos and releases.
Adhere to the project Python typing convention requiring modern
union syntax over typing.Optional.

Add from __future__ import annotations to cleanup.py and replace all
typing.Optional usages with X | None.
@rickeylev
rickeylev marked this pull request as ready for review September 4, 2026 07:41
@rickeylev
rickeylev requested a review from aignas as a code owner September 4, 2026 07:41
@rickeylev
rickeylev merged commit cf6ec45 into bazel-contrib:main Sep 4, 2026
3 of 5 checks passed
@rickeylev
rickeylev deleted the create_agent_cleanup_skill branch September 4, 2026 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant