Reverse proxy for LLMs which can wake and/or shut-down your inference server in response to incoming requests

Wait 5 sec.

Probably not very original, but a little project I put together so I can save some power and don't have to manually wake my LLM box when I want to do something with it (or shut it down when I'm done). Mostly just put it together as a test for local model based vibe-coding (almost nothing in this repo was written by hand so ymmv), but it ended up being good enough to be useful, so I thought I'd share it. It sits between your clients (openwebui/coding harness etc) and wakes the machine before forwarding requests. If no requests have come in for a while, it shuts the machine back down. It also caches the `/v1/models` endpoint, so if you're using openwebui or something else that which hits that endpoint frequently, it won't constantly wake the machine up. It's also got an option for a command to check for logged in users, which you can configure to stop it shutting down the machine down while you're doing something with it. I wouldn't say it's "good" code by any stretch of the imagination, but it's not bad for something that practically coded itself while I was off doing other things, and it seems reliable so far. Like all vibe-code though, ymmv. Happy to accept suggestions and/or PRs.   submitted by   /u/ac101m [link]   [comments]