NHacker Next
  • new
  • past
  • show
  • ask
  • show
  • jobs
  • submit
▲Serving Qwen via AWS Lambdas for fun and 80x negative profit (noahbuilt.it)
iknownothow 39 minutes ago [-]
Keep in mind that AWS Lambda has different performance characteristics based on how much memory you provide it.

1. For example a 10GB instance may have access to 6-ish cores. Also lambda instances under 1.3GB tend to have slower cores. [1].

2. There's the new aws managed lambda instances that can allow 32GB and 16vCPU instances [2]

3. Larger lambdas tend to have more network bandwidth so may be downloading layers from S3 might be faster [3]

Do you think it would make sense to stuff two or more layers into a larger lambda instances given that there's multiple cores and more memory available? I wouldn't be surprised if some optimizations would lead to only 20x negative profit :)

[1] https://aws.amazon.com/blogs/compute/optimizing-compute-inte...

[2] https://aws.amazon.com/about-aws/whats-new/2026/03/lambda-32...

[3] https://aws.amazon.com/blogs/compute/improving-lambda-functi...

catlifeonmars 8 hours ago [-]
I’m sure it’s still quite expensive but lambda can now access GPU instances via managed instances. I’d like to see the same thing implemented on some beefier GPU compute.

https://docs.aws.amazon.com/lambda/latest/dg/lambda-managed-...

alex_duf 3 hours ago [-]
Reading this, it's almost what I need, but not quite.

Why do I have to worry about it provisioning GPU instances in my account? That kinda breaks the mental model of lambdas. It feels like a billing constraint turned into a technical constraint. Then you wonder how well is it going to scale up and down to follow the load I'm giving it, which is supposed to be their problem to worry about, not mine.

octember 8 hours ago [-]
God damn it, nerd sniped again. ill be back
geophph 7 hours ago [-]
Hell yeah
cebert 8 hours ago [-]
I love it when folks experiment and try random approaches like this to see if it would even work.
octember 8 hours ago [-]
LOL thank you. Learn by doing
enjoyyourlife 5 hours ago [-]
Needs to try Cloudflare Workers next
iknownothow 1 hours ago [-]
> splitting a model call across 5,600 Lambdas is kinda wild.

100% wild! Absolutely amazing idea and implementation! The advantage (theorectical) I see with this approach is that you can run an abritrarily large open model yourself using this approach without having access to a large machine or GPU*.

* When cost, speed and practicality are of no concern :D

Do you know if a diffusion model lends itself better to this approach? Since token generation may not be serial?

hizlikovboy27 5 hours ago [-]
I love this madness. Its serves as an answer to that "what if?" question you have been harboring all this time. Im looking forward to seeing your new experiments with AWS Lambda documentation :)
janalsncm 7 hours ago [-]
Hey that’s pretty impressive even if it’s not economical.

First thing that came to mind is that you’re using a 4B model. If you can get away with something half the size, I think the numbers will be more favorable.

In order to do that you need an eval set, which you’ll want anyways if you care whether Jev or Open AI decisions or Gemini decisions are best for your problem.

Another thing is, you’ll probably be crushed on cold start unless you deliberately keep your lambdas warm.

octember 7 hours ago [-]
All good points! I did pick somewhat randomly - would be interesting to sweep. But at least in 2026 it doesn't seem like these smaller models are holding up. Maybe there is a sweet spot but I'm skeptical

For the eval set I took a sample from here: https://stanfordnlp.github.io/contract-nli/

If it's done right, answers are 100% identical so it's easy to verify you didn't break it

And yeah I kept them warm, pinging every function every 4 minutes

hawaiih1 55 minutes ago [-]
[flagged]
jdw64 8 hours ago [-]
>I need a GPU Who wouldn’t need a GPU? We all need one.
kooyu 3 hours ago [-]
[flagged]
Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact
Rendered at 12:21:57 GMT+0000 (Coordinated Universal Time) with Vercel.