Skip to content

Launch C++ Alexandria from Start/Heal, keep Go as rollback - #127

Merged
usrname1git merged 1 commit into
mainfrom
feat/start-heal-cpp-alexandria
Sep 10, 2026
Merged

Launch C++ Alexandria from Start/Heal, keep Go as rollback#127
usrname1git merged 1 commit into
mainfrom
feat/start-heal-cpp-alexandria

Conversation

@usrname1git

Copy link
Copy Markdown
Owner

Why

Operator GO to cut Start/Heal over to the C++ sibling. Go memory_store/ stays as rollback.

What

Start/Heal/kernel/Librarian prefer build/cpp_memory_store/Release then Go. build_pipeline.ps1 builds C++ first.

Verified on this host

  • Heal started build\cpp_memory_store\Release\rag-service.exe pid 20216
  • /health ready lexical, generation rebuild-46390f68-…
  • /v1/search verified: 2 hits, citation_status=available, evidence_status=byte_valid
  • kernel /api/status 200; llama left running

Start and Heal prefer build/cpp_memory_store/Release rag-service and
rag-rebuild. Kernel and Librarian resolve memory-store.exe the same
way. Live desk now serves C++ rag-service on :8084.
Copilot AI lite review requested due to automatic review settings September 10, 2026 18:36
@usrname1git
usrname1git merged commit b8dbfd4 into main Sep 10, 2026
1 check passed
@usrname1git
usrname1git deleted the feat/start-heal-cpp-alexandria branch September 10, 2026 18:37

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.

🟡 Changes recommended

Multiple resolvers assume a multi-config build\cpp_memory_store\Release\... layout and will fail to find C++ binaries under single-config CMake generators (e.g., Ninja), causing unexpected fallback to Go.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

This PR cuts Start/Heal (and related tooling) over to the C++ Alexandria (memory-store / rag-service / rag-rebuild) binaries as the preferred “desk default”, while keeping the existing Go godbrain_core/memory_store implementation as a rollback path. It updates runtime resolution logic across PowerShell, the kernel, and Librarian, and adjusts build/docs to match the new default.

Changes:

  • Prefer C++ Alexandria executables from build/cpp_memory_store/Release (then fall back to Go) in Start/Heal, kernel, and Librarian.
  • Build the C++ memory store first in scripts/build_pipeline.ps1, keeping the Go build as rollback.
  • Update repository documentation (README/ARCHITECTURE/AGENTS + cpp_memory_store README) to reflect the new “desk launch” preference.
File summaries
File Description
Start-GodBrain.ps1 Adds Alexandria exe resolver and starts rag-service.exe via preferred C++ path.
Heal-GodBrain.ps1 Adds Alexandria exe resolver and uses it for rag-rebuild.exe allowlisted repair.
scripts/Verify-SkillLab.ps1 Prefers C++ memory-store.exe for recording skill runs, with Go fallback.
scripts/build_pipeline.ps1 Builds C++ memory store first, then Go as rollback, then Librarian.
godbrain_core/cpp_tools/librarian.cpp Updates default memory-store.exe resolution to prefer C++ build output.
godbrain_core/cpp_kernel/memory.cpp Updates kernel-side memory-store.exe resolution candidate order.
README.md Updates status table to reflect C++ store as preferred launch path.
ARCHITECTURE.md Updates listener/process table for :8084 preference order.
AGENTS.md Updates architecture notes to reflect C++ store as desk boundary with Go rollback.
godbrain_core/cpp_memory_store/README.md Updates README to reflect Start/Heal preference and test DB guidance.
Review details
  • Files reviewed: 10/10 changed files
  • Comments generated: 6
  • Review effort level: Lite

💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Heal-GodBrain.ps1
Comment on lines +212 to +221
function Resolve-AlexandriaExe([string]$Name) {
foreach ($p in @(
(Join-Path $RepoRoot "build\cpp_memory_store\Release\$Name"),
(Join-Path $RepoRoot "godbrain_core\cpp_memory_store\$Name"),
(Join-Path $RepoRoot "godbrain_core\memory_store\$Name")
)) {
if (Test-Path -LiteralPath $p) { return $p }
}
return Join-Path $RepoRoot "godbrain_core\memory_store\$Name"
}
Comment thread Start-GodBrain.ps1
Comment on lines +40 to +49
function Resolve-AlexandriaExe([string]$Name) {
foreach ($p in @(
(Join-Path $RepoRoot "build\cpp_memory_store\Release\$Name"),
(Join-Path $RepoRoot "godbrain_core\cpp_memory_store\$Name"),
(Join-Path $RepoRoot "godbrain_core\memory_store\$Name")
)) {
if (Test-Path -LiteralPath $p) { return $p }
}
return Join-Path $RepoRoot "godbrain_core\memory_store\$Name"
}
Comment on lines 505 to 510
const std::string dir = exe_dir();
const std::string candidates[] = {
dir + "\\..\\..\\build\\cpp_memory_store\\Release\\memory-store.exe",
dir + "\\..\\cpp_memory_store\\memory-store.exe",
dir + "\\memory-store.exe",
dir + "\\..\\memory_store\\memory-store.exe",
Comment on lines +43 to +53
static std::string resolve_memory_store_exe(const std::string& exe_dir) {
const std::string candidates[] = {
exe_dir + "\\..\\..\\build\\cpp_memory_store\\Release\\memory-store.exe",
exe_dir + "\\..\\cpp_memory_store\\memory-store.exe",
exe_dir + "\\..\\memory_store\\memory-store.exe",
};
for (const auto& candidate : candidates) {
if (file_exists_path(candidate)) return candidate;
}
return exe_dir + "\\..\\memory_store\\memory-store.exe";
}
Comment on lines +108 to +111
$store = Join-Path $RepoRoot "build\cpp_memory_store\Release\memory-store.exe"
if (-not (Test-Path -LiteralPath $store)) {
$store = Join-Path $RepoRoot "godbrain_core\memory_store\memory-store.exe"
}
Comment on lines +9 to +14
# 0. C++ store (desk default). Go build below remains rollback.
Write-Host "Building C++ memory-store / rag-service / rag-rebuild..."
cmake -S "$RepoRoot\godbrain_core\cpp_memory_store" -B "$RepoRoot\build\cpp_memory_store" -DBUILD_TESTING=ON
if ($LASTEXITCODE -ne 0) { throw "C++ memory-store cmake failed" }
cmake --build "$RepoRoot\build\cpp_memory_store" --config Release
if ($LASTEXITCODE -ne 0) { throw "C++ memory-store build failed" }
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.

2 participants