Built with Axolotl

limarpv3-yi-llama-34b-lora

This model is an unofficial Yi-34B-Llama training on the LimaRP v3 dataset by lemonilia. It does not include the pretraining stage using stories.

The Yi-34B-Llama model is a modified 01-ai/Yi-34B with keys renamed to match those used in Llama models, eliminating the need for remote code and ensuring compatibility with existing training and inference repositories. Architecturally this is similar to a Llama 2 34B model with an expanded vocab size of 64000.

It achieves the following results on the evaluation set:

  • Loss: 1.9729

Model description

For more details about LimaRP, see the model page for the previously released v2 version for Llama-2. Most details written there apply for this version as well. Generally speaking, LimaRP is a longform-oriented, novel-style roleplaying chat model intended to replicate the experience of 1-on-1 roleplay on Internet forums. Short-form, IRC/Discord-style RP (aka "Markdown format") is not supported yet. The model does not include instruction tuning, only manually picked and slightly edited RP conversations with persona and scenario data.

Prompt format is the extended Alpaca format:

### Instruction:
Character's Persona: {bot character description}
User's Persona: {user character description}
Scenario: {what happens in the story}
Play the role of Character. You must engage in a roleplaying chat with User below this line. Do not write dialogues and narration for User.
### Input:
User: {utterance}
### Response:
Character: {utterance}
### Input:
User: {utterance}
### Response:
Character: {utterance}
(etc.)

Inspired by the previously named "Roleplay" preset in SillyTavern, with this version of LimaRP it is possible to append a length modifier to the response instruction sequence, like this:

### Input:
User: {utterance}

### Response: (length = medium)
Character: {utterance}

This has an immediately noticeable effect on bot responses. The lengths using during training are: micro, tiny, short, medium, long, massive, huge, enormous, humongous, unlimited. The recommended starting length is medium. Keep in mind that the AI can ramble or impersonate the user with very long messages.

The length control effect is reproducible, but the messages will not necessarily follow lengths very precisely, rather follow certain ranges on average, as seen in this table with data from tests made with one reply at the beginning of the conversation:

lengths

Response length control appears to work well also deep into the conversation. By omitting the modifier, the model will choose the most appropriate response length (although it might not necessarily be what the user desires).

Intended uses & limitations

The model will show biases similar to those observed in niche roleplaying forums on the Internet, besides those exhibited by the base model.

Training and evaluation data

For more details about LimaRP, see the model page for the previously released v2 version for Llama-2.

Training procedure

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 0.00015
  • train_batch_size: 2
  • eval_batch_size: 2
  • seed: 42
  • gradient_accumulation_steps: 4
  • total_train_batch_size: 8
  • optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
  • lr_scheduler_type: cosine
  • lr_scheduler_warmup_steps: 10
  • num_epochs: 2

Training results

Training Loss Epoch Step Validation Loss
2.1119 0.09 20 2.0727
1.9889 0.17 40 2.0104
1.878 0.26 60 1.9978
1.8531 0.34 80 1.9886
1.9504 0.43 100 1.9837
1.9216 0.51 120 1.9826
1.8483 0.6 140 1.9794
1.9668 0.68 160 1.9780
1.9776 0.77 180 1.9778
1.9312 0.85 200 1.9772
1.9003 0.94 220 1.9738
1.8748 1.02 240 1.9729
1.8896 1.11 260 1.9745
1.8702 1.19 280 1.9760
1.9038 1.28 300 1.9770
1.9083 1.36 320 1.9758
1.8143 1.45 340 1.9756
1.852 1.53 360 1.9742
1.8608 1.62 380 1.9735
1.8959 1.7 400 1.9735
1.7912 1.79 420 1.9731
1.8908 1.87 440 1.9727
1.8079 1.96 460 1.9729

Framework versions

  • Transformers 4.34.1
  • Pytorch 2.0.1+cu118
  • Datasets 2.14.6
  • Tokenizers 0.14.1
Downloads last month
11
Inference Examples
Inference API (serverless) has been turned off for this model.

Dataset used to train Doctor-Shotgun/limarpv3-yi-llama-34b-lora

Collection including Doctor-Shotgun/limarpv3-yi-llama-34b-lora