HuggingFace Smolagents OpenTelemetry Integration
Overview
This integration provides support for using OpenTelemetry with the HuggingFace Smolagents framework. It enables tracing and monitoring of applications built with HuggingFace Smolagents.
Installation
- Install traceAI Smolagents
pip install traceAI-smolagents
Set Environment Variables
Set up your environment variables to authenticate with FutureAGI
import os
os.environ["FI_API_KEY"] = FI_API_KEY
os.environ["FI_SECRET_KEY"] = FI_SECRET_KEY
Quickstart
Register Tracer Provider
Set up the trace provider to establish the observability pipeline. The trace provider:
from fi_instrumentation import register
from fi_instrumentation.fi_types import ProjectType
trace_provider = register(
project_type=ProjectType.OBSERVE,
project_name="smolagents_app"
)
Configure Smolagents Instrumentation
Instrument the Smolagents client to enable telemetry collection.
from traceai_smolagents import SmolagentsInstrumentor
SmolagentsInstrumentor().instrument(tracer_provider=trace_provider)
Create Smolagents Components
Set up your Smolagents client with built-in observability.
from smolagents import (
CodeAgent,
DuckDuckGoSearchTool,
OpenAIServerModel,
ToolCallingAgent,
)
model = OpenAIServerModel(model_id="gpt-4o")
agent = ToolCallingAgent(
tools=[DuckDuckGoSearchTool()],
model=model,
max_steps=3,
name="search",
description=(
"This is an agent that can do web search. "
"When solving a task, ask him directly first, he gives good answers. "
"Then you can double check."
),
)
manager_agent = CodeAgent(
tools=[DuckDuckGoSearchTool()],
model=model,
managed_agents=[agent],
)
manager_agent.run(
"How many seconds would it take for a leopard at full speed to run through Pont des Arts? "
"ASK YOUR MANAGED AGENT FOR LEOPARD SPEED FIRST"
)
Metadata
Release files for traceAI-smolagents 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| traceai_smolagents-0.1.6.tar.gz | 9.2 kB | With provenance | Details for traceai_smolagents-0.1.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| traceai_smolagents-0.1.6-py3-none-any.whl | Python 3 | none | any | Details for traceai_smolagents-0.1.6-py3-none-any.whl |
Total release size: 18.7 kB
Release files / traceai_smolagents-0.1.6.tar.gz
| Download URL | traceai_smolagents-0.1.6.tar.gz |
|---|---|
| Size | 9.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a3da382d251367d92123bc6861ab5fc06df1244e21f00839cd07a7ed89864edd
|
|
BLAKE2b-256 checksum How to use checksums |
970fba09c0cbff25db96214073f7d98955538780a4f1059e86009cd81f8f2695
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logRelease files / traceai_smolagents-0.1.6-py3-none-any.whl
| Download URL | traceai_smolagents-0.1.6-py3-none-any.whl |
|---|---|
| Size | 9.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6dbbdbb3f5196b52bb3afa9f28c99db535bc5536d0e9904864471239302341ee
|
|
BLAKE2b-256 checksum How to use checksums |
4bce48f4a8013db113d4db4d30c1464e7972aa34583907c1534bbef4c1013705
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logSecurity for traceAI-smolagents 0.1.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for traceai_smolagents-0.1.6.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.