Skip to content

Solution for long term memory for agent coding CLIs and to facilitate handoff between different agent vendors

Rust

feat(auto-improve): wire configured patchable_page_prefixes into the MCP admin path

AkitaOnRailsac96490c36c4
diff --git a/crates/ai-memory-mcp/src/admin.rs b/crates/ai-memory-mcp/src/admin.rs
index fa2f6a7a..533f9e1c 100644
--- a/crates/ai-memory-mcp/src/admin.rs
+++ b/crates/ai-memory-mcp/src/admin.rs
@@ -2017,13 +2017,14 @@ async fn handle_auto_improve(
proposal_actor: req.proposal_actor.clone(),
pending_path: req.pending_path.clone(),
max_patchable_pages: req.max_patchable_pages,
- // The admin surface does not expose this yet; the reviewer keeps the
- // configured default rather than silently reading no page bodies (#834).
- patchable_page_prefixes:
- ai_memory_consolidate::DEFAULT_AUTO_IMPROVE_PATCHABLE_PAGE_PREFIXES
- .iter()
- .map(|p| (*p).to_string())
- .collect(),
+ // The admin request body does not expose this, so the reviewer uses the
+ // server-configured `[auto_improve] patchable_page_prefixes` (which
+ // itself defaults to the historical `_rules/`/`procedures/`) rather than
+ // ignoring the operator's config on the admin-triggered path (#834).
+ patchable_page_prefixes: state
+ .auto_improve_review_config
+ .patchable_page_prefixes
+ .clone(),
max_patchable_body_chars: req.max_patchable_body_chars,
max_edits_per_proposal: req.max_edits_per_proposal,
max_edit_content_chars: req.max_edit_content_chars,