mirror of
https://github.com/ruvnet/ruflo.git
synced 2026-12-04 06:21:59 +09:00
agentdb_pattern-store writes through ReasoningBank.storePattern(), but when agentdb's Transformers.js model fails to load (offline, failed sharp install, or a loaded CI runner) it serves hash-based mock embeddings. A passage and a query then embed to unrelated vectors, so searchPatterns() returned [] for a pattern that was just stored. This is the full-suite #2226 failure that has kept the CI ratchet red since the move to agentdb 3.2. - bridgeSearchPatterns: when the agentdb vector search returns nothing, scan the same reasoning_patterns table for the query text, matching what the LocalReasoningBank branch already does over getAll(). - rescueAgentdbEmbedder: agentdb 3.x's ReasoningBank calls embedQuery() / embedPassage(), which bypass embed(). Patch the role methods too and clear the cached mock vectors, so a host with ONNX actually gets real vectors. - Regression test forces AGENTDB_DISABLE_TRANSFORMERS=1 and requires the round-trip to hit; it fails without the fix. Co-authored-by: r <r@x>