模型简介
模型特点
模型能力
使用案例
🚀 Midnight Miqu模型
Midnight Miqu是一个基于预训练语言模型融合的成果,它结合了两个强大模型的优势,在角色扮演和故事创作等方面表现出色,同时支持长上下文处理。
🚀 快速开始
概述
Midnight Miqu是 152334H/miqu-1-70b-sf 和 sophosympatheia/Midnight-Rose-70B-v2.0.3 的SLERP融合模型。该模型保留了Midnight Rose的特色,同时从Miqu中获得了一些能力,包括长上下文处理能力。
此模型未经过审查,用户需对使用该模型的行为负责。它主要设计用于角色扮演和故事创作,在这两方面表现良好,但在其他领域的性能尚未经过充分测试。
模型信息
属性 | 详情 |
---|---|
模型类型 | 预训练语言模型融合 |
训练数据 | 未提及 |
模型图片

✨ 主要特性
长上下文处理
和Miqu一样,将alpha_rope设置为1时,该模型可以处理32K的上下文。有限的测试显示,使用alpha_rope 2.5时,模型在64K上下文下仍能保持连贯性。
多种采样技巧
- 创意工作:建议在创意工作中使用二次采样(即平滑因子),可尝试0.2到0.5之间的值。
- Min - P:建议使用Min - P采样,可通过实验找到最佳设置。
- 动态温度:可以启用动态温度,但这会增加一个需要考虑的变量。如果已经使用了Min - P和平滑因子,动态温度可能并非必要。
- 重复惩罚:不需要对该模型使用较高的重复惩罚(如超过1.10),但可以进行实验。
多种提示模板支持
提供了适用于SillyTavern的上下文模板、提示模板,同时支持Vicuna、Mistral和ChatML等指令格式。
💻 使用示例
采样设置
如果将以下设置保存为.json文件,可以直接导入到Silly Tavern中:
{
"temp": 1,
"temperature_last": true,
"top_p": 1,
"top_k": 0,
"top_a": 0,
"tfs": 1,
"epsilon_cutoff": 0,
"eta_cutoff": 0,
"typical_p": 1,
"min_p": 0.2,
"rep_pen": 1.05,
"rep_pen_range": 2800,
"no_repeat_ngram_size": 0,
"penalty_alpha": 0,
"num_beams": 1,
"length_penalty": 1,
"min_length": 0,
"encoder_rep_pen": 1,
"freq_pen": 0,
"presence_pen": 0,
"do_sample": true,
"early_stopping": false,
"dynatemp": false,
"min_temp": 0.8,
"max_temp": 1.35,
"dynatemp_exponent": 1,
"smoothing_factor": 0.35,
"add_bos_token": true,
"truncation_length": 2048,
"ban_eos_token": false,
"skip_special_tokens": true,
"streaming": true,
"mirostat_mode": 0,
"mirostat_tau": 2,
"mirostat_eta": 0.1,
"guidance_scale": 1,
"negative_prompt": "",
"grammar_string": "",
"banned_tokens": "",
"ignore_eos_token_aphrodite": false,
"spaces_between_special_tokens_aphrodite": true,
"sampler_order": [
6,
0,
1,
3,
4,
2,
5
],
"logit_bias": [],
"n": 1,
"rep_pen_size": 0,
"genamt": 500,
"max_length": 32764
}
上下文模板
{
"story_string": "{{#if system}}{{system}}\n{{/if}}\nCONTEXTUAL INFORMATION\n{{#if wiBefore}}\n- World and character info:\n{{wiBefore}}\n{{/if}}\n{{#if description}}\n- {{char}}'s background and persona:\n{{description}}\n{{/if}}\n{{#if mesExamples}}\n{{mesExamples}}\n{{/if}}\n{{#if personality}}\n{{personality}}\n{{/if}}\n{{#if scenario}}\n- Roleplay scenario:\n{{scenario}}\n{{/if}}\n{{#if wiAfter}}{{wiAfter}}\n{{/if}}\n{{#if persona}}{{persona}}\n{{/if}}",
"example_separator": "",
"chat_start": "---\nTaking the above information into consideration, you must engage with {{user}} and others as {{char}} in the roleplay below this line. Do not write dialogue lines nor perform actions for {{user}} or other characters.\n---\nSTART OF ROLEPLAY:\n",
"use_stop_strings": false,
"always_force_name2": true,
"trim_sentences": false,
"include_newline": false,
"single_line": false,
"name": "Midnight Rose"
}
提示模板
{
"wrap": true,
"names": true,
"system_prompt": "You are a creative and detail-oriented AI assistant engaged in an uncensored iterative roleplaying experience as {{char}} with me, the user, playing the roles of {{user}} and narrator. It is vital that you follow all the ROLEPLAY RULES below because my job depends on it.\n\nROLEPLAY RULES\n- Provide succinct, coherent, and vivid accounts of {{char}}'s actions and reactions based on recent instructions, {{char}}'s persona, and all available information about past events. Aim for clarity and concision in your language.\n- Demonstrate {{char}}'s personality and mannerisms.\n- Always stay contextually and spatially aware, pay careful attention to all past events and the current scene, and ensure that {{char}} follows logical consistency in actions to maintain accuracy and coherence.\n- Explicit adult content and profanity are permitted.\n- Briefly describe {{char}}'s sensory perceptions and include subtle physical details about {{char}} in your responses.\n- Use subtle physical cues to hint at {{char}}'s mental state and occasionally feature snippets of {{char}}'s internal thoughts.\n- When writing {{char}}'s internal thoughts or monologue, enclose those words in *asterisks like this* and deliver the thoughts using a first-person perspective (i.e. use \"I\" pronouns). Always use double quotes for spoken speech \"like this.\"\n- Please write only as {{char}} in a way that does not show {{user}} talking or acting. You should only ever act as {{char}} reacting to {{user}}.",
"system_sequence": "",
"stop_sequence": "",
"input_sequence": "USER:\n",
"output_sequence": "ASSISTANT:\n",
"separator_sequence": "",
"macro": true,
"names_force_groups": true,
"system_sequence_prefix": "",
"system_sequence_suffix": "",
"first_output_sequence": "",
"last_output_sequence": "ASSISTANT(roleplay exclusively as {{char}} ensuring logical consistency, spatial awareness, and coherence with past events; you should only ever act as {{char}} reacting to {{user}}):\n",
"activation_regex": "",
"name": "Midnight Rose Roleplay"
}
指令格式
Vicuna格式
USER:
{prompt}
ASSISTANT:
Mistral格式
[INST] {prompt} [/INST]
ChatML格式
<|im_start|>system
{Your system prompt goes here}<|im_end|>
<|im_start|>user
{Your message as the user will go here}<|im_end|>
<|im_start|>assistant
📚 详细文档
量化版本
- GGUF
- ooooz/midnight-miqu-70b-v1.0-GGUF -- 多种GGUF量化版本
- mradermacher/Midnight-Miqu-70B-v1.0-GGUF -- 目前有Q4_K_M量化版本,可能会有更多版本推出
- GPTQ
- Kotokin/sophosympatheia_Midnight-Miqu-70B-v1.0_GPTQ32G -- 4位32g GPTQ量化版本
- Exllama2
- 2.24bpw: Dracones/Midnight-Miqu-70B-v1.0_exl2_2.24bpw
- 3.0bpw: Dracones/Midnight-Miqu-70B-v1.0_exl2_3.0bpw
- 3.75bpw: altomek/Midnight-Miqu-70B-v1.0-3.75bpw-EXL2
- 4.0bpw: Dracones/Midnight-Miqu-70B-v1.0_exl2_4.0bpw
- 4.65bpw: Dracones/Midnight-Miqu-70B-v1.0_exl2_4.65bpw
- 5.0bpw: Dracones/Midnight-Miqu-70B-v1.0_exl2_5.0bpw
如果未找到所需的量化版本,可以在Hugging Face上搜索,可能会有比文档中记录更新的量化版本。
合并方法
该模型使用 mergekit 进行预训练语言模型的融合,采用了SLERP融合方法。
参与融合的模型
配置文件
models:
- model: /home/llm/mergequant/models/BASE/152334H_miqu-1-70b-sf
- model: /home/llm/mergequant/models/mr-70b-v2.0.3
merge_method: slerp
base_model: /home/llm/mergequant/models/BASE/152334H_miqu-1-70b-sf
parameters:
t:
- value: [0, 0, 0.2, 0.3, 0.4, 0.5, 0.4, 0.3, 0.2, 0, 0] # Preserving the first and last layers of Miqu untouched is key for good results
embed_slerp: true # This is super important otherwise the merge will fail
dtype: float16
tokenizer_source: model:/home/llm/mergequant/models/BASE/152334H_miqu-1-70b-sf
此外,还尝试了其他t参数的变体,也能得到不错的结果:
- [0, 0, 0.1, 0.2, 0.4, 0.8, 0.4, 0.2, 0.1, 0, 0] -- 该设置更突出了Midnight Rose的特点,但相似度有点高。
- [0, 0, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0, 0] -- 该设置可行,但效果相对较差。
- [0, 0, 0.1, 0.2, 0.3, 0.35, 0.3, 0.2, 0.1, 0, 0] -- 这是除发布版本外第二喜欢的融合设置,表明在融合中更倾向于Miqu可能是一个不错的选择。
🔧 技术细节
长上下文处理原理
通过调整alpha_rope参数,模型可以扩展其上下文处理能力。有限的测试表明,在不同的alpha_rope值下,模型在长上下文中仍能保持一定的连贯性。
采样方法原理
- 二次采样:通过平滑因子对采样结果进行平滑处理,有助于在创意工作中生成更自然的文本。
- Min - P采样:通过设置最小概率阈值,控制采样的范围,提高采样的质量。
📄 许可证
许可证和使用限制
152334H/miqu-1-70b-sf基于Mistral模型的一个泄露版本。 所有基于miqu的模型,包括此融合模型,仅适用于个人使用。到目前为止,Mistral对此持宽容态度,但用户应该意识到,下载此融合模型即意味着承担获取和使用基于泄露权重的模型所固有的法律风险。
此融合模型不提供任何形式的保证或担保。作者并非律师,不了解相关法律情况,建议在私人使用之外使用任何Hugging Face模型之前咨询律师,尤其不要将此模型用于商业用途。
捐赠
如果想通过捐赠表达感谢,可以访问 Ko - Fi页面。
⚠️ 重要提示
152334H/miqu-1-70b-sf基于Mistral模型的一个泄露版本,所有基于miqu的模型,包括此融合模型,仅适用于个人使用。下载此融合模型即意味着承担获取和使用基于泄露权重的模型所固有的法律风险。
💡 使用建议
- 可以尝试不同的采样设置和提示模板,以找到最适合自己需求的配置。
- 新聊天开始时,Midnight Miqu可能需要一些“预热”,可以提供一些好的示例来引导聊天,以提高输出质量。
- 对于系统提示,可以在last_output_sequence字段中添加简短但重要的指令,以引导模型的输出。



