quantumaikr commited on
Commit
09cbfe6
1 Parent(s): ae58af3

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +57 -2
README.md CHANGED
@@ -1,3 +1,58 @@
1
  ---
2
- license: cc
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ license: cc-by-nc-4.0
3
+ language:
4
+ - en
5
+ pipeline_tag: text-generation
6
+ ---
7
+
8
+ # quantumaikr/quantum-dpo-v0.1
9
+
10
+ ## Usage
11
+
12
+ Start chatting with `quantumaikr/quantum-dpo-v0.1` using the following code snippet:
13
+
14
+ ```python
15
+ import torch
16
+ from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
17
+
18
+ tokenizer = AutoTokenizer.from_pretrained("quantumaikr/quantum-dpo-v0.1")
19
+ model = AutoModelForCausalLM.from_pretrained("quantumaikr/quantum-dpo-v0.1", torch_dtype=torch.float16, device_map="auto")
20
+
21
+ system_prompt = "You are QuantumLM, an AI that follows instructions extremely well. Help as much as you can. Remember, be safe, and don't do anything illegal."
22
+
23
+ message = "Write me a poem please"
24
+ prompt = f"[INST] <<SYS>>\n{system_prompt}\n<</SYS>>\n\n{message}[/INST]"
25
+ inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
26
+ output = model.generate(**inputs, do_sample=True, temperature=0.7, top_p=0.95, top_k=30, max_new_tokens=2048)
27
+
28
+ print(tokenizer.decode(output[0], skip_special_tokens=True))
29
+ ```
30
+
31
+ QuantumLM should be used with this prompt format:
32
+ ```
33
+ ### System:
34
+ This is a system prompt, please behave and help the user.
35
+
36
+ ### User:
37
+ Your prompt here
38
+
39
+ ### Assistant
40
+ The output of QuantumLM
41
+ ```
42
+
43
+
44
+
45
+ ## Use and Limitations
46
+
47
+ ### Intended Use
48
+
49
+ These models are intended for research only, in adherence with the [CC BY-NC-4.0](https://creativecommons.org/licenses/by-nc/4.0/) license.
50
+
51
+ ### Limitations and bias
52
+
53
+ Although the aforementioned dataset helps to steer the base language models into "safer" distributions of text, not all biases and toxicity can be mitigated through fine-tuning. We ask that users be mindful of such potential issues that can arise in generated responses. Do not treat model outputs as substitutes for human judgment or as sources of truth. Please use it responsibly.
54
+
55
+
56
+
57
+ Contact us : [email protected]
58
+