Instructions to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF", filename="Mistral-Nemo-Japanese-Instruct-2408.Q2_K.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
Use Docker
docker model run hf.co/QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
- Ollama
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with Ollama:
ollama run hf.co/QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
- Unsloth Studio new
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF to start chatting
- Docker Model Runner
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with Docker Model Runner:
docker model run hf.co/QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
- Lemonade
How to use QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.Mistral-Nemo-Japanese-Instruct-2408-GGUF-Q4_K_M
List all available models
lemonade list
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:# Run inference directly in the terminal:
llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Use pre-built binary
# Download pre-built binary from:
# https://github.com/ggerganov/llama.cpp/releases# Start a local OpenAI-compatible server with a web UI:
./llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:# Run inference directly in the terminal:
./llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Build from source code
git clone https://github.com/ggerganov/llama.cpp.git
cd llama.cpp
cmake -B build
cmake --build build -j --target llama-server llama-cli# Start a local OpenAI-compatible server with a web UI:
./build/bin/llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:# Run inference directly in the terminal:
./build/bin/llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:Use Docker
docker model run hf.co/QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF
This is quantized version of cyberagent/Mistral-Nemo-Japanese-Instruct-2408 created using llama.cpp
Original Model Card
Mistral-Nemo-Japanese-Instruct-2408
Model Description
This is a Japanese continually pre-trained model based on mistralai/Mistral-Nemo-Instruct-2407.
Usage
Make sure to update your transformers installation via pip install --upgrade transformers.
from transformers import AutoModelForCausalLM, AutoTokenizer, TextStreamer
model = AutoModelForCausalLM.from_pretrained("cyberagent/Mistral-Nemo-Japanese-Instruct-2408", device_map="auto", torch_dtype="auto")
tokenizer = AutoTokenizer.from_pretrained("cyberagent/Mistral-Nemo-Japanese-Instruct-2408")
streamer = TextStreamer(tokenizer, skip_prompt=True, skip_special_tokens=True)
messages = [
{"role": "system", "content": "あなたは親切なAIアシスタントです。"},
{"role": "user", "content": "AIによって私たちの暮らしはどのように変わりますか?"}
]
input_ids = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt").to(model.device)
output_ids = model.generate(input_ids,
max_new_tokens=1024,
temperature=0.5,
streamer=streamer)
Prompt Format
ChatML Format
<s><|im_start|>system
あなたは親切なAIアシスタントです。<|im_end|>
<|im_start|>user
AIによって私たちの暮らしはどのように変わりますか?<|im_end|>
<|im_start|>assistant
License
Apache-2.0
Author
How to cite
@misc{cyberagent-mistral-nemo-japanese-instruct-2408,
title={Mistral-Nemo-Japanese-Instruct-2408},
url={https://huggingface.co/cyberagent/Mistral-Nemo-Japanese-Instruct-2408},
author={Ryosuke Ishigami},
year={2024},
}
- Downloads last month
- 408
2-bit
3-bit
4-bit
5-bit
6-bit
8-bit
Model tree for QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF
Base model
mistralai/Mistral-Nemo-Base-2407
Install from brew
# Start a local OpenAI-compatible server with a web UI: llama-server -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF:# Run inference directly in the terminal: llama-cli -hf QuantFactory/Mistral-Nemo-Japanese-Instruct-2408-GGUF: