subagentic.ai RSS X YouTube GitHub
AI-generated illustration

News

LangSmith ties coding-agent spend to merged pull requests

LangSmith now links coding-agent spend to GitHub pull requests and GitLab merge requests so teams can see which agent work actually merged.

langchainlangsmithagent-costgithub

LangChain has added reporting in LangSmith that ties coding-agent spend to the pull requests and merge requests those agents produce. In a November 18, 2026 post, Jacob Lee describes the change as a way to see what a merged change cost and how much spend never led to one. That is an outcome ledger. It is not a published formula that proves return on investment.

The post says teams judging coding-agent ROI have mostly had usage analytics and consumption totals, which do not show what the tokens produced. LangChain says it hit that limit when spend on its own coding agent, Robin, started climbing. The customer-facing answer is reporting built for coding agents that attributes spend to the changes those agents work on. LangChain calls this a clearer way to calculate ROI. The post does not include an independent measurement of that return.

Outcomes, not another token chart

A new concept called outcomes links GitHub pull requests or GitLab merge requests to threads. Coding agents are the first specialized agent type on the LangSmith Agent Platform, which LangChain says operates around the agent. Each agent has its own record and an agent type that sets the dashboard, the data it connects to, and how it is evaluated. For coding agents, the dashboard presents pull requests as one sign the work was useful.

LangSmith already traces coding agents across model providers, including Claude Code and Codex. Spend in each trace is attributed to the pull requests an agent contributed to. Attribution covers both shapes of the work: one thread can open several pull requests, and one pull request can take several threads to finish. Every linked pull request points back to the threads behind it.

Before this reporting, LangSmith showed cost per trace, one trace at a time. The new overview aggregates those costs and ties them to the pull requests agents worked on. Clicking a metric opens its trend, including a before-and-after comparison if a team switched models.

Merged is a signal, not the whole bill

Spend is also split by pull-request state: open, closed, or merged. LangChain is explicit that a merged pull request is a useful signal, not the only sign of productive work. Agents review code and investigate problems, and that work does not always end in a pull request. LangSmith tracks it separately as unattributed. Teams can open the threads behind that spend and judge whether it was valuable.

A work-type view labels each thread by the kind of work it asks for. The post's examples are features, bug fixes, investigation, and code review, with the share of threads and cost for each type. Each organization decides what counts as off topic. LangChain's example is a team that uses its coding agent only for backend services and flags threads that ask the agent to draft marketing copy. The same view is meant to explain unattributed spend, because review and investigation often do not produce a pull request of their own.

The dashboard also shows which skills agents call, the most expensive pull requests, and how cost scales with conversation length. Every metric links back to the threads and sessions behind it.

One dashboard, still not a proven ROI number

LangChain says many engineering teams do not run a single coding agent. LangSmith for Coding Agents supports Claude Code, OpenAI Codex, Cursor, GitHub Copilot in VS Code, and Deep Agents, so spend and pull-request outcomes can roll up in one place instead of separate vendor consoles.

The post describes how a team might read the numbers. It does not report measured savings. Sorting by attributed cost surfaces the most expensive pull requests, each traced to its threads, the models involved, and the GitHub user behind it. Long threads are called out because every new turn carries the conversation's context, and spend concentrates there. A model change can be compared as cost per merged pull request before and after, or by running a new provider alongside the current one. The post says moving subagents onto a smaller model than the main agent should lower cost; the model breakdown shows the saving, and outcomes show whether work still gets merged. Skill calls are traced, so a skill that keeps showing up in long, expensive threads can be rewritten and compared with threads that do not use it.

For finance, LangChain points to cost per merged pull request, shown next to unattributed spend — sessions that never led to a pull request. A high cost per merged change may still reflect useful work, such as exploring a codebase or reviewing a change. When cost spikes or falls, engineering can open the threads and show what the spend went toward.

Public beta, three setup steps

LangSmith for Coding Agents is in public beta on LangSmith Cloud. Coding-agent traces count toward regular LangSmith tracing usage. The post lists three steps: install the LangSmith plugin for each coding agent the team uses, connect GitHub, and open the coding-agent overview. Outcomes also cover GitLab merge requests. The published setup steps name a GitHub connection and do not describe a separate GitLab install path.

In Claude Code, the plugin installs with three commands run from inside a session:

/plugin marketplace add langchain-ai/langsmith-claude-code-plugins
/plugin install langsmith-tracing@langsmith-claude-code-plugins
/reload-plugins

LangChain says starting with one agent and one repo shows spend broken out by pull request as soon as the first threads come in. More tailored coding-agent experiences are still ahead. Questions go to the LangChain Forum.

If you already trace a coding agent, read the November 18 post, connect one repository, and check whether merged, closed, and unattributed spend match the work you already know that agent did.

Sources