Qrzysztof/functiongemma-prepaid-cards-tool-calling
FunctionGemma Prepaid-Cards Tool-Calling Dataset Synthetic training data for fine-tuning google/functiongemma-270m-it so it can recognize chat intents for buying prepaid cards, checking balances, and viewing transaction history, and emit the correct tool call. Tools Tool Purpose purchase_card(amount, card_type, email?, currency?) Buy a Digital Prepaid Visa or Virtual Prepaid Mastercard get_card_balance(card_number) Check the balance of a card… See the full description on the dataset page: https://huggingface.co/datasets/Qrzysztof/functiongemma-prepaid-cards-tool-calling.
FunctionGemma Prepaid-Cards Tool-Calling Dataset
Synthetic training data for fine-tuning google/functiongemma-270m-it so it can recognize chat intents for buying prepaid cards, checking balances, and viewing transaction history, and emit the correct tool call.
Tools
card_type values: digital_prepaid_visa | virtual_prepaid_mastercard.
Format
Each row follows the exact structure TRL's SFTTrainer expects for FunctionGemma:
messages— conversation in the OpenAI-style format (developer/user/assistantwithtool_calls/toolresponses)tools— JSON schemas generated withtransformers.utils.get_json_schemalang— ISO 639-1 code of the user messageskind— sample category (see below)template_id— deterministic id used for the train/test splitsplit—trainortest(deterministic)
Sample kinds
purchase— single-turn card purchase requestsbalance— single-turn balance requests (full, masked****1234,1234...9876,ending in 1234card numbers)tx— single-turn transaction-history requestschain_split— multi-turn: card number given in message 1, request in message 2chain_clarify— multi-turn: request without card number → assistant asks → user provides → tool callchain_purchase_clarify— multi-turn purchase: amount/type collected across turnschain_retry— tool called with missing arg → error response → clarification → retrychain_full/chain_full_balance/chain_full_tx— full function-calling loop: call → response → assistant textchain_two/chain_purchase_balance— long multi-tool conversationsgreet/negative— small talk that must not trigger a tool call
Languages
User messages are hand-translated in 84 languages (list in the language tag above). English has the largest template set (60+ purchase phrasings, 45 balance, 45 transaction).
Train/test split
- 5 languages are fully held out of training:
ja,ko,ar,sw,ur - ~12% of English templates are held out
- Split is deterministic per
template_id
Build
python3 build_dataset.py --pushTraining
See the companion training script in this repository (train.py) which follows the official FunctionGemma fine-tuning guide.
