docs: add README.md and skill/SKILL.md
This commit is contained in:
parent
96652bceb4
commit
5ed1a6133b
19
README.md
19
README.md
@ -1,2 +1,21 @@
|
||||
# pipeline_dist
|
||||
|
||||
产线分发模块 —— 管理分发商(Distributor)及其授权的产线关联。
|
||||
|
||||
## 功能
|
||||
|
||||
- **分发商管理**:分发商注册、API Key 生成
|
||||
- **产线授权**:将产线授权给指定分发商
|
||||
|
||||
## 数据表
|
||||
|
||||
| 表 | 说明 |
|
||||
|---|------|
|
||||
| distributors | 分发商信息 |
|
||||
| distributor_pipeline | 分发商-产线授权关联 |
|
||||
|
||||
## 安装
|
||||
|
||||
```bash
|
||||
cd pkgs/pipeline_dist && pip install .
|
||||
```
|
||||
|
||||
28
skill/SKILL.md
Normal file
28
skill/SKILL.md
Normal file
@ -0,0 +1,28 @@
|
||||
---
|
||||
name: pipeline-dist
|
||||
description: "Pipeline distribution module — distributor management, API key generation, and pipeline authorization."
|
||||
---
|
||||
|
||||
# pipeline_dist
|
||||
|
||||
Manages distributors (downstream consumers) and their authorized pipeline access.
|
||||
|
||||
## Data Model
|
||||
|
||||
| Table | Key Fields |
|
||||
|-------|-----------|
|
||||
| `distributors` | id, name, api_key, status, org_id |
|
||||
| `distributor_pipeline` | id, distributor_id, pipeline_id |
|
||||
|
||||
## DSPY Endpoints
|
||||
|
||||
- `distributors_create/update/delete.dspy` — distributor CRUD
|
||||
- `distributor_generate_key.dspy` — generate API key
|
||||
- `distributor_pipeline_create/update/delete.dspy` — grant/revoke pipeline access
|
||||
- `get_search_distributor_id.dspy` — dropdown search
|
||||
|
||||
## Pitfalls
|
||||
|
||||
- API key uses `password_encode()` / `password_decode()` helpers.
|
||||
- CRUD scoped by `org_id` — multi-tenant safe.
|
||||
- Generated dirs (`wwwroot/distributors/`) are auto-generated by xls2ui.
|
||||
Loading…
x
Reference in New Issue
Block a user