@legna-lnc/legnacode 1.4.7 → 1.5.0
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 +70 -2
- package/README.md +18 -1
- package/README.zh-CN.md +18 -1
- package/package.json +9 -7
package/CHANGELOG.md
CHANGED
|
@@ -4,7 +4,75 @@
|
|
|
4
4
|
|
|
5
5
|
All notable changes to LegnaCode CLI will be documented in this file.
|
|
6
6
|
|
|
7
|
-
## [1.
|
|
7
|
+
## [1.5.0] - 2026-04-19
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
- **Fix REPL startup deadlock** — The `/undo` command was registered via static `import` in `commands.ts`, creating a circular dependency (`commands.ts` → `undo.ts` → `commands.ts`) that caused Bun's module loader to deadlock. The REPL would hang with no output on launch. Fixed by removing the static import entirely. The `/undo` feature remains available via `src/services/undoTracker.ts` (wired into Edit/Write tools) but is no longer registered as a slash command to avoid the circular dependency.
|
|
12
|
+
|
|
13
|
+
### Features (carried from 1.4.8/1.4.9)
|
|
14
|
+
|
|
15
|
+
- **AtomCode intelligence fusion** — Pangu CJK spacing, negative feedback detection, tool call loop detection, error file pre-injection, first-read full file
|
|
16
|
+
- **OpenAI-compatible bridge adapter** — Anthropic ↔ OpenAI format translation for DeepSeek/Qwen/GLM/Ollama/vLLM/LM Studio
|
|
17
|
+
- **Code Graph** — Regex-based symbol index + file dependency graph (TS/JS/Python/Go/Rust)
|
|
18
|
+
- **Parallel File Edit** — One sub-agent per file with sibling skeletons
|
|
19
|
+
- **Workflow Engine** — Structured markdown step execution with checks and dependencies
|
|
20
|
+
- **Cross-session knowledge** — Auto-writes `.legna/knowledge.md` on session end
|
|
21
|
+
- **Baseline builds** — No-AVX binaries for older x64 CPUs (darwin-x64-baseline, linux-x64-baseline)
|
|
22
|
+
|
|
23
|
+
## [1.4.9] - 2026-04-17
|
|
24
|
+
|
|
25
|
+
### Features
|
|
26
|
+
|
|
27
|
+
- **Baseline (no-AVX) builds** — New platform packages for older x64 CPUs without AVX instruction set support:
|
|
28
|
+
- `@legna-lnc/legnacode-darwin-x64-baseline` — macOS Intel (pre-2011 or Hackintosh without AVX)
|
|
29
|
+
- `@legna-lnc/legnacode-linux-x64-baseline` — Linux x64 servers/VMs without AVX
|
|
30
|
+
- Fixes `warn: CPU lacks AVX support, strange crashes may occur` error
|
|
31
|
+
- Install: `npm i -g @legna-lnc/legnacode-darwin-x64-baseline` (use directly, not via main package)
|
|
32
|
+
|
|
33
|
+
## [1.4.8] - 2026-04-17
|
|
34
|
+
|
|
35
|
+
### Features
|
|
36
|
+
|
|
37
|
+
- **AtomCode intelligence fusion (Layer A)** — Lightweight agent intelligence, zero new dependencies:
|
|
38
|
+
- **Pangu CJK spacing** — Auto-inserts spaces between CJK and ASCII in Markdown rendering
|
|
39
|
+
- **Negative feedback detection** — Detects frustration ("still broken"/"错了"/"まだ壊れ"), injects strategy-shift hint (EN/ZH/JA)
|
|
40
|
+
- **Tool call loop detection** — Same (tool, args) 3+ times → blocks. Resets per user message
|
|
41
|
+
- **Error file pre-injection** — Bash fail → extracts file paths from stderr, auto-reads first 30 lines
|
|
42
|
+
- **First-read full file** — First encounter ignores offset/limit, forces full read
|
|
43
|
+
|
|
44
|
+
- **OpenAI-compatible bridge adapter (Layer B1)** — Full Anthropic ↔ OpenAI format translation:
|
|
45
|
+
- Message format: `tool_use` ↔ `tool_calls`, `tool_result` ↔ `role: "tool"`
|
|
46
|
+
- Tool schema: `input_schema` ↔ `function.parameters`
|
|
47
|
+
- JSON repair for weak models (markdown fences, trailing commas, unbalanced brackets)
|
|
48
|
+
- Supports: OpenAI, DeepSeek, Qwen, GLM, SiliconFlow, Ollama, vLLM, LM Studio
|
|
49
|
+
- Activate: `OPENAI_COMPAT_BASE_URL` + `OPENAI_COMPAT_API_KEY` env vars
|
|
50
|
+
|
|
51
|
+
- **Code Graph (Layer B2)** — Regex-based symbol index + file dependency graph:
|
|
52
|
+
- Languages: TypeScript/TSX, JavaScript, Python, Go, Rust
|
|
53
|
+
- Incremental mtime updates, persisted to `<cwd>/.legna/.palace/graph.json`
|
|
54
|
+
- **Wired:** auto-builds on session start, injects file summaries into prefetch context
|
|
55
|
+
|
|
56
|
+
- **Parallel File Edit (Layer B3)** — "One sub-agent per file" execution model:
|
|
57
|
+
- Target file full text + sibling skeletons + interface contracts
|
|
58
|
+
- **Wired:** integrated into `/dispatch` skill prompt with parallel edit instructions
|
|
59
|
+
|
|
60
|
+
- **Workflow Engine (Layer B4)** — Structured step execution:
|
|
61
|
+
- Markdown `## Step N:` format with checks, failure handling, dependencies
|
|
62
|
+
- **Wired:** WorkflowTool now parses steps, shows status, substitutes args
|
|
63
|
+
|
|
64
|
+
- **/undo command** — Reverts the last file edit (Edit or Write tool):
|
|
65
|
+
- Tracks original content before each edit, max 20 entries per session
|
|
66
|
+
- New file creation → undo deletes the file
|
|
67
|
+
|
|
68
|
+
- **Cross-session knowledge persistence** — Auto-writes `<cwd>/.legna/knowledge.md`:
|
|
69
|
+
- Extracts key decisions/actions from last 10 assistant messages on session end
|
|
70
|
+
- Appends timestamped entries, caps at 50KB
|
|
71
|
+
|
|
72
|
+
- **Enhanced compiler error detection** — Extended error file pre-injection:
|
|
73
|
+
- Now matches compiler-style paths (`file.ts:42`, `file.py(10)`) in addition to standard paths
|
|
74
|
+
|
|
75
|
+
## [1.4.7] - 2026-04-16
|
|
8
76
|
|
|
9
77
|
### Features
|
|
10
78
|
|
|
@@ -21,7 +89,7 @@ All notable changes to LegnaCode CLI will be documented in this file.
|
|
|
21
89
|
- Modified `src/memdir/vectorStore/drawerStore.ts` — Schema migration (4 new columns), content-hash dedup in upsert, relevance feedback in search, time decay in search + topByImportance
|
|
22
90
|
- Modified `src/memdir/vectorStore/exchangeExtractor.ts` — `stripPrivate()` applied before pair extraction
|
|
23
91
|
|
|
24
|
-
## [1.4.6] - 2026-04-
|
|
92
|
+
## [1.4.6] - 2026-04-16
|
|
25
93
|
|
|
26
94
|
### Bug Fixes
|
|
27
95
|
|
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
**An AI-powered terminal programming assistant, supercharged.**
|
|
6
6
|
|
|
7
|
-
[](./CHANGELOG.md)
|
|
8
8
|
[](#platform-support)
|
|
9
9
|
[](./LICENSE)
|
|
10
10
|
[](https://github.com/anthropics/claude-code)
|
|
@@ -33,6 +33,9 @@ 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.0** | Fix REPL startup deadlock; remove /undo static import; all AtomCode features fully wired |
|
|
37
|
+
| **1.4.9** | Baseline (no-AVX) builds for older x64 CPUs (darwin-x64-baseline, linux-x64-baseline) |
|
|
38
|
+
| **1.4.8** | AtomCode fusion (Pangu CJK spacing, frustration detection, loop guard, error file injection, first-read full) |
|
|
36
39
|
| **1.4.7** | claude-mem fusion (content-hash dedup, token economics, relevance feedback, 90-day decay, privacy tags) |
|
|
37
40
|
| **1.4.6** | OML skill crash fix; plans + memory → project-local; compound engineering fusion |
|
|
38
41
|
| **1.4.5** | OpenViking content tiering (L0/L1/L2 degradation + budget-capped injection) |
|
|
@@ -154,6 +157,20 @@ npm install -g @legna-lnc/legnacode --registry=https://registry.npmjs.org
|
|
|
154
157
|
|
|
155
158
|
Once installed, the `legna` command is available in any directory. It automatically downloads the precompiled binary for your platform (supports macOS arm64/x64, Linux x64/arm64, Windows x64).
|
|
156
159
|
|
|
160
|
+
### Older CPUs without AVX
|
|
161
|
+
|
|
162
|
+
If you see `warn: CPU lacks AVX support, strange crashes may occur`, install the baseline build instead:
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
# macOS Intel (pre-2011 or Hackintosh without AVX)
|
|
166
|
+
npm i -g @legna-lnc/legnacode-darwin-x64-baseline
|
|
167
|
+
|
|
168
|
+
# Linux x64 (older servers/VMs without AVX)
|
|
169
|
+
npm i -g @legna-lnc/legnacode-linux-x64-baseline
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
The baseline binary is in `node_modules/@legna-lnc/legnacode-<platform>-baseline/bin/legna`. Add it to your PATH or create an alias.
|
|
173
|
+
|
|
157
174
|
```bash
|
|
158
175
|
# Verify installation
|
|
159
176
|
legna --version
|
package/README.zh-CN.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
**AI 驱动的终端编程助手,全面增强。**
|
|
6
6
|
|
|
7
|
-
[](./CHANGELOG.zh-CN.md)
|
|
8
8
|
[](#平台支持)
|
|
9
9
|
[](./LICENSE)
|
|
10
10
|
[](https://github.com/anthropics/claude-code)
|
|
@@ -33,6 +33,9 @@ LegnaCode 基于 [Claude Code CLI](https://github.com/anthropics/claude-code)
|
|
|
33
33
|
|
|
34
34
|
| 版本 | 摘要 |
|
|
35
35
|
|------|------|
|
|
36
|
+
| **1.5.0** | 修复 REPL 启动死锁;移除 /undo 静态导入;AtomCode 全部特性完整接线 |
|
|
37
|
+
| **1.4.9** | Baseline(无 AVX)构建,支持老款 x64 CPU(darwin-x64-baseline、linux-x64-baseline) |
|
|
38
|
+
| **1.4.8** | AtomCode 融合(Pangu CJK 间距、挫败检测、循环守卫、错误文件注入、首次全文读取) |
|
|
36
39
|
| **1.4.7** | claude-mem 融合(content-hash 去重、token 经济学、使用反馈、90 天衰减、隐私标签) |
|
|
37
40
|
| **1.4.6** | OML skill 崩溃修复;计划+记忆改为项目本地;compound engineering 融合 |
|
|
38
41
|
| **1.4.5** | OpenViking 内容分级融合(L0/L1/L2 降级 + 预算封顶注入) |
|
|
@@ -154,6 +157,20 @@ npm install -g @legna-lnc/legnacode --registry=https://registry.npmjs.org
|
|
|
154
157
|
|
|
155
158
|
安装后即可在任意目录使用 `legna` 命令。会自动下载当前平台的预编译二进制(支持 macOS arm64/x64、Linux x64/arm64、Windows x64)。
|
|
156
159
|
|
|
160
|
+
### 老款 CPU(无 AVX 指令集)
|
|
161
|
+
|
|
162
|
+
如果看到 `warn: CPU lacks AVX support, strange crashes may occur`,请安装 baseline 版本:
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
# macOS Intel(2011 年前或无 AVX 的黑苹果)
|
|
166
|
+
npm i -g @legna-lnc/legnacode-darwin-x64-baseline
|
|
167
|
+
|
|
168
|
+
# Linux x64(无 AVX 的老服务器/虚拟机)
|
|
169
|
+
npm i -g @legna-lnc/legnacode-linux-x64-baseline
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
baseline 二进制位于 `node_modules/@legna-lnc/legnacode-<platform>-baseline/bin/legna`,添加到 PATH 或创建别名即可使用。
|
|
173
|
+
|
|
157
174
|
```bash
|
|
158
175
|
# 验证安装
|
|
159
176
|
legna --version
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@legna-lnc/legnacode",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0",
|
|
4
4
|
"description": "LegnaCode — legna.lnc's official CLI for coding assistance",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -142,11 +142,13 @@
|
|
|
142
142
|
"bun": ">=1.2.0"
|
|
143
143
|
},
|
|
144
144
|
"optionalDependencies": {
|
|
145
|
-
"@legna-lnc/legnacode-darwin-arm64": "1.
|
|
146
|
-
"@legna-lnc/legnacode-darwin-x64": "1.
|
|
147
|
-
"@legna-lnc/legnacode-
|
|
148
|
-
"@legna-lnc/legnacode-linux-
|
|
149
|
-
"@legna-lnc/legnacode-
|
|
150
|
-
"@legna-lnc/legnacode-
|
|
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"
|
|
151
153
|
}
|
|
152
154
|
}
|