sw23.github.io
Convert between FP64, FP32, FP16, BF16, TF32, FP8, FP6, FP4, MX and integer formats. See bits, hex and precision loss under all five IEEE 754 rounding modes.
First seen 2026-11-05 · Last seen 2026-11-05 · Source: webmcp.com
Answer 2 · Act 3 · Transact 0 · Score: Not yet scored
Tool inspector
convert_format
Convert a value or bit pattern from one floating-point or integer format to another. Returns full encoding details for both formats and precision loss analysis.
Page: /fp-conv/
Input schema
| Property | Type | Required | Description |
|---|---|---|---|
value |
number,string | no | The value to convert. Accepts a number, hex string (read as an integer, e.g. "0xFF" is 255), or keyword. Exactly one of "value" and "bits" is required. |
bits |
string | no | The source as a bit pattern in the input format, binary (e.g. "0011110000000000") or hex with 0x prefix (e.g. "0x3C00"), read as decode_bits reads it and converted exactly as given. Use it to convert an exact encoding such as a NaN with a sign and payload. Exactly one of "value" and "bits" is required. |
inputFormat |
string,object | yes | Source format preset key or custom format object. |
outputFormat |
string,object | yes | Target format preset key or custom format object. |
roundingMode |
string | no | Rounding mode for encoding into the output format; the source operand is built with the input format's defaults. Options: "tiesToEven" (default, IEEE 754), "tiesToAway", "towardZero", "towardPositive", "towardNegative". |
overflowMode |
string | no | What an out-of-range output magnitude becomes; the source operand is built with the input format's defaults. "overflow" produces Infinity (or NaN when the format has no Infinity); "saturate" clamps to the largest finite value. Omit to use the per-format default. IEEE 754 §7.4 directed rounding still clamps finite overflow regardless. |
nanMode |
string | no | What a NaN source operand becomes; it has no effect on any other input. "canonical" gives the output format's canonical quiet NaN. "preserve" keeps the sign and as many high-order payload bits as fit, and quiets the result (IEEE 754-2019 §6.2.3). Default "canonical". Only a "bits" source has a payload to keep. |
Raw JSON schema
{
"type": "object",
"properties": {
"value": {
"type": [
"number",
"string"
],
"description": "The value to convert. Accepts a number, hex string (read as an integer, e.g. \"0xFF\" is 255), or keyword. Exactly one of \"value\" and \"bits\" is required."
},
"bits": {
"type": "string",
"description": "The source as a bit pattern in the input format, binary (e.g. \"0011110000000000\") or hex with 0x prefix (e.g. \"0x3C00\"), read as decode_bits reads it and converted exactly as given. Use it to convert an exact encoding such as a NaN with a sign and payload. Exactly one of \"value\" and \"bits\" is required."
},
"inputFormat": {
"type": [
"string",
"object"
],
"description": "Source format preset key or custom format object."
},
"outputFormat": {
"type": [
"string",
"object"
],
"description": "Target format preset key or custom format object."
},
"roundingMode": {
"type": "string",
"description": "Rounding mode for encoding into the output format; the source operand is built with the input format's defaults. Options: \"tiesToEven\" (default, IEEE 754), \"tiesToAway\", \"towardZero\", \"towardPositive\", \"towardNegative\".",
"enum": [
"tiesToEven",
"tiesToAway",
"towardZero",
"towardPositive",
"towardNegative"
]
},
"overflowMode": {
"type": "string",
"description": "What an out-of-range output magnitude becomes; the source operand is built with the input format's defaults. \"overflow\" produces Infinity (or NaN when the format has no Infinity); \"saturate\" clamps to the largest finite value. Omit to use the per-format default. IEEE 754 §7.4 directed rounding still clamps finite overflow regardless.",
"enum": [
"saturate",
"overflow"
]
},
"nanMode": {
"type": "string",
"description": "What a NaN source operand becomes; it has no effect on any other input. \"canonical\" gives the output format's canonical quiet NaN. \"preserve\" keeps the sign and as many high-order payload bits as fit, and quiets the result (IEEE 754-2019 §6.2.3). Default \"canonical\". Only a \"bits\" source has a payload to keep.",
"enum": [
"canonical",
"preserve"
]
}
},
"required": [
"inputFormat",
"outputFormat"
]
}
Similar websites
morphus.myles4miles.chatgpt.site
Morphus is an AI-native workspace for designing worlds and generating playable game experiences.
damnpdfs.com
Install the DamnPDFs Codex plugin, pair a browser workspace and use PDF, image and file tools from your coding agent. Includes setup and privacy limits.
insignifi4nt.github.io
broCAD/M: local-first CAD and CAM for parametric design, wire EDM planning, simulation and controller export.
cabinet.varera.studio
The Cartographer's Cabinet