Skip to main content

LM Studio Agent

File: examples/lm_studio_agent.py

Uses TraceAgentClient with LM Studio or any OpenAI-compatible local model, registers a tool, and records a single traced turn.

Run

uv run examples/lm_studio_agent.py

Environment Variables

VariableDescription
TRACE_AGENT_PROXY_URLURL for the local model proxy
TRACE_AGENT_TEST_MODELModel name to use
TRACE_AGENT_PROXY_TIMEOUTConnection timeout

When to Use

This is a good fit when you want to validate local model connectivity and ensure that TraceAgent can capture tool calls from a locally-hosted LLM.

💬 Comments