Graphs Over Chains: My First Steps with LangGraph (Part - 1)

Rishee PanchalRishee Panchal
3 min read

Introduction

I've just started learning LangGraph, and I’m excited to document my journey here on this blog. My goal is to explore what LangGraph can do, understand its concepts, and share the insights I gain along the way.

So, what exactly is LangGraph, and why does it matter?

What is LangGraph?

LangGraph builds on top of LangChain, but it introduces a powerful idea: graphs of AI interactions instead of simple chains. In a typical LangChain project, you pass a prompt through a chain of models or tools, and that's it, one-way. LangGraph, on the other hand, lets you create graphs where:

  • Nodes represent steps (like LLM calls, tool invocations, or control flow logic).

  • Edges represent transitions between nodes, possibly based on conditions.

  • You can loop back, retry steps, or branch into different flows.

And hence this enables you to design more stateful, multi-turn, and complex AI applications.

Flowchart diagram showing a sequence of nodes. Start leads to Node 1, which branches to Node 2 and Node 3. Both Node 2 and Node 3 point to End.

Core concepts in LangGraph

Let’s briefly introduce some of the key concepts I’ve learned so far:

  1. Graph

    A Graph in LangGraph is like the blueprint of your AI workflow. It defines how nodes connect and how the flow progresses. You can think of it as a state machine where each node represents a state or an action.

    The image you see above, is entirely known as a graph.

  2. Node

    A node is an atomic step in the graph, it represents many things for example:

    • A call to an LLM

    • A function that processes data

    • A decision-making step that branches the flow

  1. Edges

    Edges define how you move from one node to another. Edges can be static (always go to the next node) or dynamic (conditionally branch based on logic or the current state).

  2. State Management

    LangGraph introduces the idea of a shared state object that persists across steps in your graph.

    • This is typically a dictionary-like object that stores variables, intermediate results, or metadata.

    • Every node can read from and write to this state, allowing information to flow across the graph.

  3. Conditional logic

    Unlike simple pipelines, LangGraph lets you define conditional flows:

    • You can have if-else branches inside the graph.

    • You can implement retry mechanisms or loops.

This is crucial for handling real-world tasks like error handling or iterative refinement.

Why I’m learning LangGraph

My earlier experiences with LangChain taught me the limitations of linear pipelines. When building more agentic workflows, like multi-turn chatbots or decision-making systems, I often ran into rigid structures. I believe that learning LangGraph will give me an edge in building next-generation AI applications that are smarter and more interactive.

Difference between LangChain & LangGraph (Chains vs Graphs)

Feature

LangChain

LangGraph

Workflow Structure

Linear pipelines (Chains)

Graphs (Nodes + Edges, like a flowchart)

State Management

Global input/output, less structured

Explicit AgentState shared across nodes

Learning Curve

Easier for quick prototypes

Steeper but more powerful for advanced tasks

Use Cases

Simple, single-step or sequential tasks

Complex, multi-step workflows (chatbots, tools, APIs)

Conclusion

This is just the start of my LangGraph journey. I’m keeping this blog raw and honest—sharing both what clicks and what confuses me. If you're also exploring LangGraph or have ideas to share, drop a comment below. Let’s learn together!

References and Resources

  1. LangGraph Documentation

  2. LangGraph GitHub Repository

  3. LangChain Youtube

1
Subscribe to my newsletter

Read articles from Rishee Panchal directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Rishee Panchal
Rishee Panchal

I’m a computer science student exploring AI and machine learning through hands-on projects and critical thinking. My work spans from experimenting with LLMs and transformers to building practical AI tools. I believe in learning by doing, questioning assumptions, and sharing insights along the way.