planpong 0.5.6 → 0.6.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.
Files changed (61) hide show
  1. package/README.md +47 -10
  2. package/dist/bin/planpong.js +13 -1
  3. package/dist/bin/planpong.js.map +1 -1
  4. package/dist/src/cli/commands/init.d.ts +53 -0
  5. package/dist/src/cli/commands/init.js +221 -0
  6. package/dist/src/cli/commands/init.js.map +1 -0
  7. package/dist/src/cli/ui.js +11 -19
  8. package/dist/src/cli/ui.js.map +1 -1
  9. package/dist/src/config/loader.d.ts +5 -0
  10. package/dist/src/config/loader.js +21 -1
  11. package/dist/src/config/loader.js.map +1 -1
  12. package/dist/src/config/mutate.d.ts +26 -0
  13. package/dist/src/config/mutate.js +45 -32
  14. package/dist/src/config/mutate.js.map +1 -1
  15. package/dist/src/core/convergence.js +1 -1
  16. package/dist/src/core/convergence.js.map +1 -1
  17. package/dist/src/core/operations.d.ts +44 -1
  18. package/dist/src/core/operations.js +110 -37
  19. package/dist/src/core/operations.js.map +1 -1
  20. package/dist/src/core/presentation.d.ts +39 -0
  21. package/dist/src/core/presentation.js +132 -0
  22. package/dist/src/core/presentation.js.map +1 -0
  23. package/dist/src/core/round-state.d.ts +15 -0
  24. package/dist/src/core/round-state.js +49 -0
  25. package/dist/src/core/round-state.js.map +1 -0
  26. package/dist/src/core/session.d.ts +1 -0
  27. package/dist/src/core/session.js +60 -1
  28. package/dist/src/core/session.js.map +1 -1
  29. package/dist/src/mcp/server.js +6 -6
  30. package/dist/src/mcp/server.js.map +1 -1
  31. package/dist/src/mcp/tools/get-feedback.d.ts +1 -2
  32. package/dist/src/mcp/tools/get-feedback.js +154 -56
  33. package/dist/src/mcp/tools/get-feedback.js.map +1 -1
  34. package/dist/src/mcp/tools/record-revision.d.ts +0 -6
  35. package/dist/src/mcp/tools/record-revision.js +170 -95
  36. package/dist/src/mcp/tools/record-revision.js.map +1 -1
  37. package/dist/src/mcp/tools/revise.d.ts +1 -7
  38. package/dist/src/mcp/tools/revise.js +126 -90
  39. package/dist/src/mcp/tools/revise.js.map +1 -1
  40. package/dist/src/mcp/tools/status.js +18 -1
  41. package/dist/src/mcp/tools/status.js.map +1 -1
  42. package/dist/src/providers/claude.d.ts +22 -1
  43. package/dist/src/providers/claude.js +10 -10
  44. package/dist/src/providers/claude.js.map +1 -1
  45. package/dist/src/providers/codex.d.ts +12 -1
  46. package/dist/src/providers/codex.js +6 -3
  47. package/dist/src/providers/codex.js.map +1 -1
  48. package/dist/src/providers/gemini.d.ts +58 -0
  49. package/dist/src/providers/gemini.js +169 -0
  50. package/dist/src/providers/gemini.js.map +1 -0
  51. package/dist/src/providers/registry.js +7 -1
  52. package/dist/src/providers/registry.js.map +1 -1
  53. package/dist/src/providers/shared.d.ts +16 -0
  54. package/dist/src/providers/shared.js +22 -0
  55. package/dist/src/providers/shared.js.map +1 -0
  56. package/dist/src/providers/types.d.ts +1 -1
  57. package/dist/src/schemas/metrics.d.ts +14 -14
  58. package/dist/src/schemas/metrics.js +13 -2
  59. package/dist/src/schemas/metrics.js.map +1 -1
  60. package/dist/src/schemas/session.d.ts +2 -2
  61. package/package.json +3 -2
@@ -0,0 +1,58 @@
1
+ import type { Provider, InvokeOptions, ProviderResponse, ProviderError } from "./types.js";
2
+ /**
3
+ * Build argv for `gemini -p`. Pure function — no I/O.
4
+ *
5
+ * The `gemini` CLI's `-p/--prompt` flag requires a string value (the help text
6
+ * is misleading on this point). Per the CLI source, stdin content is appended
7
+ * to the `-p` argument, so passing `-p ""` plus a stdin pipe works the same as
8
+ * codex's `exec -` pattern: the model sees only the stdin content.
9
+ *
10
+ * `--skip-trust` bypasses the "trusted folder" gate added in gemini CLI 0.32.
11
+ * Without it, gemini exits 55 in any directory the user has not interactively
12
+ * acknowledged as trusted, which would block planpong runs in fresh repos,
13
+ * temp directories, and CI shells. The alternative escape hatch is the
14
+ * `GEMINI_CLI_TRUST_WORKSPACE=true` env var; we prefer the explicit flag so
15
+ * the contract is visible in process listings and not coupled to env state.
16
+ *
17
+ * Session resumption is not supported in v1 — `gemini --resume` accepts
18
+ * indices and `latest`, not UUIDs, so `newSessionId`/`resumeSessionId` are
19
+ * silently ignored. See the design doc at docs/plans/gemini-and-init-wizard.md
20
+ * (Future Work item #2) for the deferred follow-up.
21
+ */
22
+ export declare function buildArgs(options: InvokeOptions): string[];
23
+ export type ExtractResult = {
24
+ ok: true;
25
+ text: string;
26
+ } | {
27
+ ok: false;
28
+ message: string;
29
+ code?: number;
30
+ };
31
+ /**
32
+ * Parse gemini's `--output-format json` envelope. Pure function.
33
+ *
34
+ * Envelope shape (verified against @google/gemini-cli@0.32 src/output/json-formatter.ts):
35
+ * success: { session_id, response, stats }
36
+ * error: { session_id, error: { type, message, code } }
37
+ */
38
+ export declare function extractResponse(stdout: string): ExtractResult;
39
+ /**
40
+ * Classify a gemini invocation failure. v1 always returns `fatal` — gemini
41
+ * doesn't accept any structured-output flags so there is no capability axis
42
+ * to downgrade along.
43
+ */
44
+ export declare function classifyError(stderr: string, exitCode: number): ProviderError;
45
+ export declare class GeminiProvider implements Provider {
46
+ name: string;
47
+ invoke(prompt: string, options: InvokeOptions): Promise<ProviderResponse>;
48
+ isAvailable(): Promise<boolean>;
49
+ /**
50
+ * Always returns false in v1. Gemini's CLI does not expose a `--json-schema`
51
+ * or `--output-schema` flag, so structured-output mode is unavailable. See
52
+ * Future Work item #1 in docs/plans/gemini-and-init-wizard.md.
53
+ */
54
+ checkStructuredOutputSupport(): Promise<boolean>;
55
+ markNonCapable(): void;
56
+ getModels(): string[];
57
+ getEffortLevels(): string[];
58
+ }
@@ -0,0 +1,169 @@
1
+ import { execa } from "execa";
2
+ import { assertMutuallyExclusiveSessions, logClassificationFailure, } from "./shared.js";
3
+ const MODELS = ["gemini-2.5-pro", "gemini-3-pro", "gemini-2.5-flash"];
4
+ /**
5
+ * Build argv for `gemini -p`. Pure function — no I/O.
6
+ *
7
+ * The `gemini` CLI's `-p/--prompt` flag requires a string value (the help text
8
+ * is misleading on this point). Per the CLI source, stdin content is appended
9
+ * to the `-p` argument, so passing `-p ""` plus a stdin pipe works the same as
10
+ * codex's `exec -` pattern: the model sees only the stdin content.
11
+ *
12
+ * `--skip-trust` bypasses the "trusted folder" gate added in gemini CLI 0.32.
13
+ * Without it, gemini exits 55 in any directory the user has not interactively
14
+ * acknowledged as trusted, which would block planpong runs in fresh repos,
15
+ * temp directories, and CI shells. The alternative escape hatch is the
16
+ * `GEMINI_CLI_TRUST_WORKSPACE=true` env var; we prefer the explicit flag so
17
+ * the contract is visible in process listings and not coupled to env state.
18
+ *
19
+ * Session resumption is not supported in v1 — `gemini --resume` accepts
20
+ * indices and `latest`, not UUIDs, so `newSessionId`/`resumeSessionId` are
21
+ * silently ignored. See the design doc at docs/plans/gemini-and-init-wizard.md
22
+ * (Future Work item #2) for the deferred follow-up.
23
+ */
24
+ export function buildArgs(options) {
25
+ const args = ["-p", "", "--skip-trust", "--output-format", "json"];
26
+ if (options.model) {
27
+ args.push("-m", options.model);
28
+ }
29
+ return args;
30
+ }
31
+ /**
32
+ * Parse gemini's `--output-format json` envelope. Pure function.
33
+ *
34
+ * Envelope shape (verified against @google/gemini-cli@0.32 src/output/json-formatter.ts):
35
+ * success: { session_id, response, stats }
36
+ * error: { session_id, error: { type, message, code } }
37
+ */
38
+ export function extractResponse(stdout) {
39
+ let envelope;
40
+ try {
41
+ envelope = JSON.parse(stdout);
42
+ }
43
+ catch {
44
+ return {
45
+ ok: false,
46
+ message: "could not parse gemini JSON envelope",
47
+ code: undefined,
48
+ };
49
+ }
50
+ if (envelope === null || typeof envelope !== "object") {
51
+ return {
52
+ ok: false,
53
+ message: "could not parse gemini JSON envelope",
54
+ code: undefined,
55
+ };
56
+ }
57
+ const obj = envelope;
58
+ if (obj.error &&
59
+ typeof obj.error === "object" &&
60
+ obj.error !== null) {
61
+ const err = obj.error;
62
+ const message = typeof err.message === "string" ? err.message : "gemini reported error";
63
+ const code = typeof err.code === "number" ? err.code : undefined;
64
+ return { ok: false, message, code };
65
+ }
66
+ if (typeof obj.response === "string") {
67
+ return { ok: true, text: obj.response };
68
+ }
69
+ return {
70
+ ok: false,
71
+ message: "gemini envelope missing response and error fields",
72
+ code: undefined,
73
+ };
74
+ }
75
+ /**
76
+ * Classify a gemini invocation failure. v1 always returns `fatal` — gemini
77
+ * doesn't accept any structured-output flags so there is no capability axis
78
+ * to downgrade along.
79
+ */
80
+ export function classifyError(stderr, exitCode) {
81
+ return {
82
+ kind: "fatal",
83
+ message: stderr.slice(0, 500) || `gemini exited with code ${exitCode}`,
84
+ exitCode,
85
+ stderr,
86
+ };
87
+ }
88
+ export class GeminiProvider {
89
+ name = "gemini";
90
+ async invoke(prompt, options) {
91
+ assertMutuallyExclusiveSessions(this.name, options);
92
+ const args = buildArgs(options);
93
+ const start = Date.now();
94
+ try {
95
+ const result = await execa("gemini", args, {
96
+ cwd: options.cwd,
97
+ preferLocal: true,
98
+ timeout: options.timeout ?? 600_000,
99
+ reject: false,
100
+ input: prompt,
101
+ });
102
+ const duration = Date.now() - start;
103
+ const exitCode = result.exitCode ?? 1;
104
+ const stdout = result.stdout ?? "";
105
+ if (stdout.trim().length > 0) {
106
+ const parsed = extractResponse(stdout);
107
+ if (parsed.ok) {
108
+ return { ok: true, output: parsed.text, duration };
109
+ }
110
+ return {
111
+ ok: false,
112
+ error: {
113
+ kind: "fatal",
114
+ message: parsed.message,
115
+ exitCode: parsed.code ?? exitCode,
116
+ stderr: result.stderr,
117
+ },
118
+ duration,
119
+ };
120
+ }
121
+ logClassificationFailure(this.name, exitCode, result.stderr);
122
+ return {
123
+ ok: false,
124
+ error: classifyError(result.stderr ?? "", exitCode),
125
+ duration,
126
+ };
127
+ }
128
+ catch (error) {
129
+ const duration = Date.now() - start;
130
+ const message = error instanceof Error ? error.message : "Unknown error invoking gemini";
131
+ return {
132
+ ok: false,
133
+ error: { kind: "fatal", message, exitCode: 1 },
134
+ duration,
135
+ };
136
+ }
137
+ }
138
+ async isAvailable() {
139
+ try {
140
+ const result = await execa("gemini", ["--version"], {
141
+ preferLocal: true,
142
+ timeout: 5_000,
143
+ reject: false,
144
+ });
145
+ return result.exitCode === 0;
146
+ }
147
+ catch {
148
+ return false;
149
+ }
150
+ }
151
+ /**
152
+ * Always returns false in v1. Gemini's CLI does not expose a `--json-schema`
153
+ * or `--output-schema` flag, so structured-output mode is unavailable. See
154
+ * Future Work item #1 in docs/plans/gemini-and-init-wizard.md.
155
+ */
156
+ async checkStructuredOutputSupport() {
157
+ return false;
158
+ }
159
+ markNonCapable() {
160
+ // No-op for symmetry with the other providers; v1 is permanently non-capable.
161
+ }
162
+ getModels() {
163
+ return MODELS;
164
+ }
165
+ getEffortLevels() {
166
+ return ["default"];
167
+ }
168
+ }
169
+ //# sourceMappingURL=gemini.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gemini.js","sourceRoot":"","sources":["../../../src/providers/gemini.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAC9B,OAAO,EACL,+BAA+B,EAC/B,wBAAwB,GACzB,MAAM,aAAa,CAAC;AAQrB,MAAM,MAAM,GAAG,CAAC,gBAAgB,EAAE,cAAc,EAAE,kBAAkB,CAAC,CAAC;AAEtE;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,UAAU,SAAS,CAAC,OAAsB;IAC9C,MAAM,IAAI,GAAG,CAAC,IAAI,EAAE,EAAE,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,CAAC,CAAC;IACnE,IAAI,OAAO,CAAC,KAAK,EAAE,CAAC;QAClB,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;IACjC,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAMD;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAAC,MAAc;IAC5C,IAAI,QAAiB,CAAC;IACtB,IAAI,CAAC;QACH,QAAQ,GAAG,I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AAC;IAED,cAAc;QACZ,8EAA8E;IAChF,CAAC;IAED,SAAS;QACP,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,eAAe;QACb,OAAO,CAAC,SAAS,CAAC,CAAC;IACrB,CAAC;CACF"}
@@ -1,9 +1,15 @@
1
1
  import { ClaudeProvider } from "./claude.js";
2
2
  import { CodexProvider } from "./codex.js";
3
- const ALL_PROVIDERS = [new ClaudeProvider(), new CodexProvider()];
3
+ import { GeminiProvider } from "./gemini.js";
4
+ const ALL_PROVIDERS = [
5
+ new ClaudeProvider(),
6
+ new CodexProvider(),
7
+ new GeminiProvider(),
8
+ ];
4
9
  const INSTALL_HINTS = {
5
10
  claude: "Install Claude Code: npm install -g @anthropic-ai/claude-code (requires Anthropic API key or Max subscription)",
6
11
  codex: "Install Codex CLI: npm install -g @openai/codex (requires OpenAI API key)",
12
+ gemini: "Install Gemini CLI: npm install -g @google/gemini-cli, then run `gemini` once to complete Google account auth before invoking planpong.",
7
13
  };
8
14
  export async function getAvailableProviders() {
9
15
  const results = await Promise.all(ALL_PROVIDERS.map(async (p) => ({
@@ -1 +1 @@
1
- {"version":3,"file":"registry.js","sourceRoot":"","sources":["../../../src/providers/registry.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE3C,MAAM,aAAa,GAAe,CAAC,IAAI,cAAc,EAAE,EAAE,IAAI,aAAa,EAAE,CAAC,CAAC;AAE9E,MAAM,aAAa,GAA2B;IAC5C,MAAM,EACJ,gHAAgH;IAClH,KAAK,EACH,2EAA2E;CAC9E,CAAC;AAEF,MAAM,CAAC,KAAK,UAAU,qBAAqB;IACzC,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,GAAG,CAC/B,aAAa,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9B,QAAQ,EAAE,CAAC;QACX,SAAS,E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M,CAAC,CAAC,WAAW,EAAE;KACjC,CAAC,CAAC,CACJ,CAAC;IACF,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC;AACnE,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,IAAY;IACtC,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC;AACpD,CAAC;AAED,MAAM,UAAU,eAAe;IAC7B,OAAO,aAAa,CAAC;AACvB,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,YAAoB;IACjD,OAAO,aAAa,CAAC,YAAY,CAAC,IAAI,gBAAgB,YAAY,OAAO,CAAC;AAC5E,CAAC"}
@@ -0,0 +1,16 @@
1
+ import type { InvokeOptions } from "./types.js";
2
+ /**
3
+ * Reject the impossible state where a caller asks the provider to both
4
+ * initialize a fresh session AND resume an existing one. The operations-layer
5
+ * state machine never passes both today, so this is purely defensive — but
6
+ * all providers throw the same error so the parity is uniform.
7
+ */
8
+ export declare function assertMutuallyExclusiveSessions(providerName: string, options: InvokeOptions): void;
9
+ /**
10
+ * Emit a single-line debug breadcrumb when a provider invocation produces no
11
+ * usable output and is about to be classified as a failure. Matches the
12
+ * `[<provider>-provider] exit=<code> stderr=<truncated>` format originally
13
+ * added to the claude provider so triage logs read the same regardless of
14
+ * which CLI failed.
15
+ */
16
+ export declare function logClassificationFailure(providerName: string, exitCode: number, stderr: string | undefined): void;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Reject the impossible state where a caller asks the provider to both
3
+ * initialize a fresh session AND resume an existing one. The operations-layer
4
+ * state machine never passes both today, so this is purely defensive — but
5
+ * all providers throw the same error so the parity is uniform.
6
+ */
7
+ export function assertMutuallyExclusiveSessions(providerName, options) {
8
+ if (options.newSessionId && options.resumeSessionId) {
9
+ throw new Error(`${providerName} provider: newSessionId and resumeSessionId are mutually exclusive`);
10
+ }
11
+ }
12
+ /**
13
+ * Emit a single-line debug breadcrumb when a provider invocation produces no
14
+ * usable output and is about to be classified as a failure. Matches the
15
+ * `[<provider>-provider] exit=<code> stderr=<truncated>` format originally
16
+ * added to the claude provider so triage logs read the same regardless of
17
+ * which CLI failed.
18
+ */
19
+ export function logClassificationFailure(providerName, exitCode, stderr) {
20
+ process.stderr.write(`[${providerName}-provider] exit=${exitCode} stderr=${stderr?.slice(0, 500) ?? ""}\n`);
21
+ }
22
+ //# sourceMappingURL=shared.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/providers/shared.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,UAAU,+BAA+B,CAC7C,YAAoB,EACpB,OAAsB;IAEtB,IAAI,OAAO,CAAC,YAAY,IAAI,OAAO,CAAC,eAAe,EAAE,CAAC;QACpD,MAAM,IAAI,KAAK,CACb,GAAG,YAAY,oEAAoE,CACpF,CAAC;IACJ,CAAC;AACH,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,wBAAwB,CACtC,YAAoB,EACpB,QAAgB,EAChB,MAA0B;IAE1B,OAAO,CAAC,MAAM,CAAC,KAAK,CAClB,IAAI,YAAY,mBAAmB,QAAQ,WAAW,MAAM,EAAE,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,IAAI,EAAE,IAAI,CACtF,CAAC;AACJ,CAAC"}
@@ -71,7 +71,7 @@ export interface Provider {
71
71
  /**
72
72
  * Probe the underlying CLI to determine whether structured output is
73
73
  * supported. Result is cached for the session lifetime. If the probe
74
- * fails or times out, returns false (use legacy path).
74
+ * fails or times out, returns false (use prompted path).
75
75
  */
76
76
  checkStructuredOutputSupport(): Promise<boolean>;
77
77
  /**
@@ -1,6 +1,6 @@
1
1
  import { z } from "zod";
2
2
  export declare const InvocationAttemptSchema: z.ZodObject<{
3
- mode: z.ZodEnum<["structured", "legacy"]>;
3
+ mode: z.ZodEffects<z.ZodEnum<["structured", "prompted"]>, "structured" | "prompted", unknown>;
4
4
  provider: z.ZodString;
5
5
  model: z.ZodNullable<z.ZodString>;
6
6
  effort: z.ZodNullable<z.ZodString>;
@@ -16,28 +16,28 @@ export declare const InvocationAttemptSchema: z.ZodObject<{
16
16
  provider: string;
17
17
  model: string | null;
18
18
  effort: string | null;
19
- ok: boolean;
20
- mode: "structured" | "legacy";
19
+ mode: "structured" | "prompted";
21
20
  prompt_chars: number;
22
21
  prompt_lines: number;
23
22
  output_chars: number | null;
24
23
  output_lines: number | null;
25
24
  duration_ms: number;
25
+ ok: boolean;
26
26
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
27
27
  error_exit_code: number | null;
28
28
  }, {
29
29
  provider: string;
30
30
  model: string | null;
31
31
  effort: string | null;
32
- ok: boolean;
33
- mode: "structured" | "legacy";
34
32
  prompt_chars: number;
35
33
  prompt_lines: number;
36
34
  output_chars: number | null;
37
35
  output_lines: number | null;
38
36
  duration_ms: number;
37
+ ok: boolean;
39
38
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
40
39
  error_exit_code: number | null;
40
+ mode?: unknown;
41
41
  }>;
42
42
  export declare const RoundMetricsSchema: z.ZodObject<{
43
43
  schema_version: z.ZodLiteral<1>;
@@ -49,7 +49,7 @@ export declare const RoundMetricsSchema: z.ZodObject<{
49
49
  completed_at: z.ZodString;
50
50
  total_duration_ms: z.ZodNumber;
51
51
  attempts: z.ZodArray<z.ZodObject<{
52
- mode: z.ZodEnum<["structured", "legacy"]>;
52
+ mode: z.ZodEffects<z.ZodEnum<["structured", "prompted"]>, "structured" | "prompted", unknown>;
53
53
  provider: z.ZodString;
54
54
  model: z.ZodNullable<z.ZodString>;
55
55
  effort: z.ZodNullable<z.ZodString>;
@@ -65,28 +65,28 @@ export declare const RoundMetricsSchema: z.ZodObject<{
65
65
  provider: string;
66
66
  model: string | null;
67
67
  effort: string | null;
68
- ok: boolean;
69
- mode: "structured" | "legacy";
68
+ mode: "structured" | "prompted";
70
69
  prompt_chars: number;
71
70
  prompt_lines: number;
72
71
  output_chars: number | null;
73
72
  output_lines: number | null;
74
73
  duration_ms: number;
74
+ ok: boolean;
75
75
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
76
76
  error_exit_code: number | null;
77
77
  }, {
78
78
  provider: string;
79
79
  model: string | null;
80
80
  effort: string | null;
81
- ok: boolean;
82
- mode: "structured" | "legacy";
83
81
  prompt_chars: number;
84
82
  prompt_lines: number;
85
83
  output_chars: number | null;
86
84
  output_lines: number | null;
87
85
  duration_ms: number;
86
+ ok: boolean;
88
87
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
89
88
  error_exit_code: number | null;
89
+ mode?: unknown;
90
90
  }>, "many">;
91
91
  revision_mode: z.ZodOptional<z.ZodNullable<z.ZodEnum<["full", "edits"]>>>;
92
92
  edits_attempted: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
@@ -109,13 +109,13 @@ export declare const RoundMetricsSchema: z.ZodObject<{
109
109
  provider: string;
110
110
  model: string | null;
111
111
  effort: string | null;
112
- ok: boolean;
113
- mode: "structured" | "legacy";
112
+ mode: "structured" | "prompted";
114
113
  prompt_chars: number;
115
114
  prompt_lines: number;
116
115
  output_chars: number | null;
117
116
  output_lines: number | null;
118
117
  duration_ms: number;
118
+ ok: boolean;
119
119
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
120
120
  error_exit_code: number | null;
121
121
  }[];
@@ -140,15 +140,15 @@ export declare const RoundMetricsSchema: z.ZodObject<{
140
140
  provider: string;
141
141
  model: string | null;
142
142
  effort: string | null;
143
- ok: boolean;
144
- mode: "structured" | "legacy";
145
143
  prompt_chars: number;
146
144
  prompt_lines: number;
147
145
  output_chars: number | null;
148
146
  output_lines: number | null;
149
147
  duration_ms: number;
148
+ ok: boolean;
150
149
  error_kind: "capability" | "fatal" | "parse" | "zod" | "edit-retry" | null;
151
150
  error_exit_code: number | null;
151
+ mode?: unknown;
152
152
  }[];
153
153
  revision_mode?: "edits" | "full" | null | undefined;
154
154
  planner_mode?: "external" | "inline" | undefined;
@@ -1,6 +1,17 @@
1
1
  import { z } from "zod";
2
+ // Schema-enforcement mode for a single provider invocation:
3
+ // - "structured": output shape was constrained at the API level via the
4
+ // provider's schema flag (`--json-schema`, `--output-schema`).
5
+ // - "prompted": output shape was requested through prompt instructions
6
+ // wrapped in `<planpong-feedback>` / `<planpong-revision>` tags, then
7
+ // extracted and parsed. Used when the provider lacks a schema flag
8
+ // (e.g., gemini) or after a structured-mode failure downgrades.
9
+ //
10
+ // Reads accept the historical name `"legacy"` and normalize it to
11
+ // `"prompted"` so metrics files written before the rename still parse.
12
+ const InvocationModeSchema = z.preprocess((value) => (value === "legacy" ? "prompted" : value), z.enum(["structured", "prompted"]));
2
13
  export const InvocationAttemptSchema = z.object({
3
- mode: z.enum(["structured", "legacy"]),
14
+ mode: InvocationModeSchema,
4
15
  provider: z.string(),
5
16
  model: z.string().nullable(),
6
17
  effort: z.string().nullable(),
@@ -12,7 +23,7 @@ export const InvocationAttemptSchema = z.object({
12
23
  ok: z.boolean(),
13
24
  // `edit-retry` marks the targeted retry pass for failed edits in
14
25
  // edits-mode revisions. It is not a state-machine downgrade — the
15
- // structured/legacy mode is captured in `mode` independently.
26
+ // structured/prompted mode is captured in `mode` independently.
16
27
  error_kind: z
17
28
  .enum(["capability", "fatal", "parse", "zod", "edit-retry"])
18
29
  .nullable(),
@@ -1 +1 @@
1
- {"version":3,"file":"metrics.js","sourceRoot":"","sources":["../../../src/schemas/metrics.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,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odObject<{
51
51
  model?: string | undefined;
52
52
  effort?: string | undefined;
53
53
  };
54
- plannerMode: "external" | "inline";
55
54
  repoRoot: string;
56
55
  planPath: string;
57
56
  planPathAbsolute: string;
58
57
  currentRound: number;
59
58
  startedAt: string;
60
59
  planHash: string;
60
+ plannerMode: "external" | "inline";
61
61
  initialLineCount?: number | undefined;
62
62
  reviewerSessionId?: string | undefined;
63
63
  reviewerSessionInitialized?: boolean | undefined;
@@ -80,9 +80,9 @@ export declare const SessionSchema: z.ZodObject<{
80
80
  currentRound: number;
81
81
  startedAt: string;
82
82
  planHash: string;
83
- plannerMode?: "external" | "inline" | undefined;
84
83
  initialLineCount?: number | undefined;
85
84
  reviewerSessionId?: string | undefined;
86
85
  reviewerSessionInitialized?: boolean | undefined;
86
+ plannerMode?: "external" | "inline" | undefined;
87
87
  }>;
88
88
  export type Session = z.infer<typeof SessionSchema>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "planpong",
3
- "version": "0.5.6",
3
+ "version": "0.6.0",
4
4
  "description": "Multi-model adversarial plan review — orchestrates AI agents to critique and refine implementation plans",
5
5
  "type": "module",
6
6
  "bin": {
@@ -28,7 +28,8 @@
28
28
  "adversarial",
29
29
  "ai-agents",
30
30
  "claude",
31
- "codex"
31
+ "codex",
32
+ "gemini"
32
33
  ],
33
34
  "repository": {
34
35
  "type": "git",