Repository navigation
neo4j: Data_Bank is set once on create, never reset by a re-ingest - #1762
Merged
Merged
Conversation
The node MERGE put `Data_Bank = name` into $properties and ran `ON MATCH SET node += $properties`, so an incremental sync of a file reset every one of its nodes' search text to the bare name while text_embeddings and _search_fields_used survived — a vector that no longer matched its text, and jarvis's data_bank_full_index back to name-only. Data_Bank now stays out of $properties and is seeded from the map's name under ON CREATE alone, like date_added_to_graph (the same set-once rule, for the same reason): a later writer — strut's embedding pass, jarvis — composes the richer text from the type's Schema index fields, and a re-ingest of an unchanged function touches nothing it reads. build_stream() was already ON CREATE only.
… typed search through the domain indexes, the no-embed mark — stakwork/strut#140)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
NodeQueryBuilder::build()putData_Bank = nameinto$propertiesand ranON MATCH SET node += $properties, so an incremental sync of a file reset every one of its nodes' search text to the bare name whiletext_embeddingsand_search_fields_usedsurvived — a vector that no longer matched its text, and jarvis'sdata_bank_full_indexback to name-only (Problem 5 in stakwork/strutplans/semantic-search.md; built by stakwork/strut#140).Data_Banknow stays out of$propertiesand is seeded from the map'snameunderON CREATEalone (node.Data_Bank = $properties.name— no new parameter; the binder already passes the whole map), likedate_added_to_graph: the same set-once rule, for the same reason. A streamed node is searchable at once as before; a later writer — strut's embedding pass, jarvis — composes the richer text from the type's Schemaindexfields, and a re-ingest of an unchanged function touches nothing it reads. An unnamed node seeds no search text, as before.build_stream()was alreadyON CREATEonly and is untouched.Without this strut is still correct (its pass sees the reset text as stale and re-embeds the node), but a full re-ingest would re-embed every code node of the repository each time.
Test:
build_sets_data_bank_only_on_create_and_keeps_it_out_of_properties, beside the existing set-once tests (cargo test -p ast --lib --features neo4j build_sets).cargo fmt --checkon the file reports a pre-existing diff inread_probe_date_added, not touched here.Also bumps mcp's strut pin to
a50eb64, the merge of stakwork/strut#140 (the only changes between the previous pin and it are that PR and its plan documents, #138 and #139). So this is the pin that puts the embedding pass, the Schemaindexreconcile and the typed-search routing on every swarm at its next deploy — the swarm38 validation in the plan starts after it.