Text Generation
Transformers
Safetensors
Spanish
qwen2
chat
conversational
text-generation-inference
Instructions to use IIC/RigoChat-7b-v2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use IIC/RigoChat-7b-v2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="IIC/RigoChat-7b-v2") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("IIC/RigoChat-7b-v2") model = AutoModelForCausalLM.from_pretrained("IIC/RigoChat-7b-v2", 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=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use IIC/RigoChat-7b-v2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "IIC/RigoChat-7b-v2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "IIC/RigoChat-7b-v2", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/IIC/RigoChat-7b-v2
- SGLang
How to use IIC/RigoChat-7b-v2 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 "IIC/RigoChat-7b-v2" \ --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": "IIC/RigoChat-7b-v2", "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 "IIC/RigoChat-7b-v2" \ --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": "IIC/RigoChat-7b-v2", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use IIC/RigoChat-7b-v2 with Docker Model Runner:
docker model run hf.co/IIC/RigoChat-7b-v2
Update README.md
Browse files
README.md
CHANGED
|
@@ -5,7 +5,8 @@ language:
|
|
| 5 |
base_model:
|
| 6 |
- Qwen/Qwen2.5-7B-Instruct
|
| 7 |
pipeline_tag: text-generation
|
| 8 |
-
license:
|
|
|
|
| 9 |
license_link: https://huggingface.co/IIC/RigoChat-7b-v2/blob/main/LICENSE
|
| 10 |
tags:
|
| 11 |
- chat
|
|
@@ -34,7 +35,7 @@ Remarkably, this model was trained on a single A100 GPU with limited computation
|
|
| 34 |
- **Developed by:** Instituto de Ingeniería del Conocimiento (IIC).
|
| 35 |
- **Model type:** Generative Fine-tuned Transformer.
|
| 36 |
- **Language(s) (NLP):** Spanish (BCP-47 es).
|
| 37 |
-
- **License:**
|
| 38 |
- **Finetuned from model:** [Qwen/Qwen2.5-7B-Instruct](https://huggingface.co/Qwen/Qwen2.5-7B-Instruct).
|
| 39 |
|
| 40 |
### Model Sources
|
|
|
|
| 5 |
base_model:
|
| 6 |
- Qwen/Qwen2.5-7B-Instruct
|
| 7 |
pipeline_tag: text-generation
|
| 8 |
+
license: other
|
| 9 |
+
license_name: rigochat-2-nc
|
| 10 |
license_link: https://huggingface.co/IIC/RigoChat-7b-v2/blob/main/LICENSE
|
| 11 |
tags:
|
| 12 |
- chat
|
|
|
|
| 35 |
- **Developed by:** Instituto de Ingeniería del Conocimiento (IIC).
|
| 36 |
- **Model type:** Generative Fine-tuned Transformer.
|
| 37 |
- **Language(s) (NLP):** Spanish (BCP-47 es).
|
| 38 |
+
- **License:** RIGOCHAT 2 NON-COMMERCIAL.
|
| 39 |
- **Finetuned from model:** [Qwen/Qwen2.5-7B-Instruct](https://huggingface.co/Qwen/Qwen2.5-7B-Instruct).
|
| 40 |
|
| 41 |
### Model Sources
|