---
title: moxin-instruct-7b
canonical_url: "https://www.modelscope.cn/models/moxin-org/moxin-instruct-7b"
md_url: "https://www.modelscope.cn/models/moxin-org/moxin-instruct-7b.md"
repository: moxin-org/moxin-instruct-7b
last_updated: 2025-06-11
license: apache-2.0
model_type:
  - mistral
architectures:
  - MistralForCausalLM
library_name:
  - pytorch
frameworks:
  - pytorch
inference_backends:
  - "deploy_task text/emb"
  - "lmdeploy 0.9.1"
  - "lmdeploy_turbomind 0.9.1"
  - "sglang 0.5.2"
  - "vllm 0.9.2"
downloads: 461
stars: 0
---

# moxin-instruct-7b

> moxin-instruct-7b - moxin-org 在 ModelScope 开源的模型。Home Page &nbsp&nbsp | &nbsp&nbsp Technical Report &nbsp&nbsp | &nbsp&nbsp Base Model &nbsp&nbsp | &nbsp&nbsp Chat Model &nbsp&nbsp | &nbsp&nbsp Instruct Model &nbsp&nbsp | &nbsp&nbsp Reasoning Model…

moxin-org/moxin-instruct-7b 是 ModelScope 魔搭社区上的机器学习模型，采用 apache-2.0 许可，可用 deploy_task text/emb、lmdeploy 0.9.1、lmdeploy_turbomind 0.9.1 部署。

- **Repository**: moxin-org/moxin-instruct-7b
- **License**: apache-2.0
- **Inference backends**: deploy_task text/emb, lmdeploy 0.9.1, lmdeploy_turbomind 0.9.1, sglang 0.5.2, vllm 0.9.2
- **Downloads**: 461
- **Stars**: 0
- **Last updated**: 2025-06-11

Source: https://www.modelscope.cn/models/moxin-org/moxin-instruct-7b

---

<h1 align="center"> Moxin 7B Instruct </h1>

<p align="center"> <a href="https://github.com/moxin-org/Moxin-LLM">Home Page</a> &nbsp&nbsp | &nbsp&nbsp <a href="https://arxiv.org/abs/2412.06845">Technical Report</a> &nbsp&nbsp | &nbsp&nbsp <a href="https://huggingface.co/moxin-org/Moxin-7B-LLM">Base Model</a> &nbsp&nbsp | &nbsp&nbsp <a href="https://huggingface.co/moxin-org/Moxin-7B-Chat">Chat Model</a>  &nbsp&nbsp | &nbsp&nbsp  <a href="https://huggingface.co/moxin-org/Moxin-7B-Instruct">Instruct Model</a> &nbsp&nbsp | &nbsp&nbsp  <a href="https://huggingface.co/moxin-org/Moxin-7B-Reasoning">Reasoning Model</a>  &nbsp&nbsp | &nbsp&nbsp  <a href="https://huggingface.co/moxin-org/Moxin-7B-VLM">VLM Model</a> </p>



## Chat Template

The chat template is formatted as:
```
<|system|>\nYou are a helpful AI assistant!\n<|user|>\nHow are you doing?\n<|assistant|>\nThank you for asking! As an AI, I don't have feelings, but I'm functioning normally and ready to assist you. How can I help you today?<|endoftext|>
```
Or with new lines expanded:
```
<|system|>
You are a helpful AI assistant!
<|user|>
How are you doing?
<|assistant|>
Thank you for asking! As an AI, I don't have feelings, but I'm functioning normally and ready to assist you. How can I help you today?<|endoftext|>
```


## Inference

You can use the following code to run inference with the model. 

```
import transformers
import torch

model_id = "moxin-org/Moxin-7B-Instruct"
pipeline = transformers.pipeline(
    "text-generation",
    model=model_id,
    model_kwargs={"torch_dtype": torch.bfloat16},
    device_map="auto",
)

messages = [
    {"role": "system", "content": "You are a helpful AI assistant!"},
    {"role": "user", "content": "How are you doing?"},
]

outputs = pipeline(
    messages,
    max_new_tokens=1024,
)

print(outputs[0]["generated_text"][-1])

```
