Text Generation
Transformers
Safetensors
qwen2
trl
sft
text-generation-inference
4-bit precision
bitsandbytes
Instructions to use Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7") model = AutoModelForCausalLM.from_pretrained("Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7
- SGLang
How to use Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7 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 "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7" \ --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": "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7", "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 "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7" \ --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": "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7 with Docker Model Runner:
docker model run hf.co/Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7
Upload Qwen2ForCausalLM
Browse files- config.json +32 -3
- generation_config.json +1 -2
- model-00001-of-00002.safetensors +1 -1
- model.safetensors.index.json +1 -0
config.json
CHANGED
|
@@ -1,14 +1,44 @@
|
|
| 1 |
{
|
| 2 |
-
"_name_or_path": "Sefika/CRE_fewrel_qwen_10_3_task_memory_10_7",
|
| 3 |
"architectures": [
|
| 4 |
"Qwen2ForCausalLM"
|
| 5 |
],
|
| 6 |
"attention_dropout": 0.0,
|
|
|
|
| 7 |
"eos_token_id": 151645,
|
| 8 |
"hidden_act": "silu",
|
| 9 |
"hidden_size": 3584,
|
| 10 |
"initializer_range": 0.02,
|
| 11 |
"intermediate_size": 18944,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
"max_position_embeddings": 32768,
|
| 13 |
"max_window_layers": 28,
|
| 14 |
"model_type": "qwen2",
|
|
@@ -37,8 +67,7 @@
|
|
| 37 |
"rope_theta": 1000000.0,
|
| 38 |
"sliding_window": null,
|
| 39 |
"tie_word_embeddings": false,
|
| 40 |
-
"
|
| 41 |
-
"transformers_version": "4.45.2",
|
| 42 |
"use_cache": false,
|
| 43 |
"use_sliding_window": false,
|
| 44 |
"vocab_size": 152064
|
|
|
|
| 1 |
{
|
|
|
|
| 2 |
"architectures": [
|
| 3 |
"Qwen2ForCausalLM"
|
| 4 |
],
|
| 5 |
"attention_dropout": 0.0,
|
| 6 |
+
"dtype": "float16",
|
| 7 |
"eos_token_id": 151645,
|
| 8 |
"hidden_act": "silu",
|
| 9 |
"hidden_size": 3584,
|
| 10 |
"initializer_range": 0.02,
|
| 11 |
"intermediate_size": 18944,
|
| 12 |
+
"layer_types": [
|
| 13 |
+
"full_attention",
|
| 14 |
+
"full_attention",
|
| 15 |
+
"full_attention",
|
| 16 |
+
"full_attention",
|
| 17 |
+
"full_attention",
|
| 18 |
+
"full_attention",
|
| 19 |
+
"full_attention",
|
| 20 |
+
"full_attention",
|
| 21 |
+
"full_attention",
|
| 22 |
+
"full_attention",
|
| 23 |
+
"full_attention",
|
| 24 |
+
"full_attention",
|
| 25 |
+
"full_attention",
|
| 26 |
+
"full_attention",
|
| 27 |
+
"full_attention",
|
| 28 |
+
"full_attention",
|
| 29 |
+
"full_attention",
|
| 30 |
+
"full_attention",
|
| 31 |
+
"full_attention",
|
| 32 |
+
"full_attention",
|
| 33 |
+
"full_attention",
|
| 34 |
+
"full_attention",
|
| 35 |
+
"full_attention",
|
| 36 |
+
"full_attention",
|
| 37 |
+
"full_attention",
|
| 38 |
+
"full_attention",
|
| 39 |
+
"full_attention",
|
| 40 |
+
"full_attention"
|
| 41 |
+
],
|
| 42 |
"max_position_embeddings": 32768,
|
| 43 |
"max_window_layers": 28,
|
| 44 |
"model_type": "qwen2",
|
|
|
|
| 67 |
"rope_theta": 1000000.0,
|
| 68 |
"sliding_window": null,
|
| 69 |
"tie_word_embeddings": false,
|
| 70 |
+
"transformers_version": "4.56.1",
|
|
|
|
| 71 |
"use_cache": false,
|
| 72 |
"use_sliding_window": false,
|
| 73 |
"vocab_size": 152064
|
generation_config.json
CHANGED
|
@@ -1,5 +1,4 @@
|
|
| 1 |
{
|
| 2 |
-
"bos_token_id": 151643,
|
| 3 |
"do_sample": true,
|
| 4 |
"eos_token_id": [
|
| 5 |
151645,
|
|
@@ -10,5 +9,5 @@
|
|
| 10 |
"temperature": 0.7,
|
| 11 |
"top_k": 20,
|
| 12 |
"top_p": 0.8,
|
| 13 |
-
"transformers_version": "4.
|
| 14 |
}
|
|
|
|
| 1 |
{
|
|
|
|
| 2 |
"do_sample": true,
|
| 3 |
"eos_token_id": [
|
| 4 |
151645,
|
|
|
|
| 9 |
"temperature": 0.7,
|
| 10 |
"top_k": 20,
|
| 11 |
"top_p": 0.8,
|
| 12 |
+
"transformers_version": "4.56.1"
|
| 13 |
}
|
model-00001-of-00002.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4761275200
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:82381909fc6613034591de18013608480d5689783ed98603e11889669b869826
|
| 3 |
size 4761275200
|
model.safetensors.index.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
| 1 |
{
|
| 2 |
"metadata": {
|
|
|
|
| 3 |
"total_size": 5851159328
|
| 4 |
},
|
| 5 |
"weight_map": {
|
|
|
|
| 1 |
{
|
| 2 |
"metadata": {
|
| 3 |
+
"total_parameters": 7615616512,
|
| 4 |
"total_size": 5851159328
|
| 5 |
},
|
| 6 |
"weight_map": {
|