NeuralMind v4.8.2 — the low-severity bug-hunt fixes
| Type: Patch release | Theme: The rest of the end-to-end bug hunt |
v4.8.1 fixed the high- and medium-severity bugs found by testing v4.7.0 end to end. This release fixes the low-severity ones, plus a few closely related problems found while fixing them. None of them lose data. They are wrong answers, misleading messages, and a test suite that dirtied the checkout.
The ones you’re most likely to notice:
- A mistyped project path is an error. It used to create a new, empty project at that path and answer from it.
- The daemon and
neuralmind serveanswer malformed requests with a 4xx. They used to drop the connection, return a 500, or raise inside the handler. - Ingesting a Markdown file that
buildalready indexed stores it once. The same text used to come back twice in query context. feedbackanddoctorsay what actually turns query memory on.
What changed
Project paths and decisions
- A project path that doesn’t exist is an error.
query,search,wakeup,stats, thedecisionssubcommands that open a store (record,query,amend,audit,export,restore,invalidate) and every MCP tool used to create<path>/.neuralmind/for a mistyped path and run against an empty index or decision store. The CLI now exits 2 withproject path does not exist: <path>. MCP tools returncode: "project_not_found", with a hint to pass an absolute path when the path was relative, and the daemon answers 404. Nothing is created.buildin an existing directory works as before. decisions restoreanddecisions invalidatereport failures. An unknown id maderestoreprint a traceback andinvalidateprint success. A database error was logged and then reported as success. Both now printDecision not found: <id>orCould not … decision <id>: …and exit 1. The MCP invalidate tool returnsnot_foundorstorage_error.decisions record --confidencemust be between 0 and 1.7was accepted and stored as 1.0, and so wasnan. The CLI and the MCP record tool now reject the value.search --nmust be at least 1.--n 0and--n -3returned one result. The MCP tools now enforce the numeric bounds their schemas declare.stats .names the project. It printedProject:with nothing after it, in the CLI and in the MCPneuralmind_statstool.
Memory and learning
feedbackanddoctorsay how to turn query memory on. With memory off,feedback good|badsaid “run a query first”, and the next query wasn’t recorded either.doctoradvisedNEURALMIND_MEMORY=1, which changes nothing: the variable is on by default, and logging also needs a yes in~/.neuralmind/memory_consent.json. Both now name what’s off and what turns it on.validatestops warning about stale synapses on a fresh index. Every edge it flagged pointed at acommunity_<id>node or a compliance-control key, which NeuralMind writes on purpose. Synapses to deleted nodes, or to communities a rebuild dropped, are still reported.- The synapse memory export reports what each association earned.
.neuralmind/SYNAPSE_MEMORY.mdadded a pair’s weight and activation count across namespaces, so a weight could read 2.00, and it tagged edges “(long-term)” by count alone. A pair now shows its strongest namespace, and “long-term” means protected from decay: at least five activations, weight at or above 0.20, and not ephemeral. Expect fewer long-term tags. - The
SynapseDynamicsAPI does what its docstrings say. Resource limiting can trigger (ten potentiations per node until replenished), retrieval-induced forgetting weakens competitor edges that exist, and lateral inhibition keeps the strongest results instead of sometimes returning none. Nothing in the CLI, hooks or MCP tools calls this API.
Servers, demo and ingest
- The daemon and
neuralmind serveanswer malformed requests with a 4xx. A non-numericContent-Lengthdropped the connection with no response. A non-object JSON body or a non-integernwas a 500. A non-ASCII token raised inside the handler. They now get a 400 with a JSON error naming the problem: 413 for a body over 1 MiB, 401 for the token. The daemon reads flags such asforcestrictly;"false"used to count as true. Both servers close a request that stalls for 30 seconds, and the graph view’s session-cookie check is constant-time. neuralmind demostops reporting stale files. It copied the bundled project with the bundle’s timestamps, so when the bundled graph was older than its sources, every run printed “N files changed since the graph was built”.- Ingesting a Markdown file that’s already in the project stores it once.
The built-in graph already holds a Markdown file’s text, heading by
heading.
neuralmind ingest docs/guide.mdand theneuralmind_ingest_documentMCP tool stored a second copy under the absolute path, so the text came back twice in query context. Both now skip such a file and list it underalready_indexed. A file edited since the last build is skipped too, but listed underneeds_build: the graph still holds the old text, andneuralmind buildindexes the edit. Any other file inside the project is stored under its project-relative path.
For contributors
pytestleaves the checkout clean. The graph tests built the committed fixture projects in place, and each build rewrote their extraction caches. They now build throwaway copies, and the cache files are no longer tracked.
What the agent actually sees post-install
| Agent | Before | After |
|---|---|---|
| Claude Code (MCP + hooks) | A tool call with a mistyped project_path ran against a new, empty project created there. neuralmind_ingest_document on a Markdown file in the project put its text in context twice |
The call returns code: "project_not_found" and creates nothing. The ingest is skipped and the file listed under already_indexed, or needs_build if it changed since the last build |
| Cursor / Cline / Claude Desktop (MCP) | Same as Claude Code | Same as Claude Code |
| Generic MCP client | Out-of-range n or confidence was accepted |
Rejected with invalid_request, per the bounds the tool schema declares |
| Daemon clients | A malformed request could drop the connection or return a 500. "false" flags counted as true |
4xx with a JSON error naming the problem; flags read strictly; a missing project is a 404 |
Environment variables
None added or changed.
Upgrade notes
- A project path that doesn’t exist now fails. A script that relied on a
command creating
<path>/.neuralmind/should create the directory, or runneuralmind build, first. - Daemon clients: flags must be booleans (or
"true","false",1,0), request bodies are capped at 1 MiB, and a missing project is a 404. SYNAPSE_MEMORY.mdshows fewer long-term tags. It now counts only associations that are actually protected from decay.