Skip to content

Borrow selected task-store patterns from beads_rust #472

@vsumner

Description

@vsumner

Context
PR #468 raised the question of whether beads_rust should replace Spacebot's global task store. I do not think we should adopt it wholesale, but there are a few patterns worth borrowing into the native SQLite-backed store.

Why not adopt it directly

  • beads_rust is a repo-local issue tracker with SQLite + JSONL sync semantics, not an in-process runtime task store for Spacebot.
  • It uses a different storage stack and operational model than the current sqlx-based Spacebot code.
  • Pulling it in directly would add integration cost and model mismatch without solving the core Spacebot-specific workflow concerns.

Borrow candidates

  • Add an explicit task audit/event log.
    This would give us durable lifecycle history for create/update/approve/execute/reassign/complete transitions, instead of overloading SSE as the only narrative of task changes.

  • Add atomic claim semantics for ready-task pickup.
    The store should provide a compare-and-set style claim path so two contenders cannot both observe the same ready task and race on assignment/execution.

  • Consider dependency-aware ready logic.
    beads_rust has a clearer model for blocked vs ready work. If Spacebot tasks are going to become a real execution board, we should decide whether task dependencies and blocked-state derivation belong in the task store.

  • Tighten schema invariants and access-path indexes around active work.
    In particular: active-task filters, ready-task ordering, assignment lookups, and ownership/assignee constraints should be treated as first-class query paths rather than incidental fields.

  • Consider whether task history should be queryable independently from the current row state.
    This is the main structural benefit of an event log even if we keep the primary model as a current-state table.

Non-goals

  • Do not add JSONL sync/export.
  • Do not replace sqlx with the beads_rust storage stack.
  • Do not turn the task store into a generic external issue tracker.

Suggested next step

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions