Dwrko-M1.0 / QUICKSTART.md
rajatsainisim's picture
πŸš€ Complete Dwrko-M1.0 setup with HuggingFace upload tools
68afbf1
|
raw
history blame
3.88 kB

πŸš€ Dwrko-M1.0 Quick Start Guide

Get your Claude-like AI assistant running in minutes!

⚑ 5-Minute Setup

1. Install Dependencies

pip install -r requirements.txt

2. Launch Web Interface

python app.py

Open http://localhost:7860 in your browser

3. Start Training

# Quick training with sample data
python train.py --data sample_data.jsonl --epochs 3 --output_dir ./my-dwrko-m1.0

# Monitor with wandb
python train.py --data sample_data.jsonl --use_wandb --project_name "my-dwrko"

4. Test Your Model

# Run test suite
python test_dwrko.py --model_path ./my-dwrko-m1.0 --test_suite

# Interactive chat
python test_dwrko.py --model_path ./my-dwrko-m1.0 --interactive

5. πŸš€ Upload to HuggingFace

# Super easy one-click upload!
./quick_upload.sh

# Or manual upload
python upload_to_hf.py --model_path ./my-dwrko-m1.0 --username YOUR_USERNAME

🎯 Training Commands

Basic Training

python train.py --data sample_data.jsonl

Advanced Training

python train.py \
  --data your_data.jsonl \
  --epochs 5 \
  --lr 2e-4 \
  --batch_size 1 \
  --grad_steps 8 \
  --output_dir ./dwrko-m1.0 \
  --use_wandb \
  --project_name "dwrko-training"

Memory-Optimized Training (for 16GB RAM)

python train.py \
  --data your_data.jsonl \
  --batch_size 1 \
  --grad_steps 4 \
  --max_length 256

πŸ“Š Testing Commands

Full Test Suite

python test_dwrko.py --model_path ./dwrko-m1.0 --test_suite

Single Test

python test_dwrko.py --model_path ./dwrko-m1.0 --single_test "Write a Python function to sort a list"

Interactive Chat

python test_dwrko.py --model_path ./dwrko-m1.0 --interactive

6. 🌐 HuggingFace Upload Commands

Quick Upload (Automated)

# One-click upload script
./quick_upload.sh

Manual Upload

# Python script
python upload_to_hf.py \
  --model_path ./dwrko-m1.0 \
  --username YOUR_USERNAME \
  --repo_name Dwrko-M1.0

# CLI method
huggingface-cli login
huggingface-cli upload ./dwrko-m1.0 YOUR_USERNAME/Dwrko-M1.0 --repo-type model

Private Repository

python upload_to_hf.py \
  --model_path ./dwrko-m1.0 \
  --username YOUR_USERNAME \
  --repo_name Dwrko-M1.0 \
  --private

πŸ“š Data Format

Your training data should be in JSONL format:

{"text": "### Instruction: Your question here\n### Response: Your answer here"}
{"text": "### Instruction: Another question\n### Response: Another answer"}

πŸ”§ Troubleshooting

Out of Memory?

# Reduce batch size
python train.py --batch_size 1 --grad_steps 4

# Reduce sequence length
python train.py --max_length 256

Training Too Slow?

# Enable optimizations
python train.py --fp16 True --gradient_checkpointing True

Model Not Loading?

# Clear GPU cache
python -c "import torch; torch.cuda.empty_cache()"

HuggingFace Upload Issues?

# Setup virtual environment
python3 -m venv dwrko_env
source dwrko_env/bin/activate
pip install huggingface_hub

# Re-login
huggingface-cli login

# Check files
ls -la ./dwrko-m1.0/

🌟 Next Steps

  1. Upload to HuggingFace: ./quick_upload.sh ΰ€―ΰ€Ύ python upload_to_hf.py
  2. Share with Community: Post your results and get feedback
  3. Improve Training: Add more data and train longer
  4. Deploy: Use your model in production applications

πŸ’‘ Pro Tips

  • Start with sample_data.jsonl to test everything works
  • Use wandb to monitor training progress
  • Save checkpoints frequently during long training runs
  • Test your model on diverse tasks to ensure quality
  • Upload to HuggingFace to share with the world! 🌍
  • Join our community for support and tips!

🎯 Ready to create your Claude-like assistant? Let's go! πŸš€