Added
- First-class Augment AI agent support —
lean-ctx init --agent augmentwires up both Augment configuration surfaces: Auggie CLI (~/.augment/settings.json) and VS Code extension (globalStorage/augment.vscode-augment/.../mcpServers.json, JSON array with stable UUID-keyed upserts). Rules injected at~/.augment/rules/lean-ctx.md.lean-ctx doctorreports per-surface MCP drift including"disabled": truedetection. Full cross-platform support (Linux, macOS, Windows). Contributed by @parker-brown-family (#264, #267) - Context package system renamed to
.ctxpkg— Package format, CLI commands, transport envelopes, and documentation all use.ctxpkgextension. Legacy.lctxpkgfiles remain importable for backward compatibility ctx_multi_readserver-side output cap — Output capped at 512KB by default (configurable viaLCTX_MAX_MULTI_READ_BYTES) to prevent MCP client-side truncation. When exceeded, remaining files are skipped with a clear warning (#263)- Degradation policy warning —
auto_degrade_read_mode()now emits an explicit⚠ Context pressurewarning whenmode=fullis downgraded tomode=mapormode=signatures, including the verdict and bypass hint (start_line=1orctx_compress) (#262) - 28 new regression tests — 14 UTF-8 boundary tests (Cyrillic, CJK, emoji, exact user scenario), 10 degradation verdict tests, 4
ctx_multi_readcap tests
Fixed
- UTF-8 character boundary panics — 13 string truncation sites across the codebase now use
str::floor_char_boundary()/str::ceil_char_boundary()instead of raw byte slicing, preventing panics on multi-byte characters like Cyrillic, CJK, or emoji. Affected:hash_fast(4096 byte prefix/suffix), curl/cargo/test/just pattern compression, codebook display, gotcha tracker, mcp_compress, ctx_edit preview, ctx_preload hints, dashboard context, tool_defs, stats format, dashboard token masking, cloud email masking. Report and initial PR by @cburgess (#265, #266) - Context package system hardening — Fixed critical
receive --applybug, Graph edge import (usesget_node_by_symbolinstead ofget_node_by_path), Session/Patterns/Insights import, auto-load caching (prevents re-application), registry validation, HMAC signing (signs all fields including metadata), CLI flag parsing (--flag valueand--flag=value), memory leaks (.leak()removed), HTTP response status checking forsend lean-ctx updateproxy race condition —post_update_rewire()now restarts the proxy and waits for health before writingANTHROPIC_BASE_URLto Claude Code settings, preventing a connectivity gap (#234)
Changed
- Removed
PackageLayer::Artifacts— Dead enum variant removed; builder derives layers from actual content - Manifest validation expanded — Checks hex format of hashes,
byte_size > 0, duplicate layers - Import hardened — File extension check (accepts
.ctxpkgand.lctxpkg), size limit (MAX_PACKAGE_FILE_BYTES)
Upgrade
lean-ctx update # recommended (auto-downloads + refreshes shell hooks)
cargo install lean-ctx # or
npm update -g lean-ctx-bin # or
brew upgrade lean-ctxNote: After upgrading via cargo/npm/brew, run
lean-ctx setupto refresh shell aliases.lean-ctx updatedoes this automatically.
Full Changelog: v3.6.14...v3.6.14