Alexhf825 commited on
Commit
e8c1d9c
Β·
verified Β·
1 Parent(s): 99cae4e

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +84 -1
README.md CHANGED
@@ -7,4 +7,87 @@ metrics:
7
  - accuracy
8
  base_model:
9
  - FreedomIntelligence/openPangu-Embedded-7B
10
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7
  - accuracy
8
  base_model:
9
  - FreedomIntelligence/openPangu-Embedded-7B
10
+ ---
11
+
12
+
13
+ # AutoMR for Pangu
14
+
15
+ This project equips the Pangu model with the AutoMR reasoning framework, optimized for Huawei Ascend hardware.
16
+
17
+ ## 🌳 Project Structure
18
+
19
+ ```
20
+ .
21
+ β”œβ”€β”€ AMC.SH
22
+ β”œβ”€β”€ automr
23
+ β”‚Β  Β β”œβ”€β”€ config.py
24
+ β”‚Β  Β β”œβ”€β”€ dag.py
25
+ β”‚Β  Β β”œβ”€β”€ data_loader.py
26
+ β”‚Β  Β β”œβ”€β”€ evaluator.py
27
+ β”‚Β  Β β”œβ”€β”€ __init__.py
28
+ β”‚Β  Β β”œβ”€β”€ model.py
29
+ β”‚Β  Β β”œβ”€β”€ strategies.py
30
+ β”‚Β  Β β”œβ”€β”€ trainer.py
31
+ β”‚Β   └── utils.py
32
+ β”œβ”€β”€ checkpoints
33
+ β”‚Β   └── MATH
34
+ β”œβ”€β”€ embedder_server.sh
35
+ β”œβ”€β”€ generator_server.sh
36
+ β”œβ”€β”€ main.py
37
+ β”œβ”€β”€ math_train.sh
38
+ └── processed_data
39
+ Β  Β  β”œβ”€β”€ AMC
40
+ Β  Β  └── MATH
41
+ ```
42
+
43
+ ## πŸ”§ 1. Installation
44
+
45
+ ### a. Clone the Project Repository
46
+
47
+ ```bash
48
+ hf download Alexhf825/AutoMR-pangu --local-dir AutoMR-pangu
49
+ cd AutoMR-pangu
50
+ ```
51
+
52
+ ### b. Install Dependencies
53
+
54
+
55
+ ### c. Download Datasets
56
+
57
+ This command will download the datasets and place them in the `./processed_data` directory, matching the project structure.
58
+
59
+ ```bash
60
+ hf download Alexhf825/dataset-test-pangu --repo-type=dataset --local-dir=./processed_data
61
+ ```
62
+
63
+ ## πŸš€ 2. Start the Servers
64
+
65
+ This project requires two services running in an OpenAI-API style. Please run the following commands in **two separate terminal sessions**.
66
+
67
+ **Start the Embedder Server:**
68
+
69
+ ```bash
70
+ bash embedder_server.sh
71
+ ```
72
+
73
+ **Start the Generator Server:**
74
+
75
+ ```bash
76
+ bash generator_server.sh
77
+ ```
78
+
79
+ ## πŸ“ˆ 3. Run Evaluation
80
+
81
+ A pre-trained checkpoint (`MATH`) is provided. You can directly evaluate the model on the `AMC` dataset using the following command:
82
+
83
+ ```bash
84
+ bash AMC.sh
85
+ ```
86
+
87
+ ## πŸ‹οΈ 4. Run Training
88
+
89
+ You can also train the model from scratch on the `MATH` dataset by running:
90
+
91
+ ```bash
92
+ bash math_train.sh
93
+ ```