{
  "_doc": "Function call 題庫：19 個情境、49 題。每個情境（call）拆成「選 function」（part=tool）與各參數題（part=參數名）。參數題以正確的 function 為前提獨立出題；報告另算整個 call 全對的比例。決策模型不能生成文字，所以金額、帳號這類自由格式參數，採「先用規則抽出候選值、再讓模型選」的混合作法；ready 題判斷參數是否齊全、能否直接呼叫。今天是 2026-10-12。",

  "templates": {
    "tool_select_zh": {
      "type": "choice",
      "instructions": "你是銀行客服 Agent 的工具路由。依對話內容，下一步應該呼叫哪一個 function？",
      "choices": [
        {"value": "get_transactions", "description": "get_transactions(card_type, period)：查詢客戶的交易明細。"},
        {"value": "freeze_card", "description": "freeze_card(card_type, reason)：凍結或掛失卡片。"},
        {"value": "create_dispute", "description": "create_dispute(reason)：對已發生的刷卡交易建立爭議或退款申請。"},
        {"value": "transfer_money", "description": "transfer_money(to_account, amount)：從客戶帳戶轉帳給別人。"},
        {"value": "get_exchange_rate", "description": "get_exchange_rate(currency)：查詢外幣匯率。"},
        {"value": "adjust_card_limit", "description": "adjust_card_limit(type, amount)：調整信用卡額度。"},
        {"value": "escalate_to_human", "description": "escalate_to_human(reason)：轉接真人客服。"},
        {"value": "search_faq", "description": "search_faq(query)：查詢常見問題知識庫，例如操作教學、一般規定。"},
        {"value": "no_tool", "description": "不需要呼叫任何 function：閒聊、道謝，或看不出客戶要做什麼。"}
      ]
    },
    "card_type_zh": {
      "type": "choice",
      "instructions": "這次 function 的 card_type 參數應該填什麼？",
      "choices": [
        {"value": "credit_card", "description": "信用卡"},
        {"value": "debit_card", "description": "金融卡（提款卡）"},
        {"value": "unspecified", "description": "客戶沒有說是哪一張卡"}
      ]
    },
    "period_zh": {
      "type": "choice",
      "instructions": "今天是 2026 年 10 月 12 日。get_transactions 的 period 參數應該填什麼？",
      "choices": [
        {"value": "today", "description": "今天（2026-10-12）"},
        {"value": "yesterday", "description": "昨天（2026-10-11）"},
        {"value": "this_month", "description": "本月（2026 年 10 月）"},
        {"value": "last_month", "description": "上個月（2026 年 9 月）"},
        {"value": "unspecified", "description": "客戶沒有指定期間"}
      ]
    },
    "freeze_reason_zh": {
      "type": "choice",
      "instructions": "freeze_card 的 reason 參數應該填什麼？",
      "choices": [
        {"value": "lost", "description": "卡片遺失"},
        {"value": "stolen", "description": "卡片被偷"},
        {"value": "fraud_suspected", "description": "懷疑有未授權交易"},
        {"value": "precaution", "description": "沒有發生異常，客戶只是想暫時鎖卡"}
      ]
    },
    "dispute_reason_zh": {
      "type": "choice",
      "instructions": "create_dispute 的 reason 參數應該填什麼？",
      "choices": [
        {"value": "duplicate_charge", "description": "重複扣款"},
        {"value": "not_received", "description": "已扣款但商品或服務沒收到"},
        {"value": "refund_missing", "description": "商家已退款但沒有入帳"},
        {"value": "amount_mismatch", "description": "扣款金額和實際消費不符"}
      ]
    },
    "currency_zh": {
      "type": "choice",
      "instructions": "get_exchange_rate 的 currency 參數應該填什麼？",
      "choices": [
        {"value": "USD", "description": "美元"},
        {"value": "JPY", "description": "日圓"},
        {"value": "EUR", "description": "歐元"},
        {"value": "CNY", "description": "人民幣"},
        {"value": "AUD", "description": "澳幣"},
        {"value": "other", "description": "其他幣別或沒有指定"}
      ]
    },
    "escalate_reason_zh": {
      "type": "choice",
      "instructions": "escalate_to_human 的 reason 參數應該填什麼？",
      "choices": [
        {"value": "complaint", "description": "客戶對服務不滿，因此要求真人"},
        {"value": "customer_request", "description": "客戶沒有不滿，只是想跟真人談"},
        {"value": "complex_case", "description": "問題超出 Agent 能處理的範圍"}
      ]
    },
    "limit_type_zh": {
      "type": "choice",
      "instructions": "adjust_card_limit 的 type 參數應該填什麼？",
      "choices": [
        {"value": "temporary", "description": "臨時調整（有期限）"},
        {"value": "permanent", "description": "永久調整"}
      ]
    },
    "transfer_ready_zh": {
      "type": "predicate",
      "instructions": "呼叫 transfer_money 需要「收款帳號」與「金額」兩個參數。這兩個參數是否都已經明確提供，可以直接呼叫？"
    }
  },

  "cases": [
    {"id": "t01-tool", "call": "t01", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "我的金融卡剛剛在捷運上掉了，快幫我停掉", "expected": "freeze_card"},
    {"id": "t01-card", "call": "t01", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "我的金融卡剛剛在捷運上掉了，快幫我停掉", "expected": "debit_card"},
    {"id": "t01-reason", "call": "t01", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "freeze_reason_zh",
     "input": "我的金融卡剛剛在捷運上掉了，快幫我停掉", "expected": "lost"},

    {"id": "t02-tool", "call": "t02", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "幫我查一下我信用卡上個月的消費明細", "expected": "get_transactions"},
    {"id": "t02-card", "call": "t02", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "幫我查一下我信用卡上個月的消費明細", "expected": "credit_card"},
    {"id": "t02-period", "call": "t02", "part": "period", "suite": "tool_param", "lang": "zh-TW", "template": "period_zh",
     "input": "幫我查一下我信用卡上個月的消費明細", "expected": "last_month"},

    {"id": "t03-tool", "call": "t03", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "昨天金融卡的交易有一筆怪怪的，我想先看一下明細", "expected": "get_transactions",
     "note": "提到「怪怪的」但要的是看明細，不是建立爭議"},
    {"id": "t03-card", "call": "t03", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "昨天金融卡的交易有一筆怪怪的，我想先看一下明細", "expected": "debit_card"},
    {"id": "t03-period", "call": "t03", "part": "period", "suite": "tool_param", "lang": "zh-TW", "template": "period_zh",
     "input": "昨天金融卡的交易有一筆怪怪的，我想先看一下明細", "expected": "yesterday"},

    {"id": "t04-tool", "call": "t04", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "Netflix 這個月扣了我兩次，幫我申請退回多扣的那筆", "expected": "create_dispute"},
    {"id": "t04-reason", "call": "t04", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "dispute_reason_zh",
     "input": "Netflix 這個月扣了我兩次，幫我申請退回多扣的那筆", "expected": "duplicate_charge"},

    {"id": "t05-tool", "call": "t05", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "在 momo 買的氣炸鍋三週了還沒到貨，可是信用卡已經扣款了，賣家都不回", "expected": "create_dispute"},
    {"id": "t05-reason", "call": "t05", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "dispute_reason_zh",
     "input": "在 momo 買的氣炸鍋三週了還沒到貨，可是信用卡已經扣款了，賣家都不回", "expected": "not_received"},

    {"id": "t06-tool", "call": "t06", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "現在日幣匯率多少？我下週要去大阪", "expected": "get_exchange_rate"},
    {"id": "t06-currency", "call": "t06", "part": "currency", "suite": "tool_param", "lang": "zh-TW", "template": "currency_zh",
     "input": "現在日幣匯率多少？我下週要去大阪", "expected": "JPY"},

    {"id": "t07-tool", "call": "t07", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "下個月要去巴黎，想先看看歐元現在換多少", "expected": "get_exchange_rate"},
    {"id": "t07-currency", "call": "t07", "part": "currency", "suite": "tool_param", "lang": "zh-TW", "template": "currency_zh",
     "input": "下個月要去巴黎，想先看看歐元現在換多少", "expected": "EUR"},

    {"id": "t08-tool", "call": "t08", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "我帳戶還有 52,000，幫我轉 18,000 房租給房東，帳號 808-1234567", "expected": "transfer_money"},
    {"id": "t08-amount", "call": "t08", "part": "amount", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 amount 參數，應該填入訊息中的哪一個數值？",
                  "choices": [{"value": "52,000"}, {"value": "18,000"}, {"value": "808-1234567"}]},
     "input": "我帳戶還有 52,000，幫我轉 18,000 房租給房東，帳號 808-1234567", "expected": "18,000"},
    {"id": "t08-account", "call": "t08", "part": "to_account", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 to_account 參數，應該填入訊息中的哪一個值？",
                  "choices": [{"value": "52,000"}, {"value": "18,000"}, {"value": "808-1234567"}]},
     "input": "我帳戶還有 52,000，幫我轉 18,000 房租給房東，帳號 808-1234567", "expected": "808-1234567"},
    {"id": "t08-ready", "call": "t08", "part": "ready", "suite": "tool_ready", "lang": "zh-TW", "template": "transfer_ready_zh",
     "input": "我帳戶還有 52,000，幫我轉 18,000 房租給房東，帳號 808-1234567", "expected": true},

    {"id": "t09-tool", "call": "t09", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "幫我轉錢給我媽", "expected": "transfer_money"},
    {"id": "t09-ready", "call": "t09", "part": "ready", "suite": "tool_ready", "lang": "zh-TW", "template": "transfer_ready_zh",
     "input": "幫我轉錢給我媽", "expected": false, "note": "沒有帳號也沒有金額，應先追問"},

    {"id": "t10-tool", "call": "t10", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "不要轉到上次那個 012-555666 了，這次轉 3 萬到我新開的帳戶 700-888999", "expected": "transfer_money"},
    {"id": "t10-amount", "call": "t10", "part": "amount", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 amount 參數，應該填入訊息中的哪一個值？",
                  "choices": [{"value": "012-555666"}, {"value": "3 萬"}, {"value": "700-888999"}]},
     "input": "不要轉到上次那個 012-555666 了，這次轉 3 萬到我新開的帳戶 700-888999", "expected": "3 萬"},
    {"id": "t10-account", "call": "t10", "part": "to_account", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 to_account 參數，應該填入訊息中的哪一個值？",
                  "choices": [{"value": "012-555666"}, {"value": "3 萬"}, {"value": "700-888999"}]},
     "input": "不要轉到上次那個 012-555666 了，這次轉 3 萬到我新開的帳戶 700-888999", "expected": "700-888999",
     "note": "否定了舊帳號"},
    {"id": "t10-ready", "call": "t10", "part": "ready", "suite": "tool_ready", "lang": "zh-TW", "template": "transfer_ready_zh",
     "input": "不要轉到上次那個 012-555666 了，這次轉 3 萬到我新開的帳戶 700-888999", "expected": true},

    {"id": "t11-tool", "call": "t11", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "你們客服一直在踢皮球，問三次都沒解決，叫你們主管來", "expected": "escalate_to_human"},
    {"id": "t11-reason", "call": "t11", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "escalate_reason_zh",
     "input": "你們客服一直在踢皮球，問三次都沒解決，叫你們主管來", "expected": "complaint"},

    {"id": "t12-tool", "call": "t12", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "好的謝謝你，問題解決了", "expected": "no_tool"},

    {"id": "t13-tool", "call": "t13", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "我的信用卡好像被盜刷了，先幫我把卡鎖起來，我再慢慢確認", "expected": "freeze_card",
     "note": "提到盜刷，但客戶要的是先鎖卡"},
    {"id": "t13-card", "call": "t13", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "我的信用卡好像被盜刷了，先幫我把卡鎖起來，我再慢慢確認", "expected": "credit_card"},
    {"id": "t13-reason", "call": "t13", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "freeze_reason_zh",
     "input": "我的信用卡好像被盜刷了，先幫我把卡鎖起來，我再慢慢確認", "expected": "fraud_suspected"},

    {"id": "t14-tool", "call": "t14", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "出國這兩個禮拜信用卡都不會用到，可以先暫時鎖起來嗎？回來再打開", "expected": "freeze_card"},
    {"id": "t14-card", "call": "t14", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "出國這兩個禮拜信用卡都不會用到，可以先暫時鎖起來嗎？回來再打開", "expected": "credit_card"},
    {"id": "t14-reason", "call": "t14", "part": "reason", "suite": "tool_param", "lang": "zh-TW", "template": "freeze_reason_zh",
     "input": "出國這兩個禮拜信用卡都不會用到，可以先暫時鎖起來嗎？回來再打開", "expected": "precaution"},

    {"id": "t15-tool", "call": "t15", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "下個月要出國，信用卡額度先臨時調到 15 萬", "expected": "adjust_card_limit"},
    {"id": "t15-type", "call": "t15", "part": "type", "suite": "tool_param", "lang": "zh-TW", "template": "limit_type_zh",
     "input": "下個月要出國，信用卡額度先臨時調到 15 萬", "expected": "temporary"},

    {"id": "t16-tool", "call": "t16", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "客戶：我要查交易紀錄\n客服：請問要查哪一張卡、哪段期間呢？\n客戶：金融卡，這個月的", "expected": "get_transactions"},
    {"id": "t16-card", "call": "t16", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "客戶：我要查交易紀錄\n客服：請問要查哪一張卡、哪段期間呢？\n客戶：金融卡，這個月的", "expected": "debit_card"},
    {"id": "t16-period", "call": "t16", "part": "period", "suite": "tool_param", "lang": "zh-TW", "template": "period_zh",
     "input": "客戶：我要查交易紀錄\n客服：請問要查哪一張卡、哪段期間呢？\n客戶：金融卡，這個月的", "expected": "this_month",
     "note": "參數分散在多輪對話"},

    {"id": "t17-tool", "call": "t17", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "我想知道 App 要去哪裡看交易明細，選單好複雜", "expected": "search_faq",
     "note": "問操作方式，不是要 Agent 幫他查明細"},

    {"id": "t18-tool", "call": "t18", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "轉 5,000 給 700-888999，喔不對，是 700-888998", "expected": "transfer_money"},
    {"id": "t18-amount", "call": "t18", "part": "amount", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 amount 參數，應該填入訊息中的哪一個值？",
                  "choices": [{"value": "5,000"}, {"value": "700-888999"}, {"value": "700-888998"}]},
     "input": "轉 5,000 給 700-888999，喔不對，是 700-888998", "expected": "5,000"},
    {"id": "t18-account", "call": "t18", "part": "to_account", "suite": "tool_param_extract", "lang": "zh-TW",
     "question": {"type": "choice", "instructions": "transfer_money 的 to_account 參數，應該填入訊息中的哪一個值？",
                  "choices": [{"value": "5,000"}, {"value": "700-888999"}, {"value": "700-888998"}]},
     "input": "轉 5,000 給 700-888999，喔不對，是 700-888998", "expected": "700-888998", "note": "客戶自我更正"},
    {"id": "t18-ready", "call": "t18", "part": "ready", "suite": "tool_ready", "lang": "zh-TW", "template": "transfer_ready_zh",
     "input": "轉 5,000 給 700-888999，喔不對，是 700-888998", "expected": true},

    {"id": "t19-tool", "call": "t19", "part": "tool", "suite": "tool_select", "lang": "zh-TW", "template": "tool_select_zh",
     "input": "幫我看一下信用卡最近刷了哪些", "expected": "get_transactions"},
    {"id": "t19-card", "call": "t19", "part": "card_type", "suite": "tool_param", "lang": "zh-TW", "template": "card_type_zh",
     "input": "幫我看一下信用卡最近刷了哪些", "expected": "credit_card"},
    {"id": "t19-period", "call": "t19", "part": "period", "suite": "tool_param", "lang": "zh-TW", "template": "period_zh",
     "input": "幫我看一下信用卡最近刷了哪些", "expected": "unspecified", "note": "「最近」沒有明確期間"}
  ]
}
