initial commit
Browse files
README.md
ADDED
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<p align="center" width="100%">
|
2 |
+
<img src="assets/logo.png" alt="Vigogne" style="width: 30%; min-width: 300px; display: block; margin: auto;">
|
3 |
+
</p>
|
4 |
+
|
5 |
+
# LLaMandement-13B: A Llama-2-based French Models for Summarization of French Legislative Proposals.
|
6 |
+
|
7 |
+
LLaMandement-13B is a French chat LLM, based on [LLaMA-2-13B](https://ai.meta.com/llama), optimized to summarize of French Legislative Proposals.
|
8 |
+
|
9 |
+
## Model Details
|
10 |
+
|
11 |
+
- **Developed by:** [DGFIP](https://www.impots.gouv.fr/presentation-de-la-dgfip-overview-dgfip) :
|
12 | |
13 | |
14 |
+
- **Model type:** An auto-regressive language model based on the transformer architecture
|
15 |
+
- **License:** Llama 2 Community License Agreement
|
16 |
+
- **Finetuned from model:** [Llama 2](https://arxiv.org/abs/2307.09288)
|
17 |
+
- **Repository:** https://gitlab.adullact.net/dgfip/projets-ia/llamandement
|
18 |
+
- **Paper:** working
|
19 |
+
|
20 |
+
## Prompt Template
|
21 |
+
|
22 |
+
|
23 |
+
The prompt for LLaMandement-13B is based on alpaca template :
|
24 |
+
|
25 |
+
```
|
26 |
+
Below is an instruction that describes a task. Write a response that appropriately completes the request.
|
27 |
+
|
28 |
+
### Instruction:
|
29 |
+
{instruction}
|
30 |
+
|
31 |
+
### Response:
|
32 |
+
```
|
33 |
+
|
34 |
+
## How to Get Started with the Model
|
35 |
+
|
36 |
+
- Command line interface: https://github.com/lm-sys/FastChat
|
37 |
+
- APIs (OpenAI API, Huggingface API): https://github.com/lm-sys/FastChat/tree/main#api
|
38 |
+
|
39 |
+
## Training Details
|
40 |
+
|
41 |
+
Llamandement-13B is fine-tuned from Llama 2 using Low-Rank Adaptation (LORA). This method is efficient and adds minimal computational load. It introduces additional low-rank parameters, enabling the model to better handle complex legislative language without major changes to the original structure.
|
42 |
+
|
43 |
+
**LORA Settings Adjustments:**
|
44 |
+
|
45 |
+
- **Learning Rate (LR):** Set to a low value of 2e-5 to ensure stable and gradual improvements.
|
46 |
+
- **Adaptation Depth (lora_r):** Set at 64, influencing the dimension of the low-rank matrix in LORA. This affected about 0.40% of the model's weights.
|
47 |
+
- **Decay Rate:** Employed at 0.01 to prevent overfitting to specific legislative text structures.
|
48 |
+
- **LORA Alpha (α):** Set at 16, it fine-tunes the model's response to legislative text.
|
49 |
+
- **LORA Dropout:** A rate of 0.1 applied to LORA layers to prevent overfitting and enhance generalization.
|
50 |
+
- **Optimizer and Scheduler:** Utilized a cosine learning rate scheduler with a warmup ratio of 0.03 for optimal training.
|
51 |
+
|
52 |
+
|
53 |
+
For more information, visit [dgfip.finance.com](http://dgfip.finance.com). Additional details about the training dataset composition can be found [here](http://dgfip.finance.com/training-dataset-info).
|
54 |
+
|
55 |
+
|
56 |
+
|
57 |
+
## Citation
|
58 |
+
|
59 |
+
Please cite the repo if you use the data, method or code in this repo.
|
60 |
+
|
61 |
+
[...]
|
62 |
+
|
63 |
+
|