Description
Rotate one rotary-embedding coordinate pair.
Language-model bookkeeping separates scores, probabilities, dimensions, capacity and positional transforms. A local ranking, padding or coordinate operation can illustrate a model component without running a model, sampling a token, fitting calibration or demonstrating output quality.
Rotate one rotary-embedding coordinate pair.
When to use this tool
Use Rotary Embedding One Pair Rotation when checking the stated model-dimension, ranking, probability-prefix or local transform convention.
How to use the tool and how it works
- Enter first, second, angleRadians. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read firstRotated, secondRotated. Use the output convention below.
Rotate one rotary-embedding coordinate pair. firstRotated = first*cos(angleRadians)-second*sin(angleRadians), secondRotated = first*sin(angleRadians)+second*cos(angleRadians).1
Rotary position embedding uses pairwise coordinate rotations. This helper performs one supplied planar rotation without constructing positional angles or a full attention model.2
| Input field | Meaning and units | Accepted input |
|---|---|---|
| first | First | Required. Finite number. |
| second | Second | Required. Finite number. |
| angleRadians | Supplied planar rotation angle in radians; no positional frequency schedule is constructed. | Required. Finite number. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| firstRotated | First Rotated | Required. Finite number. |
| secondRotated | Second Rotated | Required. Finite number. |
{
"input": {
"first": 3,
"second": 4,
"angleRadians": 0
},
"output": {
"firstRotated": 3,
"secondRotated": 4
}
} Limitations and assumptions
- The angle is supplied in radians; no frequency schedule, token position, full embedding or transformer inference is generated.
- 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 a complete implementation with verified tensor/token conventions and appropriate model evaluation when actual inference, memory, sampling or quality results are required.
References
-
Calculation and input contract: artificial-intelligence/rotary-embedding-one-pair-rotation — tool.io
-
RoFormer: enhanced transformer with rotary position embedding — Jianlin Su and coauthors
Similar or alternative tools
- Astrological Harmonic Chart Calculator
Return a supplied harmonic angular transform.
- Classifier Free Guidance One Coordinate Tool
Use unconditional + scale*(conditional-unconditional); scale 1 reproduces the conditional prediction.