Skip to content

feat(memory): wire recall into vf plan#504

Closed
magicpro97 wants to merge 1 commit into
mainfrom
feat/memory-plan-wire
Closed

feat(memory): wire recall into vf plan#504
magicpro97 wants to merge 1 commit into
mainfrom
feat/memory-plan-wire

Conversation

@magicpro97

Copy link
Copy Markdown
Owner

Closes #489

Closes #489

Signed-off-by: magicpro97 <magicpro97@users.noreply.github.com>
Copilot AI review requested due to automatic review settings July 2, 2026 10:57

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR closes #489 by wiring the memory recall system into vf plan so relevant past decisions can be included alongside the brief’s §2 non‑negotiables in the generated planning prompt.

Changes:

  • Extend buildPlanPrompt() to accept an optional memoryBlock and append it beside §2 Non‑negotiables.
  • In plan(), read repo settings, resolve the configured memory provider, recall top hits for the artifact, and render them into the prompt.
  • Add unit tests for buildPlanPrompt() memory block inclusion/exclusion and re-export buildPlanPrompt for test access.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
src/commands/plan.ts Adds optional memory block support in buildPlanPrompt and wires settings-driven memory recall into plan().
src/commands.ts Re-exports buildPlanPrompt so tests (and other callers) can import it.
test/commands-plan.test.ts Adds direct tests validating buildPlanPrompt includes/omits the memory block.

Comment thread src/commands/plan.ts
Comment on lines +167 to +170
const base = cwd();
const settings = readSettings(base);
const memProvider = resolveMemoryProvider(settings.memory, base);
const memBlock = memProvider ? renderMemoryBlock(memProvider.recall(artifact, { limit: 3 })) : "";
Comment thread src/commands/plan.ts
Comment on lines +167 to +171
const base = cwd();
const settings = readSettings(base);
const memProvider = resolveMemoryProvider(settings.memory, base);
const memBlock = memProvider ? renderMemoryBlock(memProvider.recall(artifact, { limit: 3 })) : "";
const prompt = buildPlanPrompt(artifact, briefRaw, memBlock);
@magicpro97 magicpro97 enabled auto-merge (squash) July 2, 2026 11:00
@magicpro97

Copy link
Copy Markdown
Owner Author

Superseded by #506 which also fixes ctxDir bug + bun:sqlite bundle leak.

@magicpro97 magicpro97 closed this Jul 2, 2026
auto-merge was automatically disabled July 2, 2026 11:05

Pull request was closed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(memory): wire recall into vf plan — past decisions beside §2

2 participants