isagellm-core 0.3.0.3__tar.gz → 0.3.0.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {isagellm_core-0.3.0.3/src/isagellm_core.egg-info → isagellm_core-0.3.0.4}/PKG-INFO +1 -72
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/README.md +0 -71
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/pyproject.toml +1 -1
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4/src/isagellm_core.egg-info}/PKG-INFO +1 -72
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__init__.py +1 -1
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__init__.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/__init__.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/MANIFEST.in +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/setup.cfg +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/setup.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/SOURCES.txt +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/dependency_links.txt +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/entry_points.txt +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/requires.txt +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/top_level.txt +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__main__.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/base_engine.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/config.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/demo.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/engine.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/engine_factory.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/factory.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/health.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/mock_engine.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/pd_executor.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/plugins.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/runner.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/runtime.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/workload.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/config.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/demo.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engine.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engine_factory.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__init__.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__init__.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/__init__.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/ascend.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/cpu.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/embedding.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/hf_cuda.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/mock.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/pytorch.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/__pycache__/pytorch_engine.cpython-311.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/ascend.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/cpu.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/embedding.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/hf_cuda.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/pytorch.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/engines/pytorch_engine.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/factory.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/health.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/pd_executor.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/plugins.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/py.typed +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/runner.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/runtime.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/workload.pyc +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_ci_smoke.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_config.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_cpu_engine_contract.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_cpu_engine_error_handling.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_e2e_cpu_integration.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_engine.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_engine_behavior_parity.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_engine_contract.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_engine_contract_simplified.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_pd_separation.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_pytorch_engine.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_streaming_pd.py +0 -0
- {isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/tests/test_task0_10_workload.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: isagellm-core
|
|
3
|
-
Version: 0.3.0.
|
|
3
|
+
Version: 0.3.0.4
|
|
4
4
|
Summary: sageLLM core runtime with PD separation (MVP)
|
|
5
5
|
Author: IntelliStream Team
|
|
6
6
|
License: Proprietary - IntelliStream
|
|
@@ -58,11 +58,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
58
58
|
│ │ • YAML/JSON 配置解析 │ │
|
|
59
59
|
│ │ • Pydantic v2 类型验证 │ │
|
|
60
60
|
│ └─────────────────────────────────────────────────────┘ │
|
|
61
|
-
│ ┌─────────────────────────────────────────────────────┐ │
|
|
62
|
-
│ │ Demo Runner (runner.py) │ │
|
|
63
|
-
│ │ • 协调 backend + engine + workload │ │
|
|
64
|
-
│ │ • M1 Demo Contract 验证 │ │
|
|
65
|
-
│ └─────────────────────────────────────────────────────┘ │
|
|
66
61
|
├─────────────────────────────────────────────────────────────┤
|
|
67
62
|
│ sagellm-backend (硬件抽象层) │
|
|
68
63
|
│ • BackendProvider (CPU/CUDA/Ascend) │
|
|
@@ -81,7 +76,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
81
76
|
- 🏭 EngineFactory - 支持自动发现与优先级选择
|
|
82
77
|
- 🎯 内置引擎实现(CPU/CUDA/Embedding)
|
|
83
78
|
- 🔌 插件系统 - 扩展引擎与后端
|
|
84
|
-
- 📊 Demo Runner - M1 验证框架
|
|
85
79
|
- ⚙️ 配置系统 - YAML/JSON + Pydantic v2
|
|
86
80
|
- ✅ CPU-First - 无 GPU 测试支持
|
|
87
81
|
|
|
@@ -108,11 +102,6 @@ pip install -e ".[dev]"
|
|
|
108
102
|
pytest tests/ -v
|
|
109
103
|
```
|
|
110
104
|
|
|
111
|
-
运行 Demo(CPU 模式):
|
|
112
|
-
```bash
|
|
113
|
-
python -m sagellm_core.demo --segments short
|
|
114
|
-
```
|
|
115
|
-
|
|
116
105
|
> 💡 **提示**:`isagellm-protocol` 和 `isagellm-backend` 会自动从 PyPI 安装。
|
|
117
106
|
> 如需本地联调:
|
|
118
107
|
> ```bash
|
|
@@ -142,23 +131,9 @@ Main configuration components:
|
|
|
142
131
|
- `EngineConfig`: Inference engine configuration
|
|
143
132
|
- `WorkloadConfig`: Workload parameters
|
|
144
133
|
- `OutputConfig`: Output paths and logging
|
|
145
|
-
- `DemoConfig`: Top-level demo configuration
|
|
146
134
|
|
|
147
135
|
### 配置示例
|
|
148
136
|
|
|
149
|
-
#### 快速开始
|
|
150
|
-
|
|
151
|
-
```bash
|
|
152
|
-
# CPU 模式(无需 GPU)
|
|
153
|
-
python -m sagellm.demo --config examples/config_cpu.yaml
|
|
154
|
-
|
|
155
|
-
# CUDA 生产模式
|
|
156
|
-
python -m sagellm.demo --config examples/config_cuda.yaml
|
|
157
|
-
|
|
158
|
-
# 昇腾生产模式
|
|
159
|
-
python -m sagellm.demo --config examples/config_ascend.yaml
|
|
160
|
-
```
|
|
161
|
-
|
|
162
137
|
#### 示例配置文件
|
|
163
138
|
|
|
164
139
|
- [config_cpu.yaml](examples/config_cpu.yaml) - CPU 模式(CI/开发)
|
|
@@ -200,52 +175,6 @@ except PluginResolutionError as e:
|
|
|
200
175
|
# Install hint: pip install isagellm-backend-ascend_cann
|
|
201
176
|
```
|
|
202
177
|
|
|
203
|
-
## Demo Runner CLI (Task0.08)
|
|
204
|
-
|
|
205
|
-
sagellm-core 提供了 Demo Runner CLI,用于执行 M1 Demo Contract 验证:
|
|
206
|
-
|
|
207
|
-
### 用法
|
|
208
|
-
|
|
209
|
-
```bash
|
|
210
|
-
# 使用配置文件运行
|
|
211
|
-
python -m sagellm_core.demo --config examples/demo_config.yaml
|
|
212
|
-
|
|
213
|
-
# 强制使用 CPU 模式(覆盖配置文件)
|
|
214
|
-
python -m sagellm_core.demo --config config.yaml --backend cpu
|
|
215
|
-
|
|
216
|
-
# 覆盖 workload 段选择
|
|
217
|
-
python -m sagellm_core.demo --config config.yaml --segments short,long
|
|
218
|
-
|
|
219
|
-
# 覆盖输出路径
|
|
220
|
-
python -m sagellm_core.demo --config config.yaml --output /tmp/metrics.json
|
|
221
|
-
|
|
222
|
-
# 启用 streaming 模式和详细日志
|
|
223
|
-
python -m sagellm_core.demo --config config.yaml --stream --verbose
|
|
224
|
-
```
|
|
225
|
-
|
|
226
|
-
### 示例配置
|
|
227
|
-
|
|
228
|
-
参见 [examples/demo_config.yaml](examples/demo_config.yaml):
|
|
229
|
-
|
|
230
|
-
```yaml
|
|
231
|
-
backend:
|
|
232
|
-
kind: cpu
|
|
233
|
-
device: cpu
|
|
234
|
-
|
|
235
|
-
engine:
|
|
236
|
-
kind: cpu
|
|
237
|
-
model: sshleifer/tiny-gpt2
|
|
238
|
-
|
|
239
|
-
workload:
|
|
240
|
-
segments: [short, long, stress]
|
|
241
|
-
concurrency: 4
|
|
242
|
-
kv_budget_tokens: 8192
|
|
243
|
-
|
|
244
|
-
output:
|
|
245
|
-
metrics_path: ./output/metrics.json
|
|
246
|
-
report_path: ./output/report.md
|
|
247
|
-
```
|
|
248
|
-
|
|
249
178
|
## Development Guide
|
|
250
179
|
|
|
251
180
|
### 快速开始
|
|
@@ -29,11 +29,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
29
29
|
│ │ • YAML/JSON 配置解析 │ │
|
|
30
30
|
│ │ • Pydantic v2 类型验证 │ │
|
|
31
31
|
│ └─────────────────────────────────────────────────────┘ │
|
|
32
|
-
│ ┌─────────────────────────────────────────────────────┐ │
|
|
33
|
-
│ │ Demo Runner (runner.py) │ │
|
|
34
|
-
│ │ • 协调 backend + engine + workload │ │
|
|
35
|
-
│ │ • M1 Demo Contract 验证 │ │
|
|
36
|
-
│ └─────────────────────────────────────────────────────┘ │
|
|
37
32
|
├─────────────────────────────────────────────────────────────┤
|
|
38
33
|
│ sagellm-backend (硬件抽象层) │
|
|
39
34
|
│ • BackendProvider (CPU/CUDA/Ascend) │
|
|
@@ -52,7 +47,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
52
47
|
- 🏭 EngineFactory - 支持自动发现与优先级选择
|
|
53
48
|
- 🎯 内置引擎实现(CPU/CUDA/Embedding)
|
|
54
49
|
- 🔌 插件系统 - 扩展引擎与后端
|
|
55
|
-
- 📊 Demo Runner - M1 验证框架
|
|
56
50
|
- ⚙️ 配置系统 - YAML/JSON + Pydantic v2
|
|
57
51
|
- ✅ CPU-First - 无 GPU 测试支持
|
|
58
52
|
|
|
@@ -79,11 +73,6 @@ pip install -e ".[dev]"
|
|
|
79
73
|
pytest tests/ -v
|
|
80
74
|
```
|
|
81
75
|
|
|
82
|
-
运行 Demo(CPU 模式):
|
|
83
|
-
```bash
|
|
84
|
-
python -m sagellm_core.demo --segments short
|
|
85
|
-
```
|
|
86
|
-
|
|
87
76
|
> 💡 **提示**:`isagellm-protocol` 和 `isagellm-backend` 会自动从 PyPI 安装。
|
|
88
77
|
> 如需本地联调:
|
|
89
78
|
> ```bash
|
|
@@ -113,23 +102,9 @@ Main configuration components:
|
|
|
113
102
|
- `EngineConfig`: Inference engine configuration
|
|
114
103
|
- `WorkloadConfig`: Workload parameters
|
|
115
104
|
- `OutputConfig`: Output paths and logging
|
|
116
|
-
- `DemoConfig`: Top-level demo configuration
|
|
117
105
|
|
|
118
106
|
### 配置示例
|
|
119
107
|
|
|
120
|
-
#### 快速开始
|
|
121
|
-
|
|
122
|
-
```bash
|
|
123
|
-
# CPU 模式(无需 GPU)
|
|
124
|
-
python -m sagellm.demo --config examples/config_cpu.yaml
|
|
125
|
-
|
|
126
|
-
# CUDA 生产模式
|
|
127
|
-
python -m sagellm.demo --config examples/config_cuda.yaml
|
|
128
|
-
|
|
129
|
-
# 昇腾生产模式
|
|
130
|
-
python -m sagellm.demo --config examples/config_ascend.yaml
|
|
131
|
-
```
|
|
132
|
-
|
|
133
108
|
#### 示例配置文件
|
|
134
109
|
|
|
135
110
|
- [config_cpu.yaml](examples/config_cpu.yaml) - CPU 模式(CI/开发)
|
|
@@ -171,52 +146,6 @@ except PluginResolutionError as e:
|
|
|
171
146
|
# Install hint: pip install isagellm-backend-ascend_cann
|
|
172
147
|
```
|
|
173
148
|
|
|
174
|
-
## Demo Runner CLI (Task0.08)
|
|
175
|
-
|
|
176
|
-
sagellm-core 提供了 Demo Runner CLI,用于执行 M1 Demo Contract 验证:
|
|
177
|
-
|
|
178
|
-
### 用法
|
|
179
|
-
|
|
180
|
-
```bash
|
|
181
|
-
# 使用配置文件运行
|
|
182
|
-
python -m sagellm_core.demo --config examples/demo_config.yaml
|
|
183
|
-
|
|
184
|
-
# 强制使用 CPU 模式(覆盖配置文件)
|
|
185
|
-
python -m sagellm_core.demo --config config.yaml --backend cpu
|
|
186
|
-
|
|
187
|
-
# 覆盖 workload 段选择
|
|
188
|
-
python -m sagellm_core.demo --config config.yaml --segments short,long
|
|
189
|
-
|
|
190
|
-
# 覆盖输出路径
|
|
191
|
-
python -m sagellm_core.demo --config config.yaml --output /tmp/metrics.json
|
|
192
|
-
|
|
193
|
-
# 启用 streaming 模式和详细日志
|
|
194
|
-
python -m sagellm_core.demo --config config.yaml --stream --verbose
|
|
195
|
-
```
|
|
196
|
-
|
|
197
|
-
### 示例配置
|
|
198
|
-
|
|
199
|
-
参见 [examples/demo_config.yaml](examples/demo_config.yaml):
|
|
200
|
-
|
|
201
|
-
```yaml
|
|
202
|
-
backend:
|
|
203
|
-
kind: cpu
|
|
204
|
-
device: cpu
|
|
205
|
-
|
|
206
|
-
engine:
|
|
207
|
-
kind: cpu
|
|
208
|
-
model: sshleifer/tiny-gpt2
|
|
209
|
-
|
|
210
|
-
workload:
|
|
211
|
-
segments: [short, long, stress]
|
|
212
|
-
concurrency: 4
|
|
213
|
-
kv_budget_tokens: 8192
|
|
214
|
-
|
|
215
|
-
output:
|
|
216
|
-
metrics_path: ./output/metrics.json
|
|
217
|
-
report_path: ./output/report.md
|
|
218
|
-
```
|
|
219
|
-
|
|
220
149
|
## Development Guide
|
|
221
150
|
|
|
222
151
|
### 快速开始
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: isagellm-core
|
|
3
|
-
Version: 0.3.0.
|
|
3
|
+
Version: 0.3.0.4
|
|
4
4
|
Summary: sageLLM core runtime with PD separation (MVP)
|
|
5
5
|
Author: IntelliStream Team
|
|
6
6
|
License: Proprietary - IntelliStream
|
|
@@ -58,11 +58,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
58
58
|
│ │ • YAML/JSON 配置解析 │ │
|
|
59
59
|
│ │ • Pydantic v2 类型验证 │ │
|
|
60
60
|
│ └─────────────────────────────────────────────────────┘ │
|
|
61
|
-
│ ┌─────────────────────────────────────────────────────┐ │
|
|
62
|
-
│ │ Demo Runner (runner.py) │ │
|
|
63
|
-
│ │ • 协调 backend + engine + workload │ │
|
|
64
|
-
│ │ • M1 Demo Contract 验证 │ │
|
|
65
|
-
│ └─────────────────────────────────────────────────────┘ │
|
|
66
61
|
├─────────────────────────────────────────────────────────────┤
|
|
67
62
|
│ sagellm-backend (硬件抽象层) │
|
|
68
63
|
│ • BackendProvider (CPU/CUDA/Ascend) │
|
|
@@ -81,7 +76,6 @@ sageLLM Core - 引擎协调层与运行时系统
|
|
|
81
76
|
- 🏭 EngineFactory - 支持自动发现与优先级选择
|
|
82
77
|
- 🎯 内置引擎实现(CPU/CUDA/Embedding)
|
|
83
78
|
- 🔌 插件系统 - 扩展引擎与后端
|
|
84
|
-
- 📊 Demo Runner - M1 验证框架
|
|
85
79
|
- ⚙️ 配置系统 - YAML/JSON + Pydantic v2
|
|
86
80
|
- ✅ CPU-First - 无 GPU 测试支持
|
|
87
81
|
|
|
@@ -108,11 +102,6 @@ pip install -e ".[dev]"
|
|
|
108
102
|
pytest tests/ -v
|
|
109
103
|
```
|
|
110
104
|
|
|
111
|
-
运行 Demo(CPU 模式):
|
|
112
|
-
```bash
|
|
113
|
-
python -m sagellm_core.demo --segments short
|
|
114
|
-
```
|
|
115
|
-
|
|
116
105
|
> 💡 **提示**:`isagellm-protocol` 和 `isagellm-backend` 会自动从 PyPI 安装。
|
|
117
106
|
> 如需本地联调:
|
|
118
107
|
> ```bash
|
|
@@ -142,23 +131,9 @@ Main configuration components:
|
|
|
142
131
|
- `EngineConfig`: Inference engine configuration
|
|
143
132
|
- `WorkloadConfig`: Workload parameters
|
|
144
133
|
- `OutputConfig`: Output paths and logging
|
|
145
|
-
- `DemoConfig`: Top-level demo configuration
|
|
146
134
|
|
|
147
135
|
### 配置示例
|
|
148
136
|
|
|
149
|
-
#### 快速开始
|
|
150
|
-
|
|
151
|
-
```bash
|
|
152
|
-
# CPU 模式(无需 GPU)
|
|
153
|
-
python -m sagellm.demo --config examples/config_cpu.yaml
|
|
154
|
-
|
|
155
|
-
# CUDA 生产模式
|
|
156
|
-
python -m sagellm.demo --config examples/config_cuda.yaml
|
|
157
|
-
|
|
158
|
-
# 昇腾生产模式
|
|
159
|
-
python -m sagellm.demo --config examples/config_ascend.yaml
|
|
160
|
-
```
|
|
161
|
-
|
|
162
137
|
#### 示例配置文件
|
|
163
138
|
|
|
164
139
|
- [config_cpu.yaml](examples/config_cpu.yaml) - CPU 模式(CI/开发)
|
|
@@ -200,52 +175,6 @@ except PluginResolutionError as e:
|
|
|
200
175
|
# Install hint: pip install isagellm-backend-ascend_cann
|
|
201
176
|
```
|
|
202
177
|
|
|
203
|
-
## Demo Runner CLI (Task0.08)
|
|
204
|
-
|
|
205
|
-
sagellm-core 提供了 Demo Runner CLI,用于执行 M1 Demo Contract 验证:
|
|
206
|
-
|
|
207
|
-
### 用法
|
|
208
|
-
|
|
209
|
-
```bash
|
|
210
|
-
# 使用配置文件运行
|
|
211
|
-
python -m sagellm_core.demo --config examples/demo_config.yaml
|
|
212
|
-
|
|
213
|
-
# 强制使用 CPU 模式(覆盖配置文件)
|
|
214
|
-
python -m sagellm_core.demo --config config.yaml --backend cpu
|
|
215
|
-
|
|
216
|
-
# 覆盖 workload 段选择
|
|
217
|
-
python -m sagellm_core.demo --config config.yaml --segments short,long
|
|
218
|
-
|
|
219
|
-
# 覆盖输出路径
|
|
220
|
-
python -m sagellm_core.demo --config config.yaml --output /tmp/metrics.json
|
|
221
|
-
|
|
222
|
-
# 启用 streaming 模式和详细日志
|
|
223
|
-
python -m sagellm_core.demo --config config.yaml --stream --verbose
|
|
224
|
-
```
|
|
225
|
-
|
|
226
|
-
### 示例配置
|
|
227
|
-
|
|
228
|
-
参见 [examples/demo_config.yaml](examples/demo_config.yaml):
|
|
229
|
-
|
|
230
|
-
```yaml
|
|
231
|
-
backend:
|
|
232
|
-
kind: cpu
|
|
233
|
-
device: cpu
|
|
234
|
-
|
|
235
|
-
engine:
|
|
236
|
-
kind: cpu
|
|
237
|
-
model: sshleifer/tiny-gpt2
|
|
238
|
-
|
|
239
|
-
workload:
|
|
240
|
-
segments: [short, long, stress]
|
|
241
|
-
concurrency: 4
|
|
242
|
-
kv_budget_tokens: 8192
|
|
243
|
-
|
|
244
|
-
output:
|
|
245
|
-
metrics_path: ./output/metrics.json
|
|
246
|
-
report_path: ./output/report.md
|
|
247
|
-
```
|
|
248
|
-
|
|
249
178
|
## Development Guide
|
|
250
179
|
|
|
251
180
|
### 快速开始
|
|
index 602cf12..7711161 100644
|
|
|
Binary file
|
|
index d565b50..89da120 100644
|
|
|
Binary file
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/isagellm_core.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/config.cpython-311.pyc
RENAMED
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/demo.cpython-311.pyc
RENAMED
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/engine.cpython-311.pyc
RENAMED
|
File without changes
|
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/factory.cpython-311.pyc
RENAMED
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/health.cpython-311.pyc
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/plugins.cpython-311.pyc
RENAMED
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/runner.cpython-311.pyc
RENAMED
|
File without changes
|
{isagellm_core-0.3.0.3 → isagellm_core-0.3.0.4}/src/sagellm_core/__pycache__/runtime.cpython-311.pyc
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|