Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion genai-function-calling/openai-agents/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ dotenv -f ../.env run -- pytest
## Notes

The LLM should generate something like "The latest stable version of
Elasticsearch is 8.17.3", unless it hallucinates. Just run it again, if you
Elasticsearch is 8.17.4", unless it hallucinates. Just run it again, if you
see something else.

OpenAI Agents SDK's OpenTelemetry instrumentation is via
Expand Down
6 changes: 3 additions & 3 deletions genai-function-calling/openai-agents/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
openai-agents~=0.0.5
openai-agents~=0.0.8
httpx~=0.28.1

elastic-opentelemetry~=0.8.0
elastic-opentelemetry~=1.0.0
# Use openai-agents instrumentation from OpenInference
openinference-instrumentation-openai-agents~=0.1.1
openinference-instrumentation-openai-agents~=0.1.7
2 changes: 1 addition & 1 deletion genai-function-calling/semantic-kernel-dotnet/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ARG DOTNET_VERSION=9.0

FROM mcr.microsoft.com/dotnet/sdk:${DOTNET_VERSION}-alpine AS edot
ARG EDOT_VERSION=1.0.0-beta.2
ARG EDOT_VERSION=1.0.1
ARG EDOT_INSTALL=https://github.com/elastic/elastic-otel-dotnet/releases/download/${EDOT_VERSION}/elastic-dotnet-auto-install.sh
ENV OTEL_DOTNET_AUTO_HOME=/edot
WORKDIR /edot
Expand Down
2 changes: 1 addition & 1 deletion genai-function-calling/semantic-kernel-dotnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ docker compose run --build --rm genai-function-calling
## Notes

The LLM should generate something like "The latest stable version of
Elasticsearch is 8.17.3", unless it hallucinates. Just run it again, if you
Elasticsearch is 8.17.4", unless it hallucinates. Just run it again, if you
see something else.

Semantic Kernel .NET's OpenTelemetry instrumentation uses the following custom
Expand Down
6 changes: 3 additions & 3 deletions genai-function-calling/semantic-kernel-dotnet/app.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.SemanticKernel" Version="1.42.0" />
<PackageReference Include="Microsoft.SemanticKernel.Agents.Core" Version="1.42.0-preview" />
<PackageReference Include="Microsoft.SemanticKernel.Connectors.OpenAI" Version="1.42.0" />
<PackageReference Include="Microsoft.SemanticKernel" Version="1.45.0" />
<PackageReference Include="Microsoft.SemanticKernel.Agents.Core" Version="1.45.0-preview" />
<PackageReference Include="Microsoft.SemanticKernel.Connectors.OpenAI" Version="1.45.0" />
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion genai-function-calling/spring-ai/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Run maven after setting ENV variables like this:
## Notes

The LLM should generate something like "The latest stable version of
Elasticsearch is 8.17.3", unless it hallucinates. Just run it again, if you
Elasticsearch is 8.17.4", unless it hallucinates. Just run it again, if you
see something else.

Spring AI uses Micrometer which bridges to OpenTelemetry, but needs a few
Expand Down
2 changes: 1 addition & 1 deletion genai-function-calling/spring-ai/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.4.3</version>
<version>3.4.4</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>co.elastic.observability-labs</groupId>
Expand Down
2 changes: 1 addition & 1 deletion genai-function-calling/vercel-ai/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ npm start
## Notes

The LLM should generate something like "The latest stable version of
Elasticsearch is 8.17.3", unless it hallucinates. Just run it again, if you
Elasticsearch is 8.17.4", unless it hallucinates. Just run it again, if you
see something else.

Vercel AI's OpenTelemetry instrumentation only produces traces (not logs or
Expand Down
2 changes: 2 additions & 0 deletions genai-function-calling/vercel-ai/env.example
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,5 @@ OPENAI_API_KEY=
# OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf

OTEL_SERVICE_NAME=genai-function-calling
# Don't print status message on startup
OTEL_LOG_LEVEL=warn
1 change: 0 additions & 1 deletion genai-function-calling/vercel-ai/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
const {createAzure} = require('@ai-sdk/azure');
const {createOpenAI} = require('@ai-sdk/openai')
const fetch = require('node-fetch');
const {generateText, tool} = require('ai');
const {z} = require('zod');

Expand Down
14 changes: 4 additions & 10 deletions genai-function-calling/vercel-ai/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,9 @@
"start": "node --env-file .env -r @elastic/opentelemetry-node index.js"
},
"dependencies": {
"ai": "^4.1.63",
"@ai-sdk/azure": "^1.2.6",
"@ai-sdk/openai": "^1.2.6",
"@elastic/opentelemetry-node": "*"
},
"_comment": "Override to avoid punycode warnings in recent versions of Node.JS",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since this project doesn't require old node, we don't need to use node-fetch, so can avoid this cruft

"overrides": {
"[email protected]": {
"whatwg-url": "14.x"
}
"ai": "^4.3.2",
"@ai-sdk/azure": "^1.3.8",
"@ai-sdk/openai": "^1.3.7",
"@elastic/opentelemetry-node": "^1"
}
}