supercompat 4.1.0 → 4.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,7 +5,7 @@ import { Mistral } from '@mistralai/mistralai';
5
5
  import Anthropic from '@anthropic-ai/sdk';
6
6
  import { GoogleGenAI } from '@google/genai';
7
7
  import { OpenRouter } from '@openrouter/sdk';
8
- import { AssistantsRunBody, ResponsesRunBody, MessageWithRun, RunAdapterBody, GetOpenaiAssistantFn, StorageAdapterArgs, RequestHandler, RunAdapterWithAssistant } from '../types/index.cjs';
8
+ import { AssistantsRunBody, ResponsesRunBody, MessageWithRun, RunAdapterBody, StorageAdapterArgs, RequestHandler, RunAdapterWithAssistant } from '../types/index.cjs';
9
9
  import { PrismaClient } from '@prisma/client';
10
10
 
11
11
  declare const groqClientAdapter: ({ groq, }: {
@@ -240,7 +240,11 @@ declare const perplexityAgentRunAdapter: ({ apiKey, baseURL, preset, }: {
240
240
  */
241
241
 
242
242
  declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
243
- getOpenaiAssistant?: GetOpenaiAssistantFn;
243
+ getOpenaiAssistant?: (args?: {
244
+ select?: {
245
+ id?: boolean;
246
+ };
247
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>;
244
248
  waitUntil?: <T>(p: Promise<T>) => void | Promise<void>;
245
249
  }) => {
246
250
  handleRun: ({ client, body, onEvent, }: {
@@ -248,7 +252,11 @@ declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
248
252
  body: RunAdapterBody;
249
253
  onEvent: (event: OpenAI.Responses.ResponseStreamEvent) => Promise<void>;
250
254
  }) => Promise<void>;
251
- getOpenaiAssistant?: GetOpenaiAssistantFn | undefined;
255
+ getOpenaiAssistant?: ((args?: {
256
+ select?: {
257
+ id?: boolean;
258
+ };
259
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>) | undefined;
252
260
  type: "responses-openai";
253
261
  };
254
262
 
@@ -262,14 +270,22 @@ declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
262
270
 
263
271
  declare const azureResponsesRunAdapter: ({ azureAiProject, getOpenaiAssistant, }: {
264
272
  azureAiProject: AIProjectClient;
265
- getOpenaiAssistant?: GetOpenaiAssistantFn;
273
+ getOpenaiAssistant?: (args?: {
274
+ select?: {
275
+ id?: boolean;
276
+ };
277
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>;
266
278
  }) => {
267
279
  handleRun: ({ body, onEvent, }: {
268
280
  client?: OpenAI;
269
281
  body: RunAdapterBody;
270
282
  onEvent: (event: OpenAI.Responses.ResponseStreamEvent) => Promise<void>;
271
283
  }) => Promise<void>;
272
- getOpenaiAssistant?: GetOpenaiAssistantFn | undefined;
284
+ getOpenaiAssistant?: ((args?: {
285
+ select?: {
286
+ id?: boolean;
287
+ };
288
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>) | undefined;
273
289
  type: "responses-azure";
274
290
  };
275
291
 
@@ -5,7 +5,7 @@ import { Mistral } from '@mistralai/mistralai';
5
5
  import Anthropic from '@anthropic-ai/sdk';
6
6
  import { GoogleGenAI } from '@google/genai';
7
7
  import { OpenRouter } from '@openrouter/sdk';
8
- import { AssistantsRunBody, ResponsesRunBody, MessageWithRun, RunAdapterBody, GetOpenaiAssistantFn, StorageAdapterArgs, RequestHandler, RunAdapterWithAssistant } from '../types/index.js';
8
+ import { AssistantsRunBody, ResponsesRunBody, MessageWithRun, RunAdapterBody, StorageAdapterArgs, RequestHandler, RunAdapterWithAssistant } from '../types/index.js';
9
9
  import { PrismaClient } from '@prisma/client';
10
10
 
11
11
  declare const groqClientAdapter: ({ groq, }: {
@@ -240,7 +240,11 @@ declare const perplexityAgentRunAdapter: ({ apiKey, baseURL, preset, }: {
240
240
  */
241
241
 
242
242
  declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
243
- getOpenaiAssistant?: GetOpenaiAssistantFn;
243
+ getOpenaiAssistant?: (args?: {
244
+ select?: {
245
+ id?: boolean;
246
+ };
247
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>;
244
248
  waitUntil?: <T>(p: Promise<T>) => void | Promise<void>;
245
249
  }) => {
246
250
  handleRun: ({ client, body, onEvent, }: {
@@ -248,7 +252,11 @@ declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
248
252
  body: RunAdapterBody;
249
253
  onEvent: (event: OpenAI.Responses.ResponseStreamEvent) => Promise<void>;
250
254
  }) => Promise<void>;
251
- getOpenaiAssistant?: GetOpenaiAssistantFn | undefined;
255
+ getOpenaiAssistant?: ((args?: {
256
+ select?: {
257
+ id?: boolean;
258
+ };
259
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>) | undefined;
252
260
  type: "responses-openai";
253
261
  };
254
262
 
@@ -262,14 +270,22 @@ declare const openaiResponsesRunAdapter: ({ getOpenaiAssistant, waitUntil, }?: {
262
270
 
263
271
  declare const azureResponsesRunAdapter: ({ azureAiProject, getOpenaiAssistant, }: {
264
272
  azureAiProject: AIProjectClient;
265
- getOpenaiAssistant?: GetOpenaiAssistantFn;
273
+ getOpenaiAssistant?: (args?: {
274
+ select?: {
275
+ id?: boolean;
276
+ };
277
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>;
266
278
  }) => {
267
279
  handleRun: ({ body, onEvent, }: {
268
280
  client?: OpenAI;
269
281
  body: RunAdapterBody;
270
282
  onEvent: (event: OpenAI.Responses.ResponseStreamEvent) => Promise<void>;
271
283
  }) => Promise<void>;
272
- getOpenaiAssistant?: GetOpenaiAssistantFn | undefined;
284
+ getOpenaiAssistant?: ((args?: {
285
+ select?: {
286
+ id?: boolean;
287
+ };
288
+ }) => Promise<OpenAI.Beta.Assistants.Assistant> | OpenAI.Beta.Assistants.Assistant | Pick<OpenAI.Beta.Assistants.Assistant, "id"> | Promise<Pick<OpenAI.Beta.Assistants.Assistant, "id">>) | undefined;
273
289
  type: "responses-azure";
274
290
  };
275
291