Model resolution (from oh-my-openagent/model-core): 6-step priority resolution pipeline (UI select -> user config -> category default -> user fallback -> policy chain -> system default), provider fallback chains, fuzzy model matching, error classification, provider-specific model ID transforms. 14 files, zero runtime deps. Multi-batch matcher (from boocontext-audit): 6 batch types (Observational, Actionable, PreviouslyApplied, Disambiguation, ResponseAnalysis, LowCriticality) for behavioral guideline evaluation. RelationalResolver with iterative convergence (DEPENDS_ON, PRIORITIZES, ENTAILS, TAG_ALL, TAG_PRIORITIZES). SchematicGenerator abstract class with retry and execution plans. 4 files.
35 lines
963 B
TypeScript
35 lines
963 B
TypeScript
import type { ModelMetadata } from "./provider-cache.js"
|
|
|
|
export interface ProviderModelsCache {
|
|
readonly models: Record<string, readonly string[] | readonly ModelMetadata[]>
|
|
readonly connected: readonly string[]
|
|
readonly updatedAt: string
|
|
}
|
|
|
|
export interface ConnectedProvidersAdapter {
|
|
readConnectedProvidersCache(): string[] | null
|
|
findProviderModelMetadata(providerID: string, modelID: string): ModelMetadata | undefined
|
|
readProviderModelsCache(): ProviderModelsCache | null
|
|
}
|
|
|
|
export function readConnectedProvidersCache(): string[] | null {
|
|
return null
|
|
}
|
|
|
|
export function findProviderModelMetadata(
|
|
_providerID: string,
|
|
_modelID: string,
|
|
): ModelMetadata | undefined {
|
|
return undefined
|
|
}
|
|
|
|
export function readProviderModelsCache(): ProviderModelsCache | null {
|
|
return null
|
|
}
|
|
|
|
export const connectedProvidersAdapter: ConnectedProvidersAdapter = {
|
|
readConnectedProvidersCache,
|
|
findProviderModelMetadata,
|
|
readProviderModelsCache,
|
|
}
|