---
title: "RopeScaling"
sidebar_label: "RopeScaling"
description: "Kotlin binding reference: RopeScaling."
---

<!-- Generated by tools/api_reference/generate_api_docs.py. Do not edit. -->

//[clika-runtime](../../../index.md)/[io.clika.runtime](../index.md)/[RopeScaling](index.md)

# RopeScaling

[common]\
enum [RopeScaling](index.md) : [Enum](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-enum/index.html)&lt;[RopeScaling](index.md)&gt; 

RoPE frequency-scaling family (long-context extension). Every family also folds an OPTIONAL 1-D `[rotary_dim/2]``freq_factors` per-band divisor table into its frequencies (absent ⇒ no division); the 2-D `[2, rotary_dim/2]` short/long-row form belongs to the LongRoPE families alone, which REQUIRE a table in one of the two shapes.

## Entries

| | |
|---|---|
| [NONE](NONE/index.md) | [common]<br>[NONE](NONE/index.md)<br>inv_freq = theta^(-2i/d) |
| [LINEAR](LINEAR/index.md) | [common]<br>[LINEAR](LINEAR/index.md)<br>position interpolation: angle uses pos / scale |
| [NTK](NTK/index.md) | [common]<br>[NTK](NTK/index.md)<br>static NTK-aware base scaling |
| [DYNAMIC_NTK](DYNAMIC_NTK/index.md) | [common]<br>[DYNAMIC_NTK](DYNAMIC_NTK/index.md)<br>NTK with a runtime sequence-length trigger |
| [YARN](YARN/index.md) | [common]<br>[YARN](YARN/index.md)<br>wavelength-ramp interpolation (beta_fast/beta_slow) |
| [LLAMA3](LLAMA3/index.md) | [common]<br>[LLAMA3](LLAMA3/index.md)<br>Llama-3.1 piecewise inv_freq smoothing |
| [LONG_ROPE](LONG_ROPE/index.md) | [common]<br>[LONG_ROPE](LONG_ROPE/index.md)<br>per-dim short/long factors; row + attention factor keyed on the BUILT cache length vs original_max_pos |
| [PROPORTIONAL](PROPORTIONAL/index.md) | [common]<br>[PROPORTIONAL](PROPORTIONAL/index.md)<br>zero-tail: first ⌊scale·d/2⌋ bands carry real frequencies (exponent over the full d), the rest are zero (identity rotation) |
| [LONG_ROPE_SHORT](LONG_ROPE_SHORT/index.md) | [common]<br>[LONG_ROPE_SHORT](LONG_ROPE_SHORT/index.md)<br>LongRoPE, SHORT row pinned statically (row 0); attention factor from the config ratio (`scale`), never the built length |
| [LONG_ROPE_LONG](LONG_ROPE_LONG/index.md) | [common]<br>[LONG_ROPE_LONG](LONG_ROPE_LONG/index.md)<br>LongRoPE, LONG row pinned statically (row 1); attention factor from the config ratio (`scale`) |

## Types

| Name | Summary |
|---|---|
| [Companion](Companion/index.md) | [common]<br>object [Companion](Companion/index.md) |

## Properties

| Name | Summary |
|---|---|
| [code](code.md) | [common]<br>val [code](code.md): [Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) |
| [name](../PaddingSide/LEFT/index.md) | [common]<br>val [name](../PaddingSide/LEFT/index.md): [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) |
| [ordinal](../PaddingSide/LEFT/index.md) | [common]<br>val [ordinal](../PaddingSide/LEFT/index.md): [Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) |

## Functions

| Name | Summary |
|---|---|
| [valueOf](valueOf.md) | [common]<br>fun [valueOf](valueOf.md)(value: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)): [RopeScaling](index.md)<br>Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.) |
| [values](values.md) | [common]<br>fun [values](values.md)(): [Array](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html)&lt;[RopeScaling](index.md)&gt;<br>Returns an array containing the constants of this enum type, in the order they're declared. |