diff --git a/Sources/Dev/2026-05-16-vault-integration-test-multi.md b/Sources/Dev/2026-05-16-vault-integration-test-multi.md deleted file mode 100644 index 049fbbb..0000000 --- a/Sources/Dev/2026-05-16-vault-integration-test-multi.md +++ /dev/null @@ -1,130 +0,0 @@ ---- -project: vault-integration-test-multi -type: session-notes -status: active -tags: [test, integration, verification, multi-chunk] -created: 2026-05-16 -updated: 2026-05-16 ---- -# Vault Integration Test 2026-05-16 (multi-chunk) - -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note then index_note then public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce multiple rows -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. This run targets multi-chunk. diff --git a/Sources/Dev/2026-05-16-vault-integration-test.md b/Sources/Dev/2026-05-16-vault-integration-test.md deleted file mode 100644 index 8d43dea..0000000 --- a/Sources/Dev/2026-05-16-vault-integration-test.md +++ /dev/null @@ -1,21 +0,0 @@ ---- -project: vault-integration-test -type: session-notes -status: active -tags: [test, integration, verification] -created: 2026-05-16 -updated: 2026-05-16 ---- -# Vault Integration Test 2026-05-16 - -This is an end-to-end test of the vault indexing pipeline post-chunking-refactor. -We're verifying that the save_note → index_note → public.embeddings path is fully -operational after Travis rebuilt the vault-mcp container with the published -embedding-chunking package from gitea. - -The note should land in wiki.notes with a fresh source_id, and produce one row -in public.embeddings with source_schema='wiki', source_table='notes', and a -non-NULL chunk_text that contains the content above. - -This content is intentionally short — about 80 tokens — to verify the single-chunk -path. A separate test with longer content will exercise multi-chunk. diff --git a/Sources/Dev/index.md b/Sources/Dev/index.md index 73e4d05..0b833ee 100644 --- a/Sources/Dev/index.md +++ b/Sources/Dev/index.md @@ -49,8 +49,6 @@ Project plans and session notes for coding, AI/ML, tooling, and dev environment ## Recent Sessions -- [[Sources/Dev/2026-05-16-vault-integration-test|2026-05-16-vault-integration-test]] — vault indexing pipeline single-chunk verification *(test artifact — see flags)* -- [[Sources/Dev/2026-05-16-vault-integration-test-multi|2026-05-16-vault-integration-test-multi]] — multi-chunk indexing verification *(test artifact — see flags)* - [[Sources/Dev/2026-05-15-agentic-validation-article-review|2026-05-15-agentic-validation-article-review]] — GitHub agentic-validation article; dominator analysis vs zero-check - [[Sources/Dev/2026-05-10-dispatch-replacement-architecture-and-anthropic-billing-reality|2026-05-10-dispatch-replacement-architecture-and-anthropic-billing-reality]] — two-layer dispatch/agent split; subscription-vs-API billing - [[Sources/Dev/ai-memory-architecture-research|ai-memory-architecture-research]] — OB1 architecture; harness vs model layers; pgvector diff --git a/Sources/Homelab/2026-05-17-vault-create-artifact-verification-2026-05-16.md b/Sources/Homelab/2026-05-17-vault-create-artifact-verification-2026-05-16.md deleted file mode 100644 index 2871330..0000000 --- a/Sources/Homelab/2026-05-17-vault-create-artifact-verification-2026-05-16.md +++ /dev/null @@ -1,47 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: postgres-consolidation-reflection-layer -tags: -- mcp -- embeddings -- automation -- pgvector -type: session-notes ---- - -## Outcome - -End-to-end verification of vault MCP create_artifact after the full diagnostic + fix chain: search_path override removed from db.py connection pool (commit 051c3ba), letting the vault_mcp role's default `wiki, public` apply naturally. Goal: confirm the dual-write lands a markdown file in the vault repo AND a row in petalbrain.wiki.artifacts AND chunked rows in petalbrain.public.embeddings. - -## Topics Covered - -The full chain of fixes for this single end-to-end write: -- Renamed mcp_server → vault_mcp package (rename worker) -- Fixed artifacts subsystem imports (rename completion worker) -- Hidden artifact tools (mistake) then re-exposed + hidden save_note shim -- Fixed create_artifact wrapper dispatch (was pointing at save_note_impl) -- Added missing HERBYLAB_DATABASE_URL env var -- Removed search_path = herbylab override in connection pool's configure hook -- Multiple container rebuilds with --no-cache to defeat image caching - -If this artifact lands successfully, six iterations of architectural debugging culminated in a working vault MCP write surface. - -## Key Learnings - -When debugging MCP integration paths, work upward through the stack systematically: -1. MCP transport (auth + tool dispatch) -2. Wrapper layer (param translation + delegation target) -3. Env config (every env var referenced by every code path) -4. Database state (schemas, roles, search_path defaults) -5. Code-level overrides (session-level SET commands, SQLAlchemy connect_args, hardcoded schema names in MetaData) - -Issues at any layer can mask issues at another. The "rebuild fixed it" theory was tempting at each step but only the layer 5 fix actually unblocked the write. - -## Follow-ons - -- [ ] Worker verifies wiki.artifacts row exists for this entry with correct schema -- [ ] Worker verifies public.embeddings has chunked rows with source_schema='wiki', source_table='artifacts' (or 'notes', depending on routing) -- [ ] Worker confirms chunk_text non-NULL and chunk_token_count ≤ 512 -- [ ] If success: vault MCP write surface considered operational end-to-end -- [ ] Address the three out-of-scope items the worker flagged: tests/conftest.py:59 search_path SET, alembic/env.py:41 SCHEMA constant, HERBYLAB_DATABASE_URL env var name \ No newline at end of file diff --git a/Sources/Homelab/2026-05-17-vault-push-final-verification-2026-05-16.md b/Sources/Homelab/2026-05-17-vault-push-final-verification-2026-05-16.md deleted file mode 100644 index c28a216..0000000 --- a/Sources/Homelab/2026-05-17-vault-push-final-verification-2026-05-16.md +++ /dev/null @@ -1,30 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: postgres-consolidation-reflection-layer -tags: -- mcp -- automation -- git -type: session-notes ---- - -## Outcome - -Final-final verification of the vault MCP push path after fixing the git config parser semicolon trap (commit cd3c88f). If this returns pushed: true, the queued b578f458 plus this new commit should both land on origin, closing out the full end-to-end write surface debugging chain that started with the create_artifact body/content error. - -## Topics Covered - -The semicolon trap: git config values treat `;` as comment delimiter unless the entire value is wrapped in double quotes. Inner `"..."` quotes get stripped by the parser as inline quoted segments. So the f-string helper `!f() { echo "username=lovebug"; echo "password=$VAULT_PUSH_TOKEN"; }; f` got stored as `!f() { echo username=lovebug` — unterminated function, no credentials returned, push fails with "could not read Username". - -Fix is one line: rewrite the helper as `!echo username=$VAULT_PUSH_USER && echo password=$VAULT_PUSH_TOKEN`. No semicolons, no inner quotes, `&&` isn't special to git config. - -## Key Learnings - -Git config has its own mini-parser separate from how shells interpret quoting. `;` is a comment delimiter in config values. `"..."` quotes get stripped (their contents kept). Always validate the parsed form, not just the string you wrote. - -## Follow-ons - -- [ ] If pushed: true: vault write surface complete end-to-end -- [ ] If pushed: false: collect the actual git push error from the new container logs -- [ ] Wrap session — major architectural debugging chain closed \ No newline at end of file diff --git a/Sources/Homelab/2026-05-17-vault-push-success-verification-2026-05-16.md b/Sources/Homelab/2026-05-17-vault-push-success-verification-2026-05-16.md deleted file mode 100644 index 0a58d18..0000000 --- a/Sources/Homelab/2026-05-17-vault-push-success-verification-2026-05-16.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: postgres-consolidation-reflection-layer -tags: -- mcp -- automation -- git -type: session-notes ---- - -## Outcome - -Travis confirms push works from his side. Final confirmation from the MCP write path. If this artifact returns `pushed: true`, the vault MCP write surface is complete end-to-end: filesystem + git commit + git push + Postgres dual-write + chunked embeddings + Trello projection-ready. - -## Topics Covered - -The full architectural debugging chain that started with `create_artifact body/content` error and ended with a wrong-token issue covered every layer of the stack: package rename, import paths, MCP tool exposure, wrapper dispatch, env var presence, schema search_path, role default, connection pool configure hook, git credential helper, git config parser semicolon trap, and finally the token itself. - -## Key Learnings - -Layered configuration in MCP deployments compounds. Every layer (code, env, schema, container image, role config, credential helper, token value) needs to be right and recently rebuilt. The cheapest bugs (wrong token value) can hide behind the most architectural-looking symptoms. - -## Follow-ons - -- [ ] Confirm pushed: true closes the vault push initiative -- [ ] All queued artifacts (b578f458, ca2c8e93, f65b61c9, and this one) should be on origin -- [ ] Vault MCP write surface declared operational \ No newline at end of file diff --git a/Sources/Homelab/2026-05-17-vault-push-token-fix-verification-2026-05-16.md b/Sources/Homelab/2026-05-17-vault-push-token-fix-verification-2026-05-16.md deleted file mode 100644 index 5a2cdb2..0000000 --- a/Sources/Homelab/2026-05-17-vault-push-token-fix-verification-2026-05-16.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: postgres-consolidation-reflection-layer -tags: -- mcp -- automation -- git -type: session-notes ---- - -## Outcome - -Retesting after Travis corrected the gitea PAT in `.env`. The previous failures were not a code issue — the helper wiring was correct, gitea was returning "Authentication failed" because the wrong token was in env. If this returns `pushed: true`, the queued commits (`b578f458`, `ca2c8e93`) plus this new one should all land on origin. - -## Topics Covered - -The full debugging chain ended at the cheapest possible bug: wrong env value. All the architectural fixes (HTTPS URL rewrite, credential helper, semicolon trap fix) were correct. The thing that was actually broken was the token itself. - -## Key Learnings - -When a credential helper says "Authentication failed" and the wiring is verifiable, check the credential value FIRST before assuming code issues. `curl -u "user:$TOKEN" https://gitea/api/v1/user` is a 5-second test. - -## Follow-ons - -- [ ] If pushed: true, close out the vault push fix completely -- [ ] Mark the architectural debugging chain done \ No newline at end of file diff --git a/Sources/Homelab/2026-05-17-vault-push-verification-2026-05-16.md b/Sources/Homelab/2026-05-17-vault-push-verification-2026-05-16.md deleted file mode 100644 index 5393674..0000000 --- a/Sources/Homelab/2026-05-17-vault-push-verification-2026-05-16.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: postgres-consolidation-reflection-layer -tags: -- mcp -- automation -- git -type: session-notes ---- - -## Outcome - -Final verification of the vault MCP write path after wiring `VAULT_PUSH_TOKEN` + `VAULT_GIT_HTTPS_URL` and rewriting the vault repo's origin to HTTPS at first push. If this artifact returns `pushed: true`, the end-to-end write surface (filesystem + git commit + git push + Postgres dual-write + chunked embeddings) is operational. - -## Topics Covered - -The full push fix: -- gitea PAT generated for lovebug user with write:repository scope -- VAULT_PUSH_TOKEN + VAULT_GIT_HTTPS_URL added to deployed .env -- `_ensure_https_remote` helper in git_writer.py rewrites origin URL + configures credential.helper on first push -- Credential helper reads $VAULT_PUSH_TOKEN at push time — token never lands in .git/config - -## Key Learnings - -The credential helper pattern keeps the secret out of any persisted file while still letting git push work non-interactively. The helper string in .git/config is just the recipe (`!f() { echo "username=..."; echo "password=$VAULT_PUSH_TOKEN"; }; f`); the env var resolves at runtime. - -## Follow-ons - -- [ ] If pushed: true: vault MCP write surface complete, the previous pending commit (5fb0ce2) plus this new one should both be on origin -- [ ] If pushed: false: surface the actual git push error from vault container logs \ No newline at end of file diff --git a/Sources/Homelab/vault-semantic-search-integration-test-2026-05-16.md b/Sources/Homelab/vault-semantic-search-integration-test-2026-05-16.md deleted file mode 100644 index a1f202f..0000000 --- a/Sources/Homelab/vault-semantic-search-integration-test-2026-05-16.md +++ /dev/null @@ -1,35 +0,0 @@ ---- -created: '2026-05-17' -path: Sources/Homelab -project: vault-semantic-search-integration-test-2026-05-16 -tags: -- mcp -- embeddings -- pgvector -type: project-plan ---- - -## Goal - -Verify the vault MCP create_artifact path works end-to-end after the ALTER FUNCTION fix for the notify_project_change trigger. - -## Locked Decisions - -- Type: project-plan (exercises the projects table trigger that was failing) -- Status: on_deck (a valid project_status enum value, will be resolved by the trigger) -- Domain: homelab - -## Open Items - -- [ ] Confirm the trigger fires successfully with the ALTER FUNCTION search_path fix -- [ ] Verify push succeeds - -## Phases - -### Phase 0 - -Run this artifact creation, confirm pushed: true and ok: true. - -## Notes - -This test entry can be deleted later once verification is complete. It's intentionally created with type=project-plan to exercise the wiki.projects table + notify_project_change trigger that was failing. \ No newline at end of file diff --git a/Sources/index.md b/Sources/index.md index a97408c..0a592ab 100644 --- a/Sources/index.md +++ b/Sources/index.md @@ -8,13 +8,13 @@ updated: 2026-05-24 # Sources -All project plans and session notes. 96 files across Dev, Venture, and Homelab domains. +All project plans and session notes. 88 files across Dev, Venture, and Homelab domains. ## By Domain -- [[Sources/Dev/index|Dev]] — 34 projects, 9 sessions — coding, AI/ML, tooling, PBS tech +- [[Sources/Dev/index|Dev]] — 34 projects, 7 sessions — coding, AI/ML, tooling, PBS tech - [[Sources/Venture/index|Venture]] — 0 projects, 2 sessions — PBS business, content, brand -- [[Sources/Homelab/index|Homelab]] — 23 projects, 22 sessions — infrastructure, networking, deployments +- [[Sources/Homelab/index|Homelab]] — 22 projects, 17 sessions — infrastructure, networking, deployments - [[Sources/Reference/index|Reference]] — (empty) cross-domain reference notes ## Active Projects (cross-domain highlights) diff --git a/log.md b/log.md index a3e274f..83d6405 100644 --- a/log.md +++ b/log.md @@ -56,3 +56,14 @@ Append-only event log. Each entry records a compile, lint, or migration run. - Indexes updated: Wiki/index, Wiki/Reference/index, Wiki/Homelab/index, Wiki/Dev/index - Notes: Sources are MCP-written/immutable, so referencing Sources files were NOT rewritten to wikilinks; new entity pages link outward to their sources instead. + +## [2026-05-24 22:00] cleanup | delete test artifacts + stale worktrees (user-approved) + +- Deleted 8 pipeline test artifacts: Dev/2026-05-16-vault-integration-test{,-multi}, + Homelab/2026-05-17-vault-{create-artifact,push-final,push-success,push-token-fix,push}-verification, + Homelab/vault-semantic-search-integration-test-2026-05-16 +- Removed 3 stale git worktrees (.claude/worktrees/{amazing-bardeen,inspiring-borg-1ee437, + reverent-sinoussi}) — all clean, none complained — and deleted their 3 merged claude/* branches +- Index fixups: removed 2 deleted-file links from Sources/Dev/index; refreshed Sources/index counts + (96→88 files; Dev 9→7 sessions, Homelab 23→22 projects / 22→17 sessions) +- Broken-link recheck: 0 real broken links remaining