Description
Center a supplied quantized code around its zero point.
Model and prompt records distinguish token indices, offset units, reserved capacity, code scales and numeric representations. A common softmax shift is mathematically invariant but can alter rounded inputs. Literal brace doubling and citation tokens are format conventions rather than universal template or evidence validation.
Center a supplied quantized code around its zero point.
When to use this tool
Use Quantized Weight Zero Point Code when you already have quantizedCode, zeroPoint, minimumCode, maximumCode and need to center a supplied quantized code around its zero point.
How to use the tool and how it works
- Enter quantizedCode, zeroPoint, minimumCode, maximumCode. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read centeredCode, isZeroCode. Inspect isZeroCode before interpreting the associated values.
Require ordered safe whole code bounds and both code/zeroPoint within them; subtract exactly with BigInt and export a safe centeredCode, plus literal equality for isZeroCode.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| quantizedCode | Quantized Code | Required. Safe integer. |
| zeroPoint | Zero Point | Required. Safe integer. |
| minimumCode | Minimum Code | Required. Safe integer. |
| maximumCode | Maximum Code | Required. Safe integer. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| centeredCode | Exact quantizedCode-zeroPoint, exported only when safe; no dequantization scale is applied. | Required. Safe integer. |
| isZeroCode | Is Zero Code | Required. Boolean. |
{
"input": {
"quantizedCode": 130,
"zeroPoint": 128,
"minimumCode": 0,
"maximumCode": 255
},
"output": {
"centeredCode": 2,
"isZeroCode": false
}
} Limitations and assumptions
- No scale is applied, so centered code is not a reconstructed weight. A wide valid code range can still produce an unsafe difference and be rejected.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use the complete tokenizer, template, model contract and evaluation method. Verify actual capacity, vocabulary and numerical behavior when supplied budgets, local masks or representation checks cannot establish correct model operation.
References
Similar or alternative tools
- Model Nonfinite Logit Flag
Identify nonfinite numeric values represented by supplied logit strings.
- Softmax Logit Shift Invariance Residual
Measure numerical softmax change after a supplied common logit shift.