@uselemma/opencode 0.1.0 → 0.1.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 CHANGED
@@ -2,7 +2,18 @@
2
2
 
3
3
  `@uselemma/opencode` records one complete Lemma trace for each OpenCode user turn. It uses OpenCode's native plugin hooks and event stream directly. It does not install an MCP server or require an npm-published plugin for local use.
4
4
 
5
- ## Local setup
5
+ ## Install
6
+
7
+ ```bash
8
+ pnpm dlx @uselemma/opencode setup
9
+ ```
10
+
11
+ The setup command installs the bundled plugin into
12
+ `~/.config/opencode/plugins/uselemma-opencode.js`, opens project-scoped Lemma
13
+ authorization, and stores the returned credential under
14
+ `~/.config/opencode/lemma`.
15
+
16
+ ## Local development
6
17
 
7
18
  From a Lemma checkout:
8
19
 
@@ -13,7 +24,7 @@ pnpm --filter @uselemma/opencode build
13
24
  node plugins/lemma-opencode/scripts/setup.mjs
14
25
  ```
15
26
 
16
- Setup copies the bundled plugin into `~/.config/opencode/plugins/uselemma-opencode.js`, opens project-scoped Lemma authorization, and stores the resulting credential under `~/.config/opencode/lemma`. OpenCode automatically loads global plugin files at startup.
27
+ OpenCode automatically loads global plugin files at startup.
17
28
 
18
29
  For development:
19
30
 
@@ -34,10 +45,6 @@ Use `--config-dir PATH` and `--data-dir PATH` for isolated verification. Use `--
34
45
 
35
46
  Sensitive keys, authorization values, common provider tokens, credential-bearing URLs, and PEM material are removed before a turn is queued. Failed deliveries remain in a private pending directory and retry on the next plugin startup or completed turn. A turn keeps the API and project scope active when capture started. Rotating credentials for the same project preserves delivery, while switching projects leaves the older trace queued instead of misrouting it.
36
47
 
37
- ## Distribution
38
-
39
- OpenCode supports both local plugin files and npm package configuration. The setup command uses the local-file path so it can be verified from a checkout or packed tarball before any public npm publication. Public npm release and ecosystem listing are separate release steps.
40
-
41
48
  ## Verification
42
49
 
43
50
  ```bash
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uselemma/opencode",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Lemma SDK tracing for OpenCode coding-agent sessions",
5
5
  "license": "MIT",
6
6
  "type": "module",
package/runtime/lemma.mjs CHANGED
@@ -1,4 +1,6 @@
1
1
  // @uselemma/opencode managed plugin
2
+ import { createRequire as __lemmaCreateRequire } from "node:module";
3
+ const require = __lemmaCreateRequire(import.meta.url);
2
4
  var __create = Object.create;
3
5
  var __defProp = Object.defineProperty;
4
6
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;