Installation
LangChain 1.x ships as a set of small, independently-versioned packages instead of one monolith. Installing langchain alone gets you the orchestration layer — prompts, chains, agents — but no model provider.
Package Layout
LangChain's packages form a dependency tree. Understanding the direction of that tree tells you which package to import an abstraction from, and which packages are safe to depend on for the long term.
Keys & Config
LangChain reads provider credentials from environment variables by default. The standard pattern is a .env file loaded with python-dotenv, never a key typed directly into source.
Your First Chain
A minimal chain: a prompt template feeds a chat model, whose output feeds a parser. The | operator wires them together.