Text Generation
Transformers
Safetensors
qwen2
conversational
Eval Results (legacy)
Eval Results
text-generation-inference
Instructions to use FlameF0X/Qwen2-0.2B-it with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use FlameF0X/Qwen2-0.2B-it with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="FlameF0X/Qwen2-0.2B-it") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("FlameF0X/Qwen2-0.2B-it") model = AutoModelForCausalLM.from_pretrained("FlameF0X/Qwen2-0.2B-it") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use FlameF0X/Qwen2-0.2B-it with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "FlameF0X/Qwen2-0.2B-it" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "FlameF0X/Qwen2-0.2B-it", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/FlameF0X/Qwen2-0.2B-it
- SGLang
How to use FlameF0X/Qwen2-0.2B-it 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 "FlameF0X/Qwen2-0.2B-it" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "FlameF0X/Qwen2-0.2B-it", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "FlameF0X/Qwen2-0.2B-it" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "FlameF0X/Qwen2-0.2B-it", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use FlameF0X/Qwen2-0.2B-it with Docker Model Runner:
docker model run hf.co/FlameF0X/Qwen2-0.2B-it
Update README.md
Browse files
README.md
CHANGED
|
@@ -15,7 +15,45 @@ datasets:
|
|
| 15 |
- microsoft/orca-math-word-problems-200k
|
| 16 |
- laion/OIG
|
| 17 |
- microsoft/wiki_qa
|
| 18 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
---
|
| 20 |
|
| 21 |
## Evaluation Results
|
|
|
|
| 15 |
- microsoft/orca-math-word-problems-200k
|
| 16 |
- laion/OIG
|
| 17 |
- microsoft/wiki_qa
|
| 18 |
+
metrics:
|
| 19 |
+
- accuracy
|
| 20 |
+
model-index:
|
| 21 |
+
- name: FlameF0X/Qwen2-0.2B-it
|
| 22 |
+
results:
|
| 23 |
+
- task:
|
| 24 |
+
type: text-generation
|
| 25 |
+
name: Text Generation
|
| 26 |
+
dataset:
|
| 27 |
+
id: openai/gsm8k
|
| 28 |
+
name: GSM8K
|
| 29 |
+
type: gsm8k
|
| 30 |
+
config: main
|
| 31 |
+
split: test
|
| 32 |
+
metrics:
|
| 33 |
+
- name: Accuracy
|
| 34 |
+
type: accuracy
|
| 35 |
+
value: 2.00
|
| 36 |
+
verified: false
|
| 37 |
+
source:
|
| 38 |
+
name: Local Benchmark
|
| 39 |
+
url: https://huggingface.co/FlameF0X/Qwen2-0.2B-it
|
| 40 |
+
- task:
|
| 41 |
+
type: text-generation
|
| 42 |
+
name: Text Generation
|
| 43 |
+
dataset:
|
| 44 |
+
id: TIGER-Lab/MMLU-Pro
|
| 45 |
+
name: MMLU-Pro
|
| 46 |
+
type: TIGER-Lab/MMLU-Pro
|
| 47 |
+
config: default
|
| 48 |
+
split: test
|
| 49 |
+
metrics:
|
| 50 |
+
- name: Accuracy
|
| 51 |
+
type: accuracy
|
| 52 |
+
value: 4.00
|
| 53 |
+
verified: false
|
| 54 |
+
source:
|
| 55 |
+
name: Local Benchmark
|
| 56 |
+
url: https://huggingface.co/FlameF0X/Qwen2-0.2B-it
|
| 57 |
---
|
| 58 |
|
| 59 |
## Evaluation Results
|