LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Agent
  • Middleware
  • Backends
  • Sandboxes
  • Skills
  • Subagents
  • Configuration
  • Types
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
  • Vitest
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewAgentMiddlewareBackendsSandboxesSkillsSubagentsConfigurationTypes
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
Vitest
Language
Theme
JavaScriptdeepagentsTypes

Types

Core TypeScript type definitions for deep agents. These types are useful when building custom middleware, backends, or extending agent functionality.

Agent Types

The main types for working with deep agents:

  • DeepAgent - The compiled agent graph returned by createDeepAgent
  • CreateDeepAgentParams - Configuration options for createDeepAgent
  • MergedDeepAgentState - The agent's internal state shape

Subagent Types

Types for defining and working with subagents:

  • SubAgent - Configuration object for defining a subagent
  • CompiledSubAgent - Wrapper for using a pre-compiled LangGraph as a subagent

Backend Types

Types for implementing custom backends:

  • BackendProtocol - Interface that all backends must implement
  • BackendFactory - Factory function type for creating backends
  • FileData / FileInfo - File metadata types
  • EditResult / WriteResult - Operation result types

API Reference

Interfaces

Interface

DeepAgentTypeConfig

Type bag that extends AgentTypeConfig with subagent type information.

Interface

DefaultDeepAgentTypeConfig

Default type configuration for deep agents.

Interface

CreateDeepAgentParams

Configuration parameters for creating a Deep Agent

Interface

SubAgent

Specification for a subagent that can be dynamically created.

Interface

CompiledSubAgent

Type definitions for pre-compiled agents.

Interface

BackendProtocol

Protocol for pluggable memory backends (single, unified).

Interface

FileData

File data structure used by backends.

Interface

FileInfo

Structured file listing info.

Interface

EditResult

Result from backend edit operations.

Interface

WriteResult

Result from backend write operations.

Types

Type

DeepAgent

DeepAgent extends ReactAgent with additional subagent type information.

Type

MergedDeepAgentState

Combined state type including custom middleware and subagent middleware states

Type

BackendFactory

Factory function type for creating backend instances.