| name | ba |
| description | Task tracker for LLM sessions. Use "$ba ready" to see available work, "$ba claim <id>" to take ownership, "$ba finish <id>" when done. |
ba - Task Tracking for LLM Sessions
Simple ownership-based task tracking for multi-agent coordination.
$ba ready
Show issues ready to work on (open + not blocked by dependencies).
Run:
ba ready
Output shows:
- Issue ID, priority (0-4), type, title
- Only open issues with no unfinished blockers
- Sorted by priority
Use this to: Pick your next task from the ready queue.
$ba claim
Take ownership of an issue (moves it to in_progress).
Run:
ba claim <id> --session $SESSION_ID
Example:
ba claim ab-x7k2 --session $SESSION_ID
Important:
- Always use
--session $SESSION_ID to identify yourself
- Claiming changes status:
open โ in_progress
- Claiming a
closed issue reopens it automatically
- Only one agent can own an issue at a time
Use this before: Starting work on any issue.
$ba mine
Show issues you currently own.
Run:
ba mine --session $SESSION_ID
Output shows:
- All issues you've claimed in
in_progress status
- Sorted by priority
Use this to: See what you're currently working on.
$ba finish
Complete an issue (moves it to closed).
Run:
ba finish <id>
Example:
ba finish ab-x7k2
Requirements:
- You must be the current owner (claimed it with your session)
- Changes status:
in_progress โ closed
Use this when: Work is done and tested.
$ba release
Release an issue back to the ready queue (abandon work).
Run:
ba release <id>
Requirements:
- You must be the current owner
- Changes status:
in_progress โ open
Use this when: You can't complete the work or need to switch focus.
$ba show
Show detailed information about an issue.
Run:
ba show <id>
Output shows:
- Full details: status, owner, created_at, updated_at
- Description if present
- Labels and priority
- Comments
- Dependencies (blocks, blocked_by)
Use this to: Understand issue requirements before claiming.
$ba list
List all open issues (excludes closed by default).
Run:
ba list
ba list --all
ba list --status open
ba list --status in_progress
ba list --status closed
Use this to: Browse available work.
$ba create
Create a new issue.
Run:
ba create "Fix auth bug" -t task -p 1
ba create "Add feature" -t epic -d "Detailed description"
Options:
-t, --type - task, epic, refactor, spike (default: task)
-p, --priority - 0 (critical) to 4 (backlog), default: 2
-d, --description - Longer description
-l, --labels - Comma-separated labels
Use this when: You discover new work that needs tracking.
$ba comment
Add a comment to an issue.
Run:
ba comment ab-x7k2 "Found root cause in auth.rs:42" --author $SESSION_ID
Use this to: Document progress, findings, or blockers.
$ba block
Mark an issue as blocked by another.
Run:
ba block ab-x7k2 ab-y8m3
Effect:
ab-x7k2 won't appear in ba ready until ab-y8m3 is closed
- Use
ba tree <id> to visualize dependencies
Use this when: Work has prerequisites.
$ba unblock
Remove a blocking dependency.
Run:
ba unblock ab-x7k2 ab-y8m3
$ba tree
Visualize issue dependencies.
Run:
ba tree ab-x7k2
Output shows:
- Tree structure of issue and its blockers
- Status of each issue
Workflow Example
ba ready
ba show ab-x7k2
ba claim ab-x7k2 --session $SESSION_ID
ba comment ab-x7k2 "Implemented feature, tests passing" --author $SESSION_ID
ba finish ab-x7k2
ba release ab-x7k2
Ownership State Machine
ba uses ownership-based state transitions:
open โโclaimโโ> in_progress โโfinishโโ> closed
(take) (done)
โ
release
โ
โผ
open
(abandon)
Key rule: Every in_progress issue has an owner.
Claiming a closed issue automatically reopens it as in_progress with you as owner.
Issue Types
task - Default, general work item
epic - Container for grouping related issues
refactor - Improving existing code (no new behavior)
spike - Research/investigation (may not produce code)
Priorities
0 - Critical (security, data loss, broken builds)
1 - High (major features, important bugs)
2 - Medium (default - nice-to-have features, minor bugs)
3 - Low (polish, optimization)
4 - Backlog (future ideas)
JSON Output
All commands support --json for programmatic use:
ba --json ready
ba --json show ab-x7k2
ba --json mine --session $SESSION_ID
Storage
Issues stored in .ba/issues.jsonl:
- One issue per line (JSONL format)
- Git-friendly (conflicts are per-issue, not per-field)
- Sorted by ID (stable ordering for conflict resolution)
- Human-readable
- Grep-able:
grep ab-x7k2 .ba/issues.jsonl
Merge Conflicts
When multiple agents modify issues concurrently, git conflicts occur at the line level (one line = one issue).
Resolution strategy:
- Pull latest changes:
git pull
- If conflicts occur, each conflicting issue will show both versions
- Choose the correct version (usually the one with latest
updated_at)
- Validate JSON:
jq empty .ba/issues.jsonl
- Commit the resolution
Prevention: Always pull before starting work. Use ba ready to see current state.
Note: ba does not detect conflicting edits automatically. The line-based format makes conflicts obvious (entire issue on one line) but not automatic to resolve. Consider this when coordinating multiple agents.
Environment and SESSION_ID
Required: SESSION_ID
The $SESSION_ID environment variable must be set for ownership operations (claim, mine, comment with --author).
Verification:
echo ${SESSION_ID:-(not set - operations will fail)}
Claude Code provides this automatically in active sessions. If commands fail with "SESSION_ID not set":
export SESSION_ID=$(uuidgen | tr '[:upper:]' '[:lower:]')
Why required? ba's ownership model prevents multi-agent conflicts by requiring explicit session identification. Without it:
ba claim will fail (cannot establish ownership)
ba mine will fail (cannot identify your issues)
- Multi-agent coordination breaks down
Error Handling
If SESSION_ID is not set, ba commands will fail with:
ERROR: --session is required
This is intentional - ownership without identity doesn't make sense.
Known Limitations
Stale Ownership
If a Claude Code session crashes mid-task, the issue remains in_progress with a stale owner. ba currently has no automatic timeout/reclaim mechanism.
Workaround for the original owner:
ba release <id>
Workaround for a different agent (manual intervention required):
ba show <id>
ba claim <id> --session $SESSION_ID
Important: Manual JSON editing is fragile. Validate syntax after editing:
jq empty .ba/issues.jsonl
Future consideration: Add ba reclaim --force <id> --session $SESSION_ID command to handle this safely.
Quick Reference Card
ba ready # See available work
ba claim <id> --session $SESSION_ID # Take ownership
ba show <id> # Check details
ba mine --session $SESSION_ID # See your work
ba finish <id> # Complete
ba release <id> # Abandon
ba comment <id> "msg" --author $SESSION_ID
ba create "title" -t task -p 1 # New issue
ba list [--all] [--status <status>] # Browse