Text Generation
Transformers
Safetensors
GGUF
Japanese
gemma2
conversational
text-generation-inference
imatrix
How to use from the
Use from the
llama-cpp-python library
# !pip install llama-cpp-python

from llama_cpp import Llama

llm = Llama.from_pretrained(
	repo_id="kajuma/gemma-2-27b-instruct",
	filename="",
)
llm.create_chat_completion(
	messages = [
		{
			"role": "user",
			"content": "What is the capital of France?"
		}
	]
)

このモデルはコンペティションのために開発されたモデルです。

推論方法

まず、llama-cpp-pythonをインストールしてください。 その後推論用ライブラリをセットアップします。

git clone https://github.com/weak-kajuma/inference-for-llm-class.git
cd inference-for-llm-class
pip install datasets

次に、モデルをダウンロードします。

# GPUによって量子化サイズや次のセクションの`--ngl`を選んでください。
wget https://huggingface.co/kajuma/gemma-2-27b-instruct/resolve/main/Gemma-2-27B-Instruct_Q6_K.gguf

推論プログラムを実行します。

python answer_llama_cpp.py --model Gemma-2-27B-Instruct_Q6_K.gguf --ngl 46 --data_file data.jsonl

ただしdata.jsonlのフォーマットは以下の通りです。

{"task_id": 0, "input": "質問"}

推論後output.jsonlが作成されます。

Downloads last month
54
Safetensors
Model size
27B params
Tensor type
BF16
·
Inference Providers NEW
Input a message to start chatting with kajuma/gemma-2-27b-instruct.

Model tree for kajuma/gemma-2-27b-instruct

Quantized
(14)
this model

Datasets used to train kajuma/gemma-2-27b-instruct