初始化项目,由ModelHub XC社区提供模型
Model: zpeng1989/Medical_Qwen3_17B_Large_Language_Model Source: Original Platform
This commit is contained in:
47
.gitattributes
vendored
Normal file
47
.gitattributes
vendored
Normal file
@@ -0,0 +1,47 @@
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.arrow filter=lfs diff=lfs merge=lfs -text
|
||||
*.bin filter=lfs diff=lfs merge=lfs -text
|
||||
*.bin.* filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.ftz filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.h5 filter=lfs diff=lfs merge=lfs -text
|
||||
*.joblib filter=lfs diff=lfs merge=lfs -text
|
||||
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
||||
*.model filter=lfs diff=lfs merge=lfs -text
|
||||
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
||||
*.onnx filter=lfs diff=lfs merge=lfs -text
|
||||
*.ot filter=lfs diff=lfs merge=lfs -text
|
||||
*.parquet filter=lfs diff=lfs merge=lfs -text
|
||||
*.pb filter=lfs diff=lfs merge=lfs -text
|
||||
*.pt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pth filter=lfs diff=lfs merge=lfs -text
|
||||
*.rar filter=lfs diff=lfs merge=lfs -text
|
||||
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
||||
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
||||
*.tflite filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zstandard filter=lfs diff=lfs merge=lfs -text
|
||||
*.tfevents* filter=lfs diff=lfs merge=lfs -text
|
||||
*.db* filter=lfs diff=lfs merge=lfs -text
|
||||
*.ark* filter=lfs diff=lfs merge=lfs -text
|
||||
**/*ckpt*data* filter=lfs diff=lfs merge=lfs -text
|
||||
**/*ckpt*.meta filter=lfs diff=lfs merge=lfs -text
|
||||
**/*ckpt*.index filter=lfs diff=lfs merge=lfs -text
|
||||
*.safetensors filter=lfs diff=lfs merge=lfs -text
|
||||
*.ckpt filter=lfs diff=lfs merge=lfs -text
|
||||
*.gguf* filter=lfs diff=lfs merge=lfs -text
|
||||
*.ggml filter=lfs diff=lfs merge=lfs -text
|
||||
*.llamafile* filter=lfs diff=lfs merge=lfs -text
|
||||
*.pt2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.mlmodel filter=lfs diff=lfs merge=lfs -text
|
||||
*.npy filter=lfs diff=lfs merge=lfs -text
|
||||
*.npz filter=lfs diff=lfs merge=lfs -text
|
||||
*.pickle filter=lfs diff=lfs merge=lfs -text
|
||||
*.pkl filter=lfs diff=lfs merge=lfs -text
|
||||
*.tar filter=lfs diff=lfs merge=lfs -text
|
||||
*.wasm filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
||||
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
||||
14
Modelfile
Normal file
14
Modelfile
Normal file
@@ -0,0 +1,14 @@
|
||||
# ollama modelfile auto-generated by llamafactory
|
||||
|
||||
FROM .
|
||||
|
||||
TEMPLATE """{{ if .System }}<|im_start|>system
|
||||
{{ .System }}<|im_end|>
|
||||
{{ end }}{{ range .Messages }}{{ if eq .Role "user" }}<|im_start|>user
|
||||
{{ .Content }}<|im_end|>
|
||||
<|im_start|>assistant
|
||||
{{ else if eq .Role "assistant" }}{{ .Content }}<|im_end|>
|
||||
{{ end }}{{ end }}"""
|
||||
|
||||
PARAMETER stop "<|im_end|>"
|
||||
PARAMETER num_ctx 4096
|
||||
421
README.md
Normal file
421
README.md
Normal file
@@ -0,0 +1,421 @@
|
||||
# 医疗思考链问答大模型
|
||||
|
||||
## 项目概述
|
||||
|
||||
本项目旨在构建一个针对医疗知识的思考链条的问答大模型,基于Qwen3-1.7B模型作为基座模型[Qwen/Qwen3-1.7B],使用LoRA(Low-Rank Adaptation)技术进行微调。模型训练数据涵盖了医疗问诊、咨询等权威医学领域知识信息,并通过问答题目进行微调,以提升模型在医学领域的问答能力。这种数据预处理的策略,充分挖掘了Qwen3模型强大的推理能力,使其能够模拟在医疗场景中,如何发现患者记录描述信息中获取到关联性的过程。
|
||||
|
||||
## 模型架构
|
||||
|
||||
- **基座模型**:[`Qwen/Qwen3-1.7B`]<https://modelscope.cn/models/Qwen/Qwen3-1.7B>
|
||||
- **微调方法**: LoRA(Low-Rank Adaptation)
|
||||
- **训练数据**: 问答数据集
|
||||
|
||||
## 数据集
|
||||
|
||||
### 数据来源
|
||||
|
||||
参考链接:<https://huggingface.co/datasets/FreedomIntelligence/medical-o1-reasoning-SFT/tree/main>
|
||||
|
||||
### 数据预处理
|
||||
|
||||
训练数据格式:
|
||||
|
||||
```
|
||||
{
|
||||
"Question": "女性,34岁,双下肢麻木无力1年半,感觉障碍自下而上发展。体检:右侧胸8以下痛、温觉消失,左侧胸以下痛、温觉减退。右下肢肌力Ⅳ级,左下肢肌力Ⅲ级。左侧巴氏征阳性。病变的定性诊断应首先考虑为\nA. 脊膜瘤\nB. 神经纤维瘤\nC. 脑胶质瘤\nD. 椎管内转移瘤\nE. 脊髓髓内室管膜瘤",
|
||||
"output": "<think>患者是一名34岁的女性,哎,她已经忍受了双下肢麻木无力有一年半了。她的症状是从脚下开始向上蔓延的。这听起来像是典型的神经问题,特别是脊髓的事情。\n\n在体检中,发现她的右侧胸8以下痛、温觉已经完全消失,奇怪的是,左侧则只是减退。这些提示我去考虑下,可能是脊髓的问题,尤其是可能在胸8这个区域出毛病了。\n\n她的巴氏征左侧是阳性的,这表明脊髓半侧损害,这就是所谓的Brown-Séquard综合征呀。嗯,右下肢的肌力相较左侧还稍微好一点,但情况都不妙。\n\n想到病变性质,感觉病程发展这么缓慢,说明是一种慢性病。可以是肿瘤,那肿瘤的话,髓内的或髓外的都有可能。这个就看到底是涉及到脊髓内还是外了。\n\n室管膜瘤这种病镇的可能存在脊髓内部,而且病程缓慢符合这类症状的特点。哦,不过要是脊髓外的问题,那脊膜瘤这种可能会导致脊髓半侧损害,这样就很吻合了。\n\n啊,神经纤维瘤有时候也出现类似的症状,不过更常见多发性问题和皮肤上的表现,她没有这些其他症状。这有点排除掉。\n\n脑胶质瘤或者椎管内转移瘤不太可能造成这样的表现,这个在脊髓半侧这样单纯的损害上,不是那么直接。\n\n所以,考虑到这些症状,还有病变的特性,我觉得首先还是脊膜瘤可能性最大,特别是与这种Brown-Séquard综合征这样的一侧症状损害表现最吻合。</think>\n结合患者的症状和体检结果,考虑到病变的性质以及脊髓半侧损害的特点,这些特征非常符合脊膜瘤的表现。因此,病变的定性诊断首先应考虑为脊膜瘤。\n\nA. 脊膜瘤"
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## 模型训练
|
||||
|
||||
### 微调方法
|
||||
|
||||
使用LoRA技术对`Qwen3`模型进行微调。LoRA通过在预训练模型的权重矩阵中引入低秩矩阵来减少参数量,从而在保持模型性能的同时降低计算成本。
|
||||
|
||||
### 训练步骤
|
||||
|
||||
1. **加载预训练模型**: 加载`Qwen3`1.7B模型。
|
||||
2. **应用LoRA**: 在模型的关键层应用LoRA技术。
|
||||
3. **训练模型**: 使用准备好的肿瘤知识问答数据集进行微调。
|
||||
4. **验证与测试**: 在验证集和测试集上评估模型性能,调整超参数以优化结果。
|
||||
|
||||
## 模型评估
|
||||
|
||||
### 评估指标
|
||||
|
||||
- **准确率**: 模型在问答任务中的准确率。
|
||||
- **召回率**: 模型能够正确回答的问题比例。
|
||||
- **F1分数**: 准确率和召回率的调和平均数。
|
||||
|
||||
### 评估结果
|
||||
|
||||
在测试集上的评估结果如下:
|
||||
待更新
|
||||
|
||||
## 使用指南
|
||||
|
||||
### 环境配置
|
||||
|
||||
1. **Python版本**: 3.10+
|
||||
2. **依赖库**:
|
||||
- `transformers`
|
||||
- `torch`
|
||||
|
||||
### 模型下载
|
||||
|
||||
SDK下载
|
||||
|
||||
```bash
|
||||
#安装ModelScope
|
||||
pip install modelscope
|
||||
```
|
||||
|
||||
```python
|
||||
#SDK模型下载
|
||||
from modelscope import snapshot_download
|
||||
model_dir = snapshot_download('')
|
||||
```
|
||||
|
||||
Git下载
|
||||
|
||||
```
|
||||
#Git模型下载
|
||||
git clone
|
||||
```
|
||||
|
||||
### 模型推理
|
||||
|
||||
```python
|
||||
from transformers import AutoModelForCausalLM, AutoTokenizer
|
||||
|
||||
# 加载微调后的模型
|
||||
model = AutoModelForCausalLM.from_pretrained("path_to_your_model")
|
||||
tokenizer = AutoTokenizer.from_pretrained("path_to_your_model")
|
||||
|
||||
# 输入问题
|
||||
question = "请列出所有与葡萄胎相关的症状和体征?"
|
||||
inputs = tokenizer(question, return_tensors="pt")
|
||||
|
||||
# 生成答案
|
||||
outputs = model.generate(**inputs)
|
||||
answer = tokenizer.decode(outputs[0], skip_special_tokens=True)
|
||||
|
||||
print(answer)
|
||||
```
|
||||
|
||||
### WEB部署
|
||||
|
||||
代码参考:
|
||||
|
||||
```
|
||||
from transformers import AutoTokenizer, AutoModelForCausalLM
|
||||
import torch
|
||||
import streamlit as st
|
||||
import re
|
||||
|
||||
# 在侧边栏中创建一个标题和一个链接
|
||||
with st.sidebar:
|
||||
st.markdown("## 7B LLM")
|
||||
max_length = st.slider("max_length", 0, 8192, 8192, step=1)
|
||||
temperature = st.slider("temperature", 0.0, 1.0, 0.1, step=0.1)
|
||||
|
||||
# 创建一个标题和一个副标题
|
||||
st.title("Model Chatbot")
|
||||
st.caption("🚀 A streamlit chatbot powered by Self-LLM")
|
||||
|
||||
# 定义模型路径
|
||||
mode_name_or_path = ''
|
||||
|
||||
# 文本分割函数
|
||||
def split_text(text):
|
||||
pattern = re.compile(r'<think>(.*?)</think>(.*)', re.DOTALL) # 定义正则表达式模式
|
||||
match = pattern.search(text) # 匹配 <think>思考过程</think>回答
|
||||
|
||||
if match: # 如果匹配到思考过程
|
||||
think_content = match.group(1).strip() # 获取思考过程
|
||||
answer_content = match.group(2).strip() # 获取回答
|
||||
else:
|
||||
think_content = "" # 如果没有匹配到思考过程,则设置为空字符串
|
||||
answer_content = text.strip() # 直接返回回答
|
||||
|
||||
return think_content, answer_content
|
||||
|
||||
# 定义一个函数,用于获取模型和 tokenizer
|
||||
@st.cache_resource
|
||||
def get_model():
|
||||
# 从预训练的模型中获取 tokenizer
|
||||
tokenizer = AutoTokenizer.from_pretrained(mode_name_or_path, trust_remote_code=True)
|
||||
tokenizer.pad_token = tokenizer.eos_token
|
||||
# 从预训练的模型中获取模型,并设置模型参数
|
||||
model = AutoModelForCausalLM.from_pretrained(mode_name_or_path, torch_dtype=torch.bfloat16, device_map="auto")
|
||||
|
||||
return tokenizer, model
|
||||
|
||||
# 加载 model 和 tokenizer
|
||||
tokenizer, model = get_model()
|
||||
|
||||
# 如果 session_state 中没有 "messages",则创建一个包含默认消息的列表
|
||||
if "messages" not in st.session_state:
|
||||
st.session_state["messages"] = [{"role": "assistant", "content": "有什么可以帮您的?"}]
|
||||
|
||||
# 遍历 session_state 中的所有消息,并显示在聊天界面上
|
||||
for msg in st.session_state.messages:
|
||||
st.chat_message(msg["role"]).write(msg["content"])
|
||||
|
||||
# 如果用户在聊天输入框中输入了内容,则执行以下操作
|
||||
if prompt := st.chat_input():
|
||||
|
||||
# 在聊天界面上显示用户的输入
|
||||
st.chat_message("user").write(prompt)
|
||||
|
||||
# 将用户输入添加到 session_state 中的 messages 列表中
|
||||
st.session_state.messages.append({"role": "user", "content": prompt})
|
||||
|
||||
# 将对话输入模型,获得返回
|
||||
input_ids = tokenizer.apply_chat_template(st.session_state.messages,tokenize=False,add_generation_prompt=True)
|
||||
model_inputs = tokenizer([input_ids], return_tensors="pt").to('cuda')
|
||||
generated_ids = model.generate(model_inputs.input_ids,max_new_tokens=max_length, temperature=temperature)
|
||||
generated_ids = [
|
||||
output_ids[len(input_ids):] for input_ids, output_ids in zip(model_inputs.input_ids, generated_ids)
|
||||
]
|
||||
response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]
|
||||
print(response)
|
||||
think_content, answer_content = split_text(response) # 调用split_text函数,分割思考过程和回答
|
||||
# 将模型的输出添加到 session_state 中的 messages 列表中
|
||||
st.session_state.messages.append({"role": "assistant", "content": response})
|
||||
# 在聊天界面上显示模型的输出
|
||||
with st.expander("模型思考过程"):
|
||||
st.write(think_content) # 展示模型思考过程
|
||||
st.chat_message("assistant").write(answer_content) # 输出模型回答
|
||||
# print(st.session_state) # 打印 session_state 调试
|
||||
|
||||
|
||||
```
|
||||
|
||||
运行命令:
|
||||
|
||||
```
|
||||
# nohup streamlit run Run_Test_v1.py --server.address 0.0.0.0 --server.port 6006 &
|
||||
```
|
||||
|
||||
### 生成结果案例
|
||||
|
||||
#### Case 01
|
||||
|
||||
输入问题:
|
||||
|
||||
```
|
||||
患者信息如下:"""现病史
|
||||
(1)病史摘要
|
||||
病人,男,49岁,3小时前解大便后出现右下腹疼痛,右下腹可触及一包块,既往体健。
|
||||
(2)主诉
|
||||
右下腹痛并自扪及包块3小时。
|
||||
|
||||
体格检查
|
||||
体温: T 37.8℃,P 101次/分,呼吸22次/分,BP 100/60mmHg,腹软,未见胃肠型蠕动波,肝脾肋下未及,于右侧腹股沟区可扪及一圆形肿块,约4cm×4cm大小,有压痛、界欠清,且肿块位于腹股沟韧带上内方。
|
||||
|
||||
辅助检查
|
||||
(1)实验室检查
|
||||
血常规:WBC 5.0×109/L,N 78%。
|
||||
尿常规正常。
|
||||
(2)多普勒超声检查
|
||||
沿腹股沟纵切可见一多层分布的混合回声区,宽窄不等,远端膨大,边界整齐,长约4~5cm。
|
||||
(3)腹部X线检查
|
||||
可见阶梯状液气平。"""具体工作:简述该病人的诊断及诊断依据。
|
||||
```
|
||||
|
||||
模型增加<think>返回结果:
|
||||
|
||||
```
|
||||
<think>患者的情况是右下腹痛并能触摸到包块,很快我想这可能不是普通的胃肠道问题,因为这些典型的胃痛通常伴随胃酸过多或消化不良,但眼前并没有这些病史。而是应该考虑一些其他地方的病因。
|
||||
他的体温是37.8℃,虽然不算特别高,但结合上其他症状,提示可能有炎症。指出去,会不会有全身性的感染?我们得往更深层次的原因去追查。
|
||||
疼痛的位置也很关键。这个疼痛点,尤其在右侧腹股沟区以及右下腹,让我联想到特异性的问题,比如精囊炎或者精索静脉曲张。不过,这个精索的问题通常不会造成剧烈疼痛和触包块。
|
||||
再看看他的血常规结果,白细胞增高到5.0×109,中性球蛋白达78%,这明显是炎症反应。腹部X线显示阶梯状液气平,这常见于肠梗阻,尤其在盲肠处。
|
||||
多普勒超声的结果也很有价值。这里显示的是一个混合回声的肿块,远端膨大,这种特征通常暗示它是一个实性和液性混合的肿物,而不是单纯的炎症。
|
||||
不过,重点还是在右侧腹股沟区,这个位置的炎症或肿物,最常见的是精囊囊肿或者精索静脉曲张。但是,精囊炎和静脉曲张不太能解释目前的X线检查。
|
||||
等等,从解剖结构来看,这里在4cm×4cm的区域,如果界线不清,也有可能是深部的淋巴结反应。位置也在腹股沟韧带上内方,这位置上的淋巴结反应,确实值得考虑。
|
||||
仔细分析,结合患者的所有症状、实验室检查结果和影像学特征,这个区域的疼痛和包块很可能不是局限于精囊囊肿或精索静脉曲张,而是一种全身性反应或更深层的问题。
|
||||
想想看,精囊或精索炎症造成的局部反应,还可能是阑尾炎或腹膜炎,因为阶梯状液气平也提示盲肠附近有问题。然而,鉴于包块的特征和界不清,我可能得把重点放在腹腔内较深位置。
|
||||
更深入的检查,比如CT或MRI,可以帮助确认,但目前结合这些信息,我觉得右侧腹腔脓肿也是一个可能。它会引起剧烈疼痛和包块,就像感染引起的反应性改变。
|
||||
经过这么多思考,我倾向于认为是右侧腹腔脓肿。因为这种以全身症状和包块为主的病症,与患者当前的表现非常吻合。所有的特征似乎指向了这一诊断,这可能是更合理且符合患者情况的诊断。</think>
|
||||
|
||||
根据患者的症状、体格检查结果以及辅助检查结果,该患者最可能的诊断是右侧腹腔脓肿。
|
||||
诊断依据如下:
|
||||
1. **症状**:患者出现了急性右下腹痛并触及包块,这是一种典型的腹膜炎疼痛表现。腹腔脓肿通常会导致急性、剧烈的腹痛和局部肿胀。
|
||||
2. **体格检查**:体温为37.8℃,虽不高但结合其他症状提示存在炎症反应。此外,腹软且未见胃肠型蠕动波,增加腹腔病变的可能性。
|
||||
3. **实验室检查**:白细胞计数增高到5.0×10^9/L,且中性球蛋白增高到78%,这提示机体对感染的应答。
|
||||
4. **影像学特征**:多普勒超声显示在右侧腹股沟区域有一个界不清的肿块,呈混合回声,长4~5cm,这与脓肿的特征相符。腹部X线检查显示阶梯状液气平,提示可能存在肠道梗阻,尤其是盲肠附近。
|
||||
5. **位置特征**:右侧腹股沟区的肿块位于腹股沟韧带上内方,这种位置也可能与腹腔脓肿更为常见发生的部位一致。
|
||||
综上所述,结合患者的所有临床表现和检查结果,右侧腹腔脓肿是一个合理且符合患者表现的诊断。进一步的影像学检查(如CT或MRI)可以确认此诊断,并指导后续治疗。
|
||||
```
|
||||
|
||||
模型去除<think>返回结果:
|
||||
```
|
||||
|
||||
根据患者的现病史和体格检查信息,这位49岁男性患者表现出右下腹和腹股沟地区的剧烈疼痛,同时还摸到了包块。首先,让我们来看看他的实验室检查结果。
|
||||
他的血常规显示白细胞计数(WBC)为5.0×10^9/L,其中多数是中性粒细胞(N 78%)。这个白细胞计数的升高通常提示有炎症或感染。结合他的疼痛和包块,这似乎是一个有力的指向,可能是感染或炎症引起的。
|
||||
再看看腹股沟区的触诊发现。肿块位于腹股沟韧带上内方,有界不清的情况,且有压痛。这很像是腹股沟直肠管脓肿(PTWS)的特征。这个发现特别吸引人注意,因为这个症状在PTWS中是非常经典的。
|
||||
超声检查结果显示,沿腹股沟纵切可以看到一多层分布的混合回声区,宽窄不等,远端膨大,长约4~5cm。这个描述很像是阶梯状肿块的表现,非常符合腹股沟直肠管脓肿的超声特征。
|
||||
虽然X线检查提示了阶梯状液气平,但结合上述所有信息,这似乎并不是阶梯状气液平面最突出的地方,诊断重点还是放在腹股沟直肠管脓肿上。
|
||||
尽管有便痛的主诉,但没有提到明确的感染征兆,如白细胞进一步显著升高或脓液征象,因此结合所有信息来看,腹股沟直肠管脓肿的诊断可能性更高。
|
||||
综上所述,结合患者的疼痛、包块特征、实验室检查异常以及超声特征,我认为最可能的诊断是腹股沟直肠管脓肿。诊断依据包括白细胞升高、腹股沟区可触及包块的压痛以及超声所显示的混合回声区特征。
|
||||
```
|
||||
|
||||
参考答案
|
||||
|
||||
```
|
||||
|
||||
诊断:嵌顿性腹股沟斜疝合并肠梗阻。
|
||||
诊断依据:
|
||||
①右下腹痛并自扪及包块3小时;
|
||||
②有腹胀、呕吐,类似肠梗阻表现;腹部平片可见阶梯状液平,考虑肠梗阻可能;腹部B超考虑,
|
||||
腹部包块内可能为肠管可能;
|
||||
③有轻度毒性反应或是中毒反应,如 T 37.8℃,P 101次/分,白细胞中性分类78%;
|
||||
④腹股沟区包块位于腹股沟韧带上内方。
|
||||
|
||||
```
|
||||
|
||||
#### Case 02
|
||||
|
||||
输入问题
|
||||
|
||||
```
|
||||
患者信息如下:"""现病史
|
||||
(1)病史摘要
|
||||
杨XX,女,59岁,30年前无明显诱因开始出现反酸、反食、烧心,胸骨后烧灼感,伴胃胀、嗳气,弯腰后反酸加重,不规律服用“奥美拉唑、吗丁啉、莫沙必利”症状可缓解,停药反复发作。5年前开始出现咳嗽、咳痰,咳嗽严重时伴胸闷、喘息症状,无明显季节性,常于进食后1小时及凌晨发作,止咳平喘效果不佳,生活质量明显下降。2年前外院诊为“反流性食管炎LA-B、食管裂孔疝,睡眠时床头抬高及、服用“耐信 20mg BID”反流症状明显缓解,咳喘症状亦明显缓解。近10个月咳喘症状加重,伴有听力下降,调整耐信 40mg BID,咳喘症状再次改善,但仍时有发作。
|
||||
(2)主诉
|
||||
反酸、烧心30年,咳嗽、咳痰、喘息5年,加重10个月。
|
||||
|
||||
体格检查
|
||||
结果 T36.8℃,P70次/分,R20次/分,Bp136/80mmHg。
|
||||
自主体位,神志清楚,全身皮肤及巩膜无黄染,全身浅表淋巴结无肿大。双肺听诊呼吸音粗及散在哮鸣音。心率70次/分,律齐,未闻及病理性杂音,腹部平软,肝脏、脾脏未触及,未触及腹部包块,肠鸣音正常。
|
||||
|
||||
辅助检查
|
||||
(1)实验室检查
|
||||
出凝血功能:正常;血生化:正常;血常规:正常。
|
||||
(2)胃镜
|
||||
反流性食管炎:LA-C;食管裂孔疝(混合型)。
|
||||
(3)上消化道造影
|
||||
反流性食管炎;食管裂孔疝。
|
||||
(4)食管高分辨率测压
|
||||
LES压力低于正常,食管体部频繁无效,食管裂孔疝。
|
||||
(5)食管高分辨率测压
|
||||
1.食管pH监测:未达到胃食管病理性酸反流;卧位酸廓清能力下降。
|
||||
2.食管阻抗监测:反流总次数正常,以酸反流为主;
|
||||
3.症状相关性分析:监测期间咳嗽、喘息症状与弱酸反流相关。
|
||||
|
||||
辅助检查
|
||||
胃镜:
|
||||
所见:齿状线上移约4cm,可见多条纵行糜烂,底部有融合,齿状线不规整,周围可见充血、水肿、糜烂。 贲门口松弛。反转胃镜可见食管裂孔疝疝囊。
|
||||
结论:反流性食管炎:LA-C;食管裂孔疝(混合型)。
|
||||
|
||||
辅助检查
|
||||
食管pH-阻抗监测(口服PPI期间)
|
||||
食管pH监测显示: DeMeester积分为8.0(正常值<14.7);酸反流时间百分比(AET)为2.1%(正常值<4.2%),卧位酸反流时间所占百分比大于正常。卧位酸清除时间延长。
|
||||
食管阻抗监测显示:食团反流总时间百分比(BET)为1.2%(正常值<1.4%),立位食团反流时间百分比大于正常;反流总次数为48次(正常值<73次),其中酸反流32次,弱酸反流5次,弱碱反流3次,酸性气体反流2次,弱酸性气体反流4次,弱碱性气体反流2次。立位食团清除时间延长。
|
||||
症状相关性分析:
|
||||
1、患者监测期间共记录咳嗽症状17次,与弱酸反流相关4次,弱酸反流的SI为24%、SAP为99%。
|
||||
2、患者监测期间共记录喘息症状5次,与弱酸反流相关2次。弱酸反流的SI为40%,SAP为 96%。
|
||||
注:SI为反流/症状指数 ,参考值>50%;SAP:反流/症状相关概率,参考值>95%。
|
||||
|
||||
辅助检查
|
||||
上消化道造影:可见巨大食管裂孔疝,贲门及胃底均疝入胸腔。
|
||||
|
||||
辅助检查
|
||||
食管高分辨率测压:
|
||||
LES压力低于正常,吞咽时松弛正常。
|
||||
UES压力低于正常,松弛功能欠佳。
|
||||
食管体部频繁无效蠕动 (无效吞咽百分比50%) 。
|
||||
食管裂孔疝。"""具体工作:分析本例病人的病史、体格检查和辅助检查。
|
||||
```
|
||||
|
||||
模型增加<think>返回结果:
|
||||
|
||||
```
|
||||
<think>这个病人的病史挺长的,反酸和烧心已经有30年了,从59岁才开始出现咳嗽和喘息的症状,这些问题已经拖了5年。最近还有10个月的咳喘加重,这可不太好。
|
||||
再看看他的体格检查,体温36.8,心率70,这些是正常范围,但双肺有哮鸣音,这可能说明有气道的问题。哎,食管裂孔疝也在体检时发现,不过这和病情有什么关系呢?
|
||||
看一下他的辅助检查吧。胃镜显示食管糜烂,这可是反流性食管炎LA-C,食管裂孔疝,真是麻烦。血检啥都正常的,上消化道造影也证实了食管裂孔疝。
|
||||
尤其是食管pH和阻抗监测,酸反流明显比正常值要频繁,这已经不是小问题。酸反流时间百分比等都超出范围,看来药物治疗效果也不大好。
|
||||
食管高分辨率测压说LES压力总是无效,这可影响胃部正常功能。这样一来看,患者的问题不只是胃的问题,还伴随着呼吸和咳嗽的困扰。
|
||||
咳嗽和喘息症状记录中,咳嗽症状与弱酸反流有明显关联。看一下症状相关性分析,咳嗽的SI只有24%,而对于症状相关性要求>50%才算高相关。喘息的SI是40%,也接近但不够高。
|
||||
综合这些信息,这个病人主要就是反流性食管炎,症状复杂,还伴有咳嗽和喘息,这严重影响了他的生活质量。嗯,可能需要考虑更有效的治疗方案,特别是针对咳嗽症状的措施。
|
||||
所以,综合考虑,这个病人需要认真处理酸反流引起的咳嗽症状,同时继续处理明确的反流性食管炎问题。也许在控制酸反流的基础上,使用更合适的止咳药物会更好。</think>
|
||||
|
||||
根据提供的病史资料,这位59岁的女性病人有长期的反酸和烧心症状,伴随5年的咳嗽、咳痰和喘息症状,最近10个月来咳喘症状加重,还伴有听力下降。通过详细的病史、体格检查和辅助检查,可以明确患者主要面临的问题是反流性食管炎,以及由于反流诱发的咳嗽症状严重。
|
||||
首先,从病史来看,患者从30年前就开始有反酸、烧心的症状,经过长期的胃部问题处理,最近5年又出现了严重的呼吸系统症状:咳嗽和喘息。这些呼吸症状伴随较弱的酸反流,与症状相关性不佳。
|
||||
体格检查显示患者无明显黄疸和异常心肺杂音,这些结果提示患者身体状态良好,但双肺有哮鸣音,这提示可能存在气道高反应性。
|
||||
在辅助检查方面,胃镜及多方面的食管pH和阻抗监测都明确显示患者有显著的食管裂孔疝和明确的酸反流问题。食管内频繁的酸反流,尤其是弱酸反流与患者咳嗽和喘息症状密切相关。此外,食管高分辨率测压结果也提示LES压力无效,食管无效蠕动增加了症状的复杂性。
|
||||
从症状相关性分析来看,咳嗽和喘息症状与弱酸反流有较高的相关性,虽然达到24%和40%的相关性,但尚需结合患者的具体症状表现,考虑更优的治疗方案。
|
||||
因此,建议继续优化PPI治疗,控制酸反流问题,同时针对患者酸反流诱发的咳嗽症状制定措施。可以考虑在现有PPI基础上,进一步延长卧位酸清除时间,或者结合使用止咳药物来改善生活质量。在方案实施过程中需密切监测症状改善情况,必要时进行调整。
|
||||
```
|
||||
|
||||
模型去除<think>返回结果:
|
||||
|
||||
```
|
||||
从病人的病史、体格检查和辅助检查结果来看,这位病人患有较为复杂的消化系统和呼吸系统疾病,我们需要综合分析这些信息,以更好地理解她的病情和制定治疗方案。
|
||||
---
|
||||
### 一、病史分析
|
||||
病人自30年前开始出现胃酸相关症状,如反酸、反食、烧心,这些症状与胃泌素分泌过多有关。虽然她一直使用“奥美拉唑"等质子泵抑制剂治疗这些症状,但症状在停药后反复发作,这进一步支持了反流性食管炎的诊断。
|
||||
在过去的5年内,病人开始出现咳嗽和咳痰的症状,且发作时常伴有胸闷、喘息,显然影响了她的生活质量。虽然止咳平喘药物效果不佳,但咳嗽和喘息的症状与她的反流情况有明显相关性。
|
||||
在2年前,病人在外院曾出现咳喘症状明显改善,通过调整上消化道药物和调整睡眠体位,反流症状明显缓解。这表明通过纠正反流因素,咳喘症状得到了一些改善。
|
||||
近10个月来,病人咳喘症状加重,同时伴有听力下降,尽管在调整耐信(一种丙戊酸钠)剂量后,咳喘症状再次获得一定程度的缓解。
|
||||
---
|
||||
### 二、体格检查
|
||||
病人呈自主体位,生命体征为:T36.8℃,P70次/分,R20次/分,Bp136/80mmHg,神志清醒,未闻及病理杂音,呼吸有粗略声和散在哮鸣音。
|
||||
这些体征提示病人有呼吸系统不适,但并未见明显的严重呼吸障碍。
|
||||
---
|
||||
### 三、辅助检查
|
||||
#### (1)实验室检查
|
||||
实验室检查结果均在正常范围内,这排除了凝血功能和一般全身炎症指标的异常。
|
||||
---
|
||||
#### (2)胃镜检查
|
||||
胃镜检查明确诊断病人患有反流性食管炎,且存在食管裂孔疝,且为混合型疝。齿状线上移约4cm,伴有糜烂,提示胃黏膜的损害。
|
||||
---
|
||||
#### (3)上消化道造影
|
||||
造影结果同样提示有巨大食管裂孔疝,贲门和胃底疝入胸腔,进一步证实食管裂孔疝的存在。
|
||||
---
|
||||
#### (4)食管pH-阻抗监测
|
||||
- **pH监测**显示,DeMeester积分小于正常,说明胃酸反流的可能性较大;睡眠时酸反流时间百分比大于正常。
|
||||
- **食管阻抗监测**显示,立位时食团反流总次数大于正常,食管裂孔疝也是原因之一。反流总次数为48次(正常值<73次),其中32次为酸反流,表明频繁的胃内容反流是导致病人症状加重的原因之一。
|
||||
---
|
||||
#### (5)食管高分辨率测压(LES和1.5 MHz)
|
||||
- **LES(食管酸刺激)压力监测**显示压力低于正常,无效蠕动频繁,提示酸刺激频繁且影响较广。
|
||||
- **症状相关性分析**显示:
|
||||
- 咳嗽症状共记录17次,与弱酸反流相关4次。SI(反流/症状指数)为24%、SAP(反流/症状相关概率)为99%。这表明咳嗽症状与较弱的胃酸反流相关。
|
||||
- 喀息症状共记录5次,与弱酸反流相关2次。SI为40%,SAP为96%。这说明喘息症状与较弱的胃酸反流也有一定的相关性。
|
||||
---
|
||||
综上所述,病人的诊断高度疑似反流性食管炎伴食管裂孔疝。治疗上,首先需通过手术纠正食管裂孔疝,以彻底解决她的反流问题。在手术前后,使用质子泵抑制剂(如PPI)和适当管理反流诱发症状的药物将是当前的主要治疗策略。
|
||||
在质子泵抑制剂的使用期间,病人应密切监测食管反流诱发的症状,并在症状相关的情况下,考虑食管高分辨率测压等进一步的精准评估。
|
||||
通过综合管理,期望能有效改善病人的生活质量。
|
||||
```
|
||||
|
||||
|
||||
参考结果
|
||||
|
||||
```
|
||||
(1)病史分析:该病例的早期症状为反酸、反食、烧心,胸骨后烧灼感、嗳气等典型胃食管反流症状为主,抗反流用药治疗可缓解症状,即可诊断为胃食管反流病。之后患者逐渐出现咳嗽、咳痰和喘息等哮喘样症状,该症状呼吸内科治疗效果不佳,再进行抗反流治疗后不但反酸、烧心得到明显缓解,而且哮喘样症状也得到明显缓解。
|
||||
本病例特点为:①先出现典型胃食管反流病症状,后出现咳嗽、喘息等食管外症状;②抗反流药物治疗可同时缓解反酸、烧心以及咳喘症状。
|
||||
(2)体格检查分析:体格检查方面此病例在咳喘发作间期无过多的阳性体征,肺部听诊可闻及哮鸣音。
|
||||
(3)辅助检查分析:本例病人实验室检查无明显异常。通过胃镜、上消化道造影、食管高分辨率测压检查明确患者存在食管裂孔疝和反流性食管炎,食管pH-阻抗检查(口服PPI期间)进一步证实患者的咳嗽和喘息症状均与反流有显著相关性。上述客观检查确诊患者为胃食管反流病,反流性哮喘可能性大。
|
||||
```
|
||||
|
||||
|
||||
|
||||
## 许可证
|
||||
|
||||
本项目采用 [MIT 许可证](LICENSE)。
|
||||
|
||||
## 致谢
|
||||
|
||||
- 感谢 `Qwen` 模型的开发者。
|
||||
- 感谢所有为医疗知识问答数据集做出贡献的研究人员。
|
||||
|
||||
## 联系方式
|
||||
|
||||
如有任何问题,请联系 [592392714@qq.com]。
|
||||
|
||||
---
|
||||
|
||||
**注意**: 本项目仅供学术研究使用,不构成医疗建议。
|
||||
28
added_tokens.json
Normal file
28
added_tokens.json
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"</think>": 151668,
|
||||
"</tool_call>": 151658,
|
||||
"</tool_response>": 151666,
|
||||
"<think>": 151667,
|
||||
"<tool_call>": 151657,
|
||||
"<tool_response>": 151665,
|
||||
"<|box_end|>": 151649,
|
||||
"<|box_start|>": 151648,
|
||||
"<|endoftext|>": 151643,
|
||||
"<|file_sep|>": 151664,
|
||||
"<|fim_middle|>": 151660,
|
||||
"<|fim_pad|>": 151662,
|
||||
"<|fim_prefix|>": 151659,
|
||||
"<|fim_suffix|>": 151661,
|
||||
"<|im_end|>": 151645,
|
||||
"<|im_start|>": 151644,
|
||||
"<|image_pad|>": 151655,
|
||||
"<|object_ref_end|>": 151647,
|
||||
"<|object_ref_start|>": 151646,
|
||||
"<|quad_end|>": 151651,
|
||||
"<|quad_start|>": 151650,
|
||||
"<|repo_name|>": 151663,
|
||||
"<|video_pad|>": 151656,
|
||||
"<|vision_end|>": 151653,
|
||||
"<|vision_pad|>": 151654,
|
||||
"<|vision_start|>": 151652
|
||||
}
|
||||
30
config.json
Normal file
30
config.json
Normal file
@@ -0,0 +1,30 @@
|
||||
{
|
||||
"architectures": [
|
||||
"Qwen3ForCausalLM"
|
||||
],
|
||||
"attention_bias": false,
|
||||
"attention_dropout": 0.0,
|
||||
"bos_token_id": 151643,
|
||||
"eos_token_id": 151645,
|
||||
"head_dim": 128,
|
||||
"hidden_act": "silu",
|
||||
"hidden_size": 2048,
|
||||
"initializer_range": 0.02,
|
||||
"intermediate_size": 6144,
|
||||
"max_position_embeddings": 40960,
|
||||
"max_window_layers": 28,
|
||||
"model_type": "qwen3",
|
||||
"num_attention_heads": 16,
|
||||
"num_hidden_layers": 28,
|
||||
"num_key_value_heads": 8,
|
||||
"rms_norm_eps": 1e-06,
|
||||
"rope_scaling": null,
|
||||
"rope_theta": 1000000,
|
||||
"sliding_window": null,
|
||||
"tie_word_embeddings": true,
|
||||
"torch_dtype": "bfloat16",
|
||||
"transformers_version": "4.51.3",
|
||||
"use_cache": true,
|
||||
"use_sliding_window": false,
|
||||
"vocab_size": 151936
|
||||
}
|
||||
1
configuration.json
Normal file
1
configuration.json
Normal file
@@ -0,0 +1 @@
|
||||
{"task":"text-generation"}
|
||||
13
generation_config.json
Normal file
13
generation_config.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"bos_token_id": 151643,
|
||||
"do_sample": true,
|
||||
"eos_token_id": [
|
||||
151645,
|
||||
151643
|
||||
],
|
||||
"pad_token_id": 151643,
|
||||
"temperature": 0.6,
|
||||
"top_k": 20,
|
||||
"top_p": 0.95,
|
||||
"transformers_version": "4.51.3"
|
||||
}
|
||||
151388
merges.txt
Normal file
151388
merges.txt
Normal file
File diff suppressed because it is too large
Load Diff
3
model-00001-of-00002.safetensors
Normal file
3
model-00001-of-00002.safetensors
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:50464e7745e8b8d25a6bdb0d20a865db6c2ab067b5ebee7426bc36700eacb64b
|
||||
size 1981415312
|
||||
3
model-00002-of-00002.safetensors
Normal file
3
model-00002-of-00002.safetensors
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:093b82f57fd5e4c1d00cabdcd6a4701cc0b160ec49d477f223473380371b0379
|
||||
size 1459770104
|
||||
317
model.safetensors.index.json
Normal file
317
model.safetensors.index.json
Normal file
@@ -0,0 +1,317 @@
|
||||
{
|
||||
"metadata": {
|
||||
"total_size": 3441149952
|
||||
},
|
||||
"weight_map": {
|
||||
"model.embed_tokens.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.0.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.1.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.10.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.11.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.12.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.13.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.13.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.13.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.13.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.14.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.14.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.15.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.16.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.17.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.18.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.19.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.2.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.2.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.20.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.20.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.21.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.22.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.23.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.24.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.25.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.26.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.input_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.mlp.down_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.mlp.gate_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.mlp.up_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.post_attention_layernorm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.k_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.k_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.o_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.q_norm.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.q_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.27.self_attn.v_proj.weight": "model-00002-of-00002.safetensors",
|
||||
"model.layers.3.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.3.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.4.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.5.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.6.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.7.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.8.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.input_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.mlp.down_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.mlp.gate_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.mlp.up_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.post_attention_layernorm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.k_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.k_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.o_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.q_norm.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.q_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.layers.9.self_attn.v_proj.weight": "model-00001-of-00002.safetensors",
|
||||
"model.norm.weight": "model-00002-of-00002.safetensors"
|
||||
}
|
||||
}
|
||||
31
special_tokens_map.json
Normal file
31
special_tokens_map.json
Normal file
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"additional_special_tokens": [
|
||||
"<|im_start|>",
|
||||
"<|im_end|>",
|
||||
"<|object_ref_start|>",
|
||||
"<|object_ref_end|>",
|
||||
"<|box_start|>",
|
||||
"<|box_end|>",
|
||||
"<|quad_start|>",
|
||||
"<|quad_end|>",
|
||||
"<|vision_start|>",
|
||||
"<|vision_end|>",
|
||||
"<|vision_pad|>",
|
||||
"<|image_pad|>",
|
||||
"<|video_pad|>"
|
||||
],
|
||||
"eos_token": {
|
||||
"content": "<|im_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false
|
||||
},
|
||||
"pad_token": {
|
||||
"content": "<|endoftext|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false
|
||||
}
|
||||
}
|
||||
757480
tokenizer.json
Normal file
757480
tokenizer.json
Normal file
File diff suppressed because it is too large
Load Diff
241
tokenizer_config.json
Normal file
241
tokenizer_config.json
Normal file
@@ -0,0 +1,241 @@
|
||||
{
|
||||
"add_bos_token": false,
|
||||
"add_prefix_space": false,
|
||||
"added_tokens_decoder": {
|
||||
"151643": {
|
||||
"content": "<|endoftext|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151644": {
|
||||
"content": "<|im_start|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151645": {
|
||||
"content": "<|im_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151646": {
|
||||
"content": "<|object_ref_start|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151647": {
|
||||
"content": "<|object_ref_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151648": {
|
||||
"content": "<|box_start|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151649": {
|
||||
"content": "<|box_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151650": {
|
||||
"content": "<|quad_start|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151651": {
|
||||
"content": "<|quad_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151652": {
|
||||
"content": "<|vision_start|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151653": {
|
||||
"content": "<|vision_end|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151654": {
|
||||
"content": "<|vision_pad|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151655": {
|
||||
"content": "<|image_pad|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151656": {
|
||||
"content": "<|video_pad|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": true
|
||||
},
|
||||
"151657": {
|
||||
"content": "<tool_call>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151658": {
|
||||
"content": "</tool_call>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151659": {
|
||||
"content": "<|fim_prefix|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151660": {
|
||||
"content": "<|fim_middle|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151661": {
|
||||
"content": "<|fim_suffix|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151662": {
|
||||
"content": "<|fim_pad|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151663": {
|
||||
"content": "<|repo_name|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151664": {
|
||||
"content": "<|file_sep|>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151665": {
|
||||
"content": "<tool_response>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151666": {
|
||||
"content": "</tool_response>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151667": {
|
||||
"content": "<think>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
},
|
||||
"151668": {
|
||||
"content": "</think>",
|
||||
"lstrip": false,
|
||||
"normalized": false,
|
||||
"rstrip": false,
|
||||
"single_word": false,
|
||||
"special": false
|
||||
}
|
||||
},
|
||||
"additional_special_tokens": [
|
||||
"<|im_start|>",
|
||||
"<|im_end|>",
|
||||
"<|object_ref_start|>",
|
||||
"<|object_ref_end|>",
|
||||
"<|box_start|>",
|
||||
"<|box_end|>",
|
||||
"<|quad_start|>",
|
||||
"<|quad_end|>",
|
||||
"<|vision_start|>",
|
||||
"<|vision_end|>",
|
||||
"<|vision_pad|>",
|
||||
"<|image_pad|>",
|
||||
"<|video_pad|>"
|
||||
],
|
||||
"bos_token": null,
|
||||
"chat_template": "{%- if tools %}\n {{- '<|im_start|>system\\n' }}\n {%- if messages[0].role == 'system' %}\n {{- messages[0].content + '\\n\\n' }}\n {%- endif %}\n {{- \"# Tools\\n\\nYou may call one or more functions to assist with the user query.\\n\\nYou are provided with function signatures within <tools></tools> XML tags:\\n<tools>\" }}\n {%- for tool in tools %}\n {{- \"\\n\" }}\n {{- tool | tojson }}\n {%- endfor %}\n {{- \"\\n</tools>\\n\\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\\n<tool_call>\\n{\\\"name\\\": <function-name>, \\\"arguments\\\": <args-json-object>}\\n</tool_call><|im_end|>\\n\" }}\n{%- else %}\n {%- if messages[0].role == 'system' %}\n {{- '<|im_start|>system\\n' + messages[0].content + '<|im_end|>\\n' }}\n {%- endif %}\n{%- endif %}\n{%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}\n{%- for message in messages[::-1] %}\n {%- set index = (messages|length - 1) - loop.index0 %}\n {%- if ns.multi_step_tool and message.role == \"user\" and not(message.content.startswith('<tool_response>') and message.content.endswith('</tool_response>')) %}\n {%- set ns.multi_step_tool = false %}\n {%- set ns.last_query_index = index %}\n {%- endif %}\n{%- endfor %}\n{%- for message in messages %}\n {%- if (message.role == \"user\") or (message.role == \"system\" and not loop.first) %}\n {{- '<|im_start|>' + message.role + '\\n' + message.content + '<|im_end|>' + '\\n' }}\n {%- elif message.role == \"assistant\" %}\n {%- set content = message.content %}\n {%- set reasoning_content = '' %}\n {%- if message.reasoning_content is defined and message.reasoning_content is not none %}\n {%- set reasoning_content = message.reasoning_content %}\n {%- else %}\n {%- if '</think>' in message.content %}\n {%- set content = message.content.split('</think>')[-1].lstrip('\\n') %}\n {%- set reasoning_content = message.content.split('</think>')[0].rstrip('\\n').split('<think>')[-1].lstrip('\\n') %}\n {%- endif %}\n {%- endif %}\n {%- if loop.index0 > ns.last_query_index %}\n {%- if loop.last or (not loop.last and reasoning_content) %}\n {{- '<|im_start|>' + message.role + '\\n<think>\\n' + reasoning_content.strip('\\n') + '\\n</think>\\n\\n' + content.lstrip('\\n') }}\n {%- else %}\n {{- '<|im_start|>' + message.role + '\\n' + content }}\n {%- endif %}\n {%- else %}\n {{- '<|im_start|>' + message.role + '\\n' + content }}\n {%- endif %}\n {%- if message.tool_calls %}\n {%- for tool_call in message.tool_calls %}\n {%- if (loop.first and content) or (not loop.first) %}\n {{- '\\n' }}\n {%- endif %}\n {%- if tool_call.function %}\n {%- set tool_call = tool_call.function %}\n {%- endif %}\n {{- '<tool_call>\\n{\"name\": \"' }}\n {{- tool_call.name }}\n {{- '\", \"arguments\": ' }}\n {%- if tool_call.arguments is string %}\n {{- tool_call.arguments }}\n {%- else %}\n {{- tool_call.arguments | tojson }}\n {%- endif %}\n {{- '}\\n</tool_call>' }}\n {%- endfor %}\n {%- endif %}\n {{- '<|im_end|>\\n' }}\n {%- elif message.role == \"tool\" %}\n {%- if loop.first or (messages[loop.index0 - 1].role != \"tool\") %}\n {{- '<|im_start|>user' }}\n {%- endif %}\n {{- '\\n<tool_response>\\n' }}\n {{- message.content }}\n {{- '\\n</tool_response>' }}\n {%- if loop.last or (messages[loop.index0 + 1].role != \"tool\") %}\n {{- '<|im_end|>\\n' }}\n {%- endif %}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|im_start|>assistant\\n' }}\n {%- if enable_thinking is defined and enable_thinking is false %}\n {{- '<think>\\n\\n</think>\\n\\n' }}\n {%- endif %}\n{%- endif %}",
|
||||
"clean_up_tokenization_spaces": false,
|
||||
"eos_token": "<|im_end|>",
|
||||
"errors": "replace",
|
||||
"extra_special_tokens": {},
|
||||
"model_max_length": 131072,
|
||||
"pad_token": "<|endoftext|>",
|
||||
"padding_side": "left",
|
||||
"split_special_tokens": false,
|
||||
"tokenizer_class": "Qwen2Tokenizer",
|
||||
"unk_token": null
|
||||
}
|
||||
1
vocab.json
Normal file
1
vocab.json
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user