@asframe/opencode-iflow-auth 1.0.5 → 1.0.6

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.
@@ -13,7 +13,7 @@ export declare const IFLOW_CONSTANTS: {
13
13
  CALLBACK_PORT_START: number;
14
14
  CALLBACK_PORT_RANGE: number;
15
15
  };
16
- export declare const THINKING_MODELS: string[];
16
+ export declare const THINKING_MODEL_PATTERNS: RegExp[];
17
17
  export declare function isThinkingModel(model: string): boolean;
18
18
  export declare function applyThinkingConfig(body: any, model: string): any;
19
19
  export interface IFlowModelConfig {
package/dist/constants.js CHANGED
@@ -14,9 +14,19 @@ export const IFLOW_CONSTANTS = {
14
14
  CALLBACK_PORT_START: 8087,
15
15
  CALLBACK_PORT_RANGE: 10
16
16
  };
17
- export const THINKING_MODELS = ['glm-4.6', 'glm-5', 'qwen3-235b-a22b-thinking-2507', 'deepseek-r1'];
17
+ export const THINKING_MODEL_PATTERNS = [
18
+ /^glm-5/,
19
+ /^glm-4\.7/,
20
+ /^glm-4\.6/,
21
+ /^glm-4/,
22
+ /deepseek/,
23
+ /thinking/,
24
+ /reasoning/,
25
+ /^kimi-k2\.5/,
26
+ /^o1-/
27
+ ];
18
28
  export function isThinkingModel(model) {
19
- return THINKING_MODELS.some((m) => model.startsWith(m));
29
+ return THINKING_MODEL_PATTERNS.some(pattern => pattern.test(model));
20
30
  }
21
31
  export function applyThinkingConfig(body, model) {
22
32
  const thinkingBudget = body.providerOptions?.thinkingConfig?.thinkingBudget;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@asframe/opencode-iflow-auth",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "OpenCode plugin for iFlow.cn - Access Qwen, DeepSeek, Kimi, GLM-5 models with OAuth 2.0, API Key, and CLI Proxy support",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",