Deploy Agents with A2A on LangSmith Deployment
Key Takeaways
This video teaches how to deploy agents with A2A on LangSmith Deployment, covering automatic A2A-compatible endpoint configuration for multi-agent systems.
Full Transcript
A2A is a protocol released by Google in 2024 that enables agents across frameworks to communicate. It's become the standard for agent-to-agent communication. And with LangSmith deployment, you get A2A support right out of the box. Hi. I'm Harry from LangChain. In this video, we'll cover key A2A concepts, deploy simple agent with LangSmith deployment, and then show how to use its A2A capabilities. So, before jumping into the demo, I actually want to go over a couple core concepts in A2A. So, first is this agent card, which is a piece of JSON that basically describes the agent's capabilities. So, this will contain things like whether the agent supports streaming, the agent's URL, and a bunch of other meta metadata. I'll show this off later, and it'll become more clear what exactly this does. Then, there's a concept of a task. So, a task basically represents a request-response within a certain context. And this actually maps very similarly to the concept of runs in LangSmith. And last, there is this concept of a context. And a context groups a bunch of task objects together, and it becomes important in like a multi-turn conversation where I might have a bunch of tasks, but a single context for the entire conversation. And this is very similar to the concept of threads that we have. So, for the demo, I'm going to be using this test repo here, which actually comes with the basic agent with some tools, and also comes with the helper Python script that uses the official A2A Python SDK. Cool. So, I've cloned this locally, um and I've opened up the project up in WinSurf. Um I copied the env.example and set up uh .env, and I specified API key, and I'm going to be using a Anthropic for this example. And I've run a UV sync dev here also. So, if you go look at the actual agent code, I'll quickly show you what's actually happening here. So, we are setting up a basic create agent, and we have four tools, uh one that tells the time, one that just does some calculations, and then a read and send email tool, uh to mock uh an actual email tool, and we'll actually demo how uh human in the loop works with A2A with this tool as well. So, I'm going to do a quick UV run LangGraph deploy to deploy this. Nice. Okay. So, our deployment's done. I'm going to go hop over to LangSmith, go to the deployments page, and here's my deployment. So, I'm going to press this connect. You can see the exact shape of our graph here. And I'm actually going to go to the A2A tab here. So, like I mentioned before, here's the actual agent card, just a simple JSON object, and you can see um we have the URL right here for our actual agent, and you can see things like, yeah, we support streaming here. And there's a quick uh usage snippet here where we actually just show off sending a quick message. But, I'm actually going to show you how this works with Google's official A2A inspector. So, I'm going to copy this URL here. New tab. Going to go to A2A inspect.com. Going to paste in the URL here. And I'm actually going to do I'm going to have to set up API key auth here. So, I would put an API key in here. [clears throat] Once you've set that up, we can try to connect. Says our agent card is agent card is valid. This is the same thing I showed off in LangSmith's UI. And then we can actually just send a chat. So, I'm going to trigger the calculator tool here. So, I'm just going to say, "What is 3 * 2 * 2?" Send this. And this is all going through the official, you know, A2A interface. We get our answer here. And yeah, if you click on one of these, you can actually see what's being sent. So, here we can see a context was generated. A task was generated here, and you can see our actual text, and then can actually see the agent's response here as well. So, I'm going to show you how human in the loop works with the official A2A client. So, if you remember, we set up this human in the loop middleware here, and we wanted to block on this mock send email tool. And we're going to basically going to prompt the user to make some sort of approve, edit, or rejection statement. So, in the sample code, there's this test A2A HITL human in the loop um file here, and and here we are actually going to use the official A2A client. Um I've pasted in my agent URL here that I got from uh the LangSmith UI. And we set up a client here. So, we're going to send uh a message first asking to actually send an email. And then, after that, you can see what we do here is in order to approve the interrupt, we actually have to send this data part back. And in this data part, we actually send this resume payload. And we're going to say type approve, and [snorts] this will actually approve the task. Remember, this is all going through the A2A client. So, I'm going to quickly run this script. Cool. We can quickly s- scan the output here. So, first we say that we wanted to send the email, and you can see that in our response, we actually got this tool execution requires approval. And we need to either approve, edit, or reject this. And you can see the task is actually in this input required state, which is part of the official A2A spec for for task task states. And then, when we actually resume the interrupt, we get this done. Your email has successfully been sent. Cool. So, yeah, that's the A2A integration with uh LangSmith deployment.
Original Description
Every LangSmith Deployment comes with built-in A2A (Agent-to-Agent) support, no extra configuration needed! In this video, we walk through how your deployed agents automatically get A2A-compatible endpoints, making it easy to plug into any multi-agent system.
🔗 Resources
Docs: https://docs.langchain.com/langsmith/server-a2a#a2a-endpoint-in-agent-server
A2A Protocol: https://a2a-protocol.org/latest/
Watch on YouTube ↗
(saves to browser)
Sign in to unlock AI tutor explanation · ⚡30
Playlist
Uploads from LangChain · LangChain · 0 of 60
← Previous
Next →
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
Chat With Your Documents Using LangChain + JavaScript
LangChain
LangChain SQL Webinar
LangChain
LangChain "OpenAI functions" Webinar
LangChain
LangSmith Launch
LangChain
LangChain x Pinecone: Supercharging Llama-2 with RAG
LangChain
LangChain Expression Language
LangChain
Building LLM applications with LangChain with Lance
LangChain
Benchmarking Question/Answering Over CSV Data
LangChain
LangChain "RAG Evaluation" Webinar
LangChain
Fine-tuning in Your Voice Webinar
LangChain
Tabular Data Retrieval
LangChain
Building an LLM Application with Audio by AssemblyAI
LangChain
Superagent Deepdive Webinar
LangChain
Lessons from Deploying LLMs with LangSmith
LangChain
Shortwave Assistant Deepdive Webinar
LangChain
Cognitive Architectures for Language Agents
LangChain
Effectively Building with LLMs in the Browser with Jacob
LangChain
Data Privacy for LLMs
LangChain
"Theory of Mind" Webinar with Plastic Labs
LangChain
LangChain Templates
LangChain
Using Natural Language to Query Postgres with Jacob
LangChain
Building a Research Assistant from Scratch
LangChain
Benchmarking RAG over LangChain Docs
LangChain
Skeleton-of-Thought: Building a New Template from Scratch
LangChain
Benchmarking Methods for Semi-Structured RAG
LangChain
LangSmith Highlights: Getting Started
LangChain
LangSmith Highlights: Debugging
LangChain
LangSmith Highlights: Datasets
LangChain
LangSmith Highlights: Evaluation
LangChain
LangSmith Highlights: Human Annotation
LangChain
LangSmith Highlights: Monitoring
LangChain
LangSmith Highlights: Hub
LangChain
SQL Research Assistant
LangChain
Getting Started with Multi-Modal LLMs
LangChain
Build a Full Stack RAG App With TypeScript
LangChain
Auto-Prompt Builder (with Hosted LangServe)
LangChain
LangChain v0.1.0 Launch: Introduction
LangChain
LangChain v0.1.0 Launch: Observability
LangChain
LangChain v0.1.0 Launch: Integrations
LangChain
LangChain v0.1.0 Launch: Composability
LangChain
LangChain v0.1.0 Launch: Streaming
LangChain
LangChain v0.1.0 Launch: Output Parsing
LangChain
LangChain v0.1.0 Launch: Retrieval
LangChain
LangChain v0.1.0 Launch: Agents
LangChain
Build and Deploy a RAG app with Pinecone Serverless
LangChain
Hosted LangServe + LangChain Templates
LangChain
LangGraph: Intro
LangChain
LangGraph: Agent Executor
LangChain
LangGraph: Chat Agent Executor
LangChain
LangGraph: Human-in-the-Loop
LangChain
LangGraph: Dynamically Returning a Tool Output Directly
LangChain
LangGraph: Respond in a Specific Format
LangChain
LangGraph: Managing Agent Steps
LangChain
LangGraph: Force-Calling a Tool
LangChain
LangGraph: Multi-Agent Workflows
LangChain
Streaming Events: Introducing a new `stream_events` method
LangChain
Building a web RAG chatbot: using LangChain, Exa (prev. Metaphor), LangSmith, and Hosted Langserve
LangChain
OpenGPTs
LangChain
Open Source RAG with Nomic's New Embedding Model (and ChromaDB and Ollama)
LangChain
LangGraph: Persistence
LangChain
Related Reads
📰
📰
📰
📰
Building HawkShift: An AI Shopping OS (Not Another Affiliate Blog)
Medium · Startup
Building Production-Ready AI Agents in 2026: Engineering Best Practices Every Developer Should Follow
Dev.to AI
I filed a critical bug against my own tool. Then I read the code — and my own root cause was wrong.
Dev.to AI
How Our AI Agents Built the Visual SEO Sitemap Architect in Record Time
Dev.to AI
🎓
Tutor Explanation
DeepCamp AI