Skip to main content

Bench adapter for LangChain — auto-instrument every chain, agent, and LLM call.

Project description

bench-langchain

LangChain callback adapter for Bench. It records chain, LLM, and tool runs through the zero-dependency bench-observe SDK.

python -m pip install bench-langchain
import os
from bench import observe
from bench_langchain import BenchCallbackHandler

agent = observe(
    api_key=os.environ["BENCH_KEY"],
    agent="my-langchain-agent",
    framework="langchain",
)
handler = BenchCallbackHandler(agent)

result = chain.invoke(
    {"input": "Research this question"},
    config={"callbacks": [handler]},
)

New agents hide raw inputs and outputs by default. Bench also redacts common secret and PII patterns before storage.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bench_langchain-0.1.0.tar.gz (2.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bench_langchain-0.1.0-py3-none-any.whl (3.0 kB view details)

Uploaded Python 3

File details

Details for the file bench_langchain-0.1.0.tar.gz.

File metadata

  • Download URL: bench_langchain-0.1.0.tar.gz
  • Upload date:
  • Size: 2.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bench_langchain-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7ed2054b4c7541a469756814756e32bc288607c78d3d846a91e7d200a7c56d01
MD5 0db09ff227aabf63bb341de41d13e37c
BLAKE2b-256 47842f6d06ad08ad3d588ce3244ab258100180531dfe7fb41a91c286ced87049

See more details on using hashes here.

Provenance

The following attestation bundles were made for bench_langchain-0.1.0.tar.gz:

Publisher: publish-python.yml on VirajMishra1/bench

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file bench_langchain-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for bench_langchain-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f0243d49dbb6e16a9d84b4012f044d4cf920f4149571c6def40494083539d2e0
MD5 3ec4125fd0c83d10d1dda540cc9aa69d
BLAKE2b-256 5388f7bde9844d6971243bc685723fb04f7002a82fa5f0076fdccc4b26dfffc6

See more details on using hashes here.

Provenance

The following attestation bundles were made for bench_langchain-0.1.0-py3-none-any.whl:

Publisher: publish-python.yml on VirajMishra1/bench

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page