@corenel/term 0.8.0 → 0.8.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/dist/ink/banner.d.ts +1 -1
- package/dist/ink/banner.d.ts.map +1 -1
- package/dist/ink/index.js +3 -2
- package/package.json +4 -4
package/dist/ink/banner.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type NamespacedTool } from '@corenel/harness/tools/namespaces';
|
|
2
|
-
import type
|
|
2
|
+
import { type Policy } from '@corenel/protocol';
|
|
3
3
|
import { type PolicySource } from '../policySource';
|
|
4
4
|
/** The posture phrase, derived from the same `resolveLevel()` the loop's own
|
|
5
5
|
* `PermissionService` calls before every tool check. Covers the four shapes
|
package/dist/ink/banner.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"banner.d.ts","sourceRoot":"","sources":["../../src/ink/banner.ts"],"names":[],"mappings":"AAcA,OAAO,EAAsC,KAAK,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAC5G,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"banner.d.ts","sourceRoot":"","sources":["../../src/ink/banner.ts"],"names":[],"mappings":"AAcA,OAAO,EAAsC,KAAK,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAC5G,OAAO,EAAc,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAe,KAAK,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAmCjE;;;iDAGiD;AACjD,wBAAgB,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAW9C;AAwBD,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,YAAY,CAAC;IACrB,KAAK,EAAE,SAAS,cAAc,EAAE,CAAC;IACjC,GAAG,EAAE,MAAM,CAAC;IACZ,4EAA4E;IAC5E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,8EAA8E;IAC9E,KAAK,EAAE,OAAO,CAAC;CAChB;AAED;yCACyC;AACzC,wBAAgB,WAAW,CAAC,IAAI,EAAE,aAAa,GAAG,MAAM,CAuCvD;AAED,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,KAAK,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED;;;uCAGuC;AACvC,wBAAgB,YAAY,CAAC,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,SAAS,CAAC,GAAG,MAAM,CAInG;AAED;;iDAEiD;AACjD,wBAAgB,WAAW,CAAC,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,SAAS,CAAC,GAAG,IAAI,CAGhG"}
|
package/dist/ink/index.js
CHANGED
|
@@ -751,6 +751,7 @@ function primeScroll(out, opts) {
|
|
|
751
751
|
// src/ink/banner.ts
|
|
752
752
|
import { PermissionService } from "@corenel/harness/guardrail/permission-service";
|
|
753
753
|
import { NAMESPACE_LABELS, resolveNamespace } from "@corenel/harness/tools/namespaces";
|
|
754
|
+
import { needsHuman } from "@corenel/protocol";
|
|
754
755
|
var ART = [
|
|
755
756
|
" \u2588\u2588\u2588\u2588\u2588\u2588 \u2588\u2588\u2588\u2588\u2588\u2588 \u2588\u2588\u2588\u2588\u2588\u2588 \u2588\u2588\u2588\u2588\u2588\u2588\u2588 \u2588\u2588\u2588 \u2588\u2588 \u2588\u2588\u2588\u2588\u2588\u2588\u2588 \u2588\u2588",
|
|
756
757
|
"\u2588\u2588 \u2588\u2588 \u2588\u2588 \u2588\u2588 \u2588\u2588 \u2588\u2588 \u2588\u2588\u2588\u2588 \u2588\u2588 \u2588\u2588 \u2588\u2588",
|
|
@@ -766,11 +767,11 @@ var WRITE_SUBJECT = { name: "write_file", address: "fs:write_file", mutates: tru
|
|
|
766
767
|
function posture(policy) {
|
|
767
768
|
const permission = new PermissionService({ policy });
|
|
768
769
|
const shellLevel = permission.resolveLevel(SHELL_SUBJECT);
|
|
769
|
-
if (shellLevel
|
|
770
|
+
if (needsHuman(shellLevel)) return "shell asks first";
|
|
770
771
|
if (shellLevel === "deny") return "shell off";
|
|
771
772
|
const writeLevel = permission.resolveLevel(WRITE_SUBJECT);
|
|
772
773
|
if (writeLevel === "allow") return "nothing asks -- unattended";
|
|
773
|
-
if (writeLevel
|
|
774
|
+
if (needsHuman(writeLevel)) return "shell runs, writes ask";
|
|
774
775
|
return "shell runs, writes off";
|
|
775
776
|
}
|
|
776
777
|
function toolBreakdown(tools) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@corenel/term",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Corenel's terminal face — a headless chat controller plus its Ink views. `./session` is ink-free and shared with the CLI's readline fallback; only `./ink` pulls React. dist/ is bundled (see build.mjs), but @corenel/harness and @corenel/protocol stay EXTERNAL to that bundle — they are real runtime dependencies, declared below, so the CLI and term share exactly one harness module instance (see build.mjs for why two instances is a governance hole, not a cosmetic bug).",
|
|
6
6
|
"exports": {
|
|
@@ -46,8 +46,8 @@
|
|
|
46
46
|
"ink-text-input": "^6.0.0",
|
|
47
47
|
"openai": "^4.77.0",
|
|
48
48
|
"react": "^18.3.1",
|
|
49
|
-
"@corenel/
|
|
50
|
-
"@corenel/
|
|
49
|
+
"@corenel/protocol": "0.15.0",
|
|
50
|
+
"@corenel/harness": "0.16.0"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
53
|
"@types/node": "^24.13.1",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"esbuild": "^0.21.5",
|
|
56
56
|
"ink-testing-library": "^4.0.0",
|
|
57
57
|
"typescript": "^5.9.3",
|
|
58
|
-
"@corenel/tools-node": "0.
|
|
58
|
+
"@corenel/tools-node": "0.8.1"
|
|
59
59
|
},
|
|
60
60
|
"license": "Elastic-2.0",
|
|
61
61
|
"engines": {
|