Skip to content

v0.1.1 correctness hardening - #1

Merged
HayronHgh merged 2 commits into
mainfrom
agent/correctness-hardening
Aug 9, 2026
Merged

v0.1.1 correctness hardening#1
HayronHgh merged 2 commits into
mainfrom
agent/correctness-hardening

Conversation

@HayronHgh

Copy link
Copy Markdown
Owner

What changed

  • include all 11 tool schemas, tool_choice, and fixed prompt overhead in context utilization
  • make the 55%/65%/72%/80% thresholds perform distinct reduction strategies
  • validate Coding State Transfer fields and types, retry once, and fail without replacing history
  • label State Transfer as derived state that must defer to repository/tool evidence
  • enforce real-path containment against file symlink, directory symlink, and Windows junction escapes
  • harden malformed episode handling and artifact/memory invariants
  • update English and Traditional Chinese documentation for v0.1.1

Why

The original estimator counted only messages even though every model request also sent 11 function-tool schemas. File containment used lexical paths and could be bypassed through filesystem links. Invalid model-generated compaction could also become persistent state.

Impact

Context thresholds now better track the request sent to llama.cpp. File tools cannot read, write, or edit outside the project through tested symlink/junction paths. Invalid state transfer fails loudly and leaves existing history intact.

Validation

  • node --test: 22 tests defined; 21 passed locally, 1 file-symlink test conditionally skipped because this Windows host denied symlink creation
  • Windows junction read/write/edit escape test passed
  • node src/index.js --help
  • 3 JSON files parsed
  • 5 PowerShell scripts parsed
  • 20 Markdown documents passed local relative-link validation
  • staged diff and sensitive-information scans passed

@HayronHgh
HayronHgh marked this pull request as ready for review August 9, 2026 06:55
@HayronHgh
HayronHgh merged commit 62832e8 into main Aug 9, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant