compute_gqa_kv_cache
Calculate exact GQA KV-cache element counts and byte/GiB footprints across f16, bf16, q8_0, and q4_0 quantizations, with MHA comparison for memory sizing.
Instructions
Compute exact Grouped-Query Attention (GQA) KV-cache element counts (2 * layers * kv_heads * head_dim * tokens) and byte/GiB footprints across f16, bf16, q8_0, and q4_0 vs counterfactual Multi-Head Attention (MHA).
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "compute_gqa_kv_cache"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| preset | No | Optional built-in model preset (used unless `num_layers` is explicitly supplied). | qwen3-35b-a3b |
| head_dim | No | ||
| kv_quant | No | q8_0 | |
| num_layers | No | ||
| num_kv_heads | No | ||
| context_tokens | No | ||
| counterfactual_mha_heads | No |