LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Agent
  • Middleware
  • Backends
  • Sandboxes
  • Skills
  • Subagents
  • 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

OverviewAgentMiddlewareBackendsSandboxesSkillsSubagentsTypes
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
Vitest
Language
Theme
JavaScriptdeepagentsnodecreateUnsupportedContentMiddleware
Function●Since v1.14

createUnsupportedContentMiddleware

Support is read from model.profile (see https://docs.langchain.com/oss/javascript/langchain/models#model-profiles).

Place this middleware last in the agent's middleware list, so that if some other middleware changes request.model, this one sees the model that will actually receive the request.

Copy
createUnsupportedContentMiddleware(

): AgentMiddleware<undefined, undefined, unknown, readonly ClientTool | ServerTool[], readonly []>
View source on GitHub