Make multi-head attention's shape contract explicit by splitting one representation into equal-width head vectors.
Required APIdef split_heads(vector, head_count):
return [head, ...]BehaviorThink through the mechanism first if you want the extra reasoning step. It never blocks the editor.
split_heads([1, 2, 3, 4], 2)concatenating heads restores the model vector
split_heads([1, 2, 3, 4], 4)head width can shrink to one feature
2 hidden edge tests run after the visible contract passes.
Run Tests to see the contract verdicts here.