Text Generation
Transformers
Safetensors
mistral
LLM
llama
Mistral
conversational
text-generation-inference
4-bit precision
gptq
Run this model with HF Jobs
Run TheBloke/Generate_Question_Mistral_7B-GPTQ on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/TheBloke/Generate_Question_Mistral_7B-GPTQ. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/TheBloke/Generate_Question_Mistral_7B-GPTQ on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/TheBloke/Generate_Question_Mistral_7B-GPTQ. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Instructions to use TheBloke/Generate_Question_Mistral_7B-GPTQ with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use TheBloke/Generate_Question_Mistral_7B-GPTQ with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="TheBloke/Generate_Question_Mistral_7B-GPTQ") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("TheBloke/Generate_Question_Mistral_7B-GPTQ") model = AutoModelForCausalLM.from_pretrained("TheBloke/Generate_Question_Mistral_7B-GPTQ", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use TheBloke/Generate_Question_Mistral_7B-GPTQ with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "TheBloke/Generate_Question_Mistral_7B-GPTQ" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "TheBloke/Generate_Question_Mistral_7B-GPTQ", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/TheBloke/Generate_Question_Mistral_7B-GPTQ
- SGLang
How to use TheBloke/Generate_Question_Mistral_7B-GPTQ with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "TheBloke/Generate_Question_Mistral_7B-GPTQ" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "TheBloke/Generate_Question_Mistral_7B-GPTQ", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "TheBloke/Generate_Question_Mistral_7B-GPTQ" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "TheBloke/Generate_Question_Mistral_7B-GPTQ", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use TheBloke/Generate_Question_Mistral_7B-GPTQ with Docker Model Runner:
docker model run hf.co/TheBloke/Generate_Question_Mistral_7B-GPTQ
GPTQ model commit
Browse filesFiles changed (7)
- added_tokens.jsonAdded+4
- config.jsonAdded+38
- model.safetensorsAdded+3
- quantize_config.jsonAdded+10
- special_tokens_map.jsonAdded+23
- tokenizer.modelAdded+3
- tokenizer_config.jsonAdded+61
1234{ "<|im_end|>": 32000, "<|im_start|>": 32001}1234567891011121314151617181920212223242526272829303132333435363738{ "_name_or_path": "/workspace/process/fpham_generate_question_mistral_7b/source", "architectures": [ "MistralForCausalLM" ], "bos_token_id": 1, "eos_token_id": 32000, "hidden_act": "silu", "hidden_size": 4096, "initializer_range": 0.02, "intermediate_size": 14336, "max_position_embeddings": 32768, "model_type": "mistral", "num_attention_heads": 32, "num_hidden_layers": 32, "num_key_value_heads": 8, "pad_token_id": 0, "pretraining_tp": 1, "rms_norm_eps": 1e-05, "rope_theta": 10000.0, "sliding_window": 4096, "tie_word_embeddings": false, "torch_dtype": "float16", "transformers_version": "4.35.2", "use_cache": true, "vocab_size": 32002, "quantization_config": { "bits": 4, "group_size": 128, "damp_percent": 0.1, "desc_act": true, "sym": true, "true_sequential": true, "model_name_or_path": null, "model_file_base_name": "model", "quant_method": "gptq" }}123version https://git-lfs.github.com/spec/v1oid sha256:052964c78a11af77d5bcf8dcaf84c03e9183de6dd96040ed4673b822e1886cd8size 415869498412345678910{ "bits": 4, "group_size": 128, "damp_percent": 0.1, "desc_act": true, "sym": true, "true_sequential": true, "model_name_or_path": null, "model_file_base_name": "model"}1234567891011121314151617181920212223{ "bos_token": { "content": "<s>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false }, "eos_token": { "content": "<|im_end|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false }, "unk_token": { "content": "<unk>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false }}123version https://git-lfs.github.com/spec/v1oid sha256:dadfd56d766715c61d2ef780a525ab43b8e6da4de6865bda3d95fdef5e134055size 49344312345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061{ "add_bos_token": true, "add_eos_token": false, "added_tokens_decoder": { "0": { "content": "<unk>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true }, "1": { "content": "<s>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true }, "2": { "content": "</s>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true }, "32000": { "content": "<|im_end|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true }, "32001": { "content": "<|im_start|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true } }, "additional_special_tokens": [], "bos_token": "<s>", "chat_template": "{% for message in messages %}{{'<|im_start|>' + message['role'] + '\n' + message['content'] + '<|im_end|>' + '\n'}}{% endfor %}{% if add_generation_prompt %}{{ '<|im_start|>assistant\n' }}{% endif %}", "clean_up_tokenization_spaces": false, "eos_token": "<|im_end|>", "legacy": true, "model_max_length": 1000000000000000019884624838656, "pad_token": null, "sp_model_kwargs": {}, "spaces_between_special_tokens": false, "tokenizer_class": "LlamaTokenizer", "trust_remote_code": false, "unk_token": "<unk>", "use_default_system_prompt": true, "use_fast": true}added_tokens.jsonAdded+4
config.jsonAdded+38
model.safetensorsAdded+3
quantize_config.jsonAdded+10
special_tokens_map.jsonAdded+23
tokenizer.modelAdded+3
tokenizer_config.jsonAdded+61