@opencode-ai/plugin
Advanced tools
+1
-5
| import { tool } from "./tool"; | ||
| export const ExamplePlugin = async (ctx) => { | ||
| return { | ||
| permission: {}, | ||
| tool: { | ||
| mytool: tool({ | ||
| description: "This is a custom tool tool", | ||
| description: "This is a custom tool", | ||
| args: { | ||
@@ -16,6 +15,3 @@ foo: tool.schema.string().describe("foo"), | ||
| }, | ||
| async "chat.params"(_input, output) { | ||
| output.topP = 1; | ||
| }, | ||
| }; | ||
| }; |
+2
-2
| { | ||
| "$schema": "https://json.schemastore.org/package.json", | ||
| "name": "@opencode-ai/plugin", | ||
| "version": "0.0.0-dev-202510311845", | ||
| "version": "0.0.0-dev-202510311908", | ||
| "type": "module", | ||
@@ -24,3 +24,3 @@ "scripts": { | ||
| "dependencies": { | ||
| "@opencode-ai/sdk": "0.0.0-dev-202510311845", | ||
| "@opencode-ai/sdk": "0.0.0-dev-202510311908", | ||
| "zod": "4.1.8" | ||
@@ -27,0 +27,0 @@ }, |
8078
-1.4%253
-1.56%+ Added
- Removed