Skip to content

Support Codex /goal long-running task mode #891

@ghost

Description

Problem

Codex now supports long-horizon / goal-style workflows where the agent can keep working toward a defined objective instead of stopping after a single response. This is useful for complex coding tasks such as refactoring, multi-file feature implementation, migration, test fixing, and iterative debugging.

However, DeepSeek-TUI currently appears to be optimized for normal single-turn or interactive chat workflows. It does not provide a first-class way to run, monitor, pause, resume, or clear a persistent long-running goal similar to Codex's /goal mode.

Proposed solution

Add support for a Codex-style Goal / Long Task mode in DeepSeek-TUI.

Suggested behavior:

  1. Add a command such as /goal or /longtask.
  2. Allow the user to define:
    • the final goal
    • acceptance criteria
    • maximum iterations or token budget
    • stop conditions
    • test / verification command
  3. Let the agent automatically loop through:
    • plan
    • act
    • run checks
    • review result
    • continue or stop
  4. Show task progress in the TUI:
    • current step
    • current plan
    • files changed
    • test results
    • iteration count
    • token / cost estimate if available
  5. Support lifecycle controls:
    • pause
    • resume
    • cancel
    • clear goal
  6. Persist the goal state so the user can continue the task after restarting the TUI.

Example command:

/goal Refactor the authentication module to use the new session API.
Acceptance criteria:
- All existing tests pass.
- Add or update tests for the new session flow.
- Do not change public API behavior unless necessary.
- Stop after 10 iterations or if the same error happens 3 times.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    Status
    In progress

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions