feat(antigravity): comprehensive enhancements - model mapping, rate limiting, scheduling & ops
Key changes: - Upgrade model mapping: Opus 4.5 → Opus 4.6-thinking with precise matching - Unified rate limiting: scope-level → model-level with Redis snapshot sync - Load-balanced scheduling by call count with smart retry mechanism - Force cache billing support - Model identity injection in prompts with leak prevention - Thinking mode auto-handling (max_tokens/budget_tokens fix) - Frontend: whitelist mode toggle, model mapping validation, status indicators - Gemini session fallback with Redis Trie O(L) matching - Ops: enhanced concurrency monitoring, account availability, retry logic - Migration scripts: 049-051 for model mapping unification
This commit is contained in:
@@ -337,6 +337,22 @@ export interface OpsConcurrencyStatsResponse {
|
||||
timestamp?: string
|
||||
}
|
||||
|
||||
export interface UserConcurrencyInfo {
|
||||
user_id: number
|
||||
user_email: string
|
||||
username: string
|
||||
current_in_use: number
|
||||
max_capacity: number
|
||||
load_percentage: number
|
||||
waiting_in_queue: number
|
||||
}
|
||||
|
||||
export interface OpsUserConcurrencyStatsResponse {
|
||||
enabled: boolean
|
||||
user: Record<string, UserConcurrencyInfo>
|
||||
timestamp?: string
|
||||
}
|
||||
|
||||
export async function getConcurrencyStats(platform?: string, groupId?: number | null): Promise<OpsConcurrencyStatsResponse> {
|
||||
const params: Record<string, any> = {}
|
||||
if (platform) {
|
||||
@@ -350,6 +366,11 @@ export async function getConcurrencyStats(platform?: string, groupId?: number |
|
||||
return data
|
||||
}
|
||||
|
||||
export async function getUserConcurrencyStats(): Promise<OpsUserConcurrencyStatsResponse> {
|
||||
const { data } = await apiClient.get<OpsUserConcurrencyStatsResponse>('/admin/ops/user-concurrency')
|
||||
return data
|
||||
}
|
||||
|
||||
export interface PlatformAvailability {
|
||||
platform: string
|
||||
total_accounts: number
|
||||
@@ -1171,6 +1192,7 @@ export const opsAPI = {
|
||||
getErrorTrend,
|
||||
getErrorDistribution,
|
||||
getConcurrencyStats,
|
||||
getUserConcurrencyStats,
|
||||
getAccountAvailabilityStats,
|
||||
getRealtimeTrafficSummary,
|
||||
subscribeQPS,
|
||||
|
||||
Reference in New Issue
Block a user