@jaypie/llm 1.3.8 → 1.3.9
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.
- package/dist/cjs/{src/constants.d.ts → constants.d.ts} +4 -4
- package/dist/cjs/index.cjs +54 -3
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.d.cts +4 -4
- package/dist/cjs/{src/operate → operate}/types.d.ts +2 -0
- package/dist/cjs/{src/util → util}/index.d.ts +1 -0
- package/dist/cjs/util/tallyOperate.d.ts +14 -0
- package/dist/esm/{src/constants.d.ts → constants.d.ts} +4 -4
- package/dist/esm/index.d.ts +4 -4
- package/dist/esm/index.js +54 -3
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/{src/operate → operate}/types.d.ts +2 -0
- package/dist/esm/{src/util → util}/index.d.ts +1 -0
- package/dist/esm/util/tallyOperate.d.ts +14 -0
- package/package.json +1 -1
- package/dist/esm/src/index.d.ts +0 -17
- /package/dist/cjs/{src/Llm.d.ts → Llm.d.ts} +0 -0
- /package/dist/cjs/{src/index.d.ts → index.d.ts} +0 -0
- /package/dist/cjs/{src/observability → observability}/llmobs.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/OperateLoop.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/StreamLoop.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/AnthropicAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/BedrockAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/GoogleAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/OpenAiAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/OpenRouterAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/ProviderAdapter.interface.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/XaiAdapter.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/adapters/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/hooks/HookRunner.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/hooks/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/input/InputProcessor.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/input/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/progress/emitProgress.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/progress/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/response/ResponseBuilder.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/response/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/retry/RetryExecutor.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/retry/RetryPolicy.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/retry/createStaleRejectionGuard.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/retry/index.d.ts +0 -0
- /package/dist/cjs/{src/operate → operate}/retry/isTransientNetworkError.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/anthropic/AnthropicProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/anthropic/client.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/anthropic/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/anthropic/types.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/anthropic/utils.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/bedrock/BedrockProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/bedrock/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/bedrock/utils.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/google/GoogleProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/google/client.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/google/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/google/types.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/google/utils.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/OpenAiProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/client.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/responseFormat.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/types.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openai/utils.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openrouter/OpenRouterProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openrouter/client.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openrouter/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/openrouter/utils.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/xai/XaiProvider.class.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/xai/index.d.ts +0 -0
- /package/dist/cjs/{src/providers → providers}/xai/utils.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/Toolkit.class.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/index.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/random.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/roll.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/time.d.ts +0 -0
- /package/dist/cjs/{src/tools → tools}/weather.d.ts +0 -0
- /package/dist/cjs/{src/types → types}/LlmOperateInput.guards.d.ts +0 -0
- /package/dist/cjs/{src/types → types}/LlmProvider.interface.d.ts +0 -0
- /package/dist/cjs/{src/types → types}/LlmStreamChunk.interface.d.ts +0 -0
- /package/dist/cjs/{src/types → types}/LlmTool.interface.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/detectMimeType.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/extractPdfPages.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/index.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/loadLocalFile.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/loadS3File.d.ts +0 -0
- /package/dist/cjs/{src/upload → upload}/resolveOperateInput.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/determineModelProvider.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/extractReasoning.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/fillFormatArrays.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/formatOperateInput.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/formatOperateMessage.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/jsonSchema.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/jsonSchemaToOpenApi3.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/logger.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/maxOutputTokens.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/maxTurnsFromOptions.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/naturalZodSchema.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/random.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/repairFormatKeys.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/sse.d.ts +0 -0
- /package/dist/cjs/{src/util → util}/tryParseNumber.d.ts +0 -0
- /package/dist/esm/{src/Llm.d.ts → Llm.d.ts} +0 -0
- /package/dist/esm/{src/observability → observability}/llmobs.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/OperateLoop.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/StreamLoop.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/AnthropicAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/BedrockAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/GoogleAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/OpenAiAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/OpenRouterAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/ProviderAdapter.interface.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/XaiAdapter.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/adapters/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/hooks/HookRunner.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/hooks/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/input/InputProcessor.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/input/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/progress/emitProgress.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/progress/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/response/ResponseBuilder.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/response/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/retry/RetryExecutor.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/retry/RetryPolicy.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/retry/createStaleRejectionGuard.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/retry/index.d.ts +0 -0
- /package/dist/esm/{src/operate → operate}/retry/isTransientNetworkError.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/anthropic/AnthropicProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/anthropic/client.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/anthropic/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/anthropic/types.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/anthropic/utils.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/bedrock/BedrockProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/bedrock/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/bedrock/utils.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/google/GoogleProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/google/client.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/google/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/google/types.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/google/utils.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/OpenAiProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/client.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/responseFormat.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/types.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openai/utils.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openrouter/OpenRouterProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openrouter/client.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openrouter/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/openrouter/utils.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/xai/XaiProvider.class.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/xai/index.d.ts +0 -0
- /package/dist/esm/{src/providers → providers}/xai/utils.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/Toolkit.class.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/index.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/random.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/roll.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/time.d.ts +0 -0
- /package/dist/esm/{src/tools → tools}/weather.d.ts +0 -0
- /package/dist/esm/{src/types → types}/LlmOperateInput.guards.d.ts +0 -0
- /package/dist/esm/{src/types → types}/LlmProvider.interface.d.ts +0 -0
- /package/dist/esm/{src/types → types}/LlmStreamChunk.interface.d.ts +0 -0
- /package/dist/esm/{src/types → types}/LlmTool.interface.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/detectMimeType.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/extractPdfPages.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/index.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/loadLocalFile.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/loadS3File.d.ts +0 -0
- /package/dist/esm/{src/upload → upload}/resolveOperateInput.d.ts +0 -0
- /package/dist/esm/{src/util → util}/determineModelProvider.d.ts +0 -0
- /package/dist/esm/{src/util → util}/extractReasoning.d.ts +0 -0
- /package/dist/esm/{src/util → util}/fillFormatArrays.d.ts +0 -0
- /package/dist/esm/{src/util → util}/formatOperateInput.d.ts +0 -0
- /package/dist/esm/{src/util → util}/formatOperateMessage.d.ts +0 -0
- /package/dist/esm/{src/util → util}/jsonSchema.d.ts +0 -0
- /package/dist/esm/{src/util → util}/jsonSchemaToOpenApi3.d.ts +0 -0
- /package/dist/esm/{src/util → util}/logger.d.ts +0 -0
- /package/dist/esm/{src/util → util}/maxOutputTokens.d.ts +0 -0
- /package/dist/esm/{src/util → util}/maxTurnsFromOptions.d.ts +0 -0
- /package/dist/esm/{src/util → util}/naturalZodSchema.d.ts +0 -0
- /package/dist/esm/{src/util → util}/random.d.ts +0 -0
- /package/dist/esm/{src/util → util}/repairFormatKeys.d.ts +0 -0
- /package/dist/esm/{src/util → util}/sse.d.ts +0 -0
- /package/dist/esm/{src/util → util}/tryParseNumber.d.ts +0 -0
|
@@ -133,6 +133,8 @@ export interface OperateLoopState {
|
|
|
133
133
|
maxTurns: number;
|
|
134
134
|
/** Response builder instance */
|
|
135
135
|
responseBuilder: ResponseBuilder;
|
|
136
|
+
/** Names of tool calls executed across all turns (report tally) */
|
|
137
|
+
toolCallNames: string[];
|
|
136
138
|
/** The toolkit for tool calls */
|
|
137
139
|
toolkit?: Toolkit;
|
|
138
140
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { LlmUsageItem } from "../types/LlmProvider.interface.js";
|
|
2
|
+
interface TallyOperateOptions {
|
|
3
|
+
toolCallNames?: string[];
|
|
4
|
+
turns: number;
|
|
5
|
+
usage?: LlmUsageItem[];
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Tally loop totals onto the root logger's report session so handlers
|
|
9
|
+
* (express, lambda) include llm activity in the report emitted at teardown.
|
|
10
|
+
* Silently no-ops outside an active session or when the logger predates
|
|
11
|
+
* tally support.
|
|
12
|
+
*/
|
|
13
|
+
export declare function tallyOperate({ toolCallNames, turns, usage, }: TallyOperateOptions): void;
|
|
14
|
+
export {};
|
package/package.json
CHANGED
package/dist/esm/src/index.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export { default as Llm } from "./Llm.js";
|
|
2
|
-
export * as LLM from "./constants.js";
|
|
3
|
-
export type { LlmFallbackConfig, LlmHistory, LlmInputContent, LlmInputContentFile, LlmInputContentImage, LlmInputContentText, LlmInputMessage, LlmMessageOptions, LlmOperateInput, LlmOperateInputContent, LlmOperateInputFile, LlmOperateInputImage, LlmOperateOptions, LlmOperateResponse, LlmOptions, LlmProgressCallback, LlmProgressEvent, LlmProgressToolCall, LlmProvider, } from "./types/LlmProvider.interface.js";
|
|
4
|
-
export { LlmMessageRole, LlmMessageType, LlmProgressEventType, } from "./types/LlmProvider.interface.js";
|
|
5
|
-
export { isLlmOperateInput, isLlmOperateInputContent, isLlmOperateInputFile, isLlmOperateInputImage, } from "./types/LlmOperateInput.guards.js";
|
|
6
|
-
export type { LlmTool } from "./types/LlmTool.interface.js";
|
|
7
|
-
export type { LlmStreamChunk, LlmStreamChunkDone, LlmStreamChunkError, LlmStreamChunkText, LlmStreamChunkToolCall, LlmStreamChunkToolResult, } from "./types/LlmStreamChunk.interface.js";
|
|
8
|
-
export { LlmStreamChunkType } from "./types/LlmStreamChunk.interface.js";
|
|
9
|
-
export { JaypieToolkit, toolkit, Toolkit, tools } from "./tools/index.js";
|
|
10
|
-
export { extractReasoning } from "./util/extractReasoning.js";
|
|
11
|
-
export { jsonSchemaToNaturalSchema, naturalSchemaToJsonSchema, } from "./util/jsonSchema.js";
|
|
12
|
-
export { BedrockProvider } from "./providers/bedrock/index.js";
|
|
13
|
-
/** @deprecated Use GoogleProvider — "Google" is the provider; Gemini is the model family */
|
|
14
|
-
export { GoogleProvider as GeminiProvider } from "./providers/google/index.js";
|
|
15
|
-
export { GoogleProvider } from "./providers/google/index.js";
|
|
16
|
-
export { OpenRouterProvider } from "./providers/openrouter/index.js";
|
|
17
|
-
export { XaiProvider } from "./providers/xai/index.js";
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|