Deep AgentsDeep Agents 0.7 · Python 3.11+
0%
1
Curious builder0 XP earned · 300 to level 2
0 daysFinish a lesson to begin
Badge collection0 of 6 unlocked
28 small wins to finish your pathNext lesson →

Built-in tools: files and the task tool

The built-in tools are the tools every deep agent gets without asking: file tools to list, read, write, edit, delete and search files, and a task tool that hands work to a subagent.

Last updated: 29 Sep, 2026 · Deep Agents 0.7

create_agent vs create_deep_agent · from the Complete Deep Agents Course With LangChain · 35:52 to 38:15
In the video the to-do list hook appears in every deep agent. Since deepagents 0.7 it is not added by default: you pass TodoListMiddleware yourself, as write_todos: planning with TodoListMiddleware shows. Summarization and the tool-call patch are still built in.

create_agent next to create_deep_agent

The video builds a plain LangChain agent with create_agent and the same model and tool, and draws both. The plain agent is a model node and a tools node. The deep agent has the same two nodes plus middleware hooks around them: one that patches tool calls, one that summarizes long conversations, and one after the model that keeps a to-do list, so a big task is tracked step by step. Middleware is code that runs before or after each model call or tool call; a deep agent is a plain agent with a stack of it. The video draws both graphs; the page prints each agent's tool list, which shows the same difference as text.

Listing the tools the model gets

Start trip.py with search_travel, the catalog tool from Tools: a travel search the agent can call. Everything below goes in the same file, under it. Then build both agents from the same model and tool, and print the names of the tools each one can run. An agent's tools live in its tools node.

python
from langchain.tools import tool

CATALOG = {
    "paris": {
        "flight": ["Return flight Delhi to Paris: 42,000 rupees"],
        "hotel": ["Seine Budget Inn, Latin Quarter: 5,200 rupees a night",
                  "Hotel Lumiere, Montmartre: 7,500 rupees a night",
                  "Le Grand Opera Hotel: 16,000 rupees a night"],
        "sight": ["Eiffel Tower summit: 3,100 rupees", "Louvre Museum: 2,000 rupees",
                  "Seine river cruise: 1,500 rupees", "Versailles day trip: 2,600 rupees",
                  "Montmartre walking tour: free"],
        "food": ["Cafe breakfast and bistro dinner: 3,000 rupees a day"],
    },
}


@tool
def search_travel(city: str, kind: str) -> str:
    """Search the travel catalog. kind is "flight", "hotel", "sight" or "food". Prices are in rupees."""
    entries = CATALOG.get(city.lower(), {}).get(kind)
    return "\n".join(entries) if entries else f"The catalog has no {kind} entries for {city}."
python
from deepagents import create_deep_agent
from langchain.chat_models import init_chat_model

model = init_chat_model("groq:openai/gpt-oss-120b", temperature=0, max_retries=6)
python
from langchain.agents import create_agent

plain = create_agent(model, tools=[search_travel])
deep = create_deep_agent(model=model, tools=[search_travel])

The built-in tools in a run

The run below prints both lists, then asks the deep agent for something only its built-in tools can do: save the hotel options to a file and list the folder.

ExampleAPI keytrip.py, continued
print("create_agent:     ", sorted(plain.nodes["tools"].bound.tools_by_name))
print("create_deep_agent:", sorted(deep.nodes["tools"].bound.tools_by_name))

result = deep.invoke({"messages": [{"role": "user", "content": "Save the Paris hotel options to /trip/hotels.md, then list the files in /trip."}]})
for message in result["messages"]:
    print(f"{message.type:<5}", message.text or [(c["name"], c["args"]) for c in message.tool_calls])

What the two lists and the run show

  • create_agent has only the tool you gave it.
  • create_deep_agent adds ls, read_file, write_file, edit_file, delete, glob and grep for files, and task for subagents.
  • execute is registered too, but the model is only offered it when the agent's backend can run shell commands, such as a sandbox. With the default backend it stays hidden.
  • In the run the agent looked up the hotels, wrote them to /trip/hotels.md with write_file, then listed /trip with ls. No file appeared on your disk; the next part of the course shows where it went.

What each built-in tool does

ToolWhat it does
lsLists the files in a folder
read_fileReads a file, with line numbers, in pages for long files
write_fileCreates a file or replaces one
edit_fileReplaces an exact piece of text inside a file
deleteDeletes a file or a folder (new in 0.7)
glob / grepFinds files by name pattern / searches their contents
taskStarts a subagent with a job and returns its final report

Where the built-in tools help

  • Keeping a plan or a draft in a file the agent updates as it works.
  • Saving a large tool result so the conversation stays short.
  • Handing a side job to a subagent without writing any delegation code.
Watch out. The file tools work on the agent's own file space, not your folder, unless you choose a backend that maps to disk. Asking for /trip/hotels.md and then looking for it on disk finds nothing; Virtual filesystem: files in the agent's state explains why.
Try it yourself
  • Ask the deep agent to save the Paris sights to /trip/sights.md and list /trip again.
  • Ask it to delete /trip/hotels.md in the same request and read which tool it calls.
  • Print sorted(deep.nodes["tools"].bound.tools_by_name) after adding a second tool of your own.

This is what real progress feels like.