Everyone is building LLM routers, we deprecated ours
Posted by brunaxLorax 3 days ago
Comments
Comment by overgard 2 days ago
I'm really skeptical of this idea. Pragmatically: who has time to understand the nuances of these models when there's like a new one every week? Also without any view into the training, figuring out what each model is potentially good at is more or less just throwing spaghetti against the wall, except the spaghetti is potentially very expensive and might insert subtle issues into your code base.
Comment by drusepth 2 days ago
The better I get at recognizing what each model is good/bad at, the more I'm glad we're taking the time to choose specific models for specific prompts -- and the more I wouldn't trust a generic router to efficiently route for me.
Comment by fennecbutt 2 days ago
Comment by cyanregiment 2 days ago
Maybe Gemini or ChatGPT is a "Hi" while running a local Mistral 7b is a "Lo" - sometimes you want lo-res technologies. Faster, lighter, does the job.
Find the same with image, video, vision, and so-on.
Probably get away with pretty weak vision models for some basic edge detection, but need "a good one" for things like OCR.
I don't find a ton of competitive difference amongst the "good ones" especially not reflected in the pricing and marketing. IMO there are pretty much just "non-AI" algorithms, "basic AI" that are getting more interesting on-device for some use cases, and "good AI" or what we'd call "frontier models" - which again, not seeing a ton of differentiation on that layer.
Comment by overgard 2 days ago
Comment by cyanregiment 2 days ago
Comment by LoganDark 2 days ago
Comment by cyanregiment 2 days ago
UX-wise, I don't predict out "ghost text" like Google has been doing, I just preload the input value with the prediction. You can edit as you want. Saves a ton of time.
Comment by mrkeen 2 days ago
If it's too hard for a programmer to reason about, I wouldn't trust the programmer sitting next to him to automate the problem away.
Comment by danielmarkbruce 2 days ago
Now, there are thousands of use cases for lots of the fontier models. I don't use them for everything, so I don't test them except on the stuff I'm using them for.
Comment by overgard 2 days ago
But honestly, even if I went with your idea of picking a small number of models to eval, I wouldn't even know how to choose that subset other than.. what's hottest in the hype cycle? The benchmarks are useless and gamed. There's not a lot of transparency in how they're trained, so there's no way for me to go like "Well, I care about how much graphics programming it's been trained on, and I can see X ingested Y amount of training data on that.." It's basically a stab in the dark of very frothy people saying "X CHANGES EVERYTHING!" with no particular details other than a bunch of guys on youtube being like "I gave it a really lame prompt and it made me this game that absolutely nobody would ever want to play!"
Comment by danielmarkbruce 1 day ago
Knowing how much of type X data a model was trained on isn't going to help you one bit. Various phases of training can effectively wipe out the training from earlier steps if not done well. All that matters is does the model do what you want it to do. In practice almost everything in AI/ML is empirical.
Comment by overgard 1 day ago
Comment by danielmarkbruce 1 day ago
Comment by TZubiri 2 days ago
But model aggregators have a layman smell to me, some laymen think model A talking to model B is materially different than model A talking to model A with another context, also laymen tend to see 'learning AI' as trying out new products and keeping up with product relases.
I think it's less like having a toolbox of screwdrivers, hammers and a wrench, and more like having 30 brands of shovels because there's been a wave of shovel commercials.
Comment by brunaxLorax 2 days ago
Comment by mountainriver 2 days ago
Comment by daeken 2 days ago
We don't do any "prompt engineering" to make specific models work better or worse, so this gives us a direct comparison that lets us objectively compare how they'll work in practice for different types of tasks.
Good enough to have guided multiple model swaps and measured increases in productivity.
Comment by zackify 2 days ago
Comment by bobmcnamara 2 days ago
Comment by cyanregiment 2 days ago
So is he, and so does he. He looks like the Tales From The Crypt guy I have no idea how he's still doing manual labor.
Comment by jurgenburgen 2 days ago
This has worked quite well for me and saves a lot of time.
Comment by iLoveOncall 2 days ago
LLMs are not like screwdrivers, IDEs, or any other tool. They're indeterministic.
I keep seeing everyone make wilder and wilder metaphors which just don't work at all, as a sort of "argument" supporting whatever they say, with 0 actual proof.
Comment by paradoxyl 2 days ago
Comment by stingraycharles 2 days ago
Comment by overgard 1 day ago
Comment by inigyou 2 days ago
Comment by dweez 2 days ago
One specific challenge I was seeing is that difficulty depends a lot on what information is retrievable by the agent. Consider the question "what is the 5-state busy beaver number?" (https://en.wikipedia.org/wiki/Busy_beaver). In 2023 this would be a Mythos-tier research problem, but a solution was proved in 2024 so today any minimally intelligent model with a web search tool can just fetch the answer. You don't know which queries will be basic summarization and which will be deep reasoning until you get going.
Comment by all2 2 days ago
What I mean is that most tasks can be recursively fragmented into smaller tasks, and once you've hit suitable leaf nodes -- where the task is very granular -- you can begin to deterministically show which models perform better or worse for that specific task. Then, when your agent is running a workflow, you may use various models for different steps in a workflow. For example, some models may excel at exploration, some at determining a good architectural fit for an implementation, some at actually writing the implementation, and so on.
But you don't know until you define your 'work' taxonomy, and still further, you won't know until you have a statistically significant number of runs on a given chunk of work. Once you have that, though, you can hone in on models that excel at one specific task or another and prefer those the majority of the time (say ~80%) and hold back the remainder work as a 'test corpus' just in case a different or new model does even better.
This is something I've kept in the back of my head as I've been working through my agent harness primitives -- specifically enabling different models per chunk of work.
Comment by lucas_t_a 1 day ago
Comment by dofm 2 days ago
What you actually want is a model that can conclude either "I know the answer to this with confidence" and answer, or "I think I don't know the answer to this, I should ask another model and I know which one". But I don't think LLMs can really bring their uncertainty to the surface in that way yet? Their internal confidence can be measured and returned, so you could probably front a more powerful model with a knowledgeable assistant, but they can't consciously mark their own homework?
Comment by zbentley 2 days ago
It can? I was under the impression that confidence was either self-reported by the LLM or assessed by having another model interpret the output response. If there's a confidence score at the level of the actual model math, that's news to me.
Comment by dofm 2 days ago
My understanding was that models can be post-trained to assess their own confidence on short prompts within a level of accuracy (there was an article about this a few weeks ago that I can't find), but can't use it to reason, and that research has shown that internally they effectively have a measurable sense of truth but can't surface it:
https://arxiv.org/abs/2410.02707
I mangled what I was trying to say but the point I guess is, it is effectively in there, and researchers can see it and therefore score it, but it is not something the LLM can use.
The problem seems to me (layman's understanding at best) that the LLM is inherently confident within the words of its answer, because of what the model is trained to do and how it is trained. So you can never get an accurate "I don't know this" from a model while it is answering; it is bullshitting.
(One of the things that is most interesting to me at the moment is asking a small local LLM what it knows about a topic and then testing it. It can have no idea of what it wasn't trained on, but any question about what it knows is seemingly going to trigger it to work through all the summary word associations it did find in training, so it can sort of summarise its knowledge that way, with some likelihood of success, without any sense of introspection)
Comment by jdiff 2 days ago
Comment by dofm 2 days ago
Yes — they claim that it is likely to be able to assess confidence in whether the statement it just made is correct. But it isn't going to be capable of that while it is answering.
Comment by TZubiri 2 days ago
Comment by TZubiri 2 days ago
Comment by JarJarBeatU 2 days ago
Comment by velcrovan 3 days ago
> "A cache-aware model router will take that into account by adding stickiness to the initially chosen model and keeps querying it."
Comment by brunaxLorax 2 days ago
Comment by hhh 3 days ago
Comment by inigyou 2 days ago
I thought it could be a typo for "X will do ... and do Z" but only when I went to write why it's weird, I realised it doesn't have to be a typo.
It doesn't even matter here. It would mean the same thing either way.
Comment by 1bpp 2 days ago
Comment by thehamkercat 3 days ago
Comment by jeremyjh 2 days ago
Comment by brunaxLorax 2 days ago
Comment by try-working 2 days ago
The model pool should be kept small, and models in the pool should be clearly differentiated. For example, one large frontier model for quality, one small, fast and cheap model like DeepSeek V4 Flash for routing work.
These two principles by themselves solve the issues with caching, with routing decision making. I routinely hit >99% cache while routing between GPT 5.4 and DeepSeek.
Comment by bluejay2387 2 days ago
Comment by randomblock1 2 days ago
I don't think this a good example. The first step would be reading the documentation, reading an overview of the tests, then executing commands to run the tests. A cheap model could do that. After that, though, the router will have to figure out how complex the tests are, which is the hard part, but I can't imagine it's that hard to determine a bunch of C code is tougher than some HTML from looking at it. Unless they want to select one model at start and never change it, because that's pretty clearly not the right way to go about routing.
Regardless I agree that routers usually aren't worthwhile, at least in the form of something that's meant to be universal. It's probably more efficient to just change something in the repo code, whether that's skills or instructions or something else. Benefit of that being it's persistent, portable, and more well tuned than guessing complexity on every turn.
Comment by brunaxLorax 2 days ago
Comment by mmargenot 2 days ago
If you really need more discrimination of the complexity of an input to get an efficient response, sft or rl tuning something for your harness would be more effective.
Comment by kaycey2022 2 days ago
A serious router therefore needs to build up a dataset of how different models responded, end to end, to different tasks on different contexts. I won’t comment on whether the current frontier models can reliably judge these outputs, but I am sceptical about that. And moreover look at the state of evils! They are gamed to hell and keep losing credibility.
A more difficult problem for router builders is that they are working on an opaque system behind an external API. How can you reliably guarantee model behaviour when model behaviour has been shown to deteriorate under arbitrary conditions that have nothing to do with the task given? So much investment only to be an AI company that can get rug pulled by the real AI companies at any given time.
I would think the only people who can come up with good routers for a collection of models are the inference providers themselves. Because theoretically they have full control of how their models are served. And inference is not zero cost or cheap for them either. And going by OpenAI’s experience routing is not an easy problem for them to solve either. And they don’t have the incentive to route you to cheaper models and reduce costs for customers at the same time. Routing objective for them is to increase their own profits.
Comment by firasd 2 days ago
Comment by brunaxLorax 2 days ago
Comment by luciana1u 2 days ago
Comment by scionaura 2 days ago
The labs are incentivized to solve this problem themselves, since they’re competing on a 2D cost-intelligence frontier. If they can reduce cost without harming intelligence they will do that and pass on (some of) the cost reduction to the user. There are nicer solutions available to them because they can cut into lower levels of abstraction.
E.g. you should consider speculative decoding to be one (very conservative) form of routing and note that you can’t implement that for the labs from the outside.
Comment by CuriouslyC 2 days ago
Comment by brunaxLorax 2 days ago
Comment by atlex2 2 days ago
I think the truth is that it's not an efficient cost cutting method. Your router has to be at least as 'smart' as all the but the smartest of your models (models do poorly when asked 'is this a task you're well suited to'), and that means you're caching multiple prompt histories including kv-filling/prefix caching on your expensive router model. Most of the time, not super great for savings.
Comment by brunaxLorax 2 days ago
Comment by rrvsh 2 days ago
Comment by 0xDEAFBEAD 2 days ago
In other words, the more queries you're serving, the more worthwhile it looks to figure out a viable method of model routing.
Comment by rush86999 2 days ago
Comment by brunaxLorax 2 days ago
Comment by blackcat201 2 days ago
Comment by owenthejumper 2 days ago
Comment by hrpnk 2 days ago
Comment by sudb 2 days ago
Comment by brunaxLorax 2 days ago
Comment by htrp 2 days ago
Seems like a naive classification model lacking context?
Comment by brunaxLorax 2 days ago
Comment by maxrev17 2 days ago
Comment by robertclaus 2 days ago
Comment by ramraj07 2 days ago
Comment by brunaxLorax 2 days ago
Comment by jml78 2 days ago
Comment by brunaxLorax 2 days ago
Comment by seizethecheese 2 days ago
Saying routers don't work is sort of like saying serverless doesn't work. It depends on when and how!
One routing implementation that recently launched here is interesting (https://news.ycombinator.com/item?id=49099143). It routes based on the models' initial trajectories. This is like having multiple developers get started, seeing what they're doing, then pulling all but one off the project. It should work, but doesn't seem ideal!
I've gotten routing working well for typical chatbot prompts in http://pellmell.ai. This is fine because prompts are easy to classify into category buckets (for example: legal, medical, general knowledge, code). And models definitely have strengths and weaknesses. You want Gemini to answer General Knowledge and you want Claude to answer coding.
Comment by brunaxLorax 2 days ago
Your point is interesting, you say that task specificity is easier to classify than task complexity, which I agree - I didn't mention it but we had task specificity routing too :). My opinion is that in many cases task specificity calls are easy to distinguish at build time, and therefore you can isolate them and attach the right model/settings beforehand, so you have less need for a smart routing on the fly.
Comment by coffinbirth 2 days ago
Comment by inigyou 2 days ago
Comment by brunaxLorax 2 days ago
Comment by ljlolel 2 days ago
Comment by maherbeg 2 days ago
Comment by brunaxLorax 2 days ago
Comment by joshowens 2 days ago
Comment by scotttaylor 3 days ago
Comment by fibuladev 2 days ago
Comment by aegisora_ai 2 days ago
Comment by jing09928 2 days ago
Comment by KoleSeise1277 2 days ago
Comment by youre-wrong3 2 days ago