I am GIVING UP on LangChain!
I have been a fan of Langchain from the start. I even built my own course about it. I really liked the simplicity with which you can pipe chains together. But, as it evolved, I grew quite frustrated!
Functionalities kept being deprecated from one update to the next. The documentation kept changing on a daily basis. It was harder to find what you were looking for in the documentation than building the stuff on your own. Using Langchain has always been a game of detective on Github to understand what prompts get used and how some logic gets implemented. But I accepted those difficulties as the growing pains of a valuable tool trying to find its marks.
Now it is a fully funded company ($25M in Series A), it is difficult to ignore the weaknesses of the tool! In January, they announced the release of V0.1, which gave the promise of a more robust implementation. They made the most horrific design decisions, in my opinion! They replaced the namespace "langchain" (from langchain import ...) with a fleet of functionality-specific namespaces: langchain_core, langchain_community, langchain_openai, langchain_text_splitters, ..., which makes it impossible to remember which namespace to call. Of course, a functionality keeps moving from one namespace to the next, depending on the direction of the wind, I guess ...
The worst to me is the introduction of LangChain Expression Language (LCEL) with the Runnable interface. It allows to build chains with a simple syntax:
chain = prompt | model | parser
It seems great at first until you are trying to build something more complicated than the basic tutorial examples shown in the documentation! The image in this post is an extract of the documentation: I challenge you to explain to me what is happening in that code! Ok, after a little while, you can start to see the logic, but what about you need something slightly different? How long will that take you before you will be able to put together the code that is meant to simply put a prompt into an LLM? What is the point of trying to reinvent the Python syntax to make it more complicated?!
Right now, I am leaning toward moving my stack to Haystack (https://lnkd.in/ewaymSgG) for chaining and data connectivity, and Burr (https://lnkd.in/eM4r8qh4) for a more agentic framework. LangGraph seems nice, though, but I now have very little confidence that the LangChain guys can actually pull it off! What do you think?
--
👉 LLM Masterclass starts Aug 15th: https://lnkd.in/e3YdK6DT
--