Spaces:
Running
Running
File size: 1,186 Bytes
aaffe29 d6083a7 aaffe29 d6083a7 aaffe29 d6083a7 1830a59 d6083a7 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | ---
title: MyVillage Project Creation API
emoji: 🎓
colorFrom: blue
colorTo: purple
sdk: docker
app_port: 7860
models:
- mjpsm/project-creation-qwen2.5-1.5b-sft-v1
---
# MyVillage Project Creation API
A CPU-friendly (though potentially slow) FastAPI endpoint for the fine-tuned
MyVillage project-creation model. **Upload the merged model to Hugging Face first.**
The model repository `mjpsm/project-creation-qwen2.5-1.5b-sft-v1` must be publicly accessible, or supply
`HF_TOKEN` as a Space secret for a private repository.
POST `/predict` with JSON:
```json
{"prompt": "Create a robotics project for middle school students", "max_new_tokens": 650, "temperature": 0.7}
```
Returns `title`, `description`, and `model`.
Browse `/docs` for interactive OpenAPI documentation, `/health` for readiness.
## Operational notes
* Free CPU Basic has limited throughput. Try CPU Upgrade / GPU or a 0.5B model for faster responses.
* The request can take long for ~250-word descriptions; test with realistic prompts.
* A public Space exposes a public endpoint. Add authentication/rate limiting before production use.
* Set `MODEL_ID` in Space Variables if you change the model repository.
|