Diffusion tool caller 150M โ slot posttrain
Code and reproduction: github.com/chameleon-lizard/diffusion-toolcaller
This custom PyTorch checkpoint adds a binary tool-routing head and a three-state (absent/null/value) slot head to the masked diffusion backbone. The diffusion token head generates each selected field's raw value; code validates types and assembles the outer JSON. It selects at most one tool and does not execute tools.
The backbone started from the long-pretrain checkpoint, then received 1.6B mid-training input tokens and five epochs of slot-format SFT on roughly 10k filtered xLAM examples. The exported weights come from the fifth SFT epoch. Candidate-tool prompts have a 384-token budget; each slot has up to 128 output positions. RoPE is computed in FP32 as in training.
Use the code repository and install its requirements plus CUDA PyTorch:
hf download chameleon-lizard/buckwheat-diffusion-toolcaller --local-dir model
python call.py --checkpoint model --tools examples/unseen_quotes.tools.json \
--query "Get quotes from the inspiration category on page 3."
This is not a transformers.AutoModel package. Files are model.safetensors, config.json, a validation-only calibration.json (threshold 0.035), and the exact training tokenizer.json (SHA-256 6c8aaa9a542084f2457eab775d4eeb51f92a70c0fd9de28d5edb0ddec3c08d30). Optimizer and RNG state, absolute paths, and raw data were removed.
On a 600-example BFCL v4 subset with the upstream AST checker, forced-call accuracy was 298/600: 203/400 simple_python, 95/200 multiple. This is not the official overall BFCL score. A separate thresholded end-to-end comparison used 64 output positions and 64 denoising steps and found 1,375/3,051 pooled correct cases over selected non-parallel categories. Parallel calls, Java/JavaScript, and interactive categories were not evaluated with this adapter. The model can choose a wrong tool or value; validate proposed calls before execution.
Training data includes xLAM/APIGen examples; see APIGen. The tokenizer's upstream license has not been independently established here. This is a research release, not a tool-execution system.
- Downloads last month
- -