Concept guide · LangChain, LangGraph, and CrewAI
When should you avoid LangChain?
A slower explanation for when the short interview answer is not enough. Start with the intuition, then connect it to the technical idea and the way an interviewer expects you to reason about it.
ML area
Generative AI → Framework selection
Interview format
Core · Debugging
Question
GENAI-092
Start with the idea
In simple terms
Avoid LangChain when direct provider calls and a few clear functions solve the problem better. A framework is not automatically an improvement if it makes debugging, upgrades, latency, or dependency control harder.
Make it concrete
A single structured extraction endpoint may be clearer as a typed provider call than as a chain with several wrappers and hidden defaults.
Build the answer
What to inspect first
- 1Describe the simplest implementation that satisfies the requirements.
- 2List the concrete framework capability that would reduce future cost.
- 3Keep an exit path if the abstraction becomes a bottleneck.
Go one level deeper
The technical explanation
Compare the maintenance surface, integrations, tracing, team skills, testability, provider portability, and expected evolution of the feature. Start direct when the workflow is small; introduce abstractions when repeated patterns or integrations justify them. Preserve the ability to inspect raw requests and responses.
Say this in the interview
Avoid it when a direct provider call and a few explicit functions are clearer, when abstraction makes debugging or latency unacceptable, or when a dependency adds more surface than value. The decision should consider integrations, team familiarity, upgrade risk, tracing, and the cost of replacing it later.
Keep preparing