prithivMLmods commited on
Commit
cbf336e
·
verified ·
1 Parent(s): 4822045

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +86 -1
README.md CHANGED
@@ -10,4 +10,89 @@ tags:
10
  - CoT
11
  - Convsersational
12
  - text-generation-inference
13
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  - CoT
11
  - Convsersational
12
  - text-generation-inference
13
+ ---
14
+
15
+ # **QwQ-LCoT-14B-Conversational**
16
+
17
+ QwQ-LCoT-14B-Conversational is based on the Qwen 2.5 14B Instruct model, fine-tuned for chain-of-thought-based long conversational contexts. It is designed to excel in providing detailed explanations and reasoning, making it versatile for various complex use cases.
18
+
19
+ ## Key Features
20
+
21
+ ### Enhanced Knowledge and Capabilities
22
+ - **Coding and Mathematics**: Significantly improved performance in coding and mathematical tasks, thanks to specialized expert models in these domains.
23
+
24
+ ### Advanced Instruction Following
25
+ - **Instruction Following**: Enhanced ability to follow instructions accurately, even for complex tasks.
26
+ - **Long Text Generation**: Capable of generating long texts exceeding 8,000 tokens.
27
+ - **Structured Data Understanding**: Improved understanding of structured data such as tables.
28
+ - **JSON Generation**: Exceptional ability to generate structured outputs, including JSON.
29
+
30
+ ### Resilient and Versatile
31
+ - **Prompt Diversity**: Greater resilience to diverse system prompts, enhancing role-play scenarios and condition-setting for chatbots.
32
+
33
+ ### Long-Context Support
34
+ - **Context Length**: Supports up to 128,000 tokens, with the ability to generate up to 8,000 tokens in a single response.
35
+
36
+ ## Quickstart
37
+
38
+ Here provides a code snippet with `apply_chat_template` to show you how to load the tokenizer and model and how to generate contents.
39
+
40
+ ```python
41
+ from transformers import AutoModelForCausalLM, AutoTokenizer
42
+
43
+ model_name = "Qwen/Qwen2.5-14B-Instruct"
44
+
45
+ model = AutoModelForCausalLM.from_pretrained(
46
+ model_name,
47
+ torch_dtype="auto",
48
+ device_map="auto"
49
+ )
50
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
51
+
52
+ prompt = "Give me a short introduction to large language model."
53
+ messages = [
54
+ {"role": "system", "content": "You are Qwen, created by Alibaba Cloud. You are a helpful assistant."},
55
+ {"role": "user", "content": prompt}
56
+ ]
57
+ text = tokenizer.apply_chat_template(
58
+ messages,
59
+ tokenize=False,
60
+ add_generation_prompt=True
61
+ )
62
+ model_inputs = tokenizer([text], return_tensors="pt").to(model.device)
63
+
64
+ generated_ids = model.generate(
65
+ **model_inputs,
66
+ max_new_tokens=512
67
+ )
68
+ generated_ids = [
69
+ output_ids[len(input_ids):] for input_ids, output_ids in zip(model_inputs.input_ids, generated_ids)
70
+ ]
71
+
72
+ response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]
73
+ ```
74
+ ### Multilingual Support
75
+ - **Languages Supported**: Offers multilingual support for over 29 languages, including:
76
+ - Chinese
77
+ - English
78
+ - French
79
+ - Spanish
80
+ - Portuguese
81
+ - German
82
+ - Italian
83
+ - Russian
84
+ - Japanese
85
+ - Korean
86
+ - Vietnamese
87
+ - Thai
88
+ - Arabic
89
+ - And more
90
+
91
+ ## Applications
92
+
93
+ QwQ-LCoT-14B-Conversational is ideal for:
94
+ - Long-form conversational AI
95
+ - Complex reasoning and chain-of-thought explanations
96
+ - Multilingual communication
97
+ - Structured data generation and processing
98
+ - Enhanced role-play and chatbot implementation