openlit 1.10.0 → 1.12.0
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/README.md +35 -1
- package/dist/config.d.ts +12 -4
- package/dist/config.js +7 -17
- package/dist/config.js.map +1 -1
- package/dist/evals/llm/anthropic.js +10 -6
- package/dist/evals/llm/anthropic.js.map +1 -1
- package/dist/evals/llm/openai.js +9 -5
- package/dist/evals/llm/openai.js.map +1 -1
- package/dist/features/__tests__/rule-engine.test.d.ts +1 -0
- package/dist/features/__tests__/rule-engine.test.js +146 -0
- package/dist/features/__tests__/rule-engine.test.js.map +1 -0
- package/dist/features/base.d.ts +2 -0
- package/dist/features/base.js +2 -0
- package/dist/features/base.js.map +1 -1
- package/dist/features/rule-engine.d.ts +6 -0
- package/dist/features/rule-engine.js +60 -0
- package/dist/features/rule-engine.js.map +1 -0
- package/dist/features/vault.js +1 -1
- package/dist/features/vault.js.map +1 -1
- package/dist/helpers.d.ts +93 -1
- package/dist/helpers.js +270 -8
- package/dist/helpers.js.map +1 -1
- package/dist/index.d.ts +6 -5
- package/dist/index.js +95 -50
- package/dist/index.js.map +1 -1
- package/dist/instrumentation/__tests__/anthropic-wrapper.test.js +215 -27
- package/dist/instrumentation/__tests__/anthropic-wrapper.test.js.map +1 -1
- package/dist/instrumentation/__tests__/base-wrapper.test.js +19 -23
- package/dist/instrumentation/__tests__/base-wrapper.test.js.map +1 -1
- package/dist/instrumentation/__tests__/bedrock-trace-comparison.test.d.ts +1 -0
- package/dist/instrumentation/__tests__/bedrock-trace-comparison.test.js +422 -0
- package/dist/instrumentation/__tests__/bedrock-trace-comparison.test.js.map +1 -0
- package/dist/instrumentation/__tests__/chroma-trace-comparison.test.js +1 -1
- package/dist/instrumentation/__tests__/chroma-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/cohere-wrapper.test.js +150 -25
- package/dist/instrumentation/__tests__/cohere-wrapper.test.js.map +1 -1
- package/dist/instrumentation/__tests__/google-ai-trace-comparison.test.js +152 -33
- package/dist/instrumentation/__tests__/google-ai-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/groq-trace-comparison.test.js +391 -45
- package/dist/instrumentation/__tests__/groq-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/huggingface-trace-comparison.test.d.ts +2 -2
- package/dist/instrumentation/__tests__/huggingface-trace-comparison.test.js +323 -31
- package/dist/instrumentation/__tests__/huggingface-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/langchain-wrapper.test.d.ts +1 -0
- package/dist/instrumentation/__tests__/langchain-wrapper.test.js +282 -0
- package/dist/instrumentation/__tests__/langchain-wrapper.test.js.map +1 -0
- package/dist/instrumentation/__tests__/milvus-trace-comparison.test.js +1 -1
- package/dist/instrumentation/__tests__/milvus-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/mistral-trace-comparison.test.d.ts +0 -3
- package/dist/instrumentation/__tests__/mistral-trace-comparison.test.js +275 -68
- package/dist/instrumentation/__tests__/mistral-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/openai-wrapper.test.js +7 -9
- package/dist/instrumentation/__tests__/openai-wrapper.test.js.map +1 -1
- package/dist/instrumentation/__tests__/qdrant-trace-comparison.test.js +1 -1
- package/dist/instrumentation/__tests__/qdrant-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/replicate-trace-comparison.test.d.ts +2 -1
- package/dist/instrumentation/__tests__/replicate-trace-comparison.test.js +209 -21
- package/dist/instrumentation/__tests__/replicate-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/together-trace-comparison.test.js +231 -51
- package/dist/instrumentation/__tests__/together-trace-comparison.test.js.map +1 -1
- package/dist/instrumentation/__tests__/vercel-ai-trace-comparison.test.d.ts +8 -0
- package/dist/instrumentation/__tests__/vercel-ai-trace-comparison.test.js +446 -0
- package/dist/instrumentation/__tests__/vercel-ai-trace-comparison.test.js.map +1 -0
- package/dist/instrumentation/anthropic/index.d.ts +2 -3
- package/dist/instrumentation/anthropic/index.js.map +1 -1
- package/dist/instrumentation/anthropic/wrapper.d.ts +1 -3
- package/dist/instrumentation/anthropic/wrapper.js +211 -91
- package/dist/instrumentation/anthropic/wrapper.js.map +1 -1
- package/dist/instrumentation/azure-ai-inference/index.d.ts +11 -0
- package/dist/instrumentation/azure-ai-inference/index.js +76 -0
- package/dist/instrumentation/azure-ai-inference/index.js.map +1 -0
- package/dist/instrumentation/azure-ai-inference/wrapper.d.ts +42 -0
- package/dist/instrumentation/azure-ai-inference/wrapper.js +515 -0
- package/dist/instrumentation/azure-ai-inference/wrapper.js.map +1 -0
- package/dist/instrumentation/base-wrapper.d.ts +2 -1
- package/dist/instrumentation/base-wrapper.js +35 -23
- package/dist/instrumentation/base-wrapper.js.map +1 -1
- package/dist/instrumentation/bedrock/wrapper.d.ts +21 -3
- package/dist/instrumentation/bedrock/wrapper.js +318 -265
- package/dist/instrumentation/bedrock/wrapper.js.map +1 -1
- package/dist/instrumentation/chroma/wrapper.js +1 -1
- package/dist/instrumentation/chroma/wrapper.js.map +1 -1
- package/dist/instrumentation/claude-agent-sdk/index.d.ts +23 -0
- package/dist/instrumentation/claude-agent-sdk/index.js +83 -0
- package/dist/instrumentation/claude-agent-sdk/index.js.map +1 -0
- package/dist/instrumentation/claude-agent-sdk/wrapper.d.ts +13 -0
- package/dist/instrumentation/claude-agent-sdk/wrapper.js +1031 -0
- package/dist/instrumentation/claude-agent-sdk/wrapper.js.map +1 -0
- package/dist/instrumentation/cohere/index.d.ts +2 -3
- package/dist/instrumentation/cohere/index.js.map +1 -1
- package/dist/instrumentation/cohere/wrapper.d.ts +1 -1
- package/dist/instrumentation/cohere/wrapper.js +215 -56
- package/dist/instrumentation/cohere/wrapper.js.map +1 -1
- package/dist/instrumentation/google-adk/index.d.ts +57 -0
- package/dist/instrumentation/google-adk/index.js +371 -0
- package/dist/instrumentation/google-adk/index.js.map +1 -0
- package/dist/instrumentation/google-adk/utils.d.ts +45 -0
- package/dist/instrumentation/google-adk/utils.js +663 -0
- package/dist/instrumentation/google-adk/utils.js.map +1 -0
- package/dist/instrumentation/google-adk/wrapper.d.ts +11 -0
- package/dist/instrumentation/google-adk/wrapper.js +391 -0
- package/dist/instrumentation/google-adk/wrapper.js.map +1 -0
- package/dist/instrumentation/google-ai/wrapper.d.ts +7 -4
- package/dist/instrumentation/google-ai/wrapper.js +197 -61
- package/dist/instrumentation/google-ai/wrapper.js.map +1 -1
- package/dist/instrumentation/groq/wrapper.js +137 -65
- package/dist/instrumentation/groq/wrapper.js.map +1 -1
- package/dist/instrumentation/huggingface/wrapper.js +241 -39
- package/dist/instrumentation/huggingface/wrapper.js.map +1 -1
- package/dist/instrumentation/index.d.ts +2 -2
- package/dist/instrumentation/index.js +64 -6
- package/dist/instrumentation/index.js.map +1 -1
- package/dist/instrumentation/langchain/index.d.ts +0 -7
- package/dist/instrumentation/langchain/index.js +2 -20
- package/dist/instrumentation/langchain/index.js.map +1 -1
- package/dist/instrumentation/langchain/wrapper.d.ts +35 -0
- package/dist/instrumentation/langchain/wrapper.js +1098 -184
- package/dist/instrumentation/langchain/wrapper.js.map +1 -1
- package/dist/instrumentation/langgraph/index.d.ts +12 -0
- package/dist/instrumentation/langgraph/index.js +99 -0
- package/dist/instrumentation/langgraph/index.js.map +1 -0
- package/dist/instrumentation/langgraph/wrapper.d.ts +20 -0
- package/dist/instrumentation/langgraph/wrapper.js +619 -0
- package/dist/instrumentation/langgraph/wrapper.js.map +1 -0
- package/dist/instrumentation/llamaindex/index.d.ts +31 -6
- package/dist/instrumentation/llamaindex/index.js +180 -61
- package/dist/instrumentation/llamaindex/index.js.map +1 -1
- package/dist/instrumentation/llamaindex/wrapper.d.ts +15 -3
- package/dist/instrumentation/llamaindex/wrapper.js +670 -179
- package/dist/instrumentation/llamaindex/wrapper.js.map +1 -1
- package/dist/instrumentation/milvus/wrapper.js +1 -1
- package/dist/instrumentation/milvus/wrapper.js.map +1 -1
- package/dist/instrumentation/mistral/wrapper.js +154 -79
- package/dist/instrumentation/mistral/wrapper.js.map +1 -1
- package/dist/instrumentation/ollama/index.js +33 -4
- package/dist/instrumentation/ollama/index.js.map +1 -1
- package/dist/instrumentation/ollama/wrapper.d.ts +28 -2
- package/dist/instrumentation/ollama/wrapper.js +432 -48
- package/dist/instrumentation/ollama/wrapper.js.map +1 -1
- package/dist/instrumentation/openai/index.d.ts +2 -3
- package/dist/instrumentation/openai/index.js.map +1 -1
- package/dist/instrumentation/openai/wrapper.js +293 -194
- package/dist/instrumentation/openai/wrapper.js.map +1 -1
- package/dist/instrumentation/openai-agents/index.d.ts +20 -0
- package/dist/instrumentation/openai-agents/index.js +174 -0
- package/dist/instrumentation/openai-agents/index.js.map +1 -0
- package/dist/instrumentation/openai-agents/processor.d.ts +35 -0
- package/dist/instrumentation/openai-agents/processor.js +249 -0
- package/dist/instrumentation/openai-agents/processor.js.map +1 -0
- package/dist/instrumentation/openai-agents/utils.d.ts +20 -0
- package/dist/instrumentation/openai-agents/utils.js +624 -0
- package/dist/instrumentation/openai-agents/utils.js.map +1 -0
- package/dist/instrumentation/pinecone/wrapper.js +2 -2
- package/dist/instrumentation/pinecone/wrapper.js.map +1 -1
- package/dist/instrumentation/qdrant/wrapper.js +1 -1
- package/dist/instrumentation/qdrant/wrapper.js.map +1 -1
- package/dist/instrumentation/replicate/wrapper.js +103 -21
- package/dist/instrumentation/replicate/wrapper.js.map +1 -1
- package/dist/instrumentation/strands/index.d.ts +21 -0
- package/dist/instrumentation/strands/index.js +83 -0
- package/dist/instrumentation/strands/index.js.map +1 -0
- package/dist/instrumentation/strands/processor.d.ts +45 -0
- package/dist/instrumentation/strands/processor.js +545 -0
- package/dist/instrumentation/strands/processor.js.map +1 -0
- package/dist/instrumentation/strands/utils.d.ts +24 -0
- package/dist/instrumentation/strands/utils.js +360 -0
- package/dist/instrumentation/strands/utils.js.map +1 -0
- package/dist/instrumentation/together/wrapper.js +125 -51
- package/dist/instrumentation/together/wrapper.js.map +1 -1
- package/dist/instrumentation/vercel-ai/wrapper.d.ts +28 -2
- package/dist/instrumentation/vercel-ai/wrapper.js +314 -164
- package/dist/instrumentation/vercel-ai/wrapper.js.map +1 -1
- package/dist/llm/anthropic.js +10 -6
- package/dist/llm/anthropic.js.map +1 -1
- package/dist/llm/openai.js +9 -5
- package/dist/llm/openai.js.map +1 -1
- package/dist/otel/__tests__/metrics.test.js +16 -27
- package/dist/otel/__tests__/metrics.test.js.map +1 -1
- package/dist/otel/events.d.ts +11 -0
- package/dist/otel/events.js +74 -0
- package/dist/otel/events.js.map +1 -0
- package/dist/otel/metrics.d.ts +5 -6
- package/dist/otel/metrics.js +66 -48
- package/dist/otel/metrics.js.map +1 -1
- package/dist/otel/tracing.d.ts +6 -2
- package/dist/otel/tracing.js +71 -24
- package/dist/otel/tracing.js.map +1 -1
- package/dist/otel/utils.d.ts +11 -0
- package/dist/otel/utils.js +34 -0
- package/dist/otel/utils.js.map +1 -0
- package/dist/semantic-convention.d.ts +44 -5
- package/dist/semantic-convention.js +51 -8
- package/dist/semantic-convention.js.map +1 -1
- package/dist/types.d.ts +74 -22
- package/package.json +41 -9
|
@@ -26,17 +26,46 @@ class OpenlitOllamaInstrumentation extends instrumentation_1.InstrumentationBase
|
|
|
26
26
|
}
|
|
27
27
|
_patch(moduleExports) {
|
|
28
28
|
try {
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
const proto = moduleExports.Ollama.prototype;
|
|
30
|
+
if ((0, instrumentation_1.isWrapped)(proto.chat)) {
|
|
31
|
+
this._unwrap(proto, 'chat');
|
|
32
|
+
}
|
|
33
|
+
this._wrap(proto, 'chat', wrapper_1.default._patchChat(this.tracer));
|
|
34
|
+
if (typeof proto.generate === 'function') {
|
|
35
|
+
if ((0, instrumentation_1.isWrapped)(proto.generate)) {
|
|
36
|
+
this._unwrap(proto, 'generate');
|
|
37
|
+
}
|
|
38
|
+
this._wrap(proto, 'generate', wrapper_1.default._patchGenerate(this.tracer));
|
|
39
|
+
}
|
|
40
|
+
if (typeof proto.embed === 'function') {
|
|
41
|
+
if ((0, instrumentation_1.isWrapped)(proto.embed)) {
|
|
42
|
+
this._unwrap(proto, 'embed');
|
|
43
|
+
}
|
|
44
|
+
this._wrap(proto, 'embed', wrapper_1.default._patchEmbeddings(this.tracer));
|
|
45
|
+
}
|
|
46
|
+
if (typeof proto.embeddings === 'function') {
|
|
47
|
+
if ((0, instrumentation_1.isWrapped)(proto.embeddings)) {
|
|
48
|
+
this._unwrap(proto, 'embeddings');
|
|
49
|
+
}
|
|
50
|
+
this._wrap(proto, 'embeddings', wrapper_1.default._patchEmbeddings(this.tracer));
|
|
31
51
|
}
|
|
32
|
-
this._wrap(moduleExports.Ollama.prototype, 'chat', wrapper_1.default._patchChat(this.tracer));
|
|
33
52
|
}
|
|
34
53
|
catch (e) {
|
|
35
54
|
console.error('Error in _patch method:', e);
|
|
36
55
|
}
|
|
37
56
|
}
|
|
38
57
|
_unpatch(moduleExports) {
|
|
39
|
-
|
|
58
|
+
const proto = moduleExports.Ollama.prototype;
|
|
59
|
+
this._unwrap(proto, 'chat');
|
|
60
|
+
if (typeof proto.generate === 'function') {
|
|
61
|
+
this._unwrap(proto, 'generate');
|
|
62
|
+
}
|
|
63
|
+
if (typeof proto.embed === 'function') {
|
|
64
|
+
this._unwrap(proto, 'embed');
|
|
65
|
+
}
|
|
66
|
+
if (typeof proto.embeddings === 'function') {
|
|
67
|
+
this._unwrap(proto, 'embeddings');
|
|
68
|
+
}
|
|
40
69
|
}
|
|
41
70
|
}
|
|
42
71
|
exports.default = OpenlitOllamaInstrumentation;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/instrumentation/ollama/index.ts"],"names":[],"mappings":";;;;;AAAA,oEAKwC;AAExC,6CAAwD;AACxD,wDAAsC;AAItC,MAAqB,4BAA6B,SAAQ,qCAAmB;IAC3E,YAAY,SAAsC,EAAE;QAClD,KAAK,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,KAAK,CAAC,UAAU,KAAK,UAAU,EAAE,CAAC;gBAC3C,IAAI,IAAA,2BAAS,EAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC;oBAChC,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,YAAY,CAAC,CAAC;gBACpC,CAAC;gBACD,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,YAAY,EAAE,iBAAa,CAAC,gBAAgB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;YAC/E,CAAC;QACH,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,OAAO,CAAC,KAAK,CAAC,yBAAyB,EAAE,CAAC,CAAC,CAAC;QAC9C,CAAC;IACH,CAAC;IAES,QAAQ,CAAC,aAAkB;QACnC,MAAM,KAAK,GAAG,aAAa,CAAC,MAAM,CAAC,SAAS,CAAC;QAC7C,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QAC5B,IAAI,OAAO,KAAK,CAAC,QAAQ,KAAK,UAAU,EAAE,CAAC;YACzC,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;QAClC,CAAC;QACD,IAAI,OAAO,KAAK,CAAC,KAAK,KAAK,UAAU,EAAE,CAAC;YACtC,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;QAC/B,CAAC;QACD,IAAI,OAAO,KAAK,CAAC,UAAU,KAAK,UAAU,EAAE,CAAC;YAC3C,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,YAAY,CAAC,CAAC;QACpC,CAAC;IACH,CAAC;CACF;AAzED,+CAyEC"}
|
|
@@ -16,7 +16,7 @@ export default class OllamaWrapper extends BaseWrapper {
|
|
|
16
16
|
genAIEndpoint: string;
|
|
17
17
|
response: any;
|
|
18
18
|
span: Span;
|
|
19
|
-
}): AsyncGenerator<
|
|
19
|
+
}): AsyncGenerator<unknown, any, unknown>;
|
|
20
20
|
static _chatCommonSetter({ args, genAIEndpoint, result, span, ttft, tbt, }: {
|
|
21
21
|
args: any[];
|
|
22
22
|
genAIEndpoint: string;
|
|
@@ -27,8 +27,34 @@ export default class OllamaWrapper extends BaseWrapper {
|
|
|
27
27
|
}): Promise<{
|
|
28
28
|
genAIEndpoint: string;
|
|
29
29
|
model: any;
|
|
30
|
-
user: any;
|
|
31
30
|
cost: number;
|
|
32
31
|
aiSystem: string;
|
|
33
32
|
}>;
|
|
33
|
+
static _patchGenerate(tracer: Tracer): any;
|
|
34
|
+
static _generate({ args, genAIEndpoint, response, span, }: {
|
|
35
|
+
args: any[];
|
|
36
|
+
genAIEndpoint: string;
|
|
37
|
+
response: any;
|
|
38
|
+
span: Span;
|
|
39
|
+
}): Promise<any>;
|
|
40
|
+
static _generateGenerator({ args, genAIEndpoint, response, span, }: {
|
|
41
|
+
args: any[];
|
|
42
|
+
genAIEndpoint: string;
|
|
43
|
+
response: any;
|
|
44
|
+
span: Span;
|
|
45
|
+
}): AsyncGenerator<unknown, any, unknown>;
|
|
46
|
+
static _generateCommonSetter({ args, genAIEndpoint, result, span, ttft, tbt, }: {
|
|
47
|
+
args: any[];
|
|
48
|
+
genAIEndpoint: string;
|
|
49
|
+
result: any;
|
|
50
|
+
span: Span;
|
|
51
|
+
ttft?: number;
|
|
52
|
+
tbt?: number;
|
|
53
|
+
}): Promise<{
|
|
54
|
+
genAIEndpoint: string;
|
|
55
|
+
model: any;
|
|
56
|
+
cost: number;
|
|
57
|
+
aiSystem: string;
|
|
58
|
+
}>;
|
|
59
|
+
static _patchEmbeddings(tracer: Tracer): any;
|
|
34
60
|
}
|