Spaces:
Sleeping
Sleeping
iris-s-coon
commited on
Commit
·
56a1ce5
1
Parent(s):
3d773b0
📖 [docs] 英語READMEの更新
Browse files- docs/README.en.md +26 -26
docs/README.en.md
CHANGED
@@ -31,7 +31,7 @@ license: mit
|
|
31 |
</p>
|
32 |
|
33 |
<h2 align="center">
|
34 |
-
Llama Model Fine-tuning
|
35 |
</h2>
|
36 |
|
37 |
<p align="center">
|
@@ -44,30 +44,30 @@ license: mit
|
|
44 |
|
45 |
## 🚀 Project Overview
|
46 |
|
47 |
-
**Llama-finetune-sandbox** provides an experimental environment for learning and verifying
|
48 |
|
49 |
|
50 |
-
## ✨
|
51 |
|
52 |
-
1. **
|
53 |
- LoRA (Low-Rank Adaptation)
|
54 |
- QLoRA (Quantized LoRA)
|
55 |
|
56 |
-
2. **Flexible Model
|
57 |
- Customizable maximum sequence length
|
58 |
- Various quantization options
|
59 |
- Multiple attention mechanisms
|
60 |
|
61 |
-
3. **
|
62 |
- Optimized memory usage
|
63 |
- Visualization of experimental results
|
64 |
|
65 |
4. **Context-Aware Reflexive QA Generation System:**
|
66 |
- Generates high-quality Q&A datasets from Wikipedia data.
|
67 |
- Uses LLMs to automatically generate context-aware questions and answers, evaluate quality, and iteratively improve them.
|
68 |
-
- Employs a reflexive approach
|
69 |
- Provides comprehensive code and explanations covering environment setup, model selection, data preprocessing, Q&A pair generation, quality evaluation, and the improvement process.
|
70 |
-
-
|
71 |
- Generated Q&A pairs are saved in JSON format and can be easily uploaded to the Hugging Face Hub.
|
72 |
|
73 |
|
@@ -75,36 +75,36 @@ license: mit
|
|
75 |
|
76 |
This repository includes the following examples:
|
77 |
|
78 |
-
###
|
79 |
-
-
|
80 |
- → See [`Llama_3_2_1B+3B_Conversational_+_2x_faster_finetuning_JP.md`](sandbox/Llama_3_2_1B+3B_Conversational_+_2x_faster_finetuning_JP.md) for details.
|
81 |
-
- → [Use this to convert from
|
82 |
- [📒Notebook here](https://colab.research.google.com/drive/1AjtWF2vOEwzIoCMmlQfSTYCVgy4Y78Wi?usp=sharing)
|
83 |
|
84 |
-
### Efficient Model
|
85 |
-
- Setup and
|
86 |
- → See [`efficient-ollama-colab-setup-with-litellm-guide.md`](sandbox/efficient-ollama-colab-setup-with-litellm-guide.md) for details.
|
87 |
- [📒Notebook here](https://colab.research.google.com/drive/1buTPds1Go1NbZOLlpG94VG22GyK-F4GW?usp=sharing)
|
88 |
|
89 |
### Q&A Dataset Generation from Wikipedia Data (Sentence Pool QA Method)
|
90 |
- High-quality Q&A dataset generation using the sentence pool QA method.
|
91 |
-
- → A new dataset creation method that generates Q&A pairs while preserving context by pooling sentence
|
92 |
-
- → Chunk size is flexibly adjustable (default 200 characters)
|
93 |
- → See [`wikipedia-qa-dataset-generator.md`](sandbox/wikipedia-qa-dataset-generator.md) for details.
|
94 |
- [📒Notebook here](https://colab.research.google.com/drive/1mmK5vxUzjk3lI6OnEPrQqyjSzqsEoXpk?usp=sharing)
|
95 |
|
96 |
### Context-Aware Reflexive QA Generation System
|
97 |
- Q&A dataset generation with reflexive quality improvement.
|
98 |
-
- →
|
99 |
- → Quantifies factuality, question quality, and answer completeness for evaluation.
|
100 |
-
- →
|
101 |
- → See [`context_aware_Reflexive_qa_generator_V2.md`](sandbox/context_aware_Reflexive_qa_generator_V2.md) for details.
|
102 |
- [📒Notebook here](https://colab.research.google.com/drive/1OYdgAuXHbl-0LUJgkLl_VqknaAEmAm0S?usp=sharing)
|
103 |
|
104 |
### LLM Evaluation System (LLMs as a Judge)
|
105 |
-
- Advanced quality evaluation system
|
106 |
-
- → Automatically evaluates questions, model answers, and LLM
|
107 |
-
- → Robust design with error handling and retry
|
108 |
- → Generates detailed evaluation reports in CSV and HTML formats.
|
109 |
- → See [`LLMs_as_a_Judge_TOHO_V2.md`](sandbox/LLMs_as_a_Judge_TOHO_V2.md) for details.
|
110 |
- [📒Notebook here](https://colab.research.google.com/drive/1Zjw3sOMa2v5RFD8dFfxMZ4NDGFoQOL7s?usp=sharing)
|
@@ -121,8 +121,8 @@ cd Llama-finetune-sandbox
|
|
121 |
## 📝 Adding Examples
|
122 |
|
123 |
1. Add new implementations to the `sandbox/` directory.
|
124 |
-
2. Add necessary settings and utilities to `utils/` (
|
125 |
-
3. Update documentation and tests (
|
126 |
4. Create a pull request.
|
127 |
|
128 |
## 🤝 Contributions
|
@@ -130,13 +130,13 @@ cd Llama-finetune-sandbox
|
|
130 |
- Implementation of new fine-tuning methods
|
131 |
- Bug fixes and feature improvements
|
132 |
- Documentation improvements
|
133 |
-
-
|
134 |
|
135 |
## 📚 References
|
136 |
|
137 |
-
- [HuggingFace PEFT
|
138 |
-
- [About Llama
|
139 |
-
- [Fine-tuning
|
140 |
|
141 |
## 📄 License
|
142 |
|
|
|
31 |
</p>
|
32 |
|
33 |
<h2 align="center">
|
34 |
+
Llama Model Fine-tuning Experimentation Environment
|
35 |
</h2>
|
36 |
|
37 |
<p align="center">
|
|
|
44 |
|
45 |
## 🚀 Project Overview
|
46 |
|
47 |
+
**Llama-finetune-sandbox** provides an experimental environment for learning and verifying the fine-tuning of Llama models. You can try various fine-tuning methods, customize models, and evaluate performance. It caters to a wide range of users, from beginners to researchers. Version 0.5.0 includes updated documentation and the addition of a context-aware reflexive QA generation system. This system generates high-quality Q&A datasets from Wikipedia data, leveraging LLMs to iteratively improve the quality of questions and answers, resulting in a more accurate dataset.
|
48 |
|
49 |
|
50 |
+
## ✨ Key Features
|
51 |
|
52 |
+
1. **Diverse Fine-tuning Methods:**
|
53 |
- LoRA (Low-Rank Adaptation)
|
54 |
- QLoRA (Quantized LoRA)
|
55 |
|
56 |
+
2. **Flexible Model Configuration:**
|
57 |
- Customizable maximum sequence length
|
58 |
- Various quantization options
|
59 |
- Multiple attention mechanisms
|
60 |
|
61 |
+
3. **Well-equipped Experimentation Environment:**
|
62 |
- Optimized memory usage
|
63 |
- Visualization of experimental results
|
64 |
|
65 |
4. **Context-Aware Reflexive QA Generation System:**
|
66 |
- Generates high-quality Q&A datasets from Wikipedia data.
|
67 |
- Uses LLMs to automatically generate context-aware questions and answers, evaluate quality, and iteratively improve them.
|
68 |
+
- Employs a reflexive approach, quantifying factuality, question quality, and answer completeness for iterative improvement.
|
69 |
- Provides comprehensive code and explanations covering environment setup, model selection, data preprocessing, Q&A pair generation, quality evaluation, and the improvement process.
|
70 |
+
- Utilizes libraries such as `litellm`, `wikipedia`, and `transformers`.
|
71 |
- Generated Q&A pairs are saved in JSON format and can be easily uploaded to the Hugging Face Hub.
|
72 |
|
73 |
|
|
|
75 |
|
76 |
This repository includes the following examples:
|
77 |
|
78 |
+
### Fast Fine-tuning using Unsloth
|
79 |
+
- Implementation of fast fine-tuning for Llama-3.2-1B/3B models.
|
80 |
- → See [`Llama_3_2_1B+3B_Conversational_+_2x_faster_finetuning_JP.md`](sandbox/Llama_3_2_1B+3B_Conversational_+_2x_faster_finetuning_JP.md) for details.
|
81 |
+
- → [Use this to convert from markdown to notebook format](https://huggingface.co/spaces/MakiAi/JupytextWebUI)
|
82 |
- [📒Notebook here](https://colab.research.google.com/drive/1AjtWF2vOEwzIoCMmlQfSTYCVgy4Y78Wi?usp=sharing)
|
83 |
|
84 |
+
### Efficient Model Deployment using Ollama and LiteLLM
|
85 |
+
- Setup and deployment guide on Google Colab.
|
86 |
- → See [`efficient-ollama-colab-setup-with-litellm-guide.md`](sandbox/efficient-ollama-colab-setup-with-litellm-guide.md) for details.
|
87 |
- [📒Notebook here](https://colab.research.google.com/drive/1buTPds1Go1NbZOLlpG94VG22GyK-F4GW?usp=sharing)
|
88 |
|
89 |
### Q&A Dataset Generation from Wikipedia Data (Sentence Pool QA Method)
|
90 |
- High-quality Q&A dataset generation using the sentence pool QA method.
|
91 |
+
- → A new dataset creation method that generates Q&A pairs while preserving context by pooling sentence segments delimited by punctuation.
|
92 |
+
- → Chunk size is flexibly adjustable (default 200 characters) to generate Q&A pairs with an optimal context range depending on the application.
|
93 |
- → See [`wikipedia-qa-dataset-generator.md`](sandbox/wikipedia-qa-dataset-generator.md) for details.
|
94 |
- [📒Notebook here](https://colab.research.google.com/drive/1mmK5vxUzjk3lI6OnEPrQqyjSzqsEoXpk?usp=sharing)
|
95 |
|
96 |
### Context-Aware Reflexive QA Generation System
|
97 |
- Q&A dataset generation with reflexive quality improvement.
|
98 |
+
- → Automatically evaluates the quality of generated Q&A pairs and iteratively improves them.
|
99 |
- → Quantifies factuality, question quality, and answer completeness for evaluation.
|
100 |
+
- → Generates high-precision questions and performs consistency checks on answers using contextual information.
|
101 |
- → See [`context_aware_Reflexive_qa_generator_V2.md`](sandbox/context_aware_Reflexive_qa_generator_V2.md) for details.
|
102 |
- [📒Notebook here](https://colab.research.google.com/drive/1OYdgAuXHbl-0LUJgkLl_VqknaAEmAm0S?usp=sharing)
|
103 |
|
104 |
### LLM Evaluation System (LLMs as a Judge)
|
105 |
+
- Advanced quality evaluation system using LLMs as evaluators.
|
106 |
+
- → Automatically evaluates questions, model answers, and LLM responses on a four-level scale.
|
107 |
+
- → Robust design with error handling and retry functions.
|
108 |
- → Generates detailed evaluation reports in CSV and HTML formats.
|
109 |
- → See [`LLMs_as_a_Judge_TOHO_V2.md`](sandbox/LLMs_as_a_Judge_TOHO_V2.md) for details.
|
110 |
- [📒Notebook here](https://colab.research.google.com/drive/1Zjw3sOMa2v5RFD8dFfxMZ4NDGFoQOL7s?usp=sharing)
|
|
|
121 |
## 📝 Adding Examples
|
122 |
|
123 |
1. Add new implementations to the `sandbox/` directory.
|
124 |
+
2. Add necessary settings and utilities to `utils/` (This section was removed as `utils/` directory appears not to exist).
|
125 |
+
3. Update documentation and tests (This section was removed as there's no mention of existing tests).
|
126 |
4. Create a pull request.
|
127 |
|
128 |
## 🤝 Contributions
|
|
|
130 |
- Implementation of new fine-tuning methods
|
131 |
- Bug fixes and feature improvements
|
132 |
- Documentation improvements
|
133 |
+
- Addition of usage examples
|
134 |
|
135 |
## 📚 References
|
136 |
|
137 |
+
- [HuggingFace PEFT documentation](https://huggingface.co/docs/peft)
|
138 |
+
- [About Llama models](https://github.com/facebookresearch/llama)
|
139 |
+
- [Fine-tuning best practices](https://github.com/Sunwood-ai-labs/Llama-finetune-sandbox/wiki) (This section was removed as the wiki page appears not to exist).
|
140 |
|
141 |
## 📄 License
|
142 |
|