post: commit a8a32ef in myai
Some checks failed
Hugo Build & Deploy / build-deploy (push) Has been cancelled

This commit is contained in:
Betty
2026-08-11 17:30:58 +02:00
parent a75b09d105
commit 971371e701

View File

@@ -0,0 +1,50 @@
---
title: "[myai] feat(myai): add POST /generate via StarCoder2-3B (GPU)"
date: 2026-08-11T17:30:58+02:00
draft: false
tags: ["commit", "myai", "main"]
categories: ["Git Activity"]
summary: "Commit a8a32ef par Betty dans myai"
author: "Betty"
---
## Commit `a8a32ef`
| | |
|---|---|
| **Repository** | myai |
| **Branch** | `main` |
| **Author** | Betty |
| **Hash** | `a8a32ef01bfe78e041b3ea636d354300dc751063` |
### Description
- New app/codegen.py: loads bigcode/starcoder2-3b at startup via HuggingFace
- POST /generate endpoint: prompt + language → generated code
- Dockerfile: switch to pytorch/pytorch:2.2.0-cuda12.1-cudnn8-runtime base
- requirements.txt: add transformers<5.0 + accelerate
- stack/myai.yml: GPU placement (nvidia.vgpu), VRAM/CPU limits, hf-cache volume
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
### Files Changed
```
M Dockerfile
A app/codegen.py
M app/main.py
M requirements.txt
M stack/myai.yml
```
### Diff Summary
```
Dockerfile | 6 ++++--
app/codegen.py | 46 ++++++++++++++++++++++++++++++++++++++++++++++
app/main.py | 24 ++++++++++++++++++++++++
requirements.txt | 2 ++
stack/myai.yml | 20 ++++++++++++++++++--
5 files changed, 94 insertions(+), 4 deletions(-)
```