Team Ai
Modelpublic

Avirallm/Custom-Knowledge-LLM-Tony-Stark-Edition

sourceHugging Facemitupdated 1y agoView on Hugging Face
1likes15downloads
Model Card

🧠 Custom Knowledge LLM: Tony Stark Edition

[image]

This is a fine-tuned version of the Qwen2.5-3B-Instruct model, adapted to answer domain-specific questions related to Tony Stark, using the LoRA (Low-Rank Adaptation) method for parameter-efficient fine-tuning.


πŸ“Œ Model Details

Model Description

This project is a fun + educational experiment that fine-tunes a base LLM using a fictional dataset based on Tony Stark from the Marvel universe.


πŸ§‘β€πŸ’» Uses

Direct Use

This model is fine-tuned to answer Tony Stark–related prompts such as:

  • β€”"Who is Tony Stark?"
  • β€”"What suits did Iron Man build?"
  • β€”"What are leadership traits of Stark?"

Downstream Use

The methodology can be directly reused for:

  • β€”Corporate knowledge assistants
  • β€”Domain-specific customer support
  • β€”Educational tutors trained on custom material
  • β€”Healthcare, law, and e-commerce Q&A bots

Out-of-Scope Use

This model is not designed for:

  • β€”Real-world advice in medical, legal, or financial domains
  • β€”Factual accuracy outside of Tony Stark lore
  • β€”Handling unrelated general-purpose queries

⚠️ Bias, Risks, and Limitations

  • β€”This model is trained on fictional data and is not meant for serious tasks.
  • β€”It reflects only the content provided in the custom dataset.
  • β€”It may "hallucinate" facts if asked general questions.

Recommendations

Please do not use this for any commercial or factual purpose without re-training on a verified dataset.


πŸš€ How to Use

python
from transformers import pipeline

qa = pipeline(
    model="Avirallm/Custom-Knowledge-LLM-Tony-Stark-Edition",
    tokenizer="Avirallm/Custom-Knowledge-LLM-Tony-Stark-Edition",
    device="cuda"  # or "cpu" if not using GPU
)

qa("List all Iron Man suits and their features.")

πŸ‹οΈβ€β™‚οΈ Training Details

πŸ“¦ Training Data

A custom JSON dataset of prompt-completion pairs related to Tony Stark. Example entry:

~json { "prompt": "Who is Tony Stark?", "completion": "Tony Stark is a fictional billionaire inventor from Marvel..." } ~

πŸ”§ Training Hyperparameters

  • β€”Epochs: 10
  • β€”Batch Size: 1
  • β€”Optimizer: AdamW
  • β€”Learning Rate: 0.001
  • β€”Mixed Precision: FP16
  • β€”Framework: Hugging Face Trainer + PEFT LoRA

πŸ–₯️ Training Setup

  • β€”Trained fully on Google Colab Free Tier
  • β€”Using Qwen/Qwen2.5-3B-Instruct with LoRA adapters
  • β€”Fine-tuned only adapter layers (not full model)

πŸ“Š Evaluation

This project is primarily exploratory and not evaluated on public benchmarks.


🌱 Environmental Impact

  • β€”Hardware: Google Colab Free GPU (Tesla T4)
  • β€”Training Time: ~380 seconds (10 epochs, 1580 steps)
  • β€”Carbon Emission: Negligible (low-compute, single GPU)

🧠 Architecture

  • β€”Base Model: Qwen2.5-3B-Instruct (Alibaba Cloud)
  • β€”Fine-Tuning: LoRA adapters on top of base weights
  • β€”Task Type: Text generation, instruction following
  • β€”Token Limit: 128 tokens (during training)

✨ Example Applications

  • β€”Fan-based AI chatbot (Iron Man Assistant)
  • β€”Fictional universe assistants for games and comics
  • β€”Domain-specific tutors for educational platforms
  • β€”Startup knowledge bots (replace "Tony Stark" with your brand)

πŸ“ Repository Structure

  • β€”adapter_model.safetensors – LoRA adapter weights
  • β€”tokenizer_config.json, tokenizer.json, vocab.json – Tokenizer files
  • β€”README.md – Project overview
  • β€”training_args.bin – Training arguments
  • β€”tonyst.json (optional) – Custom dataset (if shared)

πŸ“¬ Get in Touch

Have a use case in mind? Want your own custom-trained LLM? πŸ“§ Email: sriaviralnarain@gmail.com πŸ”— LinkedIn: Aviral Srivastava πŸ’» GitHub: aviral-sri


πŸ™ Credits

  • β€”Base Model: Qwen2.5-3B-Instruct
  • β€”Fine-Tuning: PEFT + LoRA
  • β€”Tools Used:
  • β€”Hugging Face Transformers
  • β€”Hugging Face Datasets
  • β€”Google Colab
  • β€”W&B for tracking

Inspired by: Marvel's Tony Stark (for learning only, non-commercial)


πŸͺͺ License

This project is licensed under the MIT License. Feel free to modify, share, and build upon it.