move fallback map to constants
This commit is contained in:
@@ -144,6 +144,15 @@ export const OAUTH_CONFIG = {
|
|||||||
};
|
};
|
||||||
export const OAUTH_REDIRECT_URI = `http://localhost:${OAUTH_CONFIG.callbackPort}/oauth-callback`;
|
export const OAUTH_REDIRECT_URI = `http://localhost:${OAUTH_CONFIG.callbackPort}/oauth-callback`;
|
||||||
|
|
||||||
|
// Model fallback mapping - maps primary model to fallback when quota exhausted
|
||||||
|
export const MODEL_FALLBACK_MAP = {
|
||||||
|
'gemini-3-pro-high': 'claude-sonnet-4-5-thinking',
|
||||||
|
'gemini-3-pro-low': 'claude-sonnet-4-5',
|
||||||
|
'claude-opus-4-5-thinking': 'gemini-3-pro-high',
|
||||||
|
'claude-sonnet-4-5-thinking': 'gemini-3-pro-high',
|
||||||
|
'claude-sonnet-4-5': 'gemini-3-pro-low'
|
||||||
|
};
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
ANTIGRAVITY_ENDPOINT_FALLBACKS,
|
ANTIGRAVITY_ENDPOINT_FALLBACKS,
|
||||||
ANTIGRAVITY_HEADERS,
|
ANTIGRAVITY_HEADERS,
|
||||||
@@ -165,5 +174,6 @@ export default {
|
|||||||
getModelFamily,
|
getModelFamily,
|
||||||
isThinkingModel,
|
isThinkingModel,
|
||||||
OAUTH_CONFIG,
|
OAUTH_CONFIG,
|
||||||
OAUTH_REDIRECT_URI
|
OAUTH_REDIRECT_URI,
|
||||||
|
MODEL_FALLBACK_MAP
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -5,17 +5,10 @@
|
|||||||
* Enables graceful degradation to alternative models with similar capabilities.
|
* Enables graceful degradation to alternative models with similar capabilities.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
import { MODEL_FALLBACK_MAP } from './constants.js';
|
||||||
* Model fallback mapping
|
|
||||||
* Maps primary model ID to fallback model ID
|
// Re-export for convenience
|
||||||
*/
|
export { MODEL_FALLBACK_MAP };
|
||||||
export const MODEL_FALLBACK_MAP = {
|
|
||||||
'gemini-3-pro-high': 'claude-sonnet-4-5-thinking',
|
|
||||||
'gemini-3-pro-low': 'claude-sonnet-4-5',
|
|
||||||
'claude-opus-4-5-thinking': 'gemini-3-pro-high',
|
|
||||||
'claude-sonnet-4-5-thinking': 'gemini-3-pro-high',
|
|
||||||
'claude-sonnet-4-5': 'gemini-3-pro-low'
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get fallback model for a given model ID
|
* Get fallback model for a given model ID
|
||||||
|
|||||||
Reference in New Issue
Block a user