Skip to content

Commit

Permalink
export mod types
Browse files Browse the repository at this point in the history
  • Loading branch information
cfortuner committed Oct 25, 2024
1 parent 70888f2 commit 76df09b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
12 changes: 7 additions & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
export { OpenAIClient, type ConfigOpts } from './openai-client.js';
export { type ConfigOpts,OpenAIClient } from './openai-client.js';
export type {
ModerationParams,
ModerationResponse,
SpeechParams,
SpeechResponse,
} from './types.js';
export type {
APIConnectionError,
APIConnectionTimeoutError,
Expand Down Expand Up @@ -26,7 +32,3 @@ export type {
RateLimitError,
UnprocessableEntityError,
} from 'ai-fetch';
export type {
SpeechParams,
SpeechResponse,
} from './types.js';
19 changes: 9 additions & 10 deletions src/openai-client.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
import { type OpenAI } from 'openai';

import { type Options as KyOptions } from 'ky';
import { StreamCompletionChunker } from './streaming.js';
import {
AIChatClient,
AICompletionClient,
AIEmbeddingClient,
AIFetchClient,
AIFetchRequestOpts,
type AIChatClient,
type AICompletionClient,
type AIEmbeddingClient,
type AIFetchClient,
type AIFetchRequestOpts,
type ChatParams,
type ChatResponse,
type ChatStreamParams,
Expand All @@ -16,11 +12,14 @@ import {
type CompletionResponse,
type CompletionStreamParams,
type CompletionStreamResponse,
createApiInstance,
type EmbeddingParams,
type EmbeddingResponse,
createApiInstance,
} from 'ai-fetch';
import { type Options as KyOptions } from 'ky';
import { type OpenAI } from 'openai';

import { StreamCompletionChunker } from './streaming.js';
import {
type SpeechParams,
type SpeechResponse,
Expand Down

0 comments on commit 76df09b

Please sign in to comment.