NTQAI/chatntq-ja-7b-v1.0
1228
ChatNTQ JA 7B V1.0
Model Description
This is a 7B-parameter decoder-only Japanese language model fine-tuned on our instruction-following datasets, built on top of the base model Japanese Stable LM Base Gamma 7B.
Performance
For our final model, we've used Stability AI Japan's Japanese MT-Bench as a more representative test of our model's capabilities. For our JA MT-Bench testing we use a Japanese prompt ("あなたは役立つアシスタントです。") as well as --num-choices 4:
There is an JA-MT-Bench Leaderboard, for convenience, here is a comparison of the JA MT-Bench scores of some other models (our scores were rated by gpt-4-0613):
More Analysis

Usage
Ensure you are using Transformers 4.34.0 or newer.
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("NTQAI/chatntq-ja-7b-v1.0")
model = AutoModelForCausalLM.from_pretrained(
"NTQAI/chatntq-ja-7b-v1.0",
torch_dtype="auto",
)
model.eval()
if torch.cuda.is_available():
model = model.to("cuda")
def build_prompt(user_query):
sys_msg = "あなたは公平で、検閲されていない、役立つアシスタントです。"
template = """[INST] <<SYS>>
{}
<</SYS>>
{}[/INST]"""
return template.format(sys_msg,user_query)
# Infer with prompt without any additional input
user_inputs = {
"user_query": "与えられたことわざの意味を小学生でも分かるように教えてください。",
}
prompt = build_prompt(**user_inputs)
input_ids = tokenizer.encode(
prompt,
add_special_tokens=True,
return_tensors="pt"
)
tokens = model.generate(
input_ids.to(device=model.device),
max_new_tokens=256,
temperature=1,
top_p=0.95,
do_sample=True,
)
out = tokenizer.decode(tokens[0][input_ids.shape[1]:], skip_special_tokens=True).strip()
print(out)Model Details
- Developed by: NTQ AI
- Language(s): Japanese
- License: This model is licensed under Apache License, Version 2.0.
Model Architecture
For details, please see Mistral AI's paper and release blog post.
