encodeToolName function
Encode a dotted ToolDescriptor name (core.tap) into the wire form
accepted by Anthropic's tool API (core_tap).
Anthropic tool names match ^[a-zA-Z0-9_-]{1,64}$.
Implementation
String encodeToolName(String dotted) => dotted.replaceAll('.', '_');