feat(pi): add 'max' thinking level support (#2267)

* feat(pi): add 'max' thinking level support

Pi recently introduced a new 'max' thinking level beyond 'xhigh'.
This adds it to the type union, the UI options array, and the
runtime type guard so Paseo users can select it.

Changes:
- rpc-types.ts: add 'max' to PiThinkingLevel union
- agent.ts: add max entry to PI_THINKING_OPTIONS
- agent.ts: add 'max' to isPiThinkingLevel guard

* fix(pi): clarify xhigh description after adding max level

xhigh's 'Maximum reasoning' is now misleading since max is the true
maximum. Changed to 'Very deep reasoning' per review feedback.
This commit is contained in:
True Byte
2026-07-21 05:39:46 +08:00
committed by GitHub
parent 187561e433
commit ddb6d97bf0
2 changed files with 5 additions and 3 deletions

View File

@@ -173,7 +173,8 @@ const PI_THINKING_OPTIONS: ReadonlyArray<{
{ id: "low", label: "Low", description: "Faster reasoning" },
{ id: "medium", label: "Medium", description: "Balanced reasoning", isDefault: true },
{ id: "high", label: "High", description: "Deeper reasoning" },
{ id: "xhigh", label: "XHigh", description: "Maximum reasoning" },
{ id: "xhigh", label: "XHigh", description: "Very deep reasoning" },
{ id: "max", label: "Max", description: "Extreme reasoning" },
] as const;
export interface PiRpcAgentClientOptions {
@@ -329,7 +330,8 @@ function isPiThinkingLevel(value: string | null | undefined): value is PiThinkin
value === "low" ||
value === "medium" ||
value === "high" ||
value === "xhigh"
value === "xhigh" ||
value === "max"
);
}

View File

@@ -1,4 +1,4 @@
export type PiThinkingLevel = "off" | "minimal" | "low" | "medium" | "high" | "xhigh";
export type PiThinkingLevel = "off" | "minimal" | "low" | "medium" | "high" | "xhigh" | "max";
export interface PiImageContent {
type: "image";