opencode-plugin-flow 4.4.0 → 5.1.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/CHANGELOG.md +90 -0
- package/README.md +60 -43
- package/dist/application/errors.d.ts +5 -0
- package/dist/application/flow-service.d.ts +339 -0
- package/dist/application/ports/evidence-artifact-store.d.ts +28 -0
- package/dist/application/ports/session-repository.d.ts +18 -0
- package/dist/application/ports/source-identity.d.ts +61 -0
- package/dist/application/replay/canonical-json.d.ts +7 -0
- package/dist/application/replay/contract.d.ts +2007 -0
- package/dist/application/replay/engine.d.ts +101 -0
- package/dist/application/replay/index.d.ts +7 -0
- package/dist/application/replay/privacy.d.ts +14 -0
- package/dist/{runtime → application}/schema.d.ts +1176 -370
- package/dist/cli.js +295 -2721
- package/dist/cli.js.map +7 -6
- package/dist/config-shared.d.ts +28 -14
- package/dist/config.d.ts +1 -1
- package/dist/distribution/legacy-cleanup.d.ts +25 -0
- package/dist/domain/feature-id.d.ts +3 -0
- package/dist/domain/limits.d.ts +1 -0
- package/dist/domain/orchestration-policy.d.ts +27 -0
- package/dist/domain/session.d.ts +355 -0
- package/dist/domain/transitions.d.ts +163 -0
- package/dist/domain/validation-command.d.ts +8 -0
- package/dist/guidance/catalog.d.ts +18 -0
- package/dist/guidance/ids.d.ts +4 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4495 -1817
- package/dist/index.js.map +30 -18
- package/dist/infrastructure/fs/evidence-artifact-store.d.ts +5 -0
- package/dist/infrastructure/fs/session-repository.d.ts +2 -0
- package/dist/infrastructure/fs/source-identity.d.ts +26 -0
- package/dist/infrastructure/fs/workspace-flow-service.d.ts +9 -0
- package/dist/{runtime → infrastructure/fs}/workspace.d.ts +12 -15
- package/dist/infrastructure/system/transition-environment.d.ts +2 -0
- package/dist/platform/opencode/config.d.ts +2 -0
- package/dist/{adapters → platform}/opencode/plugin.d.ts +1 -1
- package/dist/{adapters → platform}/opencode/sdk.d.ts +0 -1
- package/dist/platform/opencode/tools.d.ts +6 -0
- package/dist/prompt-model-evaluation.d.ts +19 -30
- package/dist/prompt-quality.d.ts +1 -1
- package/dist/version.d.ts +1 -0
- package/package.json +18 -11
- package/dist/adapters/opencode/config.d.ts +0 -3
- package/dist/adapters/opencode/tools.d.ts +0 -322
- package/dist/distribution/flow-skill-definitions.d.ts +0 -9
- package/dist/distribution/sync.d.ts +0 -69
- package/dist/runtime/api.d.ts +0 -211
- package/dist/runtime/time.d.ts +0 -2
- package/dist/runtime/transitions.d.ts +0 -230
- /package/dist/{runtime/json/strict-object.d.ts → infrastructure/fs/strict-json-object.d.ts} +0 -0
- /package/dist/{adapters → platform}/opencode/logging.d.ts +0 -0
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type EvidenceArtifactRef, type EvidenceArtifactStore } from "../../application/ports/evidence-artifact-store.js";
|
|
2
|
+
export declare function evidenceArtifactDirectory(workspace: string): string;
|
|
3
|
+
export declare function evidenceArtifactPath(workspace: string, ref: EvidenceArtifactRef): string;
|
|
4
|
+
export declare function evidenceArtifactRefForBytes(bytes: Uint8Array): EvidenceArtifactRef;
|
|
5
|
+
export declare function createFileEvidenceArtifactStore(workspace: string): EvidenceArtifactStore;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type SourceIdentityProvider } from "../../application/ports/source-identity.js";
|
|
2
|
+
/**
|
|
3
|
+
* Bounded budgets. Exceeding any of these fails closed with a bounded recovery
|
|
4
|
+
* response rather than reading an unbounded amount of source state.
|
|
5
|
+
*/
|
|
6
|
+
export declare const MAX_SOURCE_ENTRIES = 20000;
|
|
7
|
+
export declare const MAX_SOURCE_TOTAL_BYTES: number;
|
|
8
|
+
export declare const MAX_SOURCE_FILE_BYTES: number;
|
|
9
|
+
/**
|
|
10
|
+
* Create the authoritative source-identity provider for a workspace root.
|
|
11
|
+
*
|
|
12
|
+
* The digest binds:
|
|
13
|
+
* - Git: the HEAD commit, the canonical index (mode/object/stage/path), and the
|
|
14
|
+
* independent working-tree state (content, exec/symlink/gitlink type,
|
|
15
|
+
* index-only sparse absence, and deletions) for tracked and untracked
|
|
16
|
+
* non-ignored paths. Representing the index separately from the worktree
|
|
17
|
+
* distinguishes staged-only changes from equivalent unstaged trees. Sparse
|
|
18
|
+
* and dense materializations are intentionally distinct source states.
|
|
19
|
+
* - Non-Git: a deterministic full-tree manifest.
|
|
20
|
+
*
|
|
21
|
+
* Git's `--exclude-standard` supplies ignore semantics with no heuristic source
|
|
22
|
+
* exclusions; `.git/**` internals are never enumerated and `.flow/**` is always
|
|
23
|
+
* excluded. Measurement fails closed on unsafe symlinks, unreadable entries,
|
|
24
|
+
* resource overflow, and any workspace change observed while measuring.
|
|
25
|
+
*/
|
|
26
|
+
export declare function createFileSourceIdentityProvider(root: string): SourceIdentityProvider;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type FlowResponse, type FlowService } from "../../application/flow-service.js";
|
|
2
|
+
export declare function createWorkspaceFlowService(workspace: string): FlowService;
|
|
3
|
+
export declare function flowStatus(workspace: string, input?: unknown): Promise<FlowResponse>;
|
|
4
|
+
export declare function flowPlanSave(workspace: string, input: unknown): Promise<FlowResponse>;
|
|
5
|
+
export declare function flowPlanApprove(workspace: string): Promise<FlowResponse>;
|
|
6
|
+
export declare function flowRunStart(workspace: string, input: unknown): Promise<FlowResponse>;
|
|
7
|
+
export declare function flowFeatureComplete(workspace: string, input: unknown): Promise<FlowResponse>;
|
|
8
|
+
export declare function flowFeatureReset(workspace: string, input: unknown): Promise<FlowResponse>;
|
|
9
|
+
export declare function flowSessionClose(workspace: string, input: unknown): Promise<FlowResponse>;
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { Session } from "../../domain/session.js";
|
|
2
2
|
export declare class InvalidFlowWorkspaceRootError extends Error {
|
|
3
3
|
readonly code = "INVALID_FLOW_WORKSPACE_ROOT";
|
|
4
|
-
constructor(message: string);
|
|
4
|
+
constructor(message: string, options?: ErrorOptions);
|
|
5
|
+
}
|
|
6
|
+
export declare class UnsafeFlowWorkspaceLayoutError extends Error {
|
|
7
|
+
readonly code = "UNSAFE_FLOW_WORKSPACE_LAYOUT";
|
|
8
|
+
constructor(message: string, options?: ErrorOptions);
|
|
9
|
+
}
|
|
10
|
+
export declare class ArchiveCollisionError extends Error {
|
|
11
|
+
readonly code = "FLOW_ARCHIVE_COLLISION";
|
|
12
|
+
constructor(message: string, options?: ErrorOptions);
|
|
5
13
|
}
|
|
6
14
|
export declare function normalizeWorkspaceRoot(rawPath: string | undefined): string | null;
|
|
7
15
|
export declare function assertMutableWorkspaceRoot(rawPath: string): string;
|
|
@@ -11,26 +19,15 @@ export declare function resolveWorkspaceRoot(context: {
|
|
|
11
19
|
}): string;
|
|
12
20
|
export declare function flowDir(worktree: string): string;
|
|
13
21
|
export declare function sessionPath(worktree: string): string;
|
|
14
|
-
export declare function flowInstructionPath(worktree: string): string;
|
|
15
22
|
export declare function historyDir(worktree: string): string;
|
|
16
23
|
export declare function archivedSessionPath(worktree: string, sessionId: string): string;
|
|
17
24
|
export type SessionLockOptions = {
|
|
18
25
|
timeoutMs?: number;
|
|
19
|
-
staleMs?: number;
|
|
20
26
|
};
|
|
21
27
|
export declare function withSessionLock<T>(worktree: string, task: () => Promise<T>, lockOptions?: SessionLockOptions): Promise<T>;
|
|
22
|
-
export declare class UnreadableFlowSessionError extends Error {
|
|
23
|
-
readonly reason: string;
|
|
24
|
-
readonly code = "UNREADABLE_FLOW_SESSION";
|
|
25
|
-
constructor(message: string, reason: string);
|
|
26
|
-
}
|
|
27
28
|
export declare function loadSession(worktree: string): Promise<Session | null>;
|
|
29
|
+
export declare function findArchivedSessionByOperationId(worktree: string, operationId: string): Promise<Session | null>;
|
|
28
30
|
export declare function quarantineUnreadableSession(worktree: string): Promise<string | null>;
|
|
29
|
-
export declare function flowSessionProgress(session: Session): {
|
|
30
|
-
completed: number;
|
|
31
|
-
total: number;
|
|
32
|
-
};
|
|
33
|
-
export declare function renderFlowInstructionFile(session: Session): string;
|
|
34
|
-
export declare function refreshFlowInstructionFile(worktree: string): Promise<void>;
|
|
35
31
|
export declare function saveSession(worktree: string, session: Session): Promise<Session>;
|
|
36
32
|
export declare function archiveAndClearSession(worktree: string, session: Session): Promise<void>;
|
|
33
|
+
export declare function ensureFlowGitignore(worktree: string): Promise<void>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { type Hooks } from "@opencode-ai/plugin";
|
|
2
|
+
export type FlowHostInputOperation = "status" | "planSave" | "runStart" | "featureComplete" | "featureReset" | "sessionClose";
|
|
3
|
+
export declare function acceptsFlowHostInput(operation: FlowHostInputOperation, input: unknown): boolean;
|
|
4
|
+
type FlowTools = NonNullable<Hooks["tool"]>;
|
|
5
|
+
export declare function createTools(ctx: unknown): FlowTools;
|
|
6
|
+
export {};
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
import { type FlowPromptVariant } from "./prompt-surfaces";
|
|
2
|
+
import { type FlowPromptVariant } from "./prompt-surfaces.js";
|
|
3
3
|
declare const ModelDecisionSchema: z.ZodObject<{
|
|
4
4
|
id: z.ZodString;
|
|
5
5
|
route: z.ZodEnum<{
|
|
6
|
+
"flow-audit-worker": "flow-audit-worker";
|
|
7
|
+
"flow-auto": "flow-auto";
|
|
8
|
+
"flow-candidate-worker": "flow-candidate-worker";
|
|
9
|
+
"flow-evidence-worker": "flow-evidence-worker";
|
|
6
10
|
"flow-plan": "flow-plan";
|
|
7
|
-
"flow-run": "flow-run";
|
|
8
11
|
"flow-review": "flow-review";
|
|
9
|
-
"flow-
|
|
12
|
+
"flow-reviewer": "flow-reviewer";
|
|
13
|
+
"flow-run": "flow-run";
|
|
14
|
+
"flow-status": "flow-status";
|
|
10
15
|
"flow-validation-worker": "flow-validation-worker";
|
|
11
|
-
"flow-audit-worker": "flow-audit-worker";
|
|
12
|
-
"flow-candidate-worker": "flow-candidate-worker";
|
|
13
16
|
"flow-verifier-worker": "flow-verifier-worker";
|
|
14
|
-
"flow-auto": "flow-auto";
|
|
15
|
-
"flow-status": "flow-status";
|
|
16
|
-
"flow-reviewer": "flow-reviewer";
|
|
17
17
|
}>;
|
|
18
18
|
executionMode: z.ZodEnum<{
|
|
19
19
|
blocked: "blocked";
|
|
20
|
-
serial: "serial";
|
|
21
|
-
readonly_parallel: "readonly_parallel";
|
|
22
20
|
candidate_worker: "candidate_worker";
|
|
21
|
+
readonly_parallel: "readonly_parallel";
|
|
22
|
+
serial: "serial";
|
|
23
23
|
}>;
|
|
24
24
|
workers: z.ZodArray<z.ZodString>;
|
|
25
25
|
stateOwner: z.ZodEnum<{
|
|
@@ -30,51 +30,40 @@ declare const ModelDecisionSchema: z.ZodObject<{
|
|
|
30
30
|
planOnly: z.ZodBoolean;
|
|
31
31
|
reviewFirst: z.ZodBoolean;
|
|
32
32
|
validation: z.ZodArray<z.ZodEnum<{
|
|
33
|
+
behavioral: "behavioral";
|
|
33
34
|
broad: "broad";
|
|
35
|
+
browser: "browser";
|
|
34
36
|
focused: "focused";
|
|
35
|
-
behavioral: "behavioral";
|
|
36
37
|
ui: "ui";
|
|
37
|
-
browser: "browser";
|
|
38
38
|
}>>;
|
|
39
39
|
independentReview: z.ZodBoolean;
|
|
40
40
|
reviewDepth: z.ZodEnum<{
|
|
41
41
|
broad: "broad";
|
|
42
|
-
quick: "quick";
|
|
43
|
-
standard: "standard";
|
|
44
42
|
detailed: "detailed";
|
|
45
43
|
not_applicable: "not_applicable";
|
|
44
|
+
quick: "quick";
|
|
45
|
+
standard: "standard";
|
|
46
46
|
}>;
|
|
47
47
|
manifestComplete: z.ZodBoolean;
|
|
48
48
|
coverage: z.ZodEnum<{
|
|
49
|
+
complete: "complete";
|
|
49
50
|
missing: "missing";
|
|
50
|
-
partial: "partial";
|
|
51
51
|
not_applicable: "not_applicable";
|
|
52
|
-
|
|
52
|
+
partial: "partial";
|
|
53
53
|
}>;
|
|
54
54
|
handoffStatus: z.ZodEnum<{
|
|
55
55
|
blocked: "blocked";
|
|
56
|
+
not_applicable: "not_applicable";
|
|
56
57
|
partial: "partial";
|
|
57
58
|
success: "success";
|
|
58
|
-
not_applicable: "not_applicable";
|
|
59
59
|
}>;
|
|
60
60
|
handoffHasRequiredSections: z.ZodBoolean;
|
|
61
61
|
retryReviews: z.ZodNumber;
|
|
62
62
|
stopsAfterRetryFailure: z.ZodBoolean;
|
|
63
|
-
phaseBoundaryAction: z.ZodEnum<{
|
|
64
|
-
none: "none";
|
|
65
|
-
stop: "stop";
|
|
66
|
-
resume_with_ack: "resume_with_ack";
|
|
67
|
-
}>;
|
|
68
|
-
sessionContinuation: z.ZodEnum<{
|
|
69
|
-
continue: "continue";
|
|
70
|
-
not_applicable: "not_applicable";
|
|
71
|
-
stop_on_runtime_boundary: "stop_on_runtime_boundary";
|
|
72
|
-
self_initiated_rollover: "self_initiated_rollover";
|
|
73
|
-
}>;
|
|
74
63
|
candidateDecision: z.ZodEnum<{
|
|
75
|
-
used: "used";
|
|
76
|
-
serial_required: "serial_required";
|
|
77
64
|
not_applicable: "not_applicable";
|
|
65
|
+
serial_required: "serial_required";
|
|
66
|
+
used: "used";
|
|
78
67
|
}>;
|
|
79
68
|
completionClaimed: z.ZodBoolean;
|
|
80
69
|
reason: z.ZodString;
|
package/dist/prompt-quality.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type CompiledFlowPrompt, type FlowPromptSurfaceName, type FlowPromptVariant } from "./prompt-surfaces";
|
|
1
|
+
import { type CompiledFlowPrompt, type FlowPromptSurfaceName, type FlowPromptVariant } from "./prompt-surfaces.js";
|
|
2
2
|
export type PromptMetric = {
|
|
3
3
|
surface: string;
|
|
4
4
|
variant: FlowPromptVariant | "runtime";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function resolveFlowPluginVersion(): string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "opencode-plugin-flow",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.1.0",
|
|
4
4
|
"description": "Stateful planning and execution workflow plugin for OpenCode",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
@@ -26,20 +26,22 @@
|
|
|
26
26
|
"CHANGELOG.md"
|
|
27
27
|
],
|
|
28
28
|
"scripts": {
|
|
29
|
-
"build": "bun run build:plugin && bun run build:cli && bun run build:types",
|
|
29
|
+
"build": "bun run clean && bun run build:plugin && bun run build:cli && bun run build:types",
|
|
30
30
|
"build:plugin": "bun build --target=node --outdir=./dist --entry-naming=index.js --external=@opencode-ai/plugin --external=zod --sourcemap=external ./src/index.ts",
|
|
31
31
|
"build:cli": "bun build --target=node --outdir=./dist --entry-naming=cli.js --banner='#!/usr/bin/env node' --sourcemap=external ./src/cli.ts",
|
|
32
32
|
"build:types": "tsc -p tsconfig.types.json",
|
|
33
|
+
"clean": "bun run scripts/clean-dist.ts",
|
|
33
34
|
"lint": "bunx biome check src tests scripts --files-ignore-unknown=true --vcs-use-ignore-file=true",
|
|
34
35
|
"prompt:quality": "bun run scripts/prompt-quality.ts",
|
|
35
36
|
"prompt:model-eval": "bun run scripts/prompt-model-eval.ts",
|
|
37
|
+
"replay:report": "bun run scripts/replay-report.ts",
|
|
38
|
+
"transport:report": "bun run scripts/causal-transport-report.ts",
|
|
36
39
|
"package:smoke": "bun test tests/package-smoke.test.ts",
|
|
37
40
|
"release:monitor": "node scripts/release-monitor.mjs",
|
|
38
41
|
"smoke:live": "FLOW_LIVE_SMOKE=1 bun test tests/live-opencode-smoke.test.ts",
|
|
39
42
|
"test": "bun test tests",
|
|
40
43
|
"typecheck": "tsc --noEmit",
|
|
41
|
-
"
|
|
42
|
-
"check": "bun run typecheck && bun run lint && bun run build && bun run test"
|
|
44
|
+
"check": "bun run typecheck && bun run lint && bun run prompt:quality && bun run build && bun run test"
|
|
43
45
|
},
|
|
44
46
|
"keywords": [
|
|
45
47
|
"opencode",
|
|
@@ -50,19 +52,24 @@
|
|
|
50
52
|
],
|
|
51
53
|
"author": "Douwe de Vries",
|
|
52
54
|
"license": "MIT",
|
|
55
|
+
"packageManager": "bun@1.3.14",
|
|
53
56
|
"engines": {
|
|
54
|
-
"node": ">=
|
|
57
|
+
"node": ">=24"
|
|
55
58
|
},
|
|
56
59
|
"peerDependencies": {
|
|
57
|
-
"@opencode-ai/plugin": ">=1.
|
|
60
|
+
"@opencode-ai/plugin": ">=1.18.3 <2"
|
|
58
61
|
},
|
|
59
62
|
"dependencies": {
|
|
60
|
-
"zod": "4.
|
|
63
|
+
"zod": "4.4.3"
|
|
61
64
|
},
|
|
62
65
|
"devDependencies": {
|
|
63
|
-
"@biomejs/biome": "
|
|
64
|
-
"@opencode-ai/plugin": "1.
|
|
65
|
-
"bun
|
|
66
|
-
"
|
|
66
|
+
"@biomejs/biome": "2.5.4",
|
|
67
|
+
"@opencode-ai/plugin": "1.18.3",
|
|
68
|
+
"@types/bun": "1.3.14",
|
|
69
|
+
"@types/node": "24.13.3",
|
|
70
|
+
"typescript": "7.0.2"
|
|
71
|
+
},
|
|
72
|
+
"overrides": {
|
|
73
|
+
"@types/node": "24.13.3"
|
|
67
74
|
}
|
|
68
75
|
}
|
|
@@ -1,322 +0,0 @@
|
|
|
1
|
-
import { type ToolContext } from "./sdk";
|
|
2
|
-
export declare function createTools(ctx: unknown): {
|
|
3
|
-
flow_status: {
|
|
4
|
-
description: string;
|
|
5
|
-
args: {};
|
|
6
|
-
execute(args: Record<string, never>, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
7
|
-
};
|
|
8
|
-
flow_plan_save: {
|
|
9
|
-
description: string;
|
|
10
|
-
args: {
|
|
11
|
-
goal: import("zod").ZodOptional<import("zod").ZodString>;
|
|
12
|
-
plan: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
13
|
-
summary: import("zod").ZodString;
|
|
14
|
-
overview: import("zod").ZodString;
|
|
15
|
-
requirements: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
16
|
-
decisions: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
17
|
-
finalReviewPolicy: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
18
|
-
broad: "broad";
|
|
19
|
-
detailed: "detailed";
|
|
20
|
-
}>>;
|
|
21
|
-
features: import("zod").ZodArray<import("zod").ZodObject<{
|
|
22
|
-
summary: import("zod").ZodString;
|
|
23
|
-
id: import("zod").ZodString;
|
|
24
|
-
title: import("zod").ZodString;
|
|
25
|
-
status: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
26
|
-
pending: "pending";
|
|
27
|
-
in_progress: "in_progress";
|
|
28
|
-
completed: "completed";
|
|
29
|
-
blocked: "blocked";
|
|
30
|
-
}>>;
|
|
31
|
-
reviewDepth: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
32
|
-
quick: "quick";
|
|
33
|
-
standard: "standard";
|
|
34
|
-
detailed: "detailed";
|
|
35
|
-
}>>;
|
|
36
|
-
targets: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
37
|
-
validation: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
38
|
-
dependsOn: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
39
|
-
}, import("zod/v4/core").$strict>>;
|
|
40
|
-
}, import("zod/v4/core").$strict>>;
|
|
41
|
-
};
|
|
42
|
-
execute(args: {
|
|
43
|
-
goal?: string | undefined;
|
|
44
|
-
plan?: {
|
|
45
|
-
summary: string;
|
|
46
|
-
overview: string;
|
|
47
|
-
requirements: string[];
|
|
48
|
-
decisions: string[];
|
|
49
|
-
features: {
|
|
50
|
-
summary: string;
|
|
51
|
-
id: string;
|
|
52
|
-
title: string;
|
|
53
|
-
status?: "pending" | "in_progress" | "completed" | "blocked" | undefined;
|
|
54
|
-
reviewDepth?: "quick" | "standard" | "detailed" | undefined;
|
|
55
|
-
targets?: string[] | undefined;
|
|
56
|
-
validation?: string[] | undefined;
|
|
57
|
-
dependsOn?: string[] | undefined;
|
|
58
|
-
}[];
|
|
59
|
-
finalReviewPolicy?: "broad" | "detailed" | undefined;
|
|
60
|
-
} | undefined;
|
|
61
|
-
}, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
62
|
-
};
|
|
63
|
-
flow_plan_approve: {
|
|
64
|
-
description: string;
|
|
65
|
-
args: {};
|
|
66
|
-
execute(args: Record<string, never>, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
67
|
-
};
|
|
68
|
-
flow_run_start: {
|
|
69
|
-
description: string;
|
|
70
|
-
args: {
|
|
71
|
-
featureId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
72
|
-
phaseBoundaryAck: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
73
|
-
};
|
|
74
|
-
execute(args: {
|
|
75
|
-
featureId?: string | undefined;
|
|
76
|
-
phaseBoundaryAck?: boolean | undefined;
|
|
77
|
-
}, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
78
|
-
};
|
|
79
|
-
flow_feature_complete: {
|
|
80
|
-
description: string;
|
|
81
|
-
args: {
|
|
82
|
-
status: import("zod").ZodEnum<{
|
|
83
|
-
ok: "ok";
|
|
84
|
-
needs_input: "needs_input";
|
|
85
|
-
}>;
|
|
86
|
-
featureId: import("zod").ZodString;
|
|
87
|
-
summary: import("zod").ZodString;
|
|
88
|
-
artifactsChanged: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
89
|
-
path: import("zod").ZodString;
|
|
90
|
-
}, import("zod/v4/core").$strict>>>;
|
|
91
|
-
validationRun: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
92
|
-
command: import("zod").ZodString;
|
|
93
|
-
status: import("zod").ZodEnum<{
|
|
94
|
-
passed: "passed";
|
|
95
|
-
failed: "failed";
|
|
96
|
-
}>;
|
|
97
|
-
summary: import("zod").ZodString;
|
|
98
|
-
}, import("zod/v4/core").$strict>>>;
|
|
99
|
-
validationScope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
100
|
-
targeted: "targeted";
|
|
101
|
-
broad: "broad";
|
|
102
|
-
}>>;
|
|
103
|
-
featureReviewDepth: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
104
|
-
quick: "quick";
|
|
105
|
-
standard: "standard";
|
|
106
|
-
detailed: "detailed";
|
|
107
|
-
}>>;
|
|
108
|
-
featureReview: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
109
|
-
status: import("zod").ZodEnum<{
|
|
110
|
-
passed: "passed";
|
|
111
|
-
failed: "failed";
|
|
112
|
-
}>;
|
|
113
|
-
summary: import("zod").ZodString;
|
|
114
|
-
blockingFindings: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodObject<{
|
|
115
|
-
summary: import("zod").ZodString;
|
|
116
|
-
severity: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
117
|
-
blocking: "blocking";
|
|
118
|
-
advisory: "advisory";
|
|
119
|
-
}>>;
|
|
120
|
-
}, import("zod/v4/core").$strict>>>;
|
|
121
|
-
}, import("zod/v4/core").$strict>>;
|
|
122
|
-
finalReview: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
123
|
-
status: import("zod").ZodEnum<{
|
|
124
|
-
passed: "passed";
|
|
125
|
-
failed: "failed";
|
|
126
|
-
}>;
|
|
127
|
-
summary: import("zod").ZodString;
|
|
128
|
-
blockingFindings: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodObject<{
|
|
129
|
-
summary: import("zod").ZodString;
|
|
130
|
-
severity: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
131
|
-
blocking: "blocking";
|
|
132
|
-
advisory: "advisory";
|
|
133
|
-
}>>;
|
|
134
|
-
}, import("zod/v4/core").$strict>>>;
|
|
135
|
-
reviewDepth: import("zod").ZodEnum<{
|
|
136
|
-
broad: "broad";
|
|
137
|
-
detailed: "detailed";
|
|
138
|
-
}>;
|
|
139
|
-
}, import("zod/v4/core").$strict>>;
|
|
140
|
-
outcome: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodObject<{
|
|
141
|
-
kind: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
142
|
-
completed: "completed";
|
|
143
|
-
blocked: "blocked";
|
|
144
|
-
needs_input: "needs_input";
|
|
145
|
-
replan_required: "replan_required";
|
|
146
|
-
}>>;
|
|
147
|
-
summary: import("zod").ZodOptional<import("zod").ZodString>;
|
|
148
|
-
resolutionHint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
149
|
-
}, import("zod/v4/core").$strict>, import("zod").ZodObject<{
|
|
150
|
-
kind: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
151
|
-
blocked: "blocked";
|
|
152
|
-
needs_input: "needs_input";
|
|
153
|
-
replan_required: "replan_required";
|
|
154
|
-
}>>;
|
|
155
|
-
summary: import("zod").ZodString;
|
|
156
|
-
resolutionHint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
157
|
-
}, import("zod/v4/core").$strict>]>>;
|
|
158
|
-
orchestrationPasses: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
159
|
-
id: import("zod").ZodString;
|
|
160
|
-
kind: import("zod").ZodEnum<{
|
|
161
|
-
validation: "validation";
|
|
162
|
-
audit: "audit";
|
|
163
|
-
candidate: "candidate";
|
|
164
|
-
discovery: "discovery";
|
|
165
|
-
review: "review";
|
|
166
|
-
verification: "verification";
|
|
167
|
-
"implementation-decision": "implementation-decision";
|
|
168
|
-
}>;
|
|
169
|
-
decision: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
170
|
-
parallel: "parallel";
|
|
171
|
-
serial: "serial";
|
|
172
|
-
"candidate-exact-path": "candidate-exact-path";
|
|
173
|
-
"candidate-worktree": "candidate-worktree";
|
|
174
|
-
tournament: "tournament";
|
|
175
|
-
skipped: "skipped";
|
|
176
|
-
}>>;
|
|
177
|
-
decisionReason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
178
|
-
candidateEligibility: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
179
|
-
eligible: "eligible";
|
|
180
|
-
not_eligible: "not_eligible";
|
|
181
|
-
unknown: "unknown";
|
|
182
|
-
}>>;
|
|
183
|
-
candidateDecision: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
184
|
-
skipped: "skipped";
|
|
185
|
-
used: "used";
|
|
186
|
-
serial_required: "serial_required";
|
|
187
|
-
}>>;
|
|
188
|
-
decisionFactors: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodEnum<{
|
|
189
|
-
shared_state: "shared_state";
|
|
190
|
-
overlapping_files: "overlapping_files";
|
|
191
|
-
small_slice: "small_slice";
|
|
192
|
-
needs_manager_judgment: "needs_manager_judgment";
|
|
193
|
-
independent_surface: "independent_surface";
|
|
194
|
-
validation_available: "validation_available";
|
|
195
|
-
}>>>;
|
|
196
|
-
modes: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodEnum<{
|
|
197
|
-
evidence: "evidence";
|
|
198
|
-
validation: "validation";
|
|
199
|
-
audit: "audit";
|
|
200
|
-
verifier: "verifier";
|
|
201
|
-
review: "review";
|
|
202
|
-
"candidate-implementation": "candidate-implementation";
|
|
203
|
-
}>>>;
|
|
204
|
-
workerCount: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
205
|
-
candidateWorkerCount: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
206
|
-
verifierWorkerCount: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
207
|
-
sliceIds: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
208
|
-
dependsOn: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
209
|
-
writeScope: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
210
|
-
none: "none";
|
|
211
|
-
"manager-serial": "manager-serial";
|
|
212
|
-
"exact-path": "exact-path";
|
|
213
|
-
"isolated-worktree": "isolated-worktree";
|
|
214
|
-
mixed: "mixed";
|
|
215
|
-
}>>;
|
|
216
|
-
handoffRefs: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodString>>;
|
|
217
|
-
verificationStatus: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
218
|
-
pending: "pending";
|
|
219
|
-
passed: "passed";
|
|
220
|
-
failed: "failed";
|
|
221
|
-
mixed: "mixed";
|
|
222
|
-
"not-needed": "not-needed";
|
|
223
|
-
downgraded: "downgraded";
|
|
224
|
-
}>>;
|
|
225
|
-
outcome: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
226
|
-
accepted: "accepted";
|
|
227
|
-
modified: "modified";
|
|
228
|
-
rejected: "rejected";
|
|
229
|
-
partial: "partial";
|
|
230
|
-
"not-covered": "not-covered";
|
|
231
|
-
superseded: "superseded";
|
|
232
|
-
}>>;
|
|
233
|
-
synthesisRef: import("zod").ZodOptional<import("zod").ZodString>;
|
|
234
|
-
}, import("zod/v4/core").$strict>>>;
|
|
235
|
-
};
|
|
236
|
-
execute(args: {
|
|
237
|
-
status: "ok" | "needs_input";
|
|
238
|
-
featureId: string;
|
|
239
|
-
summary: string;
|
|
240
|
-
artifactsChanged?: {
|
|
241
|
-
path: string;
|
|
242
|
-
}[] | undefined;
|
|
243
|
-
validationRun?: {
|
|
244
|
-
command: string;
|
|
245
|
-
status: "passed" | "failed";
|
|
246
|
-
summary: string;
|
|
247
|
-
}[] | undefined;
|
|
248
|
-
validationScope?: "targeted" | "broad" | undefined;
|
|
249
|
-
featureReviewDepth?: "quick" | "standard" | "detailed" | undefined;
|
|
250
|
-
featureReview?: {
|
|
251
|
-
status: "passed" | "failed";
|
|
252
|
-
summary: string;
|
|
253
|
-
blockingFindings: {
|
|
254
|
-
summary: string;
|
|
255
|
-
severity: "blocking" | "advisory";
|
|
256
|
-
}[];
|
|
257
|
-
} | undefined;
|
|
258
|
-
finalReview?: {
|
|
259
|
-
status: "passed" | "failed";
|
|
260
|
-
summary: string;
|
|
261
|
-
blockingFindings: {
|
|
262
|
-
summary: string;
|
|
263
|
-
severity: "blocking" | "advisory";
|
|
264
|
-
}[];
|
|
265
|
-
reviewDepth: "broad" | "detailed";
|
|
266
|
-
} | undefined;
|
|
267
|
-
outcome?: {
|
|
268
|
-
kind: "completed" | "blocked" | "needs_input" | "replan_required";
|
|
269
|
-
summary?: string | undefined;
|
|
270
|
-
resolutionHint?: string | undefined;
|
|
271
|
-
} | {
|
|
272
|
-
kind: "blocked" | "needs_input" | "replan_required";
|
|
273
|
-
summary: string;
|
|
274
|
-
resolutionHint?: string | undefined;
|
|
275
|
-
} | undefined;
|
|
276
|
-
orchestrationPasses?: {
|
|
277
|
-
id: string;
|
|
278
|
-
kind: "validation" | "audit" | "candidate" | "discovery" | "review" | "verification" | "implementation-decision";
|
|
279
|
-
candidateEligibility: "eligible" | "not_eligible" | "unknown";
|
|
280
|
-
decisionFactors: ("shared_state" | "overlapping_files" | "small_slice" | "needs_manager_judgment" | "independent_surface" | "validation_available")[];
|
|
281
|
-
modes: ("evidence" | "validation" | "audit" | "verifier" | "review" | "candidate-implementation")[];
|
|
282
|
-
workerCount: number;
|
|
283
|
-
candidateWorkerCount: number;
|
|
284
|
-
verifierWorkerCount: number;
|
|
285
|
-
sliceIds: string[];
|
|
286
|
-
dependsOn: string[];
|
|
287
|
-
writeScope: "none" | "manager-serial" | "exact-path" | "isolated-worktree" | "mixed";
|
|
288
|
-
handoffRefs: string[];
|
|
289
|
-
verificationStatus: "pending" | "passed" | "failed" | "mixed" | "not-needed" | "downgraded";
|
|
290
|
-
outcome: "accepted" | "modified" | "rejected" | "partial" | "not-covered" | "superseded";
|
|
291
|
-
decision?: "parallel" | "serial" | "candidate-exact-path" | "candidate-worktree" | "tournament" | "skipped" | undefined;
|
|
292
|
-
decisionReason?: string | undefined;
|
|
293
|
-
candidateDecision?: "skipped" | "used" | "serial_required" | undefined;
|
|
294
|
-
synthesisRef?: string | undefined;
|
|
295
|
-
}[] | undefined;
|
|
296
|
-
}, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
297
|
-
};
|
|
298
|
-
flow_feature_reset: {
|
|
299
|
-
description: string;
|
|
300
|
-
args: {
|
|
301
|
-
featureId: import("zod").ZodString;
|
|
302
|
-
};
|
|
303
|
-
execute(args: {
|
|
304
|
-
featureId: string;
|
|
305
|
-
}, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
306
|
-
};
|
|
307
|
-
flow_session_close: {
|
|
308
|
-
description: string;
|
|
309
|
-
args: {
|
|
310
|
-
kind: import("zod").ZodEnum<{
|
|
311
|
-
completed: "completed";
|
|
312
|
-
deferred: "deferred";
|
|
313
|
-
abandoned: "abandoned";
|
|
314
|
-
}>;
|
|
315
|
-
summary: import("zod").ZodOptional<import("zod").ZodString>;
|
|
316
|
-
};
|
|
317
|
-
execute(args: {
|
|
318
|
-
kind: "completed" | "deferred" | "abandoned";
|
|
319
|
-
summary?: string | undefined;
|
|
320
|
-
}, context: ToolContext): Promise<import("@opencode-ai/plugin").ToolResult>;
|
|
321
|
-
};
|
|
322
|
-
};
|