All products / langchain-golang

Foundation

langchain-golang

A community Go port of LangChain and LangGraph for production-grade agents.

What it is

A community Go port of LangChain and LangGraph for production-grade agents.

Why it exists

The Go ecosystem deserved first-class agent primitives instead of a wrapper around a Python service. This port brings runnables, tools, checkpoints and subagents to Go.

How to use it

Go module

go get github.com/projanvil/langchain-golang

Checkpoint backends

go get github.com/projanvil/langchain-golang/langgraph/checkpoint/sqlite
go get github.com/projanvil/langchain-golang/langgraph/checkpoint/postgres

Create an agent

import (
  "github.com/projanvil/langchain-golang/core/language"
  "github.com/projanvil/langchain-golang/langchain/agents"
)

↗ Full README

For other agents

Use CreateAgent with middleware for structured output, interrupts and subagents. It is the model backend inside Corpit, and works with Anthropic, OpenAI, Ollama and Gemini.