Philipp-Sc commited on
Commit
c5dac99
1 Parent(s): 69f49fd

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +70 -0
README.md CHANGED
@@ -1,3 +1,73 @@
1
  ---
2
  license: apache-2.0
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: apache-2.0
3
+ datasets:
4
+ - pankajmathur/WizardLM_Orca
5
+ language:
6
+ - en
7
+ pipeline_tag: text-generation
8
  ---
9
+ ---
10
+ base_model: mistralai/Mistral-7B-v0.1
11
+ ---
12
+
13
+ ## Reverse Instruct LoRa Adapter
14
+
15
+ This LoRa Adapter is fine tuned to reverse engineer the original prompt of a given LLM output/response.
16
+
17
+ ## Response Format
18
+
19
+ "[INST]\n### System:\n{system}\n### Instruction:\n{instruction}\n[/INST]\n"
20
+
21
+ (without the "")
22
+
23
+ ## Prompt Template
24
+
25
+ "\n### System:\nYou craft instructions for generating the given output through reverse engineering.\n### Instruction:\nDecipher the steps used to produce the given output and articulate a refined set of instructions (System & Instruction).\n### OUTPUT:\n {output}"
26
+
27
+ (use the template without the " ")
28
+
29
+ ## Training Dataset
30
+
31
+ About 21k items of the following datasets were used. (mostly coding-like tasks were removed)
32
+
33
+ ```bash
34
+ wget https://raw.githubusercontent.com/Instruction-Tuning-with-GPT-4/GPT-4-LLM/main/data/alpaca_gpt4_data.json
35
+ wget https://raw.githubusercontent.com/teknium1/GPTeacher/main/Roleplay%20Supplemental/roleplay-instruct-v2.1.json
36
+ wget https://huggingface.co/datasets/pankajmathur/WizardLM_Orca/resolve/main/wizardlm_orca.json
37
+ ```
38
+
39
+ ## Training Procedure
40
+
41
+ ```bash
42
+ CUDA_VISIBLE_DEVICES=0 WANDB_DISABLED=True python LLaMA-Factory/src/train_bash.py \
43
+ --stage sft \
44
+ --model_name_or_path model_name_or_path \
45
+ --checkpoint_dir checkpoint_dir \
46
+ --do_train \
47
+ --dataset default \
48
+ --template vanilla \
49
+ --finetuning_type lora \
50
+ --lora_target q_proj,v_proj \
51
+ --output_dir path_to_sft_checkpoint \
52
+ --overwrite_cache \
53
+ --per_device_train_batch_size 1 \
54
+ --gradient_accumulation_steps 1 \
55
+ --lr_scheduler_type cosine \
56
+ --logging_steps 10 \
57
+ --save_steps 100 \
58
+ --learning_rate 5e-5 \
59
+ --num_train_epochs 3.0 \
60
+ --plot_loss \
61
+ --fp16 \
62
+ --overwrite_output_dir \
63
+ --cutoff_len 2048 \
64
+ --quantization_bit 4
65
+ ```
66
+
67
+ ## Training Time
68
+
69
+ - ~30h on Kaggle's P100 GPU
70
+
71
+ ### Framework versions
72
+
73
+ - LLaMA-Factory