8000 feat(examples): add LangChain agent example + E2E test · Issue #23 · zvectorlabs/zradar · GitHub
[go: up one dir, main page]

Skip to content

feat(examples): add LangChain agent example + E2E test #23

Open

Description

@Rushit

Goal

Add a working LangChain ReAct agent example with E2E span validation against a local zradar instance.

Skeleton

A skeleton is already in examples/langchain/ on the docs_opt branch:

examples/langchain/
  agent.py              ← ReAct agent with get_weather tool, mock + real LLM
  pyproject.toml        ← uv-managed, Python 3.11+
  README.md
  tests/
    expected_spans.json ← span schema contract

What "done" looks like

  • just example langchain runs without error (no API key required — uses mock LLM)
  • just example-test langchain runs the agent and validates spans arrived in zradar
  • Works with OPENAI_API_KEY set for real LLM calls
  • Spans match the contract in tests/expected_spans.json

How to test locally

just dev                       # start zradar + postgres
just example-test langchain    # run agent + validate spans

Activity

  1. Rushit commented on Jun 29, 2026

    @Rushit
    ContributorAuthor

    Path update: Example is now at examples/langchain/python/example.py following the <provider>/<language>/example.* convention.

    just dev
    just example-test langchain
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    examplesExample code and instrumentation guidesgood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0