opencode-antigravity-auth-remix 1.0.7
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/LICENSE +21 -0
- package/README.md +723 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -0
- package/dist/src/antigravity/oauth.d.ts +31 -0
- package/dist/src/antigravity/oauth.d.ts.map +1 -0
- package/dist/src/antigravity/oauth.js +168 -0
- package/dist/src/antigravity/oauth.js.map +1 -0
- package/dist/src/constants.d.ts +107 -0
- package/dist/src/constants.d.ts.map +1 -0
- package/dist/src/constants.js +138 -0
- package/dist/src/constants.js.map +1 -0
- package/dist/src/hooks/auto-update-checker/cache.d.ts +3 -0
- package/dist/src/hooks/auto-update-checker/cache.d.ts.map +1 -0
- package/dist/src/hooks/auto-update-checker/cache.js +71 -0
- package/dist/src/hooks/auto-update-checker/cache.js.map +1 -0
- package/dist/src/hooks/auto-update-checker/checker.d.ts +16 -0
- package/dist/src/hooks/auto-update-checker/checker.d.ts.map +1 -0
- package/dist/src/hooks/auto-update-checker/checker.js +237 -0
- package/dist/src/hooks/auto-update-checker/checker.js.map +1 -0
- package/dist/src/hooks/auto-update-checker/constants.d.ts +9 -0
- package/dist/src/hooks/auto-update-checker/constants.d.ts.map +1 -0
- package/dist/src/hooks/auto-update-checker/constants.js +23 -0
- package/dist/src/hooks/auto-update-checker/constants.js.map +1 -0
- package/dist/src/hooks/auto-update-checker/index.d.ts +34 -0
- package/dist/src/hooks/auto-update-checker/index.d.ts.map +1 -0
- package/dist/src/hooks/auto-update-checker/index.js +125 -0
- package/dist/src/hooks/auto-update-checker/index.js.map +1 -0
- package/dist/src/hooks/auto-update-checker/types.d.ts +25 -0
- package/dist/src/hooks/auto-update-checker/types.d.ts.map +1 -0
- package/dist/src/hooks/auto-update-checker/types.js +1 -0
- package/dist/src/hooks/auto-update-checker/types.js.map +1 -0
- package/dist/src/plugin/accounts.d.ts +58 -0
- package/dist/src/plugin/accounts.d.ts.map +1 -0
- package/dist/src/plugin/accounts.js +350 -0
- package/dist/src/plugin/accounts.js.map +1 -0
- package/dist/src/plugin/auth.d.ts +21 -0
- package/dist/src/plugin/auth.d.ts.map +1 -0
- package/dist/src/plugin/auth.js +46 -0
- package/dist/src/plugin/auth.js.map +1 -0
- package/dist/src/plugin/cache/index.d.ts +5 -0
- package/dist/src/plugin/cache/index.d.ts.map +1 -0
- package/dist/src/plugin/cache/index.js +5 -0
- package/dist/src/plugin/cache/index.js.map +1 -0
- package/dist/src/plugin/cache/signature-cache.d.ts +111 -0
- package/dist/src/plugin/cache/signature-cache.d.ts.map +1 -0
- package/dist/src/plugin/cache/signature-cache.js +373 -0
- package/dist/src/plugin/cache/signature-cache.js.map +1 -0
- package/dist/src/plugin/cache.d.ts +44 -0
- package/dist/src/plugin/cache.d.ts.map +1 -0
- package/dist/src/plugin/cache.js +200 -0
- package/dist/src/plugin/cache.js.map +1 -0
- package/dist/src/plugin/cli.d.ts +19 -0
- package/dist/src/plugin/cli.d.ts.map +1 -0
- package/dist/src/plugin/cli.js +59 -0
- package/dist/src/plugin/cli.js.map +1 -0
- package/dist/src/plugin/config/index.d.ts +16 -0
- package/dist/src/plugin/config/index.d.ts.map +1 -0
- package/dist/src/plugin/config/index.js +16 -0
- package/dist/src/plugin/config/index.js.map +1 -0
- package/dist/src/plugin/config/loader.d.ts +35 -0
- package/dist/src/plugin/config/loader.d.ts.map +1 -0
- package/dist/src/plugin/config/loader.js +178 -0
- package/dist/src/plugin/config/loader.js.map +1 -0
- package/dist/src/plugin/config/schema.d.ts +257 -0
- package/dist/src/plugin/config/schema.d.ts.map +1 -0
- package/dist/src/plugin/config/schema.js +229 -0
- package/dist/src/plugin/config/schema.js.map +1 -0
- package/dist/src/plugin/core/streaming/index.d.ts +3 -0
- package/dist/src/plugin/core/streaming/index.d.ts.map +1 -0
- package/dist/src/plugin/core/streaming/index.js +3 -0
- package/dist/src/plugin/core/streaming/index.js.map +1 -0
- package/dist/src/plugin/core/streaming/transformer.d.ts +9 -0
- package/dist/src/plugin/core/streaming/transformer.d.ts.map +1 -0
- package/dist/src/plugin/core/streaming/transformer.js +134 -0
- package/dist/src/plugin/core/streaming/transformer.js.map +1 -0
- package/dist/src/plugin/core/streaming/types.d.ts +26 -0
- package/dist/src/plugin/core/streaming/types.d.ts.map +1 -0
- package/dist/src/plugin/core/streaming/types.js +1 -0
- package/dist/src/plugin/core/streaming/types.js.map +1 -0
- package/dist/src/plugin/debug.d.ts +68 -0
- package/dist/src/plugin/debug.d.ts.map +1 -0
- package/dist/src/plugin/debug.js +321 -0
- package/dist/src/plugin/debug.js.map +1 -0
- package/dist/src/plugin/errors.d.ts +28 -0
- package/dist/src/plugin/errors.d.ts.map +1 -0
- package/dist/src/plugin/errors.js +42 -0
- package/dist/src/plugin/errors.js.map +1 -0
- package/dist/src/plugin/logger.d.ts +54 -0
- package/dist/src/plugin/logger.d.ts.map +1 -0
- package/dist/src/plugin/logger.js +120 -0
- package/dist/src/plugin/logger.js.map +1 -0
- package/dist/src/plugin/project.d.ts +33 -0
- package/dist/src/plugin/project.d.ts.map +1 -0
- package/dist/src/plugin/project.js +239 -0
- package/dist/src/plugin/project.js.map +1 -0
- package/dist/src/plugin/recovery/constants.d.ts +22 -0
- package/dist/src/plugin/recovery/constants.d.ts.map +1 -0
- package/dist/src/plugin/recovery/constants.js +43 -0
- package/dist/src/plugin/recovery/constants.js.map +1 -0
- package/dist/src/plugin/recovery/index.d.ts +12 -0
- package/dist/src/plugin/recovery/index.d.ts.map +1 -0
- package/dist/src/plugin/recovery/index.js +12 -0
- package/dist/src/plugin/recovery/index.js.map +1 -0
- package/dist/src/plugin/recovery/storage.d.ts +24 -0
- package/dist/src/plugin/recovery/storage.d.ts.map +1 -0
- package/dist/src/plugin/recovery/storage.js +354 -0
- package/dist/src/plugin/recovery/storage.js.map +1 -0
- package/dist/src/plugin/recovery/types.d.ts +116 -0
- package/dist/src/plugin/recovery/types.d.ts.map +1 -0
- package/dist/src/plugin/recovery/types.js +6 -0
- package/dist/src/plugin/recovery/types.js.map +1 -0
- package/dist/src/plugin/recovery.d.ts +61 -0
- package/dist/src/plugin/recovery.d.ts.map +1 -0
- package/dist/src/plugin/recovery.js +376 -0
- package/dist/src/plugin/recovery.js.map +1 -0
- package/dist/src/plugin/refresh-queue.d.ts +101 -0
- package/dist/src/plugin/refresh-queue.d.ts.map +1 -0
- package/dist/src/plugin/refresh-queue.js +244 -0
- package/dist/src/plugin/refresh-queue.js.map +1 -0
- package/dist/src/plugin/request-helpers.d.ts +270 -0
- package/dist/src/plugin/request-helpers.d.ts.map +1 -0
- package/dist/src/plugin/request-helpers.js +2158 -0
- package/dist/src/plugin/request-helpers.js.map +1 -0
- package/dist/src/plugin/request.d.ts +87 -0
- package/dist/src/plugin/request.d.ts.map +1 -0
- package/dist/src/plugin/request.js +1233 -0
- package/dist/src/plugin/request.js.map +1 -0
- package/dist/src/plugin/search.d.ts +19 -0
- package/dist/src/plugin/search.d.ts.map +1 -0
- package/dist/src/plugin/search.js +191 -0
- package/dist/src/plugin/search.js.map +1 -0
- package/dist/src/plugin/server.d.ts +23 -0
- package/dist/src/plugin/server.d.ts.map +1 -0
- package/dist/src/plugin/server.js +222 -0
- package/dist/src/plugin/server.js.map +1 -0
- package/dist/src/plugin/storage.d.ts +77 -0
- package/dist/src/plugin/storage.d.ts.map +1 -0
- package/dist/src/plugin/storage.js +207 -0
- package/dist/src/plugin/storage.js.map +1 -0
- package/dist/src/plugin/stores/signature-store.d.ts +5 -0
- package/dist/src/plugin/stores/signature-store.d.ts.map +1 -0
- package/dist/src/plugin/stores/signature-store.js +25 -0
- package/dist/src/plugin/stores/signature-store.js.map +1 -0
- package/dist/src/plugin/thinking-recovery.d.ts +90 -0
- package/dist/src/plugin/thinking-recovery.d.ts.map +1 -0
- package/dist/src/plugin/thinking-recovery.js +316 -0
- package/dist/src/plugin/thinking-recovery.js.map +1 -0
- package/dist/src/plugin/token.d.ts +19 -0
- package/dist/src/plugin/token.d.ts.map +1 -0
- package/dist/src/plugin/token.js +128 -0
- package/dist/src/plugin/token.js.map +1 -0
- package/dist/src/plugin/transform/claude.d.ts +80 -0
- package/dist/src/plugin/transform/claude.d.ts.map +1 -0
- package/dist/src/plugin/transform/claude.js +265 -0
- package/dist/src/plugin/transform/claude.js.map +1 -0
- package/dist/src/plugin/transform/cross-model-sanitizer.d.ts +35 -0
- package/dist/src/plugin/transform/cross-model-sanitizer.d.ts.map +1 -0
- package/dist/src/plugin/transform/cross-model-sanitizer.js +225 -0
- package/dist/src/plugin/transform/cross-model-sanitizer.js.map +1 -0
- package/dist/src/plugin/transform/gemini.d.ts +63 -0
- package/dist/src/plugin/transform/gemini.d.ts.map +1 -0
- package/dist/src/plugin/transform/gemini.js +142 -0
- package/dist/src/plugin/transform/gemini.js.map +1 -0
- package/dist/src/plugin/transform/index.d.ts +14 -0
- package/dist/src/plugin/transform/index.d.ts.map +1 -0
- package/dist/src/plugin/transform/index.js +14 -0
- package/dist/src/plugin/transform/index.js.map +1 -0
- package/dist/src/plugin/transform/model-resolver.d.ts +78 -0
- package/dist/src/plugin/transform/model-resolver.d.ts.map +1 -0
- package/dist/src/plugin/transform/model-resolver.js +221 -0
- package/dist/src/plugin/transform/model-resolver.js.map +1 -0
- package/dist/src/plugin/transform/types.d.ts +93 -0
- package/dist/src/plugin/transform/types.d.ts.map +1 -0
- package/dist/src/plugin/transform/types.js +1 -0
- package/dist/src/plugin/transform/types.js.map +1 -0
- package/dist/src/plugin/types.d.ts +97 -0
- package/dist/src/plugin/types.d.ts.map +1 -0
- package/dist/src/plugin/types.js +1 -0
- package/dist/src/plugin/types.js.map +1 -0
- package/dist/src/plugin.d.ts +8 -0
- package/dist/src/plugin.d.ts.map +1 -0
- package/dist/src/plugin.js +1845 -0
- package/dist/src/plugin.js.map +1 -0
- package/package.json +65 -0
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Gemini-specific Request Transformations
|
|
3
|
+
*
|
|
4
|
+
* Handles Gemini model-specific request transformations including:
|
|
5
|
+
* - Thinking config (camelCase keys, thinkingLevel for Gemini 3)
|
|
6
|
+
* - Tool normalization (function/custom format)
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Check if a model is a Gemini model (not Claude).
|
|
10
|
+
*/
|
|
11
|
+
export function isGeminiModel(model) {
|
|
12
|
+
const lower = model.toLowerCase();
|
|
13
|
+
return lower.includes("gemini") && !lower.includes("claude");
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Check if a model is Gemini 3 (uses thinkingLevel string).
|
|
17
|
+
*/
|
|
18
|
+
export function isGemini3Model(model) {
|
|
19
|
+
return model.toLowerCase().includes("gemini-3");
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Check if a model is Gemini 2.5 (uses numeric thinkingBudget).
|
|
23
|
+
*/
|
|
24
|
+
export function isGemini25Model(model) {
|
|
25
|
+
return model.toLowerCase().includes("gemini-2.5");
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Build Gemini 3 thinking config with thinkingLevel string.
|
|
29
|
+
*/
|
|
30
|
+
export function buildGemini3ThinkingConfig(includeThoughts, thinkingLevel) {
|
|
31
|
+
return {
|
|
32
|
+
includeThoughts,
|
|
33
|
+
thinkingLevel,
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Build Gemini 2.5 thinking config with numeric thinkingBudget.
|
|
38
|
+
*/
|
|
39
|
+
export function buildGemini25ThinkingConfig(includeThoughts, thinkingBudget) {
|
|
40
|
+
return {
|
|
41
|
+
includeThoughts,
|
|
42
|
+
...(typeof thinkingBudget === "number" && thinkingBudget > 0 ? { thinkingBudget } : {}),
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Normalize tools for Gemini models.
|
|
47
|
+
* Ensures tools have proper function-style format.
|
|
48
|
+
*
|
|
49
|
+
* @returns Debug info about tool normalization
|
|
50
|
+
*/
|
|
51
|
+
export function normalizeGeminiTools(payload) {
|
|
52
|
+
let toolDebugMissing = 0;
|
|
53
|
+
const toolDebugSummaries = [];
|
|
54
|
+
if (!Array.isArray(payload.tools)) {
|
|
55
|
+
return { toolDebugMissing, toolDebugSummaries };
|
|
56
|
+
}
|
|
57
|
+
payload.tools = payload.tools.map((tool, toolIndex) => {
|
|
58
|
+
const t = tool;
|
|
59
|
+
const newTool = { ...t };
|
|
60
|
+
const schemaCandidates = [
|
|
61
|
+
newTool.function?.input_schema,
|
|
62
|
+
newTool.function?.parameters,
|
|
63
|
+
newTool.function?.inputSchema,
|
|
64
|
+
newTool.custom?.input_schema,
|
|
65
|
+
newTool.custom?.parameters,
|
|
66
|
+
newTool.parameters,
|
|
67
|
+
newTool.input_schema,
|
|
68
|
+
newTool.inputSchema,
|
|
69
|
+
].filter(Boolean);
|
|
70
|
+
const schema = schemaCandidates[0];
|
|
71
|
+
const nameCandidate = newTool.name ||
|
|
72
|
+
newTool.function?.name ||
|
|
73
|
+
newTool.custom?.name ||
|
|
74
|
+
`tool-${toolIndex}`;
|
|
75
|
+
// Ensure function has input_schema
|
|
76
|
+
if (newTool.function && !newTool.function.input_schema && schema) {
|
|
77
|
+
newTool.function.input_schema = schema;
|
|
78
|
+
}
|
|
79
|
+
// Ensure custom has input_schema
|
|
80
|
+
if (newTool.custom && !newTool.custom.input_schema && schema) {
|
|
81
|
+
newTool.custom.input_schema = schema;
|
|
82
|
+
}
|
|
83
|
+
// Create custom from function if missing
|
|
84
|
+
if (!newTool.custom && newTool.function) {
|
|
85
|
+
const fn = newTool.function;
|
|
86
|
+
newTool.custom = {
|
|
87
|
+
name: fn.name || nameCandidate,
|
|
88
|
+
description: fn.description,
|
|
89
|
+
input_schema: schema ?? { type: "object", properties: {}, additionalProperties: false },
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
// Create custom if both missing
|
|
93
|
+
if (!newTool.custom && !newTool.function) {
|
|
94
|
+
newTool.custom = {
|
|
95
|
+
name: nameCandidate,
|
|
96
|
+
description: newTool.description,
|
|
97
|
+
input_schema: schema ?? { type: "object", properties: {}, additionalProperties: false },
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
// Ensure custom has input_schema
|
|
101
|
+
if (newTool.custom && !newTool.custom.input_schema) {
|
|
102
|
+
newTool.custom.input_schema = {
|
|
103
|
+
type: "object",
|
|
104
|
+
properties: {},
|
|
105
|
+
additionalProperties: false
|
|
106
|
+
};
|
|
107
|
+
toolDebugMissing += 1;
|
|
108
|
+
}
|
|
109
|
+
toolDebugSummaries.push(`idx=${toolIndex}, hasCustom=${!!newTool.custom}, customSchema=${!!newTool.custom?.input_schema}, hasFunction=${!!newTool.function}, functionSchema=${!!newTool.function?.input_schema}`);
|
|
110
|
+
// Strip custom wrappers for Gemini; only function-style is accepted.
|
|
111
|
+
if (newTool.custom) {
|
|
112
|
+
delete newTool.custom;
|
|
113
|
+
}
|
|
114
|
+
return newTool;
|
|
115
|
+
});
|
|
116
|
+
return { toolDebugMissing, toolDebugSummaries };
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Apply all Gemini-specific transformations.
|
|
120
|
+
*/
|
|
121
|
+
export function applyGeminiTransforms(payload, options) {
|
|
122
|
+
const { model, tierThinkingBudget, tierThinkingLevel, normalizedThinking } = options;
|
|
123
|
+
// 1. Apply thinking config if needed
|
|
124
|
+
if (normalizedThinking) {
|
|
125
|
+
let thinkingConfig;
|
|
126
|
+
if (tierThinkingLevel && isGemini3Model(model)) {
|
|
127
|
+
// Gemini 3 uses thinkingLevel string
|
|
128
|
+
thinkingConfig = buildGemini3ThinkingConfig(normalizedThinking.includeThoughts ?? true, tierThinkingLevel);
|
|
129
|
+
}
|
|
130
|
+
else {
|
|
131
|
+
// Gemini 2.5 and others use numeric budget
|
|
132
|
+
const thinkingBudget = tierThinkingBudget ?? normalizedThinking.thinkingBudget;
|
|
133
|
+
thinkingConfig = buildGemini25ThinkingConfig(normalizedThinking.includeThoughts ?? true, thinkingBudget);
|
|
134
|
+
}
|
|
135
|
+
const generationConfig = (payload.generationConfig ?? {});
|
|
136
|
+
generationConfig.thinkingConfig = thinkingConfig;
|
|
137
|
+
payload.generationConfig = generationConfig;
|
|
138
|
+
}
|
|
139
|
+
// 2. Normalize tools
|
|
140
|
+
return normalizeGeminiTools(payload);
|
|
141
|
+
}
|
|
142
|
+
//# sourceMappingURL=gemini.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gemini.js","sourceRoot":"","sources":["../../../../src/plugin/transform/gemini.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,KAAa;IACzC,MAAM,KAAK,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IAClC,OAAO,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;AAC/D,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,KAAa;IAC1C,OAAO,KAAK,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;AAClD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,eAAe,CAAC,KAAa;IAC3C,OAAO,KAAK,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;AACpD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,0BAA0B,CACxC,eAAwB,EACxB,aAA2B;IAE3B,OAAO;QACL,eAAe;QACf,aAAa;KACd,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,2BAA2B,CACzC,eAAwB,EACxB,cAAuB;IAEvB,OAAO;QACL,eAAe;QACf,GAAG,CAAC,OAAO,cAAc,KAAK,QAAQ,IAAI,cAAc,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,cAAc,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BAAoB,CAAC,OAAO,CAAC,CAAC;AACvC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transform Module Index
|
|
3
|
+
*
|
|
4
|
+
* Re-exports transform functions and types for request transformation.
|
|
5
|
+
*/
|
|
6
|
+
export type { ModelFamily, ThinkingTier, TransformContext, TransformResult, TransformDebugInfo, RequestPayload, ThinkingConfig, ResolvedModel, } from "./types";
|
|
7
|
+
export { resolveModelWithTier, getModelFamily, MODEL_ALIASES, MODEL_FALLBACKS, THINKING_TIER_BUDGETS, GEMINI_3_THINKING_LEVELS, } from "./model-resolver";
|
|
8
|
+
export { isClaudeModel, isClaudeThinkingModel, configureClaudeToolConfig, buildClaudeThinkingConfig, ensureClaudeMaxOutputTokens, appendClaudeThinkingHint, normalizeClaudeTools, applyClaudeTransforms, CLAUDE_THINKING_MAX_OUTPUT_TOKENS, CLAUDE_INTERLEAVED_THINKING_HINT, } from "./claude";
|
|
9
|
+
export type { ClaudeTransformOptions, ClaudeTransformResult } from "./claude";
|
|
10
|
+
export { isGeminiModel, isGemini3Model, isGemini25Model, buildGemini3ThinkingConfig, buildGemini25ThinkingConfig, normalizeGeminiTools, applyGeminiTransforms, } from "./gemini";
|
|
11
|
+
export type { GeminiTransformOptions, GeminiTransformResult } from "./gemini";
|
|
12
|
+
export { sanitizeCrossModelPayload, sanitizeCrossModelPayloadInPlace, getModelFamily as getCrossModelFamily, stripGeminiThinkingMetadata, stripClaudeThinkingFields, } from "./cross-model-sanitizer";
|
|
13
|
+
export type { SanitizerOptions } from "./cross-model-sanitizer";
|
|
14
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/plugin/transform/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,YAAY,EACV,WAAW,EACX,YAAY,EACZ,gBAAgB,EAChB,eAAe,EACf,kBAAkB,EAClB,cAAc,EACd,cAAc,EACd,aAAa,GACd,MAAM,SAAS,CAAC;AAGjB,OAAO,EACL,oBAAoB,EACpB,cAAc,EACd,aAAa,EACb,eAAe,EACf,qBAAqB,EACrB,wBAAwB,GACzB,MAAM,kBAAkB,CAAC;AAG1B,OAAO,EACL,aAAa,EACb,qBAAqB,EACrB,yBAAyB,EACzB,yBAAyB,EACzB,2BAA2B,EAC3B,wBAAwB,EACxB,oBAAoB,EACpB,qBAAqB,EACrB,iCAAiC,EACjC,gCAAgC,GACjC,MAAM,UAAU,CAAC;AAClB,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AAG9E,OAAO,EACL,aAAa,EACb,cAAc,EACd,eAAe,EACf,0BAA0B,EAC1B,2BAA2B,EAC3B,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,UAAU,CAAC;AAClB,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AAG9E,OAAO,EACL,yBAAyB,EACzB,gCAAgC,EAChC,cAAc,IAAI,mBAAmB,EACrC,2BAA2B,EAC3B,yBAAyB,GAC1B,MAAM,yBAAyB,CAAC;AACjC,YAAY,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transform Module Index
|
|
3
|
+
*
|
|
4
|
+
* Re-exports transform functions and types for request transformation.
|
|
5
|
+
*/
|
|
6
|
+
// Model resolution
|
|
7
|
+
export { resolveModelWithTier, getModelFamily, MODEL_ALIASES, MODEL_FALLBACKS, THINKING_TIER_BUDGETS, GEMINI_3_THINKING_LEVELS, } from "./model-resolver";
|
|
8
|
+
// Claude transforms
|
|
9
|
+
export { isClaudeModel, isClaudeThinkingModel, configureClaudeToolConfig, buildClaudeThinkingConfig, ensureClaudeMaxOutputTokens, appendClaudeThinkingHint, normalizeClaudeTools, applyClaudeTransforms, CLAUDE_THINKING_MAX_OUTPUT_TOKENS, CLAUDE_INTERLEAVED_THINKING_HINT, } from "./claude";
|
|
10
|
+
// Gemini transforms
|
|
11
|
+
export { isGeminiModel, isGemini3Model, isGemini25Model, buildGemini3ThinkingConfig, buildGemini25ThinkingConfig, normalizeGeminiTools, applyGeminiTransforms, } from "./gemini";
|
|
12
|
+
// Cross-model sanitization
|
|
13
|
+
export { sanitizeCrossModelPayload, sanitizeCrossModelPayloadInPlace, getModelFamily as getCrossModelFamily, stripGeminiThinkingMetadata, stripClaudeThinkingFields, } from "./cross-model-sanitizer";
|
|
14
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/plugin/transform/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAcH,mBAAmB;AACnB,OAAO,EACL,oBAAoB,EACpB,cAAc,EACd,aAAa,EACb,eAAe,EACf,qBAAqB,EACrB,wBAAwB,GACzB,MAAM,kBAAkB,CAAC;AAE1B,oBAAoB;AACpB,OAAO,EACL,aAAa,EACb,qBAAqB,EACrB,yBAAyB,EACzB,yBAAyB,EACzB,2BAA2B,EAC3B,wBAAwB,EACxB,oBAAoB,EACpB,qBAAqB,EACrB,iCAAiC,EACjC,gCAAgC,GACjC,MAAM,UAAU,CAAC;AAGlB,oBAAoB;AACpB,OAAO,EACL,aAAa,EACb,cAAc,EACd,eAAe,EACf,0BAA0B,EAC1B,2BAA2B,EAC3B,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,UAAU,CAAC;AAGlB,2BAA2B;AAC3B,OAAO,EACL,yBAAyB,EACzB,gCAAgC,EAChC,cAAc,IAAI,mBAAmB,EACrC,2BAA2B,EAC3B,yBAAyB,GAC1B,MAAM,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model Resolution with Thinking Tier Support
|
|
3
|
+
*
|
|
4
|
+
* Resolves model names with tier suffixes (e.g., gemini-3-pro-high, claude-sonnet-4-5-thinking-low)
|
|
5
|
+
* to their actual API model names and corresponding thinking configurations.
|
|
6
|
+
*/
|
|
7
|
+
import type { ResolvedModel } from "./types";
|
|
8
|
+
/**
|
|
9
|
+
* Thinking tier budgets by model family.
|
|
10
|
+
* Claude and Gemini 2.5 Pro use numeric budgets.
|
|
11
|
+
*/
|
|
12
|
+
export declare const THINKING_TIER_BUDGETS: {
|
|
13
|
+
readonly claude: {
|
|
14
|
+
readonly low: 8192;
|
|
15
|
+
readonly medium: 16384;
|
|
16
|
+
readonly high: 32768;
|
|
17
|
+
};
|
|
18
|
+
readonly "gemini-2.5-pro": {
|
|
19
|
+
readonly low: 8192;
|
|
20
|
+
readonly medium: 16384;
|
|
21
|
+
readonly high: 32768;
|
|
22
|
+
};
|
|
23
|
+
readonly "gemini-2.5-flash": {
|
|
24
|
+
readonly low: 6144;
|
|
25
|
+
readonly medium: 12288;
|
|
26
|
+
readonly high: 24576;
|
|
27
|
+
};
|
|
28
|
+
readonly default: {
|
|
29
|
+
readonly low: 4096;
|
|
30
|
+
readonly medium: 8192;
|
|
31
|
+
readonly high: 16384;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Gemini 3 uses thinkingLevel strings instead of numeric budgets.
|
|
36
|
+
* Flash supports: low, medium, high
|
|
37
|
+
* Pro supports: low, high
|
|
38
|
+
*/
|
|
39
|
+
export declare const GEMINI_3_THINKING_LEVELS: readonly ["low", "medium", "high"];
|
|
40
|
+
/**
|
|
41
|
+
* Model aliases - maps user-friendly names to API model names.
|
|
42
|
+
*
|
|
43
|
+
* Format:
|
|
44
|
+
* - Gemini 3 Pro variants: gemini-3-pro-{low,medium,high}
|
|
45
|
+
* - Claude thinking variants: claude-{model}-thinking-{low,medium,high}
|
|
46
|
+
* - Claude non-thinking: claude-{model} (no -thinking suffix)
|
|
47
|
+
*/
|
|
48
|
+
export declare const MODEL_ALIASES: Record<string, string>;
|
|
49
|
+
/**
|
|
50
|
+
* Model fallbacks when primary model is unavailable.
|
|
51
|
+
*/
|
|
52
|
+
export declare const MODEL_FALLBACKS: Record<string, string>;
|
|
53
|
+
/**
|
|
54
|
+
* Resolves a model name with optional tier suffix and quota prefix to its actual API model name
|
|
55
|
+
* and corresponding thinking configuration.
|
|
56
|
+
*
|
|
57
|
+
* Quota routing:
|
|
58
|
+
* - "antigravity-" prefix → Antigravity quota
|
|
59
|
+
* - Claude/GPT models → Antigravity quota (auto, these only exist on Antigravity)
|
|
60
|
+
* - Legacy Gemini 3 names (gemini-3-pro-low, gemini-3-flash, etc.) → Antigravity quota (backward compat)
|
|
61
|
+
* - Other models → Gemini CLI quota (default)
|
|
62
|
+
*
|
|
63
|
+
* Examples:
|
|
64
|
+
* - "gemini-2.5-flash" → { quotaPreference: "gemini-cli" }
|
|
65
|
+
* - "gemini-3-pro-preview" → { quotaPreference: "gemini-cli" } (Gemini CLI uses -preview)
|
|
66
|
+
* - "gemini-3-pro-low" → { quotaPreference: "antigravity" } (legacy name, backward compat)
|
|
67
|
+
* - "antigravity-gemini-3-pro-high" → { quotaPreference: "antigravity" } (explicit prefix)
|
|
68
|
+
* - "claude-sonnet-4-5-thinking-medium" → { quotaPreference: "antigravity" } (Claude only on Antigravity)
|
|
69
|
+
*
|
|
70
|
+
* @param requestedModel - The model name from the request
|
|
71
|
+
* @returns Resolved model with thinking configuration
|
|
72
|
+
*/
|
|
73
|
+
export declare function resolveModelWithTier(requestedModel: string): ResolvedModel;
|
|
74
|
+
/**
|
|
75
|
+
* Gets the model family for routing decisions.
|
|
76
|
+
*/
|
|
77
|
+
export declare function getModelFamily(model: string): "claude" | "gemini-flash" | "gemini-pro";
|
|
78
|
+
//# sourceMappingURL=model-resolver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model-resolver.d.ts","sourceRoot":"","sources":["../../../../src/plugin/transform/model-resolver.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAgB,MAAM,SAAS,CAAC;AAE3D;;;GAGG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;CAKxB,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,oCAAqC,CAAC;AAE3E;;;;;;;GAOG;AACH,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAoBhD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAElD,CAAC;AAsFF;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,oBAAoB,CAAC,cAAc,EAAE,MAAM,GAAG,aAAa,CAoE1E;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,QAAQ,GAAG,cAAc,GAAG,YAAY,CAStF"}
|
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model Resolution with Thinking Tier Support
|
|
3
|
+
*
|
|
4
|
+
* Resolves model names with tier suffixes (e.g., gemini-3-pro-high, claude-sonnet-4-5-thinking-low)
|
|
5
|
+
* to their actual API model names and corresponding thinking configurations.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Thinking tier budgets by model family.
|
|
9
|
+
* Claude and Gemini 2.5 Pro use numeric budgets.
|
|
10
|
+
*/
|
|
11
|
+
export const THINKING_TIER_BUDGETS = {
|
|
12
|
+
claude: { low: 8192, medium: 16384, high: 32768 },
|
|
13
|
+
"gemini-2.5-pro": { low: 8192, medium: 16384, high: 32768 },
|
|
14
|
+
"gemini-2.5-flash": { low: 6144, medium: 12288, high: 24576 },
|
|
15
|
+
default: { low: 4096, medium: 8192, high: 16384 },
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Gemini 3 uses thinkingLevel strings instead of numeric budgets.
|
|
19
|
+
* Flash supports: low, medium, high
|
|
20
|
+
* Pro supports: low, high
|
|
21
|
+
*/
|
|
22
|
+
export const GEMINI_3_THINKING_LEVELS = ["low", "medium", "high"];
|
|
23
|
+
/**
|
|
24
|
+
* Model aliases - maps user-friendly names to API model names.
|
|
25
|
+
*
|
|
26
|
+
* Format:
|
|
27
|
+
* - Gemini 3 Pro variants: gemini-3-pro-{low,medium,high}
|
|
28
|
+
* - Claude thinking variants: claude-{model}-thinking-{low,medium,high}
|
|
29
|
+
* - Claude non-thinking: claude-{model} (no -thinking suffix)
|
|
30
|
+
*/
|
|
31
|
+
export const MODEL_ALIASES = {
|
|
32
|
+
// Gemini 3 variants - for Gemini CLI only (tier stripped, thinkingLevel used)
|
|
33
|
+
// For Antigravity, these are bypassed and full model name is kept
|
|
34
|
+
"gemini-3-pro-low": "gemini-3-pro",
|
|
35
|
+
"gemini-3-pro-high": "gemini-3-pro",
|
|
36
|
+
"gemini-3-flash-low": "gemini-3-flash",
|
|
37
|
+
"gemini-3-flash-medium": "gemini-3-flash",
|
|
38
|
+
"gemini-3-flash-high": "gemini-3-flash",
|
|
39
|
+
// Claude proxy names (gemini- prefix for compatibility)
|
|
40
|
+
"gemini-claude-sonnet-4-5": "claude-sonnet-4-5",
|
|
41
|
+
"gemini-claude-sonnet-4-5-thinking-low": "claude-sonnet-4-5-thinking",
|
|
42
|
+
"gemini-claude-sonnet-4-5-thinking-medium": "claude-sonnet-4-5-thinking",
|
|
43
|
+
"gemini-claude-sonnet-4-5-thinking-high": "claude-sonnet-4-5-thinking",
|
|
44
|
+
"gemini-claude-opus-4-5-thinking-low": "claude-opus-4-5-thinking",
|
|
45
|
+
"gemini-claude-opus-4-5-thinking-medium": "claude-opus-4-5-thinking",
|
|
46
|
+
"gemini-claude-opus-4-5-thinking-high": "claude-opus-4-5-thinking",
|
|
47
|
+
// Image variants
|
|
48
|
+
"gemini-3-pro-image-preview": "gemini-3-pro-image",
|
|
49
|
+
};
|
|
50
|
+
/**
|
|
51
|
+
* Model fallbacks when primary model is unavailable.
|
|
52
|
+
*/
|
|
53
|
+
export const MODEL_FALLBACKS = {
|
|
54
|
+
"gemini-2.5-flash-image": "gemini-2.5-flash",
|
|
55
|
+
};
|
|
56
|
+
const TIER_REGEX = /-(minimal|low|medium|high)$/;
|
|
57
|
+
const QUOTA_PREFIX_REGEX = /^antigravity-/i;
|
|
58
|
+
/**
|
|
59
|
+
* Models that only exist on Antigravity (not on Gemini CLI).
|
|
60
|
+
* These automatically route to Antigravity even without the prefix.
|
|
61
|
+
*/
|
|
62
|
+
const ANTIGRAVITY_ONLY_MODELS = /^(claude|gpt)/i;
|
|
63
|
+
/**
|
|
64
|
+
* Legacy Gemini 3 model names that should route to Antigravity quota.
|
|
65
|
+
*
|
|
66
|
+
* Backward compatibility: Since Gemini CLI now uses -preview suffix
|
|
67
|
+
* (gemini-3-pro-preview, gemini-3-flash-preview), old model names
|
|
68
|
+
* without -preview can safely route to Antigravity quota.
|
|
69
|
+
*
|
|
70
|
+
* Matches:
|
|
71
|
+
* - gemini-3-pro-low, gemini-3-pro-high
|
|
72
|
+
* - gemini-3-flash, gemini-3-flash-low, gemini-3-flash-medium, gemini-3-flash-high
|
|
73
|
+
*
|
|
74
|
+
* Does NOT match:
|
|
75
|
+
* - gemini-3-pro-preview (Gemini CLI)
|
|
76
|
+
* - gemini-3-flash-preview (Gemini CLI)
|
|
77
|
+
* - antigravity-gemini-3-* (already handled by prefix)
|
|
78
|
+
*
|
|
79
|
+
* WARNING: This may break if Google/Opencode removes the -preview suffix.
|
|
80
|
+
*/
|
|
81
|
+
const LEGACY_ANTIGRAVITY_GEMINI3 = /^gemini-3-(pro-(low|high)|flash(-low|-medium|-high)?)$/i;
|
|
82
|
+
/**
|
|
83
|
+
* Models that support thinking tier suffixes.
|
|
84
|
+
* Only these models should have -low/-medium/-high stripped as thinking tiers.
|
|
85
|
+
* GPT models like gpt-oss-120b-medium should NOT have -medium stripped.
|
|
86
|
+
*/
|
|
87
|
+
function supportsThinkingTiers(model) {
|
|
88
|
+
const lower = model.toLowerCase();
|
|
89
|
+
return (lower.includes("gemini-3") ||
|
|
90
|
+
lower.includes("gemini-2.5") ||
|
|
91
|
+
(lower.includes("claude") && lower.includes("thinking")));
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Extracts thinking tier from model name suffix.
|
|
95
|
+
* Only extracts tier for models that support thinking tiers.
|
|
96
|
+
*/
|
|
97
|
+
function extractThinkingTierFromModel(model) {
|
|
98
|
+
// Only extract tier for models that support thinking tiers
|
|
99
|
+
if (!supportsThinkingTiers(model)) {
|
|
100
|
+
return undefined;
|
|
101
|
+
}
|
|
102
|
+
const tierMatch = model.match(TIER_REGEX);
|
|
103
|
+
return tierMatch?.[1];
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Determines the budget family for a model.
|
|
107
|
+
*/
|
|
108
|
+
function getBudgetFamily(model) {
|
|
109
|
+
if (model.includes("claude")) {
|
|
110
|
+
return "claude";
|
|
111
|
+
}
|
|
112
|
+
if (model.includes("gemini-2.5-pro")) {
|
|
113
|
+
return "gemini-2.5-pro";
|
|
114
|
+
}
|
|
115
|
+
if (model.includes("gemini-2.5-flash")) {
|
|
116
|
+
return "gemini-2.5-flash";
|
|
117
|
+
}
|
|
118
|
+
return "default";
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Checks if a model is a thinking-capable model.
|
|
122
|
+
*/
|
|
123
|
+
function isThinkingCapableModel(model) {
|
|
124
|
+
const lower = model.toLowerCase();
|
|
125
|
+
return (lower.includes("thinking") ||
|
|
126
|
+
lower.includes("gemini-3") ||
|
|
127
|
+
lower.includes("gemini-2.5"));
|
|
128
|
+
}
|
|
129
|
+
/**
|
|
130
|
+
* Resolves a model name with optional tier suffix and quota prefix to its actual API model name
|
|
131
|
+
* and corresponding thinking configuration.
|
|
132
|
+
*
|
|
133
|
+
* Quota routing:
|
|
134
|
+
* - "antigravity-" prefix → Antigravity quota
|
|
135
|
+
* - Claude/GPT models → Antigravity quota (auto, these only exist on Antigravity)
|
|
136
|
+
* - Legacy Gemini 3 names (gemini-3-pro-low, gemini-3-flash, etc.) → Antigravity quota (backward compat)
|
|
137
|
+
* - Other models → Gemini CLI quota (default)
|
|
138
|
+
*
|
|
139
|
+
* Examples:
|
|
140
|
+
* - "gemini-2.5-flash" → { quotaPreference: "gemini-cli" }
|
|
141
|
+
* - "gemini-3-pro-preview" → { quotaPreference: "gemini-cli" } (Gemini CLI uses -preview)
|
|
142
|
+
* - "gemini-3-pro-low" → { quotaPreference: "antigravity" } (legacy name, backward compat)
|
|
143
|
+
* - "antigravity-gemini-3-pro-high" → { quotaPreference: "antigravity" } (explicit prefix)
|
|
144
|
+
* - "claude-sonnet-4-5-thinking-medium" → { quotaPreference: "antigravity" } (Claude only on Antigravity)
|
|
145
|
+
*
|
|
146
|
+
* @param requestedModel - The model name from the request
|
|
147
|
+
* @returns Resolved model with thinking configuration
|
|
148
|
+
*/
|
|
149
|
+
export function resolveModelWithTier(requestedModel) {
|
|
150
|
+
const isAntigravity = QUOTA_PREFIX_REGEX.test(requestedModel);
|
|
151
|
+
const modelWithoutQuota = requestedModel.replace(QUOTA_PREFIX_REGEX, "");
|
|
152
|
+
const tier = extractThinkingTierFromModel(modelWithoutQuota);
|
|
153
|
+
const baseName = tier ? modelWithoutQuota.replace(TIER_REGEX, "") : modelWithoutQuota;
|
|
154
|
+
const isAntigravityOnly = ANTIGRAVITY_ONLY_MODELS.test(modelWithoutQuota);
|
|
155
|
+
const isLegacyAntigravity = LEGACY_ANTIGRAVITY_GEMINI3.test(modelWithoutQuota);
|
|
156
|
+
const quotaPreference = isAntigravity || isAntigravityOnly || isLegacyAntigravity ? "antigravity" : "gemini-cli";
|
|
157
|
+
const explicitQuota = isAntigravity;
|
|
158
|
+
const isGemini3 = modelWithoutQuota.toLowerCase().startsWith("gemini-3");
|
|
159
|
+
const skipAlias = isAntigravity && isGemini3;
|
|
160
|
+
const actualModel = skipAlias
|
|
161
|
+
? modelWithoutQuota
|
|
162
|
+
: MODEL_ALIASES[modelWithoutQuota] || MODEL_ALIASES[baseName] || baseName;
|
|
163
|
+
const resolvedModel = MODEL_FALLBACKS[actualModel] || actualModel;
|
|
164
|
+
const isThinking = isThinkingCapableModel(resolvedModel);
|
|
165
|
+
if (!tier) {
|
|
166
|
+
if (resolvedModel === "gemini-3-flash" && !skipAlias) {
|
|
167
|
+
return {
|
|
168
|
+
actualModel: resolvedModel,
|
|
169
|
+
thinkingLevel: "minimal",
|
|
170
|
+
isThinkingModel: true,
|
|
171
|
+
quotaPreference,
|
|
172
|
+
explicitQuota,
|
|
173
|
+
};
|
|
174
|
+
}
|
|
175
|
+
return { actualModel: resolvedModel, isThinkingModel: isThinking, quotaPreference, explicitQuota };
|
|
176
|
+
}
|
|
177
|
+
if (resolvedModel.includes("gemini-3") && !skipAlias) {
|
|
178
|
+
return {
|
|
179
|
+
actualModel: resolvedModel,
|
|
180
|
+
thinkingLevel: tier,
|
|
181
|
+
tier,
|
|
182
|
+
isThinkingModel: true,
|
|
183
|
+
quotaPreference,
|
|
184
|
+
explicitQuota,
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
if (skipAlias) {
|
|
188
|
+
return {
|
|
189
|
+
actualModel: resolvedModel,
|
|
190
|
+
tier,
|
|
191
|
+
isThinkingModel: true,
|
|
192
|
+
quotaPreference,
|
|
193
|
+
explicitQuota,
|
|
194
|
+
};
|
|
195
|
+
}
|
|
196
|
+
const budgetFamily = getBudgetFamily(resolvedModel);
|
|
197
|
+
const budgets = THINKING_TIER_BUDGETS[budgetFamily];
|
|
198
|
+
const thinkingBudget = budgets[tier];
|
|
199
|
+
return {
|
|
200
|
+
actualModel: resolvedModel,
|
|
201
|
+
thinkingBudget,
|
|
202
|
+
tier,
|
|
203
|
+
isThinkingModel: isThinking,
|
|
204
|
+
quotaPreference,
|
|
205
|
+
explicitQuota,
|
|
206
|
+
};
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Gets the model family for routing decisions.
|
|
210
|
+
*/
|
|
211
|
+
export function getModelFamily(model) {
|
|
212
|
+
const lower = model.toLowerCase();
|
|
213
|
+
if (lower.includes("claude")) {
|
|
214
|
+
return "claude";
|
|
215
|
+
}
|
|
216
|
+
if (lower.includes("flash")) {
|
|
217
|
+
return "gemini-flash";
|
|
218
|
+
}
|
|
219
|
+
return "gemini-pro";
|
|
220
|
+
}
|
|
221
|
+
//# sourceMappingURL=model-resolver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model-resolver.js","sourceRoot":"","sources":["../../../../src/plugin/transform/model-resolver.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH;;;GAGG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,MAAM,EAAE,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE;IACjD,gBAAgB,EAAE,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE;IAC3D,kBAAkB,EAAE,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE;IAC7D,OAAO,EAAE,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE;CACzC,CAAC;AAEX;;;;GAIG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,KAAK,EAAE,QAAQ,EAAE,MAAM,CAAU,CAAC;AAE3E;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,aAAa,GAA2B;IACnD,8EAA8E;IAC9E,kEAAkE;IAClE,kBAAkB,EAAE,cAAc;IAClC,mBAAmB,EAAE,cAAc;IACnC,oBAAoB,EAAE,gBAAgB;IACtC,uBAAuB,EAAE,gBAAgB;IACzC,qBAAqB,EAAE,gBAAgB;IAEvC,wDAAwD;IACxD,0BAA0B,EAAE,mBAAmB;IAC/C,uCAAuC,EA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C,YAAY,CAAC,CAAC;IACpD,MAAM,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErC,OAAO;QACL,WAAW,EAAE,aAAa;QAC1B,cAAc;QACd,IAAI;QACJ,eAAe,EAAE,UAAU;QAC3B,eAAe;QACf,aAAa;KACd,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,KAAa;IAC1C,MAAM,KAAK,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IAClC,IAAI,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC7B,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,IAAI,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,CAAC;QAC5B,OAAO,cAAc,CAAC;IACxB,CAAC;IACD,OAAO,YAAY,CAAC;AACtB,CAAC"}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import type { HeaderStyle } from "../../constants";
|
|
2
|
+
export type ModelFamily = "claude" | "gemini-flash" | "gemini-pro";
|
|
3
|
+
export type ThinkingTier = "low" | "medium" | "high";
|
|
4
|
+
/**
|
|
5
|
+
* Context for request transformation.
|
|
6
|
+
* Contains all information needed to transform a request payload.
|
|
7
|
+
*/
|
|
8
|
+
export interface TransformContext {
|
|
9
|
+
/** The resolved project ID for the API call */
|
|
10
|
+
projectId: string;
|
|
11
|
+
/** The resolved model name (after alias resolution) */
|
|
12
|
+
model: string;
|
|
13
|
+
/** The original model name from the request */
|
|
14
|
+
requestedModel: string;
|
|
15
|
+
/** Model family for routing decisions */
|
|
16
|
+
family: ModelFamily;
|
|
17
|
+
/** Whether this is a streaming request */
|
|
18
|
+
streaming: boolean;
|
|
19
|
+
/** Unique request ID for tracking */
|
|
20
|
+
requestId: string;
|
|
21
|
+
/** Session ID for signature caching */
|
|
22
|
+
sessionId?: string;
|
|
23
|
+
/** Thinking tier if specified via model suffix */
|
|
24
|
+
thinkingTier?: ThinkingTier;
|
|
25
|
+
/** Thinking budget for Claude models (derived from tier) */
|
|
26
|
+
thinkingBudget?: number;
|
|
27
|
+
/** Thinking level for Gemini 3 models (derived from tier) */
|
|
28
|
+
thinkingLevel?: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Result of request transformation.
|
|
32
|
+
*/
|
|
33
|
+
export interface TransformResult {
|
|
34
|
+
/** The transformed request body as JSON string */
|
|
35
|
+
body: string;
|
|
36
|
+
/** Debug information about the transformation */
|
|
37
|
+
debugInfo: TransformDebugInfo;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Debug information from transformation.
|
|
41
|
+
*/
|
|
42
|
+
export interface TransformDebugInfo {
|
|
43
|
+
/** Which transformer was used */
|
|
44
|
+
transformer: "claude" | "gemini";
|
|
45
|
+
/** Number of tools in the request */
|
|
46
|
+
toolCount: number;
|
|
47
|
+
/** Whether tools were transformed */
|
|
48
|
+
toolsTransformed?: boolean;
|
|
49
|
+
/** Thinking tier if resolved */
|
|
50
|
+
thinkingTier?: string;
|
|
51
|
+
/** Thinking budget if set */
|
|
52
|
+
thinkingBudget?: number;
|
|
53
|
+
/** Thinking level if set (Gemini 3) */
|
|
54
|
+
thinkingLevel?: string;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Generic request payload type.
|
|
58
|
+
* The actual structure varies between Claude and Gemini.
|
|
59
|
+
*/
|
|
60
|
+
export type RequestPayload = Record<string, unknown>;
|
|
61
|
+
/**
|
|
62
|
+
* Thinking configuration normalized from various input formats.
|
|
63
|
+
*/
|
|
64
|
+
export interface ThinkingConfig {
|
|
65
|
+
/** Numeric thinking budget (for Claude and Gemini 2.5) */
|
|
66
|
+
thinkingBudget?: number;
|
|
67
|
+
/** String thinking level (for Gemini 3: 'low', 'medium', 'high') */
|
|
68
|
+
thinkingLevel?: string;
|
|
69
|
+
/** Whether to include thinking in the response */
|
|
70
|
+
includeThoughts?: boolean;
|
|
71
|
+
/** Snake_case variant for Antigravity backend */
|
|
72
|
+
include_thoughts?: boolean;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Model resolution result with tier information.
|
|
76
|
+
*/
|
|
77
|
+
export interface ResolvedModel {
|
|
78
|
+
/** The actual model name for the API call */
|
|
79
|
+
actualModel: string;
|
|
80
|
+
/** Thinking level for Gemini 3 models */
|
|
81
|
+
thinkingLevel?: string;
|
|
82
|
+
/** Thinking budget for Claude/Gemini 2.5 */
|
|
83
|
+
thinkingBudget?: number;
|
|
84
|
+
/** The tier suffix that was extracted */
|
|
85
|
+
tier?: ThinkingTier;
|
|
86
|
+
/** Whether this is a thinking-capable model */
|
|
87
|
+
isThinkingModel?: boolean;
|
|
88
|
+
/** Quota preference based on :antigravity or :gemini-cli suffix */
|
|
89
|
+
quotaPreference?: HeaderStyle;
|
|
90
|
+
/** Whether user explicitly specified quota via suffix (vs default selection) */
|
|
91
|
+
explicitQuota?: boolean;
|
|
92
|
+
}
|
|
93
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/plugin/transform/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,MAAM,MAAM,WAAW,GAAG,QAAQ,GAAG,cAAc,GAAG,YAAY,CAAC;AAEnE,MAAM,MAAM,YAAY,GAAG,KAAK,GAAG,QAAQ,GAAG,MAAM,CAAC;AAErD;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,+CAA+C;IAC/C,SAAS,EAAE,MAAM,CAAC;IAClB,uDAAuD;IACvD,KAAK,EAAE,MAAM,CAAC;IACd,+CAA+C;IAC/C,cAAc,EAAE,MAAM,CAAC;IACvB,yCAAyC;IACzC,MAAM,EAAE,WAAW,CAAC;IACpB,0CAA0C;IAC1C,SAAS,EAAE,OAAO,CAAC;IACnB,qCAAqC;IACrC,SAAS,EAAE,MAAM,CA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AyC;IACzC,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,+CAA+C;IAC/C,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,mEAAmE;IACnE,eAAe,CAAC,EAAE,WAAW,CAAC;IAC9B,gFAAgF;IAChF,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/plugin/transform/types.ts"],"names":[],"mappings":""}
|