@legna-lnc/legnacode 1.5.0 → 1.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,40 @@
4
4
 
5
5
  All notable changes to LegnaCode CLI will be documented in this file.
6
6
 
7
+ ## [1.5.2] - 2026-04-20
8
+
9
+ ### Performance
10
+
11
+ - **Async CodeGraph** — `build()` and `walkDir()` converted from sync to async, yielding the event loop every 50 files. Added `maxDepth=10` depth limit and `visitedInodes` symlink loop protection. `save()` now uses async `writeFile`.
12
+ - **undoTracker size guard** — Added 1MB file size limit; files exceeding it skip undo snapshot recording (prevents OOM). `readFileSync` → async `readFile`.
13
+ - **Async error file pre-injection** — `extractErrorFiles` converted from `existsSync`+`readFileSync` to async `access`+`readFile`.
14
+ - **stripCode dedup** — `magicKeywords.ts` reduced `stripCode()` from 3-4 calls to 1, passing the result to all downstream functions.
15
+ - **FileMemoryProvider TTL cache** — `searchSolutions` and fallback file search now use 60s TTL cache, avoiding repeated disk reads on every prefetch.
16
+ - **OML_SESSION_GUIDANCE cache** — `attachments.ts` dynamic import cached at module level after first load.
17
+ - **frustrationHint patterns hoisted** — Regex array moved from function body to module-level constant.
18
+
19
+ ### i18n
20
+
21
+ - **Compacting status messages localized** — "Compacting context…" → "凝练上下文…", "Compacting conversation" → "精炼对话中" for Chinese users.
22
+ - **Turn completion verbs localized** — New `getTurnCompletionVerbs()` function; Chinese users see "烹制了 5s" instead of "Baked for 5s".
23
+
24
+ ### Cleanup
25
+
26
+ - Deleted dead code `src/commands/undo.ts` (was never registered in command list).
27
+ - Fixed dead conditional in `extractImports`.
28
+
29
+ ## [1.5.1] - 2026-04-19
30
+
31
+ ### Features
32
+
33
+ - **Proactive skill invocation** — Wired `OML_SESSION_GUIDANCE` (the "1% rule") into the `skill_listing` attachment. The AI now proactively considers available skills before every response, instead of only responding to explicit `/slash` commands.
34
+ - **Frontend/design auto-guidelines** — New `designPrompt.ts` detects frontend intent (UI, prototype, design exploration) from user input and transparently injects layered design guidelines (oklch colors, responsive layout, animation best practices, design exploration methodology). Zero user action required.
35
+ - **Enhanced designer agent** — `/oml:designer` now carries a full design methodology prompt (oklch palettes, mobile-first, ARIA accessibility, 3+ variation exploration) instead of a one-line description.
36
+
37
+ ### Bug Fixes
38
+
39
+ - **Skills were never proactively used** — `OML_SESSION_GUIDANCE` was defined in `superpowers.ts` but never imported or injected anywhere. Now wired into the skill listing attachment.
40
+
7
41
  ## [1.5.0] - 2026-04-19
8
42
 
9
43
  ### Bug Fixes
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  **An AI-powered terminal programming assistant, supercharged.**
6
6
 
7
- [![version](https://img.shields.io/badge/version-1.5.0-blue)](./CHANGELOG.md)
7
+ [![version](https://img.shields.io/badge/version-1.5.2-blue)](./CHANGELOG.md)
8
8
  [![platforms](https://img.shields.io/badge/platforms-macOS%20%7C%20Linux%20%7C%20Windows-brightgreen)](#platform-support)
9
9
  [![license](https://img.shields.io/badge/license-MIT-yellow)](./LICENSE)
10
10
  [![Claude Code](https://img.shields.io/badge/based%20on-Claude%20Code-blueviolet)](https://github.com/anthropics/claude-code)
@@ -33,6 +33,8 @@ LegnaCode is built on top of [Claude Code CLI](https://github.com/anthropics/cla
33
33
 
34
34
  | Version | Summary |
35
35
  |---------|---------|
36
+ | **1.5.2** | Perf audit: async CodeGraph, undoTracker size guard, compacting i18n, TTL caches |
37
+ | **1.5.1** | Proactive skill invocation (OML 1% rule); auto-inject frontend/design guidelines; enhanced designer agent |
36
38
  | **1.5.0** | Fix REPL startup deadlock; remove /undo static import; all AtomCode features fully wired |
37
39
  | **1.4.9** | Baseline (no-AVX) builds for older x64 CPUs (darwin-x64-baseline, linux-x64-baseline) |
38
40
  | **1.4.8** | AtomCode fusion (Pangu CJK spacing, frustration detection, loop guard, error file injection, first-read full) |
package/README.zh-CN.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  **AI 驱动的终端编程助手,全面增强。**
6
6
 
7
- [![version](https://img.shields.io/badge/version-1.5.0-blue)](./CHANGELOG.zh-CN.md)
7
+ [![version](https://img.shields.io/badge/version-1.5.2-blue)](./CHANGELOG.zh-CN.md)
8
8
  [![platforms](https://img.shields.io/badge/platforms-macOS%20%7C%20Linux%20%7C%20Windows-brightgreen)](#平台支持)
9
9
  [![license](https://img.shields.io/badge/license-MIT-yellow)](./LICENSE)
10
10
  [![Claude Code](https://img.shields.io/badge/based%20on-Claude%20Code-blueviolet)](https://github.com/anthropics/claude-code)
@@ -33,6 +33,8 @@ LegnaCode 基于 [Claude Code CLI](https://github.com/anthropics/claude-code)
33
33
 
34
34
  | 版本 | 摘要 |
35
35
  |------|------|
36
+ | **1.5.2** | 性能审计:CodeGraph async 化 + undoTracker 大文件保护 + 状态文案 i18n |
37
+ | **1.5.1** | Skill 主动调用(OML 1% 规则);前端/设计指令自动注入;增强 designer agent |
36
38
  | **1.5.0** | 修复 REPL 启动死锁;移除 /undo 静态导入;AtomCode 全部特性完整接线 |
37
39
  | **1.4.9** | Baseline(无 AVX)构建,支持老款 x64 CPU(darwin-x64-baseline、linux-x64-baseline) |
38
40
  | **1.4.8** | AtomCode 融合(Pangu CJK 间距、挫败检测、循环守卫、错误文件注入、首次全文读取) |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@legna-lnc/legnacode",
3
- "version": "1.5.0",
3
+ "version": "1.5.2",
4
4
  "description": "LegnaCode — legna.lnc's official CLI for coding assistance",
5
5
  "type": "module",
6
6
  "bin": {
@@ -142,13 +142,13 @@
142
142
  "bun": ">=1.2.0"
143
143
  },
144
144
  "optionalDependencies": {
145
- "@legna-lnc/legnacode-darwin-arm64": "1.5.0",
146
- "@legna-lnc/legnacode-darwin-x64": "1.5.0",
147
- "@legna-lnc/legnacode-darwin-x64-baseline": "1.5.0",
148
- "@legna-lnc/legnacode-linux-x64": "1.5.0",
149
- "@legna-lnc/legnacode-linux-x64-baseline": "1.5.0",
150
- "@legna-lnc/legnacode-linux-arm64": "1.5.0",
151
- "@legna-lnc/legnacode-win32-x64": "1.5.0",
152
- "@legna-lnc/legnacode-win32-ia32": "1.5.0"
145
+ "@legna-lnc/legnacode-darwin-arm64": "1.5.2",
146
+ "@legna-lnc/legnacode-darwin-x64": "1.5.2",
147
+ "@legna-lnc/legnacode-darwin-x64-baseline": "1.5.2",
148
+ "@legna-lnc/legnacode-linux-x64": "1.5.2",
149
+ "@legna-lnc/legnacode-linux-x64-baseline": "1.5.2",
150
+ "@legna-lnc/legnacode-linux-arm64": "1.5.2",
151
+ "@legna-lnc/legnacode-win32-x64": "1.5.2",
152
+ "@legna-lnc/legnacode-win32-ia32": "1.5.2"
153
153
  }
154
154
  }