huffman_code
Build a Huffman coding tree from input text to return the code table, encoded bit count, compression ratio, and entropy for compression analysis.
Instructions
Build a Huffman coding tree for the given text and return the code table, encoded bit count, compression ratio, and entropy.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"text": "<text>"
},
"name": "huffman_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | Text to encode (max 100000 chars) |