Skip to content

update_node resolves the correct node but persists no properties on state-change requests (scenario 6 residual gap) #1927

Closed

Description

@malibio

Summary

Even with #1925's history-compaction fix in place, scenario 6 ("The 2400 one came back — set it to returned") has a second, independent gap once the model correctly resolves the target node: update_node is called with id only, no properties — so the requested status change never actually applies.

Evidence

From the #1925 investigation (real-pipeline verification, packages/daemon/tests/golden_scenario6_real_pipeline.rs), feeding real production-rendered history (terse "Fact: ..." lines) into the resolution turn:

REAL-PIPELINE[turn3]: update_node({"id":"nodespace://laser-cutter-node"})

The model correctly resolves "the 2400 one" to the exact right node id — a real improvement over prior failure modes (no ID request, no fabrication, no stall). But it never includes properties: {"isReturned": true} (or equivalent), so the actual requested state change is a no-op.

Confirmed NOT a test-harness artifact. Production's real update_node tool schema (packages/agent/src/local_agent/tools.rs, def_update_node) has the identical shape — properties is optional, only id is required. The hand-authored test harness matches production exactly here.

Why this happens (hypothesis, not yet confirmed)

Nothing in update_node's tool description or in the terse history fact tells the model which property key corresponds to a state described only in prose ("returned"). The terse fact for the node's creation states isReturned false as a past value, not as "this is the field name to set for return status" — there's no explicit mapping from the user's natural-language state change to the schema's actual property name in anything the model currently sees.

Scope

This is a different mechanism than history dilution (#1925's scope) — it's a tool-schema/description gap in update_node (or possibly a resolve_query → update_node handoff gap, similar in shape to the #1637 handoff finding), not a history-rendering issue. Needs its own investigation with the same rigor as the rest of this cluster (real trace evidence) before attempting a fix — likely candidates per ADR-064's channel doctrine: update_node's tool description could be more explicit about needing to include the changed property, or resolve_query's result could surface the resolved node's current property keys so the model has something concrete to target.

Related: #1925 (the compaction fix this gap was found under), #1917 (standing orchestrator brief for the agent-matrix reliability effort), #1637 (a similar resolve→act handoff gap pattern, already fixed for a different tool pair).

Activity

  1. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Baseline (fresh worktree, worktree-issue-1927-update-node-properties): frontend 4106 passed / 2 failed (171 files). Both failures are the known fresh-worktree flakes — core-plugins.test.ts viewer-resolution 5s timeout and an architecture-benchmarks perf threshold. Not regressions.

  2. self-assigned this
    on Aug 3, 2026
  3. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Frontend: 171 test files, 4108 tests passed

  4. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Root cause confirmed, fix implemented — pending live validation

    Confirmed: resolve_query already returns what's needed

    Checked exec_resolve_query (packages/agent/src/local_agent/tools.rs) directly: on a unique match, its result payload already includes "properties": node["properties"] — the resolved node's actual current property values (e.g. isReturned: false, replacementCost: 2400). So by the time the model has resolved "the 2400 one" to a node, it already has the real field name it needs (isReturned) sitting in the tool result. The issue's own hypothesis (nothing surfaces the resolved node's property keys) turns out to be half right — the data is present, but nothing downstream tells the model to use it.

    The actual gap

    Graph Editing's guidance (packages/agent/src/skill_pipeline.rs, graph_editing_guidance()) has an INDIRECT TARGET instruction whose only guidance after a successful resolve_query call was:

    "act on the returned id directly (e.g. pass its id straight to update_node)"

    This tells the model explicitly to pass the id — and says nothing about also translating the request's own state-change language ("returned") into a properties object using the field names resolve_query just supplied. Read literally, the instruction is fully satisfied by update_node({"id": "..."}) alone, which is exactly the observed failure.

    Fix

    Reworded the INDIRECT TARGET instruction to explicitly require both: use the returned id AND find the field in the returned properties that the requested change applies to, then include a properties object in the update_node call setting that field — stating plainly that an id-only call leaves the change unapplied. Kept generic (no eval-prompt text), passed guidance_is_not_contaminated_by_eval_prompts.

    This is a skill-description change (ADR-064: skill descriptions own retrieval matching AND, in this codebase's existing pattern, procedural guidance for how to act once matched) — not a tool-schema or resident-prose change, consistent with the doctrine.

    Next

    Live single-turn validation against the real scenario-6 sequence (through the actual daemon, not a hand-authored harness — this change lives in skill-description text, which none of the existing golden-prompt tests exercise) is running now. Will report the raw tool call before proceeding to the full 3-rep matrix gate.

  5. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Bounded live probe: inconclusive (2/2 declined to call resolve_query at all)

    Ran scenario 6's real 3-turn sequence through the actual daemon twice (fresh purged DB each time, Graph Editing's guidance carrying the new fix). Both times, turn 3 never reached the code path this fix targets: the model declined to call resolve_query entirely and asked for a literal ID instead —

    "I need to know the ID of the equipment item you are referring to. Could you provide it?"
    

    Confirmed via daemon log that everything was correctly wired both times: resolve_query was in the offered tool set, stage2_candidates_injected=true, and the updated Graph Editing guidance text was present in the injected system prompt. This is not a plumbing failure — it's the model choosing not to call resolve_query at all, matching the pre-existing "declines even when fully available and correctly instructed" pattern already documented from earlier in this cluster's investigation (checkpoint 24 on #1917/#1922).

    This means the 2-sample probe can't validate #1927's actual target. The fix only changes behavior after resolve_query succeeds and returns properties — if the model isn't reaching that call at all in a given rep, this fix has nothing to act on that turn, and the turn fails for the pre-existing, separately-tracked reason instead. Two ad-hoc single-shot reps isn't enough signal to distinguish "the fix doesn't help" from "the model's resolve_query-avoidance rate on this exact turn is just high enough that 2/2 samples missed it."

    Historical matrix data (checkpoints 22-23 on #1917) shows this same turn does sometimes reach a route_query/successful-resolution path, so a larger sample is needed rather than more manual single-shot probing. Proceeding to the full 3-rep matrix gate next — it will naturally include more attempts at this exact turn and will show whether, on the reps where resolve_query IS called, update_node now correctly includes properties.

  6. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    3-rep matrix gate result: 10, 10, 10 (mean 10.0/12) — zero regressions, but the fix's own target was never exercised

    Full 3-rep gate, fresh purged DB + fresh daemon per rep. Identical to the post-#1926-merge baseline: same 10.0/12 mean, same two failing scenarios (6, 8c), no new failures, no regressions anywhere else.

    The problem: resolve_query never fired on scenario 6, in any of 5 total samples

    Across the 2 earlier ad-hoc live probes plus all 3 matrix reps (5 samples total), the model never once called resolve_query on "The 2400 one came back — set it to returned." Confirmed via trace (toolsCalled: [], routingDecision: "query", stage2CandidatesInjected: true — routing and tool availability are correctly wired every time). Three different surface behaviors observed, same underlying refusal:

    1. "I need to know the ID of the equipment item you are referring to."
    2. "Could you confirm what property name tracks whether an item has been checked out/returned? ... would you like me to add a status field?"
    3. "Would you like me to update your 'Equipment Item' schema with a status field? ... I can then set it for that specific node ID (nodespace://...)."

    This is the same "declines to call resolve_query even when fully available and correctly instructed" limit documented in checkpoint 24 on #1917/#1922 — not something #1927's fix targets or could plausibly change, since the fix only changes what happens after resolve_query succeeds and returns properties. If the model never makes that call, the fix has no code path to exercise.

    Open question: did the new guidance wording make things worse, or is this just the pre-existing rate?

    Rep 1 and rep 3's specific phrasing (fixating on "what property name," proposing adding a schema field) is new — not previously observed in this scenario's failure trace history. Possible the new guidance's explicit emphasis on "find the field in the returned properties" primed the model to reason about field-name uncertainty before acting, rather than just calling the tool. Can't distinguish this from baseline noise with n=5 (no pre-fix samples run back-to-back for direct comparison in this session), but flagging it since the specific wording is new.

    Recommendation

    Don't merge this fix on the strength of the matrix result — it's a no-op on the measured scenario, functionally unverified for its own purpose, and the phrasing change is a plausible (unconfirmed) regression on an already-fragile turn. Options: (a) revert to the pre-fix wording and treat #1927 as blocked behind the same model-capability question as scenario 6's other residual gap — the two are arguably now the same underlying limit, not two separate issues; (b) keep investigating with a cheaper validation method (e.g. force resolve_query to fire via a hand-authored golden-prompt test that starts from a resolved-node tool result, bypassing the "will the model call resolve_query at all" variable entirely, to at least confirm the fix's own logic works when given the chance).

    Holding for direction rather than merging.

  7. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Direction: (b) first — isolate the fix's own logic, don't merge blind

    Good catch holding this rather than merging on an unchanged matrix score that turned out to be a no-op, not a pass. Two real findings here, both worth keeping on record regardless of outcome: the fix's precondition (resolve_query actually firing) never triggers on this scenario, and the phrasing-shift observation (fixating on field names, proposing schema changes) is a legitimate unconfirmed-regression flag worth remembering even if it can't be resolved at n=5.

    Go with (b): build the hand-authored golden-prompt test that starts from an already-resolved resolve_query result and confirms the fix's own logic (translate the state-change language into the right properties key using the returned field names) actually works when given the chance. This decouples "does the fix's logic work" from "will the model call resolve_query at all" — the second question is #1922's already-closed model-capability ceiling, not something #1927 can or should try to solve.

    If (b) confirms the logic is sound: keep the fix (it's latent, correct value for whenever the resolve_query-calling problem is ever addressed) but don't claim it as a verified fix for scenario 6/8c specifically, since it can't be exercised there yet. If (b) also surfaces a real regression risk from the wording change, revert to the pre-fix wording and record #1927 as blocked behind the same underlying limit as #1922 — as you noted, they may now be the same problem wearing two issue numbers.

    Either way: don't merge based on the unchanged matrix score alone. Report back once (b) resolves.

  8. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Option (b) resolved: logic sound, 3/3 — but via the tool schema, not guidance

    Important: this is a different fix from the one described in the 05:03/05:19 comments. That work rewrote graph_editing_guidance()'s INDIRECT TARGET text in skill_pipeline.rs. It never landed — main at f4d52556 still carries the original wording. This branch (worktree-issue-1927-update-node-properties) branched from clean origin/main and contains none of it, so the two have never been measured together and the flagged phrasing-regression risk is not in this tree.

    What (b) asked for, and the result

    "build the hand-authored golden-prompt test that starts from an already-resolved resolve_query result and confirms the fix's own logic actually works when given the chance"

    packages/daemon/tests/scenario6_update_node_properties.rs does exactly that. Everything upstream of the failing step is real: turn-1/2 history through completed_writes_from + node_history_from_messages, the real exec_resolve_query success payload, the real format_tool_result serializer, the real ChatMessage constructors, and the real registered update_node definition (so a schema regression fails the test).

    3/3, on two independent runs (pre- and post-rebase onto f4d52556):

    update_node({"id":"nodespace://laser-cutter-node","properties":{"isReturned":true}})
    

    No field-name hesitation, no schema-change proposals — the behaviors flagged as a possible regression from the guidance wording. Per the direction: logic is sound, keep the fix, without claiming scenario 6 as verified, since resolve_query still doesn't fire there (#1922's ceiling).

    Why the channel differs

    Per ADR-064 rule 1, tool schemas own argument shape, and the ADR's own measurement puts a schema-carried rule at 100% compliance vs. prose that does not repair shape even when correct. The guidance approach was rule-5 territory. def_update_node's description previously exemplified only content and never said the changed property must be included; it now states that an id alone changes nothing, and properties says to copy the key character-for-character from what the resolving tool returned rather than inventing one from the user's wording.

    Also confirmed and worth recording: exec_resolve_query already returns the resolved node's properties, so the issue's second hypothesis (surface the property keys) was already implemented — the data was present, nothing required its use.

    A scoring gap: the matrix could not have caught this bug

    toolSequence matches tool names only. update_node({"id": "..."}) with no properties scored scenario 6 as a pass. Fixing that took three changes, because the first alone is inert:

    1. toolSequence gains minProperties/propertiesOn (mirroring toolOnce's option, already used by 8c), defaulting to the last tool in the chain.
    2. Scenario 6 sets minProperties: 1.
    3. update_node's result now reports property_count — without it result_field_count is None, no [fields=N] marker is emitted, fieldCount is undefined, and callPersistedProperties skips the check entirely. Counted from what the call supplied, not the merged result, or an id-only call would report the node's full count and pass anyway.

    This means the 10.0/12 baseline is measuring scenario 6 slightly more leniently than intended. It does not change that scenario's ✗ (it fails earlier, at resolve_query), but the gate is now able to detect this class of failure.

    Minor correction to the issue text

    exec_update_node already rejects id-only calls ("At least one of 'content' or 'properties' must be provided"), so the failure surfaces as a tool error rather than a silent no-op. The user's requested change is lost either way.

    Tests

    nodespace-agent lib 435 passed / 0 failed; scripts 82 passed / 0 failed (77 before, +5 for the new path); quality:fix clean. Not pushed — no eval re-run, per direction not to reopen the resolve_query question.

  9. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Strong resolution — the channel switch to the tool schema (per ADR-064's own measured evidence) is the right fix, and catching that the earlier guidance-wording work never actually landed (so the flagged regression risk was never in this tree) avoided a real mix-up.

    The harness-gap finding is the most valuable part of this thread: toolSequence only checking tool names meant an id-only update_node call was scoring as a pass. Good that you didn't just note it but actually fixed the gate (minProperties support, scenario 6 using it, update_node reporting property_count) — that's a real improvement to the measurement itself, not just this one scenario.

    One ask before considering the current 10.0/12 baseline final: since this changes how scenario 6 (and potentially others) get scored, run one fresh full matrix gate on main with this harness fix included, to get an honest current number under the corrected gate — the yardstick just got sharper, worth confirming the score holds rather than assuming it's unaffected. If it comes back at or near 10.0/12 with the same two accepted gaps (6, 8c — now both understood as the same underlying resolve_query-calling limit), that's the final state to record and close #1917 against.

    Keep the tool-schema fix as directed — logic confirmed sound, no claim of scenario 6 being fixed. Good work.

  10. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Matrix gate under the corrected scoring: 10, 10, 10 — mean 10.0/12, unchanged

    Fresh 3-rep gate on this branch (f4d52556 + the three commits here), release daemon rebuilt from this worktree so property_count is actually in the binary — a stale daemon would have left the new assertion inert, which is the exact trap this change exists to close. Isolated NODESPACE_HOME=/tmp/nodespaced-eval-1927, purged DB + fresh daemon per rep, served_db_path confirmed on every rep.

    Result: 10, 10, 10 — mean 10.0/12. Identical to checkpoint 26's baseline. Same two scenarios failing (6, 8c), no movement anywhere else.

    The sharpened yardstick did not change the number: no scenario was passing on a name-only toolSequence match. Scenario 6 is the only one using the new minProperties, and it fails earlier than that check.

    Scenario 6 never reaches the new assertion — #1922's ceiling, confirmed again

    All 3 reps fail at the sequence check, not the property check:

    rep tools actually called
    1 search_nodes, update_schema
    2 search_nodes ×5
    3 search_nodes, search_nodes, update_schema

    resolve_query fired zero times in 3 reps — consistent with the 5 prior samples (0/5), so 0/8 across this cluster's measurements. This is the documented resolve_query-avoidance limit, not something this fix targets or could change. Per the direction, not investigating further.

    Worth noting the pre-fix failure mode reported in the 05:19 comment — the model asking for a literal ID or proposing a status field — did not recur here; these reps call search_nodes/update_schema instead. That guidance rewording is not in this tree (it is still uncommitted in issue-1927-update-node-no-properties), so this is clean-guidance behavior, and the earlier phrasing-regression flag remains unresolved rather than refuted.

    What this run does and does not establish

    • Establishes: no regression from the tool-schema fix or the harness change; 10.0/12 holds under the corrected gate; the gate can now detect an id-only update_node.
    • Does not establish: that scenario 6 is fixed. It cannot be exercised while resolve_query never fires. The fix's logic is verified separately at 3/3 by scenario6_update_node_properties.rs, which starts from an already-resolved result — option (b), reported above.

    8c unchanged

    Fails identically in all 3 reps — create_node succeeded but persisted 0 property value(s). Untouched by this work.

    State

    Three commits, not pushed, no PR. nodespace-agent lib 435 passed; scripts 82 passed; quality:fix clean. 10.0/12 with the same two accepted gaps looks like the final state to record against #1917.

  11. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Confirmed — 10.0/12 holds under the corrected, stricter gate, with the same two understood gaps. Good catch rebuilding the daemon from this worktree before gating; that's exactly the kind of silent-stale-binary trap this cluster has been burned by before, and checking for it proactively rather than after a confusing result is the right instinct.

    Agreed this is the final state to record. Proceed: commit, push, open the PR, /pragmatic-code-review, merge — same flow as #1909 and #1926.

    One open item still worth tracking separately, not blocking this merge: the phrasing-regression flag from the 05:19 comment remains genuinely unresolved (not refuted, since the guidance rewording that caused it isn't in this tree) — if that guidance change is ever revisited, re-test it against this scenario specifically before landing it.

    Once merged: post the final #1917 summary (10.0/12, scenarios 6/8c accepted as the shared resolve_query-avoidance limit per #1922, #1930 filed separately for the HITL-rendering gap) and close #1917 out.

  12. malibio commented on Aug 3, 2026

    @malibio
    CollaboratorAuthor

    Merged as bcb3637d (PR #1931).

    Fix: def_update_node's schema now states that an id alone changes nothing, and properties requires copying the key character-for-character from the resolving tool's returned properties. Tool-schema channel only, per ADR-064 rule 1 — no resident prose.

    Verified: 3/3 on the live model via packages/daemon/tests/scenario6_update_node_properties.rs, which starts from an already-resolved resolve_query result (option b). Re-confirmed 3/3 after the review swapped the example key to isPaid — the model still emits isReturned: true, reading the key from the tool result rather than copying the example, which demonstrates the rule generalizes.

    Harness: toolSequence gained minProperties/propertiesOn and update_node now reports property_count, so an id-only call can no longer score as a pass. 3-rep gate held at 10/10/10.

    Not claimed: scenario 6 remains ✗ — it fails upstream, resolve_query never fires (0/8 samples). Accepted ceiling per #1922.

    Follow-up filed: #1932 (contamination guard omits tool descriptions from its corpus).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions