Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/OpenPipe/ART
/ functions
Functions
1,502 in github.com/OpenPipe/ART
⨍
Functions
1,502
◇
Types & classes
261
↳
Endpoints
14
↓ 5 callers
Method
finish
Finish parsing and yield any remaining content plus final Message. Call this after all tokens have been fed (either naturally when en
src/art/tinker/cookbook_v/renderers/kimi_k2.py:280
↓ 5 callers
Method
get_active
()
src/art/metrics.py:235
↓ 5 callers
Function
get_last_checkpoint_dir
(output_dir: str)
src/art/local/checkpoints.py:23
↓ 5 callers
Function
get_model_pricing
Return pricing for a model or None if missing.
src/art/costs.py:71
↓ 5 callers
Function
get_renderer_name
(base_model: str)
src/art/tinker/renderers.py:1
↓ 5 callers
Function
get_step_from_dir
(output_dir: str)
src/art/utils/get_model_step.py:10
↓ 5 callers
Method
log
(self, message: str)
src/art/trajectories.py:50
↓ 5 callers
Method
lookup
(self, rendered_tokens: Sequence[int])
src/art/tinker/prefix_cache.py:70
↓ 5 callers
Function
migrate_model_dir
Migrate all trajectory files for a model. Args: model_dir: Path to the model directory (containing trajectories/ subdirectory).
src/art/utils/trajectory_migration.py:377
↓ 5 callers
Function
packed_tensors_from_dir
(**kwargs: Unpack[DiskPackedTensors])
src/art/preprocessing/pack.py:177
↓ 5 callers
Function
parse_args
(argv: list[str] | None = None)
src/art/vllm/dedicated_server.py:16
↓ 5 callers
Function
parse_response_for_stop_token
Parse response for a single stop token. We expect a properly rendered response to have exactly one stop token; but it may have zero if e.g. the m
src/art/tinker/cookbook_v/renderers/base.py:1184
↓ 5 callers
Method
ping
(self)
tests/unit/test_mp_actors.py:25
↓ 5 callers
Function
pull_model_from_s3
Pull a model from S3 to the local directory. Args: model_name: The name of the model to pull. project: The project name.
src/art/utils/s3.py:161
↓ 5 callers
Method
read_state
Read persistent state from the model directory. Returns: The state dictionary if it exists, or None if no state has been saved.
src/art/model.py:404
↓ 5 callers
Function
rollout
( x_model: art.Model, o_model: art.Model, scenario: TicTacToeScenario )
examples/tic_tac_toe_self_play/rollout.py:112
↓ 5 callers
Function
s3_sync
Synchronise *source* and *destination* using the AWS CLI. Either *source* or *destination* (or both) can point to an S3 URI, making it possib
src/art/utils/s3.py:66
↓ 5 callers
Method
start
(self)
src/art/tinker/server.py:75
↓ 5 callers
Method
train
( self, model: AnyTrainableModel, trajectory_groups: Iterable[TrajectoryGroup],
src/art/backend.py:38
↓ 5 callers
Function
train_one_step
Run one training step and return the result.
tests/integration/test_push_and_fork.py:49
↓ 5 callers
Function
warn
(msg)
src/art/utils/logging.py:35
↓ 4 callers
Method
__get_step
(self, model: Model)
src/art/local/backend.py:359
↓ 4 callers
Method
__init__
(self, message: str, status_code: int)
src/art/errors.py:11
↓ 4 callers
Method
__init__
( self, adapter_model_prefix: str, in_features: int, out_features: int,
src/art/megatron/lora.py:20
↓ 4 callers
Method
_fmt_float
(value: object, decimals: int)
src/art/pipeline_trainer/status.py:394
↓ 4 callers
Method
_fmt_float_compact
(value: object, decimals: int)
src/art/pipeline_trainer/status.py:402
↓ 4 callers
Method
_fmt_int_compact
(value: object)
src/art/pipeline_trainer/status.py:388
↓ 4 callers
Method
_get_service
(self, model: TrainableModel)
src/art/local/backend.py:244
↓ 4 callers
Function
_get_trainer_optimizer
(trainer: GRPOTrainer)
src/art/unsloth/service.py:194
↓ 4 callers
Method
_log_metrics
Log metrics to history.jsonl and optionally wandb.
src/art/model.py:510
↓ 4 callers
Method
_persist_state
(self, training_step: int)
src/art/pipeline_trainer/trainer.py:772
↓ 4 callers
Method
_save_sampler_weights
( self, training_client: tinker.TrainingClient, checkpoint_name: str, )
src/art/tinker_native/backend.py:806
↓ 4 callers
Method
add_user_timing
( self, step_wall_s: float | None = None, step_actor_s: float | None = None, s
src/art/metrics.py:159
↓ 4 callers
Method
backend
(self)
src/art/model.py:214
↓ 4 callers
Method
build_generation_prompt
Generates tokens for sampling from the model. Args: messages: a list of messages to render. role: the role o
src/art/tinker/cookbook_v/renderers/base.py:941
↓ 4 callers
Function
calculate_beat_comp
( groups: list[art.TrajectoryGroup], control_groups: list[art.TrajectoryGroup], control_first: boo
examples/mcp-rl/mcp_rl/benchmarks/generate_benchmarks.py:46
↓ 4 callers
Method
close
(self)
src/art/tinker_native/backend.py:178
↓ 4 callers
Method
close
Terminate vLLM subprocess if running.
src/art/unsloth/service.py:451
↓ 4 callers
Function
condense_sequence
(sequence: list[int | None])
examples/2048/utils.py:89
↓ 4 callers
Function
create_temp_jsonl
Create a temporary JSONL file with dummy trajectories.
tests/unit/test_sft.py:17
↓ 4 callers
Method
from_dict
Create a Tool from a dictionary.
src/art/mcp/types.py:19
↓ 4 callers
Function
gather_trajectory_groups_by_index
( grouped_trajectory_awaitables: Iterable[Awaitable[tuple[art.Trajectory, ...]]], *, pbar_desc: st
examples/tic_tac_toe_self_play/gather_trajectory_groups_by_index.py:10
↓ 4 callers
Function
generate_val_groups
( model: art.Model, val_scenarios: List[McpScenario] )
examples/mcp-rl/mcp_rl/benchmarks/generate_benchmarks.py:31
↓ 4 callers
Function
get_messages
(messages_and_choices: MessagesAndChoices)
src/art/trajectories.py:97
↓ 4 callers
Function
iterate_dataset
Generates batches from a dataset over multiple epochs with deterministic shuffling. Args: dataset: The list of data items. g
src/art/utils/iterate_dataset.py:21
↓ 4 callers
Method
litellm_completion_params
Return the parameters that should be sent to litellm.completion. Args: step: If provided, returns params for specific checkpoint
src/art/model.py:260
↓ 4 callers
Method
load_state_dict
(self, state: dict[str, Any])
src/art/metrics.py:307
↓ 4 callers
Function
log_timing
Context manager that logs a message with timestamp and duration.
src/art/tinker/service.py:27
↓ 4 callers
Function
normalize_provider
(provider: str | None)
src/art/api_costs.py:74
↓ 4 callers
Function
record_metrics
(context: "GatherContext", trajectory: Trajectory)
src/art/gather.py:183
↓ 4 callers
Method
register_model_pricing
( self, model_name: str, *, prompt_per_million: float, completion_per_
src/art/metrics.py:268
↓ 4 callers
Function
render_board
(game: TwentyFortyEightGame)
examples/2048/utils.py:59
↓ 4 callers
Function
rollout
(model: art.Model, scenario: FactsScenario)
examples/just-the-facts/just_the_facts/rollout.py:26
↓ 4 callers
Function
set_gather_context
(context: GatherContext)
src/art/gather.py:248
↓ 4 callers
Method
state_dict
(self)
src/art/metrics.py:301
↓ 3 callers
Method
__init__
Initialize MCP server.
examples/mcp-rl/mcp_rl/mcp_server.py:16
↓ 3 callers
Function
_check_job_status
Checks the status of a model deployment job in Together.
src/art/utils/deployment/together.py:147
↓ 3 callers
Method
_ensure_lora_adapter_config
( self, lora_path: str, *, source_path: str | None = None )
src/art/megatron/service.py:124
↓ 3 callers
Function
_ensure_message
Narrow a trajectory entry to a concrete message (not a Choice).
tests/unit/test_trajectory_parquet.py:58
↓ 3 callers
Function
_extract_cost_value
(value: Any)
src/art/api_costs.py:126
↓ 3 callers
Function
_format_description
(description: str, indent: str = "")
src/art/tinker/cookbook_v/renderers/kimi_k2_5_tool_declaration_ts.py:47
↓ 3 callers
Function
_format_json
Format JSON data for display
examples/mcp-rl/servers/python/mcp_balldontlie/server.py:318
↓ 3 callers
Method
_get_tenant
(self, api_key: str)
src/art/tinker/server.py:277
↓ 3 callers
Function
_init_session
Initializes a session for interacting with Together.
src/art/utils/deployment/together.py:63
↓ 3 callers
Method
_list_checkpoints
( self, rest_client: Any, tinker_run_ids: list[str] )
src/art/tinker_native/backend.py:642
↓ 3 callers
Function
_load_font
(font_path: str | Path | None, preferred_size: int)
dev/yes-no-maybe-vision/generate_images.py:14
↓ 3 callers
Function
_make_group
( rewards: list[float], *, initial_policy_version: int | None )
tests/unit/test_pipeline_trainer_metrics.py:13
↓ 3 callers
Method
_metrics_builder_for_split
(self, split: str)
src/art/model.py:672
↓ 3 callers
Method
_next_lora_id
Return a new unique LoRA ID to avoid collisions in vLLM.
src/art/unsloth/service.py:324
↓ 3 callers
Method
_pending_state
(self)
src/art/metrics.py:340
↓ 3 callers
Method
_persist_model_state
(self, model: TrainableModel, state: ModelState)
src/art/tinker_native/backend.py:832
↓ 3 callers
Method
_reset_optimizer_if_mode_changed
Reset optimizer state if training mode changed. Uses a single shared optimizer (trainer.optimizer) for both SFT and RL. Resets optimi
src/art/unsloth/service.py:539
↓ 3 callers
Function
_response_usage
(response: Any)
src/art/api_costs.py:133
↓ 3 callers
Method
_update_ewa
(self, previous: float | None, new_value: float)
src/art/pipeline_trainer/status.py:359
↓ 3 callers
Method
add_idle_times
( self, step_trainer_idle_s: float | None = None, step_actor_idle_s: float | None = No
src/art/metrics.py:172
↓ 3 callers
Method
add_response_cost
( self, source: str, response: Any, *, provider: str, model_na
src/art/metrics.py:104
↓ 3 callers
Function
assert_chat_logprobs
( client: openai.AsyncOpenAI, model_name: str, )
tests/integration/test_vllm_contract.py:89
↓ 3 callers
Function
benchmark_model
(model: art.Model)
examples/benchmarking_comparison_models.py:64
↓ 3 callers
Method
build_supervised_example
Override to properly handle thinking preservation for the last assistant message. Also ensures default system message is prepended if
src/art/tinker/cookbook_v/renderers/kimi_k2.py:615
↓ 3 callers
Function
check_winner
(board: list[list[str]])
examples/tic_tac_toe_self_play/game_utils.py:82
↓ 3 callers
Function
check_winner
(board: list[list[str]])
examples/tic_tac_toe/game_utils.py:80
↓ 3 callers
Function
compute_sample_costs
Compute Tinker prompt+completion costs for a single inference call.
src/art/costs.py:92
↓ 3 callers
Function
convert_openai_messages_to_renderer_format
( messages: list[dict[str, Any]], tools: list[dict[str, Any]] | None, renderer: Any, )
src/art/tinker_native/data.py:38
↓ 3 callers
Function
create_sample_tools
Create sample tools for testing.
examples/mcp-rl/test_scenario_generation.py:15
↓ 3 callers
Method
delete_checkpoints
Delete all but the latest and best checkpoints. Args: best_checkpoint_metric: The metric to use to determine the best ch
src/art/model.py:1017
↓ 3 callers
Function
deploy_model
Deploy a model checkpoint to a hosted inference endpoint. This function assumes the checkpoint is already available locally. Use Backend.pull
src/art/utils/deployment/common.py:28
↓ 3 callers
Function
ensure_reward_variance
(groups)
tests/integration/test_tinker_native_backend.py:20
↓ 3 callers
Method
execute
()
src/art/langgraph/llm_wrapper.py:145
↓ 3 callers
Method
fetch_data
Fetch data from Balldontlie API
examples/mcp-rl/servers/python/mcp_balldontlie/server.py:23
↓ 3 callers
Method
finish
(self)
src/art/trajectories.py:53
↓ 3 callers
Function
get_base_model
()
tests/integration/test_tinker_native_backend.py:16
↓ 3 callers
Function
get_gather_context
()
src/art/gather.py:256
↓ 3 callers
Function
get_latest_checkpoint_step_from_s3
Get the latest checkpoint step number from S3 without downloading files. Returns: The latest step number, or None if no checkpoints
src/art/utils/s3_checkpoint_utils.py:7
↓ 3 callers
Function
get_model_step
(model: "TrainableModel", art_path: str)
src/art/utils/get_model_step.py:26
↓ 3 callers
Function
get_model_trajectories
( trajectories: list[art.Trajectory], )
examples/tic_tac_toe_self_play/train_o4_mini.py:58
↓ 3 callers
Function
get_openai_server_config
( model_name: str, base_model: str, log_file: str, lora_path: str | None = None, config: "
src/art/dev/openai_server.py:8
↓ 3 callers
Function
init_chat_completion
(chunk: ChatCompletionChunk)
src/art/openai.py:64
↓ 3 callers
Function
load_benchmarked_models
( project: str, benchmark_keys: list[BenchmarkedModelKey], metrics: list[str] = ["reward"], ap
src/art/utils/old_benchmarking/load_benchmarked_models.py:18
↓ 3 callers
Method
merge_state
Deep-merge state into the existing state and persist it. Args: state: A dictionary of JSON-serializable values to merge.
src/art/model.py:346
↓ 3 callers
Function
migrate_trajectories_dir
Migrate all JSONL files in a trajectories directory (including subdirectories). Args: trajectories_dir: Path to the trajectories dir
src/art/utils/trajectory_migration.py:335
← previous
next →
101–200 of 1,502, ranked by callers