Hacker Newsnew | past | comments | ask | show | jobs | submit | nfcampos's commentslogin

But on the other hand the claude app is garbage… https://github.com/anthropics/claude-code/issues/22543 obviously native apps can be garbage too, but I must say electron apps have a surprisingly high incidence of terrible performance issues, unsure if it’s a correlation or causation issue

LangGraph implements a variant of the Pregel/BSP algorithm for orchestrating workflows with cycles (ie. not DAGs) and parallelism without data races. You can design your graph as a state machine if you so desire



Hi do you mind sharing more what you mean by "the api makes excessive calls"?


Hi, you don't have to use langchain tools or ToolNode with langgraph, you can absolutely write your custom tool handling logic. In langgraph nodes are just functions that can do whatever you want, seems to be some misconception somewhere?


That's true, you could not use the ToolNode object and define your own logic to handle tools. You do need to use at least the @tool decorator in order to attach those functions to a model using LangGraph's bind_tools function.

Defining some of the functions as tools was where some of the "self" parameter issues mentioned in the TDS write up came up - since those parameters aren't added by the LLM, but LangGraph/Pydantic errors if there missing.

Technically you could forgo using the ToolNode object, not define your functions as tools, not use the bind_tools method, and potentially not use Langchain's model abstractions - but at that point, you're not using much of the framework at all.

Let me know if I'm missing something there!


Almost none of those things are part of the LangGraph framework? LangGraph does the scheduling, checkpointing, state management, etc.

All of those things are LangChain abstractions that you can use when building a graph.


FWIW we have first class support for subgraphs in the library, would love to know what issues you faced there. Support for subgraphs in the studio is coming soon.


Fwiw we didn't start with Pregel, but instead reached for it when we saw issues (described elsewhere in this thread) with the previous approach


Thanks, would using a topological sort or other simpler algos, not sufficed processing the graph with cycles directly, may not be as optimised as Pregel, but would have been simpler.


A topological sort can't be used for graphs with cycles



Pregel actually doesn't require the structure of the graph to be declared ahead of time, the next set of tasks (functions) to run is computed at the beginning of each step, so in theory the graph topology could be entirely dynamic. Langgraph supports dynamic topologies too, ie. don't declare any hard edges, add a conditional edge after every node


Good to know!

Is there a succinct explanation of the value that pregel brings to LangGraph? Is it the 3 items I mentioned?


The value of using pregel is supporting cyclical graphs, with concurrent tasks, but completely deterministic behavior (eg. doesn't matter that task A this time happens to finish before task B, its results will be applied in a predetermined order, etc)


Making concurrent work deterministic and solving data races makes sense.

Thanks for explaining! I didn't fully grok this from the LangGraph docs


Langgraph is not a no-code tool for visual programming, it's an implementation of the Pregel algorithm for execution of cyclical computation graphs (ie not DAGs)


Oh I see - that's interesting.

Honestly I'm happy to be proven wrong about the usefulness of it.

I've used langsmith and found it quite useful. I think I was just so jaded by my bad experience with Langchain, that I'm immediately skeptical of other "lang" products.


I almost didn't try langgraph because I had similar experiences with langchain. IMO it is a lot better than langchain; its abstractions are lower level and more appropriate at least for the projects I've taken on. I think it's probably the best toolkit with which to prototype an agent-based workflow right now.

That being said, it's not doing that much. And you still end up having to use some of langchain's abstractions. If this current "make a cyclical graph of LLM agents that send messages to each other" thing has any staying power than I imagine we'll see a more robust option soon. Personally I'd love a way to build agent graphs in a strongly typed language with first class concurrency.


What's your opinion of Langgraph, if you're not affiliated with it?


I'm one of the authors so my opinion would be biased ha


Really? Can you point to code for that? To me it's just a way to describe a graph and execute it, exactly like https://github.com/dagworks-inc/burr (I'm an author).



Wow. Implemented pregel to run a 3 node graph... Jokes aside, that's an interesting thesis to have in there...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: