@elastic/opentelemetry-instrumentation-openai
Version:
OpenTelemetry instrumentation for the `openai` OpenAI client library
39 lines • 964 B
TypeScript
import { AnyValue } from '@opentelemetry/api-logs';
export declare type GenAIFunction = {
name: string;
arguments?: AnyValue;
};
export declare type GenAIToolCall = {
id: string;
type: string;
function: GenAIFunction;
};
export declare type GenAIMessage = {
role?: string;
content?: AnyValue;
tool_calls?: GenAIToolCall[];
};
export declare type GenAIChoiceEventBody = {
finish_reason: string;
index: number;
message: GenAIMessage;
};
export declare type GenAISystemMessageEventBody = {
role?: string;
content?: AnyValue;
};
export declare type GenAIUserMessageEventBody = {
role?: string;
content?: AnyValue;
};
export declare type GenAIAssistantMessageEventBody = {
role?: string;
content?: AnyValue;
tool_calls?: GenAIToolCall[];
};
export declare type GenAIToolMessageEventBody = {
role?: string;
content?: AnyValue;
id: string;
};
//# sourceMappingURL=internal-types.d.ts.map