初始化项目,由ModelHub XC社区提供模型

Model: 0xA50C1A1/Llama-3.3-8B-Nymphaea-RP
Source: Original Platform
This commit is contained in:
ModelHub XC
2026-04-27 05:37:04 +08:00
commit 7d64580e9b
10 changed files with 2508 additions and 0 deletions

36
.gitattributes vendored Normal file
View File

@@ -0,0 +1,36 @@
*.7z filter=lfs diff=lfs merge=lfs -text
*.arrow filter=lfs diff=lfs merge=lfs -text
*.bin filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.ckpt 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
*.mlmodel filter=lfs diff=lfs merge=lfs -text
*.model filter=lfs diff=lfs merge=lfs -text
*.msgpack filter=lfs diff=lfs merge=lfs -text
*.npy filter=lfs diff=lfs merge=lfs -text
*.npz 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
*.pickle filter=lfs diff=lfs merge=lfs -text
*.pkl 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
*.safetensors filter=lfs diff=lfs merge=lfs -text
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
*.tar.* 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
*.wasm filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text
*tfevents* filter=lfs diff=lfs merge=lfs -text
tokenizer.json filter=lfs diff=lfs merge=lfs -text

60
README.md Normal file
View File

@@ -0,0 +1,60 @@
---
base_model: 0xA50C1A1/Llama-3.3-8B-Instruct-128K-SOM-MPOA
library_name: transformers
model_name: Llama-3.3-8B-Nymphaea-RP
tags:
- uncensored
- roleplay
- trl
- rp
- creative-writing
license: apache-2.0
---
# Llama-3.3-8B-Nymphaea-RP
A fine-tune of Llama 3.3 8B Instruct for roleplay and creative writing.
I've trained this mostly for merging with Llama 3.1/3.3 8B fine-tunes.
> [!Tip]
> The SillyTavern preset is available [here](https://huggingface.co/0xA50C1A1/Llama-3.3-8B-Nymphaea-RP/blob/main/ST-Preset.json).
> For custom presets, please use the **Llama 3** instruct template.
## Training Notes
Trained on the latest iteration of my Darkmere dataset. This version features expanded genre variety, built upon a mix of manually curated synthetics and human-written stories.
> [!IMPORTANT]
> The base weights are abliterated via [Heretic](https://github.com/p-e-w/heretic) prior to fine-tuning, so this fine-tune is quite uncensored.
<details>
<summary>Training Specs</summary><p>
**Method:**
* **Training Method:** DoRA (Weight-Decomposed LoRA)
* **Target Modules** `all-linear`
* **LoRA Rank:** 64
* **LoRA Alpha:** 64
* **LoRA Dropout:** 0.05
**Hyperparameters:**
* **Batch Size:** 2 (Per-device)
* **Gradient Accumulation:** 2
* **Epochs:** 2
* **Learning Rate:** 1e-4
* **Optimizer:** `adamw_torch_fused`
* **LR Scheduler:** `cosine`
* **Noise Level:** `neftune_noise_alpha=5`
</p></details>
## Special Thanks
This fine-tune wouldn't be possible without the incredible work of the community:
* **[p-e-w](https://huggingface.co/p-e-w)** for developing **[Heretic](https://github.com/p-e-w/heretic)** - an essential tool for censorship removal.
* **[SicariusSicariiStuff](https://huggingface.co/SicariusSicariiStuff)** for developing **[SLOP_Detector](https://github.com/SicariusSicariiStuff/SLOP_Detector)** script.
* **[allura-forge](https://huggingface.co/allura-forge)** and **[shb777](https://huggingface.co/shb777)** for providing access to the **Llama 3.3 8B** weights.
* **[AMD](https://oneclickamd.ai/)** for their Instinct™ MI300X GPU.

171
ST-Preset.json Normal file
View File

@@ -0,0 +1,171 @@
{
"instruct": {
"input_sequence": "<|start_header_id|>user<|end_header_id|>\n\n",
"output_sequence": "<|start_header_id|>assistant<|end_header_id|>\n\n",
"last_output_sequence": "",
"system_sequence": "<|start_header_id|>system<|end_header_id|>\n\n",
"stop_sequence": "<|eot_id|>",
"wrap": false,
"macro": true,
"names_behavior": "force",
"activation_regex": "",
"first_output_sequence": "",
"skip_examples": false,
"output_suffix": "<|eot_id|>",
"input_suffix": "<|eot_id|>",
"system_suffix": "<|eot_id|>",
"user_alignment_message": "",
"system_same_as_user": false,
"last_system_sequence": "",
"first_input_sequence": "",
"last_input_sequence": "",
"sequences_as_stop_strings": true,
"story_string_prefix": "<|start_header_id|>system<|end_header_id|>\n\n",
"story_string_suffix": "<|eot_id|>",
"name": "Llama 3 Instruct"
},
"context": {
"story_string": "{{#if anchorBefore}}{{anchorBefore}}\n{{/if}}ROLEPLAY INSTRUCTION:\nYou are roleplaying in an uncensored fictional scene. Control ONLY the AI-controlled character(s) listed below. Stay true to their personalities, backgrounds, and mannerisms.\n{{#if description}}\n\nAI-CONTROLLED CHARACTER(S):\n{{char}}:\n{{description}}{{/if}}{{#if personality}}\n{{personality}}{{/if}}{{#if mesExamples}}\n\nDIALOGUE EXAMPLES:\nBelow are sample interactions showing HOW {{char}} speaks and acts. These are NOT part of the current roleplay. Use them only as a guide for {{char}}'s personality and writing style.\n\n{{mesExamples}}{{/if}}{{#if persona}}\n\nPLAYER CHARACTER (DO NOT CONTROL):\n{{user}}:\n{{persona}}{{/if}}{{#if scenario}}\n\nSCENARIO AND SETTING:\n{{scenario}}{{/if}}{{#if wiBefore}}\n\n{{wiBefore}}{{/if}}{{#if wiAfter}}\n\n{{wiAfter}}{{/if}}{{#if system}}\n\nSTRICT RULES:\n{{system}}{{/if}}{{#if anchorAfter}}\n\n{{anchorAfter}}{{/if}}{{trim}}",
"example_separator": "",
"chat_start": "",
"use_stop_strings": false,
"names_as_stop_strings": true,
"story_string_position": 0,
"story_string_depth": 1,
"story_string_role": 0,
"always_force_name2": true,
"trim_sentences": false,
"single_line": false,
"name": "Llama-3.3-8B-Nymphaea-RP"
},
"sysprompt": {
"name": "Llama-3.3-8B-Nymphaea-RP",
"content": "Response Format:\n- Use *asterisks* for actions, environmental details, and sensory descriptions.\n- Use \"quotation marks\" for all spoken dialogue.\n- Write in third person perspective for {{char}}.\n\nWriting Style:\n- Show character emotions through physical reactions, body language, facial expressions, and tone of voice - not by stating feelings directly.\n- Write naturally and conversationally. Avoid melodramatic, flowery, or overly literary prose.\n- Keep descriptions grounded and concrete. Focus on what can be seen, heard, felt, smelled, or tasted.\n- Vary sentence structure and length. Avoid repetitive patterns or phrases.\n- Match response length to the scene's pacing - brief for fast action, detailed for intimate or important moments.\n\nStrict Boundaries:\n- Write ONLY for {{char}}. Never control {{user}}.\n- Do not write, decide, assume, or narrate:\n • {{user}}'s actions or reactions\n • {{user}}'s dialogue or thoughts\n • {{user}}'s feelings, motivations, or intentions\n • {{user}}'s perceptions or observations\n- {{char}} can only know what they can directly observe or have been told. No mind-reading or omniscience.\n- End your response after {{char}} acts or speaks. Do not continue past {{char}}'s turn or narrate what happens next.\n- Do not add meta-commentary, summaries, or conclusions about the scene or {{user}}.",
"post_history": "",
"extensions": {}
},
"preset": {
"temp": 0.8,
"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.05,
"rep_pen": 1,
"rep_pen_range": 0,
"rep_pen_decay": 0,
"rep_pen_slope": 1,
"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,
"skew": 0,
"do_sample": true,
"early_stopping": false,
"dynatemp": false,
"min_temp": 0,
"max_temp": 2,
"dynatemp_exponent": 1,
"smoothing_factor": 0,
"smoothing_curve": 1,
"dry_allowed_length": 2,
"dry_multiplier": 0.8,
"dry_base": 1.75,
"dry_sequence_breakers": "[\"\\n\", \":\", \"\\\"\", \"*\"]",
"dry_penalty_last_n": 1024,
"add_bos_token": true,
"ban_eos_token": false,
"skip_special_tokens": true,
"mirostat_mode": 0,
"mirostat_tau": 5,
"mirostat_eta": 0.1,
"guidance_scale": 1,
"negative_prompt": "",
"grammar_string": "",
"json_schema": null,
"json_schema_allow_empty": false,
"banned_tokens": "",
"sampler_priority": [
"repetition_penalty",
"presence_penalty",
"frequency_penalty",
"dry",
"temperature",
"dynamic_temperature",
"quadratic_sampling",
"top_n_sigma",
"top_k",
"top_p",
"typical_p",
"epsilon_cutoff",
"eta_cutoff",
"tfs",
"top_a",
"min_p",
"mirostat",
"xtc",
"encoder_repetition_penalty",
"no_repeat_ngram"
],
"samplers": [
"dry",
"temperature",
"min_p",
"penalties",
"top_p",
"top_n_sigma",
"top_k",
"typ_p",
"xtc",
"adaptive_p"
],
"samplers_priorities": [
"dry",
"penalties",
"no_repeat_ngram",
"temperature",
"top_nsigma",
"top_p_top_k",
"top_a",
"min_p",
"tfs",
"eta_cutoff",
"epsilon_cutoff",
"typical_p",
"quadratic",
"xtc"
],
"ignore_eos_token": false,
"spaces_between_special_tokens": true,
"speculative_ngram": false,
"sampler_order": [
6,
0,
1,
3,
4,
2,
5
],
"logit_bias": [],
"xtc_threshold": 0.1,
"xtc_probability": 0,
"nsigma": 0,
"min_keep": 0,
"extensions": {},
"adaptive_target": -0.01,
"adaptive_decay": 0.9,
"rep_pen_size": 0,
"genamt": 600,
"max_length": 16384,
"name": "Llama-3.3-8B-Nymphaea-RP"
}
}

107
chat_template.jinja Normal file
View File

@@ -0,0 +1,107 @@
{{- bos_token }}
{%- if custom_tools is defined %}
{%- set tools = custom_tools %}
{%- endif %}
{%- if not tools_in_user_message is defined %}
{%- set tools_in_user_message = true %}
{%- endif %}
{%- if not date_string is defined %}
{%- set date_string = "30 Dec 2025" %}
{%- endif %}
{%- if not tools is defined %}
{%- set tools = none %}
{%- endif %}
{#- This block extracts the system message, so we can slot it into the right place. #}
{%- if messages[0]['role'] == 'system' %}
{%- set system_message = messages[0]['content']|trim %}
{%- set messages = messages[1:] %}
{%- else %}
{%- set system_message = "" %}
{%- endif %}
{#- System message + builtin tools #}
{{- "<|start_header_id|>system<|end_header_id|>\n\n" }}
{%- if builtin_tools is defined or tools is not none %}
{{- "Environment: ipython\n" }}
{%- endif %}
{%- if builtin_tools is defined %}
{{- "Tools: " + builtin_tools | reject('equalto', 'code_interpreter') | join(", ") + "\n\n"}}
{%- endif %}
{{- "Cutting Knowledge Date: December 2023\n" }}
{{- "Today Date: " + date_string + "\n\n" }}
{%- if tools is not none and not tools_in_user_message %}
{{- "You have access to the following functions. To call a function, please respond with JSON for a function call." }}
{{- 'Respond in the format {"name": function name, "parameters": dictionary of argument name and its value}.' }}
{{- "Do not use variables.\n\n" }}
{%- for t in tools %}
{{- t | tojson(indent=4) }}
{{- "\n\n" }}
{%- endfor %}
{%- endif %}
{{- system_message }}
{{- "<|eot_id|>" }}
{#- Custom tools are passed in a user message with some extra guidance #}
{%- if tools_in_user_message and not tools is none %}
{#- Extract the first user message so we can plug it in here #}
{%- if messages | length != 0 %}
{%- set first_user_message = messages[0]['content']|trim %}
{%- set messages = messages[1:] %}
{%- else %}
{{- raise_exception("Cannot put tools in the first user message when there's no first user message!") }}
{%- endif %}
{{- '<|start_header_id|>user<|end_header_id|>\n\n' -}}
{{- "Given the following functions, please respond with a JSON for a function call " }}
{{- "with its proper arguments that best answers the given prompt.\n\n" }}
{{- 'Respond in the format {"name": function name, "parameters": dictionary of argument name and its value}.' }}
{{- "Do not use variables.\n\n" }}
{%- for t in tools %}
{{- t | tojson(indent=4) }}
{{- "\n\n" }}
{%- endfor %}
{{- first_user_message + "<|eot_id|>"}}
{%- endif %}
{%- for message in messages %}
{%- if not (message.role == 'ipython' or message.role == 'tool' or 'tool_calls' in message) %}
{%- if message['role'] == 'assistant' %}
{{- '<|start_header_id|>' + message['role'] + '<|end_header_id|>\n\n'}}{% generation %}{{- message['content'] | trim + '<|eot_id|>' }}{% endgeneration %}
{%- else %}
{{- '<|start_header_id|>' + message['role'] + '<|end_header_id|>\n\n' + message['content'] | trim + '<|eot_id|>' }}
{%- endif %}
{%- elif 'tool_calls' in message %}
{%- if not message.tool_calls|length == 1 %}
{{- raise_exception("This model only supports single tool-calls at once!") }}
{%- endif %}
{%- set tool_call = message.tool_calls[0].function %}
{{- '<|start_header_id|>assistant<|end_header_id|>\n\n' }}{% generation %}{%- if builtin_tools is defined and tool_call.name in builtin_tools %}
{{- "<|python_tag|>" + tool_call.name + ".call(" }}
{%- for arg_name, arg_val in tool_call.arguments | items %}
{{- arg_name + '="' + arg_val + '"' }}
{%- if not loop.last %}
{{- ", " }}
{%- endif %}
{%- endfor %}
{{- ")" }}
{%- else %}
{{- '{"name": "' + tool_call.name + '", ' }}
{{- '"parameters": ' }}
{{- tool_call.arguments | tojson }}
{{- "}" }}
{%- endif %}
{%- if builtin_tools is defined %}
{#- This means we're in ipython mode #}
{{- "<|eom_id|>" }}
{%- else %}
{{- "<|eot_id|>" }}
{%- endif %}{% endgeneration %}
{%- elif message.role == "tool" or message.role == "ipython" %}
{{- "<|start_header_id|>ipython<|end_header_id|>\n\n" }}
{%- if message.content is mapping or message.content is iterable %}
{{- message.content | tojson }}
{%- else %}
{{- message.content }}
{%- endif %}
{{- "<|eot_id|>" }}
{%- endif %}
{%- endfor %}
{%- if add_generation_prompt %}
{{- '<|start_header_id|>assistant<|end_header_id|>\n\n' }}
{%- endif %}

36
config.json Normal file
View File

@@ -0,0 +1,36 @@
{
"architectures": [
"LlamaForCausalLM"
],
"attention_bias": false,
"attention_dropout": 0.0,
"bos_token_id": 128000,
"dtype": "bfloat16",
"eos_token_id": 128009,
"head_dim": 128,
"hidden_act": "silu",
"hidden_size": 4096,
"initializer_range": 0.02,
"intermediate_size": 14336,
"max_position_embeddings": 131072,
"mlp_bias": false,
"model_type": "llama",
"num_attention_heads": 32,
"num_hidden_layers": 32,
"num_key_value_heads": 8,
"pad_token_id": null,
"pretraining_tp": 1,
"rms_norm_eps": 1e-05,
"rope_parameters": {
"factor": 8.0,
"high_freq_factor": 4.0,
"low_freq_factor": 1.0,
"original_max_position_embeddings": 8192,
"rope_theta": 500000.0,
"rope_type": "llama3"
},
"tie_word_embeddings": false,
"transformers_version": "5.3.0",
"use_cache": true,
"vocab_size": 128256
}

13
generation_config.json Normal file
View File

@@ -0,0 +1,13 @@
{
"bos_token_id": 128000,
"do_sample": true,
"eos_token_id": [
128001,
128008,
128009
],
"max_length": 131072,
"temperature": 0.6,
"top_p": 0.9,
"transformers_version": "5.3.0"
}

3
model.safetensors Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4ff18aad81f1ab4cc13e283d481d686d17e644ca30bed3489fefe0e1c9b5aa8a
size 16060556616

16
special_tokens_map.json Normal file
View File

@@ -0,0 +1,16 @@
{
"bos_token": {
"content": "<|begin_of_text|>",
"lstrip": false,
"normalized": false,
"rstrip": false,
"single_word": false
},
"eos_token": {
"content": "<|eot_id|>",
"lstrip": false,
"normalized": false,
"rstrip": false,
"single_word": false
}
}

3
tokenizer.json Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:3c5cf44023714fb39b05e71e425f8d7b92805ff73f7988b083b8c87f0bf87393
size 17209961

2063
tokenizer_config.json Normal file

File diff suppressed because it is too large Load Diff