Text Generation
Transformers
Safetensors
English
llama
course-assignment
sft
text-generation-inference
Instructions to use centenohugo/SFTChatBot-comp4221 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use centenohugo/SFTChatBot-comp4221 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="centenohugo/SFTChatBot-comp4221")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("centenohugo/SFTChatBot-comp4221") model = AutoModelForCausalLM.from_pretrained("centenohugo/SFTChatBot-comp4221", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use centenohugo/SFTChatBot-comp4221 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "centenohugo/SFTChatBot-comp4221" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "centenohugo/SFTChatBot-comp4221", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/centenohugo/SFTChatBot-comp4221
- SGLang
How to use centenohugo/SFTChatBot-comp4221 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "centenohugo/SFTChatBot-comp4221" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "centenohugo/SFTChatBot-comp4221", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "centenohugo/SFTChatBot-comp4221" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "centenohugo/SFTChatBot-comp4221", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use centenohugo/SFTChatBot-comp4221 with Docker Model Runner:
docker model run hf.co/centenohugo/SFTChatBot-comp4221
Download run_config.json from centenohugo/SFTChatBot-comp4221: direct link, hf CLI and curl.
- Browser
- Download file 719 Bytes
-
https://huggingface.co/centenohugo/SFTChatBot-comp4221/resolve/main/run_config.json
- Command line
-
hf download hf://centenohugo/SFTChatBot-comp4221/run_config.json
-
curl -L -o run_config.json https://huggingface.co/centenohugo/SFTChatBot-comp4221/resolve/main/run_config.json
719 Bytes
| { | |
| "model": "HuggingFaceTB/SmolLM2-135M", | |
| "seed": 4221, | |
| "device": "cuda", | |
| "hardware": "NVIDIA GeForce RTX 4090 D", | |
| "steps": 100, | |
| "completed_steps": 100, | |
| "raw_training_examples": 300, | |
| "usable_training_examples": 300, | |
| "sequence_length": 256, | |
| "effective_batch_size": 8, | |
| "micro_batch_size": 1, | |
| "learning_rate": 2e-05, | |
| "epsilon": 0.1, | |
| "torch_version": "2.8.0+cu128", | |
| "transformers_version": "4.57.6", | |
| "training_data_sha256": "abe6b2efa12d14a280bc44b2d8b7642aaf09dfe65ad1a766327023bb2cb62ee1", | |
| "student_tasks_sha256": "0dd3cfb63ac0e0fc22a16965a1e75d5534f439bf171adc514a52553984b1536c", | |
| "elapsed_training_seconds": 112.60666490718722, | |
| "final_checkpoint_saved": true | |
| } | |