opencode-swarm 6.21.2 → 6.22.0
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 +56 -4
- package/dist/agents/critic.d.ts +1 -0
- package/dist/agents/explorer.d.ts +1 -0
- package/dist/background/event-bus.d.ts +1 -1
- package/dist/cli/index.js +19 -7
- package/dist/config/schema.d.ts +21 -0
- package/dist/hooks/curator-drift.d.ts +30 -0
- package/dist/hooks/curator-types.d.ts +99 -0
- package/dist/hooks/curator.d.ts +70 -0
- package/dist/index.js +953 -282
- package/dist/session/snapshot-reader.d.ts +8 -0
- package/dist/session/snapshot-writer.d.ts +1 -0
- package/dist/tools/create-tool.d.ts +3 -3
- package/package.json +1 -1
|
@@ -21,6 +21,14 @@ export declare function readSnapshot(directory: string): Promise<SnapshotData |
|
|
|
21
21
|
* Does NOT touch activeToolCalls or pendingEvents (remain at defaults).
|
|
22
22
|
*/
|
|
23
23
|
export declare function rehydrateState(snapshot: SnapshotData): void;
|
|
24
|
+
/**
|
|
25
|
+
* Reconcile task workflow states from plan.json for all active sessions.
|
|
26
|
+
* Seeds completed plan tasks to 'tests_run' and in_progress tasks to 'coder_delegated'.
|
|
27
|
+
* Best-effort: returns silently on any file/parse error. NEVER throws.
|
|
28
|
+
*
|
|
29
|
+
* @param directory - The project root directory containing .swarm/plan.json
|
|
30
|
+
*/
|
|
31
|
+
export declare function reconcileTaskStatesFromPlan(directory: string): Promise<void>;
|
|
24
32
|
/**
|
|
25
33
|
* Load snapshot from disk and rehydrate swarmState.
|
|
26
34
|
* Called on plugin init to restore state from previous session.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { tool } from '@opencode-ai/plugin';
|
|
1
|
+
import { type ToolContext, tool } from '@opencode-ai/plugin';
|
|
2
2
|
/**
|
|
3
3
|
* Options for creating a swarm tool.
|
|
4
4
|
* The args type is inferred from what you pass to the tool() call.
|
|
@@ -6,10 +6,10 @@ import { tool } from '@opencode-ai/plugin';
|
|
|
6
6
|
export interface SwarmToolOptions<Args extends Record<string, unknown>> {
|
|
7
7
|
description: string;
|
|
8
8
|
args: Args;
|
|
9
|
-
execute: (args: Args, directory: string) => Promise<string>;
|
|
9
|
+
execute: (args: Args, directory: string, ctx?: ToolContext) => Promise<string>;
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Creates a swarm tool with automatic working directory injection.
|
|
13
|
-
* Wraps the @opencode-ai/plugin/tool factory to always inject `directory` into tool execute callbacks.
|
|
13
|
+
* Wraps the @opencode-ai/plugin/tool factory to always inject `directory` and `ctx` into tool execute callbacks.
|
|
14
14
|
*/
|
|
15
15
|
export declare function createSwarmTool<Args extends Record<string, unknown>>(opts: SwarmToolOptions<Args>): ReturnType<typeof tool>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "opencode-swarm",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.22.0",
|
|
4
4
|
"description": "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|