---
title: "HuggingFace Integration"
sidebar:
  label: "HuggingFace"
seo:
  title: "HuggingFace Integration with Judgment | Model Provider Docs"
  description: "Use Judgment with HuggingFace to capture model calls, trace agent behavior, and evaluate production AI systems."
---

{/* @test-flow
  id: provider-huggingface
  lang: python
  env: JUDGMENT_API_KEY, JUDGMENT_ORG_ID
  skip: Requires HuggingFace model download which is too slow for CI
*/}

If you use HuggingFace Transformers within your application, you can trace, monitor, and analyze them with **Judgment** using [TransformersInstrumentor](https://pypi.org/project/opentelemetry-instrumentation-transformers/).

1. ### OpenTelemetry

    ```bash
    pip install opentelemetry-instrumentation-transformers
    ```

    ```python
    from judgeval import Tracer
    # Make sure you installed the dependency: opentelemetry-instrumentation-transformers
    from opentelemetry.instrumentation.transformers import TransformersInstrumentor

    Tracer.init(project_name="huggingface_project")
    Tracer.registerOTELInstrumentation(TransformersInstrumentor())
    ```

> **Info**
>
> This instrumentation automatically traces text generation calls sent with the
> HuggingFace Transformers library.
