# TTK 默认配置
# ── 复制一份修改,不要直接改此文件 ──

# ---------------------------------------------------------------------------
# remote — 远端 XPU 执行
# ---------------------------------------------------------------------------
remote:
  # 退避重试(503 时)
  backoff_base_s: 0.5
  backoff_max_s: 10.0
  backoff_jitter: 0.25
  max_503_retries: 10
  max_conn_retries: 5
  dispatch_deadline_s: 300       # 与 server run_deadline_s 一致

  # mTLS(跨机加密;留空 = HTTP 明文,同机/内网用)
  tls_ca: ""
  tls_cert: ""
  tls_key: ""
  # tls_skip_verify: false   # 内部 mTLS 且 server IP 多变时设 true: 关 client 对 server 的 hostname 校验(CA 签名验证仍防中间人); 默认 false(严格)

  # endpoints 默认不启用 —— 必须显式配置 endpoints(写进 yaml 或 --config)才启用三方连接
  # endpoints:
  #   - host: 127.0.0.1            # 默认 localhost(本机测试)
  #     port: 9090                 # 与 server 默认端口呼应
  #     # providers 由 /v1/heartbeat 发现(可选 yaml override);顺序无优先级语义

# ---------------------------------------------------------------------------
# frameworks — 硬件中立配置(framework_api backends)
# ---------------------------------------------------------------------------
# 每个 framework 段下是 hardware profile(key = role: npu/xpu/cpu)。
# torch_lib 是 torch 模块属性名('npu'/'mlu'/'cpu',torch binding value);
# profiler 为 'builtin' 或带 activities 的 dict。
# 仅 cpu 是合法默认(无 framework 段时 get_hardware_config 返回 {})。
frameworks:
  torch:
    npu:
      torch_lib: npu
      profiler: builtin
    # xpu 部署态补(在 ttk.conf.yaml 覆盖加此段),示例:
    # xpu:
    #   torch_lib: mlu           # 需 import torch_mlu
    #   profiler:
    #     module: torch.profiler
    #     activities: [CPU, MLU]