Skip to content

lucas-ht-hackathon/model-station

Repository files navigation

ModelStation — SLM Fine-tuning Platform (Simple Overview)

Short summary

  • ModelStation turns user requirements into a compact, high-quality SLM (small tail model) by:
    1. Capturing a user query / intent,
    2. Distilling that intent against a large dataset to produce a focused custom dataset,
    3. Fine-tuning a base SLM on that distilled dataset,
    4. Producing a small, deployable model tailored to the customer's needs.

Architecture & components

High-level flow (user-friendly)

  1. User submits a request to create a custom model via the web UI.
  2. API creates a model record (status: "pending") and enqueues a training job.
  3. Semantic distillation
    • The semantic-split service queries Weaviate for examples matching the user's intent (DatasetGenerator), filters/structures rows, then optionally pushes a curated dataset to Hugging Face. See DatasetGenerator and scripts/semantic_split/main.py.
  4. Embedding & seeding (if needed)
  5. Fine-tuning
  6. Deployment & use
    • The resulting model (small tail model) is saved and can be used for inference in any project/team. The platform maintains model metadata in the API database and exposes endpoints to list/delete models. See api/app/controllers/models/routes.py.

Why this approach?

  • Distillation: selecting a focused subset of the big dataset aligns training examples with the customer's policy, objective, and distribution — producing a compact dataset that yields an efficient "tail" model.
  • Small tail model: fine-tuning a small SLM on the distilled dataset produces a lightweight model that preserves desired behavior while being cheaper and faster to serve.

Developer quickstart (local)

  • The repo includes Docker Compose files to run services:
  • Typical steps:
    1. Configure environment variables (do not commit secrets).
    2. Start services with Docker Compose (use the dev compose for local testing).
    3. Use the frontend to create a model or call API endpoints directly.
    4. Monitor logs for the semantic split, embedding, and trainer services.

Key endpoints & symbols

Notes & next steps

  • Secrets: keep API keys and tokens out of version control (use environment variables).
  • Training orchestration: currently the API enqueues training entries; integrate a job-worker or pod orchestration to run the trainer and report progress back to the API.
  • Metrics & QA: add evaluation suites and logging during training to validate model behavior against the customer's success criteria.

License & contribution

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 2

  •  
  •