Building a Multi-Agent System from Scratch: Architecture Patterns

Posted by kadharmfn 1 day ago

Counter100Comment41OpenOriginal

Comments

Comment by pss314 21 hours ago

I liked going thru Stanford CS146S: How always-on agents work

Lecture recording: https://www.youtube.com/watch?v=L1OBRtfPS34

Slides: https://drive.google.com/file/d/1b8WiBk_lcB3ue-jZMLijSUMLj6S...

Note: The lecture talks mostly on always-on agents and not necessarily multi-agent system.

Comment by pss314 21 hours ago

CMU's 11-768: AI Agents course https://www.cmu-agents.com/ looks really good. I haven't had a chance to go thru it yet.

Comment by 1shooner 17 hours ago

This is probably my own bias, but the Claudlish in that slide deck is throwing me off. There's just part of my learner brain that can't take it seriously if you can't write your own headings.

Comment by phainopepla2 1 day ago

Perhaps I'm being uncharitable, but when I open up a page that was obviously created by Claude, I just close it again.

Comment by crimsontech 7 hours ago

I saw the last heading was "The Honest Summary" and closed it thinking it would be out of date by now anyway.

Comment by KellyCriterion 1 day ago

TBH, this one is an example of the rather good bucket, Id say?

I have seen much much worse examples on corporate blogs for example, where I question if authors even understand how to use any publishing system and how colors & info architecture works :-D

Comment by l9o 22 hours ago

haha I agree that the information seems well laid out in this case, but the "Anthropic terracotta" is waaay too overused nowadays

Comment by mtrovo 17 hours ago

The more I see these daily slop posts, the more I wish it were more common to dump your conversation transcript with your slop post with an option to jump in with my own live LLM session and a Socratic persona where I figure out by questioning what exactly the author thought this was worth posting about.

Comment by randysalami 4 hours ago

I think most people’s conversations in these slop mines would show a lack of depth and undermine what image they are trying to portray. I do agree though. I’m always happy to show my transcripts. Usually they show the gap between someone experienced and inexperienced rather than the opposite.

Comment by beardbandit 1 hour ago

Is it just me or are many of these things just common sense to someone that has designed systems before? I’ve found zero help with many of these AI-related blogs and articles. The only novel ones that actually turn into anything actionable or insightful are the first party articles from the frontier companies themselves…

Comment by brkomir 21 hours ago

I usually run 4-5 claude sessions in parallel on the same branch, each with its own working plan or work item. They coordinate almost in real time, leaving messages in a shared queue and picking them up every 30 seconds. What keeps them from stepping over each other's work is a commit script that allows only staged changes from one session to be committed at a time.

Where it actually pays off to have separate sessions is the code review. Every code change that affects how the app behaves is checked by a session that didn't write the change. Some numbers: 4,454 verdicts on 4,471 commits since September. About four in five first reviews found something, and about half asked for changes.

Comment by cgio 20 hours ago

They always find something. I am at the level where in a review I allow the reviewer to give me the most important item only and explain its impact.

Comment by brkomir 13 hours ago

[dead]

Comment by UncleOxidant 16 hours ago

Interesting. I'd like to have something where I'm primarily running a local model - Qwen3.8-Flash-Next - and then have it consult with a frontier model as an "advisor" - like how you can setup an advisor model in Claude code.

Comment by empath75 23 hours ago

If you leave "The Honest Summary" in anything Claude wrote, I am not going to read any of it, shows a complete lack of care or interest in what you are doing.

I don't care if you are having Claude write something for you, but I feel like I spent more time writing these two sentences than this person put into this post.

Comment by scubbo 22 hours ago

My opinion has shifted over the last few months. Instead of valuing effort put into "putting words together", I am trying to judge the value that I get _from_ the words[0].

I'm reminded of a passage in Stephen Fry's "The Liar"[1], which draws the distinction between a book as an object of art, and a book as a vehicle for communication. If the message is worthwhile, I don't care if it was blurted out by a model or if blind monks inscribed it by hand into vellum parchment.

Don't get me wrong, there's certainly correlation - if I _know_ you've taken a lot of effort to write something, the chances are good that there is worthwhile content being communicated. But the correlation is _not_ perfect.

[0] when it comes to technical writing that intends to communicate information. Narrative writing that intends to evoke an emotion or viewpoint is a different story!

[1] https://blog.scubbo.org/posts/books-as-vehicles/

Comment by ClaraForm 22 hours ago

The problem is there's no signal for the recipient that the value being delivered aligns with the intention of the human who set the prompting chain into action, right?

If an AI auto-outputs something with no sign of final check-off by a human, we don't even know if the intention of the human is to spam 100 different articles and delete 99 based on perceived success, or if the AI actually helped them translate something worth saying.

edit: One might argue that value and intention should be kept separate, but clear intention is also an indicator of value, and these days there are dozens of sources of material. It's very easy to "talk" at the void, and very difficult to figure out where to "listen". If an author doesn't try to make "listening" easier, then it puts the value they hold into question if they don't care about it enough themselves.

Comment by whartung 16 hours ago

  > The problem is there's no signal for the recipient that the value being delivered aligns with the intention of the human who set the prompting chain into action, right?
Don’t you think that the fact that the person put their name on it and published it carries some weight as to the congruence of what the person wanted to convey and text of the article itself?

We don’t even know what iterations, granted, if any, were performed on the article text before it was published.

Comment by scubbo 15 hours ago

> Clear intention is also an indicator of value

Genuine question - is it? Why? If I set out to write a mediocre guide to bicycle maintenance, and through a spectacular series of typos I accidentally write a recipe for a sublime cheesecake, it's still true that I've written a good recipe, even if that wasn't my intent.

(Hopefully we can bypass quibbling about the use of the term "write" in an LLM-assisted context. Readers should feel free to substitute the clunkier phrase "take actions that cause words to be recorded" if they wish)

> It's [...] very difficult to figure out where to "listen"

I don't agree. Or rather, I don't think it's any harder than it has been since the Internet exploded, long before LLMs. It's just based on track record. Read an article; note that it's useful; note the source. See another article by that source; find it useful again; begin to attribute trust to them. Read a less-good article by them; lessen your trust somewhat.

By all means, observe "this person probably didn't edit this after an LLM generated it" and take that as an input to whether you will trust their observations - but you should probably be verifying anything technical that you read anyway. If you consistently observe unhelpful or misleading content from a particular source, you should stop trusting it, regardless of whether that content was human- or AI-generated.

> If an author doesn't try to make "listening" easier, then it puts the value they hold into question if they don't care about it enough themselves.

Again, I don't think that's true. If someone has tweaked and moulded an LLM-content-generation pipeline such that they can generate a piece of technical content that is still genuinely-useful even without a human editing pass to reduce LLM-isms, they're still a useful source. I might justifiably think they're lazy, uninvested, or not an expert in the domain - but it would be foolish to deny the usefulness of their output.

To put it differently - Michael Jordan could wake up hungover and, with one hand behind his back, still kick my ass at basketball. The fact that he's not trying the hardest he could doesn't mean that the scoreboard would be any less valid. Equivalently, caring about the content you create doesn't directly affect the value of what you create (again, I can't stress enough - for technical content only!) - it's probably positively correlated (because it will cause you to take more care), but _not_ a prerequisite.

Comment by goosejuice 22 hours ago

Beyond that, criticism based on a simplistic aversion to the mere usage of an LLM can be ablelist. I think few of us want to give our own time to things others didn't invest time in, but how do you really know why the reader used an llm, or even if they did, at a surface level?

There's obviously no obligation to read someone else's shit, but there's no obligation to criticize it without context either. Why not criticize the content instead of the assumed methods?

Comment by mncharity 16 hours ago

I'm reminded of a American professor teaching in France, who said... I sound more intelligent in English.

Comment by latentsea 14 hours ago

Invite a culture of laziness and the laziest of people will thrive in it. Just sayin'.

Comment by bill10 12 hours ago

Claude code is good enough now to call subagent and manage them itself, right?

Comment by kadharmfn 1 hour ago

[dead]

Comment by albertgoeswoof 21 hours ago

What’s an example of a multi agent system that people are using?

Comment by gerardnico 3 hours ago

Most agents starts sub-agent to not mess with the context when exploring (ie they gather files, directory listening)

This agent for Claude is called explore. https://code.claude.com/docs/en/sub-agents

It returns only a summary.

Comment by kadharmfn 18 hours ago

Claude's Research feature itself is one such example. one agent plan and multiple sub agents in parallel work on assigned task and reports back.

Comment by bob1029 1 day ago

Sub agents are significantly more useful than multi agents.

Wrap a nested prompt with a tool call that is invoked by the caller prompt. That is the answer to all your suffering. You can repeat this for as many layers of invocation as you desire. You can layer determinism and non-determinism as much as you like in whatever orders you see fit with additional alignment, retry policies, logging, etc.

Agents running concurrently will not go any faster than one well-designed hierarchical agent system.

Imagine the simple task of incrementing a global counter. That would be my #1 benchmark. If you can demonstrate a MAS can increment that counter faster than a single agent can (monotonically without skipping), then I will happily delete 100% of the AI-related code I've authored and start over using your ideas.

Comment by gbnwl 23 hours ago

What harness are you using? In both Claude Code and Codex I run into the issue of subagents being unable to dispatch their own subagents, so I haven't been able to play with "many layers of invocation".

Comment by mickeyp 9 hours ago

You can do this trivially in dreamcoder.ai.

Build the sub agent to your specification (prompt, how the parent agent should call it); give it tools and optionally skills; then give it permission to call some or all the other sub agents you have set up.

Easy-peasy.

Comment by bob1029 23 hours ago

Custom harness, custom tools.

With custom we don't have to disclose to the caller that the implementation of the tool is another LLM. Each piece of deterministic tool code can firewall the perspective of the model as appropriate.

Think of a sub agent as being isomorphic with a tool call.

Comment by bscannedinc 18 hours ago

[flagged]

Comment by vielite1310 22 hours ago

Agree on this. I have been using oh-my-pi and subagents just works for me.

I have never see a case where I need multi-agents talking to each others or something

Comment by dominotw 1 day ago

depends on what type of problem it is

Comment by bob1029 23 hours ago

I am curious if we have any examples of problems that can only be solved via multiple concurrent prompts coordinating in real time.

Comment by dominotw 46 minutes ago

afaik math problems at openai are being solved like this. i heard it on noam brown dwarkesh podcast

Comment by mncharity 16 hours ago

As with the sibling comment from kadharmfn (quickly flagged/dead why??), problems which are inherently real time.

For example, a small fast model watching another model's CoT stream to annotate it - highlighting and summarizing for me, or flagging intervention conditions.

Comment by kadharmfn 16 hours ago

[flagged]

Comment by alala-lala-lon 1 day ago

[dead]

Comment by latentsea 14 hours ago

The Honest Summary

Comment by kadharmfn 1 hour ago

Thanks for the feedback. is this the question or comment ?

Comment by FLeXMurphy 22 hours ago

I remember all these topics being discussed... well over 25 years ago, though I'm sure they are much older than that.

Comment by nzjrs 22 hours ago

Slop

Comment by kadharmfn 16 hours ago

Thanks for feedback. Content generated with the help of AI but will make sure to post original hand written content soon.

Comment by kadharmfn 1 day ago

[flagged]

Comment by RetardedBastard 21 hours ago

[dead]

Comment by cush 1 day ago

Does anyone else open sites with this default claude code theme and immediately close them?

Comment by kadharmfn 18 hours ago

Thanks for flagging. Changed the theme !