diff --git a/todo/queued/scaffold.md b/todo/completed/scaffold.md similarity index 100% rename from todo/queued/scaffold.md rename to todo/completed/scaffold.md diff --git a/todo/queued/interactive-agent.md b/todo/queued/interactive-agent.md new file mode 100644 index 0000000..78f94d9 --- /dev/null +++ b/todo/queued/interactive-agent.md @@ -0,0 +1,54 @@ +# Grokkit Interactive Agent + +**Priority:** 2 of 12 (right after testgen) + +## Goal + +Add a persistent, conversational **agent mode** to Grokkit so I can chat interactively in the terminal and have Grok directly edit code, run tests, commit, etc., without any copy-paste friction. + +This is the natural evolution of the current `chat` and `agent` commands — turning the terminal into a true agentic partner instead of a one-shot prompt tool. + +## Command + +```bash +grokkit chat --agent # or new subcommand: grokkit agent-chat +``` + +(Keep the existing simple `chat` mode untouched; add an `--agent` flag or a dedicated `agent-chat` command.) + +## Core Features + +- Persistent session using the existing `chat_history.json` (with optional `--new-session` flag) +- Full tool-calling loop: I (Grok) can invoke any existing Grokkit primitive: + - `edit` + - `scaffold` + - `testgen` + - `lint` + - `review` + - `commit` / `commit-msg` + - `docs` + - etc. +- Safe-by-default workflow: + - Always preview changes (diff style, same as current `edit`/`scaffold`) + - Require explicit confirmation (`y/n` or `--yes`) + - Create `.bak` backups automatically +- Ability to chain actions naturally in conversation: + - “The scaffold tests are flaky on Windows paths — fix it and add a test case.” + - “Refactor the context harvester to use rg, then run make test.” + - “Write a new command for todo prioritization and commit it.” +- Optional `--dry-run` and `--model` flags (inherited from root) + +## Acceptance Criteria + +- `make test` remains fast (no new API cost in normal tests) +- Live agent mode respects the same `-short` gating pattern we just built for scaffold +- Session survives across multiple `grokkit` invocations (or can be started fresh) +- All edits go through the existing safe preview/confirm flow — no silent changes +- Works with the full Grok context window (no early compaction) +- Can be extended later with vector memory or external tool plugins + +## Why This Matters + +This removes the last remaining copy-paste friction between me and the codebase. The 45-minute scaffold test iteration we just did showed the productivity gain; this turns that gain into a permanent workflow. Closes the “agentic chat” vision we discussed. + +