@opencode-ai/plugin 0.0.0-next-17149 → 0.0.0-next-17151
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.
|
@@ -2,5 +2,5 @@ import type { Effect, Scope } from "effect";
|
|
|
2
2
|
export interface Registration {
|
|
3
3
|
readonly dispose: Effect.Effect<void>;
|
|
4
4
|
}
|
|
5
|
-
export type Hooks<Spec> = <Name extends keyof Spec>(name: Name, callback: (input: Spec[Name]) => Effect.Effect<void>) => Effect.Effect<Registration, never, Scope.Scope>;
|
|
5
|
+
export type Hooks<Spec, Failures extends Record<keyof Spec, unknown> = Record<keyof Spec, never>> = <Name extends keyof Spec>(name: Name, callback: (input: Spec[Name]) => Effect.Effect<void, Failures[Name]>) => Effect.Effect<Registration, never, Scope.Scope>;
|
|
6
6
|
export type Transform<Input> = (callback: (input: Input) => void) => Effect.Effect<Registration, never, Scope.Scope>;
|
package/dist/effect/tool.d.ts
CHANGED
|
@@ -30,7 +30,11 @@ export interface ToolHooks {
|
|
|
30
30
|
error: Tool.Error;
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
|
+
export interface ToolFailures extends Record<keyof ToolHooks, unknown> {
|
|
34
|
+
readonly "execute.before": Tool.Error;
|
|
35
|
+
readonly "execute.after": never;
|
|
36
|
+
}
|
|
33
37
|
export interface ToolDomain {
|
|
34
38
|
readonly transform: Transform<ToolDraft>;
|
|
35
|
-
readonly hook: Hooks<ToolHooks>;
|
|
39
|
+
readonly hook: Hooks<ToolHooks, ToolFailures>;
|
|
36
40
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@opencode-ai/plugin",
|
|
4
|
-
"version": "0.0.0-next-
|
|
4
|
+
"version": "0.0.0-next-17151",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"scripts": {
|
|
@@ -36,16 +36,16 @@
|
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@ai-sdk/provider": "3.0.8",
|
|
39
|
-
"@opencode-ai/ai": "0.0.0-next-
|
|
40
|
-
"@opencode-ai/client": "0.0.0-next-
|
|
41
|
-
"@opencode-ai/schema": "0.0.0-next-
|
|
39
|
+
"@opencode-ai/ai": "0.0.0-next-17151",
|
|
40
|
+
"@opencode-ai/client": "0.0.0-next-17151",
|
|
41
|
+
"@opencode-ai/schema": "0.0.0-next-17151",
|
|
42
42
|
"@opencode-ai/sdk": "1.18.5",
|
|
43
43
|
"@standard-schema/spec": "1.1.0",
|
|
44
44
|
"effect": "4.0.0-beta.101",
|
|
45
45
|
"zod": "4.1.8"
|
|
46
46
|
},
|
|
47
47
|
"peerDependencies": {
|
|
48
|
-
"@opencode-ai/theme": "0.0.0-next-
|
|
48
|
+
"@opencode-ai/theme": "0.0.0-next-17151",
|
|
49
49
|
"@opentui/core": "0.0.0-20260808-9ecf7c0a",
|
|
50
50
|
"@opentui/keymap": "0.0.0-20260808-9ecf7c0a",
|
|
51
51
|
"@opentui/solid": "0.0.0-20260808-9ecf7c0a",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
}
|
|
70
70
|
},
|
|
71
71
|
"devDependencies": {
|
|
72
|
-
"@opencode-ai/theme": "0.0.0-next-
|
|
72
|
+
"@opencode-ai/theme": "0.0.0-next-17151",
|
|
73
73
|
"@opentui/core": "0.0.0-20260808-9ecf7c0a",
|
|
74
74
|
"@opentui/keymap": "0.0.0-20260808-9ecf7c0a",
|
|
75
75
|
"@opentui/solid": "0.0.0-20260808-9ecf7c0a",
|