Text Generation
Transformers
Chinese
English
llama
text-generation-inference
fireballoon commited on
Commit
4a1a0d4
1 Parent(s): dbd619f

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -1
README.md CHANGED
@@ -37,7 +37,7 @@ datasets:
37
  >>> from transformers import AutoTokenizer, TextStreamer
38
  >>> from auto_gptq import AutoGPTQForCausalLM
39
  >>> tokenizer = AutoTokenizer.from_pretrained("fireballoon/baichuan-vicuna-chinese-7b-gptq", use_fast=False)
40
- >>> model = AutoGPTQForCausalLM.from_pretrained("fireballoon/baichuan-vicuna-chinese-7b-gptq").cuda()
41
  >>> streamer = TextStreamer(tokenizer, skip_prompt=True, skip_special_tokens=True)
42
  >>> instruction = "A chat between a curious user and an artificial intelligence assistant. The assistant gives helpful, detailed, and polite answers to the user's questions. USER: {} ASSISTANT:"
43
  >>> prompt = instruction.format("How can I improve my time management skills?") # user message
 
37
  >>> from transformers import AutoTokenizer, TextStreamer
38
  >>> from auto_gptq import AutoGPTQForCausalLM
39
  >>> tokenizer = AutoTokenizer.from_pretrained("fireballoon/baichuan-vicuna-chinese-7b-gptq", use_fast=False)
40
+ >>> model = AutoGPTQForCausalLM.from_quantized("fireballoon/baichuan-vicuna-chinese-7b-gptq", device="cuda:0")
41
  >>> streamer = TextStreamer(tokenizer, skip_prompt=True, skip_special_tokens=True)
42
  >>> instruction = "A chat between a curious user and an artificial intelligence assistant. The assistant gives helpful, detailed, and polite answers to the user's questions. USER: {} ASSISTANT:"
43
  >>> prompt = instruction.format("How can I improve my time management skills?") # user message