Downloads · 30 days
21
4% of all-time downloads
cczhong/internlm-chat-7b-4bit-gptq
internlm-chat-7b-4bit-gptq is a feature extraction model from cczhong. Use it when you need embeddings to search or compare text. It is set up for transformers.
need install "pip install git+https://github.com/cczhong11/AutoGPTQ" before https://github.com/PanQiWei/AutoGPTQ/pull/189 got merged
Downloads · 30 days
21
4% of all-time downloads
All-time downloads
590
Public
Repo size
5.1 GB
Likes
4
Public
Click a slice to open those files.
.bin5.1 GB · 100%
From the Hugging Face model README
need install "pip install git+https://github.com/cczhong11/AutoGPTQ" before https://github.com/PanQiWei/AutoGPTQ/pull/189 got merged
from transformers import AutoTokenizer, AutoModelForCausalLM
from auto_gptq import AutoGPTQForCausalLM, BaseQuantizeConfig
quantized_model_dir = "cczhong/internlm-chat-7b-4bit-gptq"
tokenizer = AutoTokenizer.from_pretrained(quantized_model_dir, trust_remote_code=True)
model = AutoGPTQForCausalLM.from_quantized(quantized_model_dir, device="cuda:0",trust_remote_code=True)
response, history = model.chat(tokenizer, "你好", history=[])