Documentation
¶
Index ¶
- Constants
- func Now() int64
- type Plan
- type Store
- func (s *Store) Archive(id string) error
- func (s *Store) Create(plan *Plan) error
- func (s *Store) Delete(id string) error
- func (s *Store) Get(id string) (*Plan, error)
- func (s *Store) List(directory string) ([]*Plan, error)
- func (s *Store) ListArchived(directory string) ([]*Plan, error)
- func (s *Store) Lock(id string) error
- func (s *Store) Update(plan *Plan) error
Constants ¶
View Source
const ( StatusOpen = "open" StatusLocked = "locked" )
Plan statuses
View Source
const ( BreakdownNone = "" BreakdownInProgress = "in_progress" BreakdownCompleted = "completed" BreakdownFailed = "failed" )
Breakdown statuses
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Plan ¶
type Plan struct {
ID string `json:"id"`
SessionID string `json:"sessionId"`
ProjectID string `json:"projectId"`
Directory string `json:"directory"`
Title string `json:"title"`
Status string `json:"status"` // "open" | "locked"
Model string `json:"model,omitempty"`
CompactionSummary string `json:"compactionSummary,omitempty"`
BreakdownStatus string `json:"breakdownStatus,omitempty"` // "" | "in_progress" | "completed" | "failed"
BreakdownWarnings string `json:"breakdownWarnings,omitempty"` // non-empty when some tasks failed to create
AllTasksCompleted bool `json:"allTasksCompleted,omitempty"` // true when locked and all tasks done
Archived bool `json:"archived,omitempty"` // true when ArchivedAt > 0
CreatedAt int64 `json:"createdAt"`
UpdatedAt int64 `json:"updatedAt"`
ArchivedAt int64 `json:"archivedAt,omitempty"`
}
Plan represents a planning session — a collaborative conversation between the user and the PlanAgent. Once locked, no further messages can be added. The plan serves as the reference point for all derived tasks.
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store provides persistence operations for Plan entities.
func (*Store) Archive ¶ added in v0.2.5
Archive marks a plan as archived by setting archived_at and time_updated to the current timestamp.
func (*Store) List ¶
List returns all plans for a given directory, ordered by most recently updated.
func (*Store) ListArchived ¶ added in v0.2.5
ListArchived returns all archived plans for a given directory (status = locked AND archived_at > 0).
Click to show internal directories.
Click to hide internal directories.