{% extends "ewoooc_base.html" %} {% set active_page = 'obs_business_intel' %} {% block title %}商業 AI 戰果室{% endblock %} {% block extra_css %} {% endblock %} {% block ewooo_content %} {% import "admin/_observability_labels.html" as obs_label %} {% set rec_total = rec_by_strategy|sum(attribute='count') if rec_by_strategy else 0 %} {% set ns = namespace(conf_total=0, effective=0, backfired=0, neutral=0, verdict_total=0) %} {% for r in rec_by_strategy %} {% set ns.conf_total = ns.conf_total + ((r.avg_confidence or 0) * (r.count or 0)) %} {% endfor %} {% for v in verdict_stats %} {% set label = v.verdict or '未分類' %} {% set ns.verdict_total = ns.verdict_total + (v.count or 0) %} {% if label == 'effective' or label == 'success' or label == 'positive' %} {% set ns.effective = ns.effective + (v.count or 0) %} {% elif label == 'backfired' or label == 'negative' or label == 'failed' %} {% set ns.backfired = ns.backfired + (v.count or 0) %} {% else %} {% set ns.neutral = ns.neutral + (v.count or 0) %} {% endif %} {% endfor %} {% set avg_conf = (ns.conf_total / rec_total) if rec_total else 0 %} {% set effective_rate = ((ns.effective / ns.verdict_total) * 100) if ns.verdict_total else 0 %}
商業情報

商業 AI 戰果室

先看價格建議是否被採用,再追蹤閉環結果與競品訊號。

近 {{ days }} 天 {{ rec_total }} 筆價格建議 {{ ns.verdict_total }} 筆閉環結果
{% if error %}
{{ error }}
{% endif %}
高信心未跟進
{{ unfollowed_count }}
信心分 >= 0.8 且仍未轉行動計畫
平均信心分
{{ '%.0f'|format(avg_conf * 100) }}%
依策略建議量加權
有效率
{{ '%.0f'|format(effective_rate) }}%
有效 / 已回收結論
競品監測
{{ recent_competitor_prices|length }}
近 24h 價格變動樣本
{% if unfollowed_count > 0 %}
{{ unfollowed_count }} 筆高信心 AI 價格建議尚未跟進,建議優先轉為行動計畫或標記原因。
需人工決策
{% endif %}

外部促銷活動監控

AI Agent 以外部價格與折扣訊號監控促銷壓力,先對照 PChome 現況,再提出業績提升解法。

{{ promo_watch_rows|length }} 筆訊號
守價確認售價、折扣券與毛利底線,避免被外部促銷壓住。
組合用組合包、贈品或加價購拉高感知價值,不只跟價。
曝光把 PChome 有利商品推到搜尋、首頁、EDM 或活動入口。
會員用會員回饋、免運或售後服務對抗短期低價。
{% if promo_watch_rows %}
{% for r in promo_watch_rows %}
{{ r.pressure_label }} {{ r.source or '外部電商' }} {{ r.crawled_at or '-' }}
{{ r.product_name or r.sku }}
PChome 解法:{{ r.recommended_action }}
{{ '%.0f'|format(r.discount_pct or 0) }}%外部折扣
{{ '%.0f'|format(r.gap_abs or 0) }}價差壓力
{{ '%.2f'|format(r.match_score or 0) }}同款可信度
{% endfor %}
{% else %}
目前尚未捕捉到可判讀的外部促銷壓力;AI Agent 會持續觀察外部價格、折扣與同款可信度,捕捉到訊號後先進這裡,再進作戰清單。
{% endif %}

策略族群雷達

把 AI 價格建議依策略類型聚合,快速判斷目前主攻降價、防守或毛利修復。

{{ rec_by_strategy|length }} 類策略
{% if rec_by_strategy %}
{% for r in rec_by_strategy %}
{{ obs_label.strategy(r.strategy) }}
{{ r.count }}建議數
{{ '%.0f'|format((r.avg_confidence or 0) * 100) }}%信心
{{ '%.1f'|format(r.avg_gap_pct or 0) }}%價差
平均銷量變化 {{ '%.1f'|format(r.avg_sales_delta or 0) }}
{% endfor %}
{% else %}
目前觀測窗口沒有策略建議。
{% endif %}

最近 AI 價格建議

保留決策原因與競品價差,方便直接追到 SKU 層級。

Latest 20
{% if latest_recommendations %}
{% for r in latest_recommendations %}
{{ r.created_at or '-' }}
{{ r.sku }}
{{ r.name or '-' }}
{{ obs_label.strategy(r.strategy, '-') }} {{ '%.0f'|format((r.confidence or 0) * 100) }}%
{{ r.momo_price or '-' }} / {{ r.pchome_price or '-' }} 差距 {{ '%.1f'|format(r.gap_pct or 0) }}%
{{ r.reason or '尚無原因摘要' }}
{% endfor %}
{% else %}
目前沒有最新價格建議。
{% endif %}

閉環學習紀錄

追蹤行動計畫到實際結果的真實效果,這是 AI 能不能變聰明的核心證據。

{{ loop_records|length }} 筆紀錄
{% if loop_records %} {% for r in loop_records %} {% endfor %}
計畫 SKU 狀態 建立 / 執行 結論 指標 變化
#{{ r.plan_id }}
{{ obs_label.plan_type(r.plan_type, '-') }}
{{ r.sku }} {{ obs_label.status(r.status, '-') }} {{ r.created_at or '-' }} / {{ r.executed_at or '-' }} {{ obs_label.verdict(r.verdict, '-') }} {{ obs_label.metric(r.metric_type, '-') }}
{{ r.before or '-' }} → {{ r.after or '-' }}
{{ '%.1f'|format(r.change_pct or 0) }}%
{% else %}
尚未形成行動計畫到實際結果的閉環紀錄。
{% endif %}
資料來源:AI 價格建議、行動計畫、實際結果、競品比對與競品價格歷史。
{% endblock %} {% block extra_js %} {% endblock %}