LLM
Multilingual large language model with native proficiency across Indian languages for text generation and reasoning.
Install langchain-sarvam
pip install langchain-sarvam python-dotenv
Add your API key
Set SARVAM_API_KEY in a .env file with a key from dashboard.sarvam.ai
Create a ChatSarvam instance
Use ChatSarvam in chains, agents, or tool-calling loops like any other BaseChatModel
pip install langchain-sarvam python-dotenv
from langchain_sarvam import ChatSarvam llm = ChatSarvam(model="sarvam-105b") response = llm.invoke("Translate this to malayalam: 'Keep cooking, guys'") print(response.content) # പാചകം തുടരൂ, സുഹൃത്തുക്കളേ
Multilingual
Multilingual Chat Agents
Build LangChain agents that reason and respond natively in Indian languages.
Tool-Calling
Tool-Calling Pipelines
Wire Sarvam models into bind_tools() workflows alongside retrievers and other LangChain components.
Structured
Structured Output Chains
Use with_structured_output() to extract typed, schema-constrained data from Indic-language text.
Ready to build? Start building with LangChain in minutes.
Ready to build?
Start building with LangChain in minutes.