Sync contents

This commit is contained in:
Daniel Xu 2025-11-25 06:15:14 +00:00
parent 937c36e9b1
commit 9bf0df6796
9 changed files with 5 additions and 179 deletions

View file

@ -1,5 +1,3 @@
# `tinker.types.optim_step_request`
## `AdamParams` Objects
```python
@ -22,8 +20,6 @@ Coefficient used for computing running averages of gradient square
Term added to the denominator to improve numerical stability
# `tinker.types.optim_step_response`
## `OptimStepResponse` Objects
```python
@ -34,8 +30,6 @@ class OptimStepResponse(BaseModel)
Optimization step metrics as key-value pairs
# `tinker.types.model_input`
## `ModelInput` Objects
```python
@ -49,7 +43,6 @@ Sequence of input chunks (formerly TokenSequence)
#### `from_ints`
```python
@classmethod
def from_ints(cls, tokens: List[int]) -> "ModelInput"
```
@ -67,7 +60,6 @@ Throws exception if there are any non-token chunks
#### `length`
```python
@property
def length() -> int
```
@ -76,7 +68,6 @@ Return the total context length used by this ModelInput.
#### `empty`
```python
@classmethod
def empty(cls) -> "ModelInput"
```
@ -98,8 +89,6 @@ def append_int(token: int) -> "ModelInput"
Add a new token, return a new ModelInput.
# `tinker.types.weights_info_response`
## `WeightsInfoResponse` Objects
```python
@ -108,8 +97,6 @@ class WeightsInfoResponse(BaseModel)
Minimal information for loading public checkpoints.
# `tinker.types.checkpoint`
## `Checkpoint` Objects
```python
@ -165,14 +152,11 @@ The checkpoint ID
#### `from_tinker_path`
```python
@classmethod
def from_tinker_path(cls, tinker_path: str) -> "ParsedCheckpointTinkerPath"
```
Parse a tinker path to an instance of ParsedCheckpointTinkerPath
# `tinker.types.checkpoint_archive_url_response`
## `CheckpointArchiveUrlResponse` Objects
```python
@ -187,8 +171,6 @@ Signed URL to download the checkpoint archive
Unix timestamp when the signed URL expires, if available
# `tinker.types.sampled_sequence`
## `SampledSequence` Objects
```python
@ -207,8 +189,6 @@ List of generated token IDs
Log probabilities for each token (optional)
# `tinker.types.try_again_response`
## `TryAgainResponse` Objects
```python
@ -219,8 +199,6 @@ class TryAgainResponse(BaseModel)
Request ID that is still pending
# `tinker.types.load_weights_request`
## `LoadWeightsRequest` Objects
```python
@ -235,8 +213,6 @@ A tinker URI for model weights at a specific step
Whether to load optimizer state along with model weights
# `tinker.types.telemetry_send_request`
## `TelemetrySendRequest` Objects
```python
@ -251,8 +227,6 @@ Host platform name
SDK version string
# `tinker.types.image_asset_pointer_chunk`
## `ImageAssetPointerChunk` Objects
```python
@ -279,8 +253,6 @@ Number of tokens this image represents
Image width in pixels
# `tinker.types.checkpoints_list_response`
## `CheckpointsListResponse` Objects
```python
@ -295,8 +267,6 @@ List of available model checkpoints for the model
Pagination cursor information (None for unpaginated responses)
# `tinker.types.generic_event`
## `GenericEvent` Objects
```python
@ -319,8 +289,6 @@ Log severity level
Arbitrary structured JSON payload
# `tinker.types.encoded_text_chunk`
## `EncodedTextChunk` Objects
```python
@ -331,8 +299,6 @@ class EncodedTextChunk(StrictBase)
Array of token IDs
# `tinker.types.forward_backward_input`
## `ForwardBackwardInput` Objects
```python
@ -351,8 +317,6 @@ Fully qualified function path for the loss function
Optional configuration parameters for the loss function (e.g., PPO clip thresholds, DPO beta)
# `tinker.types.session_start_event`
## `SessionStartEvent` Objects
```python
@ -367,8 +331,6 @@ Telemetry event type
Log severity level
# `tinker.types.training_runs_response`
## `TrainingRunsResponse` Objects
```python
@ -383,8 +345,6 @@ List of training runs
Pagination cursor information
# `tinker.types.save_weights_response`
## `SaveWeightsResponse` Objects
```python
@ -395,8 +355,6 @@ class SaveWeightsResponse(BaseModel)
A tinker URI for model weights at a specific step
# `tinker.types.sample_request`
## `SampleRequest` Objects
```python
@ -444,8 +402,6 @@ Defaults to false.
If set to a positive integer, returns the top-k logprobs for each prompt token.
# `tinker.types.forward_backward_output`
## `ForwardBackwardOutput` Objects
```python
@ -464,8 +420,6 @@ Dictionary mapping field names to tensor data
Training metrics as key-value pairs
# `tinker.types.sample_response`
## `SampleResponse` Objects
```python
@ -485,8 +439,6 @@ the top-k logprobs are computed for every token in the prompt. The
`topk_prompt_logprobs` response contains, for every token in the prompt,
a list of up to k (token_id, logprob) tuples.
# `tinker.types.create_sampling_session_response`
## `CreateSamplingSessionResponse` Objects
```python
@ -497,8 +449,6 @@ class CreateSamplingSessionResponse(BaseModel)
The generated sampling session ID
# `tinker.types.cursor`
## `Cursor` Objects
```python
@ -517,8 +467,6 @@ The maximum number of items requested
The total number of items available
# `tinker.types.create_model_request`
## `CreateModelRequest` Objects
```python
@ -529,8 +477,6 @@ class CreateModelRequest(StrictBase)
Optional metadata about this model/training run, set by the end-user
# `tinker.types.datum`
## `Datum` Objects
```python
@ -544,15 +490,11 @@ Dictionary mapping field names to tensor data
#### `convert_tensors`
```python
@model_validator(mode="before")
@classmethod
def convert_tensors(cls, data: Any) -> Any
```
Convert torch.Tensor and numpy arrays to TensorData in loss_fn_inputs during construction.
# `tinker.types.training_run`
## `TrainingRun` Objects
```python
@ -599,8 +541,6 @@ The most recent sampler checkpoint, if available
Optional metadata about this training run, set by the end-user
# `tinker.types.session_end_event`
## `SessionEndEvent` Objects
```python
@ -619,8 +559,6 @@ Telemetry event type
Log severity level
# `tinker.types.telemetry_batch`
## `TelemetryBatch` Objects
```python
@ -635,8 +573,6 @@ Host platform name
SDK version string
# `tinker.types.unhandled_exception_event`
## `UnhandledExceptionEvent` Objects
```python
@ -655,8 +591,6 @@ Log severity level
Optional Python traceback string
# `tinker.types.image_chunk`
## `ImageChunk` Objects
```python
@ -693,8 +627,6 @@ match expected_tokens.
#### `validate_data`
```python
@field_validator("data", mode="before")
@classmethod
def validate_data(cls, value: Union[bytes, str]) -> bytes
```
@ -703,14 +635,11 @@ Deserialize base64 string to bytes if needed.
#### `serialize_data`
```python
@field_serializer("data")
def serialize_data(value: bytes) -> str
```
Serialize bytes to base64 string for JSON.
# `tinker.types.save_weights_request`
## `SaveWeightsRequest` Objects
```python
@ -721,8 +650,6 @@ class SaveWeightsRequest(StrictBase)
A file/directory name for the weights
# `tinker.types.lora_config`
## `LoraConfig` Objects
```python
@ -751,8 +678,6 @@ Whether to add loras to the MLP layers (including MoE layers)
Whether to add loras to the attention layers
# `tinker.types.create_sampling_session_request`
## `CreateSamplingSessionRequest` Objects
```python
@ -780,8 +705,6 @@ Optional tinker:// path to your model weights or LoRA weights.
If not provided, samples against the base model.
# `tinker.types.future_retrieve_request`
## `FutureRetrieveRequest` Objects
```python
@ -792,8 +715,6 @@ class FutureRetrieveRequest(StrictBase)
The ID of the request to retrieve
# `tinker.types.tensor_data`
## `TensorData` Objects
```python
@ -828,8 +749,6 @@ def to_torch() -> "torch.Tensor"
Convert TensorData to torch tensor.
# `tinker.types.save_weights_for_sampler_request`
## `SaveWeightsForSamplerRequest` Objects
```python
@ -840,8 +759,6 @@ class SaveWeightsForSamplerRequest(StrictBase)
A file/directory name for the weights
# `tinker.types.sampling_params`
## `SamplingParams` Objects
```python
@ -872,8 +789,6 @@ Top-k sampling parameter (-1 for no limit)
Nucleus sampling probability
# `tinker.types.save_weights_for_sampler_response`
## `SaveWeightsForSamplerResponseInternal` Objects
```python
@ -898,8 +813,6 @@ class SaveWeightsForSamplerResponse(BaseModel)
A tinker URI for model weights for sampling at a specific step
# `tinker.types.load_weights_response`
## `LoadWeightsResponse` Objects
```python