Pocket Flow
A minimalist LLM framework implemented in about 100 lines of Python, providing a single graph abstraction that agents, workflows and RAG pipelines can be built from without vendor-specific wrappers.
Pocket Flow is a minimalist LLM framework written in about 100 lines of Python, with no dependencies and no vendor lock-in. It captures the core abstraction shared by larger LLM frameworks in a single graph primitive, and that graph is used to implement common patterns such as (multi-)agents, workflows and retrieval-augmented generation.
It installs as a Python package or can simply be copied as source, and is also available in TypeScript, Java, C++, Go, Rust and PHP. Tutorials cover a chat bot with conversation history, structured-output extraction from resumes, a writing workflow that outlines and styles content, and a research agent, ranging from beginner to more advanced difficulty.