@asobacloud/nehanda 0.6.0 → 0.6.1
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/README.md +4 -0
- package/lib/laya_sidecar.mjs +6 -3
- package/lib/scripts/ensure-laya-env.sh +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -497,6 +497,10 @@ node tests/unit/ui_legibility_behavioral.mjs
|
|
|
497
497
|
|
|
498
498
|
## Changelog
|
|
499
499
|
|
|
500
|
+
### 0.6.1
|
|
501
|
+
|
|
502
|
+
- **Fix: Laya provisioning smoke test (`lib/scripts/ensure-laya-env.sh`):** The `Router()` constructibility check was missing `import sys`, causing `npm install` to fail with `NameError: name 'sys' is not defined` even when all packages installed successfully. The marker file was never written, leaving the CLI in a permanently broken state despite a complete venv. Fixed.
|
|
503
|
+
|
|
500
504
|
### 0.6.0
|
|
501
505
|
|
|
502
506
|
- **Provider API Key Management (`lib/auth.mjs`, `lib/orchestrate.mjs`, `bin/nehanda-ui.mjs`):** OpenRouter, ZhipuAI (z.ai), and generic OpenAI-compatible providers can now be configured entirely from within the REPL. `/key openrouter sk-or-v1-...` saves the key to the secure file and auto-sets `base_url`. `/key zhipu sk-zai-...` saves the ZhipuAI key. `/config` now shows compat and Zhipu key status (masked). Fixes a pre-existing gap where `resolveZhipuApiKey()` existed in `lib/auth.mjs` but was never called by the orchestrator — the `zhipu` provider fell through to `OPENAI_API_KEY`. Closes #1.
|
package/lib/laya_sidecar.mjs
CHANGED
|
@@ -54,6 +54,10 @@ function attachChild(c) {
|
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
})
|
|
57
|
+
// Unref after listener attachment — adding a 'data' listener re-refs the stream,
|
|
58
|
+
// so unref must come after to actually take effect. This prevents the stdout pipe
|
|
59
|
+
// from holding the Node event loop open when the sidecar runs as a background daemon.
|
|
60
|
+
c.stdout.unref()
|
|
57
61
|
c.on('error', err => {
|
|
58
62
|
process.stderr.write(`[laya-sidecar] worker error: ${err.message}\n`)
|
|
59
63
|
child = null
|
|
@@ -88,9 +92,8 @@ function ensureChild() {
|
|
|
88
92
|
env: { ...process.env },
|
|
89
93
|
})
|
|
90
94
|
child.unref()
|
|
91
|
-
//
|
|
92
|
-
//
|
|
93
|
-
child.stdout.unref()
|
|
95
|
+
// stdin and stderr unreffed here; stdout is unreffed inside attachChild
|
|
96
|
+
// after its 'data' listener is attached (re-ref order matters).
|
|
94
97
|
child.stdin.unref()
|
|
95
98
|
child.stderr.unref()
|
|
96
99
|
restartCount += 1
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@asobacloud/nehanda",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Agentic terminal REPL and single-process engine for governed AI deep research and software development. Connects to Nehanda v3, OpenRouter, Ollama, LM Studio, ZhipuAI, or any OpenAI-compatible API. Includes Laya System-1 control plane for memory management, pre-execution safety gating, and intent-driven instruction shaping.",
|
|
6
6
|
"keywords": [
|