保留平台模型 RPM、TPM 和并发策略语义,增加 PostgreSQL 集群级租约、饱和候选重选和多平台自动负载,避免突发任务固定等待首个平台。\n\n新增 Worker 实时负载采样、自适应 active/heavy 容量、心跳与管理端指标,并扩展本地 acceptance runner,覆盖三 Worker、同模型三平台 2/4/6 并发和 48 个带图视频突发任务。\n\n验证:go test ./...、go vet ./...、PostgreSQL 跨 Store 集成测试、gofmt、bash -n、ShellCheck 及本地集群 provider-burst 验收通过;48/48 成功,无越限、重复提交、重复计费、重复回调或终态资源泄漏。
71 lines
2.0 KiB
TypeScript
71 lines
2.0 KiB
TypeScript
import type {
|
|
AdminGatewayTask,
|
|
AuthUser,
|
|
BaseModelCatalogItem,
|
|
CatalogProvider,
|
|
ClientCustomizationSettings,
|
|
FileStorageChannel,
|
|
FileStorageSettings,
|
|
GatewayAccessRule,
|
|
GatewayApiKey,
|
|
GatewayAuditLog,
|
|
GatewayNetworkProxyConfig,
|
|
GatewayRunnerPolicy,
|
|
GatewayTask,
|
|
GatewayTenant,
|
|
GatewayUser,
|
|
GatewayWalletAccount,
|
|
GatewayWalletTransaction,
|
|
IntegrationPlatform,
|
|
ModelCatalogResponse,
|
|
ModelRateLimitStatus,
|
|
PlatformModel,
|
|
PricingRule,
|
|
PricingRuleSet,
|
|
RateLimitWindow,
|
|
RuntimePolicySet,
|
|
SecurityEventConnectionResponse,
|
|
UserGroup,
|
|
WorkerClusterRuntime,
|
|
} from '@easyai-ai-gateway/contracts';
|
|
|
|
export interface ConsoleData {
|
|
accessRules: GatewayAccessRule[];
|
|
adminTasks: AdminGatewayTask[];
|
|
auditLogs: GatewayAuditLog[];
|
|
apiKeys: GatewayApiKey[];
|
|
baseModels: BaseModelCatalogItem[];
|
|
currentUser: AuthUser | null;
|
|
currentUserGroups: UserGroup[];
|
|
clientCustomizationSettings: ClientCustomizationSettings | null;
|
|
fileStorageChannels: FileStorageChannel[];
|
|
fileStorageSettings: FileStorageSettings | null;
|
|
modelCatalog: ModelCatalogResponse;
|
|
models: PlatformModel[];
|
|
networkProxyConfig: GatewayNetworkProxyConfig | null;
|
|
runnerPolicy: GatewayRunnerPolicy | null;
|
|
platforms: IntegrationPlatform[];
|
|
pricingRules: PricingRule[];
|
|
pricingRuleSets: PricingRuleSet[];
|
|
providers: CatalogProvider[];
|
|
rateLimitWindows: RateLimitWindow[];
|
|
modelRateLimits: ModelRateLimitStatus[];
|
|
modelRateLimitsUpdatedAt: number | null;
|
|
workerClusterRuntime: WorkerClusterRuntime | null;
|
|
runtimePolicySets: RuntimePolicySet[];
|
|
securityEventConnection: SecurityEventConnectionResponse | null;
|
|
taskResult: GatewayTask | null;
|
|
tasks: GatewayTask[];
|
|
tenants: GatewayTenant[];
|
|
userGroups: UserGroup[];
|
|
users: GatewayUser[];
|
|
walletAccounts: GatewayWalletAccount[];
|
|
walletTransactions: GatewayWalletTransaction[];
|
|
}
|
|
|
|
export interface StatItem {
|
|
label: string;
|
|
value: number | string;
|
|
tone: 'blue' | 'green' | 'violet' | 'amber' | 'cyan' | 'rose' | 'slate';
|
|
}
|