Skip to content

v1.3.153

Choose a tag to compare

@topcheer topcheer released this 15 Jul 11:26
· 3399 commits to main since this release

v1.3.153

Highlights

  • Context management overhaul: Reworked auto-compact threshold calculation to use a simple, accurate formula (contextWindow - outputReserve). Tool-definition overhead is now tracked and included in token counts so compaction triggers at the right time. Token estimator base ratio adjusted from 4.0 to 3.5 chars/token for closer real-world accuracy.
  • Auto-memory optimization: System prompt now loads only memory titles via LoadIndex() instead of full file contents via LoadAll(), significantly reducing prompt token overhead. The LLM reads full content on demand via read_file.
  • Session-scoped model limits: Context window and max output tokens edited in the model panel are now persisted to endpoint config and re-applied after async relay catalog refresh, preventing user overrides from being silently clobbered.

Fixes

  • TUI paste: Fixed paste forwarding to provider panel new-vendor and new-endpoint wizard inputs. Added Windows clipboard image-paste fallback that tries clipboard image first, then falls back to text paste.
  • Dead code removal: Removed confirmed-unused functions across config_access.go (harness config getters), broker.go (unused trackSend/resetSession helpers), and mobile_adb.go (unused cleanup method).
  • Token calibration: Added comprehensive debug logging throughout the calibration pipeline for easier diagnostics.
  • Tool output guard: Added token count and threshold to debug log output for context-fill truncation decisions.

Refactoring

  • Progressive clearing simplification: Removed multi-tier progressive tool-result clearing schedule (50%/65%/75% thresholds) from precompact pipeline. Superseded-read compaction remains as the mechanical step before LLM summarization.
  • RecordUsage: Baseline now uses InputTokens + OutputTokens to accurately reflect the next turn's starting context size.
  • CheckAndSummarize: Removed internal threshold check — callers (maybeAutoCompact, tryReactiveCompact) already gate on thresholds.

Infrastructure

  • Updated all 11 impersonation preset versions to latest upstream releases.
  • Added RuntimeContextWindow / RuntimeMaxTokens to runtime status provider interface across TUI, daemon, and desktop platforms.
  • Web API RuntimeStatus now includes context_window and max_tokens fields.

Compare

v1.3.152...v1.3.153