refactor: remove retired agent provider integration
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { fromPrismaProvider } from "./llm/provider-ids.js";
|
||||
import { parseProvider } from "./llm/provider-ids.js";
|
||||
|
||||
function record(value: unknown): Record<string, unknown> {
|
||||
return value && typeof value === "object" && !Array.isArray(value) ? value as Record<string, unknown> : {};
|
||||
@@ -18,7 +18,7 @@ export function withMessageGenerations<T extends { role: string; metadata: unkno
|
||||
for (const call of calls) {
|
||||
const requestId = record(call.request).clientRequestId;
|
||||
if (typeof requestId !== "string" || !requestId || call.error !== null || call.latencyMs === null) continue;
|
||||
const provider = fromPrismaProvider(call.provider);
|
||||
const provider = parseProvider(call.provider);
|
||||
if (!provider || !call.model.trim()) continue;
|
||||
byRequest.set(requestId, byRequest.has(requestId) ? null : { provider, model: call.model });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user