opencode-plugin-flow 5.2.1 → 5.2.2
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 +30 -0
- package/README.md +6 -5
- package/dist/cli.js +10 -1
- package/dist/cli.js.map +3 -3
- package/dist/index.js +1150 -493
- package/dist/index.js.map +15 -15
- package/package.json +12 -5
- package/dist/application/errors.d.ts +0 -10
- package/dist/application/flow-service.d.ts +0 -311
- package/dist/application/ports/evidence-artifact-store.d.ts +0 -28
- package/dist/application/ports/session-repository.d.ts +0 -22
- package/dist/application/ports/source-identity.d.ts +0 -61
- package/dist/application/replay/canonical-json.d.ts +0 -7
- package/dist/application/replay/contract.d.ts +0 -2130
- package/dist/application/replay/engine.d.ts +0 -101
- package/dist/application/replay/index.d.ts +0 -7
- package/dist/application/replay/privacy.d.ts +0 -14
- package/dist/application/schema.d.ts +0 -1813
- package/dist/cli.d.ts +0 -1
- package/dist/config-shared.d.ts +0 -287
- package/dist/config.d.ts +0 -1
- package/dist/distribution/legacy-cleanup.d.ts +0 -25
- package/dist/domain/feature-id.d.ts +0 -3
- package/dist/domain/limits.d.ts +0 -4
- package/dist/domain/orchestration-policy.d.ts +0 -27
- package/dist/domain/session-invariants.d.ts +0 -8
- package/dist/domain/session.d.ts +0 -356
- package/dist/domain/transitions.d.ts +0 -275
- package/dist/domain/validation-command.d.ts +0 -8
- package/dist/guidance/catalog.d.ts +0 -18
- package/dist/guidance/ids.d.ts +0 -4
- package/dist/infrastructure/fs/evidence-artifact-store.d.ts +0 -5
- package/dist/infrastructure/fs/session-repository.d.ts +0 -2
- package/dist/infrastructure/fs/source-identity.d.ts +0 -26
- package/dist/infrastructure/fs/strict-json-object.d.ts +0 -9
- package/dist/infrastructure/fs/workspace-flow-service.d.ts +0 -10
- package/dist/infrastructure/fs/workspace.d.ts +0 -63
- package/dist/infrastructure/system/transition-environment.d.ts +0 -2
- package/dist/platform/opencode/config.d.ts +0 -2
- package/dist/platform/opencode/logging.d.ts +0 -3
- package/dist/platform/opencode/tools.d.ts +0 -4
- package/dist/prompt-baseline-fixtures.d.ts +0 -20
- package/dist/prompt-model-evaluation.d.ts +0 -88
- package/dist/prompt-quality.d.ts +0 -80
- package/dist/prompt-surfaces.d.ts +0 -28
- package/dist/version.d.ts +0 -1
|
@@ -1,101 +0,0 @@
|
|
|
1
|
-
import type { OpaqueId, ReplayControlDefect, ReplayDecision, ReplayFixture, ReplayReason, ReplayScenario, ReplayScenarioId, ReplayVariant, Sha256Digest } from "./contract.js";
|
|
2
|
-
export type ReplayMismatch = "contradictory_review_verdicts" | "duplicate_mutation_commit" | "mutation_left_uncommitted" | "recovery_without_crash" | "snapshot_revision_mismatch" | "terminal_decision_missing" | "terminal_decision_multiple" | "terminal_not_final" | "terminal_decision_mismatch" | "terminal_reason_mismatch" | "terminal_revision_mismatch" | "terminal_digest_mismatch";
|
|
3
|
-
export interface ReplayCounters {
|
|
4
|
-
readonly validationAttempts: number;
|
|
5
|
-
readonly featureReviewAttempts: number;
|
|
6
|
-
readonly finalReviewAttempts: number;
|
|
7
|
-
readonly submittedReviewAttempts: number;
|
|
8
|
-
readonly failedReviewAttempts: number;
|
|
9
|
-
readonly retries: number;
|
|
10
|
-
readonly findingCount: number;
|
|
11
|
-
readonly duplicateFindingCount: number;
|
|
12
|
-
readonly invalidHandoffs: number;
|
|
13
|
-
readonly invalidTelemetry: number;
|
|
14
|
-
readonly schemaFailures: number;
|
|
15
|
-
readonly compactions: number;
|
|
16
|
-
readonly mutationStarts: number;
|
|
17
|
-
readonly mutationCommits: number;
|
|
18
|
-
readonly crashes: number;
|
|
19
|
-
readonly recoveries: number;
|
|
20
|
-
}
|
|
21
|
-
/** Terminal truth the fixture asserts; the oracle treats it as an expectation. */
|
|
22
|
-
export interface ReplayTerminalExpectation {
|
|
23
|
-
readonly decision: ReplayDecision;
|
|
24
|
-
readonly reason: ReplayReason;
|
|
25
|
-
readonly revision: number;
|
|
26
|
-
readonly stateDigest: Sha256Digest;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Per-field comparison of the fixture's asserted terminal against independently
|
|
30
|
-
* derived truth. `unavailable` means no independent state-bearing event derived
|
|
31
|
-
* the field, so the assertion is neither confirmed nor refuted — never assumed.
|
|
32
|
-
*/
|
|
33
|
-
export type TerminalComparisonStatus = "matched" | "mismatched" | "unavailable";
|
|
34
|
-
export interface ReplayTerminalComparison {
|
|
35
|
-
readonly decision: TerminalComparisonStatus;
|
|
36
|
-
readonly reason: TerminalComparisonStatus;
|
|
37
|
-
readonly revision: TerminalComparisonStatus;
|
|
38
|
-
readonly stateDigest: TerminalComparisonStatus;
|
|
39
|
-
/** Roll-up: mismatched if any field mismatched, else unavailable, else matched. */
|
|
40
|
-
readonly status: TerminalComparisonStatus;
|
|
41
|
-
}
|
|
42
|
-
interface CommonScenarioResult {
|
|
43
|
-
readonly scenarioId: ReplayScenarioId;
|
|
44
|
-
readonly variant: ReplayVariant;
|
|
45
|
-
readonly counters: ReplayCounters;
|
|
46
|
-
readonly evidenceRefs: readonly OpaqueId[];
|
|
47
|
-
readonly stateDigestRefs: readonly Sha256Digest[];
|
|
48
|
-
readonly defects: readonly ReplayControlDefect[];
|
|
49
|
-
readonly mismatches: readonly ReplayMismatch[];
|
|
50
|
-
/** Durable revision derived from state-bearing events, or null when absent. */
|
|
51
|
-
readonly derivedRevision: number | null;
|
|
52
|
-
/** Durable state digest derived from state-bearing events, or null. */
|
|
53
|
-
readonly derivedStateDigest: Sha256Digest | null;
|
|
54
|
-
/** The fixture's asserted terminal truth, compared against derived truth. */
|
|
55
|
-
readonly expectedTerminal: ReplayTerminalExpectation | null;
|
|
56
|
-
/** Fail-closed comparison of the asserted terminal against derived truth. */
|
|
57
|
-
readonly terminalComparison: ReplayTerminalComparison;
|
|
58
|
-
}
|
|
59
|
-
export type ReplayScenarioResult = (CommonScenarioResult & {
|
|
60
|
-
readonly supported: false;
|
|
61
|
-
readonly decision: null;
|
|
62
|
-
readonly reason: "unsupported_variant";
|
|
63
|
-
}) | (CommonScenarioResult & {
|
|
64
|
-
readonly variant: "A";
|
|
65
|
-
readonly supported: true;
|
|
66
|
-
readonly decision: ReplayDecision;
|
|
67
|
-
readonly reason: ReplayReason;
|
|
68
|
-
});
|
|
69
|
-
export interface ReplayFixtureResult {
|
|
70
|
-
readonly fixtureId: OpaqueId;
|
|
71
|
-
readonly variant: ReplayVariant;
|
|
72
|
-
readonly supported: boolean;
|
|
73
|
-
readonly scenarios: readonly ReplayScenarioResult[];
|
|
74
|
-
}
|
|
75
|
-
interface ReviewPassReduction {
|
|
76
|
-
readonly featureReviewAttempts: number;
|
|
77
|
-
readonly finalReviewAttempts: number;
|
|
78
|
-
readonly submittedReviewAttempts: number;
|
|
79
|
-
readonly failedReviewAttempts: number;
|
|
80
|
-
readonly findingCount: number;
|
|
81
|
-
readonly duplicateFindingCount: number;
|
|
82
|
-
readonly evidenceRefs: readonly OpaqueId[];
|
|
83
|
-
readonly invalidCausality: boolean;
|
|
84
|
-
readonly contradictoryVerdicts: boolean;
|
|
85
|
-
readonly retryUnchanged: boolean;
|
|
86
|
-
readonly retryResolved: boolean;
|
|
87
|
-
readonly unsubmittedFailure: boolean;
|
|
88
|
-
readonly reviewFailed: boolean;
|
|
89
|
-
readonly anyPassedReview: boolean;
|
|
90
|
-
}
|
|
91
|
-
/**
|
|
92
|
-
* Projects append-only review evidence into latest logical-pass truth.
|
|
93
|
-
*
|
|
94
|
-
* The reduction is pure: repeated attempt identities with identical semantic
|
|
95
|
-
* evidence are idempotent, conflicting reuse and invalid retry links fail
|
|
96
|
-
* closed, and historical attempts never override the latest pass projection.
|
|
97
|
-
*/
|
|
98
|
-
export declare function reduceReviewPasses(events: readonly ReplayScenario["events"][number][]): ReviewPassReduction;
|
|
99
|
-
export declare function replayScenario(scenario: ReplayScenario, variant: ReplayVariant): ReplayScenarioResult;
|
|
100
|
-
export declare function replayFixture(fixture: ReplayFixture, variant: ReplayVariant): ReplayFixtureResult;
|
|
101
|
-
export {};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { z } from "zod";
|
|
2
|
-
import { ReplayFixtureSchema } from "./contract.js";
|
|
3
|
-
export * from "./canonical-json.js";
|
|
4
|
-
export * from "./contract.js";
|
|
5
|
-
export * from "./engine.js";
|
|
6
|
-
export * from "./privacy.js";
|
|
7
|
-
export declare function parseReplayFixture(raw: unknown): z.infer<typeof ReplayFixtureSchema>;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export type ReplayPrivacyValidation = {
|
|
2
|
-
readonly safe: true;
|
|
3
|
-
readonly violations: readonly [];
|
|
4
|
-
} | {
|
|
5
|
-
readonly safe: false;
|
|
6
|
-
readonly violations: readonly string[];
|
|
7
|
-
};
|
|
8
|
-
export declare class ReplayPrivacyError extends Error {
|
|
9
|
-
readonly code = "replay_privacy_violation";
|
|
10
|
-
readonly violations: readonly string[];
|
|
11
|
-
constructor(violations: readonly string[]);
|
|
12
|
-
}
|
|
13
|
-
/** Scans any raw value without trusting its schema or object prototype. */
|
|
14
|
-
export declare function validateReplayFixturePrivacy(raw: unknown): ReplayPrivacyValidation;
|