@letterblack/lbe-sdk 1.0.1 → 1.0.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/README.md +6 -3
- package/dist/mcp-server.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,6 +6,8 @@ LBE SDK exposes a WASM-authoritative execution boundary for local AI agent
|
|
|
6
6
|
governance. JavaScript is transport only: it verifies the engine hash, passes a
|
|
7
7
|
UTF-8 JSON request into WASM, and returns the UTF-8 JSON response.
|
|
8
8
|
|
|
9
|
+
Every AI action passes through a local gate before it can execute.
|
|
10
|
+
|
|
9
11
|
Everything runs on your machine. No cloud service is required.
|
|
10
12
|
|
|
11
13
|
## Install
|
|
@@ -33,17 +35,18 @@ validation and decisions originate in `dist/lbe_engine.wasm`.
|
|
|
33
35
|
import crypto from 'node:crypto';
|
|
34
36
|
import { execute } from '@letterblack/lbe-sdk';
|
|
35
37
|
|
|
36
|
-
const
|
|
38
|
+
const buildRequest = (name, payload = {}) => ({
|
|
37
39
|
version: '1.0',
|
|
38
40
|
request_id: crypto.randomUUID(),
|
|
39
41
|
timestamp: Math.floor(Date.now() / 1000),
|
|
40
42
|
actor: { id: 'agent:local', role: 'agent' },
|
|
41
|
-
intent: { type: 'command', name
|
|
43
|
+
intent: { type: 'command', name, payload },
|
|
42
44
|
context: { workspace: process.cwd(), env: {}, history: [] },
|
|
43
45
|
constraints: { policy_mode: 'strict', timeout_ms: 5000 },
|
|
44
46
|
auth: { signature: 'provided-by-host', nonce: crypto.randomUUID() }
|
|
45
|
-
})
|
|
47
|
+
});
|
|
46
48
|
|
|
49
|
+
const output = execute(JSON.stringify(buildRequest('status')));
|
|
47
50
|
console.log(JSON.parse(output));
|
|
48
51
|
```
|
|
49
52
|
|
package/dist/mcp-server.js
CHANGED