메뉴
HN
Hacker News 26일 전

모델 라우팅의 기본 원칙

IMP
7/10
핵심 요약

AI 코딩 에이전트 및 복잡한 워크플로우에서 비용과 성능을 최적화하기 위한 '모델 라우팅'의 핵심 원칙을 다룬 글입니다. 단순히 여러 최신 모델을 섞어 쓰는 것보다 속도, 품질, 비용 측면에서 명확한 차별점이 있는 소수의 모델을 두고, 실제 작업 환경 기반의 벤치마크와 과거 데이터를 활용해 라우팅해야 한다고 강조합니다.

번역된 본문

Try-Works: 프로젝트, 제품 및 아이디어 모음

프로젝트 & 제품: rlm-workflow, tinytunes, DJ, lurkkit, role-model, Pocketmodel 글쓰기: 코딩 에이전트를 위한 recursive-mode, 중국 AI 랩들이 오픈소스로 전환하고 유지하는 이유, 코딩 에이전트와 커지는 1% 문제, role-model: 모델 라우팅 프로토콜을 위한 사례 연락처: 이메일, 내 새 트위터

모델 라우팅의 기본 원칙 2026-07-03

이것은 제가 모델 라우터, 라우팅 프로토콜, 그리고 Pi 확장 프로그램인 role-model을 개발하면서 정립한 몇 가지 모델 라우팅 원칙입니다. 이 원칙들은 모델 라우터를 사용하거나 직접 구축하는 모든 사람에게 유용할 것입니다.

1. 모델들을 명확하게 구분하세요 가끔 최신 GPT 모델과 최신 Opus 모델을 함께 사용하면서, 코딩 워크플로우에서 각각 다른 역할을 부여하는 분들을 봅니다. 이것 자체가 틀린 것은 아니지만, 라우팅 관점에서는 최적의 선택이 아닙니다. 사람마다 GPT와 Opus 모델에 대한 경험과 선호도가 다르겠지만, 두 모델 모두 코딩에 특화된 일반적인 범용 모델이며 동일한 성능 및 비용대를 가집니다. 즉, 두 모델 사이의 라우팅은 어렵습니다. 요청의 난이도를 판단해 모델과 매칭시키는 것 자체도 충분히 어려운 일인데, 모든 영역에서 두 모델이 우열을 가리기 어렵다면 어떤 모델로 보내야 할지 결정하는 것은 더욱 어려워지기 때문입니다.

두 개의 최신 프론티어 모델 사이에서 라우팅하는 대신, 하나의 최신 프론티어 모델과 '제약의 삼각형(속도, 품질, 비용)' 중 적어도 한 가지 측면에서 뛰어난 성능을 발휘하는 다른 모델을 조합해 라우팅하는 것이 좋습니다. 예를 들어, GPT 5.5와 함께 라우터를 사용하여 중간이나 쉬운 난이도의 요청을 DeepSeek V4 Pro로 라우팅하도록 설정해 구독 한도를 늘릴 수 있습니다. 이 전략은 훨씬 더 저렴할 뿐만 아니라, 매우 어려운 작업에 대한 성능이 떨어지기 때문에 라우팅 결정을 내리기가 훨씬 수월해집니다.

2. 모델 풀(pool)은 작게 유지하세요 이 점은 이전 주장과 이어집니다. 라우팅할 모델 풀의 크기를 늘려서 더 많은 모델을 추가하는 것이 좋다고 생각할 수 있습니다. 예를 들어, role-model을 설정해 GPT 5.5, Kimi 2.7, DeepSeek V4 Pro 및 DeepSeek V4 Flash, 그리고 몇 가지 소규모 GPT 모델까지 사용하도록 구성할 수도 있습니다. 하지만 각 모델이 뚜렷한 특성을 가지고 있지 않다면, 모델을 추가하는 것은 오히려 라우팅 결정을 더욱 어렵게 만들 뿐입니다. 실제로 이 풀은 결국 성능 때문에 GPT 5.5로 라우팅되는 경우가 대부분일 것이고, 캐시가 따뜻해진 상태(워밍업된 상태)를 유지하기 위해 선택된 나머지 하나의 모델만이 소규모 작업에 사용될 가능성이 높습니다. 따라서 명확한 차이를 가진 모델이 아니라면 풀에 추가하지 마세요. 기본적으로 풀 크기를 2개로 제한하고, 각 모델의 역할을 명확하게 정의할 수 있을 때만 모델을 추가하십시오. 모델을 하나 추가했을 때 속도, 품질 또는 비용 중 하나라도 개선되나요? 그렇지 않다면 추가하지 마세요.

3. 상대적이고 실제 환경을 반영한 벤치마크를 사용하세요 때로는 단순히 비용과 같은 모델 메타데이터를 기반으로 라우팅하는 라우터를 보거나, Artificial Analysis와 같은 소스의 외부 벤치마크를 메타데이터에 추가하는 라우터를 봅니다. 이 방식이 아예 안 하는 것보다는 낫지만 이상적이지는 않습니다. 왜냐하면 해당 벤치마크가 성능 프로필을 세밀하게 제공하지 못할 수 있고, 실제 작업 부하를 반영하지 못할 수도 있으며, 엄격하게 상대적이지 않거나 특정 모델에 대한 데이터가 부족할 수 있기 때문입니다. 또한, 모델은 다양한 원격 엔드포인트에서 다르게 수행되고, 시간이 지남에 따라 변경될 수 있으며, 로컬 시스템마다 다르게 작동합니다. 풀 내 모델들의 명확한 프로필 데이터를 얻으려면, 라우터 내에서 직접 벤치마크를 실행하는 것이 가장 좋습니다. 이때 개별 테스트에 기능(도구 사용, 비전 등), 작업 또는 역할 태그를 지정하고, 모델의 성능을 서로 나란히 비교하여 점수를 매기면 훨씬 풍부한 라우팅 프로필을 구축할 수 있습니다.

4. 과거의 기록된 결정을 평가하여 라우팅 결정 데이터를 강화하세요 벤치마크는 시작점으로만 간주되어야 합니다. 우리가 요청을 라우팅할 때 우리의 목표는 어떻게든 미래를 예측하는 것입니다. 즉, 비용과 속도를 포함한 다양한 매개변수가 주어졌을 때 어떤 모델이 이 요청에서 최고의 성능을 낼 것인가를 예측하는 것입니다. 이러한 결정들은 사용자별 맞춤형 설정을 통해 재검토되어야 합니다...

원문 보기
원문 보기 (영어)
Try-Works An index of projects, products, and ideas. Projects & Products rlm-workflow tinytunes DJ lurkkit role-model Pocketmodel Writing recursive-mode for coding agents Why Chinese AI labs went open and will remain open Coding agents and the growing 1% problem role-model: the case for a model routing protocol Contact Email My new Twitter First principles of model routing 2026-07-03 Here are a few principles for model routing that I've developed while building role-model , a model router, a routing protocol and a Pi extension. These principles will be useful for anyone that uses a model router, or builds their own. 1. Keep models distinct I sometimes see people using the latest GPT model with the latest Opus model, each assigned different roles in a coding workflow. This is not wrong per se, but it also isn't optimal from a routing perspective. While people have different experiences of and preferences for the GPT and Opus model, they are both generalist models with a bent for coding, in the same performance and cost tiers. This means that routing between them is difficult, because it is hard enough to determine the difficulty of a request in order to match it with a model, but after this is done it is even harder to make the decision which model it should go to when they are neck and neck in every area. Instead of routing between two frontier models it is better to route between one frontier model and another model that excels in at least one of the sides of the triangle of constraints: speed, quality and cost. For example, use a router together with GPT 5.5 to extend the quota of your subscription by routing medium and easy requests to DeepSeek V4 Pro. It is significantly cheaper and also significantly less capable on very difficult tasks so routing decisions are easier to make here. 2. Keep the model pool small This point follows from the previous point. You might think that increasing the pool size with more models to route between is a good thing. As an example, I could configure role-model to use GPT 5.5, Kimi 2.7, DeepSeek V4 Pro and DeepSeek V4 Flash, and even a couple of smaller GPT models. But if each model does not have distinct characteristics, adding more models just makes routing decision making harder. In reality, this pool is likely to just end up routing between GPT 5.5 due to performance, and one of the other models that is selected and then kept for smaller tasks due to cache being warm. So unless you have models with distinct differences, do not add more to the pool. Limit the pool size to 2 by default and only add more models when you can clearly define the roles of each of them. Does adding one increase speed, quality or cost? If not, don't add it. 3. Use relative, real-world benchmarks I sometimes see some routers that simply route based on model metadata like cost, and other routers that add external benchmarks from sources like Artifical Analysis to the metadata. This is better than nothing but not ideal because the benchmarks may not provide a granular enough performance profile, may not reflect your real workloads, may not be strictly relative and may lack data for certain models. Additionally, models perform differently on different remote endpoints, may change over time, and perform different on different local systems. To get clear data for for the profiles of models in the pool it is best to run benchmarks in your router that runs benchmark with individual test tagged with capabilities (tool use, vision, etc), tasks or roles, then scores the model performance side by side relative to each other to build out a richer routing profile. 4. Evaluate past historic decisions to enrich routing decision data The benchmark should only be seen as a starting point. When we route requests we aim to in a way predict the future: which model will perform optimally on this request given various parameters including cost and speed. These decisions should be revisited by creating user-specific evaluations based on past requests and to run them as a benchmark across the model pool. This is the best signal you get on how models perform and how to route them. Additionally, telemetry data tell us about an endpoint's stability, turn around time for a request, and other things that are not captured in catalog metadata. If you made it all the way here, you can give model routing with your own choice of model a go with role-model. Check out the repo link in the comment below. If you’ve made it this far, you may want to check out role-model and set up your own pool of models for routing: https://github.com/try-works/role-model © Try-Works