Skip to content
masterclass Buddy

LangChain · Class

RunnableLambda

RunnableLambda wraps a Python callable as a Runnable. It supports synchronous and asynchronous use, composition, and LangChain tracing.

Last updated

Since
v1.7

Syntax

RunnableLambda(self, func: Callable[[Input], Output] | Callable[[Input], Awaitable[Output]] | Callable[[Input], Runnable[Input, Output]] | ...)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • RunnableGenerator
  • Runnable
  • RunnableConfig
  • invoke
  • ainvoke
  • stream
  • astream

Source: RunnableLambda | langchain_core | LangChain Reference. Checked 2026-11-03.