TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

LLM Agents Are Simply Graph – Tutorial for Dummies

263 pointsby zh24082 months ago

12 comments

DebtDeflation2 months ago
There are two competing definitions of agents being used in industry.<p><a href="https:&#x2F;&#x2F;www.anthropic.com&#x2F;engineering&#x2F;building-effective-agents" rel="nofollow">https:&#x2F;&#x2F;www.anthropic.com&#x2F;engineering&#x2F;building-effective-age...</a><p>&quot;- Workflows are systems where LLMs and tools are orchestrated through predefined code paths.<p>- Agents, on the other hand, are systems where LLMs dynamically direct their own processes and tool usage, maintaining control over how they accomplish tasks.&quot;<p>What Anthropic calls a &quot;workflow&quot; in the above definition is what most of the big enterprise software companies (Salesforce, ServiceNow, Workday, SAP, etc.) are building and calling AI Agents.<p>What Anthropic calls an &quot;agent&quot; in the above definition is what AI Researchers mean by the term. It&#x27;s also something that mainly exists in their labs. Real world examples are fairly primitive right now, mainly stuff like Deep Research. That will change over time, but right now the hype far exceeds the reality.
评论 #43421950 未加载
评论 #43434486 未加载
campbel2 months ago
I follow Mr. Huang, read&#x2F;watch his content and also plan to use PocketFlow in some cases. A preamble, because I don&#x27;t agree with this assessment. I think agents as nodes in a DAG workflow is _an_ implementation of an agentic system, but is not the systems I most often interact with (e.g. Cursor, Claude + MCP).<p>Agentic systems can be simply the LLM + prompting + tools[1]. LLMs are more than capable (especially chain-of thought models) to breakdown problems into steps, analyze necessary tools to use and then executing the steps in sequence. All of this is done with the model in the driver seat.<p>I think the system described in the post need a different name. It&#x27;s a traditional workflow system with an agent operating on individual tasks. Its more rigid in that the workflow is setup ahead of time. Typical agentic systems are largely undefined or defined via prompting. For some use cases this rigidity is a feature.<p>[1 <a href="https:&#x2F;&#x2F;docs.anthropic.com&#x2F;en&#x2F;docs&#x2F;build-with-claude&#x2F;tool-use&#x2F;overview" rel="nofollow">https:&#x2F;&#x2F;docs.anthropic.com&#x2F;en&#x2F;docs&#x2F;build-with-claude&#x2F;tool-us...</a>
评论 #43421466 未加载
评论 #43419329 未加载
评论 #43418134 未加载
zh24082 months ago
Hey folks! I just posted a quick tutorial explaining how LLM agents (like OpenAI Agents, Pydantic AI, Manus AI, AutoGPT or PerplexityAI) are basically small graphs with loops and branches. For example:<p>OpenAI Agents: for the workflow logic: <a href="https:&#x2F;&#x2F;github.com&#x2F;openai&#x2F;openai-agents-python&#x2F;blob&#x2F;48ff99bb736249e99251eb2c7ecf00237488c17a&#x2F;src&#x2F;agents&#x2F;run.py#L119" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;openai&#x2F;openai-agents-python&#x2F;blob&#x2F;48ff99bb...</a><p>Pydantic Agents: organizes steps in a graph: <a href="https:&#x2F;&#x2F;github.com&#x2F;pydantic&#x2F;pydantic-ai&#x2F;blob&#x2F;4c0f384a0626299382c22a8e3372638885e18286&#x2F;pydantic_ai_slim&#x2F;pydantic_ai&#x2F;_agent_graph.py#L779" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;pydantic&#x2F;pydantic-ai&#x2F;blob&#x2F;4c0f384a0626299...</a><p>Langchain: demonstrates the loop structure: <a href="https:&#x2F;&#x2F;github.com&#x2F;langchain-ai&#x2F;langchain&#x2F;blob&#x2F;4d1d726e61ed58b39278903262d19bbe9f010772&#x2F;libs&#x2F;langchain&#x2F;langchain&#x2F;agents&#x2F;agent_iterator.py#L174" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;langchain-ai&#x2F;langchain&#x2F;blob&#x2F;4d1d726e61ed5...</a><p>If all the hype has been confusing, this guide shows how they actually work under the hood, with simple examples. Check it out!<p><a href="https:&#x2F;&#x2F;zacharyhuang.substack.com&#x2F;p&#x2F;llm-agent-internal-as-a-graph-tutorial" rel="nofollow">https:&#x2F;&#x2F;zacharyhuang.substack.com&#x2F;p&#x2F;llm-agent-internal-as-a-...</a>
评论 #43418941 未加载
评论 #43418733 未加载
评论 #43422386 未加载
评论 #43424526 未加载
评论 #43417909 未加载
_pdp_2 months ago
It is hard to put a pin on this one because there are so many thing wrong with this definition. There are agent frameworks that are not rebranded workflow tools too. I don&#x27;t think this article helps explain anything except putting the intended audience in the same box of mind we were stuck since the invention of programming - i.e. it does not help.<p>Forget about boxes and deterministic control and start thinking of error tolerance and recovery. That is what agents are all about.
评论 #43421213 未加载
评论 #43421137 未加载
评论 #43418260 未加载
评论 #43420184 未加载
评论 #43418763 未加载
mentalgear2 months ago
Everything that was previously just called automation or pipeline processing on-top of LLM is now the buzzword &quot;agents&quot;. The hype bubble needs constant feeding to keep from imploding.
评论 #43418625 未加载
jumploops2 months ago
Anthropic[0] and Google[1] are both pushing for a clear definition of an “agent” vs. an “agentic workflow”<p>tl;dr from Anthropic:<p>&gt; Workflows are systems where LLMs and tools are orchestrated through predefined code paths.<p>&gt; Agents, on the other hand, are systems where LLMs dynamically direct their own processes and tool usage, maintaining control over how they accomplish tasks.<p>Most “agents” today fall into the workflow category.<p>The foundation model makers are pushing their new models to be better at the second, “pure” agent, approach.<p>In practice, I’m not sure how effective the “pure” approach will work for most LLM-assisted tasks.<p>I liken it to a fresh intern who shows up with amnesia every day.<p>Even if you tell them what they did yesterday, they’re still liable to take a different path for today’s work.<p>My hunch is that we’ll see an evolution of this terminology, and agents of the future will still have some “guiderails” (note: not necessarily _guard_rails), that makes their behavior more predictable over long horizons.<p>[0]<a href="https:&#x2F;&#x2F;www.anthropic.com&#x2F;engineering&#x2F;building-effective-agents" rel="nofollow">https:&#x2F;&#x2F;www.anthropic.com&#x2F;engineering&#x2F;building-effective-age...</a><p>[1]<a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=Qd6anWv0mv0" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=Qd6anWv0mv0</a>
评论 #43419260 未加载
miguelinho2 months ago
Great write up! In my opinion, your description likely accurately models what AI agents are doing. Perhaps the graph could be static or dynamic. Either way - it makes sense! Also, thank you for removing the hype!
评论 #43418628 未加载
nxpnsv2 months ago
I found it understandable and clear. Pocket flow looks cool, although that magic with - &gt;&gt; operators seems a bit obtuse... Also, I think &quot;simply&quot; is a trap - an agent might be modeled by a graph, but that graph can be arbitrarily complex.
admiralrohan2 months ago
Strangely the original HN post on the framework got no comments but this one is getting viral! Good luck.
bckr2 months ago
Anyone succeeding with agents in production? Other than cursor :)
v3ss0n2 months ago
My experience is Mistral Small, QwQ and QwenCoder can build much better diagrams in Mermaid compared to those attempt by Mr haung
DrFalkyn2 months ago
I think the model he is looking for is a deterministic finite automata (DFA)