|
--- |
|
license: apache-2.0 |
|
datasets: |
|
- sajaw/Arasquad3_llama2_version2 |
|
- sajaw/GQA_llama2_version |
|
language: |
|
- ar |
|
metrics: |
|
- bertscore |
|
pipeline_tag: question-answering |
|
--- |
|
# Model Card for Model ID |
|
|
|
<!-- Provide a quick summary of what the model is/does. --> |
|
|
|
This model is an LoRA adapter file from finetuned Llama-2-7b-hf model. This is an experimental model. |
|
|
|
|
|
To run it, you need to: |
|
|
|
Agree with Meta's agreements to download the Llama-2-13b-chat-hf model from here: https://huggingface.co/meta-llama/Llama-2-13b-chat-hf |
|
Clone this repository |
|
Clone the Alpaca-LoRA repository from here: https://github.com/tloen/alpaca-lora |
|
Use this command to run it: -python generate.py |
|
--load_8bit |
|
--base_model 'PATH_TO_YOUR_LOCAL_LLAMA_2_7B_CHAT_HF' |
|
--lora_weights 'PATH_TO_YOUR_LOCAL_FILE_OF_THIS_MODEL' |
|
You must agree with Meta/Llama-2's agreements to use this model. |
|
## Model Details |
|
|
|
### Model Description |
|
|
|
<!-- Provide a longer summary of what this model is. --> |
|
|
|
|
|
|
|
- **Developed by:** Saja Nakhleh |
|
|
|
- **Model type:** Question answering model |
|
- **Language(s) (NLP):** Arabic |
|
- **Finetuned from model [optional]:** llama-2-7b |
|
### Model Sources [optional] |
|
|
|
<!-- Provide the basic links for the model. --> |
|
|
|
- **Paper [optional]:** Not Yet |
|
|
|
## Bias, Risks, and Limitations |
|
|
|
This model performs well with hetrogenius data. |
|
|
|
|
|
|
|
### Recommendations |
|
|
|
<!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. --> |
|
|
|
None |
|
## How to Get Started with the Model |
|
|
|
Use the code below to get started with the model. |
|
|
|
from transformers import AutoConfig, AutoModel, AutoTokenizer |
|
config = AutoConfig.from_pretrained("sajaw/llama-2-7b-RandomGPT-5K-ar") |
|
model = AutoModel.from_pretrained("sajaw/llama-2-7b-RandomGPT-5K-ar") |
|
tokenizer = AutoTokenizer.from_pretrained("sajaw/llama-2-7b-RandomGPT-5K-ar") |
|
|
|
## Training Details |
|
|
|
### Training Data |
|
|
|
<!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. --> |
|
|
|
- sajaw/Arasquad3_llama2_version2 |
|
- sajaw/GQA_llama2_version |
|
|
|
|
|
#### Preprocessing [optional] |
|
|
|
Context, questions and answers are concatinated with the instructions in one "message" record |
|
|
|
|
|
#### Training Hyperparameters |
|
|
|
- **Training regime:** NA <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision --> |
|
|
|
#### Speeds, Sizes, Times [optional] |
|
|
|
<!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. --> |
|
|
|
NA |
|
|
|
## Evaluation |
|
|
|
<!-- This section describes the evaluation protocols and provides the results. --> |
|
|
|
### Testing Data, Factors & Metrics |
|
|
|
#### Testing Data |
|
|
|
<!-- This should link to a Dataset Card if possible. --> |
|
|
|
We have used 250 samples from AraSquad as true samples to test the model |
|
|
|
#### Factors |
|
|
|
<!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. --> |
|
NA |
|
|
|
#### Metrics |
|
|
|
<!-- These are the evaluation metrics being used, ideally with a description of why. --> |
|
|
|
F1-score, precision, recall |
|
|
|
### Results |
|
|
|
F1-score= 0.6818 |
|
precision= 0.6564 |
|
recall=0.7226 |
|
|
|
#### Summary |
|
|
|
|
|
|
|
## Model Examination [optional] |
|
|
|
<!-- Relevant interpretability work for the model goes here --> |
|
|
|
NA |
|
|
|
## Environmental Impact |
|
|
|
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly --> |
|
|
|
Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700). |
|
|
|
- **Hardware Type:** kaggle - GPU T4 *2 |
|
- **Hours used:** 9 hours |
|
- **Cloud Provider:** kaggle |
|
- **Compute Region:** NA |
|
- **Carbon Emitted:** NA |
|
|
|
## Technical Specifications [optional] |
|
|
|
### Model Architecture and Objective |
|
|
|
NA |
|
|
|
### Compute Infrastructure |
|
|
|
NA |
|
|
|
#### Hardware |
|
|
|
NA |
|
|
|
#### Software |
|
|
|
NA |
|
|
|
## Citation [optional] |
|
|
|
<!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. --> |
|
|
|
**BibTeX:** |
|
|
|
|
|
**APA:** |
|
|
|
|
|
|
|
## Glossary [optional] |
|
|
|
<!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. --> |
|
|
|
NA |
|
|
|
## More Information [optional] |
|
|
|
NA |
|
|
|
## Model Card Authors [optional] |
|
|
|
Saja Nakhleh |
|
|
|
## Model Card Contact |
|
|
|
[email protected] |