KarthikNA/Model-Router ? reverse-engineered prompt
Reverse engineered prompt
Build me a small Python tool that routes a user prompt to the best language model without making any API calls.
I want it to look at the text of the prompt, estimate things like task type, language, rough length, and whether it seems like code, math, summarization, or long context, then pick the cheapest model that still seems capable enough. It should balance cost, speed, task fit, and model strength, and fall back to a safe default if nothing fits.
Please include a simple model registry with a few built in model profiles, a router that returns the chosen model plus a short explanation and some basic diagnostics, and a demo script that shows it working on a handful of sample prompts. Also add a small evaluation script that can score correctness, latency, and cost on a labeled test set, all offline. Keep it lightweight, fast, and easy to extend with new models later.
Are you gonna build this?
make sure you review the code using coderabbit