Repository navigation
Fix audit findings: result integrity, model units, cleanup and bounded context - #23
Merged
Merged
Conversation
…and archive cache - Discovery: a group named only by a keyword (a Russian request gives English descriptions nothing to rank by) is loaded whole instead of its first 12 tools in registration order; every keyword group in the prompt is loaded; ranked matches beyond 12 are listed by name. - Keyword matching accepts common Russian verb prefixes (образмерь, замаркируй, сгруппируй, заармируй), splits keys like the text so "технико-эконом" and "СП 1.13130" match, treats quotes, guillemets and brackets as separators, and restores English welded/wire mesh triggers. - Live SPDS updater writes its DataStorage only when the refresh state changes, so ordinary edits no longer modify it on every transaction (ownership conflicts in workshared models). - Headless results are re-encoded without \uXXXX escapes before the budget is measured; the test now uses the production serializer. - Archive hot cache is a real LRU; Dictionary slot reuse made it evict the newest entry. 14 new regression tests, each failing on the previous revision. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RCGB6xWx3ZtmWZRQEJtN6B
…nup and model tools - Exceptions and repeated-error notes stay one JSON value, so aged results keep their failure state; text "Error…" results count as failures. - Aged summaries copy fewer, shorter fields and never replace a result with something larger. - get_full_result pages carry completion fields up front, so they are not re-capped; the test now runs completion then cap. - System prompt describes the JSON aged summary and next_offset paging. - post_write_readback timing passes the task id from the Revit thread. - Pre-loading uses the user's text only and pre-loads each group once per conversation, avoiding repeated prompt-cache rewrites. - Catalog: overview with family type counts by default, paging first, limit halved until the response fits, offset limited to a single list. - Benchmark API runs that reach the round budget are marked budget-stopped. - undo_last: "steps": null undoes the whole action; an unconfirmed Redo of the user's step is reported as such; no empty change archives. - clean_model: one purge pass, one batch rehearsal with per-candidate fallback only on cascades/errors, bounded failure and cascade samples. - unload_family refuses when types reference the family via a parameter. - NameResolve prefers an exact-case match and accepts "Family: Type" for system types. - derive_parameters fails once on a dimension mismatch, bounds failures, documents factor; calculate_weight lets material density win over the fallback and reports parameter write failures. - Native density case uses 1234 kg/m3 converted by Revit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RCGB6xWx3ZtmWZRQEJtN6B
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.
Large tool outputs could turn failures into success and hide rollback state, and Python failures could commit partial model edits. Incorrect density conversion also understated mass, and cleanup and Undo relied on unsafe assumptions.
This PR preserves execution semantics across JSON completion, truncation, history aging, MCP and API chat. It rolls back logical failures before committing, and adds bounded archive pages that can retrieve data beyond the previous 30k ceiling.
Changes:
docs/audit-fixes-2026-10-20.md.Follow-up review fixes (
6f104f2,e2d0aad)A review of this change found 28 issues; all are addressed:
"steps": nullundoes the whole last action.unload_familychecks type-parameter references.Family: Typeform.derive_parametersfails once on a dimension mismatch, and the description offactoris clarified.calculate_weight, material density takes precedence over the fallback, and parameter write failures are reported.Validation:
Native acceptance is still pending in live Revit:
Scope: this implements the confirmed recommendations. It does not claim that all 168 raw report entries were independently verified or resolved.
🤖 Generated with Claude Code
https://claude.ai/code/session_01RCGB6xWx3ZtmWZRQEJtN6B