YummyYum commited on
Commit
3f51b2b
·
verified ·
1 Parent(s): 51e8fe2

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +133 -51
README.md CHANGED
@@ -1,75 +1,92 @@
1
  # Introduction
2
 
3
- RoboBrain2.0-7B-FlagOS-Nvidia provides an all-in-one deployment solution, enabling execution of RoboBrain2.0-7B on Nvidia GPUs. As the first-generation release for the <HARDWARE_PLATFORM_SERIES>, this package delivers three key features:
4
 
5
- 1. Comprehensive Integration:
6
- - Integrated with FlagScale (https://github.com/FlagOpen/FlagScale).
7
- - Open-source inference execution code, preconfigured with all necessary software and hardware settings.
8
- - Pre-built Docker image for rapid deployment on <HARDWARE_PLATFORM_SERIES>.
9
- 3. Consistency Validation:
10
- - Evaluation tests verifying consistency of results between the official and ours.
11
 
12
- # Technical Summary
13
 
14
- ## Serving Engine
 
 
15
 
16
- We use FlagScale as the serving engine to improve the portability of distributed inference.
17
 
18
- FlagScale is an end-to-end framework for large models across multiple chips, maximizing computational resource efficiency while ensuring model effectiveness. It ensures both ease of use and high performance for users when deploying models across different chip architectures:
19
 
20
- - One-Click Service Deployment: FlagScale provides a unified and simple command execution mechanism, allowing users to fast deploy services seamlessly across various hardware platforms using the same command. This significantly reduces the entry barrier and enhances user experience.
21
- - Automated Deployment Optimization: FlagScale automatically optimizes distributed parallel strategies based on the computational capabilities of different AI chips, ensuring optimal resource allocation and efficient utilization, thereby improving overall deployment performance.
22
- - Automatic Operator Library Switching: Leveraging FlagScale's unified Runner mechanism and deep integration with FlagGems, users can seamlessly switch to the FlagGems operator library for inference by simply adding environment variables in the configuration file.
23
 
24
- ## Triton Support
25
 
26
- We validate the execution of RoboBrain2.0-7B model with a Triton-based operator library as a PyTorch alternative.
27
 
28
- We use a variety of Triton-implemented operation kernels to run the RoboBrain2.0-7B model. These kernels come from two main sources:
 
 
29
 
30
- - Most Triton kernels are provided by FlagGems (https://github.com/FlagOpen/FlagGems). You can enable FlagGems kernels by setting the environment variable USE_FLAGGEMS.
31
 
32
- - Also included are Triton kernels from vLLM, such as fused MoE.
33
 
34
- # Container Image Download
 
 
 
 
 
 
 
 
 
35
 
36
- | | Usage | Nvidia |
37
- | ----------- | ------------------------------------------------------------ | ------------------- |
38
- | Basic Image | basic software environment that supports FlagOS model running | |
39
  # Evaluation Results
40
 
41
- ## Benchmark Result
42
 
43
- | Metrics | RoboBrain2.0-7B-H100-CUDA | RoboBrain2.0-7B-FlagOS-Nvidia |
44
- |:-------------------|--------------------------|-----------------------------|
45
- | livebench_new | - | 0.504 |
46
- | aime | - | 0.167 |
47
- | GPQA(0-shot) | - | 0.395 |
48
- | MMLU | - | 0.697 |
49
- | MUSR | - | 0.570 |
50
- | TheoremQA | - | 0.151 |
51
 
 
52
 
53
- # How to Run Locally
54
- ## 📌 Getting Started
55
- ### Download open-source weights
56
 
57
- ```bash
58
 
59
- pip install modelscope
60
- modelscope download --model <Model Name> --local_dir <Cache Path>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
61
 
 
 
 
62
  ```
63
 
64
- ### Download the FlagOS image
65
 
66
- ```bash
67
- docker pull
68
  ```
69
 
70
  ### Start the inference service
71
 
72
- ```bash
 
73
  docker run --rm --init --detach \
74
  --net=host --uts=host --ipc=host \
75
  --security-opt=seccomp=unconfined \
@@ -81,33 +98,98 @@ docker run --rm --init --detach \
81
  -v /share:/share \
82
  --gpus all \
83
  --name flagos \
84
- \
85
  sleep infinity
86
-
87
  docker exec -it flagos bash
88
  ```
89
 
90
  ### Serve
91
 
92
- ```bash
93
- flagscale serve <Model>
 
 
 
 
 
 
 
 
 
 
 
94
  ```
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
95
 
96
  # Contributing
97
 
98
  We warmly welcome global developers to join us:
 
99
  1. Submit Issues to report problems
100
  2. Create Pull Requests to contribute code
101
  3. Improve technical documentation
102
  4. Expand hardware adaptation support
103
 
104
- # 📞 Contact Us
105
 
106
- Scan the QR code below to add our WeChat group
107
- send "FlagRelease"
108
-
109
- ![WeChat](image/group.png)
110
 
111
  # License
112
 
113
  This project and related model weights are licensed under the MIT License.
 
 
 
1
  # Introduction
2
 
3
+ **FlagOS** is a unified heterogeneous computing software stack for large models, co-developed with leading global chip manufacturers. With core technologies such as the **FlagScale** distributed training/inference framework, **FlagGems** universal operator library, **FlagCX** communication library, and **FlagTree** unified compiler, the **FlagRelease** platform leverages the FlagOS stack to automatically produce and release various combinations of <chip + open-source model>. This enables efficient and automated model migration across diverse chips, opening a new chapter for large model deployment and application.
4
 
5
+ Based on this, the **RoboBrain2.0-7B-FlagOS-FP8Dynamic** model is adapted for the Metax chip using the FlagOS software stack, enabling:
 
 
 
 
 
6
 
7
+ ### Integrated Deployment
8
 
9
+ - Deep integration with the open-source [FlagScale framework](https://github.com/FlagOpen/FlagScale)
10
+ - Out-of-the-box inference scripts with pre-configured hardware and software parameters
11
+ - Released **FlagOS** container image supporting deployment within minutes
12
 
13
+ ### Consistency Validation
14
 
15
+ - Rigorously evaluated through benchmark testing: Performance and results from the FlagOS software stack are compared against native stacks on multiple public.
16
 
17
+ # Technical Overview
 
 
18
 
19
+ ## **FlagScale Distributed Training and Inference Framework**
20
 
21
+ FlagScale is an end-to-end framework for large models across heterogeneous computing resources, maximizing computational efficiency and ensuring model validity through core technologies. Its key advantages include:
22
 
23
+ - **Unified Deployment Interface:** Standardized command-line tools support one-click service deployment across multiple hardware platforms, significantly reducing adaptation costs in heterogeneous environments.
24
+ - **Intelligent Parallel Optimization:** Automatically generates optimal distributed parallel strategies based on chip computing characteristics, achieving dynamic load balancing of computation/communication resources.
25
+ - **Seamless Operator Switching:** Deep integration with the FlagGems operator library allows high-performance operators to be invoked via environment variables without modifying model code.
26
 
27
+ ## **FlagGems Universal Large-Model Operator Library**
28
 
29
+ FlagGems is a Triton-based, cross-architecture operator library collaboratively developed with industry partners. Its core strengths include:
30
 
31
+ - **Full-stack Coverage**: Over 100 operators, with a broader range of operator types than competing libraries.
32
+ - **Ecosystem Compatibility**: Supports 7 accelerator backends. Ongoing optimizations have significantly improved performance.
33
+ - **High Efficiency**: Employs unique code generation and runtime optimization techniques for faster secondary development and better runtime performance compared to alternatives.
34
+
35
+ ## **FlagEval Evaluation Framework**
36
+
37
+ FlagEval (Libra)** is a comprehensive evaluation system and open platform for large models launched in 2023. It aims to establish scientific, fair, and open benchmarks, methodologies, and tools to help researchers assess model and training algorithm performance. It features:
38
+
39
+ - **Multi-dimensional Evaluation**: Supports 800+ model evaluations across NLP, CV, Audio, and Multimodal fields, covering 20+ downstream tasks including language understanding and image-text generation.
40
+ - **Industry-Grade Use Cases**: Has completed horizontal evaluations of mainstream large models, providing authoritative benchmarks for chip-model performance validation.
41
 
 
 
 
42
  # Evaluation Results
43
 
44
+ ## Benchmark Result
45
 
46
+ | Metrics | RoboBrain2.0-7B-H100-CUDA | RoboBrain2.0-7B-FlagOS-FP8Dynamic |
47
+ | ----------- | ------------------------- | --------------------------------- |
48
+ | coming soon | coming soon | coming soon |
 
 
 
 
 
49
 
50
+ # User Guide
51
 
52
+ ## General Information
 
 
53
 
54
+ **Basic Information**
55
 
56
+ | Type | Location |
57
+ | --------------- | ----------- |
58
+ | Model Weights | coming soon |
59
+ | Container Image | coming soon |
60
+
61
+ **Environment Setup**
62
+
63
+ | System Component | Version Information |
64
+ | ------------------------------- | ------------------------------------- |
65
+ | Accelerator Card Driver Version | Driver Version: 535.183.06 |
66
+ | Docker Version | Docker version 20.10.5, build 55c4c88 |
67
+ | Operating System | Description: Ubuntu 22.04.4 LTS |
68
+ | FlagScale | Version: 0.6.0 |
69
+ | FlagGems | Version: 2.2 |
70
+
71
+ ## Operation Steps
72
+
73
+ ### Download Open-source Model Weights
74
 
75
+ ```python
76
+ pip install modelscope
77
+ modelscope download --model <model path> --local_dir /share/RoboBrain2.0-7B
78
  ```
79
 
80
+ ### Download FlagOS Image
81
 
82
+ ```python
83
+ docker pull <image>
84
  ```
85
 
86
  ### Start the inference service
87
 
88
+ ```
89
+ #Container Startup
90
  docker run --rm --init --detach \
91
  --net=host --uts=host --ipc=host \
92
  --security-opt=seccomp=unconfined \
 
98
  -v /share:/share \
99
  --gpus all \
100
  --name flagos \
101
+ <image> \
102
  sleep infinity
103
+
104
  docker exec -it flagos bash
105
  ```
106
 
107
  ### Serve
108
 
109
+ ```python
110
+ flagscale serve robobrain2
111
+
112
+ #After the service starts, you will see output similar to the following:
113
+ #INFO: Started server process [392]
114
+ #INFO: Waiting for application startup.
115
+ #INFO: Application startup complete.
116
+ ```
117
+
118
+ # Service Invocation
119
+
120
+ ## API-based Invocation Script
121
+
122
  ```
123
+ import openai
124
+ openai.api_key = "EMPTY"
125
+ openai.base_url = "http://<server_ip>:9010/v1/"
126
+ model = "RoboBrain2.0-7B-nv-flagos-FP8Dynamic"
127
+ messages = [
128
+ {"role": "system", "content": "You are a helpful assistant."},
129
+ {"role": "user", "content": "What's the weather like today?"}
130
+ ]
131
+ response = openai.chat.completions.create(
132
+ model=model,
133
+ messages=messages,
134
+ temperature=0.7,
135
+ top_p=0.95,
136
+ stream=False,
137
+ )
138
+ for item in response:
139
+ print(item)
140
+ ```
141
+
142
+ ## AnythingLLM Integration Guide
143
+
144
+ #### 1. Download & Install
145
+
146
+ - Visit the official site: https://anythingllm.com/
147
+ - Choose the appropriate version for your OS (Windows/macOS/Linux)
148
+ - Follow the installation wizard to complete the setup
149
+
150
+ #### 2. Configuration
151
+
152
+ - Launch AnythingLLM
153
+ - Open settings (bottom left, fourth tab)
154
+ - Configure core LLM parameters
155
+ - Click "Save Settings" to apply changes
156
+
157
+ #### 3. Model Interaction
158
+
159
+ - After model loading is complete:
160
+ - Click **"New Conversation"**
161
+ - Enter your question (e.g., “Explain the basics of quantum computing”)
162
+ - Click the send button to get a response
163
+
164
+ # Frequently Asked Questions
165
+
166
+ ### Q1: What should I do if the model fails to load?
167
+
168
+ - Check if the model weight path is correct.
169
+ - Ensure the Qwen3-4B model files are present in the `/share` directory inside the container.
170
+ - Check the container logs: `docker logs flagos`.
171
+
172
+ ### Q2: API call returns a timeout error. What should I do?
173
+
174
+ - Verify that the server IP address is correct.
175
+ - Check the firewall settings to ensure port 9010 is open.
176
+ - Confirm that the service is running properly: `docker exec flagos ps aux | grep flagscale`.
177
 
178
  # Contributing
179
 
180
  We warmly welcome global developers to join us:
181
+
182
  1. Submit Issues to report problems
183
  2. Create Pull Requests to contribute code
184
  3. Improve technical documentation
185
  4. Expand hardware adaptation support
186
 
187
+ # Contact Us
188
 
189
+ ![image](image_.jpeg)
 
 
 
190
 
191
  # License
192
 
193
  This project and related model weights are licensed under the MIT License.
194
+
195
+ Release Date: 2025.07.12