forked from luopingyi/xc_agent_platform_demo
select-opt dry-run: foothold verified_reuse first, build-config default w/ fallback, GPU enum map (45/45)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Read-only Phase2 pending draft report. Offline by default; opt-in configuration generation only."""
|
||||
"""Read-only Phase2 pending draft report. Token-resolvable build-config first; explicit sample fallback."""
|
||||
import json
|
||||
import os
|
||||
import sys
|
||||
@@ -10,7 +10,7 @@ from zoneinfo import ZoneInfo
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
sys.path.insert(0, str(ROOT))
|
||||
from src.pending_pool import build_ordered_candidates, input_path, experience_order
|
||||
from src.config_params import build_config_params, config_params_source, SOURCE, GAP
|
||||
from src.config_params import build_config_params_with_meta, SOURCE, GAP
|
||||
from src.queue_depth import queue_depth
|
||||
from src.task_add_client import build_payload
|
||||
|
||||
@@ -27,9 +27,9 @@ def _render(candidates, ts, src):
|
||||
c.get('section', 'B') == os.environ['PENDING_SECTION'].strip().upper()]
|
||||
depth = queue_depth()
|
||||
lines = [f'# 代提候选 / 需 Victor 确认 — Dry-run — {ts} (Asia/Shanghai)', '',
|
||||
'> 模式:dry-run;零网络写;需 Victor 人工提交/确认',
|
||||
'> 模式:dry-run;仅配置生成 API;无任务提交;需 Victor 人工提交/确认',
|
||||
'> 积分:待平台核实', '> perf_order=unset;order_source=experience(经验序 / 待平台核实)',
|
||||
f'> configParams source: {SOURCE}', f'> configParams_source={config_params_source()}', f'> {GAP}', '',
|
||||
f'> configParams source: {SOURCE}', '> API foothold evidence: GAP (not wired)', f'> {GAP}', '',
|
||||
'## A→B 顺序草稿', '', f'输入:{src};候选条数:{len(candidates)}',
|
||||
f'队列深度:{depth if depth is not None else "未知,需人工确认"}',
|
||||
'队列≥95:禁 live;适配 W1 优先,不抢空位。', '']
|
||||
@@ -45,8 +45,11 @@ def _render(candidates, ts, src):
|
||||
f'过滤:{c.get("skip_reason") or "名称硬门未命中;元数据/唯一性待人工核实"}', ''])
|
||||
lines.extend([f'未适配卡(仅 pending 缺口):{", ".join(gpus) or "未提供,需确认"}',
|
||||
'perf_order=unset;order_source=experience;天垓100 一般不扇出', ''])
|
||||
yaml, meta = build_config_params_with_meta(target)
|
||||
lines.extend([f'foothold_class={c.get("foothold_class", "unknown")}; evidence_source={c.get("evidence_source", "GAP")}; no_download={c.get("no_download", False)}',
|
||||
'; '.join(f'{key}={value}' for key, value in meta.items()), ''])
|
||||
draft = build_payload(model, target, 'vllm', strategy_id='<STRATEGY_ID>',
|
||||
config_params=build_config_params(target))
|
||||
config_params=yaml)
|
||||
# Display only; this truncated draft must never be submitted.
|
||||
draft['configParams'] = draft['configParams'][:400] + '\n… [truncated; dry-run only]'
|
||||
lines.extend(['build-config query: gpuType=<targetGpu>&framework=vllm&taskType=text-generation; POST empty body', 'POST 字段草稿(skipped 行禁止提交):', '```json', json.dumps(draft, ensure_ascii=False, indent=2), '```',
|
||||
|
||||
Reference in New Issue
Block a user