@joe-broadhead/opencode-plaud 0.0.5 → 0.0.6

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 CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project are documented here. The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and versions follow [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
4
4
 
5
+ ## [0.0.6] - 2026-11-05
6
+
7
+ ### Changed
8
+
9
+ - `opencode-plaud-export` spells out the `list_files` call that finds a recording by date or name, with `start_at` in UTC, so it needs no catalogue search when the main skill isn't loaded. It says that the export itself refuses an existing file with `EXPORT_EXISTS`, so there is no need to list the folder first. When several recordings match, it exports only after the user answers, and never a guess or every match.
10
+ - Scripts use a session created for them. `opencode-plaud` and `docs/scripting.md` say to create the script's session with `opencode api post /api/session` and keep `data.id`, and never to borrow a session found in history or a session list, which would run as that session's agent, under its rules.
11
+
5
12
  ## [0.0.5] - 2026-11-05
6
13
 
7
14
  ### Added
package/dist/index.js CHANGED
@@ -6776,7 +6776,7 @@ ${status.permissionsBlock.map((rule2) => ` ${JSON.stringify(rule2)}`).join(",\n
6776
6776
 
6777
6777
  // src/version.ts
6778
6778
  var PLUGIN_ID = "plaud.recordings";
6779
- var PLUGIN_VERSION = "0.0.5";
6779
+ var PLUGIN_VERSION = "0.0.6";
6780
6780
  var SUPPORTED_HOSTS = ">=2.2.3 <2.3.0";
6781
6781
  var TESTED_HOSTS = ["2.2.3", "2.2.4", "2.2.5"];
6782
6782
  var RELEASE = /^(\d+)\.(\d+)\.(\d+)$/;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@joe-broadhead/opencode-plaud",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "description": "Unofficial OpenCode plugin for Plaud recordings",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -88,8 +88,10 @@ return page.data.map((r) => ({ id: r.id, name: r.name, start: r.start_at + "Z",
88
88
  For a job without a model, such as a cron job: `opencode api post /api/rpc/plaud.recordings.tools/<method>`, where the
89
89
  methods are the five reads, `recent` and `describe`. The body is
90
90
  `{"input":{"sessionID":"<session>","account":"work","input":<the tool's input>}}`, with `account` optional. The
91
- script runs as the session's agent, under its rules, and an ask is refused. Scripts get no export, no other Plaud
92
- tool and no link.
91
+ script runs as the session's agent, under its rules, and an ask is refused. So a script, or a test of one, uses a
92
+ session created for it: `opencode api post /api/session -d '{"title":"<job>","agent":"build"}'`, keeping `data.id`.
93
+ Never borrow a session found through history or a list, which would run as its agent. Scripts get no export, no
94
+ other Plaud tool and no link.
93
95
 
94
96
  ## Sign-in and errors
95
97
 
@@ -23,10 +23,13 @@ It returns `{ path, bytes, sha256 }`, never the content.
23
23
 
24
24
  ## Decide
25
25
 
26
- 1. **Find the id** with `plaud_recent` (the newest: `tools.plaud.recent({ limit: 1 })` in Code Mode, a plain object)
27
- or `list_files` (a date or a name; see `opencode-plaud`). These Code Mode calls are exact, so no catalogue search
28
- is needed. If several recordings match,
29
- such as two on one day, list them with their title, start time and length, and ask which one before exporting.
26
+ 1. **Find the id** with `plaud_recent` for the newest (`tools.plaud.recent({ limit: 1 })` in Code Mode, a plain
27
+ object), or `list_files` for a date or a name:
28
+ `tools.plaud.list_files({ date_from: "YYYY-MM-DD", date_to: "YYYY-MM-DD", page_size: 50 })`, both dates inclusive;
29
+ for a name, add `query: "name"` or drop the dates. Its `start_at` is UTC without a `Z`. These Code Mode calls are exact, so
30
+ no catalogue search is needed. If several recordings match, such as two on one day, list them with their title,
31
+ start time and length, and ask which one. Export only after the user answers: if you can't ask, end your answer
32
+ with the question, and never export a guess or every match instead.
30
33
  2. **Pick the kind.** Asked to save or download the audio: `kind: "audio"`, at once. The export reads `get_file`
31
34
  itself, so don't call `get_file` first. Asked only for a link: say Plaud's links are withheld and offer to save
32
35
  the audio, and export when they agree. Summary or action items: `kind: "note"`. A transcript: omit `block` for the raw one,
@@ -38,7 +41,8 @@ It returns `{ path, bytes, sha256 }`, never the content.
38
41
  ~~~json
39
42
  { "plugins": [{ "package": "@joe-broadhead/opencode-plaud", "options": { "exportRoots": ["~/Plaud", "~/Documents"] } }] }
40
43
  ~~~
41
- 4. **Pass `overwrite: true`** only when the user asked to replace that file.
44
+ 4. **Pass `overwrite: true`** only when the user asked to replace that file. The export itself refuses an existing
45
+ file with `EXPORT_EXISTS`, so don't list the folder first.
42
46
 
43
47
  ## The ask
44
48