Skip to content

Main content

Logit Bias One Token Odds Factor Tool

Apply an additive bias to one token with all other logits fixed; its odds against the rest multiply by exp(bias).

Loading tool…

Description

Return one-token logit-bias odds transformation.

Log probabilities, logits, guidance scales and sequence scores use different conventions. Temperature changes logit scale, an additive bias changes odds, and a sequence-length penalty changes ranking. One supplied scalar contribution can be checked independently of a complete probability distribution or model-generation process.

Return one-token logit-bias odds transformation.

When to use this tool

Use Logit Bias One Token Odds Factor when checking the stated probability, score, guidance or scale contribution.

How to use the tool and how it works

  1. Enter bias, baseProbability. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read oddsMultiplier, adjustedProbability. Use the output convention below.

Return one-token logit-bias odds transformation. Require baseProbability in [0,1]; oddsMultiplier = exp(bias), adjustedProbability preserves endpoints or returns 1/[1+((1-p)/p)*exp(-bias)].1

Input fieldMeaning and unitsAccepted input
biasBiasRequired. Finite number.
baseProbabilityBase ProbabilityRequired. Finite number; minimum 0; maximum 1.
Output fieldInterpretationReturned shape
oddsMultiplierOdds MultiplierRequired. Finite number.
adjustedProbabilityProbability after multiplying selected-token odds by exp(bias), keeping all other unnormalized weights fixed.Required. Finite number.
json
{
  "input": {
    "bias": 0.6931471805599453,
    "baseProbability": 0.25
  },
  "output": {
    "oddsMultiplier": 2,
    "adjustedProbability": 0.4
  }
}

Limitations and assumptions

  • This assumes other unnormalized class weights fixed; no full probability vector, token sampling or model calibration is performed.
  • 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 full distribution and model-specific decoding or training objective for normalized probabilities, preference optimization or actual generation.

References

  1. Calculation and input contract: artificial-intelligence/logit-bias-one-token-odds-factor — tool.io

Similar or alternative tools