leo-pekelis-gradient commited on
Commit
2d5b9af
1 Parent(s): 1ea7aae

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +102 -38
README.md CHANGED
@@ -1,46 +1,109 @@
1
  ---
2
  tags:
3
  - generated_from_trainer
 
4
  model-index:
5
  - name: completed-model
6
  results: []
 
 
 
7
  ---
8
 
9
- <!-- This model card has been generated automatically according to the information the Trainer had access to. You
10
- should probably proofread and complete it, then remove this comment. -->
11
-
12
  [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
13
- # completed-model
14
-
15
- This model was trained from scratch on the None dataset.
16
- It achieves the following results on the evaluation set:
17
- - Loss: 0.3186
18
- - Rewards/chosen: -0.6296
19
- - Rewards/rejected: -2.5591
20
- - Rewards/accuracies: 0.8571
21
- - Rewards/margins: 1.9295
22
- - Logps/rejected: -296.3221
23
- - Logps/chosen: -425.5087
24
- - Logits/rejected: -2.2481
25
- - Logits/chosen: -1.7413
26
 
27
  ## Model description
28
 
29
- More information needed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
 
31
- ## Intended uses & limitations
32
 
33
- More information needed
 
 
 
 
 
 
 
34
 
35
- ## Training and evaluation data
36
 
37
- More information needed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
 
39
  ## Training procedure
40
 
41
- ### Training hyperparameters
 
 
 
 
42
 
43
- The following hyperparameters were used during training:
44
  - learning_rate: 5e-07
45
  - train_batch_size: 3
46
  - eval_batch_size: 3
@@ -55,24 +118,25 @@ The following hyperparameters were used during training:
55
  - num_epochs: 1
56
  - dpo_beta: .1
57
 
58
- ### Training results
59
-
60
- | Training Loss | Epoch | Step | Validation Loss | Rewards/chosen | Rewards/rejected | Rewards/accuracies | Rewards/margins | Logps/rejected | Logps/chosen | Logits/rejected | Logits/chosen |
61
- |:-------------:|:-----:|:----:|:---------------:|:--------------:|:----------------:|:------------------:|:---------------:|:--------------:|:------------:|:---------------:|:-------------:|
62
- | 0.4772 | 0.1 | 61 | 0.4037 | -0.3256 | -1.2099 | 0.8095 | 0.8843 | -282.8301 | -422.4691 | -2.1649 | -1.6678 |
63
- | 0.3859 | 0.2 | 122 | 0.3681 | -0.3816 | -1.7445 | 0.7143 | 1.3629 | -288.1762 | -423.0287 | -2.2536 | -1.7385 |
64
- | 0.3061 | 0.3 | 183 | 0.3546 | -0.4969 | -2.1025 | 0.8095 | 1.6056 | -291.7559 | -424.1818 | -2.1989 | -1.7108 |
65
- | 0.3765 | 0.4 | 244 | 0.3374 | -0.5153 | -2.1301 | 0.7619 | 1.6148 | -292.0326 | -424.3660 | -2.2182 | -1.7222 |
66
- | 0.2819 | 0.5 | 305 | 0.3303 | -0.4402 | -2.1809 | 0.8095 | 1.7407 | -292.5404 | -423.6147 | -2.1835 | -1.6998 |
67
- | 0.3009 | 0.6 | 366 | 0.3314 | -0.8026 | -2.7756 | 0.8571 | 1.9730 | -298.4871 | -427.2388 | -2.2430 | -1.7529 |
68
- | 0.3015 | 0.7 | 427 | 0.3228 | -0.6439 | -2.5710 | 0.9048 | 1.9271 | -296.4410 | -425.6519 | -2.2258 | -1.7303 |
69
- | 0.3407 | 0.8 | 488 | 0.3185 | -0.7270 | -2.7118 | 0.8571 | 1.9847 | -297.8488 | -426.4829 | -2.2530 | -1.7496 |
70
- | 0.3149 | 0.9 | 549 | 0.3186 | -0.6296 | -2.5591 | 0.8571 | 1.9295 | -296.3221 | -425.5087 | -2.2481 | -1.7413 |
71
-
72
-
73
  ### Framework versions
74
 
75
  - Transformers 4.35.1
76
  - Pytorch 2.0.1+cu118
77
  - Datasets 2.14.7
78
  - Tokenizers 0.14.1
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  tags:
3
  - generated_from_trainer
4
+ - finance
5
  model-index:
6
  - name: completed-model
7
  results: []
8
+ license: apache-2.0
9
+ language:
10
+ - en
11
  ---
12
 
 
 
 
13
  [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
14
+
15
+ **Albatross** is a collection of domain-specific language models for finance applications developed by [Gradient](https://gradient.ai/).
16
+
17
+ This is the repository for an early, limited capability version, the `v-alpha-tross`, designed to showcase performance on
18
+
19
+ - mathematical reasoning
20
+ - tabular understanding
21
+ - open-book retrieval (RAG) & summarization
22
+ - conversational interface
23
+
24
+ Release versions of Albatross models are additionally trained on proprietary implementations of the latest architecture augmentation, expanded training and alignment data, and target reduced hallucination at retrieval, improved auditability, and multi-hop reasoning. To inquire for access to release versions, please reach out to [[email protected]](mailto:[email protected])
 
 
25
 
26
  ## Model description
27
 
28
+ The `v-alpha-tross` model is based on [meta-llama/Llama-2-70b-hf](https://huggingface.co/meta-llama/Llama-2-70b-hf), with additional, finance specific, pre-training, fine-tuning and instruction tuning.
29
+
30
+ This model substantially outperforms Llama2-70B models on H6 Average score, and GSM8K, with similar performance to [mistralai/Mixtral-8x7B-Instruct-v0.1](https://huggingface.co/mistralai/Mixtral-8x7B-Instruct-v0.1). It also reaches `gpt-3.5-turbo` performance in extracting information from tabular data like those found in SEC filings.
31
+
32
+ ## Intended use
33
+
34
+ The `v-alpha-tross` is intended as a demonstration of Gradient’s Albatross framework for developing large language models specific to the finance domain. We welcome additional research and development, but do not plan on continued internal development on this legacy model.
35
+
36
+ To get the expected performance, follow formatting requirements of *Llama-2 chat*, including `INST` and `<<SYS>>` tags, and `<s>` tokens.
37
+
38
+ ## Training Strategy
39
+
40
+ The Albatross framework overcomes deficiencies in general-purpose language models that arise in the face of solving tasks in the finance domain.
41
+
42
+ Release versions of Albatross use an expanded data universe for extended capabilities.
43
+
44
+ ### Pre-Training
45
+
46
+ A base Llama2-70B is further pre-trained on finance data since LLMs are poor at answering questions when their internal relevant document store is sparse [1].
47
+
48
+ To curate quality training data with low operational overhead we demo a novel data gathering approach:
49
+
50
+ 1. Crawl public repositories of text data. For `v-alpha-tross`, we limited to [Red Pajamas](https://github.com/togethercomputer/RedPajama-Data) and https://github.com/.
51
+ 2. Programmatically filter the crawled corpus to datasets not likely to be in the base model's training already, using a likelihood ratio test adapted from LiRA membership inference.[2]
52
+ 3. Human finance professionals review the (much smaller) filtered corpus to further remove low quality results.
53
+
54
+ [1] Kandpal, Nikhil, et al. "Large language models struggle to learn long-tail knowledge." International Conference on Machine Learning. PMLR, 2023.
55
+
56
+ [2] Carlini, Nicholas, et al. "Membership inference attacks from first principles." 2022 IEEE Symposium on Security and Privacy (SP). IEEE, 2022.
57
+
58
+ ### Fine-Tuning
59
+
60
+ Supervised fine-tuning (SFT) and direct preference optimization (DPO)[3] further enhances performance and alignment on finance-related tasks.
61
 
62
+ `v-alpha-tross` includes a subset of Albatross tuning goals: financial anchoring, mathematical reasoning, tabular understanding, conversational communication, summarization.
63
 
64
+ | Category | # Tokens (1Ms) | % of Total |
65
+ | --- | --- | --- |
66
+ | Chat (e.g. [ultrachat_200k](https://huggingface.co/datasets/HuggingFaceH4/ultrachat_200k)) | 640 | 45.2 |
67
+ | Alignment (e.g. [orca_dpo](https://huggingface.co/datasets/Intel/orca_dpo_pairs)) | 331 | 23.4 |
68
+ | Math (e.g. Goat[4]) | 300 | 21.2 |
69
+ | Tabular * | 68 | 4.8 |
70
+ | Summarization (e.g. [legal_summarization](https://huggingface.co/datasets/lighteval/legal_summarization)) | 52 | 3.7 |
71
+ | Open-book (e.g. [selfrag](https://huggingface.co/datasets/selfrag/selfrag_train_data)) | 25 | 1.8 |
72
 
73
+ (*) = Proprietary
74
 
75
+ [3] Rafailov, R., Sharma, A., Mitchell, E., Ermon, S., Manning, C.D. and Finn, C., 2023. Direct preference optimization: Your language model is secretly a reward model. NeurIPS.
76
+
77
+ [4] Liu, Tiedong, and Bryan Kian Hsiang Low. "Goat: Fine-tuned LLaMA Outperforms GPT-4 on Arithmetic Tasks." arXiv preprint arXiv:2305.14201 (2023).
78
+
79
+ ## Benchmarks
80
+
81
+ From a Llama-2-70B base, `v-alpha-tross` improves H6 metrics, and in particular GSM8k (arithmetic reasoning), scoring similar to Mixtral-8x7B-Instruct-v0.1. Relative to a subset of Open LLM Leaderboard [4] models which also use Llama-2-70B as a base, the model achieves state of the art results for the Average H6 score.
82
+
83
+ On financial table understanding (our new metric) the model is on par with GPT-3.5.
84
+
85
+ | Model | H6 [4] | GSM8k | sec_tables_v1 |
86
+ | --- | --- | --- | --- |
87
+ | v-alpha-tross | 72.81 | 61.79 | 100.0 |
88
+ | meta-llama/Llama-2-70B-hf | 67.87 | 54.06 | 75.76 |
89
+ | meta-llama/Llama-2-70b-chat-hf | 62.40 | 26.69 | 87.88 |
90
+ | mistralai/Mixtral-8x7B-Instruct-v0.1 | 72.70 | 61.11 | 82.35 |
91
+ | GPT-3.5 | N/A | 57.1 [5] | 100.0 |
92
+
93
+ [4]
94
+ https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard
95
+
96
+ [5]
97
+ https://paperswithcode.com/sota/arithmetic-reasoning-on-gsm8k
98
 
99
  ## Training procedure
100
 
101
+ We develop Albatross on Gradient’s distributed training platform, leveraging leading open source toolsets and optimizations like [Axolotl](https://github.com/OpenAccess-AI-Collective/axolotl), [Accelerate](https://github.com/huggingface/accelerate), and [Deepspeed](https://github.com/microsoft/DeepSpeed) for high throughput and memory efficiency.
102
+
103
+ ### Training hyperparameters (DPO)
104
+
105
+ The following hyperparameters were used during DPO training:
106
 
 
107
  - learning_rate: 5e-07
108
  - train_batch_size: 3
109
  - eval_batch_size: 3
 
118
  - num_epochs: 1
119
  - dpo_beta: .1
120
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
121
  ### Framework versions
122
 
123
  - Transformers 4.35.1
124
  - Pytorch 2.0.1+cu118
125
  - Datasets 2.14.7
126
  - Tokenizers 0.14.1
127
+
128
+ ## Bias
129
+
130
+ `v-alpha-tross` has not been specifically aligned for safety, so the model can produce problematic outputs (especially when prompted to do so). It is also subject to any risks of the corpus that was used to train the base Llama 2 models.
131
+
132
+ ## More information & how to cite
133
+
134
+ Whitepaper coming soon!
135
+
136
+ ## The Gradient AI Team
137
+
138
+ Gradient is accelerating AI transformation across industries. https://gradient.ai/
139
+
140
+ ## Contact Us
141
+
142
+ Drop an email to [[email protected]](mailto:[email protected])