ml-sensei-chat / README.md
mackenzietechdocs's picture
readme
330050a

A newer version of the Gradio SDK is available: 6.1.0

Upgrade
metadata
title: Ml Sensei Chat
emoji: πŸ“ˆ
colorFrom: red
colorTo: yellow
sdk: gradio
sdk_version: 6.0.2
app_file: app.py
pinned: false
license: mit
short_description: A place to chat to an ML training LoRA of TinyLlama.

πŸ₯‹ ML Sensei β€” TinyLlama LoRA Chat

A lightweight interactive tutor for machine learning concepts.

Welcome to ML Sensei, a fine-tuned TinyLlama model designed to teach machine learning concepts with clarity, intuition, and gentleness.

This Space provides an interactive chat interface where you can ask ML Sensei questions about:

  • Machine Learning
  • Deep Learning
  • Neural networks
  • Optimization
  • Training loops
  • Data science fundamentals
  • Applied concepts and intuition

ML Sensei uses a LoRA adapter fine-tuned on a custom instruction dataset built from curated ML texts, chunk-based self-generated Q&A, intuitive breakdowns, and code-ready explanations.


🧠 Model Details

Base Model:
TinyLlama/TinyLlama-1.1B-Chat-v1.0

LoRA Adapter:
mackenzietechdocs/ml-sensei-lora-tinyllama-1.1b

Architecture:

  • Decoder-only Transformer
  • Chat-tuned
  • LoRA-adapted for ML instruction

🧩 What ML Sensei Can Do

ML Sensei specializes in:

βœ” Beginner-friendly explanations

Breaks down ML ideas into approachable, intuitive pieces.

βœ” Simple analogies + concept-first teaching

Uses everyday intuition instead of heavy math when possible.

βœ” Helpful follow-up questions

Ask more and ML Sensei will guide you deeper step-by-step.

βœ” Code examples on request

Provides PyTorch or pseudocode snippets when helpful.

βœ” Checking your understanding

Ask ML Sensei to quiz you on a topic!


▢️ How to Use This Space

Just type a question into the chat box:

Example prompts:

  • β€œExplain gradient descent simply.”
  • β€œWhat is weight decay?”
  • β€œHow does cross-entropy work conceptually?”
  • β€œCan you quiz me on neural networks?”
  • β€œWrite a small PyTorch example showing a training loop.”

ML Sensei will respond with high-quality educational text aimed at clarity and intuition.


βš™οΈ Technical Details

This app loads:

  1. The TinyLlama 1.1B Chat model
  2. The ML Sensei LoRA adapter via PEFT
  3. A Gradio chat interface for interactive conversation
  4. TinyLlama’s official chat template for structured inputs

The LoRA adds:

  • Improved conceptual explanations
  • Beginner-friendly language
  • Educational reasoning patterns
  • Stepwise breakdowns
  • Vocabulary simplification

The underlying LLM remains safe, stable, and compact enough to run on CPU.


πŸ“¦ Environment & Requirements

The Space installs:

transformers
peft
gradio
accelerate
torch
sentencepiece

Inference runs on CPU unless upgraded to GPU.


πŸ“œ License

  • Base model license: TinyLlama License
  • LoRA adapter license: Apache 2.0
  • Dataset used: Fully model-generated instructional text

Users must comply with the base model license.


πŸ›‘ Safety

ML Sensei is designed for educational purposes only.
It is not a certified resource for:

  • Academic evaluation
  • Recruitment / hiring
  • Safety-critical decision making

Please report issues via β€œCommunity” tab.


🀝 Contributing

If you'd like to extend ML Sensei with:

  • More curriculum topics
  • More examples
  • Better reasoning chains
  • Additional Q&A datasets

Feel free to open a PR or connect with me on GitHub or Hugging Face!


✨ Philosophy

Machine learning becomes easier when taught patiently and simply.

ML Sensei exists to make ML concepts less intimidating β€” and to help more learners enter the AI field confidently.

Enjoy chatting with your tutor, and may your gradients always descend! πŸ§˜β€β™€οΈπŸ“‰