langchain-hs-graph

Graph-based stateful agent orchestration engine for langchain-hs

https://github.com/tusharad/langchain-hs#readme

Stackage Nightly 2026-10-16:0.0.6.0
Latest on Hackage:0.0.6.0

See all snapshots langchain-hs-graph appears in

MIT licensed by Tushar Adhatrao
Maintained by [email protected]
This version can be pinned in stack with:langchain-hs-graph-0.0.6.0@sha256:33935f62e1da6e020c5a5b2315207e2423033649cb7eb8bdaa3cbfe43be177fc,2769

Module documentation for 0.0.6.0

langchain-hs-graph

Stateful agent orchestration and cyclic graph workflows for langchain-hs (LangGraph in Haskell).

langchain-hs-graph provides cyclic state machines, pure monoidal state reducers, in-memory STM checkpointers, persistent SQLite checkpointers, Human-in-the-Loop (HITL) interrupts, and multi-agent coordination patterns.

Key Primitives

  • StateGraph s m: Cyclic workflow builder with typed nodes, directed edges, and conditional branches.
  • StateReducer s: Pure binary state merge reducer (s -> s -> s) satisfying monoid associativity laws.
  • Checkpointers:
    • MemoryCheckpointer: In-memory thread-safe state persistence using STM TVar.
    • SQLiteCheckpointer: Persistent state checkpointer for production runs.
  • Human-in-the-Loop (HITL): Node interruption before execution, inspection/modification, and resumed execution via resumeGraph.
  • Parallel Nodes: Concurrent node evaluation using async.
  • Multi-Agent Architectures: Supervisor teams with capability routing, multi-agent debate, and majority voting.

Installation

build-depends: langchain-hs-graph >= 0.0.6 && < 0.0.7

License

MIT License. See LICENSE.

Changes

Changelog for langchain-hs-graph

All notable changes to this package will be documented in this file.

0.0.6.0 - 2026-10-02

  • Updated bounds for GHC 9.12 and modern Stackage LTS releases.
  • Standalone stack configuration and verified test suite.

0.0.5.0 - 2026-09-10

  • Initial standalone Hackage release of langchain-hs-graph.
  • Cyclic graph orchestration engine (StateGraph s m).
  • Pure monoidal state merge reducers (StateReducer s).
  • In-memory STM TVar checkpointer and persistent SQLite checkpointer.
  • Human-in-the-Loop (HITL) interruption and resumption.
  • Parallel concurrent node execution via async.
  • Multi-Agent coordination: Supervisor teams, debate loops, and voting classifiers.
  • Graphviz DOT export for visual workflow inspection.