Skip to content

v0.3: Implement flg context --mode resume #2

Description

@dlxeva

Owner decision

The next core command should be flg context --mode resume.

This is the smallest build that turns FlowGrid from a handoff workflow into a project-state context engine.

Product goal

Create a bounded agent startup context for long-running rationale-heavy projects.

Agents should not load raw history by default. They should load reviewed project state, active pending state, and next actions.

Proposed command

flg context --mode resume --budget 4000

Default inputs

Read in this priority order:

  1. SNAPSHOT.md
  2. recent reviewed decisions from DECISIONS.md
  3. recent entries from PROGRESS.md
  4. next_actions from .flg/state.json
  5. active pending patches from .flg/patches/
  6. evidence references when available

Raw sessions under .flg/sessions/ should not enter the startup context by default.

Output

Write:

.flg/context/startup.md

Also print a short terminal summary:

  • context file path
  • estimated size
  • sources included
  • pending patches count
  • warning if no reviewed decisions exist

Rules

  • confirmed state outranks pending state
  • reviewed decisions outrank unreviewed suggestions
  • current project state outranks old history
  • raw sessions are retrieved only on explicit request
  • deterministic first version; no vector search or generic compression

Acceptance criteria

  • command registered in src/flg/cli.py
  • creates .flg/context/startup.md
  • works in a freshly initialized FLG project
  • works when no decisions exist
  • includes active pending patch summary
  • smoke test covers command

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions