From 9987c9d176fa6cbef05cc45669f6ddaa684d218d Mon Sep 17 00:00:00 2001 From: Cherrytest Date: Wed, 5 Mar 2025 17:26:36 +0000 Subject: [PATCH] Update README.md --- README.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 3982fe0..ddddcfe 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ tags: ## Introduction -QwQ is the reasoning model of Qwen series. Compared with conventional instruction-tuned models QwQ which is capable of thinking and reasoning can achieve significantly enhanced performance in downstream tasks espeically hard problems. QwQ-32B is the medium-size reasoning model, which is capable of achieving competitive performance against state-of-the art reasoning models, e.g., DeepSeek-R1, o1-mini. +QwQ is the reasoning model of the Qwen series. Compared with conventional instruction-tuned models, QwQ, which is capable of thinking and reasoning, can achieve significantly enhanced performance in downstream tasks, especially hard problems. QwQ-32B is the medium-sized reasoning model, which is capable of achieving competitive performance against state-of-the-art reasoning models, e.g., DeepSeek-R1, o1-mini. **This repo contains the QwQ 32B model**, which has the following features: - Type: Causal Language Models @@ -68,10 +68,6 @@ text = tokenizer.apply_chat_template( add_generation_prompt=True ) -# avoid empty thought content by forcing the model to start with "\n" -response_prefix = "\n" -text += response_prefix - model_inputs = tokenizer([text], return_tensors="pt").to(model.device) generated_ids = model.generate( @@ -83,14 +79,14 @@ generated_ids = [ ] response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0] -print(response_prefix + response) +print(response) ``` ### Usage Guidelines To achieve optimal performance, we recommend the following settings: -1. **Enforce Thoughtful Output**: Ensure the model starts with "\\n" to prevent generating empty thinking content, which can degrade output quality. +1. **Enforce Thoughtful Output**: Ensure the model starts with "\\n" to prevent generating empty thinking content, which can degrade output quality. If you use `apply_chat_template` and set `add_generation_prompt=True`, this is already automatically implemented, but it may cause the response to lack the \ tag at the beginning. This is normal behavior. 2. **Sampling Parameters**: - Use Temperature=0.6 and TopP=0.95 instead of Greedy decoding to avoid endless repetitions and enhance diversity.