Files
param-auto-manager/config/agent_fill_fields_template.txt
T
hz4th_coder 4177acf75c refactor: 步骤5简化为数据生成+格式检查
- 步骤5不再提交到ParamHub,只生成产品数据
- 智能体任务模板去掉提交部分,增加格式检查要求
- 新增本地格式验证方法_validate_product_data
- 验证字段类型、必填项、数值范围等
- 步骤6恢复为独立的提交审核步骤
- 更新步骤描述为'调用智能体生成产品数据并检查格式'
2026-07-15 16:42:19 +08:00

66 lines
2.4 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
## 任务背景
### 产品基本信息
- **产品名称:** {{product_name}}
- **产品类别:** {{category}}
- **子类别:** {{subcategory}}
### 相关内容数据ID
上一步已筛选出以下与产品直接相关且对参数提取有用的内容库数据ID:
{{relevant_content_ids}}
## 任务要求
请完成以下工作:
### 1. 获取对应类别的字段配置
首先,请访问 ParamHub API 文档获取对应类别的字段定义:
- API文档地址:http://192.168.2.8:12007/hz4th_coder/param-hub-python/src/branch/master/API.md
- 根据产品类别({{category}})确定应该使用哪个API
- AI模型 → `/api/models`,字段包括:name, organization, parameters, context_length, mmlu, publish_date, visible, is_pinned
- GPU → `/api/gpus`,字段包括:name, manufacturer, memory_gb, cuda_cores, tensor_cores, price_usd, release_year, visible, is_pinned
- CPU → `/api/cpus`,字段包括:name, manufacturer, cores, threads, base_clock, boost_clock, price_usd, visible, is_pinned
- 其他动态分类 → `/api/items/{category_id}`
### 2. 从内容库获取数据内容
根据上述数据ID,从内容库中获取每条数据的完整内容。
### 3. 整理产品参数
根据获取到的内容,提取并整理产品的各项参数,严格按照API文档中定义的字段格式填充。
### 4. 格式检查
对生成的数据进行以下检查:
- 必填字段是否齐全(name必须有值)
- 字段类型是否正确(数字字段不能是字符串,布尔字段必须是true/false)
- 字段值是否合理(如参数量应为正数,价格应为正数等)
- 如果发现格式问题,请修正后重新输出
### 5. 输出要求
请以JSON格式输出最终的产品数据(不要提交,只输出数据):
```json
{
"success": true,
"product_data": {
"name": "产品名称",
"field1": "值1",
"field2": "值2",
"visible": true,
"is_pinned": false
},
"data_sources": [数据ID列表],
"format_check": {
"passed": true,
"issues_found": [],
"issues_fixed": []
},
"message": "数据生成说明"
}
```
**注意:**
- 严格按照API文档的字段定义填充数据
- 不要编造或推测任何参数,只使用内容库中实际存在的信息
- 如果某些字段无法从内容中提取,可以留空或填写默认值
- 不要执行任何提交操作,只生成并输出数据
- 确保输出的JSON格式正确,可以被程序解析