Sync contents

This commit is contained in:
Daniel Xu 2025-11-25 05:55:10 +00:00
parent 097e108902
commit 937c36e9b1
6 changed files with 109 additions and 106 deletions

View file

@ -24,7 +24,7 @@ Key methods:
- unpublish_checkpoint_from_tinker_path() - unpublish a checkpoint to make it private
Args:
holder: Internal client managing HTTP connections and async operations
- `holder`: Internal client managing HTTP connections and async operations
Example:
```python
@ -49,10 +49,10 @@ def get_training_run(
Get training run info.
Args:
training_run_id: The training run ID to get information for
- `training_run_id`: The training run ID to get information for
Returns:
A Future containing the training run information
- A `Future` containing the training run information
Example:
```python
@ -83,10 +83,10 @@ def get_training_run_by_tinker_path(
Get training run info.
Args:
tinker_path: The tinker path to the checkpoint
- `tinker_path`: The tinker path to the checkpoint
Returns:
A Future containing the training run information
- A `Future` containing the training run information
Example:
```python
@ -116,10 +116,10 @@ def get_weights_info_by_tinker_path(
Get checkpoint information from a tinker path.
Args:
tinker_path: The tinker path to the checkpoint
- `tinker_path`: The tinker path to the checkpoint
Returns:
An APIFuture containing the checkpoint information. The future is awaitable.
- An `APIFuture` containing the checkpoint information. The future is awaitable.
Example:
```python
@ -141,11 +141,11 @@ def list_training_runs(
List training runs with pagination support.
Args:
limit: Maximum number of training runs to return (default 20)
offset: Offset for pagination (default 0)
- `limit`: Maximum number of training runs to return (default 20)
- `offset`: Offset for pagination (default 0)
Returns:
A Future containing the TrainingRunsResponse with training runs and cursor info
- A `Future` containing the `TrainingRunsResponse` with training runs and cursor info
Example:
```python
@ -181,10 +181,10 @@ def list_checkpoints(
List available checkpoints (both training and sampler).
Args:
training_run_id: The training run ID to list checkpoints for
- `training_run_id`: The training run ID to list checkpoints for
Returns:
A Future containing the CheckpointsListResponse with available checkpoints
- A `Future` containing the `CheckpointsListResponse` with available checkpoints
Example:
```python
@ -220,11 +220,11 @@ def get_checkpoint_archive_url(
Get signed URL to download checkpoint archive.
Args:
training_run_id: The training run ID to download weights for
checkpoint_id: The checkpoint ID to download
- `training_run_id`: The training run ID to download weights for
- `checkpoint_id`: The checkpoint ID to download
Returns:
A Future containing the CheckpointArchiveUrlResponse with signed URL and expiration
- A `Future` containing the `CheckpointArchiveUrlResponse` with signed URL and expiration
Example:
```python
@ -300,10 +300,10 @@ def get_checkpoint_archive_url_from_tinker_path(
Get signed URL to download checkpoint archive.
Args:
tinker_path: The tinker path to the checkpoint
- `tinker_path`: The tinker path to the checkpoint
Returns:
A Future containing the CheckpointArchiveUrlResponse with signed URL and expiration
- A `Future` containing the `CheckpointArchiveUrlResponse` with signed URL and expiration
#### `get_checkpoint_archive_url_from_tinker_path_async`
@ -330,10 +330,10 @@ Only the exact owner of the training run can publish checkpoints.
Published checkpoints can be unpublished using the unpublish_checkpoint_from_tinker_path method.
Args:
tinker_path: The tinker path to the checkpoint (e.g., "tinker://run-id/weights/0001")
- `tinker_path`: The tinker path to the checkpoint (e.g., "tinker://run-id/weights/0001")
Returns:
A Future that completes when the checkpoint is published
- A `Future` that completes when the checkpoint is published
Raises:
HTTPException: 400 if checkpoint identifier is invalid
@ -372,10 +372,10 @@ Only the exact owner of the training run can unpublish checkpoints.
This reverses the effect of publishing a checkpoint.
Args:
tinker_path: The tinker path to the checkpoint (e.g., "tinker://run-id/weights/0001")
- `tinker_path`: The tinker path to the checkpoint (e.g., "tinker://run-id/weights/0001")
Returns:
A Future that completes when the checkpoint is unpublished
- A `Future` that completes when the checkpoint is unpublished
Raises:
HTTPException: 400 if checkpoint identifier is invalid
@ -417,11 +417,11 @@ sorted by time (newest first). It supports pagination for efficiently handling l
numbers of checkpoints.
Args:
limit: Maximum number of checkpoints to return (default 100)
offset: Offset for pagination (default 0)
- `limit`: Maximum number of checkpoints to return (default 100)
- `offset`: Offset for pagination (default 0)
Returns:
A Future containing the CheckpointsListResponse with checkpoints and cursor info
- A `Future` containing the `CheckpointsListResponse` with checkpoints and cursor info
Example:
```python
@ -458,10 +458,10 @@ def get_session(session_id: str) -> ConcurrentFuture[types.GetSessionResponse]
Get session information including all training runs and samplers.
Args:
session_id: The session ID to get information for
- `session_id`: The session ID to get information for
Returns:
A Future containing the GetSessionResponse with training_run_ids and sampler_ids
- A `Future` containing the `GetSessionResponse` with training_run_ids and sampler_ids
Example:
```python
@ -493,11 +493,11 @@ def list_sessions(
List sessions with pagination support.
Args:
limit: Maximum number of sessions to return (default 20)
offset: Offset for pagination (default 0)
- `limit`: Maximum number of sessions to return (default 20)
- `offset`: Offset for pagination (default 0)
Returns:
A Future containing the ListSessionsResponse with list of session IDs
- A `Future` containing the `ListSessionsResponse` with list of session IDs
Example:
```python
@ -528,10 +528,10 @@ def get_sampler(sampler_id: str) -> APIFuture[types.GetSamplerResponse]
Get sampler information.
Args:
sampler_id: The sampler ID (sampling_session_id) to get information for
- `sampler_id`: The sampler ID (sampling_session_id) to get information for
Returns:
An APIFuture containing the GetSamplerResponse with sampler details
- An `APIFuture` containing the `GetSamplerResponse` with sampler details
Example:
```python