feat: agent routing engine — cost/capability matrix (P2-003) (#75)
Co-authored-by: Jason Woltje <jason@diversecanvas.com> Co-committed-by: Jason Woltje <jason@diversecanvas.com>
This commit was merged in pull request #75.
This commit is contained in:
@@ -3,3 +3,4 @@ export const VERSION = '0.0.0';
|
||||
export * from './chat/index.js';
|
||||
export * from './agent/index.js';
|
||||
export * from './provider/index.js';
|
||||
export * from './routing/index.js';
|
||||
|
||||
25
packages/types/src/routing/index.ts
Normal file
25
packages/types/src/routing/index.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
/** Cost tier for model selection */
|
||||
export type CostTier = 'cheap' | 'standard' | 'premium';
|
||||
|
||||
/** Task type hint for routing */
|
||||
export type TaskType = 'chat' | 'coding' | 'analysis' | 'summarization' | 'general';
|
||||
|
||||
/** Routing criteria for model selection */
|
||||
export interface RoutingCriteria {
|
||||
taskType?: TaskType;
|
||||
costTier?: CostTier;
|
||||
requireReasoning?: boolean;
|
||||
requireImageInput?: boolean;
|
||||
minContextWindow?: number;
|
||||
preferredProvider?: string;
|
||||
preferredModel?: string;
|
||||
}
|
||||
|
||||
/** Result of a routing decision */
|
||||
export interface RoutingResult {
|
||||
provider: string;
|
||||
modelId: string;
|
||||
modelName: string;
|
||||
score: number;
|
||||
reasoning: string;
|
||||
}
|
||||
Reference in New Issue
Block a user