SYMBOL INDEX (4125 symbols across 409 files) FILE: .mlx_typings/mflux/callbacks/callback.pyi class BeforeLoopCallback (line 11) | class BeforeLoopCallback(Protocol): method call_before_loop (line 12) | def call_before_loop( class InLoopCallback (line 22) | class InLoopCallback(Protocol): method call_in_loop (line 23) | def call_in_loop( class AfterLoopCallback (line 33) | class AfterLoopCallback(Protocol): method call_after_loop (line 34) | def call_after_loop( class InterruptCallback (line 38) | class InterruptCallback(Protocol): method call_interrupt (line 39) | def call_interrupt( FILE: .mlx_typings/mflux/callbacks/callback_registry.pyi class CallbackRegistry (line 17) | class CallbackRegistry: method __init__ (line 18) | def __init__(self) -> None: ... method register (line 19) | def register(self, callback) -> None: ... method start (line 20) | def start(self, seed: int, prompt: str, config: Config) -> GenerationC... method before_loop_callbacks (line 21) | def before_loop_callbacks(self) -> list[BeforeLoopCallback]: ... method in_loop_callbacks (line 22) | def in_loop_callbacks(self) -> list[InLoopCallback]: ... method after_loop_callbacks (line 23) | def after_loop_callbacks(self) -> list[AfterLoopCallback]: ... method interrupt_callbacks (line 24) | def interrupt_callbacks(self) -> list[InterruptCallback]: ... FILE: .mlx_typings/mflux/callbacks/generation_context.pyi class GenerationContext (line 14) | class GenerationContext: method __init__ (line 15) | def __init__( method before_loop (line 18) | def before_loop( method in_loop (line 25) | def in_loop(self, t: int, latents: mx.array, time_steps: tqdm = ...) -... method after_loop (line 26) | def after_loop(self, latents: mx.array) -> None: ... method interruption (line 27) | def interruption( FILE: .mlx_typings/mflux/models/common/config/config.pyi class Config (line 13) | class Config: method __init__ (line 14) | def __init__( method height (line 31) | def height(self) -> int: ... method width (line 33) | def width(self) -> int: ... method width (line 35) | def width(self, value): # -> None: method image_seq_len (line 38) | def image_seq_len(self) -> int: ... method guidance (line 40) | def guidance(self) -> float: ... method num_inference_steps (line 42) | def num_inference_steps(self) -> int: ... method precision (line 44) | def precision(self) -> mx.Dtype: ... method num_train_steps (line 46) | def num_train_steps(self) -> int: ... method image_path (line 48) | def image_path(self) -> Path | None: ... method image_strength (line 50) | def image_strength(self) -> float | None: ... method depth_image_path (line 52) | def depth_image_path(self) -> Path | None: ... method redux_image_paths (line 54) | def redux_image_paths(self) -> list[Path] | None: ... method redux_image_strengths (line 56) | def redux_image_strengths(self) -> list[float] | None: ... method masked_image_path (line 58) | def masked_image_path(self) -> Path | None: ... method init_time_step (line 60) | def init_time_step(self) -> int: ... method time_steps (line 62) | def time_steps(self) -> tqdm: ... method controlnet_strength (line 64) | def controlnet_strength(self) -> float | None: ... method scheduler (line 66) | def scheduler(self) -> Any: ... FILE: .mlx_typings/mflux/models/common/config/model_config.pyi class ModelConfig (line 9) | class ModelConfig: method __init__ (line 11) | def __init__( method dev (line 27) | def dev() -> ModelConfig: ... method schnell (line 30) | def schnell() -> ModelConfig: ... method dev_kontext (line 33) | def dev_kontext() -> ModelConfig: ... method dev_fill (line 36) | def dev_fill() -> ModelConfig: ... method dev_redux (line 39) | def dev_redux() -> ModelConfig: ... method dev_depth (line 42) | def dev_depth() -> ModelConfig: ... method dev_controlnet_canny (line 45) | def dev_controlnet_canny() -> ModelConfig: ... method schnell_controlnet_canny (line 48) | def schnell_controlnet_canny() -> ModelConfig: ... method dev_controlnet_upscaler (line 51) | def dev_controlnet_upscaler() -> ModelConfig: ... method dev_fill_catvton (line 54) | def dev_fill_catvton() -> ModelConfig: ... method krea_dev (line 57) | def krea_dev() -> ModelConfig: ... method flux2_klein_4b (line 60) | def flux2_klein_4b() -> ModelConfig: ... method flux2_klein_9b (line 63) | def flux2_klein_9b() -> ModelConfig: ... method qwen_image (line 66) | def qwen_image() -> ModelConfig: ... method qwen_image_edit (line 69) | def qwen_image_edit() -> ModelConfig: ... method fibo (line 72) | def fibo() -> ModelConfig: ... method z_image_turbo (line 75) | def z_image_turbo() -> ModelConfig: ... method seedvr2_3b (line 78) | def seedvr2_3b() -> ModelConfig: ... method x_embedder_input_dim (line 79) | def x_embedder_input_dim(self) -> int: ... method is_canny (line 80) | def is_canny(self) -> bool: ... method from_name (line 82) | def from_name( FILE: .mlx_typings/mflux/models/common/latent_creator/latent_creator.pyi class Img2Img (line 22) | class Img2Img: method __init__ (line 23) | def __init__( class LatentCreator (line 33) | class LatentCreator: method create_for_txt2img_or_img2img (line 35) | def create_for_txt2img_or_img2img( method encode_image (line 39) | def encode_image( method add_noise_by_interpolation (line 47) | def add_noise_by_interpolation( FILE: .mlx_typings/mflux/models/common/lora/layer/fused_linear_lora_layer.pyi class FusedLoRALinear (line 8) | class FusedLoRALinear(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__(self, x): # -> array: FILE: .mlx_typings/mflux/models/common/lora/layer/linear_lora_layer.pyi class LoRALinear (line 7) | class LoRALinear(nn.Module): method from_linear (line 9) | def from_linear( method __init__ (line 13) | def __init__( method __call__ (line 21) | def __call__(self, x): # -> array: FILE: .mlx_typings/mflux/models/common/lora/mapping/lora_loader.pyi class PatternMatch (line 12) | class PatternMatch: class LoRALoader (line 19) | class LoRALoader: method load_and_apply_lora (line 21) | def load_and_apply_lora( FILE: .mlx_typings/mflux/models/common/lora/mapping/lora_mapping.pyi class LoRATarget (line 11) | class LoRATarget: class LoRAMapping (line 19) | class LoRAMapping(Protocol): method get_mapping (line 21) | def get_mapping() -> List[LoRATarget]: ... FILE: .mlx_typings/mflux/models/common/lora/mapping/lora_saver.pyi class LoRASaver (line 7) | class LoRASaver: method bake_and_strip_lora (line 9) | def bake_and_strip_lora(module: nn.Module) -> nn.Module: ... FILE: .mlx_typings/mflux/models/common/lora/mapping/lora_transforms.pyi class LoraTransforms (line 7) | class LoraTransforms: method split_q_up (line 9) | def split_q_up(tensor: mx.array) -> mx.array: ... method split_k_up (line 11) | def split_k_up(tensor: mx.array) -> mx.array: ... method split_v_up (line 13) | def split_v_up(tensor: mx.array) -> mx.array: ... method split_q_down (line 15) | def split_q_down(tensor: mx.array) -> mx.array: ... method split_k_down (line 17) | def split_k_down(tensor: mx.array) -> mx.array: ... method split_v_down (line 19) | def split_v_down(tensor: mx.array) -> mx.array: ... method split_single_q_up (line 21) | def split_single_q_up(tensor: mx.array) -> mx.array: ... method split_single_k_up (line 23) | def split_single_k_up(tensor: mx.array) -> mx.array: ... method split_single_v_up (line 25) | def split_single_v_up(tensor: mx.array) -> mx.array: ... method split_single_mlp_up (line 27) | def split_single_mlp_up(tensor: mx.array) -> mx.array: ... method split_single_q_down (line 29) | def split_single_q_down(tensor: mx.array) -> mx.array: ... method split_single_k_down (line 31) | def split_single_k_down(tensor: mx.array) -> mx.array: ... method split_single_v_down (line 33) | def split_single_v_down(tensor: mx.array) -> mx.array: ... method split_single_mlp_down (line 35) | def split_single_mlp_down(tensor: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/common/resolution/actions.pyi class QuantizationAction (line 8) | class QuantizationAction(Enum): class PathAction (line 13) | class PathAction(Enum): class LoraAction (line 19) | class LoraAction(Enum): class ConfigAction (line 28) | class ConfigAction(Enum): class Rule (line 34) | class Rule(NamedTuple): FILE: .mlx_typings/mflux/models/common/resolution/config_resolution.pyi class ConfigResolution (line 11) | class ConfigResolution: method resolve (line 14) | def resolve(model_name: str, base_model: str | None = ...) -> ModelCon... FILE: .mlx_typings/mflux/models/common/resolution/lora_resolution.pyi class LoraResolution (line 9) | class LoraResolution: method resolve (line 13) | def resolve(path: str) -> str: ... method resolve_paths (line 15) | def resolve_paths(paths: list[str] | None) -> list[str]: ... method resolve_scales (line 17) | def resolve_scales(scales: list[float] | None, num_paths: int) -> list... method get_registry (line 19) | def get_registry() -> dict[str, Path]: ... method discover_files (line 21) | def discover_files(library_paths: list[Path]) -> dict[str, Path]: ... FILE: .mlx_typings/mflux/models/common/resolution/path_resolution.pyi class PathResolution (line 9) | class PathResolution: method resolve (line 12) | def resolve(path: str | None, patterns: list[str] | None = ...) -> Pat... FILE: .mlx_typings/mflux/models/common/resolution/quantization_resolution.pyi class QuantizationResolution (line 7) | class QuantizationResolution: method resolve (line 10) | def resolve( FILE: .mlx_typings/mflux/models/common/schedulers/__init__.pyi class SchedulerModuleNotFound (line 15) | class SchedulerModuleNotFound(ValueError): ... class SchedulerClassNotFound (line 16) | class SchedulerClassNotFound(ValueError): ... class InvalidSchedulerType (line 17) | class InvalidSchedulerType(TypeError): ... function register_contrib (line 21) | def register_contrib(scheduler_object, scheduler_name=...): # -> None: function try_import_external_scheduler (line 23) | def try_import_external_scheduler( FILE: .mlx_typings/mflux/models/common/schedulers/base_scheduler.pyi class BaseScheduler (line 8) | class BaseScheduler(ABC): method sigmas (line 11) | def sigmas(self) -> mx.array: ... method step (line 13) | def step( method scale_model_input (line 16) | def scale_model_input(self, latents: mx.array, t: int) -> mx.array: ... FILE: .mlx_typings/mflux/models/common/schedulers/flow_match_euler_discrete_scheduler.pyi class FlowMatchEulerDiscreteScheduler (line 12) | class FlowMatchEulerDiscreteScheduler(BaseScheduler): method __init__ (line 13) | def __init__(self, config: Config) -> None: ... method sigmas (line 15) | def sigmas(self) -> mx.array: ... method timesteps (line 17) | def timesteps(self) -> mx.array: ... method set_image_seq_len (line 18) | def set_image_seq_len(self, image_seq_len: int) -> None: ... method get_timesteps_and_sigmas (line 20) | def get_timesteps_and_sigmas( method step (line 23) | def step( method scale_model_input (line 26) | def scale_model_input(self, latents: mx.array, t: int) -> mx.array: ... FILE: .mlx_typings/mflux/models/common/schedulers/linear_scheduler.pyi class LinearScheduler (line 12) | class LinearScheduler(BaseScheduler): method __init__ (line 13) | def __init__(self, config: Config) -> None: ... method sigmas (line 15) | def sigmas(self) -> mx.array: ... method timesteps (line 17) | def timesteps(self) -> mx.array: ... method step (line 18) | def step( FILE: .mlx_typings/mflux/models/common/schedulers/seedvr2_euler_scheduler.pyi class SeedVR2EulerScheduler (line 12) | class SeedVR2EulerScheduler(BaseScheduler): method __init__ (line 13) | def __init__(self, config: Config) -> None: ... method timesteps (line 15) | def timesteps(self) -> mx.array: ... method sigmas (line 17) | def sigmas(self) -> mx.array: ... method step (line 18) | def step( FILE: .mlx_typings/mflux/models/common/tokenizer/tokenizer.pyi class Tokenizer (line 16) | class Tokenizer(Protocol): method tokenize (line 18) | def tokenize( class BaseTokenizer (line 26) | class BaseTokenizer(ABC): method __init__ (line 27) | def __init__( method tokenize (line 31) | def tokenize( class LanguageTokenizer (line 39) | class LanguageTokenizer(BaseTokenizer): method __init__ (line 40) | def __init__( method tokenize (line 51) | def tokenize( class VisionLanguageTokenizer (line 59) | class VisionLanguageTokenizer(BaseTokenizer): method __init__ (line 60) | def __init__( method tokenize (line 68) | def tokenize( FILE: .mlx_typings/mflux/models/common/tokenizer/tokenizer_loader.pyi class TokenizerLoader (line 14) | class TokenizerLoader: method load (line 16) | def load(definition: TokenizerDefinition, model_path: str) -> BaseToke... method load_all (line 18) | def load_all( FILE: .mlx_typings/mflux/models/common/tokenizer/tokenizer_output.pyi class TokenizerOutput (line 13) | class TokenizerOutput: FILE: .mlx_typings/mflux/models/common/vae/tiling_config.pyi class TilingConfig (line 8) | class TilingConfig: FILE: .mlx_typings/mflux/models/common/vae/vae_tiler.pyi class VAETiler (line 8) | class VAETiler: method encode_image_tiled (line 10) | def encode_image_tiled( method decode_image_tiled (line 20) | def decode_image_tiled( FILE: .mlx_typings/mflux/models/common/vae/vae_util.pyi class VAEUtil (line 9) | class VAEUtil: method encode (line 11) | def encode( method decode (line 15) | def decode( FILE: .mlx_typings/mflux/models/common/weights/loading/loaded_weights.pyi class MetaData (line 8) | class MetaData: class LoadedWeights (line 13) | class LoadedWeights: method __getattr__ (line 16) | def __getattr__(self, name: str) -> dict | None: ... method num_transformer_blocks (line 17) | def num_transformer_blocks(self, component_name: str = ...) -> int: ... method num_single_transformer_blocks (line 18) | def num_single_transformer_blocks(self, component_name: str = ...) -> ... FILE: .mlx_typings/mflux/models/common/weights/loading/weight_applier.pyi class WeightApplier (line 15) | class WeightApplier: method apply_and_quantize_single (line 17) | def apply_and_quantize_single( method apply_and_quantize (line 25) | def apply_and_quantize( FILE: .mlx_typings/mflux/models/common/weights/loading/weight_definition.pyi class ComponentDefinition (line 41) | class ComponentDefinition: class TokenizerDefinition (line 58) | class TokenizerDefinition: FILE: .mlx_typings/mflux/models/common/weights/loading/weight_loader.pyi class WeightLoader (line 15) | class WeightLoader: method load_single (line 17) | def load_single( method load (line 21) | def load( FILE: .mlx_typings/mflux/models/common/weights/mapping/weight_mapper.pyi class WeightMapper (line 9) | class WeightMapper: method apply_mapping (line 11) | def apply_mapping( FILE: .mlx_typings/mflux/models/common/weights/mapping/weight_mapping.pyi class WeightTarget (line 14) | class WeightTarget: class WeightMapping (line 21) | class WeightMapping(Protocol): method get_mapping (line 23) | def get_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/common/weights/mapping/weight_transforms.pyi class WeightTransforms (line 7) | class WeightTransforms: method reshape_gamma_to_1d (line 9) | def reshape_gamma_to_1d(tensor: mx.array) -> mx.array: ... method transpose_patch_embed (line 11) | def transpose_patch_embed(tensor: mx.array) -> mx.array: ... method transpose_conv3d_weight (line 13) | def transpose_conv3d_weight(tensor: mx.array) -> mx.array: ... method transpose_conv2d_weight (line 15) | def transpose_conv2d_weight(tensor: mx.array) -> mx.array: ... method transpose_conv_transpose2d_weight (line 17) | def transpose_conv_transpose2d_weight(tensor: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/common/weights/saving/model_saver.pyi class ModelSaver (line 10) | class ModelSaver: method save_model (line 12) | def save_model( FILE: .mlx_typings/mflux/models/depth_pro/depth_pro_initializer.pyi class DepthProInitializer (line 7) | class DepthProInitializer: method init (line 9) | def init(model: DepthProModel, quantize: int | None = ...) -> None: ... FILE: .mlx_typings/mflux/models/depth_pro/model/decoder/feature_fusion_block_2d.pyi class FeatureFusionBlock2d (line 8) | class FeatureFusionBlock2d(nn.Module): method __init__ (line 9) | def __init__(self, num_features: int, deconv: bool = ...) -> None: ... method __call__ (line 10) | def __call__(self, x0: mx.array, x1: mx.array | None = ...) -> mx.arra... FILE: .mlx_typings/mflux/models/depth_pro/model/decoder/multires_conv_decoder.pyi class MultiresConvDecoder (line 8) | class MultiresConvDecoder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/depth_pro/model/decoder/residual_block.pyi class ResidualBlock (line 8) | class ResidualBlock(nn.Module): method __init__ (line 9) | def __init__(self, num_features: int) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/depth_pro.pyi class DepthResult (line 11) | class DepthResult: class DepthPro (line 18) | class DepthPro: method __init__ (line 19) | def __init__(self, quantize: int | None = ...) -> None: ... method create_depth_map (line 20) | def create_depth_map(self, image_path: str | Path) -> DepthResult: ... FILE: .mlx_typings/mflux/models/depth_pro/model/depth_pro_model.pyi class DepthProModel (line 8) | class DepthProModel(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/depth_pro/model/depth_pro_util.pyi class DepthProUtil (line 8) | class DepthProUtil: method split (line 10) | def split(x: mx.array, overlap_ratio: float = ...) -> mx.array: ... method interpolate (line 12) | def interpolate(x: mx.array, size=..., scale_factor=...): # -> array: method apply_conv (line 15) | def apply_conv(x: mx.array, conv_module: nn.Module) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/attention.pyi class Attention (line 8) | class Attention(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/dino_vision_transformer.pyi class DinoVisionTransformer (line 8) | class DinoVisionTransformer(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> tuple[mx.array, mx.array, mx.array]... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/layer_scale.pyi class LayerScale (line 8) | class LayerScale(nn.Module): method __init__ (line 9) | def __init__(self, dims: int, init_values: float = ...) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/mlp.pyi class MLP (line 8) | class MLP(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/patch_embed.pyi class PatchEmbed (line 8) | class PatchEmbed(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/dino_v2/transformer_block.pyi class TransformerBlock (line 8) | class TransformerBlock(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/encoder/depth_pro_encoder.pyi class DepthProEncoder (line 8) | class DepthProEncoder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/depth_pro/model/encoder/upsample_block.pyi class UpSampleBlock (line 8) | class UpSampleBlock(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 16) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/model/head/fov_head.pyi class FOVHead (line 8) | class FOVHead(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/depth_pro/weights/depth_pro_weight_definition.pyi class DepthProWeightDefinition (line 15) | class DepthProWeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/depth_pro/weights/depth_pro_weight_mapping.pyi class DepthProWeightMapping (line 11) | class DepthProWeightMapping(WeightMapping): method get_mapping (line 13) | def get_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/fibo/latent_creator/fibo_latent_creator.pyi class FiboLatentCreator (line 7) | class FiboLatentCreator: method create_noise (line 9) | def create_noise(seed: int, height: int, width: int) -> mx.array: ... method pack_latents (line 11) | def pack_latents(latents: mx.array, height: int, width: int) -> mx.arr... method unpack_latents (line 13) | def unpack_latents(latents: mx.array, height: int, width: int) -> mx.a... FILE: .mlx_typings/mflux/models/fibo/weights/fibo_weight_definition.pyi class FIBOWeightDefinition (line 15) | class FIBOWeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/fibo/weights/fibo_weight_mapping.pyi class FIBOWeightMapping (line 11) | class FIBOWeightMapping(WeightMapping): method get_transformer_mapping (line 13) | def get_transformer_mapping() -> List[WeightTarget]: ... method get_text_encoder_mapping (line 15) | def get_text_encoder_mapping() -> List[WeightTarget]: ... method get_vae_mapping (line 17) | def get_vae_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/fibo_vlm/tokenizer/qwen2vl_image_processor.pyi class Qwen2VLImageProcessor (line 7) | class Qwen2VLImageProcessor(QwenImageProcessor): method __init__ (line 8) | def __init__(self) -> None: ... FILE: .mlx_typings/mflux/models/fibo_vlm/tokenizer/qwen2vl_processor.pyi class Qwen2VLProcessor (line 8) | class Qwen2VLProcessor: method __init__ (line 9) | def __init__(self, tokenizer) -> None: ... method apply_chat_template (line 10) | def apply_chat_template( method __call__ (line 20) | def __call__( FILE: .mlx_typings/mflux/models/fibo_vlm/weights/fibo_vlm_weight_definition.pyi class FIBOVLMWeightDefinition (line 16) | class FIBOVLMWeightDefinition: method get_components (line 18) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 20) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 22) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 24) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/fibo_vlm/weights/fibo_vlm_weight_mapping.pyi class FIBOVLMWeightMapping (line 11) | class FIBOVLMWeightMapping(WeightMapping): method get_vlm_decoder_mapping (line 13) | def get_vlm_decoder_mapping(num_layers: int = ...) -> List[WeightTarge... method get_vlm_visual_mapping (line 15) | def get_vlm_visual_mapping(depth: int = ...) -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/flux/flux_initializer.pyi class FluxInitializer (line 7) | class FluxInitializer: method init (line 9) | def init( method init_depth (line 19) | def init_depth( method init_redux (line 28) | def init_redux( method init_controlnet (line 37) | def init_controlnet( method init_concept (line 46) | def init_concept( FILE: .mlx_typings/mflux/models/flux/latent_creator/flux_latent_creator.pyi class FluxLatentCreator (line 11) | class FluxLatentCreator: method create_noise (line 13) | def create_noise(seed: int, height: int, width: int) -> mx.array: ... method pack_latents (line 15) | def pack_latents( method unpack_latents (line 19) | def unpack_latents(latents: mx.array, height: int, width: int) -> mx.a... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_embeddings.pyi class CLIPEmbeddings (line 8) | class CLIPEmbeddings(nn.Module): method __init__ (line 9) | def __init__(self, dims: int) -> None: ... method __call__ (line 10) | def __call__(self, tokens: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_encoder.pyi class CLIPEncoder (line 12) | class CLIPEncoder(nn.Module): method __init__ (line 13) | def __init__(self) -> None: ... method __call__ (line 14) | def __call__(self, tokens: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_encoder_layer.pyi class CLIPEncoderLayer (line 8) | class CLIPEncoderLayer(nn.Module): method __init__ (line 9) | def __init__(self, layer: int) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_mlp.pyi class CLIPMLP (line 8) | class CLIPMLP(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... method quick_gelu (line 12) | def quick_gelu(input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_sdpa_attention.pyi class CLIPSdpaAttention (line 8) | class CLIPSdpaAttention(nn.Module): method __init__ (line 12) | def __init__(self) -> None: ... method __call__ (line 13) | def __call__( method reshape_and_transpose (line 17) | def reshape_and_transpose(x, batch_size, num_heads, head_dim): # -> a... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/clip_text_model.pyi class CLIPTextModel (line 8) | class CLIPTextModel(nn.Module): method __init__ (line 9) | def __init__(self, dims: int, num_encoder_layers: int) -> None: ... method __call__ (line 10) | def __call__(self, tokens: mx.array) -> tuple[mx.array, mx.array]: ... method create_causal_attention_mask (line 12) | def create_causal_attention_mask(input_shape: tuple) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/clip_encoder/encoder_clip.pyi class EncoderCLIP (line 8) | class EncoderCLIP(nn.Module): method __init__ (line 9) | def __init__(self, num_encoder_layers: int) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/prompt_encoder.pyi class PromptEncoder (line 16) | class PromptEncoder: method encode_prompt (line 18) | def encode_prompt( FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_attention.pyi class T5Attention (line 8) | class T5Attention(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_block.pyi class T5Block (line 8) | class T5Block(nn.Module): method __init__ (line 9) | def __init__(self, layer: int) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_dense_relu_dense.pyi class T5DenseReluDense (line 8) | class T5DenseReluDense(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... method new_gelu (line 12) | def new_gelu(input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_encoder.pyi class T5Encoder (line 12) | class T5Encoder(nn.Module): method __init__ (line 13) | def __init__(self) -> None: ... method __call__ (line 14) | def __call__(self, tokens: mx.array): ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_feed_forward.pyi class T5FeedForward (line 8) | class T5FeedForward(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_layer_norm.pyi class T5LayerNorm (line 8) | class T5LayerNorm(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_text_encoder/t5_encoder/t5_self_attention.pyi class T5SelfAttention (line 8) | class T5SelfAttention(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... method shape (line 12) | def shape(states): # -> array: method un_shape (line 15) | def un_shape(states): # -> array: FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/ada_layer_norm_continuous.pyi class AdaLayerNormContinuous (line 8) | class AdaLayerNormContinuous(nn.Module): method __init__ (line 9) | def __init__(self, embedding_dim: int, conditioning_embedding_dim: int... method __call__ (line 10) | def __call__(self, x: mx.array, text_embeddings: mx.array) -> mx.array... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/ada_layer_norm_zero.pyi class AdaLayerNormZero (line 8) | class AdaLayerNormZero(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/ada_layer_norm_zero_single.pyi class AdaLayerNormZeroSingle (line 8) | class AdaLayerNormZeroSingle(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/common/attention_utils.pyi class AttentionUtils (line 8) | class AttentionUtils: method process_qkv (line 10) | def process_qkv( method compute_attention (line 21) | def compute_attention( method convert_key_padding_mask_to_additive_mask (line 31) | def convert_key_padding_mask_to_additive_mask( method apply_rope (line 35) | def apply_rope( method apply_rope_bshd (line 39) | def apply_rope_bshd( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/embed_nd.pyi class EmbedND (line 8) | class EmbedND(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, ids: mx.array) -> mx.array: ... method rope (line 12) | def rope(pos: mx.array, dim: int, theta: float) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/feed_forward.pyi class FeedForward (line 8) | class FeedForward(nn.Module): method __init__ (line 9) | def __init__(self, activation_function) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/guidance_embedder.pyi class GuidanceEmbedder (line 8) | class GuidanceEmbedder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, sample: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/joint_attention.pyi class JointAttention (line 9) | class JointAttention(nn.Module): method __init__ (line 25) | def __init__(self) -> None: ... method __call__ (line 26) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/joint_transformer_block.pyi class JointTransformerBlock (line 13) | class JointTransformerBlock(nn.Module): method __init__ (line 22) | def __init__(self, layer: Any) -> None: ... method __call__ (line 23) | def __call__( method apply_norm_and_feed_forward (line 31) | def apply_norm_and_feed_forward( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/single_block_attention.pyi class SingleBlockAttention (line 8) | class SingleBlockAttention(nn.Module): method __init__ (line 17) | def __init__(self) -> None: ... method __call__ (line 18) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/single_transformer_block.pyi class SingleTransformerBlock (line 15) | class SingleTransformerBlock(nn.Module): method __init__ (line 19) | def __init__(self, layer: Any) -> None: ... method __call__ (line 20) | def __call__( method _apply_feed_forward_and_projection (line 26) | def _apply_feed_forward_and_projection( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/text_embedder.pyi class TextEmbedder (line 8) | class TextEmbedder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, caption: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/time_text_embed.pyi class TimeTextEmbed (line 9) | class TimeTextEmbed(nn.Module): method __init__ (line 10) | def __init__(self, model_config: ModelConfig) -> None: ... method __call__ (line 11) | def __call__( FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/timestep_embedder.pyi class TimestepEmbedder (line 8) | class TimestepEmbedder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, sample: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_transformer/transformer.pyi class Transformer (line 18) | class Transformer(nn.Module): method __init__ (line 28) | def __init__( method __call__ (line 34) | def __call__( method compute_rotary_embeddings (line 46) | def compute_rotary_embeddings( method compute_text_embeddings (line 53) | def compute_text_embeddings( FILE: .mlx_typings/mflux/models/flux/model/flux_vae/common/attention.pyi class Attention (line 8) | class Attention(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/common/resnet_block_2d.pyi class ResnetBlock2D (line 8) | class ResnetBlock2D(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 21) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/common/unet_mid_block.pyi class UnetMidBlock (line 8) | class UnetMidBlock(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/conv_in.pyi class ConvIn (line 8) | class ConvIn(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/conv_norm_out.pyi class ConvNormOut (line 8) | class ConvNormOut(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/conv_out.pyi class ConvOut (line 8) | class ConvOut(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/decoder.pyi class Decoder (line 8) | class Decoder(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__(self, latents: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/up_block_1_or_2.pyi class UpBlock1Or2 (line 8) | class UpBlock1Or2(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/up_block_3.pyi class UpBlock3 (line 8) | class UpBlock3(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/up_block_4.pyi class UpBlock4 (line 8) | class UpBlock4(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/decoder/up_sampler.pyi class UpSampler (line 8) | class UpSampler(nn.Module): method __init__ (line 9) | def __init__(self, conv_in: int, conv_out: int) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... method up_sample_nearest (line 12) | def up_sample_nearest(x: mx.array, scale: int = ...): # -> array: FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/conv_in.pyi class ConvIn (line 8) | class ConvIn(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/conv_norm_out.pyi class ConvNormOut (line 8) | class ConvNormOut(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/conv_out.pyi class ConvOut (line 8) | class ConvOut(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/down_block_1.pyi class DownBlock1 (line 8) | class DownBlock1(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/down_block_2.pyi class DownBlock2 (line 8) | class DownBlock2(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/down_block_3.pyi class DownBlock3 (line 8) | class DownBlock3(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/down_block_4.pyi class DownBlock4 (line 8) | class DownBlock4(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/down_sampler.pyi class DownSampler (line 8) | class DownSampler(nn.Module): method __init__ (line 9) | def __init__(self, conv_in: int, conv_out: int) -> None: ... method __call__ (line 10) | def __call__(self, input_array: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/encoder/encoder.pyi class Encoder (line 8) | class Encoder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, latents: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/flux_vae/vae.pyi class VAE (line 8) | class VAE(nn.Module): method __init__ (line 13) | def __init__(self) -> None: ... method decode (line 14) | def decode(self, latents: mx.array) -> mx.array: ... method encode (line 15) | def encode(self, image: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/redux_encoder/redux_encoder.pyi class ReduxEncoder (line 8) | class ReduxEncoder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_encoder.pyi class SiglipEncoder (line 8) | class SiglipEncoder(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, inputs_embeds: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_encoder_layer.pyi class SiglipEncoderLayer (line 8) | class SiglipEncoderLayer(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_mlp.pyi class SiglipMLP (line 8) | class SiglipMLP(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_multi_head_attention_pooling_head.pyi class SiglipMultiHeadAttentionPoolingHead (line 8) | class SiglipMultiHeadAttentionPoolingHead(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_sdpa_attention.pyi class SiglipSdpaAttention (line 8) | class SiglipSdpaAttention(nn.Module): method __init__ (line 12) | def __init__(self) -> None: ... method __call__ (line 13) | def __call__(self, hidden_states: mx.array) -> mx.array: ... method reshape_and_transpose (line 15) | def reshape_and_transpose(x, batch_size, num_heads, head_dim): # -> a... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_vision_embeddings.pyi class SiglipVisionEmbeddings (line 8) | class SiglipVisionEmbeddings(nn.Module): method __init__ (line 12) | def __init__(self) -> None: ... method __call__ (line 13) | def __call__(self, pixel_values: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/model/siglip_vision_transformer/siglip_vision_transformer.pyi class SiglipVisionTransformer (line 8) | class SiglipVisionTransformer(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, pixel_values: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/flux/variants/concept_attention/attention_data.pyi class TimestepAttentionData (line 15) | class TimestepAttentionData: method stack_img_attentions (line 18) | def stack_img_attentions(self) -> mx.array: ... method stack_concept_attentions (line 19) | def stack_concept_attentions(self) -> mx.array: ... class GenerationAttentionData (line 21) | class GenerationAttentionData: method __init__ (line 22) | def __init__(self) -> None: ... method append (line 23) | def append(self, timestep_attention: TimestepAttentionData): # -> None: method stack_all_img_attentions (line 25) | def stack_all_img_attentions(self) -> mx.array: ... method stack_all_concept_attentions (line 26) | def stack_all_concept_attentions(self) -> mx.array: ... class ConceptHeatmap (line 29) | class ConceptHeatmap: method save (line 36) | def save( method get_metadata (line 39) | def get_metadata(self) -> dict: ... FILE: .mlx_typings/mflux/models/flux/variants/concept_attention/joint_attention_concept.pyi class JointAttentionConcept (line 8) | class JointAttentionConcept(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/flux/variants/concept_attention/joint_transformer_block_concept.pyi class LayerAttentionData (line 10) | class LayerAttentionData: class JointTransformerBlockConcept (line 16) | class JointTransformerBlockConcept(nn.Module): method __init__ (line 17) | def __init__(self, layer) -> None: ... method __call__ (line 18) | def __call__( FILE: .mlx_typings/mflux/models/flux/variants/concept_attention/transformer_concept.pyi class TransformerConcept (line 13) | class TransformerConcept(nn.Module): method __init__ (line 14) | def __init__( method __call__ (line 20) | def __call__( FILE: .mlx_typings/mflux/models/flux/variants/controlnet/transformer_controlnet.pyi class TransformerControlnet (line 10) | class TransformerControlnet(nn.Module): method __init__ (line 11) | def __init__( method __call__ (line 17) | def __call__( FILE: .mlx_typings/mflux/models/flux/variants/kontext/flux_kontext.pyi class Flux1Kontext (line 19) | class Flux1Kontext(nn.Module): method __init__ (line 30) | def __init__( method generate_image (line 38) | def generate_image( FILE: .mlx_typings/mflux/models/flux/variants/kontext/kontext_util.pyi class KontextUtil (line 9) | class KontextUtil: method create_image_conditioning_latents (line 11) | def create_image_conditioning_latents( FILE: .mlx_typings/mflux/models/flux/variants/txt2img/flux.pyi class Flux1 (line 17) | class Flux1(nn.Module): method __init__ (line 28) | def __init__( method generate_image (line 36) | def generate_image( method from_name (line 50) | def from_name(model_name: str, quantize: int | None = ...) -> Flux1: ... method save_model (line 51) | def save_model(self, base_path: str) -> None: ... method freeze (line 52) | def freeze(self, **kwargs): # -> None: FILE: .mlx_typings/mflux/models/flux/weights/flux_lora_mapping.pyi class FluxLoRAMapping (line 7) | class FluxLoRAMapping(LoRAMapping): method get_mapping (line 9) | def get_mapping() -> list[LoRATarget]: ... FILE: .mlx_typings/mflux/models/flux/weights/flux_weight_definition.pyi class FluxWeightDefinition (line 15) | class FluxWeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... class FluxControlnetWeightDefinition (line 25) | class FluxControlnetWeightDefinition: method get_controlnet_component (line 27) | def get_controlnet_component() -> ComponentDefinition: ... method get_components (line 29) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 31) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 33) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 35) | def quantization_predicate(path: str, module) -> bool: ... class FluxReduxWeightDefinition (line 37) | class FluxReduxWeightDefinition: method get_components (line 39) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 41) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 43) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 45) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/flux/weights/flux_weight_mapping.pyi class FluxWeightMapping (line 11) | class FluxWeightMapping(WeightMapping): method get_transformer_mapping (line 13) | def get_transformer_mapping() -> List[WeightTarget]: ... method get_controlnet_transformer_mapping (line 15) | def get_controlnet_transformer_mapping() -> List[WeightTarget]: ... method get_vae_mapping (line 17) | def get_vae_mapping() -> List[WeightTarget]: ... method get_t5_encoder_mapping (line 19) | def get_t5_encoder_mapping() -> List[WeightTarget]: ... method get_clip_encoder_mapping (line 21) | def get_clip_encoder_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/qwen/latent_creator/qwen_latent_creator.pyi class QwenLatentCreator (line 11) | class QwenLatentCreator: method create_noise (line 13) | def create_noise(seed: int, height: int, width: int) -> mx.array: ... method pack_latents (line 15) | def pack_latents( method unpack_latents (line 19) | def unpack_latents(latents: mx.array, height: int, width: int) -> mx.a... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_attention.pyi class QwenAttention (line 8) | class QwenAttention(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 18) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_encoder.pyi class QwenEncoder (line 8) | class QwenEncoder(nn.Module): method __init__ (line 9) | def __init__( method get_image_features (line 17) | def get_image_features( method __call__ (line 20) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_encoder_layer.pyi class QwenEncoderLayer (line 8) | class QwenEncoderLayer(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 19) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_mlp.pyi class QwenMLP (line 8) | class QwenMLP(nn.Module): method __init__ (line 9) | def __init__(self, hidden_size: int, intermediate_size: int) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_patch_merger.pyi class PatchMerger (line 8) | class PatchMerger(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__(self, x: mx.array, grid_thw: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_prompt_encoder.pyi class QwenPromptEncoder (line 13) | class QwenPromptEncoder: method encode_prompt (line 15) | def encode_prompt( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_rms_norm.pyi class QwenRMSNorm (line 8) | class QwenRMSNorm(nn.Module): method __init__ (line 9) | def __init__(self, hidden_size: int, eps: float = ...) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_rope.pyi class QwenRotaryEmbedding (line 8) | class QwenRotaryEmbedding(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 19) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_text_encoder.pyi class QwenTextEncoder (line 12) | class QwenTextEncoder(nn.Module): method __init__ (line 13) | def __init__(self) -> None: ... method __call__ (line 14) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_attention.pyi class VisionAttention (line 8) | class VisionAttention(nn.Module): method __init__ (line 9) | def __init__(self, embed_dim: int = ..., num_heads: int = ...) -> None... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_block.pyi class VisionBlock (line 8) | class VisionBlock(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_language_encoder.pyi class QwenVisionLanguageEncoder (line 8) | class QwenVisionLanguageEncoder(nn.Module): method __init__ (line 9) | def __init__(self, encoder=...) -> None: ... method __call__ (line 10) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_mlp.pyi class VisionMLP (line 8) | class VisionMLP(nn.Module): method __init__ (line 9) | def __init__(self, dim: int, hidden_dim: int) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_patch_embed.pyi class VisionPatchEmbed (line 8) | class VisionPatchEmbed(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 16) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_rotary_embedding.pyi class VisionRotaryEmbedding (line 8) | class VisionRotaryEmbedding(nn.Module): method __init__ (line 9) | def __init__(self, dim: int, theta: float = ...) -> None: ... method __call__ (line 10) | def __call__(self, max_grid_size: int) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_text_encoder/qwen_vision_transformer.pyi class VisionTransformer (line 8) | class VisionTransformer(nn.Module): method __init__ (line 9) | def __init__( method get_window_index (line 23) | def get_window_index(self, grid_thw: mx.array): # -> tuple[array, arr... method rot_pos_emb (line 25) | def rot_pos_emb(self, grid_thw: mx.array) -> mx.array: ... method __call__ (line 26) | def __call__(self, pixel_values: mx.array, grid_thw: mx.array) -> mx.a... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_attention.pyi class QwenAttention (line 9) | class QwenAttention(nn.Module): method __init__ (line 27) | def __init__( method __call__ (line 30) | def __call__( method _compute_attention_qwen (line 38) | def _compute_attention_qwen( method _convert_mask_for_qwen (line 47) | def _convert_mask_for_qwen( method _apply_rope_qwen (line 51) | def _apply_rope_qwen( FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_feed_forward.pyi class QwenFeedForward (line 8) | class QwenFeedForward(nn.Module): method __init__ (line 9) | def __init__(self, dim: int = ...) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_rope.pyi class QwenEmbedRopeMLX (line 8) | class QwenEmbedRopeMLX(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__( FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_time_text_embed.pyi class QwenTimeTextEmbed (line 8) | class QwenTimeTextEmbed(nn.Module): method __init__ (line 9) | def __init__(self, timestep_proj_dim: int = ..., inner_dim: int = ...)... method __call__ (line 10) | def __call__(self, timestep: mx.array, hidden_states: mx.array) -> mx.... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_timestep_embedding.pyi class QwenTimestepEmbedding (line 8) | class QwenTimestepEmbedding(nn.Module): method __init__ (line 9) | def __init__(self, proj_dim: int, inner_dim: int) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_timesteps.pyi class QwenTimesteps (line 8) | class QwenTimesteps(nn.Module): method __init__ (line 9) | def __init__(self, proj_dim: int = ..., scale: float = ...) -> None: ... method __call__ (line 10) | def __call__(self, timesteps: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_transformer.pyi class QwenTransformer (line 13) | class QwenTransformer(nn.Module): method __init__ (line 24) | def __init__( method __call__ (line 34) | def __call__( method _compute_timestep (line 45) | def _compute_timestep(t: int | float, config: Config) -> mx.array: ... method _compute_rotary_embeddings (line 47) | def _compute_rotary_embeddings( FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_transformer_block.pyi class QwenTransformerBlock (line 10) | class QwenTransformerBlock(nn.Module): method __init__ (line 23) | def __init__( method __call__ (line 26) | def __call__( method _modulate (line 36) | def _modulate(x: mx.array, mod_params: mx.array) -> tuple[mx.array, mx... FILE: .mlx_typings/mflux/models/qwen/model/qwen_transformer/qwen_transformer_rms_norm.pyi class QwenTransformerRMSNorm (line 8) | class QwenTransformerRMSNorm(nn.Module): method __init__ (line 9) | def __init__(self, dim: int, eps: float = ...) -> None: ... method __call__ (line 10) | def __call__(self, hidden_states: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_attention_block_3d.pyi class QwenImageAttentionBlock3D (line 8) | class QwenImageAttentionBlock3D(nn.Module): method __init__ (line 9) | def __init__(self, dim: int) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_causal_conv_3d.pyi class QwenImageCausalConv3D (line 8) | class QwenImageCausalConv3D(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 17) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_decoder_3d.pyi class QwenImageDecoder3D (line 8) | class QwenImageDecoder3D(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_down_block_3d.pyi class QwenImageDownBlock3D (line 8) | class QwenImageDownBlock3D(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 16) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_encoder_3d.pyi class QwenImageEncoder3D (line 8) | class QwenImageEncoder3D(nn.Module): method __init__ (line 9) | def __init__(self) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_mid_block_3d.pyi class QwenImageMidBlock3D (line 8) | class QwenImageMidBlock3D(nn.Module): method __init__ (line 9) | def __init__(self, dim: int, num_layers: int = ...) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_res_block_3d.pyi class QwenImageResBlock3D (line 8) | class QwenImageResBlock3D(nn.Module): method __init__ (line 9) | def __init__(self, in_channels: int, out_channels: int) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_resample_3d.pyi class QwenImageResample3D (line 8) | class QwenImageResample3D(nn.Module): method __init__ (line 9) | def __init__(self, dim: int, mode: str) -> None: ... method __call__ (line 10) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_rms_norm.pyi class QwenImageRMSNorm (line 8) | class QwenImageRMSNorm(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 12) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_image_up_block_3d.pyi class QwenImageUpBlock3D (line 8) | class QwenImageUpBlock3D(nn.Module): method __init__ (line 9) | def __init__( method __call__ (line 16) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/model/qwen_vae/qwen_vae.pyi class QwenVAE (line 8) | class QwenVAE(nn.Module): method __init__ (line 13) | def __init__(self) -> None: ... method decode (line 14) | def decode(self, latents: mx.array) -> mx.array: ... method encode (line 15) | def encode(self, latents: mx.array) -> mx.array: ... FILE: .mlx_typings/mflux/models/qwen/qwen_initializer.pyi class QwenImageInitializer (line 7) | class QwenImageInitializer: method init (line 9) | def init( method init_edit (line 18) | def init_edit( FILE: .mlx_typings/mflux/models/qwen/tokenizer/qwen_image_processor.pyi function smart_resize (line 12) | def smart_resize( class QwenImageProcessor (line 20) | class QwenImageProcessor: method __init__ (line 21) | def __init__( method preprocess (line 31) | def preprocess( method get_number_of_image_patches (line 34) | def get_number_of_image_patches( FILE: .mlx_typings/mflux/models/qwen/tokenizer/qwen_vision_language_processor.pyi class QwenVisionLanguageProcessor (line 9) | class QwenVisionLanguageProcessor: method __init__ (line 10) | def __init__( method __call__ (line 17) | def __call__( FILE: .mlx_typings/mflux/models/qwen/tokenizer/qwen_vision_language_tokenizer.pyi class QwenVisionLanguageTokenizer (line 13) | class QwenVisionLanguageTokenizer: method __init__ (line 14) | def __init__( method tokenize_with_image (line 20) | def tokenize_with_image( method tokenize_text_only (line 27) | def tokenize_text_only(self, prompt: str) -> tuple[mx.array, mx.array]... FILE: .mlx_typings/mflux/models/qwen/variants/edit/qwen_edit_util.pyi class QwenEditUtil (line 8) | class QwenEditUtil: method create_image_conditioning_latents (line 10) | def create_image_conditioning_latents( FILE: .mlx_typings/mflux/models/qwen/variants/edit/qwen_image_edit.pyi class QwenImageEdit (line 16) | class QwenImageEdit(nn.Module): method __init__ (line 26) | def __init__( method generate_image (line 34) | def generate_image( method _encode_prompts_with_images (line 47) | def _encode_prompts_with_images( FILE: .mlx_typings/mflux/models/qwen/variants/txt2img/qwen_image.pyi class QwenImage (line 15) | class QwenImage(nn.Module): method __init__ (line 25) | def __init__( method generate_image (line 33) | def generate_image( method save_model (line 46) | def save_model(self, base_path: str) -> None: ... method compute_guided_noise (line 48) | def compute_guided_noise( FILE: .mlx_typings/mflux/models/qwen/weights/qwen_lora_mapping.pyi class QwenLoRAMapping (line 8) | class QwenLoRAMapping(LoRAMapping): method get_mapping (line 10) | def get_mapping() -> List[LoRATarget]: ... FILE: .mlx_typings/mflux/models/qwen/weights/qwen_weight_definition.pyi class QwenWeightDefinition (line 15) | class QwenWeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/qwen/weights/qwen_weight_mapping.pyi class QwenWeightMapping (line 11) | class QwenWeightMapping(WeightMapping): method get_transformer_mapping (line 13) | def get_transformer_mapping() -> List[WeightTarget]: ... method get_vae_mapping (line 15) | def get_vae_mapping() -> List[WeightTarget]: ... method get_text_encoder_mapping (line 17) | def get_text_encoder_mapping() -> List[WeightTarget]: ... method get_mapping (line 19) | def get_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/seedvr2/weights/seedvr2_weight_definition.pyi class SeedVR2WeightDefinition (line 15) | class SeedVR2WeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/seedvr2/weights/seedvr2_weight_mapping.pyi class SeedVR2WeightMapping (line 11) | class SeedVR2WeightMapping(WeightMapping): method get_transformer_mapping (line 13) | def get_transformer_mapping() -> List[WeightTarget]: ... method get_vae_mapping (line 15) | def get_vae_mapping() -> List[WeightTarget]: ... FILE: .mlx_typings/mflux/models/z_image/latent_creator/z_image_latent_creator.pyi class ZImageLatentCreator (line 7) | class ZImageLatentCreator: method create_noise (line 9) | def create_noise(seed: int, height: int, width: int) -> mx.array: ... method pack_latents (line 11) | def pack_latents(latents: mx.array, height: int, width: int) -> mx.arr... method unpack_latents (line 13) | def unpack_latents(latents: mx.array, height: int, width: int) -> mx.a... FILE: .mlx_typings/mflux/models/z_image/weights/z_image_weight_definition.pyi class ZImageWeightDefinition (line 15) | class ZImageWeightDefinition: method get_components (line 17) | def get_components() -> List[ComponentDefinition]: ... method get_tokenizers (line 19) | def get_tokenizers() -> List[TokenizerDefinition]: ... method get_download_patterns (line 21) | def get_download_patterns() -> List[str]: ... method quantization_predicate (line 23) | def quantization_predicate(path: str, module) -> bool: ... FILE: .mlx_typings/mflux/models/z_image/weights/z_image_weight_mapping.pyi class ZImageWeightMapping (line 10) | class ZImageWeightMapping(WeightMapping): method get_text_encoder_mapping (line 12) | def get_text_encoder_mapping() -> list[WeightTarget]: ... method get_vae_mapping (line 14) | def get_vae_mapping() -> list[WeightTarget]: ... method get_transformer_mapping (line 16) | def get_transformer_mapping() -> list[WeightTarget]: ... FILE: .mlx_typings/mflux/utils/box_values.pyi class AbsoluteBoxValues (line 8) | class AbsoluteBoxValues: class BoxValueError (line 15) | class BoxValueError(ValueError): ... class BoxValues (line 18) | class BoxValues: method normalize_to_dimensions (line 23) | def normalize_to_dimensions(self, width, height) -> AbsoluteBoxValues:... method parse (line 25) | def parse(value, delimiter=...) -> BoxValues: ... FILE: .mlx_typings/mflux/utils/exceptions.pyi class MFluxException (line 9) | class MFluxException(Exception): ... class ImageSavingException (line 10) | class ImageSavingException(MFluxException): ... class MetadataEmbedException (line 11) | class MetadataEmbedException(MFluxException): ... class MFluxUserException (line 12) | class MFluxUserException(MFluxException): ... class PromptFileReadError (line 13) | class PromptFileReadError(MFluxUserException): ... class StopImageGenerationException (line 14) | class StopImageGenerationException(MFluxUserException): ... class StopTrainingException (line 15) | class StopTrainingException(MFluxUserException): ... class CommandExecutionError (line 17) | class CommandExecutionError(MFluxException): method __init__ (line 18) | def __init__( class ReferenceVsOutputImageError (line 22) | class ReferenceVsOutputImageError(AssertionError): ... class ModelConfigError (line 23) | class ModelConfigError(ValueError): ... class InvalidBaseModel (line 24) | class InvalidBaseModel(ModelConfigError): ... FILE: .mlx_typings/mflux/utils/generated_image.pyi class GeneratedImage (line 13) | class GeneratedImage: method __init__ (line 16) | def __init__( method get_right_half (line 44) | def get_right_half(self) -> GeneratedImage: ... method save (line 45) | def save( method save_with_heatmap (line 48) | def save_with_heatmap( method save_concept_heatmap (line 51) | def save_concept_heatmap( FILE: .mlx_typings/mflux/utils/image_util.pyi class ImageUtil (line 17) | class ImageUtil: method to_image (line 19) | def to_image( method to_composite_image (line 41) | def to_composite_image( method to_array (line 45) | def to_array(image: PIL.Image.Image, is_mask: bool = ...) -> mx.array:... method load_image (line 47) | def load_image( method expand_image (line 51) | def expand_image( method create_outpaint_mask_image (line 61) | def create_outpaint_mask_image( method create_bordered_image (line 66) | def create_bordered_image( method scale_to_dimensions (line 78) | def scale_to_dimensions( method save_image (line 82) | def save_image( method preprocess_for_model (line 90) | def preprocess_for_model( method preprocess_for_depth_pro (line 98) | def preprocess_for_depth_pro( FILE: .mlx_typings/mflux/utils/metadata_builder.pyi class MetadataBuilder (line 9) | class MetadataBuilder: method embed_metadata (line 12) | def embed_metadata(metadata: dict, path: str | Path) -> None: ... method build_xmp_packet (line 14) | def build_xmp_packet(metadata: dict) -> str: ... method build_iptc_binary (line 16) | def build_iptc_binary(metadata: dict) -> bytes: ... FILE: .mlx_typings/mflux/utils/version_util.pyi class VersionUtil (line 9) | class VersionUtil: method get_mflux_version (line 11) | def get_mflux_version() -> str: ... FILE: .mlx_typings/mlx/core/__init__.pyi class ArrayAt (line 23) | class ArrayAt: method __getitem__ (line 25) | def __getitem__(self, indices: object | None) -> ArrayAt: ... method add (line 26) | def add( method subtract (line 36) | def subtract( method multiply (line 46) | def multiply( method divide (line 56) | def divide( method maximum (line 66) | def maximum( method minimum (line 76) | def minimum( class ArrayIterator (line 87) | class ArrayIterator: method __next__ (line 89) | def __next__(self) -> array: ... method __iter__ (line 90) | def __iter__(self) -> ArrayIterator: ... class ArrayLike (line 92) | class ArrayLike: method __init__ (line 97) | def __init__(self, arg: object, /) -> None: ... class Device (line 99) | class Device: method __init__ (line 101) | def __init__(self, type: DeviceType, index: int = ...) -> None: ... method type (line 103) | def type(self) -> DeviceType: ... method __repr__ (line 104) | def __repr__(self) -> str: ... method __eq__ (line 105) | def __eq__(self, arg: object, /) -> bool: ... class DeviceType (line 107) | class DeviceType(enum.Enum): method __eq__ (line 110) | def __eq__(self, arg: object, /) -> bool: ... class Dtype (line 112) | class Dtype: method size (line 120) | def size(self) -> int: method __repr__ (line 123) | def __repr__(self) -> str: ... method __eq__ (line 124) | def __eq__(self, arg: object, /) -> bool: ... method __hash__ (line 125) | def __hash__(self) -> int: ... class DtypeCategory (line 127) | class DtypeCategory(enum.Enum): class FunctionExporter (line 176) | class FunctionExporter: method close (line 183) | def close(self) -> None: ... method __enter__ (line 184) | def __enter__(self) -> FunctionExporter: ... method __exit__ (line 185) | def __exit__( method __call__ (line 191) | def __call__(self, *args, **kwargs) -> None: ... class Stream (line 193) | class Stream: method device (line 196) | def device(self) -> Device: ... method __repr__ (line 197) | def __repr__(self) -> str: ... method __eq__ (line 198) | def __eq__(self, arg: object, /) -> bool: ... class StreamContext (line 200) | class StreamContext: method __init__ (line 209) | def __init__(self, s: Stream | Device) -> None: ... method __enter__ (line 210) | def __enter__(self) -> None: ... method __exit__ (line 211) | def __exit__( function device_info (line 218) | def device_info() -> dict[str, str | int]: function abs (line 234) | def abs(a: array, /, *, stream: Stream | Device | None = ...) -> array: function add (line 245) | def add( function addmm (line 264) | def addmm( function all (line 292) | def all( function allclose (line 315) | def allclose( function any (line 351) | def any( function arange (line 375) | def arange( function arange (line 406) | def arange( function arccos (line 413) | def arccos(a: array, /, *, stream: Stream | Device | None = ...) -> array: function arccosh (line 424) | def arccosh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function arcsin (line 435) | def arcsin(a: array, /, *, stream: Stream | Device | None = ...) -> array: function arcsinh (line 446) | def arcsinh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function arctan (line 457) | def arctan(a: array, /, *, stream: Stream | Device | None = ...) -> array: function arctan2 (line 468) | def arctan2(a: array, b: array, /, *, stream: Stream | Device | None = .... function arctanh (line 480) | def arctanh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function argmax (line 491) | def argmax( function argmin (line 513) | def argmin( function argpartition (line 535) | def argpartition( function argsort (line 564) | def argsort( class array (line 584) | class array: method __init__ (line 586) | def __init__( method __buffer__ (line 591) | def __buffer__(self, flags, /): method __release_buffer__ (line 596) | def __release_buffer__(self, buffer, /): method size (line 602) | def size(self) -> int: method ndim (line 606) | def ndim(self) -> int: method itemsize (line 610) | def itemsize(self) -> int: method nbytes (line 614) | def nbytes(self) -> int: method shape (line 618) | def shape(self) -> tuple[int, ...]: method dtype (line 627) | def dtype(self) -> Dtype: method real (line 631) | def real(self) -> array: method imag (line 635) | def imag(self) -> array: method item (line 638) | def item(self) -> scalar: method tolist (line 646) | def tolist(self) -> list_or_scalar: method astype (line 662) | def astype(self, dtype: Dtype, stream: Stream | Device | None = ...) -... method __array_namespace__ (line 674) | def __array_namespace__(self, api_version: str | None = ...) -> types.... method __getitem__ (line 689) | def __getitem__(self, arg: object | None) -> array: ... method __setitem__ (line 690) | def __setitem__( method at (line 702) | def at(self) -> ArrayAt: method __len__ (line 743) | def __len__(self) -> int: ... method __iter__ (line 744) | def __iter__(self) -> ArrayIterator: ... method __getstate__ (line 745) | def __getstate__(self) -> tuple: ... method __setstate__ (line 746) | def __setstate__(self, arg: tuple, /) -> None: ... method __dlpack__ (line 747) | def __dlpack__(self) -> _ArrayLike: ... method __dlpack_device__ (line 748) | def __dlpack_device__(self) -> tuple: ... method __copy__ (line 749) | def __copy__(self) -> array: ... method __deepcopy__ (line 750) | def __deepcopy__(self, memo: dict) -> array: ... method __add__ (line 751) | def __add__( method __iadd__ (line 761) | def __iadd__( method __radd__ (line 771) | def __radd__( method __sub__ (line 781) | def __sub__( method __isub__ (line 791) | def __isub__( method __rsub__ (line 801) | def __rsub__( method __mul__ (line 811) | def __mul__( method __imul__ (line 821) | def __imul__( method __rmul__ (line 831) | def __rmul__( method __truediv__ (line 841) | def __truediv__( method __itruediv__ (line 851) | def __itruediv__( method __rtruediv__ (line 861) | def __rtruediv__( method __div__ (line 871) | def __div__( method __rdiv__ (line 881) | def __rdiv__( method __floordiv__ (line 891) | def __floordiv__( method __ifloordiv__ (line 901) | def __ifloordiv__( method __rfloordiv__ (line 911) | def __rfloordiv__( method __mod__ (line 921) | def __mod__( method __imod__ (line 931) | def __imod__( method __rmod__ (line 941) | def __rmod__( method __eq__ (line 951) | def __eq__( method __lt__ (line 961) | def __lt__( method __le__ (line 971) | def __le__( method __gt__ (line 981) | def __gt__( method __ge__ (line 991) | def __ge__( method __ne__ (line 1001) | def __ne__( method __neg__ (line 1011) | def __neg__(self) -> array: ... method __bool__ (line 1012) | def __bool__(self) -> bool: ... method __repr__ (line 1013) | def __repr__(self) -> str: ... method __matmul__ (line 1014) | def __matmul__(self, other: array) -> array: ... method __imatmul__ (line 1015) | def __imatmul__(self, other: array) -> array: ... method __pow__ (line 1016) | def __pow__( method __rpow__ (line 1026) | def __rpow__( method __ipow__ (line 1036) | def __ipow__( method __invert__ (line 1046) | def __invert__(self) -> array: ... method __and__ (line 1047) | def __and__( method __iand__ (line 1057) | def __iand__( method __or__ (line 1067) | def __or__( method __ior__ (line 1077) | def __ior__( method __lshift__ (line 1087) | def __lshift__( method __ilshift__ (line 1097) | def __ilshift__( method __rshift__ (line 1107) | def __rshift__( method __irshift__ (line 1117) | def __irshift__( method __xor__ (line 1127) | def __xor__( method __ixor__ (line 1137) | def __ixor__( method __int__ (line 1147) | def __int__(self) -> int: ... method __float__ (line 1148) | def __float__(self) -> float: ... method flatten (line 1149) | def flatten( method reshape (line 1158) | def reshape(self, *shape: int, stream: Stream | Device | None = ...) -... method squeeze (line 1166) | def squeeze( method abs (line 1174) | def abs(self, *, stream: Stream | Device | None = ...) -> array: method __abs__ (line 1177) | def __abs__(self) -> array: method square (line 1180) | def square(self, *, stream: Stream | Device | None = ...) -> array: method sqrt (line 1183) | def sqrt(self, *, stream: Stream | Device | None = ...) -> array: method rsqrt (line 1186) | def rsqrt(self, *, stream: Stream | Device | None = ...) -> array: method reciprocal (line 1189) | def reciprocal(self, *, stream: Stream | Device | None = ...) -> array: method exp (line 1192) | def exp(self, *, stream: Stream | Device | None = ...) -> array: method log (line 1195) | def log(self, *, stream: Stream | Device | None = ...) -> array: method log2 (line 1198) | def log2(self, *, stream: Stream | Device | None = ...) -> array: method log10 (line 1201) | def log10(self, *, stream: Stream | Device | None = ...) -> array: method sin (line 1204) | def sin(self, *, stream: Stream | Device | None = ...) -> array: method cos (line 1207) | def cos(self, *, stream: Stream | Device | None = ...) -> array: method log1p (line 1210) | def log1p(self, *, stream: Stream | Device | None = ...) -> array: method all (line 1213) | def all( method any (line 1222) | def any( method moveaxis (line 1231) | def moveaxis( method swapaxes (line 1236) | def swapaxes( method transpose (line 1241) | def transpose(self, *axes: int, stream: Stream | Device | None = ...) ... method T (line 1250) | def T(self) -> array: method sum (line 1253) | def sum( method prod (line 1262) | def prod( method min (line 1271) | def min( method max (line 1280) | def max( method logcumsumexp (line 1289) | def logcumsumexp( method logsumexp (line 1299) | def logsumexp( method mean (line 1308) | def mean( method std (line 1317) | def std( method var (line 1327) | def var( method split (line 1337) | def split( method argmin (line 1346) | def argmin( method argmax (line 1355) | def argmax( method cumsum (line 1364) | def cumsum( method cumprod (line 1374) | def cumprod( method cummax (line 1384) | def cummax( method cummin (line 1394) | def cummin( method round (line 1404) | def round( method diagonal (line 1409) | def diagonal( method diag (line 1418) | def diag(self, k: int = ..., *, stream: Stream | Device | None = ...) ... method conj (line 1421) | def conj(self, *, stream: Stream | Device | None = ...) -> array: method view (line 1424) | def view(self, dtype: Dtype, *, stream: Stream | Device | None = ...) ... function array_equal (line 1427) | def array_equal( function as_strided (line 1450) | def as_strided( function async_eval (line 1486) | def async_eval(*args: MX_ARRAY_TREE) -> None: function atleast_1d (line 1513) | def atleast_1d( function atleast_2d (line 1527) | def atleast_2d( function atleast_3d (line 1541) | def atleast_3d( function bitwise_and (line 1557) | def bitwise_and( function bitwise_invert (line 1576) | def bitwise_invert(a: scalar | array, stream: Stream | Device | None = .... function bitwise_or (line 1589) | def bitwise_or( function bitwise_xor (line 1608) | def bitwise_xor( function block_masked_mm (line 1628) | def block_masked_mm( function broadcast_arrays (line 1667) | def broadcast_arrays( function broadcast_shapes (line 1682) | def broadcast_shapes(*shapes: Sequence[int]) -> tuple[int]: function broadcast_to (line 1707) | def broadcast_to( function ceil (line 1727) | def ceil(a: array, /, *, stream: Stream | Device | None = ...) -> array: function checkpoint (line 1738) | def checkpoint(fun: Callable) -> Callable: ... function clear_cache (line 1739) | def clear_cache() -> None: function clip (line 1746) | def clip( function compile (line 1770) | def compile( function concat (line 1808) | def concat( function concatenate (line 1816) | def concatenate( function conj (line 1834) | def conj(a: array, *, stream: Stream | Device | None = ...) -> array: function conjugate (line 1846) | def conjugate(a: array, *, stream: Stream | Device | None = ...) -> array: function contiguous (line 1858) | def contiguous( function conv1d (line 1876) | def conv1d( function conv2d (line 1902) | def conv2d( function conv3d (line 1934) | def conv3d( function conv_general (line 1968) | def conv_general( function conv_transpose1d (line 2009) | def conv_transpose1d( function conv_transpose2d (line 2037) | def conv_transpose2d( function conv_transpose3d (line 2075) | def conv_transpose3d( function convolve (line 2113) | def convolve( function cos (line 2131) | def cos(a: array, /, *, stream: Stream | Device | None = ...) -> array: function cosh (line 2142) | def cosh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function cummax (line 2155) | def cummax( function cummin (line 2180) | def cummin( function cumprod (line 2205) | def cumprod( function cumsum (line 2230) | def cumsum( class custom_function (line 2255) | class custom_function: method __init__ (line 2324) | def __init__(self, f: Callable) -> None: ... method __call__ (line 2325) | def __call__(self, *args, **kwargs) -> object: ... method vjp (line 2326) | def vjp(self, f: Callable): method jvp (line 2345) | def jvp(self, f: Callable): method vmap (line 2362) | def vmap(self, f: Callable): function default_device (line 2382) | def default_device() -> Device: function default_stream (line 2385) | def default_stream(device: Device | DeviceType) -> Stream: function degrees (line 2388) | def degrees(a: array, /, *, stream: Stream | Device | None = ...) -> array: function depends (line 2399) | def depends(inputs: array | Sequence[array], dependencies: array | Seque... function dequantize (line 2413) | def dequantize( function diag (line 2453) | def diag(a: array, /, k: int = ..., *, stream: Stream | Device | None = ... function diagonal (line 2469) | def diagonal( function disable_compile (line 2500) | def disable_compile() -> None: function divide (line 2506) | def divide( function divmod (line 2525) | def divmod( function einsum (line 2547) | def einsum(subscripts: str, *operands, stream: Stream | Device | None = ... function einsum_path (line 2559) | def einsum_path(subscripts: str, *operands): function enable_compile (line 2573) | def enable_compile() -> None: function equal (line 2579) | def equal( function erf (line 2598) | def erf(a: array, /, *, stream: Stream | Device | None = ...) -> array: function erfinv (line 2612) | def erfinv(a: array, /, *, stream: Stream | Device | None = ...) -> array: function eval (line 2633) | def eval(*args: MX_ARRAY_TREE | None) -> None: function exp (line 2644) | def exp(a: array, /, *, stream: Stream | Device | None = ...) -> array: function expand_dims (line 2655) | def expand_dims( function expm1 (line 2673) | def expm1(a: array, /, *, stream: Stream | Device | None = ...) -> array: function export_function (line 2686) | def export_function( function export_to_dot (line 2725) | def export_to_dot(file: object, *args, **kwargs) -> None: function exporter (line 2747) | def exporter(file: str, fun: Callable, *, shapeless: bool = ...) -> Func... function eye (line 2775) | def eye( class finfo (line 2797) | class finfo: method __init__ (line 2799) | def __init__(self, arg: Dtype, /) -> None: ... method min (line 2801) | def min(self) -> float: method max (line 2805) | def max(self) -> float: method eps (line 2809) | def eps(self) -> float: method dtype (line 2816) | def dtype(self) -> Dtype: method __repr__ (line 2819) | def __repr__(self) -> str: ... function flatten (line 2821) | def flatten( function floor (line 2861) | def floor(a: array, /, *, stream: Stream | Device | None = ...) -> array: function floor_divide (line 2872) | def floor_divide( function full (line 2891) | def full( function gather_mm (line 2914) | def gather_mm( function gather_qmm (line 2957) | def gather_qmm( function get_active_memory (line 3010) | def get_active_memory() -> int: function get_cache_memory (line 3018) | def get_cache_memory() -> int: function get_peak_memory (line 3026) | def get_peak_memory() -> int: function grad (line 3036) | def grad( function greater (line 3062) | def greater( function greater_equal (line 3081) | def greater_equal( function hadamard_transform (line 3100) | def hadamard_transform( function identity (line 3126) | def identity( class iinfo (line 3141) | class iinfo: method __init__ (line 3143) | def __init__(self, arg: Dtype, /) -> None: ... method min (line 3145) | def min(self) -> int: method max (line 3149) | def max(self) -> int: method dtype (line 3153) | def dtype(self) -> Dtype: method __repr__ (line 3156) | def __repr__(self) -> str: ... function imag (line 3158) | def imag(a: array, /, *, stream: Stream | Device | None = ...) -> array: function import_function (line 3169) | def import_function(file: str) -> Callable: function inner (line 3200) | def inner(a: array, b: array, /, *, stream: Stream | Device | None = ...... function is_available (line 3218) | def is_available(device: Device) -> bool: function isclose (line 3221) | def isclose( function isfinite (line 3258) | def isfinite(a: array, stream: Stream | Device | None = ...) -> array: function isinf (line 3271) | def isinf(a: array, stream: Stream | Device | None = ...) -> array: function isnan (line 3282) | def isnan(a: array, stream: Stream | Device | None = ...) -> array: function isneginf (line 3293) | def isneginf(a: array, stream: Stream | Device | None = ...) -> array: function isposinf (line 3305) | def isposinf(a: array, stream: Stream | Device | None = ...) -> array: function issubdtype (line 3317) | def issubdtype(arg1: Dtype | DtypeCategory, arg2: Dtype | DtypeCategory)... function jvp (line 3367) | def jvp( function kron (line 3390) | def kron(a: array, b: array, *, stream: Stream | Device | None = ...) ->... function left_shift (line 3414) | def left_shift( function less (line 3434) | def less( function less_equal (line 3453) | def less_equal( function linspace (line 3472) | def linspace( function load (line 3493) | def load( function log (line 3528) | def log(a: array, /, *, stream: Stream | Device | None = ...) -> array: function log10 (line 3539) | def log10(a: array, /, *, stream: Stream | Device | None = ...) -> array: function log1p (line 3550) | def log1p(a: array, /, *, stream: Stream | Device | None = ...) -> array: function log2 (line 3561) | def log2(a: array, /, *, stream: Stream | Device | None = ...) -> array: function logaddexp (line 3572) | def logaddexp( function logcumsumexp (line 3595) | def logcumsumexp( function logical_and (line 3620) | def logical_and( function logical_not (line 3634) | def logical_not(a: array, /, *, stream: Stream | Device | None = ...) ->... function logical_or (line 3645) | def logical_or(a: array, b: array, /, *, stream: Stream | Device | None ... function logsumexp (line 3657) | def logsumexp( function matmul (line 3686) | def matmul(a: array, b: array, /, *, stream: Stream | Device | None = ..... function max (line 3711) | def max( function maximum (line 3734) | def maximum( function mean (line 3755) | def mean( function meshgrid (line 3778) | def meshgrid( function min (line 3799) | def min( function minimum (line 3822) | def minimum( function moveaxis (line 3843) | def moveaxis( function multiply (line 3863) | def multiply( function nan_to_num (line 3884) | def nan_to_num( function negative (line 3909) | def negative(a: array, /, *, stream: Stream | Device | None = ...) -> ar... function new_stream (line 3920) | def new_stream(device: Device) -> Stream: function not_equal (line 3925) | def not_equal( function ones (line 3946) | def ones( function ones_like (line 3964) | def ones_like(a: array, /, *, stream: Stream | Device | None = ...) -> a... function outer (line 3975) | def outer(a: array, b: array, /, *, stream: Stream | Device | None = ...... function pad (line 3987) | def pad( function partition (line 4016) | def partition( function permute_dims (line 4044) | def permute_dims( function power (line 4055) | def power( function prod (line 4076) | def prod( function put_along_axis (line 4099) | def put_along_axis( function quantize (line 4126) | def quantize( function quantized_matmul (line 4198) | def quantized_matmul( function radians (line 4236) | def radians(a: array, /, *, stream: Stream | Device | None = ...) -> array: function real (line 4247) | def real(a: array, /, *, stream: Stream | Device | None = ...) -> array: function reciprocal (line 4258) | def reciprocal(a: array, /, *, stream: Stream | Device | None = ...) -> ... function remainder (line 4269) | def remainder( function repeat (line 4289) | def repeat( function reset_peak_memory (line 4311) | def reset_peak_memory() -> None: function reshape (line 4314) | def reshape( function right_shift (line 4330) | def right_shift( function roll (line 4350) | def roll( function round (line 4377) | def round( function rsqrt (line 4399) | def rsqrt(a: array, /, *, stream: Stream | Device | None = ...) -> array: function save (line 4410) | def save(file: str | pathlib.Path, arr: array) -> None: function save_gguf (line 4419) | def save_gguf( function save_safetensors (line 4440) | def save_safetensors( function savez (line 4460) | def savez(file: str | pathlib.Path, *args, **kwargs): function savez_compressed (line 4486) | def savez_compressed(file: str | pathlib.Path, *args, **kwargs): function segmented_mm (line 4497) | def segmented_mm( function set_cache_limit (line 4513) | def set_cache_limit(limit: int) -> int: function set_default_device (line 4531) | def set_default_device(device: Device | DeviceType) -> None: function set_default_stream (line 4534) | def set_default_stream(stream: Stream) -> None: function set_memory_limit (line 4545) | def set_memory_limit(limit: int) -> int: function set_wired_limit (line 4564) | def set_wired_limit(limit: int) -> int: function sigmoid (line 4594) | def sigmoid(a: array, /, *, stream: Stream | Device | None = ...) -> array: function sign (line 4610) | def sign(a: array, /, *, stream: Stream | Device | None = ...) -> array: function sin (line 4623) | def sin(a: array, /, *, stream: Stream | Device | None = ...) -> array: function sinh (line 4634) | def sinh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function slice (line 4645) | def slice( function slice_update (line 4676) | def slice_update( function softmax (line 4705) | def softmax( function sort (line 4731) | def sort( function split (line 4751) | def split( function sqrt (line 4775) | def sqrt(a: array, /, *, stream: Stream | Device | None = ...) -> array: function square (line 4786) | def square(a: array, /, *, stream: Stream | Device | None = ...) -> array: function squeeze (line 4797) | def squeeze( function stack (line 4816) | def stack( function std (line 4835) | def std( function stop_gradient (line 4861) | def stop_gradient(a: array, /, *, stream: Stream | Device | None = ...) ... function stream (line 4877) | def stream(s: Stream | Device) -> StreamContext: function subtract (line 4899) | def subtract( function sum (line 4918) | def sum( function swapaxes (line 4941) | def swapaxes( function synchronize (line 4956) | def synchronize(stream: Stream | None = ...) -> None: function take (line 4966) | def take( function take_along_axis (line 4993) | def take_along_axis( function tan (line 5016) | def tan(a: array, /, *, stream: Stream | Device | None = ...) -> array: function tanh (line 5027) | def tanh(a: array, /, *, stream: Stream | Device | None = ...) -> array: function tensordot (line 5038) | def tensordot( function tile (line 5062) | def tile( function topk (line 5080) | def topk( function trace (line 5104) | def trace( function transpose (line 5132) | def transpose( function tri (line 5151) | def tri( function tril (line 5173) | def tril(x: array, k: int, *, stream: Stream | Device | None = ...) -> a... function triu (line 5186) | def triu(x: array, k: int, *, stream: Stream | Device | None = ...) -> a... function unflatten (line 5204) | def unflatten( function value_and_grad (line 5235) | def value_and_grad( function var (line 5290) | def var( function view (line 5316) | def view( function vjp (line 5337) | def vjp( function vmap (line 5360) | def vmap(fun: Callable, in_axes: object = ..., out_axes: object = ...) -... function where (line 5381) | def where( function zeros (line 5405) | def zeros( function zeros_like (line 5423) | def zeros_like(a: array, /, *, stream: Stream | Device | None = ...) -> ... FILE: .mlx_typings/mlx/core/cuda/__init__.pyi function is_available (line 1) | def is_available() -> bool: FILE: .mlx_typings/mlx/core/distributed/__init__.pyi class Group (line 5) | class Group: method rank (line 10) | def rank(self) -> int: method size (line 13) | def size(self) -> int: method split (line 16) | def split(self, color: int, key: int = ...) -> Group: function all_gather (line 31) | def all_gather( function all_max (line 52) | def all_max( function all_min (line 72) | def all_min( function all_sum (line 92) | def all_sum( function init (line 112) | def init(strict: bool = ..., backend: str = ...) -> Group: function is_available (line 138) | def is_available() -> bool: function recv (line 141) | def recv( function recv_like (line 167) | def recv_like( function send (line 194) | def send( FILE: .mlx_typings/mlx/core/metal/__init__.pyi function clear_cache (line 1) | def clear_cache() -> None: ... function device_info (line 2) | def device_info() -> dict[str, str | int]: function get_active_memory (line 18) | def get_active_memory() -> int: ... function get_cache_memory (line 19) | def get_cache_memory() -> int: ... function get_peak_memory (line 20) | def get_peak_memory() -> int: ... function is_available (line 21) | def is_available() -> bool: function reset_peak_memory (line 24) | def reset_peak_memory() -> None: ... function set_cache_limit (line 25) | def set_cache_limit(limit: int) -> int: ... function set_memory_limit (line 26) | def set_memory_limit(limit: int) -> int: ... function set_wired_limit (line 27) | def set_wired_limit(limit: int) -> int: ... function start_capture (line 28) | def start_capture(path: str) -> None: function stop_capture (line 37) | def stop_capture() -> None: FILE: .mlx_typings/mlx/core/random/__init__.pyi function bernoulli (line 6) | def bernoulli( function categorical (line 30) | def categorical( function gumbel (line 62) | def gumbel( function key (line 86) | def key(seed: int) -> array: function laplace (line 97) | def laplace( function multivariate_normal (line 120) | def multivariate_normal( function normal (line 151) | def normal( function permutation (line 180) | def permutation( function randint (line 201) | def randint( function seed (line 227) | def seed(seed: int) -> None: function split (line 235) | def split(key: array, num: int = ..., stream: Stream | Device | None = .... function truncated_normal (line 247) | def truncated_normal( function uniform (line 275) | def uniform( FILE: .mlx_typings/mlx/nn/init.pyi function constant (line 9) | def constant(value: float, dtype: mx.Dtype = ...) -> Callable[[mx.array]... function normal (line 29) | def normal( function uniform (line 54) | def uniform( function identity (line 79) | def identity(dtype: mx.Dtype = ...) -> Callable[[mx.array], mx.array]: function glorot_normal (line 98) | def glorot_normal(dtype: mx.Dtype = ...) -> Callable[[mx.array, float], ... function glorot_uniform (line 131) | def glorot_uniform(dtype: mx.Dtype = ...) -> Callable[[mx.array, float],... function he_normal (line 164) | def he_normal( function he_uniform (line 203) | def he_uniform( function sparse (line 244) | def sparse( function orthogonal (line 271) | def orthogonal( FILE: .mlx_typings/mlx/nn/layers/activations.pyi function sigmoid (line 12) | def sigmoid(x: mx.array) -> mx.array: function relu (line 20) | def relu(x: mx.array) -> mx.array: function relu2 (line 27) | def relu2(x: mx.array) -> mx.array: function relu6 (line 34) | def relu6(x: mx.array) -> mx.array: function leaky_relu (line 41) | def leaky_relu(x: mx.array, negative_slope=...) -> mx.array: function log_softmax (line 48) | def log_softmax(x: mx.array, axis=...): function elu (line 55) | def elu(x: mx.array, alpha=...) -> mx.array: function softmax (line 62) | def softmax(x: mx.array, axis=...) -> mx.array: function softplus (line 69) | def softplus(x: mx.array) -> mx.array: function softsign (line 76) | def softsign(x: mx.array) -> mx.array: function softshrink (line 83) | def softshrink(x: mx.array, lambd: float = ...) -> mx.array: function celu (line 95) | def celu(x: mx.array, alpha=...) -> mx.array: function silu (line 103) | def silu(x: mx.array) -> mx.array: function log_sigmoid (line 111) | def log_sigmoid(x: mx.array) -> mx.array: function gelu (line 118) | def gelu(x: mx.array) -> mx.array: function gelu_approx (line 131) | def gelu_approx(x: mx.array) -> mx.array: function gelu_fast_approx (line 146) | def gelu_fast_approx(x: mx.array) -> mx.array: function glu (line 165) | def glu(x: mx.array, axis: int = ...) -> mx.array: function step (line 179) | def step(x: mx.array, threshold: float = ...) -> mx.array: function selu (line 196) | def selu(x: mx.array) -> mx.array: function prelu (line 211) | def prelu(x: mx.array, alpha: mx.array) -> mx.array: function mish (line 221) | def mish(x: mx.array) -> mx.array: function hardswish (line 234) | def hardswish(x: mx.array) -> mx.array: function hard_tanh (line 242) | def hard_tanh(x: mx.array, min_val=..., max_val=...) -> mx.array: function hard_shrink (line 249) | def hard_shrink(x: mx.array, lambd=...) -> mx.array: function softmin (line 261) | def softmin(x: mx.array, axis=...) -> mx.array: function tanh (line 267) | def tanh(x: mx.array) -> mx.array: class GLU (line 273) | class GLU(Module): method __init__ (line 285) | def __init__(self, axis: int = ...) -> None: ... method __call__ (line 286) | def __call__(self, x) -> Any: ... class Sigmoid (line 289) | class Sigmoid(Module): class Mish (line 297) | class Mish(Module): class ReLU (line 308) | class ReLU(Module): class ReLU2 (line 316) | class ReLU2(Module): class ReLU6 (line 323) | class ReLU6(Module): class LeakyReLU (line 329) | class LeakyReLU(Module): method __init__ (line 337) | def __init__(self, negative_slope=...) -> None: ... method __call__ (line 338) | def __call__(self, x): ... class ELU (line 340) | class ELU(Module): method __init__ (line 349) | def __init__(self, alpha=...) -> None: ... method __call__ (line 350) | def __call__(self, x): ... class Softmax (line 353) | class Softmax(Module): class Softplus (line 360) | class Softplus(Module): class Softsign (line 367) | class Softsign(Module): class Softshrink (line 373) | class Softshrink(Module): method __init__ (line 381) | def __init__(self, lambd=...) -> None: ... method __call__ (line 382) | def __call__(self, x): ... class CELU (line 384) | class CELU(Module): method __init__ (line 394) | def __init__(self, alpha=...) -> None: ... method __call__ (line 395) | def __call__(self, x): ... class SiLU (line 398) | class SiLU(Module): class LogSoftmax (line 405) | class LogSoftmax(Module): class LogSigmoid (line 412) | class LogSigmoid(Module): class PReLU (line 418) | class PReLU(Module): method __init__ (line 429) | def __init__(self, num_parameters=..., init=...) -> None: ... method __call__ (line 430) | def __call__(self, x: mx.array): ... class GELU (line 432) | class GELU(Module): method __init__ (line 459) | def __init__(self, approx=...) -> None: ... method __call__ (line 460) | def __call__(self, x): ... class Tanh (line 463) | class Tanh(Module): class Hardswish (line 470) | class Hardswish(Module): class Step (line 476) | class Step(Module): method __init__ (line 491) | def __init__(self, threshold: float = ...) -> None: ... method __call__ (line 492) | def __call__(self, x: mx.array): ... class SELU (line 495) | class SELU(Module): class HardTanh (line 502) | class HardTanh(Module): class HardShrink (line 509) | class HardShrink(Module): class Softmin (line 519) | class Softmin(Module): FILE: .mlx_typings/mlx/nn/layers/base.pyi class Module (line 9) | class Module(dict): method __init__ (line 57) | def __init__(self) -> None: method training (line 61) | def training(self): # -> bool: method state (line 65) | def state(self): # -> Self: method __repr__ (line 76) | def __repr__(self): # -> str: method __getattr__ (line 78) | def __getattr__(self, key: str): # -> None: method __setattr__ (line 80) | def __setattr__(self, key: str, val: Any): # -> None: method __delattr__ (line 82) | def __delattr__(self, name): # -> None: method load_weights (line 84) | def load_weights( method save_weights (line 137) | def save_weights(self, file: str): # -> None: method is_module (line 145) | def is_module(value): # -> bool: method valid_child_filter (line 148) | def valid_child_filter(module, key, value): # -> bool: method valid_parameter_filter (line 151) | def valid_parameter_filter(module, key, value): # -> bool: method trainable_parameter_filter (line 154) | def trainable_parameter_filter(module, key, value): # -> bool: method filter_and_map (line 156) | def filter_and_map( method parameters (line 181) | def parameters( method trainable_parameters (line 187) | def trainable_parameters( method children (line 193) | def children( method leaf_modules (line 198) | def leaf_modules( method update (line 203) | def update(self, parameters: dict[str, Any], strict: bool = ...) -> Mo... method apply (line 224) | def apply( method update_modules (line 244) | def update_modules(self, modules: dict, strict: bool = ...) -> Module: method apply_to_modules (line 265) | def apply_to_modules(self, apply_fn: Callable[[str, Module], Any]) -> ... method modules (line 276) | def modules(self): # -> list[Any]: method named_modules (line 283) | def named_modules(self): # -> list[Any]: method freeze (line 291) | def freeze( method unfreeze (line 326) | def unfreeze( method train (line 362) | def train(self, mode: bool = ...) -> Module: method eval (line 376) | def eval(self) -> Module: method set_dtype (line 382) | def set_dtype( FILE: .mlx_typings/mlx/nn/layers/containers.pyi class Sequential (line 10) | class Sequential(Module): method __init__ (line 20) | def __init__(self, *modules: Module | Callable[[mx.array], mx.array]) ... method __call__ (line 21) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/layers/convolution.pyi class Conv1d (line 10) | class Conv1d(Module): method __init__ (line 37) | def __init__( method __call__ (line 48) | def __call__(self, x: mx.array) -> mx.array: ... class Conv2d (line 50) | class Conv2d(Module): method __init__ (line 74) | def __init__( method __call__ (line 85) | def __call__(self, x) -> mx.array: ... class Conv3d (line 87) | class Conv3d(Module): method __init__ (line 110) | def __init__( method __call__ (line 120) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/layers/convolution_transpose.pyi class ConvTranspose1d (line 10) | class ConvTranspose1d(Module): method __init__ (line 33) | def __init__( method __call__ (line 44) | def __call__(self, x: mx.array) -> mx.array: ... class ConvTranspose2d (line 46) | class ConvTranspose2d(Module): method __init__ (line 70) | def __init__( method __call__ (line 81) | def __call__(self, x: mx.array) -> mx.array: ... class ConvTranspose3d (line 83) | class ConvTranspose3d(Module): method __init__ (line 108) | def __init__( method __call__ (line 119) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/layers/distributed.pyi function sum_gradients (line 13) | def sum_gradients( function shard_inplace (line 17) | def shard_inplace( function shard_linear (line 48) | def shard_linear( class AllToShardedLinear (line 72) | class AllToShardedLinear(Module): method __init__ (line 87) | def __init__( method __call__ (line 94) | def __call__(self, x: mx.array) -> mx.array: ... method from_linear (line 96) | def from_linear( class ShardedToAllLinear (line 104) | class ShardedToAllLinear(Module): method __init__ (line 122) | def __init__( method __call__ (line 129) | def __call__(self, x: mx.array) -> mx.array: ... method from_linear (line 131) | def from_linear( class QuantizedAllToShardedLinear (line 139) | class QuantizedAllToShardedLinear(Module): method __init__ (line 160) | def __init__( method unfreeze (line 169) | def unfreeze(self, *args, **kwargs) -> None: method __call__ (line 173) | def __call__(self, x: mx.array) -> mx.array: ... method from_quantized_linear (line 175) | def from_quantized_linear( class QuantizedShardedToAllLinear (line 183) | class QuantizedShardedToAllLinear(Module): method __init__ (line 206) | def __init__( method unfreeze (line 215) | def unfreeze(self, *args, **kwargs): # -> None: method __call__ (line 219) | def __call__(self, x: mx.array) -> mx.array: ... method from_quantized_linear (line 221) | def from_quantized_linear( FILE: .mlx_typings/mlx/nn/layers/dropout.pyi class Dropout (line 8) | class Dropout(Module): method __init__ (line 18) | def __init__(self, p: float = ...) -> None: ... method __call__ (line 19) | def __call__(self, x: mx.array) -> mx.array: ... class Dropout2d (line 21) | class Dropout2d(Module): method __init__ (line 43) | def __init__(self, p: float = ...) -> None: ... method __call__ (line 44) | def __call__(self, x: mx.array) -> mx.array: ... class Dropout3d (line 46) | class Dropout3d(Module): method __init__ (line 64) | def __init__(self, p: float = ...) -> None: ... method __call__ (line 65) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/layers/embedding.pyi class Embedding (line 10) | class Embedding(Module): method __init__ (line 21) | def __init__(self, num_embeddings: int, dims: int) -> None: ... method __call__ (line 22) | def __call__(self, x: mx.array) -> mx.array: ... method as_linear (line 23) | def as_linear(self, x: mx.array) -> mx.array: method to_quantized (line 31) | def to_quantized( FILE: .mlx_typings/mlx/nn/layers/linear.pyi class Identity (line 12) | class Identity(Module): method __init__ (line 19) | def __init__(self, *args: Any, **kwargs: Any) -> None: ... method __call__ (line 20) | def __call__(self, x: mx.array) -> mx.array: ... class Linear (line 22) | class Linear(Module): method __init__ (line 47) | def __init__(self, input_dims: int, output_dims: int, bias: bool = ...... method __call__ (line 48) | def __call__(self, x: mx.array) -> mx.array: ... method to_quantized (line 49) | def to_quantized( class Bilinear (line 54) | class Bilinear(Module): method __init__ (line 77) | def __init__( method __call__ (line 80) | def __call__(self, x1: mx.array, x2: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/layers/normalization.pyi class InstanceNorm (line 8) | class InstanceNorm(Module): method __init__ (line 40) | def __init__(self, dims: int, eps: float = ..., affine: bool = ...) ->... method __call__ (line 41) | def __call__(self, x: mx.array) -> mx.array: ... class LayerNorm (line 43) | class LayerNorm(Module): method __init__ (line 66) | def __init__( method __call__ (line 69) | def __call__(self, x) -> mx.array: ... class RMSNorm (line 71) | class RMSNorm(Module): method __init__ (line 94) | def __init__(self, dims: int, eps: float = ...) -> None: ... method __call__ (line 95) | def __call__(self, x) -> mx.array: ... class GroupNorm (line 97) | class GroupNorm(Module): method __init__ (line 126) | def __init__( method __call__ (line 134) | def __call__(self, x) -> mx.array: ... class BatchNorm (line 136) | class BatchNorm(Module): method __init__ (line 176) | def __init__( method unfreeze (line 184) | def unfreeze(self, *args, **kwargs): # -> None: method __call__ (line 188) | def __call__(self, x: mx.array) -> mx.array: FILE: .mlx_typings/mlx/nn/layers/pooling.pyi class _Pool (line 10) | class _Pool(Module): method __init__ (line 11) | def __init__( method __call__ (line 14) | def __call__(self, x: mx.array) -> mx.array: ... class _Pool1d (line 16) | class _Pool1d(_Pool): method __init__ (line 17) | def __init__( class _Pool2d (line 26) | class _Pool2d(_Pool): method __init__ (line 27) | def __init__( class _Pool3d (line 36) | class _Pool3d(_Pool): method __init__ (line 37) | def __init__( class MaxPool1d (line 46) | class MaxPool1d(_Pool1d): method __init__ (line 67) | def __init__( class AvgPool1d (line 74) | class AvgPool1d(_Pool1d): method __init__ (line 95) | def __init__( class MaxPool2d (line 102) | class MaxPool2d(_Pool2d): method __init__ (line 130) | def __init__( class AvgPool2d (line 137) | class AvgPool2d(_Pool2d): method __init__ (line 165) | def __init__( class MaxPool3d (line 172) | class MaxPool3d(_Pool3d): method __init__ (line 201) | def __init__( class AvgPool3d (line 208) | class AvgPool3d(_Pool3d): method __init__ (line 237) | def __init__( FILE: .mlx_typings/mlx/nn/layers/positional_encoding.pyi class RoPE (line 10) | class RoPE(Module): method __init__ (line 29) | def __init__( method __call__ (line 32) | def __call__(self, x, offset: int = ...) -> mx.array: ... class SinusoidalPositionalEncoding (line 34) | class SinusoidalPositionalEncoding(Module): method __init__ (line 53) | def __init__( method __call__ (line 62) | def __call__(self, x: mx.array) -> mx.array: ... class ALiBi (line 64) | class ALiBi(Module): method create_alibi_matrix (line 68) | def create_alibi_matrix( method create_alibi_slope (line 77) | def create_alibi_slope(num_heads: int) -> mx.array: ... method __call__ (line 78) | def __call__( FILE: .mlx_typings/mlx/nn/layers/quantized.pyi function quantize (line 10) | def quantize( class QuantizedEmbedding (line 40) | class QuantizedEmbedding(Module): method __init__ (line 58) | def __init__( method __call__ (line 66) | def __call__(self, x: mx.array) -> mx.array: ... method as_linear (line 67) | def as_linear(self, x: mx.array) -> mx.array: method from_embedding (line 76) | def from_embedding( class QuantizedLinear (line 85) | class QuantizedLinear(Module): method __init__ (line 107) | def __init__( method __call__ (line 116) | def __call__(self, x: mx.array) -> mx.array: ... method from_linear (line 118) | def from_linear( FILE: .mlx_typings/mlx/nn/layers/recurrent.pyi class RNN (line 10) | class RNN(Module): method __init__ (line 37) | def __init__( method __call__ (line 44) | def __call__(self, x: mx.array, hidden=...) -> mx.array: ... class GRU (line 46) | class GRU(Module): method __init__ (line 75) | def __init__(self, input_size: int, hidden_size: int, bias: bool = ...... method __call__ (line 76) | def __call__(self, x: mx.array, hidden=...) -> mx.array: ... class LSTM (line 78) | class LSTM(Module): method __init__ (line 110) | def __init__(self, input_size: int, hidden_size: int, bias: bool = ...... method __call__ (line 111) | def __call__( FILE: .mlx_typings/mlx/nn/layers/transformer.pyi class MultiHeadAttention (line 10) | class MultiHeadAttention(Module): method __init__ (line 42) | def __init__( method __call__ (line 53) | def __call__( method create_additive_causal_mask (line 57) | def create_additive_causal_mask(N: int, dtype: mx.Dtype = ...) -> mx.a... class TransformerEncoderLayer (line 59) | class TransformerEncoderLayer(Module): method __init__ (line 60) | def __init__( method __call__ (line 69) | def __call__(self, x: mx.array, mask: mx.array) -> mx.array: ... class TransformerEncoder (line 71) | class TransformerEncoder(Module): method __init__ (line 72) | def __init__( method __call__ (line 83) | def __call__(self, x: mx.array, mask: mx.array) -> mx.array: ... class TransformerDecoderLayer (line 85) | class TransformerDecoderLayer(Module): method __init__ (line 86) | def __init__( method __call__ (line 95) | def __call__(self, x: mx.array, memory, x_mask, memory_mask) -> mx.arr... class TransformerDecoder (line 97) | class TransformerDecoder(Module): method __init__ (line 98) | def __init__( method __call__ (line 109) | def __call__(self, x: mx.array, memory, x_mask, memory_mask) -> mx.arr... class Transformer (line 111) | class Transformer(Module): method __init__ (line 151) | def __init__( method __call__ (line 165) | def __call__( FILE: .mlx_typings/mlx/nn/layers/upsample.pyi function upsample_nearest (line 10) | def upsample_nearest(x: mx.array, scale_factor: Tuple) -> mx.array: ... function upsample_linear (line 11) | def upsample_linear( function upsample_cubic (line 15) | def upsample_cubic( class Upsample (line 20) | class Upsample(Module): method __init__ (line 81) | def __init__( method __call__ (line 87) | def __call__(self, x: mx.array) -> mx.array: ... FILE: .mlx_typings/mlx/nn/losses.pyi function cross_entropy (line 11) | def cross_entropy( function binary_cross_entropy (line 56) | def binary_cross_entropy( function l1_loss (line 99) | def l1_loss( function mse_loss (line 115) | def mse_loss( function nll_loss (line 131) | def nll_loss( function gaussian_nll_loss (line 148) | def gaussian_nll_loss( function kl_div_loss (line 184) | def kl_div_loss( function smooth_l1_loss (line 207) | def smooth_l1_loss( function triplet_loss (line 241) | def triplet_loss( function hinge_loss (line 275) | def hinge_loss( function huber_loss (line 296) | def huber_loss( function log_cosh_loss (line 322) | def log_cosh_loss( function cosine_similarity_loss (line 349) | def cosine_similarity_loss( function margin_ranking_loss (line 378) | def margin_ranking_loss( FILE: .mlx_typings/mlx/nn/utils.pyi function value_and_grad (line 11) | def value_and_grad( function checkpoint (line 28) | def checkpoint( function average_gradients (line 46) | def average_gradients( FILE: .mlx_typings/mlx/utils.pyi function tree_map (line 9) | def tree_map( function tree_map_with_path (line 49) | def tree_map_with_path( function tree_flatten (line 83) | def tree_flatten( function tree_unflatten (line 124) | def tree_unflatten(tree: list[tuple[str, Any]] | dict[str, Any]) -> Any: function tree_reduce (line 147) | def tree_reduce( function tree_merge (line 178) | def tree_merge( FILE: .mlx_typings/mlx_lm/convert.pyi function mixed_quant_predicate_builder (line 10) | def mixed_quant_predicate_builder( function convert (line 17) | def convert( function configure_parser (line 34) | def configure_parser() -> argparse.ArgumentParser: function main (line 42) | def main(): # -> None: FILE: .mlx_typings/mlx_lm/generate.pyi function str2bool (line 28) | def str2bool(string): # -> bool: function setup_arg_parser (line 30) | def setup_arg_parser(): # -> ArgumentParser: function wired_limit (line 36) | def wired_limit( class GenerationResponse (line 47) | class GenerationResponse: function maybe_quantize_kv_cache (line 75) | def maybe_quantize_kv_cache( function generate_step (line 81) | def generate_step( function speculative_generate_step (line 129) | def speculative_generate_step( function stream_generate (line 174) | def stream_generate( function generate (line 203) | def generate( class BatchStats (line 223) | class BatchStats: class BatchResponse (line 246) | class BatchResponse: function _left_pad_prompts (line 259) | def _left_pad_prompts(prompts: Any, max_length: Optional[int] = ...) -> ... function _right_pad_prompts (line 260) | def _right_pad_prompts(prompts: Any, max_length: Optional[int] = ...) ->... function _make_cache (line 261) | def _make_cache( function _merge_caches (line 264) | def _merge_caches(caches: Any) -> List[Any]: ... class Batch (line 266) | class Batch: method __len__ (line 276) | def __len__(self) -> int: ... method filter (line 277) | def filter(self, keep_idx: List[int]) -> None: ... method extend (line 278) | def extend(self, other: "Batch") -> None: ... method extract_cache (line 279) | def extract_cache(self, idx: int) -> List[Any]: ... class BatchGenerator (line 281) | class BatchGenerator: class Response (line 291) | class Response: method __init__ (line 298) | def __init__( method close (line 315) | def close(self) -> None: ... method insert (line 316) | def insert( method remove (line 324) | def remove( method stats (line 327) | def stats(self) -> BatchStats: ... method next (line 328) | def next(self) -> List[Response]: ... method _process_prompts (line 329) | def _process_prompts(self, prompts: List[Any]) -> Batch: ... method _step (line 330) | def _step( function batch_generate (line 339) | def batch_generate( function main (line 362) | def main(): # -> None: FILE: .mlx_typings/mlx_lm/models/base.pyi class BaseModelArgs (line 11) | class BaseModelArgs: method from_dict (line 13) | def from_dict(cls, params): # -> Self: function create_causal_mask (line 16) | def create_causal_mask( function create_attention_mask (line 24) | def create_attention_mask( function create_ssm_mask (line 28) | def create_ssm_mask(h, cache=...): # -> None: function quantized_scaled_dot_product_attention (line 30) | def quantized_scaled_dot_product_attention( function scaled_dot_product_attention (line 39) | def scaled_dot_product_attention( FILE: .mlx_typings/mlx_lm/models/bitlinear_layers.pyi function bitnet_quantize (line 7) | def bitnet_quantize(model, quantization_config: dict): ... function make_bitlinear_kernel (line 8) | def make_bitlinear_kernel(): class BitLinear (line 17) | class BitLinear(nn.Module): method __init__ (line 21) | def __init__( method execute_matmul_kernel (line 24) | def execute_matmul_kernel(self, x, packed_weights): ... method __call__ (line 25) | def __call__(self, x): # -> array: FILE: .mlx_typings/mlx_lm/models/cache.pyi class Cache (line 11) | class Cache(Protocol): method update_and_fetch (line 15) | def update_and_fetch( method state (line 19) | def state(self) -> tuple[mx.array | None, mx.array | None]: ... method state (line 21) | def state(self, v) -> None: ... function make_prompt_cache (line 23) | def make_prompt_cache( function save_prompt_cache (line 39) | def save_prompt_cache( function load_prompt_cache (line 52) | def load_prompt_cache(file_name: str, return_metadata=...) -> array: function can_trim_prompt_cache (line 66) | def can_trim_prompt_cache(cache: List[Cache]) -> bool: function trim_prompt_cache (line 71) | def trim_prompt_cache(cache: List[Cache], num_tokens: int) -> List[Cache]: function create_attention_mask (line 86) | def create_attention_mask( class _BaseCache (line 90) | class _BaseCache(Cache): method state (line 95) | def state(self) -> tuple[mx.array | None, mx.array | None]: ... method state (line 97) | def state(self, v) -> None: ... method meta_state (line 99) | def meta_state(self) -> Literal[""]: ... method meta_state (line 101) | def meta_state(self, v) -> None: ... method trim (line 102) | def trim(self, n: int) -> int: ... method is_trimmable (line 103) | def is_trimmable(self) -> Literal[False]: ... method from_state (line 105) | def from_state(cls, state, meta_state) -> Self: ... class ConcatenateKVCache (line 107) | class ConcatenateKVCache(_BaseCache): method __init__ (line 114) | def __init__(self) -> None: ... method update_and_fetch (line 115) | def update_and_fetch(self, keys, values): # -> tuple[Any | array, Any... method state (line 118) | def state(self) -> tuple[mx.array | None, mx.array | None]: ... method state (line 120) | def state(self, v): # -> None: method is_trimmable (line 122) | def is_trimmable(self): # -> Literal[True]: method trim (line 124) | def trim(self, n: int) -> int: ... method make_mask (line 125) | def make_mask(self, *args, **kwargs): # -> array | Literal['causal'] ... class QuantizedKVCache (line 128) | class QuantizedKVCache(_BaseCache): method __init__ (line 130) | def __init__(self, group_size: int = ..., bits: int = ...) -> None: ... method update_and_fetch (line 131) | def update_and_fetch(self, keys, values): # -> Any: method state (line 134) | def state(self) -> tuple[mx.array | None, mx.array | None]: ... method state (line 136) | def state(self, v): # -> None: method meta_state (line 139) | def meta_state(self): # -> tuple[str, ...]: method meta_state (line 142) | def meta_state(self, v): # -> None: method is_trimmable (line 144) | def is_trimmable(self): # -> Literal[True]: method trim (line 146) | def trim(self, n: int) -> int: ... method make_mask (line 147) | def make_mask(self, *args, **kwargs): # -> array | Literal['causal'] ... class KVCache (line 150) | class KVCache(_BaseCache): method __init__ (line 152) | def __init__(self) -> None: ... method update_and_fetch (line 153) | def update_and_fetch(self, keys, values): # -> tuple[array | Any, arr... method state (line 156) | def state( method state (line 160) | def state(self, v) -> None: ... method is_trimmable (line 161) | def is_trimmable(self): # -> Literal[True]: method trim (line 163) | def trim(self, n: int) -> int: ... method to_quantized (line 164) | def to_quantized( method make_mask (line 167) | def make_mask( class RotatingKVCache (line 171) | class RotatingKVCache(_BaseCache): method __init__ (line 178) | def __init__(self, max_size, keep=...) -> None: ... method _trim (line 179) | def _trim( method update_and_fetch (line 182) | def update_and_fetch( method state (line 187) | def state( method state (line 191) | def state(self, v): # -> None: method meta_state (line 194) | def meta_state(self): # -> tuple[str, ...]: method meta_state (line 197) | def meta_state(self, v): # -> None: method is_trimmable (line 199) | def is_trimmable(self): # -> bool: method trim (line 201) | def trim(self, n: int) -> int: ... method to_quantized (line 202) | def to_quantized( method make_mask (line 205) | def make_mask( class ArraysCache (line 210) | class ArraysCache(_BaseCache): method __init__ (line 211) | def __init__(self, size, left_padding: Optional[List[int]] = ...) -> N... method __setitem__ (line 212) | def __setitem__(self, idx, value): # -> None: method __getitem__ (line 214) | def __getitem__(self, idx): ... method state (line 216) | def state(self) -> tuple[mx.array | None, mx.array | None]: ... method state (line 218) | def state(self, v): # -> None: method filter (line 220) | def filter(self, batch_indices): # -> None: method extend (line 225) | def extend(self, other): # -> None: method make_mask (line 230) | def make_mask(self, N: int) -> mx.array | None: ... class MambaCache (line 232) | class MambaCache(ArraysCache): method __init__ (line 233) | def __init__(self, left_padding: Optional[List[int]] = ...) -> None: ... class ChunkedKVCache (line 235) | class ChunkedKVCache(KVCache): method __init__ (line 236) | def __init__(self, chunk_size) -> None: ... method maybe_trim_front (line 237) | def maybe_trim_front(self): # -> None: method update_and_fetch (line 239) | def update_and_fetch(self, keys, values): # -> tuple[array, array]: method trim (line 241) | def trim(self, n: int) -> int: ... method meta_state (line 243) | def meta_state(self): # -> tuple[str, ...]: method meta_state (line 246) | def meta_state(self, v): # -> None: class CacheList (line 249) | class CacheList(_BaseCache): method __init__ (line 250) | def __init__(self, *caches) -> None: ... method __getitem__ (line 251) | def __getitem__(self, idx): ... method is_trimmable (line 252) | def is_trimmable(self): # -> bool: method trim (line 254) | def trim(self, n: int) -> int: ... method state (line 256) | def state(self) -> list[tuple[mx.array | None, mx.array | None]]: ... method state (line 258) | def state(self, v): # -> None: method filter (line 260) | def filter(self, batch_indices): # -> None: method extend (line 265) | def extend(self, other): # -> None: class BatchKVCache (line 270) | class BatchKVCache(_BaseCache): method __init__ (line 272) | def __init__(self, left_padding: List[int]) -> None: method update_and_fetch (line 292) | def update_and_fetch(self, keys, values): # -> tuple[array | Any, arr... method state (line 295) | def state( method state (line 300) | def state(self, v): # -> None: method is_trimmable (line 302) | def is_trimmable(self): # -> Literal[True]: method trim (line 304) | def trim(self, n): # -> int | float: method make_mask (line 306) | def make_mask(self, N: int, return_array: bool = ..., **kwargs): # ->... method filter (line 308) | def filter(self, batch_indices): # -> None: method extend (line 313) | def extend(self, other): # -> None: class BatchRotatingKVCache (line 318) | class BatchRotatingKVCache(_BaseCache): method __init__ (line 320) | def __init__(self, max_size, left_padding: List[int]) -> None: ... method update_and_fetch (line 321) | def update_and_fetch( method state (line 326) | def state( method state (line 331) | def state(self, v): # -> None: method meta_state (line 334) | def meta_state(self): # -> tuple[str, ...]: method meta_state (line 337) | def meta_state(self, v): # -> None: method is_trimmable (line 339) | def is_trimmable(self): # -> bool: method trim (line 341) | def trim(self, n): # -> int: method to_quantized (line 343) | def to_quantized( method make_mask (line 346) | def make_mask( method filter (line 350) | def filter(self, batch_indices): # -> None: method extend (line 355) | def extend(self, other): # -> None: FILE: .mlx_typings/mlx_lm/models/deepseek_v3.pyi class ModelArgs (line 14) | class ModelArgs(BaseModelArgs): class DeepseekV3Attention (line 45) | class DeepseekV3Attention(nn.Module): method __init__ (line 71) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 72) | def __call__( class DeepseekV3MLP (line 79) | class DeepseekV3MLP(nn.Module): method __init__ (line 87) | def __init__( method __call__ (line 93) | def __call__(self, x: mx.array) -> mx.array: ... class MoEGate (line 95) | class MoEGate(nn.Module): method __init__ (line 106) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 107) | def __call__(self, x: mx.array) -> tuple[mx.array, mx.array]: ... class DeepseekV3MoE (line 109) | class DeepseekV3MoE(nn.Module): method __init__ (line 117) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 118) | def __call__(self, x: mx.array) -> mx.array: ... class DeepseekV3DecoderLayer (line 120) | class DeepseekV3DecoderLayer(nn.Module): method __init__ (line 126) | def __init__(self, config: ModelArgs, layer_idx: int) -> None: ... method __call__ (line 127) | def __call__( class DeepseekV3Model (line 134) | class DeepseekV3Model(nn.Module): method __init__ (line 140) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 141) | def __call__( class Model (line 147) | class Model(nn.Module): method __init__ (line 152) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 153) | def __call__( method sanitize (line 158) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... method layers (line 160) | def layers(self) -> list[DeepseekV3DecoderLayer]: ... FILE: .mlx_typings/mlx_lm/models/glm4_moe.pyi class ModelArgs (line 11) | class ModelArgs(BaseModelArgs): class Attention (line 40) | class Attention(nn.Module): method __init__ (line 53) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 54) | def __call__( class MLP (line 61) | class MLP(nn.Module): method __init__ (line 69) | def __init__( method __call__ (line 75) | def __call__(self, x: mx.array) -> mx.array: ... class MoEGate (line 77) | class MoEGate(nn.Module): method __init__ (line 88) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 89) | def __call__(self, x: mx.array) -> tuple[mx.array, mx.array]: ... class MoE (line 91) | class MoE(nn.Module): method __init__ (line 99) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 100) | def __call__(self, x: mx.array) -> mx.array: ... class DecoderLayer (line 102) | class DecoderLayer(nn.Module): method __init__ (line 108) | def __init__(self, config: ModelArgs, layer_idx: int) -> None: ... method __call__ (line 109) | def __call__( class LanguageModel (line 116) | class LanguageModel(nn.Module): method __init__ (line 127) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 128) | def __call__( method pipeline_layers (line 134) | def pipeline_layers(self) -> list[DecoderLayer]: ... class Model (line 136) | class Model(nn.Module): method __init__ (line 142) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 143) | def __call__( method sanitize (line 148) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... method shard (line 149) | def shard(self, group: Optional[mx.distributed.Group] = None) -> None:... method layers (line 151) | def layers(self) -> list[DecoderLayer]: ... method cast_predicate (line 153) | def cast_predicate(self) -> Any: ... FILE: .mlx_typings/mlx_lm/models/glm_moe_dsa.pyi class ModelArgs (line 10) | class ModelArgs(BaseModelArgs): class Model (line 45) | class Model(DSV32Model): method __init__ (line 46) | def __init__(self, config: ModelArgs) -> None: ... FILE: .mlx_typings/mlx_lm/models/nemotron_h.pyi class ModelArgs (line 11) | class ModelArgs: method from_dict (line 47) | def from_dict(cls, params: dict[str, Any]) -> ModelArgs: ... method __post_init__ (line 48) | def __post_init__(self) -> None: ... class NemotronHMamba2Mixer (line 50) | class NemotronHMamba2Mixer(nn.Module): method __init__ (line 68) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 69) | def __call__( class NemotronHAttention (line 76) | class NemotronHAttention(nn.Module): method __init__ (line 87) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 88) | def __call__( class NemotronHMLP (line 95) | class NemotronHMLP(nn.Module): method __init__ (line 99) | def __init__( method __call__ (line 102) | def __call__(self, x: mx.array) -> mx.array: ... class NemotronHMoE (line 104) | class NemotronHMoE(nn.Module): method __init__ (line 109) | def __init__(self, config: ModelArgs) -> None: ... method __call__ (line 110) | def __call__(self, x: mx.array) -> mx.array: ... class NemotronHBlock (line 112) | class NemotronHBlock(nn.Module): method __init__ (line 117) | def __init__(self, args: ModelArgs, block_type: str) -> None: ... method __call__ (line 118) | def __call__( class NemotronHModel (line 125) | class NemotronHModel(nn.Module): method __init__ (line 132) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 133) | def __call__( class Model (line 139) | class Model(nn.Module): method __init__ (line 145) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 146) | def __call__( method layers (line 152) | def layers(self) -> list[NemotronHBlock]: ... method make_cache (line 153) | def make_cache(self) -> list[ArraysCache | KVCache]: ... method sanitize (line 154) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... FILE: .mlx_typings/mlx_lm/models/qwen3_5.pyi class TextModelArgs (line 19) | class TextModelArgs: method from_dict (line 50) | def from_dict(cls, params: dict[str, Any]) -> TextModelArgs: ... method __post_init__ (line 51) | def __post_init__(self) -> None: ... class GatedDeltaNet (line 53) | class GatedDeltaNet(nn.Module): method __init__ (line 73) | def __init__(self, config: TextModelArgs) -> None: ... method __call__ (line 74) | def __call__( class DecoderLayer (line 81) | class DecoderLayer(nn.Module): method __init__ (line 89) | def __init__(self, args: TextModelArgs, layer_idx: int) -> None: ... method __call__ (line 90) | def __call__( class Qwen3_5TextModel (line 97) | class Qwen3_5TextModel(nn.Module): method __init__ (line 104) | def __init__(self, args: TextModelArgs) -> None: ... method __call__ (line 105) | def __call__( class TextModel (line 112) | class TextModel(nn.Module): method __init__ (line 118) | def __init__(self, args: TextModelArgs) -> None: ... method __call__ (line 119) | def __call__( method layers (line 126) | def layers(self) -> list[DecoderLayer]: ... method make_cache (line 127) | def make_cache(self) -> list[ArraysCache | KVCache]: ... method sanitize (line 128) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... class ModelArgs (line 131) | class ModelArgs: method from_dict (line 136) | def from_dict(cls, params: dict[str, Any]) -> ModelArgs: ... class Model (line 138) | class Model(nn.Module): method __init__ (line 143) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 144) | def __call__( method sanitize (line 150) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... method layers (line 152) | def layers(self) -> list[DecoderLayer]: ... method make_cache (line 153) | def make_cache(self) -> list[ArraysCache | KVCache]: ... FILE: .mlx_typings/mlx_lm/models/qwen3_5_moe.pyi class ModelArgs (line 11) | class ModelArgs: method from_dict (line 16) | def from_dict(cls, params: dict[str, Any]) -> ModelArgs: ... class Model (line 18) | class Model(Qwen3_5Model): method sanitize (line 19) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... FILE: .mlx_typings/mlx_lm/models/qwen3_next.pyi class Qwen3NextRMSNormGated (line 11) | class Qwen3NextRMSNormGated(nn.Module): method __init__ (line 15) | def __init__(self, hidden_size: int, eps: float = ...) -> None: ... method __call__ (line 16) | def __call__( class Qwen3NextMLP (line 20) | class Qwen3NextMLP(nn.Module): method __init__ (line 25) | def __init__(self, dim: int, hidden_dim: int) -> None: ... method __call__ (line 26) | def __call__(self, x: mx.array) -> mx.array: ... class Qwen3NextGatedDeltaNet (line 28) | class Qwen3NextGatedDeltaNet(nn.Module): method __init__ (line 45) | def __init__(self, config: Any) -> None: ... method __call__ (line 46) | def __call__( class Qwen3NextAttention (line 53) | class Qwen3NextAttention(nn.Module): method __init__ (line 63) | def __init__(self, args: Any) -> None: ... method __call__ (line 64) | def __call__( class Qwen3NextSparseMoeBlock (line 71) | class Qwen3NextSparseMoeBlock(nn.Module): method __init__ (line 80) | def __init__(self, args: Any) -> None: ... method __call__ (line 81) | def __call__(self, x: mx.array) -> mx.array: ... class Qwen3NextDecoderLayer (line 83) | class Qwen3NextDecoderLayer(nn.Module): method __init__ (line 91) | def __init__(self, args: Any, layer_idx: int) -> None: ... method __call__ (line 92) | def __call__( class Qwen3NextModel (line 99) | class Qwen3NextModel(nn.Module): method __init__ (line 106) | def __init__(self, args: Any) -> None: ... method __call__ (line 107) | def __call__( class Model (line 113) | class Model(nn.Module): method __init__ (line 118) | def __init__(self, args: Any) -> None: ... method __call__ (line 119) | def __call__( method sanitize (line 124) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... method layers (line 126) | def layers(self) -> list[Qwen3NextDecoderLayer]: ... method make_cache (line 127) | def make_cache(self) -> list[ArraysCache | KVCache]: ... FILE: .mlx_typings/mlx_lm/models/step3p5.pyi class ModelArgs (line 11) | class ModelArgs(BaseModelArgs): class Step3p5MLP (line 41) | class Step3p5MLP(nn.Module): method __init__ (line 49) | def __init__( method __call__ (line 52) | def __call__(self, x: mx.array) -> mx.array: ... class Step3p5MoEGate (line 54) | class Step3p5MoEGate(nn.Module): method __init__ (line 62) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 63) | def __call__(self, x: mx.array) -> tuple[mx.array, mx.array]: ... class Step3p5MoE (line 65) | class Step3p5MoE(nn.Module): method __init__ (line 71) | def __init__(self, args: ModelArgs, layer_idx: int) -> None: ... method __call__ (line 72) | def __call__(self, x: mx.array) -> mx.array: ... class Step3p5Attention (line 74) | class Step3p5Attention(nn.Module): method __init__ (line 90) | def __init__(self, args: ModelArgs, layer_idx: int) -> None: ... method __call__ (line 91) | def __call__( class Step3p5DecoderLayer (line 98) | class Step3p5DecoderLayer(nn.Module): method __init__ (line 106) | def __init__(self, args: ModelArgs, layer_idx: int) -> None: ... method __call__ (line 107) | def __call__( class Step3p5Model (line 114) | class Step3p5Model(nn.Module): method __init__ (line 124) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 125) | def __call__( class Model (line 131) | class Model(nn.Module): method __init__ (line 137) | def __init__(self, args: ModelArgs) -> None: ... method __call__ (line 138) | def __call__( method sanitize (line 143) | def sanitize(self, weights: dict[str, Any]) -> dict[str, Any]: ... method shard (line 144) | def shard(self, group: Optional[mx.distributed.Group] = None) -> None:... method layers (line 146) | def layers(self) -> list[Step3p5DecoderLayer]: ... method make_cache (line 147) | def make_cache(self) -> list[Any]: ... method cast_predicate (line 149) | def cast_predicate(self) -> Any: ... method quant_predicate (line 151) | def quant_predicate(self) -> Any: ... FILE: .mlx_typings/mlx_lm/models/switch_layers.pyi class QuantizedSwitchLinear (line 10) | class QuantizedSwitchLinear(nn.Module): method __init__ (line 11) | def __init__( method input_dims (line 22) | def input_dims(self): # -> int: method output_dims (line 25) | def output_dims(self): # -> int: method num_experts (line 28) | def num_experts(self): # -> int: method __call__ (line 30) | def __call__(self, x, indices, sorted_indices=...): # -> array: class SwitchLinear (line 33) | class SwitchLinear(nn.Module): method __init__ (line 34) | def __init__( method input_dims (line 38) | def input_dims(self): # -> int: method output_dims (line 41) | def output_dims(self): # -> int: method num_experts (line 44) | def num_experts(self): # -> int: method __call__ (line 46) | def __call__(self, x, indices, sorted_indices=...): ... method to_quantized (line 47) | def to_quantized( function swiglu (line 53) | def swiglu(x, gate): ... class SwiGLU (line 55) | class SwiGLU(nn.Module): method __init__ (line 56) | def __init__(self) -> None: ... method __call__ (line 57) | def __call__(self, x, gate): ... class SwitchGLU (line 59) | class SwitchGLU(nn.Module): method __init__ (line 65) | def __init__( method __call__ (line 73) | def __call__(self, x, indices) -> mx.array: ... class SwitchMLP (line 75) | class SwitchMLP(nn.Module): method __init__ (line 79) | def __init__( method __call__ (line 87) | def __call__(self, x, indices) -> mx.array: ... FILE: .mlx_typings/mlx_lm/sample_utils.pyi function make_sampler (line 10) | def make_sampler( function make_logits_processors (line 47) | def make_logits_processors( function apply_top_k (line 70) | def apply_top_k(logprobs: mx.array, top_k: int) -> mx.array: function apply_min_p (line 80) | def apply_min_p( function apply_top_p (line 101) | def apply_top_p(logprobs: mx.array, top_p: float) -> mx.array: function apply_xtc (line 113) | def apply_xtc( function categorical_sampling (line 130) | def categorical_sampling(logits, temp): # -> array: function make_repetition_penalty (line 132) | def make_repetition_penalty( FILE: .mlx_typings/mlx_lm/tokenizer_utils.pyi class StreamingDetokenizer (line 11) | class StreamingDetokenizer: method reset (line 42) | def reset(self) -> None: ... method add_token (line 43) | def add_token(self, token: int) -> None: ... method finalize (line 44) | def finalize(self) -> None: ... method last_segment (line 46) | def last_segment(self) -> str: class NaiveStreamingDetokenizer (line 49) | class NaiveStreamingDetokenizer(StreamingDetokenizer): method __init__ (line 56) | def __init__(self, tokenizer) -> None: ... method reset (line 57) | def reset(self): # -> None: method add_token (line 59) | def add_token(self, token): # -> None: method finalize (line 61) | def finalize(self): # -> None: method text (line 64) | def text(self): # -> str: class SPMStreamingDetokenizer (line 67) | class SPMStreamingDetokenizer(StreamingDetokenizer): method __init__ (line 73) | def __init__(self, tokenizer, trim_space=...) -> None: ... method reset (line 74) | def reset(self): # -> None: method add_token (line 76) | def add_token(self, token): # -> None: method finalize (line 78) | def finalize(self): # -> None: class BPEStreamingDetokenizer (line 81) | class BPEStreamingDetokenizer(StreamingDetokenizer): method __init__ (line 90) | def __init__(self, tokenizer) -> None: ... method reset (line 91) | def reset(self): # -> None: method add_token (line 93) | def add_token(self, token): # -> None: method finalize (line 95) | def finalize(self): # -> None: method make_byte_decoder (line 98) | def make_byte_decoder(cls): # -> None: class TokenizerWrapper (line 101) | class TokenizerWrapper: method __init__ (line 121) | def __init__( method encode (line 131) | def encode(self, text: str, **kwargs: Any) -> list[int]: ... method decode (line 132) | def decode(self, token_ids: list[int], **kwargs: Any) -> str: ... method apply_chat_template (line 133) | def apply_chat_template( method get_vocab (line 141) | def get_vocab(self) -> dict[str, int]: ... method add_eos_token (line 142) | def add_eos_token(self, token: str) -> None: ... method has_thinking (line 144) | def has_thinking(self) -> bool: ... method think_start (line 146) | def think_start(self) -> str | None: ... method think_end (line 148) | def think_end(self) -> str | None: ... method has_tool_calling (line 150) | def has_tool_calling(self) -> bool: ... method tool_call_start (line 152) | def tool_call_start(self) -> str | None: ... method tool_call_end (line 154) | def tool_call_end(self) -> str | None: ... method detokenizer (line 156) | def detokenizer(self) -> NaiveStreamingDetokenizer: method __getattr__ (line 159) | def __getattr__(self, attr: str) -> Any: ... method __setattr__ (line 160) | def __setattr__(self, attr: str, value: Any) -> None: ... class NewlineTokenizer (line 162) | class NewlineTokenizer(PreTrainedTokenizerFast): method __init__ (line 164) | def __init__(self, *args, **kwargs) -> None: ... method encode (line 165) | def encode(self, text, **kwargs): # -> list[int]: method encode_batch (line 167) | def encode_batch(self, texts, **kwargs): ... method decode (line 168) | def decode(self, *args, **kwargs): # -> str: method batch_decode (line 170) | def batch_decode(self, *args, **kwargs): # -> list[str]: function load (line 173) | def load( function no_bos_or_eos (line 188) | def no_bos_or_eos(sequence: list[int], bos: int, eos: int) -> list[int]:... FILE: .mlx_typings/mlx_lm/utils.pyi function compute_bits_per_weight (line 19) | def compute_bits_per_weight(model): ... function hf_repo_to_path (line 20) | def hf_repo_to_path(hf_repo): # -> Path: function load_config (line 22) | def load_config(model_path: Path) -> dict: ... function load_model (line 23) | def load_model( function load (line 56) | def load( function make_shards (line 93) | def make_shards(weights: dict, max_file_size_gb: int = ...) -> list: function create_model_card (line 105) | def create_model_card( function upload_to_hub (line 116) | def upload_to_hub(path: str, upload_repo: str): # -> None: function save_model (line 125) | def save_model( function quantize_model (line 130) | def quantize_model( function save_config (line 156) | def save_config(config: dict, config_path: Union[str, Path]) -> None: function save (line 166) | def save( function common_prefix_len (line 175) | def common_prefix_len(list1, list2): # -> int: function does_model_support_input_embeddings (line 188) | def does_model_support_input_embeddings(model: nn.Module) -> bool: FILE: bench/eval_tool_calls.py class Scenario (line 33) | class Scenario: function load_scenarios (line 46) | def load_scenarios(path: Path) -> list[Scenario]: class ParsedResponse (line 123) | class ParsedResponse: class ScenarioResult (line 131) | class ScenarioResult: function validate_args (line 141) | def validate_args(args_str: str, required_keys: list[str]) -> tuple[bool... function validate_nested_args (line 155) | def validate_nested_args( function call_api (line 184) | def call_api( function _openai_build_request (line 201) | def _openai_build_request( function _openai_parse_response (line 217) | def _openai_parse_response(data: dict[str, Any]) -> ParsedResponse: function _openai_build_followup (line 244) | def _openai_build_followup( function _claude_translate_tools (line 284) | def _claude_translate_tools(tools: list[dict[str, Any]]) -> list[dict[st... function _claude_translate_messages (line 299) | def _claude_translate_messages(messages: list[dict[str, Any]]) -> list[d... function _claude_build_request (line 362) | def _claude_build_request( function _claude_parse_response (line 390) | def _claude_parse_response(data: dict[str, Any]) -> ParsedResponse: function _claude_build_followup (line 434) | def _claude_build_followup( function _responses_translate_input (line 500) | def _responses_translate_input(messages: list[dict[str, Any]]) -> list[d... function _responses_build_request (line 549) | def _responses_build_request( function _responses_parse_response (line 567) | def _responses_parse_response(data: dict[str, Any]) -> ParsedResponse: function _responses_build_followup (line 612) | def _responses_build_followup( function run_scenario (line 671) | def run_scenario( function result_to_dict (line 854) | def result_to_dict(result: ScenarioResult) -> dict[str, Any]: function _placement_sort_key (line 876) | def _placement_sort_key(p: dict[str, Any]) -> tuple[int, int]: function main (line 890) | def main() -> None: FILE: bench/exo_bench.py function load_tokenizer_for_bench (line 60) | def load_tokenizer_for_bench(model_id: str) -> Any: function format_peak_memory (line 126) | def format_peak_memory(b: float) -> str: function parse_int_list (line 134) | def parse_int_list(values: list[str]) -> list[int]: function run_one_completion (line 144) | def run_one_completion( class PromptSizer (line 174) | class PromptSizer: method __init__ (line 175) | def __init__(self, tokenizer: Any, atom: str = "a "): method _make_counter (line 182) | def _make_counter(tokenizer: Any) -> Callable[[str], int]: method build (line 195) | def build(self, target_prompt_tokens: int) -> tuple[str, int]: function main (line 235) | def main() -> int: FILE: bench/exo_eval.py function load_model_config (line 94) | def load_model_config(model_id: str) -> dict[str, Any] | None: function extract_mc_answer (line 113) | def extract_mc_answer(text: str, valid_letters: str = "ABCD") -> str | N... function extract_boxed_answer (line 127) | def extract_boxed_answer(text: str) -> str | None: function extract_code_block (line 151) | def extract_code_block(text: str, preserve_indent: bool = False) -> str ... function check_aime_answer (line 169) | def check_aime_answer(extracted: str, gold: int) -> bool: function _lcb_worker (line 192) | def _lcb_worker( function run_livecodebench_test (line 211) | def run_livecodebench_test( function run_humaneval_test (line 254) | def run_humaneval_test( class QuestionResult (line 272) | class QuestionResult: class BenchmarkConfig (line 287) | class BenchmarkConfig: function format_gpqa_question (line 402) | def format_gpqa_question(doc: dict, idx: int) -> tuple[str, str]: function format_mmlu_pro_question (line 419) | def format_mmlu_pro_question(doc: dict) -> tuple[str, str]: function format_aime_question (line 429) | def format_aime_question(doc: dict) -> tuple[str, int]: function format_humaneval_question (line 434) | def format_humaneval_question(doc: dict) -> tuple[str, dict]: function format_livecodebench_question (line 450) | def format_livecodebench_question(doc: dict) -> tuple[str, str | None, d... class ApiResult (line 514) | class ApiResult: function _call_api (line 521) | async def _call_api( function call_with_retries (line 569) | async def call_with_retries( function evaluate_benchmark (line 612) | async def evaluate_benchmark( function print_results (line 852) | def print_results( function print_comparison (line 901) | def print_comparison( function pick_tasks_interactive (line 954) | def pick_tasks_interactive() -> list[str]: function save_results (line 1023) | def save_results( function parse_int_list (line 1069) | def parse_int_list(values: list[str]) -> list[int]: function main (line 1078) | def main() -> int: FILE: bench/harness.py class ExoHttpError (line 19) | class ExoHttpError(RuntimeError): method __init__ (line 20) | def __init__(self, status: int, reason: str, body_preview: str): class ExoClient (line 25) | class ExoClient: method __init__ (line 26) | def __init__(self, host: str, port: int, timeout_s: float = 7200.0): method request_json (line 31) | def request_json( method post_bench_chat_completions (line 69) | def post_bench_chat_completions(self, payload: dict[str, Any]) -> dict... function unwrap_instance (line 73) | def unwrap_instance(instance: dict[str, Any]) -> dict[str, Any]: function instance_id_from_instance (line 84) | def instance_id_from_instance(instance: dict[str, Any]) -> str: function nodes_used_in_instance (line 89) | def nodes_used_in_instance(instance: dict[str, Any]) -> int: function runner_ids_from_instance (line 94) | def runner_ids_from_instance(instance: dict[str, Any]) -> list[str]: function runner_ready (line 100) | def runner_ready(runner: dict[str, Any]) -> bool: function runner_failed (line 104) | def runner_failed(runner: dict[str, Any]) -> bool: function get_runner_failed_message (line 108) | def get_runner_failed_message(runner: dict[str, Any]) -> str | None: function wait_for_instance_ready (line 114) | def wait_for_instance_ready( function wait_for_instance_gone (line 152) | def wait_for_instance_gone( function resolve_model_short_id (line 168) | def resolve_model_short_id( function placement_filter (line 199) | def placement_filter(instance_meta: str, wanted: str) -> bool: function sharding_filter (line 206) | def sharding_filter(sharding: str, wanted: str) -> bool: function fetch_and_filter_placements (line 213) | def fetch_and_filter_placements( function settle_and_fetch_placements (line 273) | def settle_and_fetch_placements( function run_planning_phase (line 297) | def run_planning_phase( function add_common_instance_args (line 454) | def add_common_instance_args(ap: argparse.ArgumentParser) -> None: FILE: bench/parallel_requests.py function write (line 28) | def write(s: str) -> None: function fetch_models (line 37) | def fetch_models() -> list[str]: function pick_model (line 53) | def pick_model() -> str | None: function render_progress (line 116) | def render_progress(first: bool = False) -> None: function send_request (line 145) | async def send_request( function run_requests (line 185) | async def run_requests(print_stdout: bool = False) -> None: function main (line 233) | def main() -> None: FILE: bench/vendor/lcb_testing_util.py function truncatefn (line 32) | def truncatefn(s, length=300): class CODE_TYPE (line 43) | class CODE_TYPE(Enum): class TimeoutException (line 49) | class TimeoutException(Exception): function timeout_handler (line 53) | def timeout_handler(signum, frame): class Capturing (line 61) | class Capturing(list): method __enter__ (line 62) | def __enter__(self): method __exit__ (line 69) | def __exit__(self, *args): class MockStdinWithBuffer (line 76) | class MockStdinWithBuffer: method __init__ (line 77) | def __init__(self, inputs: str): method read (line 82) | def read(self, *args): method readline (line 85) | def readline(self, *args): method readlines (line 88) | def readlines(self, *args): method __getattr__ (line 91) | def __getattr__(self, name): class MockBuffer (line 96) | class MockBuffer: method __init__ (line 97) | def __init__(self, inputs: str): method read (line 100) | def read(self, *args): method readline (line 104) | def readline(self, *args): function clean_if_name (line 108) | def clean_if_name(code: str) -> str: function make_function (line 124) | def make_function(code: str) -> str: function call_method (line 156) | def call_method(method, inputs): function get_function (line 185) | def get_function(compiled_sol, fn_name: str): # type: ignore function compile_code (line 193) | def compile_code(code: str, timeout: int): function convert_line_to_decimals (line 215) | def convert_line_to_decimals(line: str) -> tuple[bool, list[Decimal]]: function get_stripped_lines (line 223) | def get_stripped_lines(val: str): function grade_call_based (line 230) | def grade_call_based( function grade_stdio (line 311) | def grade_stdio( function run_test (line 429) | def run_test(sample, test=None, debug=False, timeout=6): function reliability_guard (line 510) | def reliability_guard(maximum_memory_bytes=None): FILE: dashboard/src/lib/stores/app.svelte.ts function generateUUID (line 13) | function generateUUID(): string { type NodeInfo (line 28) | interface NodeInfo { type TopologyEdge (line 55) | interface TopologyEdge { type TopologyData (line 64) | interface TopologyData { type Instance (line 69) | interface Instance { type RawNodeIdentity (line 78) | interface RawNodeIdentity { type RawMemoryUsage (line 86) | interface RawMemoryUsage { type RawSystemPerformanceProfile (line 93) | interface RawSystemPerformanceProfile { type RawNetworkInterfaceInfo (line 101) | interface RawNetworkInterfaceInfo { type RawNodeNetworkInfo (line 111) | interface RawNodeNetworkInfo { type RawSocketConnection (line 115) | interface RawSocketConnection { type RawRDMAConnection (line 124) | interface RawRDMAConnection { type RawConnectionEdge (line 129) | type RawConnectionEdge = RawSocketConnection | RawRDMAConnection; type RawConnectionsMap (line 132) | type RawConnectionsMap = Record) { method resetImageGenerationParams (line 764) | resetImageGenerationParams() { method setEditingImage (line 769) | setEditingImage(imageDataUrl: string, sourceMessage: Message) { method clearEditingImage (line 773) | clearEditingImage() { method createConversation (line 780) | createConversation(name?: string): string { method loadConversation (line 840) | loadConversation(id: string): boolean { method deleteConversation (line 862) | deleteConversation(id: string) { method deleteAllConversations (line 878) | deleteAllConversations() { method renameConversation (line 890) | renameConversation(id: string, newName: string) { method getTaggedValue (line 899) | private getTaggedValue(obj: unknown): [string | null, unknown] { method extractInstanceModelId (line 908) | private extractInstanceModelId(instanceWrapped: unknown): string | null { method describeInstance (line 915) | private describeInstance(instanceWrapped: unknown): { method buildConversationModelInfo (line 945) | private buildConversationModelInfo(modelId: string): { method applyConversationModelInfo (line 966) | private applyConversationModelInfo(info: { method getModelTail (line 986) | private getModelTail(modelId: string): string { method isBetterModelId (line 991) | private isBetterModelId( method refreshConversationModelFromInstances (line 1005) | private refreshConversationModelFromInstances() { method getDebugMode (line 1056) | getDebugMode(): boolean { method updateActiveConversation (line 1063) | private updateActiveConversation() { method persistActiveConversation (line 1096) | private persistActiveConversation(throttleMs = 400) { method updateConversationMessage (line 1107) | private updateConversationMessage( method syncActiveMessagesIfNeeded (line 1127) | private syncActiveMessagesIfNeeded(conversationId: string): void { method conversationExists (line 1141) | private conversationExists(conversationId: string): boolean { method persistConversation (line 1148) | private persistConversation(conversationId: string, throttleMs = 400):... method addMessageToConversation (line 1185) | private addMessageToConversation( method toggleSidebar (line 1208) | toggleSidebar() { method setDebugMode (line 1212) | setDebugMode(enabled: boolean) { method toggleDebugMode (line 1217) | toggleDebugMode() { method getTopologyOnlyMode (line 1222) | getTopologyOnlyMode(): boolean { method setTopologyOnlyMode (line 1226) | setTopologyOnlyMode(enabled: boolean) { method toggleTopologyOnlyMode (line 1231) | toggleTopologyOnlyMode() { method getChatSidebarVisible (line 1236) | getChatSidebarVisible(): boolean { method setChatSidebarVisible (line 1240) | setChatSidebarVisible(visible: boolean) { method toggleChatSidebarVisible (line 1245) | toggleChatSidebarVisible() { method getMobileChatSidebarOpen (line 1250) | getMobileChatSidebarOpen(): boolean { method setMobileChatSidebarOpen (line 1254) | setMobileChatSidebarOpen(open: boolean) { method toggleMobileChatSidebar (line 1258) | toggleMobileChatSidebar() { method getMobileRightSidebarOpen (line 1262) | getMobileRightSidebarOpen(): boolean { method setMobileRightSidebarOpen (line 1266) | setMobileRightSidebarOpen(open: boolean) { method toggleMobileRightSidebar (line 1270) | toggleMobileRightSidebar() { method startPolling (line 1274) | startPolling() { method stopPolling (line 1279) | stopPolling() { method fetchState (line 1287) | async fetchState() { method fetchPlacementPreviews (line 1346) | async fetchPlacementPreviews(modelId: string, showLoading = true) { method startPreviewsPolling (line 1380) | startPreviewsPolling(modelId: string) { method stopPreviewsPolling (line 1395) | stopPreviewsPolling() { method selectPreviewModel (line 1402) | selectPreviewModel(modelId: string | null) { method togglePreviewNodeFilter (line 1415) | togglePreviewNodeFilter(nodeId: string) { method clearPreviewNodeFilter (line 1432) | clearPreviewNodeFilter() { method handleTopologyChange (line 1443) | private handleTopologyChange() { method startChat (line 1481) | startChat() { method addMessage (line 1497) | addMessage(role: "user" | "assistant", content: string) { method deleteMessage (line 1511) | deleteMessage(messageId: string) { method editMessage (line 1523) | editMessage(messageId: string, newContent: string) { method editAndRegenerate (line 1535) | async editAndRegenerate( method regenerateLastResponse (line 1559) | async regenerateLastResponse(): Promise { method regenerateFromToken (line 1614) | async regenerateFromToken( method regenerateChatCompletion (line 1834) | private async regenerateChatCompletion(): Promise { method setSelectedModel (line 2041) | setSelectedModel(modelId: string) { method stripThinkingTags (line 2052) | private stripThinkingTags(content: string): { method parseSSEStream (line 2092) | private async parseSSEStream( method handleStreamingError (line 2171) | private handleStreamingError( method getModelForRequest (line 2197) | private getModelForRequest(modelId?: string): string | null { method sendMessage (line 2221) | async sendMessage( method stopGeneration (line 2575) | stopGeneration(): void { method generateImage (line 2583) | async generateImage(prompt: string, modelId?: string): Promise { method editImage (line 2839) | async editImage( method clearChat (line 3071) | clearChat() { method getActiveConversation (line 3085) | getActiveConversation(): Conversation | null { method setConversationThinking (line 3095) | setConversationThinking(enabled: boolean) { method startDownload (line 3107) | async startDownload(nodeId: string, shardMetadata: object): Promise { method listTraces (line 3155) | async listTraces(): Promise { method checkTraceExists (line 3166) | async checkTraceExists(taskId: string): Promise { method fetchTraceStats (line 3178) | async fetchTraceStats(taskId: string): Promise { method deleteTraces (line 3191) | async deleteTraces( method getTraceRawUrl (line 3208) | getTraceRawUrl(taskId: string): string { FILE: dashboard/src/lib/stores/favorites.svelte.ts constant FAVORITES_KEY (line 7) | const FAVORITES_KEY = "exo-favorite-models"; class FavoritesStore (line 9) | class FavoritesStore { method constructor (line 12) | constructor() { method loadFromStorage (line 18) | private loadFromStorage() { method saveToStorage (line 30) | private saveToStorage() { method add (line 39) | add(baseModelId: string) { method remove (line 46) | remove(baseModelId: string) { method toggle (line 53) | toggle(baseModelId: string) { method isFavorite (line 61) | isFavorite(baseModelId: string): boolean { method getAll (line 65) | getAll(): string[] { method getSet (line 69) | getSet(): Set { method hasAny (line 73) | hasAny(): boolean { method clearAll (line 77) | clearAll() { FILE: dashboard/src/lib/stores/recents.svelte.ts constant RECENTS_KEY (line 7) | const RECENTS_KEY = "exo-recent-models"; constant MAX_RECENT_MODELS (line 8) | const MAX_RECENT_MODELS = 20; type RecentEntry (line 10) | interface RecentEntry { class RecentsStore (line 15) | class RecentsStore { method constructor (line 18) | constructor() { method loadFromStorage (line 24) | private loadFromStorage() { method saveToStorage (line 36) | private saveToStorage() { method recordLaunch (line 44) | recordLaunch(modelId: string) { method getRecentModelIds (line 54) | getRecentModelIds(): string[] { method hasAny (line 58) | hasAny(): boolean { method clearAll (line 62) | clearAll() { FILE: dashboard/src/lib/stores/toast.svelte.ts type ToastType (line 10) | type ToastType = "success" | "error" | "warning" | "info"; type Toast (line 12) | interface Toast { type ToastInput (line 21) | interface ToastInput { constant DEFAULT_DURATIONS (line 30) | const DEFAULT_DURATIONS: Record = { function generateId (line 40) | function generateId(): string { function addToast (line 44) | function addToast(input: ToastInput): string { function dismissToast (line 68) | function dismissToast(id: string): void { function dismissByMessage (line 78) | function dismissByMessage(message: string): void { function toasts (line 85) | function toasts(): Toast[] { FILE: dashboard/src/lib/types/files.ts type ChatUploadedFile (line 5) | interface ChatUploadedFile { type ChatAttachment (line 15) | interface ChatAttachment { type FileCategory (line 23) | type FileCategory = "image" | "text" | "pdf" | "audio" | "unknown"; constant IMAGE_EXTENSIONS (line 25) | const IMAGE_EXTENSIONS = [ constant IMAGE_MIME_TYPES (line 33) | const IMAGE_MIME_TYPES = [ constant TEXT_EXTENSIONS (line 41) | const TEXT_EXTENSIONS = [ constant TEXT_MIME_TYPES (line 77) | const TEXT_MIME_TYPES = [ constant PDF_EXTENSIONS (line 91) | const PDF_EXTENSIONS = [".pdf"]; constant PDF_MIME_TYPES (line 92) | const PDF_MIME_TYPES = ["application/pdf"]; constant AUDIO_EXTENSIONS (line 94) | const AUDIO_EXTENSIONS = [".mp3", ".wav", ".ogg", ".m4a"]; constant AUDIO_MIME_TYPES (line 95) | const AUDIO_MIME_TYPES = [ function getFileCategory (line 105) | function getFileCategory( function getAcceptString (line 139) | function getAcceptString(categories: FileCategory[]): string { function formatFileSize (line 165) | function formatFileSize(bytes: number): string { function readFileAsDataURL (line 176) | function readFileAsDataURL(file: File): Promise { function readFileAsText (line 188) | function readFileAsText(file: File): Promise { function processUploadedFiles (line 200) | async function processUploadedFiles( FILE: dashboard/src/lib/utils/downloads.ts function unwrapTagged (line 12) | function unwrapTagged( function extractModelIdFromDownload (line 24) | function extractModelIdFromDownload( function extractShardMetadata (line 43) | function extractShardMetadata( function getDownloadTag (line 53) | function getDownloadTag( function isModelDownloadedOnNode (line 77) | function isModelDownloadedOnNode( function getNodesWithModelDownloaded (line 92) | function getNodesWithModelDownloaded( function getShardMetadataForModel (line 109) | function getShardMetadataForModel( function getModelDownloadStatus (line 136) | function getModelDownloadStatus( FILE: packaging/dmg/generate-background.py function draw_arrow (line 39) | def draw_arrow(draw: ImageDraw.ImageDraw) -> None: function generate_background (line 79) | def generate_background(output_path: str) -> None: FILE: rust/exo_pyo3_bindings/exo_pyo3_bindings.pyi class AllQueuesFullError (line 8) | class AllQueuesFullError(builtins.Exception): method __new__ (line 9) | def __new__(cls, *args: typing.Any) -> AllQueuesFullError: ... method __repr__ (line 10) | def __repr__(self) -> builtins.str: ... method __str__ (line 11) | def __str__(self) -> builtins.str: ... class Keypair (line 14) | class Keypair: method generate (line 19) | def generate() -> Keypair: method from_bytes (line 24) | def from_bytes(bytes: bytes) -> Keypair: method to_bytes (line 28) | def to_bytes(self) -> bytes: method to_node_id (line 32) | def to_node_id(self) -> builtins.str: class MessageTooLargeError (line 38) | class MessageTooLargeError(builtins.Exception): method __new__ (line 39) | def __new__(cls, *args: typing.Any) -> MessageTooLargeError: ... method __repr__ (line 40) | def __repr__(self) -> builtins.str: ... method __str__ (line 41) | def __str__(self) -> builtins.str: ... class NetworkingHandle (line 44) | class NetworkingHandle: method __new__ (line 45) | def __new__(cls, identity: Keypair) -> NetworkingHandle: ... method gossipsub_subscribe (line 46) | async def gossipsub_subscribe(self, topic: builtins.str) -> builtins.b... method gossipsub_unsubscribe (line 52) | async def gossipsub_unsubscribe(self, topic: builtins.str) -> builtins... method gossipsub_publish (line 58) | async def gossipsub_publish(self, topic: builtins.str, data: bytes) ->... method recv (line 64) | async def recv(self) -> PyFromSwarm: ... class NoPeersSubscribedToTopicError (line 67) | class NoPeersSubscribedToTopicError(builtins.Exception): method __new__ (line 68) | def __new__(cls, *args: typing.Any) -> NoPeersSubscribedToTopicError: ... method __repr__ (line 69) | def __repr__(self) -> builtins.str: ... method __str__ (line 70) | def __str__(self) -> builtins.str: ... class PyFromSwarm (line 72) | class PyFromSwarm: class Connection (line 74) | class Connection(PyFromSwarm): method peer_id (line 77) | def peer_id(self) -> builtins.str: ... method connected (line 79) | def connected(self) -> builtins.bool: ... method __new__ (line 80) | def __new__(cls, peer_id: builtins.str, connected: builtins.bool) ->... class Message (line 83) | class Message(PyFromSwarm): method origin (line 86) | def origin(self) -> builtins.str: ... method topic (line 88) | def topic(self) -> builtins.str: ... method data (line 90) | def data(self) -> bytes: ... method __new__ (line 91) | def __new__(cls, origin: builtins.str, topic: builtins.str, data: by... FILE: rust/exo_pyo3_bindings/src/allow_threading.rs type AllowThreads (line 15) | pub(crate) struct AllowThreads(#[pin] F); function new (line 21) | pub fn new(f: F) -> Self { type Output (line 31) | type Output = F::Output; method poll (line 33) | fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll { FILE: rust/exo_pyo3_bindings/src/bin/stub_gen.rs function main (line 3) | fn main() -> Result<()> { FILE: rust/exo_pyo3_bindings/src/ident.rs type PyKeypair (line 11) | pub struct PyKeypair(pub Keypair); method generate (line 19) | fn generate() -> Self { method from_bytes (line 25) | fn from_bytes(bytes: Bound<'_, PyBytes>) -> PyResult { method to_bytes (line 31) | fn to_bytes<'py>(&self, py: Python<'py>) -> PyResult String { FILE: rust/exo_pyo3_bindings/src/lib.rs constant MPSC_CHANNEL_SIZE (line 20) | pub const MPSC_CHANNEL_SIZE: usize = 1024; function pybytes (line 37) | fn pybytes(&self) -> Py { function pyerr (line 47) | fn pyerr(self) -> PyResult { type FutureExt (line 52) | pub trait FutureExt: Future + Sized { method allow_threads_py (line 54) | fn allow_threads_py(self) -> AllowThreads method receiver_channel_closed (line 66) | fn receiver_channel_closed() -> Self { function write_unraisable (line 73) | fn write_unraisable(self) -> Option { function write_unraisable_with (line 77) | fn write_unraisable_with(self, py: Python<'_>) -> Option { method spawn_with_scope (line 91) | fn spawn_with_scope(&self, py: Python<'_>, future: F) -> PyResult PyResult<()> { function recv_py (line 118) | async fn recv_py(&mut self) -> PyResult { function recv_many_py (line 127) | async fn recv_many_py(&mut self, limit: usize) -> PyResult> { function try_recv_py (line 141) | fn try_recv_py(&mut self) -> PyResult> { function main_module (line 155) | fn main_module(m: &Bound<'_, PyModule>) -> PyResult<()> { FILE: rust/exo_pyo3_bindings/src/networking.rs type PyNoPeersSubscribedToTopicError (line 31) | pub struct PyNoPeersSubscribedToTopicError {} constant MSG (line 34) | const MSG: &'static str = "\ method new_err (line 41) | pub(crate) fn new_err() -> PyErr { method new (line 52) | pub(crate) fn new(args: &Bound<'_, PyTuple>) -> Self { method __repr__ (line 56) | fn __repr__(&self) -> String { method __str__ (line 60) | fn __str__(&self) -> String { type PyAllQueuesFullError (line 67) | pub struct PyAllQueuesFullError {} constant MSG (line 70) | const MSG: &'static str = method new_err (line 76) | pub(crate) fn new_err() -> PyErr { method new (line 87) | pub(crate) fn new(args: &Bound<'_, PyTuple>) -> Self { method __repr__ (line 91) | fn __repr__(&self) -> String { method __str__ (line 95) | fn __str__(&self) -> String { type PyMessageTooLargeError (line 102) | pub struct PyMessageTooLargeError {} constant MSG (line 105) | const MSG: &'static str = "Gossipsub message exceeds max_transmit_size... method new_err (line 107) | pub(crate) fn new_err() -> PyErr { method new (line 118) | pub(crate) fn new(args: &Bound<'_, PyTuple>) -> Self { method __repr__ (line 122) | fn __repr__(&self) -> String { method __str__ (line 126) | fn __str__(&self) -> String { type PyNetworkingHandle (line 134) | struct PyNetworkingHandle { method py_new (line 183) | fn py_new(identity: Bound<'_, PyKeypair>) -> PyResult { method recv (line 201) | fn recv<'py>(&'py self, py: Python<'py>) -> PyResult> { method gossipsub_subscribe (line 219) | async fn gossipsub_subscribe(&self, topic: String) -> PyResult { method gossipsub_unsubscribe (line 241) | async fn gossipsub_unsubscribe(&self, topic: String) -> PyResult { method gossipsub_publish (line 262) | async fn gossipsub_publish(&self, topic: String, data: Py) ->... type PyFromSwarm (line 142) | enum PyFromSwarm { method from (line 154) | fn from(value: FromSwarm) -> Self { function networking_submodule (line 302) | pub fn networking_submodule(m: &Bound<'_, PyModule>) -> PyResult<()> { FILE: rust/exo_pyo3_bindings/tests/dummy.rs function test_drop_channel (line 10) | async fn test_drop_channel() { FILE: rust/exo_pyo3_bindings/tests/test_python.py function test_sleep_on_multiple_items (line 13) | async def test_sleep_on_multiple_items() -> None: function _await_recv (line 29) | async def _await_recv(h: NetworkingHandle): FILE: rust/networking/examples/chatroom.rs function main (line 11) | async fn main() { FILE: rust/networking/src/discovery.rs constant RETRY_CONNECT_INTERVAL (line 24) | const RETRY_CONNECT_INTERVAL: Duration = Duration::from_secs(5); constant MDNS_RECORD_TTL (line 32) | const MDNS_RECORD_TTL: Duration = Duration::from_secs(2_500); constant MDNS_QUERY_INTERVAL (line 33) | const MDNS_QUERY_INTERVAL: Duration = Duration::from_secs(1_500); constant PING_TIMEOUT (line 34) | const PING_TIMEOUT: Duration = Duration::from_millis(2_500); constant PING_INTERVAL (line 35) | const PING_INTERVAL: Duration = Duration::from_millis(2_500); type Behaviour (line 38) | pub struct Behaviour { method new (line 44) | pub fn new(keypair: &identity::Keypair) -> io::Result { method new (line 115) | pub fn new(keypair: &identity::Keypair) -> io::Result { method dial (line 124) | fn dial(&mut self, peer_id: PeerId, addr: Multiaddr) { method close_connection (line 130) | fn close_connection(&mut self, peer_id: PeerId, connection: Connection... method handle_mdns_discovered (line 138) | fn handle_mdns_discovered(&mut self, peers: Vec<(PeerId, Multiaddr)>) { method handle_mdns_expired (line 154) | fn handle_mdns_expired(&mut self, peers: Vec<(PeerId, Multiaddr)>) { method on_connection_established (line 173) | fn on_connection_established( method on_connection_closed (line 190) | fn on_connection_closed( function mdns_behaviour (line 52) | fn mdns_behaviour(keypair: &identity::Keypair) -> io::Result ping::Behaviour { type Event (line 79) | pub enum Event { type Behaviour (line 103) | pub struct Behaviour { method new (line 44) | pub fn new(keypair: &identity::Keypair) -> io::Result { method new (line 115) | pub fn new(keypair: &identity::Keypair) -> io::Result { method dial (line 124) | fn dial(&mut self, peer_id: PeerId, addr: Multiaddr) { method close_connection (line 130) | fn close_connection(&mut self, peer_id: PeerId, connection: Connection... method handle_mdns_discovered (line 138) | fn handle_mdns_discovered(&mut self, peers: Vec<(PeerId, Multiaddr)>) { method handle_mdns_expired (line 154) | fn handle_mdns_expired(&mut self, peers: Vec<(PeerId, Multiaddr)>) { method on_connection_established (line 173) | fn on_connection_established( method on_connection_closed (line 190) | fn on_connection_closed( type ConnectionHandler (line 209) | type ConnectionHandler = type ToSwarm (line 211) | type ToSwarm = Event; method handle_established_inbound_connection (line 222) | fn handle_established_inbound_connection( method handle_established_outbound_connection (line 241) | fn handle_established_outbound_connection( method on_connection_handler_event (line 261) | fn on_connection_handler_event( method on_swarm_event (line 278) | fn on_swarm_event(&mut self, event: FromSwarm) { method poll (line 325) | fn poll(&mut self, cx: &mut Context) -> Poll; type AnyResult (line 14) | pub type AnyResult = Result; method try_to_tcp_addr (line 27) | fn try_to_tcp_addr(&self) -> Option<(IpAddr, u16)> { FILE: rust/networking/src/swarm.rs constant NETWORK_VERSION (line 17) | pub const NETWORK_VERSION: &[u8] = b"v0.0.1"; constant OVERRIDE_VERSION_ENV_VAR (line 18) | pub const OVERRIDE_VERSION_ENV_VAR: &str = "EXO_LIBP2P_NAMESPACE"; type ToSwarm (line 22) | pub enum ToSwarm { type FromSwarm (line 37) | pub enum FromSwarm { type Swarm (line 51) | pub struct Swarm { method into_stream (line 57) | pub fn into_stream(self) -> Pin + Sen... function on_message (line 82) | fn on_message(swarm: &mut libp2p::Swarm, message: ToSwarm) { function filter_swarm_event (line 118) | fn filter_swarm_event(event: SwarmEvent) -> Option( function tcp_transport (line 203) | pub fn tcp_transport( type Behaviour (line 243) | pub struct Behaviour { method new (line 249) | pub fn new(keypair: &identity::Keypair) -> alias::AnyResult { function gossipsub_behaviour (line 257) | fn gossipsub_behaviour(keypair: &identity::Keypair) -> gossipsub::Behavi... FILE: rust/networking/tests/dummy.rs function does_nothing (line 6) | fn does_nothing() {} FILE: rust/util/src/wakerdeque.rs type WakerDeque (line 7) | pub struct WakerDeque { method fmt (line 13) | fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { function new (line 19) | pub fn new() -> Self { function update (line 26) | fn update(&mut self, cx: &mut Context<'_>) { function wake (line 30) | fn wake(&mut self) { function pop_front (line 36) | pub fn pop_front(&mut self, cx: &mut Context<'_>) -> Option { function pop_back (line 41) | pub fn pop_back(&mut self, cx: &mut Context<'_>) -> Option { function push_front (line 46) | pub fn push_front(&mut self, value: T) { function push_back (line 51) | pub fn push_back(&mut self, value: T) { FILE: scripts/fetch_kv_heads.py function fetch_kv_heads (line 29) | def fetch_kv_heads(model_id: str) -> int | None: function update_toml (line 46) | def update_toml(path: Path, kv_heads: int) -> bool: function process_card (line 69) | def process_card(path: Path) -> tuple[str, str]: function main (line 85) | def main(): FILE: src/exo/__main__.py function _maybe_run_inline_code (line 13) | def _maybe_run_inline_code(argv: Sequence[str]) -> bool: FILE: src/exo/api/adapters/chat_completions.py function chat_request_to_text_generation (line 36) | def chat_request_to_text_generation( function chunk_to_response (line 113) | def chunk_to_response( function generate_chat_stream (line 150) | async def generate_chat_stream( function collect_chat_response (line 222) | async def collect_chat_response( FILE: src/exo/api/adapters/claude.py function finish_reason_to_claude_stop_reason (line 42) | def finish_reason_to_claude_stop_reason( function _extract_tool_result_text (line 58) | def _extract_tool_result_text(block: ClaudeToolResultBlock) -> str: function _strip_volatile_headers (line 72) | def _strip_volatile_headers(text: str) -> str: function claude_request_to_text_generation (line 83) | def claude_request_to_text_generation( function collect_claude_response (line 203) | async def collect_claude_response( function generate_claude_stream (line 285) | async def generate_claude_stream( FILE: src/exo/api/adapters/ollama.py function _map_done_reason (line 27) | def _map_done_reason( function _try_parse_json (line 43) | def _try_parse_json(value: str) -> dict[str, Any] | str: function _build_tool_calls (line 50) | def _build_tool_calls(chunk: ToolCallChunk) -> list[OllamaToolCall]: function _get_usage (line 67) | def _get_usage( function ollama_request_to_text_generation (line 78) | def ollama_request_to_text_generation( function generate_ollama_chat_stream (line 158) | async def generate_ollama_chat_stream( function collect_ollama_chat_response (line 241) | async def collect_ollama_chat_response( function ollama_generate_request_to_text_generation (line 309) | def ollama_generate_request_to_text_generation( function generate_ollama_generate_stream (line 337) | async def generate_ollama_generate_stream( function collect_ollama_generate_response (line 410) | async def collect_ollama_generate_response( FILE: src/exo/api/adapters/responses.py function _format_sse (line 52) | def _format_sse(event: ResponsesStreamEvent) -> str: function _extract_content (line 57) | def _extract_content(content: str | list[ResponseContentPart]) -> str: function responses_request_to_text_generation (line 64) | def responses_request_to_text_generation( function collect_responses_response (line 171) | async def collect_responses_response( function generate_responses_stream (line 258) | async def generate_responses_stream( FILE: src/exo/api/main.py function _format_to_content_type (line 184) | def _format_to_content_type(image_format: Literal["png", "jpeg", "webp"]... function _ensure_seed (line 188) | def _ensure_seed(params: AdvancedImageParams | None) -> AdvancedImagePar... class API (line 197) | class API: method __init__ (line 198) | def __init__( method reset (line 256) | def reset(self, result_clock: int, event_receiver: Receiver[IndexedEve... method unpause (line 269) | def unpause(self, result_clock: int): method _setup_exception_handlers (line 276) | def _setup_exception_handlers(self) -> None: method http_exception_handler (line 279) | async def http_exception_handler( method _setup_cors (line 291) | def _setup_cors(self) -> None: method _setup_routes (line 300) | def _setup_routes(self) -> None: method place_instance (line 355) | async def place_instance(self, payload: PlaceInstanceParams): method create_instance (line 370) | async def create_instance( method get_placement (line 395) | async def get_placement( method get_placement_previews (line 432) | async def get_placement_previews( method get_instance (line 554) | def get_instance(self, instance_id: InstanceId) -> Instance: method delete_instance (line 559) | async def delete_instance(self, instance_id: InstanceId) -> DeleteInst... method cancel_command (line 573) | async def cancel_command(self, command_id: CommandId) -> CancelCommand... method _token_chunk_stream (line 592) | async def _token_chunk_stream( method _collect_text_generation_with_stats (line 626) | async def _collect_text_generation_with_stats( method _trigger_notify_user_to_download_model (line 695) | async def _trigger_notify_user_to_download_model(self, model_id: Model... method chat_completions (line 700) | async def chat_completions( method bench_chat_completions (line 735) | async def bench_chat_completions( method _resolve_and_validate_text_model (line 751) | async def _resolve_and_validate_text_model(self, model_id: ModelId) ->... method _validate_image_model (line 767) | async def _validate_image_model(self, model: ModelId) -> ModelId: method stream_events (line 784) | def stream_events(self) -> StreamingResponse: method get_image (line 800) | async def get_image(self, image_id: str) -> FileResponse: method list_images (line 806) | async def list_images(self, request: Request) -> ImageListResponse: method _build_image_url (line 821) | def _build_image_url(self, request: Request, image_id: Id) -> str: method image_generations (line 826) | async def image_generations( method _generate_image_stream (line 866) | async def _generate_image_stream( method _collect_image_chunks (line 980) | async def _collect_image_chunks( method _collect_image_generation (line 1066) | async def _collect_image_generation( method _collect_image_generation_with_stats (line 1079) | async def _collect_image_generation_with_stats( method bench_image_generations (line 1099) | async def bench_image_generations( method _send_image_edits_command (line 1123) | async def _send_image_edits_command( method image_edits (line 1192) | async def image_edits( method bench_image_edits (line 1254) | async def bench_image_edits( method claude_messages (line 1299) | async def claude_messages( method openai_responses (line 1336) | async def openai_responses( method _ollama_root (line 1372) | async def _ollama_root(self) -> JSONResponse: method ollama_chat (line 1376) | async def ollama_chat( method ollama_generate (line 1413) | async def ollama_generate( method ollama_tags (line 1450) | async def ollama_tags(self) -> OllamaTagsResponse: method ollama_show (line 1484) | async def ollama_show(self, request: Request) -> OllamaShowResponse: method ollama_ps (line 1507) | async def ollama_ps(self) -> OllamaPsResponse: method ollama_version (line 1525) | async def ollama_version(self) -> dict[str, str]: method _calculate_total_available_memory (line 1529) | def _calculate_total_available_memory(self) -> Memory: method get_models (line 1538) | async def get_models(self, status: str | None = Query(default=None)) -... method add_custom_model (line 1571) | async def add_custom_model(self, payload: AddCustomModelParams) -> Mod... method delete_custom_model (line 1592) | async def delete_custom_model(self, model_id: ModelId) -> JSONResponse: method search_models (line 1601) | async def search_models( method run (line 1641) | async def run(self): method run_api (line 1662) | async def run_api(self, ev: anyio.Event): method _apply_state (line 1676) | async def _apply_state(self): method _save_merged_trace (line 1703) | def _save_merged_trace(self, event: TracesMerged) -> None: method _pause_on_new_election (line 1718) | async def _pause_on_new_election(self): method _cleanup_expired_images (line 1724) | async def _cleanup_expired_images(self): method _send (line 1733) | async def _send(self, command: Command): method _send_download (line 1740) | async def _send_download(self, command: DownloadCommand): method start_download (line 1745) | async def start_download( method delete_download (line 1755) | async def delete_download( method _get_trace_path (line 1766) | def _get_trace_path(task_id: str) -> Path: method list_traces (line 1772) | async def list_traces(self) -> TraceListResponse: method get_trace (line 1796) | async def get_trace(self, task_id: str) -> TraceResponse: method get_trace_stats (line 1818) | async def get_trace_stats(self, task_id: str) -> TraceStatsResponse: method get_trace_raw (line 1857) | async def get_trace_raw(self, task_id: str) -> FileResponse: method delete_traces (line 1869) | async def delete_traces(self, request: DeleteTracesRequest) -> DeleteT... method get_onboarding (line 1881) | async def get_onboarding(self) -> JSONResponse: method complete_onboarding (line 1884) | async def complete_onboarding(self) -> JSONResponse: FILE: src/exo/api/tests/test_api_error_handling.py function test_http_exception_handler_formats_openai_style (line 10) | def test_http_exception_handler_formats_openai_style() -> None: FILE: src/exo/api/tests/test_cancel_command.py function _make_api (line 12) | def _make_api() -> Any: function test_cancel_nonexistent_command_returns_404 (line 26) | def test_cancel_nonexistent_command_returns_404() -> None: function test_cancel_active_text_generation (line 40) | def test_cancel_active_text_generation() -> None: function test_cancel_active_image_generation (line 60) | def test_cancel_active_image_generation() -> None: FILE: src/exo/api/tests/test_claude_api.py class TestFinishReasonToClaudeStopReason (line 18) | class TestFinishReasonToClaudeStopReason: method test_stop_maps_to_end_turn (line 21) | def test_stop_maps_to_end_turn(self): method test_length_maps_to_max_tokens (line 24) | def test_length_maps_to_max_tokens(self): method test_tool_calls_maps_to_tool_use (line 27) | def test_tool_calls_maps_to_tool_use(self): method test_function_call_maps_to_tool_use (line 30) | def test_function_call_maps_to_tool_use(self): method test_content_filter_maps_to_end_turn (line 33) | def test_content_filter_maps_to_end_turn(self): method test_none_returns_none (line 36) | def test_none_returns_none(self): class TestClaudeRequestToInternal (line 40) | class TestClaudeRequestToInternal: method test_basic_request_conversion (line 43) | def test_basic_request_conversion(self): method test_request_with_system_string (line 61) | def test_request_with_system_string(self): method test_request_with_system_text_blocks (line 78) | def test_request_with_system_text_blocks(self): method test_request_with_content_blocks (line 96) | def test_request_with_content_blocks(self): method test_request_with_multi_turn_conversation (line 116) | def test_request_with_multi_turn_conversation(self): method test_request_with_optional_parameters (line 134) | def test_request_with_optional_parameters(self): class TestClaudeMessagesRequestValidation (line 154) | class TestClaudeMessagesRequestValidation: method test_request_requires_model (line 157) | def test_request_requires_model(self): method test_request_requires_max_tokens (line 166) | def test_request_requires_max_tokens(self): method test_request_requires_messages (line 175) | def test_request_requires_messages(self): FILE: src/exo/api/tests/test_claude_tool_use.py function _chunks_to_stream (line 17) | async def _chunks_to_stream( function _collect_response (line 24) | async def _collect_response( function _parse_sse_events (line 40) | def _parse_sse_events(events: list[str]) -> list[dict[str, Any]]: class TestCollectClaudeResponseToolUse (line 50) | class TestCollectClaudeResponseToolUse: method test_tool_call_chunk_produces_tool_use_blocks (line 53) | async def test_tool_call_chunk_produces_tool_use_blocks(self): method test_multiple_tool_calls (line 79) | async def test_multiple_tool_calls(self): method test_mixed_text_and_tool_use (line 106) | async def test_mixed_text_and_tool_use(self): method test_no_content_produces_empty_text_block (line 133) | async def test_no_content_produces_empty_text_block(self): class TestGenerateClaudeStreamToolUse (line 142) | class TestGenerateClaudeStreamToolUse: method test_tool_call_emits_tool_use_events (line 145) | async def test_tool_call_emits_tool_use_events(self): method test_streaming_mixed_text_and_tool_use (line 197) | async def test_streaming_mixed_text_and_tool_use(self): method test_streaming_tool_block_stop_events (line 245) | async def test_streaming_tool_block_stop_events(self): FILE: src/exo/api/tests/test_openai_responses_api.py class TestResponsesRequestValidation (line 17) | class TestResponsesRequestValidation: method test_request_requires_model (line 20) | def test_request_requires_model(self): method test_request_requires_input (line 28) | def test_request_requires_input(self): method test_request_accepts_string_input (line 36) | def test_request_accepts_string_input(self): method test_request_accepts_message_array_input (line 43) | def test_request_accepts_message_array_input(self): FILE: src/exo/api/types/api.py class ErrorInfo (line 21) | class ErrorInfo(BaseModel): class ErrorResponse (line 28) | class ErrorResponse(BaseModel): class ModelListModel (line 32) | class ModelListModel(BaseModel): class ModelList (line 53) | class ModelList(BaseModel): class ChatCompletionMessageText (line 58) | class ChatCompletionMessageText(BaseModel): class ToolCallItem (line 63) | class ToolCallItem(BaseModel): class ToolCall (line 69) | class ToolCall(BaseModel): class ChatCompletionMessage (line 76) | class ChatCompletionMessage(BaseModel): class BenchChatCompletionMessage (line 88) | class BenchChatCompletionMessage(ChatCompletionMessage): class TopLogprobItem (line 92) | class TopLogprobItem(BaseModel): class LogprobsContentItem (line 98) | class LogprobsContentItem(BaseModel): class Logprobs (line 105) | class Logprobs(BaseModel): class PromptTokensDetails (line 109) | class PromptTokensDetails(BaseModel): class CompletionTokensDetails (line 114) | class CompletionTokensDetails(BaseModel): class Usage (line 121) | class Usage(BaseModel): class StreamingChoiceResponse (line 129) | class StreamingChoiceResponse(BaseModel): class ChatCompletionChoice (line 137) | class ChatCompletionChoice(BaseModel): class ChatCompletionResponse (line 144) | class ChatCompletionResponse(BaseModel): class GenerationStats (line 154) | class GenerationStats(BaseModel): class ImageGenerationStats (line 162) | class ImageGenerationStats(BaseModel): class NodePowerStats (line 175) | class NodePowerStats(BaseModel, frozen=True): class PowerUsage (line 181) | class PowerUsage(BaseModel, frozen=True): class BenchChatCompletionResponse (line 188) | class BenchChatCompletionResponse(ChatCompletionResponse): class StreamOptions (line 193) | class StreamOptions(BaseModel): class ChatCompletionRequest (line 197) | class ChatCompletionRequest(BaseModel): class BenchChatCompletionRequest (line 226) | class BenchChatCompletionRequest(ChatCompletionRequest): class AddCustomModelParams (line 230) | class AddCustomModelParams(BaseModel): class HuggingFaceSearchResult (line 234) | class HuggingFaceSearchResult(BaseModel): class PlaceInstanceParams (line 243) | class PlaceInstanceParams(BaseModel): class CreateInstanceParams (line 250) | class CreateInstanceParams(BaseModel): class PlacementPreview (line 254) | class PlacementPreview(BaseModel): class PlacementPreviewResponse (line 264) | class PlacementPreviewResponse(BaseModel): class DeleteInstanceTaskParams (line 268) | class DeleteInstanceTaskParams(BaseModel): class CreateInstanceResponse (line 272) | class CreateInstanceResponse(BaseModel): class DeleteInstanceResponse (line 278) | class DeleteInstanceResponse(BaseModel): class CancelCommandResponse (line 284) | class CancelCommandResponse(BaseModel): function normalize_image_size (line 301) | def normalize_image_size(v: object) -> ImageSize: class AdvancedImageParams (line 310) | class AdvancedImageParams(BaseModel): class ImageGenerationTaskParams (line 318) | class ImageGenerationTaskParams(BaseModel): method normalize_size (line 339) | def normalize_size(cls, v: object) -> ImageSize: class BenchImageGenerationTaskParams (line 343) | class BenchImageGenerationTaskParams(ImageGenerationTaskParams): class ImageEditsTaskParams (line 347) | class ImageEditsTaskParams(BaseModel): method normalize_size (line 367) | def normalize_size(cls, v: object) -> ImageSize: method __repr_args__ (line 370) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class ImageData (line 378) | class ImageData(BaseModel): method __repr_args__ (line 383) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class ImageGenerationResponse (line 391) | class ImageGenerationResponse(BaseModel): class BenchImageGenerationResponse (line 396) | class BenchImageGenerationResponse(ImageGenerationResponse): class ImageListItem (line 401) | class ImageListItem(BaseModel, frozen=True): class ImageListResponse (line 408) | class ImageListResponse(BaseModel, frozen=True): class StartDownloadParams (line 412) | class StartDownloadParams(CamelCaseModel): class StartDownloadResponse (line 417) | class StartDownloadResponse(CamelCaseModel): class DeleteDownloadResponse (line 421) | class DeleteDownloadResponse(CamelCaseModel): class TraceEventResponse (line 425) | class TraceEventResponse(CamelCaseModel): class TraceResponse (line 433) | class TraceResponse(CamelCaseModel): class TraceCategoryStats (line 438) | class TraceCategoryStats(CamelCaseModel): class TraceRankStats (line 446) | class TraceRankStats(CamelCaseModel): class TraceStatsResponse (line 450) | class TraceStatsResponse(CamelCaseModel): class TraceListItem (line 457) | class TraceListItem(CamelCaseModel): class TraceListResponse (line 463) | class TraceListResponse(CamelCaseModel): class DeleteTracesRequest (line 467) | class DeleteTracesRequest(CamelCaseModel): class DeleteTracesResponse (line 471) | class DeleteTracesResponse(CamelCaseModel): FILE: src/exo/api/types/claude_api.py class ClaudeToolDefinition (line 13) | class ClaudeToolDefinition(BaseModel, frozen=True): class ClaudeTextBlock (line 27) | class ClaudeTextBlock(BaseModel, frozen=True): class ClaudeImageSource (line 34) | class ClaudeImageSource(BaseModel, frozen=True): class ClaudeImageBlock (line 43) | class ClaudeImageBlock(BaseModel, frozen=True): class ClaudeThinkingBlock (line 50) | class ClaudeThinkingBlock(BaseModel, frozen=True): class ClaudeToolUseBlock (line 58) | class ClaudeToolUseBlock(BaseModel, frozen=True): class ClaudeToolResultBlock (line 67) | class ClaudeToolResultBlock(BaseModel, frozen=True): class ClaudeMessage (line 92) | class ClaudeMessage(BaseModel, frozen=True): class ClaudeThinkingConfig (line 99) | class ClaudeThinkingConfig(BaseModel, frozen=True): class ClaudeMessagesRequest (line 104) | class ClaudeMessagesRequest(BaseModel): class ClaudeUsage (line 122) | class ClaudeUsage(BaseModel, frozen=True): class ClaudeMessagesResponse (line 129) | class ClaudeMessagesResponse(BaseModel, frozen=True): class ClaudeMessageStart (line 143) | class ClaudeMessageStart(BaseModel, frozen=True): class ClaudeMessageStartEvent (line 156) | class ClaudeMessageStartEvent(BaseModel, frozen=True): class ClaudeContentBlockStartEvent (line 163) | class ClaudeContentBlockStartEvent(BaseModel, frozen=True): class ClaudeTextDelta (line 171) | class ClaudeTextDelta(BaseModel, frozen=True): class ClaudeThinkingDelta (line 178) | class ClaudeThinkingDelta(BaseModel, frozen=True): class ClaudeInputJsonDelta (line 185) | class ClaudeInputJsonDelta(BaseModel, frozen=True): class ClaudeContentBlockDeltaEvent (line 192) | class ClaudeContentBlockDeltaEvent(BaseModel, frozen=True): class ClaudeContentBlockStopEvent (line 200) | class ClaudeContentBlockStopEvent(BaseModel, frozen=True): class ClaudeMessageDeltaUsage (line 207) | class ClaudeMessageDeltaUsage(BaseModel, frozen=True): class ClaudeMessageDelta (line 213) | class ClaudeMessageDelta(BaseModel, frozen=True): class ClaudeMessageDeltaEvent (line 220) | class ClaudeMessageDeltaEvent(BaseModel, frozen=True): class ClaudeMessageStopEvent (line 228) | class ClaudeMessageStopEvent(BaseModel, frozen=True): FILE: src/exo/api/types/ollama_api.py class OllamaToolFunction (line 16) | class OllamaToolFunction(BaseModel, frozen=True): class OllamaToolCall (line 22) | class OllamaToolCall(BaseModel, frozen=True): class OllamaMessage (line 28) | class OllamaMessage(BaseModel, frozen=True): class OllamaOptions (line 38) | class OllamaOptions(BaseModel, frozen=True): class OllamaChatRequest (line 47) | class OllamaChatRequest(BaseModel, frozen=True): class OllamaGenerateRequest (line 58) | class OllamaGenerateRequest(BaseModel, frozen=True): class OllamaGenerateResponse (line 70) | class OllamaGenerateResponse(BaseModel, frozen=True, strict=True): class OllamaShowRequest (line 87) | class OllamaShowRequest(BaseModel, frozen=True): class OllamaChatResponse (line 93) | class OllamaChatResponse(BaseModel, frozen=True, strict=True): class OllamaModelDetails (line 109) | class OllamaModelDetails(BaseModel, frozen=True, strict=True): class OllamaModelTag (line 116) | class OllamaModelTag(BaseModel, frozen=True, strict=True): class OllamaTagsResponse (line 125) | class OllamaTagsResponse(BaseModel, frozen=True, strict=True): class OllamaShowResponse (line 129) | class OllamaShowResponse(BaseModel, frozen=True, strict=True): class OllamaPsModel (line 137) | class OllamaPsModel(BaseModel, frozen=True, strict=True): class OllamaPsResponse (line 147) | class OllamaPsResponse(BaseModel, frozen=True, strict=True): FILE: src/exo/api/types/openai_responses.py class ResponseInputTextPart (line 23) | class ResponseInputTextPart(BaseModel, frozen=True): class ResponseOutputTextPart (line 30) | class ResponseOutputTextPart(BaseModel, frozen=True): class ResponseInputMessage (line 41) | class ResponseInputMessage(BaseModel, frozen=True): class FunctionCallInputItem (line 49) | class FunctionCallInputItem(BaseModel, frozen=True): class FunctionCallOutputInputItem (line 60) | class FunctionCallOutputInputItem(BaseModel, frozen=True): class Reasoning (line 75) | class Reasoning(BaseModel, frozen=True): class ResponsesRequest (line 82) | class ResponsesRequest(BaseModel, frozen=True): class ResponseOutputText (line 134) | class ResponseOutputText(BaseModel, frozen=True): class ResponseMessageItem (line 142) | class ResponseMessageItem(BaseModel, frozen=True): class ResponseFunctionCallItem (line 152) | class ResponseFunctionCallItem(BaseModel, frozen=True): class ResponseReasoningSummaryText (line 163) | class ResponseReasoningSummaryText(BaseModel, frozen=True): class ResponseReasoningItem (line 170) | class ResponseReasoningItem(BaseModel, frozen=True): class ResponseUsage (line 182) | class ResponseUsage(BaseModel, frozen=True): class ResponsesResponse (line 190) | class ResponsesResponse(BaseModel, frozen=True): class ResponseCreatedEvent (line 204) | class ResponseCreatedEvent(BaseModel, frozen=True): class ResponseInProgressEvent (line 212) | class ResponseInProgressEvent(BaseModel, frozen=True): class ResponseOutputItemAddedEvent (line 220) | class ResponseOutputItemAddedEvent(BaseModel, frozen=True): class ResponseContentPartAddedEvent (line 229) | class ResponseContentPartAddedEvent(BaseModel, frozen=True): class ResponseTextDeltaEvent (line 240) | class ResponseTextDeltaEvent(BaseModel, frozen=True): class ResponseTextDoneEvent (line 251) | class ResponseTextDoneEvent(BaseModel, frozen=True): class ResponseContentPartDoneEvent (line 262) | class ResponseContentPartDoneEvent(BaseModel, frozen=True): class ResponseOutputItemDoneEvent (line 273) | class ResponseOutputItemDoneEvent(BaseModel, frozen=True): class ResponseFunctionCallArgumentsDeltaEvent (line 282) | class ResponseFunctionCallArgumentsDeltaEvent(BaseModel, frozen=True): class ResponseFunctionCallArgumentsDoneEvent (line 294) | class ResponseFunctionCallArgumentsDoneEvent(BaseModel, frozen=True): class ResponseReasoningSummaryPartAddedEvent (line 307) | class ResponseReasoningSummaryPartAddedEvent(BaseModel, frozen=True): class ResponseReasoningSummaryTextDeltaEvent (line 320) | class ResponseReasoningSummaryTextDeltaEvent(BaseModel, frozen=True): class ResponseReasoningSummaryTextDoneEvent (line 333) | class ResponseReasoningSummaryTextDoneEvent(BaseModel, frozen=True): class ResponseReasoningSummaryPartDoneEvent (line 346) | class ResponseReasoningSummaryPartDoneEvent(BaseModel, frozen=True): class ResponseCompletedEvent (line 359) | class ResponseCompletedEvent(BaseModel, frozen=True): FILE: src/exo/download/coordinator.py class DownloadCoordinator (line 40) | class DownloadCoordinator: method __post_init__ (line 56) | def __post_init__(self) -> None: method _model_dir (line 59) | def _model_dir(self, model_id: ModelId) -> str: method _download_progress_callback (line 62) | async def _download_progress_callback( method run (line 99) | async def run(self) -> None: method shutdown (line 107) | def shutdown(self) -> None: method _command_processor (line 110) | async def _command_processor(self) -> None: method _cancel_download (line 125) | async def _cancel_download(self, model_id: ModelId) -> None: method _start_download (line 140) | async def _start_download(self, shard: ShardMetadata) -> None: method _start_download_task (line 215) | def _start_download_task( method _delete_download (line 258) | async def _delete_download(self, model_id: ModelId) -> None: method _emit_existing_download_progress (line 295) | async def _emit_existing_download_progress(self) -> None: FILE: src/exo/download/download_utils.py class HuggingFaceAuthenticationError (line 47) | class HuggingFaceAuthenticationError(Exception): class HuggingFaceRateLimitError (line 51) | class HuggingFaceRateLimitError(Exception): function _build_auth_error_message (line 55) | async def _build_auth_error_message(status_code: int, model_id: ModelId)... function trim_etag (line 72) | def trim_etag(etag: str) -> str: function map_repo_file_download_progress_to_download_progress_data (line 78) | def map_repo_file_download_progress_to_download_progress_data( function map_repo_download_progress_to_download_progress_data (line 93) | def map_repo_download_progress_to_download_progress_data( function resolve_model_in_path (line 113) | def resolve_model_in_path(model_id: ModelId) -> Path | None: function build_model_path (line 130) | def build_model_path(model_id: ModelId) -> Path: function resolve_model_path_for_repo (line 137) | async def resolve_model_path_for_repo(model_id: ModelId) -> Path: function ensure_models_dir (line 141) | async def ensure_models_dir() -> Path: function delete_model (line 146) | async def delete_model(model_id: ModelId) -> bool: function seed_models (line 163) | async def seed_models(seed_dir: str | Path): function _scan_model_directory (line 180) | def _scan_model_directory( function is_model_directory_complete (line 240) | def is_model_directory_complete(model_dir: Path) -> bool: function _build_file_list_from_local_directory (line 246) | async def _build_file_list_from_local_directory( function fetch_file_list_with_cache (line 269) | async def fetch_file_list_with_cache( function fetch_file_list_with_retry (line 338) | async def fetch_file_list_with_retry( function _fetch_file_list (line 361) | async def _fetch_file_list( function get_download_headers (line 396) | async def get_download_headers() -> dict[str, str]: function create_http_session (line 400) | def create_http_session( function calc_hash (line 433) | async def calc_hash(path: Path, hash_type: Literal["sha1", "sha256"] = "... function file_meta (line 444) | async def file_meta( function download_file_with_retry (line 481) | async def download_file_with_retry( function _download_file (line 522) | async def _download_file( function calculate_repo_progress (line 611) | def calculate_repo_progress( function get_weight_map (line 660) | async def get_weight_map(model_id: ModelId, revision: str = "main") -> d... function resolve_allow_patterns (line 692) | async def resolve_allow_patterns(shard: ShardMetadata) -> list[str]: function is_image_model (line 707) | def is_image_model(shard: ShardMetadata) -> bool: function get_downloaded_size (line 712) | async def get_downloaded_size(path: Path) -> int: function download_shard (line 721) | async def download_shard( FILE: src/exo/download/huggingface_utils.py function filter_repo_objects (line 13) | def filter_repo_objects[T]( function _add_wildcard_to_directories (line 55) | def _add_wildcard_to_directories(pattern: str) -> str: function get_hf_endpoint (line 61) | def get_hf_endpoint() -> str: function get_hf_home (line 65) | def get_hf_home() -> Path: function get_hf_token (line 70) | async def get_hf_token() -> str | None: function get_auth_headers (line 83) | async def get_auth_headers() -> dict[str, str]: function extract_layer_num (line 91) | def extract_layer_num(tensor_name: str) -> int | None: function get_allow_patterns (line 100) | def get_allow_patterns(weight_map: dict[str, str], shard: ShardMetadata)... FILE: src/exo/download/impl_shard_downloader.py function exo_shard_downloader (line 18) | def exo_shard_downloader( function build_base_shard (line 26) | async def build_base_shard(model_id: ModelId) -> ShardMetadata: function build_full_shard (line 38) | async def build_full_shard(model_id: ModelId) -> PipelineShardMetadata: class SingletonShardDownloader (line 50) | class SingletonShardDownloader(ShardDownloader): method __init__ (line 51) | def __init__(self, shard_downloader: ShardDownloader): method on_progress (line 55) | def on_progress( method ensure_shard (line 61) | async def ensure_shard( method get_shard_download_status (line 74) | async def get_shard_download_status( method get_shard_download_status_for_shard (line 80) | async def get_shard_download_status_for_shard( class ResumableShardDownloader (line 86) | class ResumableShardDownloader(ShardDownloader): method __init__ (line 87) | def __init__(self, max_parallel_downloads: int = 8, offline: bool = Fa... method on_progress_wrapper (line 94) | async def on_progress_wrapper( method on_progress (line 100) | def on_progress( method ensure_shard (line 106) | async def ensure_shard( method get_shard_download_status (line 120) | async def get_shard_download_status( method get_shard_download_status_for_shard (line 154) | async def get_shard_download_status_for_shard( FILE: src/exo/download/shard_downloader.py class ShardDownloader (line 18) | class ShardDownloader(ABC): method ensure_shard (line 20) | async def ensure_shard( method on_progress (line 34) | def on_progress( method get_shard_download_status (line 41) | async def get_shard_download_status( method get_shard_download_status_for_shard (line 52) | async def get_shard_download_status_for_shard( class NoopShardDownloader (line 57) | class NoopShardDownloader(ShardDownloader): method ensure_shard (line 58) | async def ensure_shard( method on_progress (line 63) | def on_progress( method get_shard_download_status (line 69) | async def get_shard_download_status( method get_shard_download_status_for_shard (line 77) | async def get_shard_download_status_for_shard( FILE: src/exo/download/tests/test_download_verification.py function model_id (line 24) | def model_id() -> ModelId: function temp_models_dir (line 29) | async def temp_models_dir(tmp_path: Path) -> AsyncIterator[Path]: class TestFileVerification (line 37) | class TestFileVerification: method test_redownload_when_file_size_changes_upstream (line 40) | async def test_redownload_when_file_size_changes_upstream( method test_skip_download_when_file_size_matches (line 102) | async def test_skip_download_when_file_size_matches( method test_offline_fallback_uses_local_file (line 141) | async def test_offline_fallback_uses_local_file( class TestFileListCache (line 176) | class TestFileListCache: method test_fetch_fresh_and_update_cache (line 179) | async def test_fetch_fresh_and_update_cache( method test_fallback_to_cache_when_fetch_fails (line 218) | async def test_fallback_to_cache_when_fetch_fails( method test_error_propagates_when_no_cache (line 248) | async def test_error_propagates_when_no_cache( class TestModelDeletion (line 266) | class TestModelDeletion: method test_delete_model_clears_cache (line 269) | async def test_delete_model_clears_cache( method test_delete_model_only_cache_exists (line 294) | async def test_delete_model_only_cache_exists( method test_delete_nonexistent_model (line 314) | async def test_delete_nonexistent_model( class TestProgressResetOnRedownload (line 327) | class TestProgressResetOnRedownload: method test_progress_resets_correctly_on_redownload (line 330) | async def test_progress_resets_correctly_on_redownload( method test_progress_accumulates_on_continuing_download (line 394) | async def test_progress_accumulates_on_continuing_download( FILE: src/exo/download/tests/test_offline_mode.py function model_id (line 21) | def model_id() -> ModelId: function temp_models_dir (line 26) | async def temp_models_dir(tmp_path: Path) -> AsyncIterator[Path]: class TestDownloadFileOffline (line 33) | class TestDownloadFileOffline: method test_returns_local_file_without_http_verification (line 36) | async def test_returns_local_file_without_http_verification( method test_raises_file_not_found_for_missing_file (line 63) | async def test_raises_file_not_found_for_missing_file( method test_returns_local_file_in_subdirectory (line 80) | async def test_returns_local_file_in_subdirectory( class TestDownloadFileWithRetryOffline (line 109) | class TestDownloadFileWithRetryOffline: method test_propagates_skip_internet_to_download_file (line 112) | async def test_propagates_skip_internet_to_download_file( method test_file_not_found_does_not_retry (line 138) | async def test_file_not_found_does_not_retry( class TestFetchFileListOffline (line 155) | class TestFetchFileListOffline: method test_uses_cached_file_list (line 158) | async def test_uses_cached_file_list( method test_falls_back_to_local_directory_scan (line 188) | async def test_falls_back_to_local_directory_scan( method test_raises_when_no_cache_and_no_local_files (line 224) | async def test_raises_when_no_cache_and_no_local_files( FILE: src/exo/download/tests/test_re_download.py function _make_shard (line 32) | def _make_shard(model_id: ModelId = MODEL_ID) -> ShardMetadata: class FakeShardDownloader (line 50) | class FakeShardDownloader(ShardDownloader): method __init__ (line 54) | def __init__(self) -> None: method on_progress (line 59) | def on_progress( method ensure_shard (line 65) | async def ensure_shard( method get_shard_download_status (line 88) | async def get_shard_download_status( method get_shard_download_status_for_shard (line 109) | async def get_shard_download_status_for_shard( function test_re_download_after_delete_completes (line 128) | async def test_re_download_after_delete_completes() -> None: function _wait_for_download_completed (line 195) | async def _wait_for_download_completed( FILE: src/exo/main.py class Node (line 31) | class Node: method create (line 46) | async def create(cls, args: "Args") -> Self: method run (line 139) | async def run(self): method shutdown (line 156) | def shutdown(self): method _elect_loop (line 164) | async def _elect_loop(self): function main (line 258) | def main(): class Args (line 298) | class Args(CamelCaseModel): method parse (line 311) | def parse(cls) -> Self: FILE: src/exo/master/image_store.py class StoredImage (line 9) | class StoredImage(BaseModel, frozen=True): class ImageStore (line 16) | class ImageStore: method __init__ (line 17) | def __init__(self, storage_dir: Path, default_expiry_seconds: int = 36... method store (line 23) | def store(self, image_bytes: bytes, content_type: str) -> StoredImage: method get (line 38) | def get(self, image_id: Id) -> StoredImage | None: method list_images (line 49) | def list_images(self) -> list[StoredImage]: method cleanup_expired (line 53) | def cleanup_expired(self) -> int: method _remove (line 66) | def _remove(self, image_id: Id) -> None: function _content_type_to_extension (line 72) | def _content_type_to_extension( FILE: src/exo/master/main.py class Master (line 68) | class Master: method __init__ (line 69) | def __init__( method run (line 96) | async def run(self): method shutdown (line 110) | async def shutdown(self): method _command_processor (line 114) | async def _command_processor(self) -> None: method _plan (line 362) | async def _plan(self) -> None: method _event_processor (line 383) | async def _event_processor(self) -> None: method _send_event (line 411) | async def _send_event(self, event: IndexedEvent): method _handle_traces_collected (line 422) | async def _handle_traces_collected(self, event: TracesCollected) -> None: method _merge_and_save_traces (line 435) | async def _merge_and_save_traces(self, task_id: TaskId) -> None: FILE: src/exo/master/placement.py function random_ephemeral_port (line 48) | def random_ephemeral_port() -> int: function add_instance_to_placements (line 53) | def add_instance_to_placements( function place_instance (line 63) | def place_instance( function delete_instance (line 206) | def delete_instance( function get_transition_events (line 217) | def get_transition_events( function cancel_unnecessary_downloads (line 257) | def cancel_unnecessary_downloads( FILE: src/exo/master/placement_utils.py function filter_cycles_by_memory (line 21) | def filter_cycles_by_memory( function get_smallest_cycles (line 40) | def get_smallest_cycles( function allocate_layers_proportionally (line 47) | def allocate_layers_proportionally( function _validate_cycle (line 78) | def _validate_cycle(cycle: Cycle) -> None: function _compute_total_memory (line 83) | def _compute_total_memory( function _allocate_and_validate_layers (line 96) | def _allocate_and_validate_layers( function get_shard_assignments_for_pipeline_parallel (line 125) | def get_shard_assignments_for_pipeline_parallel( function _get_shard_assignments_for_cfg_parallel (line 140) | def _get_shard_assignments_for_cfg_parallel( function _get_shard_assignments_for_pure_pipeline (line 203) | def _get_shard_assignments_for_pure_pipeline( function get_shard_assignments_for_tensor_parallel (line 243) | def get_shard_assignments_for_tensor_parallel( function get_shard_assignments (line 276) | def get_shard_assignments( function get_mlx_jaccl_devices_matrix (line 296) | def get_mlx_jaccl_devices_matrix( function _find_connection_ip (line 328) | def _find_connection_ip( function _find_ip_prioritised (line 339) | def _find_ip_prioritised( function get_mlx_ring_hosts_by_node (line 381) | def get_mlx_ring_hosts_by_node( function get_mlx_jaccl_coordinators (line 431) | def get_mlx_jaccl_coordinators( FILE: src/exo/master/tests/conftest.py function create_node_memory (line 10) | def create_node_memory(memory: int) -> MemoryUsage: function create_node_network (line 19) | def create_node_network() -> NodeNetworkInfo: function create_socket_connection (line 28) | def create_socket_connection(ip: int, sink_port: int = 1234) -> SocketCo... function create_rdma_connection (line 34) | def create_rdma_connection(iface: int) -> RDMAConnection: FILE: src/exo/master/tests/test_master.py function test_master (line 45) | async def test_master(): FILE: src/exo/master/tests/test_placement.py function instance (line 40) | def instance() -> Instance: function model_card (line 52) | def model_card() -> ModelCard: function place_instance_command (line 63) | def place_instance_command(model_card: ModelCard) -> PlaceInstance: function test_get_instance_placements_create_instance (line 81) | def test_get_instance_placements_create_instance( function test_get_instance_placements_one_node_exact_fit (line 166) | def test_get_instance_placements_one_node_exact_fit() -> None: function test_get_instance_placements_one_node_fits_with_extra_memory (line 193) | def test_get_instance_placements_one_node_fits_with_extra_memory() -> None: function test_get_instance_placements_one_node_not_fit (line 220) | def test_get_instance_placements_one_node_not_fit() -> None: function test_get_transition_events_no_change (line 241) | def test_get_transition_events_no_change(instance: Instance): function test_get_transition_events_create_instance (line 254) | def test_get_transition_events_create_instance(instance: Instance): function test_get_transition_events_delete_instance (line 268) | def test_get_transition_events_delete_instance(instance: Instance): function test_placement_selects_leaf_nodes (line 283) | def test_placement_selects_leaf_nodes( function test_tensor_rdma_backend_connectivity_matrix (line 352) | def test_tensor_rdma_backend_connectivity_matrix( function _make_task (line 467) | def _make_task( function test_get_transition_events_delete_instance_cancels_running_tasks (line 483) | def test_get_transition_events_delete_instance_cancels_running_tasks( function test_get_transition_events_delete_instance_cancels_pending_tasks (line 505) | def test_get_transition_events_delete_instance_cancels_pending_tasks( function test_get_transition_events_delete_instance_ignores_completed_tasks (line 526) | def test_get_transition_events_delete_instance_ignores_completed_tasks( function test_get_transition_events_delete_instance_cancels_only_matching_tasks (line 551) | def test_get_transition_events_delete_instance_cancels_only_matching_tasks( FILE: src/exo/master/tests/test_placement_utils.py function test_filter_cycles_by_memory (line 31) | def test_filter_cycles_by_memory(): function test_filter_cycles_by_insufficient_memory (line 65) | def test_filter_cycles_by_insufficient_memory(): function test_filter_multiple_cycles_by_memory (line 95) | def test_filter_multiple_cycles_by_memory(): function test_get_smallest_cycles (line 146) | def test_get_smallest_cycles(): function test_get_shard_assignments (line 197) | def test_get_shard_assignments( function test_get_mlx_jaccl_coordinators (line 280) | def test_get_mlx_jaccl_coordinators(): class TestAllocateLayersProportionally (line 387) | class TestAllocateLayersProportionally: method test_empty_node_list_raises (line 388) | def test_empty_node_list_raises(self): method test_zero_layers_raises (line 392) | def test_zero_layers_raises(self): method test_negative_layers_raises (line 396) | def test_negative_layers_raises(self): method test_fewer_layers_than_nodes_raises (line 400) | def test_fewer_layers_than_nodes_raises(self): method test_equal_distribution (line 406) | def test_equal_distribution(self): method test_proportional_distribution (line 413) | def test_proportional_distribution(self): method test_extreme_imbalance_ensures_minimum (line 420) | def test_extreme_imbalance_ensures_minimum(self): method test_single_node_gets_all_layers (line 429) | def test_single_node_gets_all_layers(self): method test_minimum_viable_allocation (line 433) | def test_minimum_viable_allocation(self): function test_get_shard_assignments_insufficient_memory_raises (line 441) | def test_get_shard_assignments_insufficient_memory_raises(): class TestCfgParallelPlacement (line 497) | class TestCfgParallelPlacement: method _create_ring_topology (line 498) | def _create_ring_topology(self, node_ids: list[NodeId]) -> Topology: method test_two_nodes_cfg_model_uses_cfg_parallel (line 514) | def test_two_nodes_cfg_model_uses_cfg_parallel(self): method test_four_nodes_cfg_model_uses_hybrid (line 561) | def test_four_nodes_cfg_model_uses_hybrid(self): method test_three_nodes_cfg_model_uses_sequential_cfg (line 610) | def test_three_nodes_cfg_model_uses_sequential_cfg(self): method test_two_nodes_non_cfg_model_uses_pipeline (line 641) | def test_two_nodes_non_cfg_model_uses_pipeline(self): FILE: src/exo/master/tests/test_topology.py function topology (line 10) | def topology() -> Topology: function socket_connection (line 15) | def socket_connection() -> SocketConnection: function test_add_node (line 21) | def test_add_node(topology: Topology): function test_add_connection (line 32) | def test_add_connection(topology: Topology, socket_connection: SocketCon... function test_remove_connection_still_connected (line 52) | def test_remove_connection_still_connected( function test_remove_node_still_connected (line 71) | def test_remove_node_still_connected( function test_list_nodes (line 91) | def test_list_nodes(topology: Topology, socket_connection: SocketConnect... FILE: src/exo/routing/connection_message.py class ConnectionMessage (line 9) | class ConnectionMessage(CamelCaseModel): method from_update (line 14) | def from_update(cls, update: PyFromSwarm.Connection) -> "ConnectionMes... FILE: src/exo/routing/event_router.py class EventRouter (line 24) | class EventRouter: method run (line 46) | async def run(self): method _simple_retry (line 57) | async def _simple_retry(self): method sender (line 66) | def sender(self) -> Sender[Event]: method receiver (line 74) | def receiver(self) -> Receiver[IndexedEvent]: method shutdown (line 79) | def shutdown(self) -> None: method _ingest (line 82) | async def _ingest(self, system_id: SystemId, recv: Receiver[Event]): method _run_ext_in (line 96) | async def _run_ext_in(self): method _nack_request (line 134) | async def _nack_request(self, since_idx: int) -> None: FILE: src/exo/routing/router.py class TopicRouter (line 38) | class TopicRouter[T: CamelCaseModel]: method __init__ (line 39) | def __init__( method run (line 52) | async def run(self): method shutdown (line 68) | async def shutdown(self): method publish (line 76) | async def publish(self, item: T): method publish_bytes (line 90) | async def publish_bytes(self, data: bytes): method new_sender (line 93) | def new_sender(self) -> Sender[T]: method _send_out (line 96) | async def _send_out(self, item: T): class Router (line 103) | class Router: method create (line 105) | def create(cls, identity: Keypair) -> "Router": method __init__ (line 108) | def __init__(self, handle: NetworkingHandle): method register_topic (line 117) | async def register_topic[T: CamelCaseModel](self, topic: TypedTopic[T]): method sender (line 128) | def sender[T: CamelCaseModel](self, topic: TypedTopic[T]) -> Sender[T]: method receiver (line 136) | def receiver[T: CamelCaseModel](self, topic: TypedTopic[T]) -> Receive... method run (line 149) | async def run(self): method shutdown (line 168) | async def shutdown(self): method _networking_subscribe (line 172) | async def _networking_subscribe(self, topic: str): method _networking_unsubscribe (line 176) | async def _networking_unsubscribe(self, topic: str): method _networking_recv (line 180) | async def _networking_recv(self): method _networking_publish (line 217) | async def _networking_publish(self): function get_node_id_keypair (line 237) | def get_node_id_keypair( FILE: src/exo/routing/tests/test_event_buffer.py function make_indexed_event (line 7) | def make_indexed_event(idx: int) -> tuple[int, Event]: function buffer (line 13) | def buffer() -> OrderedBuffer[Event]: function test_initial_state (line 19) | async def test_initial_state(buffer: OrderedBuffer[Event]): function test_ingest_and_drain_sequential_events (line 27) | async def test_ingest_and_drain_sequential_events(buffer: OrderedBuffer[... function test_ingest_out_of_order_events (line 39) | async def test_ingest_out_of_order_events(buffer: OrderedBuffer[Event]): function test_drain_with_gap_in_sequence (line 55) | async def test_drain_with_gap_in_sequence(buffer: OrderedBuffer[Event]): function test_fill_gap_and_drain_remaining (line 72) | async def test_fill_gap_and_drain_remaining(buffer: OrderedBuffer[Event]): function test_ingest_drops_duplicate_indices (line 91) | async def test_ingest_drops_duplicate_indices(buffer: OrderedBuffer[Even... function test_ingest_drops_stale_events (line 110) | async def test_ingest_drops_stale_events(buffer: OrderedBuffer[Event]): function test_drain_and_ingest_with_new_sequence (line 128) | async def test_drain_and_ingest_with_new_sequence(buffer: OrderedBuffer[... FILE: src/exo/routing/topics.py class PublishPolicy (line 14) | class PublishPolicy(str, Enum): class TypedTopic (line 24) | class TypedTopic[T: CamelCaseModel]: method serialize (line 33) | def serialize(t: T) -> bytes: method deserialize (line 36) | def deserialize(self, b: bytes) -> T: FILE: src/exo/shared/apply.py function event_apply (line 58) | def event_apply(event: Event, state: State) -> State: function apply (line 96) | def apply(state: State, event: IndexedEvent) -> State: function apply_node_download_progress (line 107) | def apply_node_download_progress(event: NodeDownloadProgress, state: Sta... function apply_task_created (line 139) | def apply_task_created(event: TaskCreated, state: State) -> State: function apply_task_deleted (line 144) | def apply_task_deleted(event: TaskDeleted, state: State) -> State: function apply_task_status_updated (line 151) | def apply_task_status_updated(event: TaskStatusUpdated, state: State) ->... function apply_task_failed (line 168) | def apply_task_failed(event: TaskFailed, state: State) -> State: function apply_instance_created (line 180) | def apply_instance_created(event: InstanceCreated, state: State) -> State: function apply_instance_deleted (line 189) | def apply_instance_deleted(event: InstanceDeleted, state: State) -> State: function apply_runner_status_updated (line 196) | def apply_runner_status_updated(event: RunnerStatusUpdated, state: State... function apply_node_timed_out (line 209) | def apply_node_timed_out(event: NodeTimedOut, state: State) -> State: function apply_node_gathered_info (line 271) | def apply_node_gathered_info(event: NodeGatheredInfo, state: State) -> S... function apply_topology_edge_created (line 376) | def apply_topology_edge_created(event: TopologyEdgeCreated, state: State... function apply_topology_edge_deleted (line 382) | def apply_topology_edge_deleted(event: TopologyEdgeDeleted, state: State... FILE: src/exo/shared/constants.py function _get_xdg_dir (line 10) | def _get_xdg_dir(env_var: str, fallback: str) -> Path: FILE: src/exo/shared/election.py class ElectionMessage (line 21) | class ElectionMessage(CamelCaseModel): method __lt__ (line 28) | def __lt__(self, other: Self) -> bool: class ElectionResult (line 42) | class ElectionResult(CamelCaseModel): class Election (line 48) | class Election: method __init__ (line 49) | def __init__( method run (line 86) | async def run(self): method elect (line 111) | async def elect(self, em: ElectionMessage) -> None: method shutdown (line 124) | async def shutdown(self) -> None: method _election_receiver (line 127) | async def _election_receiver(self) -> None: method _connection_receiver (line 159) | async def _connection_receiver(self) -> None: method _command_counter (line 182) | async def _command_counter(self) -> None: method _campaign (line 187) | async def _campaign( method _election_status (line 254) | def _election_status(self, clock: int | None = None) -> ElectionMessage: FILE: src/exo/shared/logging.py function _zstd_compress (line 14) | def _zstd_compress(filepath: str) -> None: function _once_then_never (line 23) | def _once_then_never() -> Iterator[bool]: class InterceptLogger (line 29) | class InterceptLogger(HypercornLogger): method __init__ (line 30) | def __init__(self, config: Config): class _InterceptHandler (line 36) | class _InterceptHandler(logging.Handler): method emit (line 37) | def emit(self, record: logging.LogRecord): function logger_setup (line 46) | def logger_setup(log_file: Path | None, verbosity: int = 0): function logger_cleanup (line 88) | def logger_cleanup(): FILE: src/exo/shared/models/model_cards.py function _refresh_card_cache (line 42) | async def _refresh_card_cache(): function _is_image_card (line 53) | def _is_image_card(card: "ModelCard") -> bool: function get_model_cards (line 57) | async def get_model_cards() -> list["ModelCard"]: class ModelTask (line 65) | class ModelTask(str, Enum): class ComponentInfo (line 71) | class ComponentInfo(CamelCaseModel): class ModelCard (line 80) | class ModelCard(CamelCaseModel): method _validate_tasks (line 98) | def _validate_tasks(cls, v: list[str | ModelTask]) -> list[ModelTask]: method save (line 101) | async def save(self, path: Path) -> None: method save_to_custom_dir (line 107) | async def save_to_custom_dir(self) -> None: method load_from_path (line 112) | async def load_from_path(path: Path) -> "ModelCard": method load (line 119) | async def load(model_id: ModelId) -> "ModelCard": method fetch_from_hf (line 128) | async def fetch_from_hf(model_id: ModelId) -> "ModelCard": function delete_custom_card (line 150) | async def delete_custom_card(model_id: ModelId) -> bool: function is_custom_card (line 160) | def is_custom_card(model_id: ModelId) -> bool: class ConfigData (line 170) | class ConfigData(BaseModel): method supports_tensor (line 188) | def supports_tensor(self) -> bool: method defer_to_text_config (line 207) | def defer_to_text_config(cls, data: dict[str, Any]): function fetch_config_data (line 229) | async def fetch_config_data(model_id: ModelId) -> ConfigData: function fetch_safetensors_size (line 251) | async def fetch_safetensors_size(model_id: ModelId) -> Memory: FILE: src/exo/shared/tests/conftest.py function event_loop (line 16) | def event_loop() -> Generator[asyncio.AbstractEventLoop, None, None]: function reset_event_loop (line 25) | def reset_event_loop(): function get_pipeline_shard_metadata (line 30) | def get_pipeline_shard_metadata( function caplog (line 51) | def caplog(caplog: LogCaptureFixture): FILE: src/exo/shared/tests/test_apply/test_apply_node_download.py function test_apply_node_download_progress (line 11) | def test_apply_node_download_progress(): function test_apply_two_node_download_progress (line 27) | def test_apply_two_node_download_progress(): FILE: src/exo/shared/tests/test_apply/test_apply_runner_deleted.py function test_apply_runner_shutdown_removes_runner (line 7) | def test_apply_runner_shutdown_removes_runner(): function test_apply_runner_status_updated_adds_runner (line 18) | def test_apply_runner_status_updated_adds_runner(): FILE: src/exo/shared/tests/test_election.py function em (line 15) | def em( function fast_election_timeout (line 45) | def fast_election_timeout(monkeypatch: pytest.MonkeyPatch): function test_single_round_broadcasts_and_updates_seniority_on_self_win (line 50) | async def test_single_round_broadcasts_and_updates_seniority_on_self_win... function test_peer_with_higher_seniority_wins_and_we_switch_master (line 106) | async def test_peer_with_higher_seniority_wins_and_we_switch_master() ->... function test_ignores_older_messages (line 160) | async def test_ignores_older_messages() -> None: function test_two_rounds_emit_two_broadcasts_and_increment_clock (line 209) | async def test_two_rounds_emit_two_broadcasts_and_increment_clock() -> N... function test_promotion_new_seniority_counts_participants (line 255) | async def test_promotion_new_seniority_counts_participants() -> None: function test_connection_message_triggers_new_round_broadcast (line 304) | async def test_connection_message_triggers_new_round_broadcast() -> None: function test_tie_breaker_prefers_node_with_more_commands_seen (line 349) | async def test_tie_breaker_prefers_node_with_more_commands_seen() -> None: FILE: src/exo/shared/tests/test_node_id_persistence.py function _get_keypair_concurrent_subprocess_task (line 19) | def _get_keypair_concurrent_subprocess_task( function _get_keypair_concurrent (line 29) | def _get_keypair_concurrent(num_procs: int) -> bytes: function _delete_if_exists (line 72) | def _delete_if_exists(p: str | bytes | os.PathLike[str] | os.PathLike[by... function test_node_id_fetching (line 78) | def test_node_id_fetching(caplog: LogCaptureFixture): FILE: src/exo/shared/tests/test_resolve_reasoning_params.py function test_both_none_returns_none_none (line 6) | def test_both_none_returns_none_none() -> None: function test_both_set_passes_through_unchanged (line 10) | def test_both_set_passes_through_unchanged() -> None: function test_enable_thinking_true_derives_medium (line 16) | def test_enable_thinking_true_derives_medium() -> None: function test_enable_thinking_false_derives_none (line 20) | def test_enable_thinking_false_derives_none() -> None: function test_reasoning_effort_none_derives_thinking_false (line 24) | def test_reasoning_effort_none_derives_thinking_false() -> None: function test_non_none_effort_derives_thinking_true (line 29) | def test_non_none_effort_derives_thinking_true(effort: str) -> None: FILE: src/exo/shared/tests/test_state_serialization.py function test_state_serialization_roundtrip (line 7) | def test_state_serialization_roundtrip() -> None: FILE: src/exo/shared/tests/test_xdg_paths.py function test_xdg_paths_on_linux (line 9) | def test_xdg_paths_on_linux(): function test_xdg_default_paths_on_linux (line 35) | def test_xdg_default_paths_on_linux(): function test_legacy_exo_home_takes_precedence (line 59) | def test_legacy_exo_home_takes_precedence(): function test_macos_uses_traditional_paths (line 80) | def test_macos_uses_traditional_paths(): function test_node_id_in_config_dir (line 100) | def test_node_id_in_config_dir(): function test_models_in_data_dir (line 107) | def test_models_in_data_dir(): FILE: src/exo/shared/topology.py class TopologySnapshot (line 23) | class TopologySnapshot(BaseModel): class Topology (line 33) | class Topology: method to_snapshot (line 39) | def to_snapshot(self) -> TopologySnapshot: method from_snapshot (line 45) | def from_snapshot(cls, snapshot: TopologySnapshot) -> "Topology": method add_node (line 61) | def add_node(self, node_id: NodeId) -> None: method node_is_leaf (line 67) | def node_is_leaf(self, node_id: NodeId) -> bool: method neighbours (line 73) | def neighbours(self, node_id: NodeId) -> list[NodeId]: method out_edges (line 79) | def out_edges(self, node_id: NodeId) -> Iterable[Connection]: method contains_node (line 89) | def contains_node(self, node_id: NodeId) -> bool: method add_connection (line 92) | def add_connection(self, conn: Connection) -> None: method get_all_connections_between (line 108) | def get_all_connections_between( method list_nodes (line 123) | def list_nodes(self) -> Iterable[NodeId]: method map_connections (line 126) | def map_connections( method list_connections (line 140) | def list_connections( method remove_node (line 154) | def remove_node(self, node_id: NodeId) -> None: method replace_all_out_rdma_connections (line 163) | def replace_all_out_rdma_connections( method remove_connection (line 172) | def remove_connection(self, conn: Connection) -> None: method get_cycles (line 184) | def get_cycles(self) -> list[Cycle]: method get_rdma_cycles (line 196) | def get_rdma_cycles(self) -> list[Cycle]: method get_subgraph_from_nodes (line 219) | def get_subgraph_from_nodes(self, node_ids: list[NodeId]) -> "Topology": method is_rdma_cycle (line 228) | def is_rdma_cycle(self, cycle: Cycle) -> bool: method get_thunderbolt_bridge_cycles (line 244) | def get_thunderbolt_bridge_cycles( function _get_ips_with_interface_type (line 295) | def _get_ips_with_interface_type( FILE: src/exo/shared/tracing.py class TraceEvent (line 22) | class TraceEvent: class CategoryStats (line 32) | class CategoryStats: method add (line 38) | def add(self, duration_us: int) -> None: method avg_us (line 49) | def avg_us(self) -> float: class TraceStats (line 55) | class TraceStats: function _record_span (line 65) | def _record_span( function trace (line 80) | def trace( function get_trace_buffer (line 122) | def get_trace_buffer() -> list[TraceEvent]: function clear_trace_buffer (line 126) | def clear_trace_buffer() -> None: function export_trace (line 130) | def export_trace(traces: list[TraceEvent], output_path: Path) -> None: function load_trace_file (line 169) | def load_trace_file(path: Path) -> list[TraceEvent]: function compute_stats (line 211) | def compute_stats(traces: list[TraceEvent]) -> TraceStats: FILE: src/exo/shared/types/chunks.py class BaseChunk (line 18) | class BaseChunk(TaggedModel): class TokenChunk (line 22) | class TokenChunk(BaseChunk): class ErrorChunk (line 33) | class ErrorChunk(BaseChunk): class ToolCallChunk (line 38) | class ToolCallChunk(BaseChunk): class ImageChunk (line 45) | class ImageChunk(BaseChunk): method __repr_args__ (line 58) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class InputImageChunk (line 66) | class InputImageChunk(BaseChunk): method __repr_args__ (line 72) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class PrefillProgressChunk (line 80) | class PrefillProgressChunk(BaseChunk): FILE: src/exo/shared/types/commands.py class BaseCommand (line 16) | class BaseCommand(TaggedModel): class TestCommand (line 20) | class TestCommand(BaseCommand): class TextGeneration (line 24) | class TextGeneration(BaseCommand): class ImageGeneration (line 28) | class ImageGeneration(BaseCommand): class ImageEdits (line 32) | class ImageEdits(BaseCommand): class PlaceInstance (line 36) | class PlaceInstance(BaseCommand): class CreateInstance (line 43) | class CreateInstance(BaseCommand): class DeleteInstance (line 47) | class DeleteInstance(BaseCommand): class TaskCancelled (line 51) | class TaskCancelled(BaseCommand): class TaskFinished (line 55) | class TaskFinished(BaseCommand): class SendInputChunk (line 59) | class SendInputChunk(BaseCommand): class RequestEventLog (line 65) | class RequestEventLog(BaseCommand): class StartDownload (line 69) | class StartDownload(BaseCommand): class DeleteDownload (line 74) | class DeleteDownload(BaseCommand): class CancelDownload (line 79) | class CancelDownload(BaseCommand): class ForwarderCommand (line 102) | class ForwarderCommand(CamelCaseModel): class ForwarderDownloadCommand (line 107) | class ForwarderDownloadCommand(CamelCaseModel): FILE: src/exo/shared/types/common.py class Id (line 10) | class Id(str): method __new__ (line 11) | def __new__(cls, value: str | None = None) -> Self: method __get_pydantic_core_schema__ (line 15) | def __get_pydantic_core_schema__( class NodeId (line 24) | class NodeId(Id): class SystemId (line 28) | class SystemId(Id): class ModelId (line 32) | class ModelId(Id): method normalize (line 33) | def normalize(self) -> str: method short (line 36) | def short(self) -> str: class SessionId (line 40) | class SessionId(CamelCaseModel): class CommandId (line 45) | class CommandId(Id): class Host (line 49) | class Host(CamelCaseModel): method __str__ (line 53) | def __str__(self) -> str: method check_port (line 58) | def check_port(cls, v: int) -> int: FILE: src/exo/shared/types/events.py class EventId (line 17) | class EventId(Id): class BaseEvent (line 23) | class BaseEvent(TaggedModel): class TestEvent (line 29) | class TestEvent(BaseEvent): class TaskCreated (line 33) | class TaskCreated(BaseEvent): class TaskAcknowledged (line 38) | class TaskAcknowledged(BaseEvent): class TaskDeleted (line 42) | class TaskDeleted(BaseEvent): class TaskStatusUpdated (line 46) | class TaskStatusUpdated(BaseEvent): class TaskFailed (line 51) | class TaskFailed(BaseEvent): class InstanceCreated (line 57) | class InstanceCreated(BaseEvent): method __eq__ (line 60) | def __eq__(self, other: object) -> bool: class InstanceDeleted (line 67) | class InstanceDeleted(BaseEvent): class RunnerStatusUpdated (line 71) | class RunnerStatusUpdated(BaseEvent): class NodeTimedOut (line 76) | class NodeTimedOut(BaseEvent): class NodeGatheredInfo (line 81) | class NodeGatheredInfo(BaseEvent): class NodeDownloadProgress (line 87) | class NodeDownloadProgress(BaseEvent): class ChunkGenerated (line 91) | class ChunkGenerated(BaseEvent): class InputChunkReceived (line 96) | class InputChunkReceived(BaseEvent): class TopologyEdgeCreated (line 101) | class TopologyEdgeCreated(BaseEvent): class TopologyEdgeDeleted (line 105) | class TopologyEdgeDeleted(BaseEvent): class TraceEventData (line 110) | class TraceEventData(FrozenModel): class TracesCollected (line 119) | class TracesCollected(BaseEvent): class TracesMerged (line 126) | class TracesMerged(BaseEvent): class IndexedEvent (line 153) | class IndexedEvent(CamelCaseModel): class GlobalForwarderEvent (line 160) | class GlobalForwarderEvent(CamelCaseModel): class LocalForwarderEvent (line 169) | class LocalForwarderEvent(CamelCaseModel): FILE: src/exo/shared/types/memory.py class Memory (line 7) | class Memory(FrozenModel): method from_bytes (line 11) | def from_bytes(cls, val: int) -> Self: method in_kb (line 16) | def in_kb(self) -> int: method in_kb (line 21) | def in_kb(self, val: int): method from_kb (line 26) | def from_kb(cls, val: int) -> Self: method from_float_kb (line 31) | def from_float_kb(cls, val: float) -> Self: method in_mb (line 36) | def in_mb(self) -> int: method in_mb (line 41) | def in_mb(self, val: int): method in_float_mb (line 46) | def in_float_mb(self) -> float: method in_float_mb (line 51) | def in_float_mb(self, val: float): method from_mb (line 56) | def from_mb(cls, val: float) -> Self: method from_gb (line 61) | def from_gb(cls, val: float) -> Self: method in_gb (line 66) | def in_gb(self) -> float: method __add__ (line 70) | def __add__(self, other: object) -> "Memory": method __radd__ (line 75) | def __radd__(self, other: object) -> "Memory": method __sub__ (line 80) | def __sub__(self, other: object) -> "Memory": method __mul__ (line 85) | def __mul__(self, other: int | float): method __rmul__ (line 88) | def __rmul__(self, other: int | float): method __truediv__ (line 92) | def __truediv__(self, other: "Memory") -> float: ... method __truediv__ (line 94) | def __truediv__(self, other: int) -> "Memory": ... method __truediv__ (line 96) | def __truediv__(self, other: float) -> "Memory": ... method __truediv__ (line 97) | def __truediv__(self, other: object) -> "Memory | float": method __floordiv__ (line 104) | def __floordiv__(self, other: object) -> "Memory": method __lt__ (line 109) | def __lt__(self, other: object) -> bool: method __le__ (line 114) | def __le__(self, other: object) -> bool: method __gt__ (line 119) | def __gt__(self, other: object) -> bool: method __ge__ (line 124) | def __ge__(self, other: object) -> bool: method __eq__ (line 129) | def __eq__(self, other: object) -> bool: method __repr__ (line 134) | def __repr__(self) -> str: method __str__ (line 137) | def __str__(self) -> str: FILE: src/exo/shared/types/mlx.py class Model (line 23) | class Model(nn.Module): method __call__ (line 26) | def __call__( FILE: src/exo/shared/types/multiaddr.py class Multiaddr (line 7) | class Multiaddr(BaseModel): method validate_format (line 19) | def validate_format(cls, v: str) -> str: method address_type (line 29) | def address_type(self) -> str: method ipv6_address (line 36) | def ipv6_address(self) -> str: method ipv4_address (line 45) | def ipv4_address(self) -> str: method ip_address (line 55) | def ip_address(self) -> str: method port (line 60) | def port(self) -> int: method __str__ (line 68) | def __str__(self) -> str: FILE: src/exo/shared/types/profiling.py class MemoryUsage (line 13) | class MemoryUsage(CamelCaseModel): method from_bytes (line 20) | def from_bytes( method from_psutil (line 31) | def from_psutil(cls, *, override_memory: int | None) -> Self: class DiskUsage (line 43) | class DiskUsage(CamelCaseModel): method from_path (line 50) | def from_path(cls, path: Path) -> Self: class SystemPerformanceProfile (line 59) | class SystemPerformanceProfile(CamelCaseModel): class NetworkInterfaceInfo (line 72) | class NetworkInterfaceInfo(CamelCaseModel): class NodeIdentity (line 78) | class NodeIdentity(CamelCaseModel): class NodeNetworkInfo (line 88) | class NodeNetworkInfo(CamelCaseModel): class NodeThunderboltInfo (line 94) | class NodeThunderboltInfo(CamelCaseModel): class NodeRdmaCtlStatus (line 100) | class NodeRdmaCtlStatus(CamelCaseModel): class ThunderboltBridgeStatus (line 106) | class ThunderboltBridgeStatus(CamelCaseModel): FILE: src/exo/shared/types/state.py class State (line 27) | class State(CamelCaseModel): method _encode_topology (line 65) | def _encode_topology(self, value: Topology) -> TopologySnapshot: method _deserialize_topology (line 70) | def _deserialize_topology(cls, value: object) -> Topology: # noqa: D4... FILE: src/exo/shared/types/tasks.py class TaskId (line 17) | class TaskId(Id): class TaskStatus (line 24) | class TaskStatus(str, Enum): class BaseTask (line 33) | class BaseTask(TaggedModel): class CreateRunner (line 39) | class CreateRunner(BaseTask): # emitted by Worker class DownloadModel (line 43) | class DownloadModel(BaseTask): # emitted by Worker class LoadModel (line 47) | class LoadModel(BaseTask): # emitted by Worker class ConnectToGroup (line 51) | class ConnectToGroup(BaseTask): # emitted by Worker class StartWarmup (line 55) | class StartWarmup(BaseTask): # emitted by Worker class TextGeneration (line 59) | class TextGeneration(BaseTask): # emitted by Master class CancelTask (line 67) | class CancelTask(BaseTask): class ImageGeneration (line 72) | class ImageGeneration(BaseTask): # emitted by Master class ImageEdits (line 80) | class ImageEdits(BaseTask): # emitted by Master class Shutdown (line 88) | class Shutdown(BaseTask): # emitted by Worker FILE: src/exo/shared/types/text_generation.py function resolve_reasoning_params (line 17) | def resolve_reasoning_params( class InputMessage (line 39) | class InputMessage(BaseModel, frozen=True): class TextGenerationTaskParams (line 46) | class TextGenerationTaskParams(BaseModel, frozen=True): FILE: src/exo/shared/types/thunderbolt.py class ThunderboltConnection (line 7) | class ThunderboltConnection(CamelCaseModel): class ThunderboltIdentifier (line 12) | class ThunderboltIdentifier(CamelCaseModel): class _ReceptacleTag (line 21) | class _ReceptacleTag(BaseModel, extra="ignore"): class _ConnectivityItem (line 26) | class _ConnectivityItem(BaseModel, extra="ignore"): class ThunderboltConnectivityData (line 30) | class ThunderboltConnectivityData(BaseModel, extra="ignore"): method ident (line 35) | def ident(self, ifaces: dict[str, str]) -> ThunderboltIdentifier | None: method conn (line 52) | def conn(self) -> ThunderboltConnection | None: class ThunderboltConnectivity (line 72) | class ThunderboltConnectivity(BaseModel, extra="ignore"): method gather (line 76) | async def gather(cls) -> list[ThunderboltConnectivityData] | None: FILE: src/exo/shared/types/topology.py class Cycle (line 10) | class Cycle: method __len__ (line 13) | def __len__(self) -> int: method __iter__ (line 16) | def __iter__(self) -> Iterator[NodeId]: class RDMAConnection (line 20) | class RDMAConnection(FrozenModel): class SocketConnection (line 25) | class SocketConnection(FrozenModel): method __hash__ (line 28) | def __hash__(self): class Connection (line 32) | class Connection(FrozenModel): FILE: src/exo/shared/types/worker/downloads.py class DownloadProgressData (line 12) | class DownloadProgressData(CamelCaseModel): class BaseDownloadProgress (line 26) | class BaseDownloadProgress(TaggedModel): class DownloadPending (line 32) | class DownloadPending(BaseDownloadProgress): class DownloadCompleted (line 37) | class DownloadCompleted(BaseDownloadProgress): class DownloadFailed (line 42) | class DownloadFailed(BaseDownloadProgress): class DownloadOngoing (line 46) | class DownloadOngoing(BaseDownloadProgress): class ModelSafetensorsIndexMetadata (line 55) | class ModelSafetensorsIndexMetadata(BaseModel): class ModelSafetensorsIndex (line 59) | class ModelSafetensorsIndex(BaseModel): class FileListEntry (line 64) | class FileListEntry(BaseModel): class RepoFileDownloadProgress (line 70) | class RepoFileDownloadProgress(BaseModel): class RepoDownloadProgress (line 85) | class RepoDownloadProgress(BaseModel): FILE: src/exo/shared/types/worker/instances.py class InstanceId (line 11) | class InstanceId(Id): class InstanceMeta (line 15) | class InstanceMeta(str, Enum): class BaseInstance (line 20) | class BaseInstance(TaggedModel): method shard (line 24) | def shard(self, runner_id: RunnerId) -> ShardMetadata | None: class MlxRingInstance (line 28) | class MlxRingInstance(BaseInstance): class MlxJacclInstance (line 33) | class MlxJacclInstance(BaseInstance): class BoundInstance (line 42) | class BoundInstance(CamelCaseModel): method bound_shard (line 48) | def bound_shard(self) -> ShardMetadata: method is_image_model (line 54) | def is_image_model(self) -> bool: method validate_shard_exists (line 61) | def validate_shard_exists(self) -> "BoundInstance": FILE: src/exo/shared/types/worker/runner_response.py class BaseRunnerResponse (line 15) | class BaseRunnerResponse(TaggedModel): class TokenizedResponse (line 19) | class TokenizedResponse(BaseRunnerResponse): class GenerationResponse (line 23) | class GenerationResponse(BaseRunnerResponse): class ImageGenerationResponse (line 34) | class ImageGenerationResponse(BaseRunnerResponse): method __repr_args__ (line 40) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class PartialImageResponse (line 48) | class PartialImageResponse(BaseRunnerResponse): method __repr_args__ (line 55) | def __repr_args__(self) -> Generator[tuple[str, Any], None, None]: class ToolCallResponse (line 63) | class ToolCallResponse(BaseRunnerResponse): class FinishedResponse (line 69) | class FinishedResponse(BaseRunnerResponse): class PrefillProgressResponse (line 73) | class PrefillProgressResponse(BaseRunnerResponse): FILE: src/exo/shared/types/worker/runners.py class RunnerId (line 11) | class RunnerId(Id): class RunnerError (line 15) | class RunnerError(Exception): class BaseRunnerStatus (line 19) | class BaseRunnerStatus(TaggedModel): method is_running (line 20) | def is_running(self): class RunnerIdle (line 24) | class RunnerIdle(BaseRunnerStatus): class RunnerConnecting (line 28) | class RunnerConnecting(BaseRunnerStatus): class RunnerConnected (line 32) | class RunnerConnected(BaseRunnerStatus): class RunnerLoading (line 36) | class RunnerLoading(BaseRunnerStatus): class RunnerLoaded (line 41) | class RunnerLoaded(BaseRunnerStatus): class RunnerWarmingUp (line 45) | class RunnerWarmingUp(BaseRunnerStatus): class RunnerReady (line 49) | class RunnerReady(BaseRunnerStatus): class RunnerRunning (line 53) | class RunnerRunning(BaseRunnerStatus): class RunnerShuttingDown (line 57) | class RunnerShuttingDown(BaseRunnerStatus): class RunnerShutdown (line 61) | class RunnerShutdown(BaseRunnerStatus): class RunnerFailed (line 65) | class RunnerFailed(BaseRunnerStatus): class ShardAssignments (line 84) | class ShardAssignments(CamelCaseModel): method validate_runners_exist (line 90) | def validate_runners_exist(self) -> "ShardAssignments": FILE: src/exo/shared/types/worker/shards.py class Sharding (line 10) | class Sharding(str, Enum): class BaseShardMetadata (line 15) | class BaseShardMetadata(TaggedModel): method is_first_layer (line 35) | def is_first_layer(self) -> bool: method is_last_layer (line 39) | def is_last_layer(self) -> bool: method __hash__ (line 42) | def __hash__(self) -> int: class PipelineShardMetadata (line 56) | class PipelineShardMetadata(BaseShardMetadata): class CfgShardMetadata (line 66) | class CfgShardMetadata(BaseShardMetadata): class TensorShardMetadata (line 78) | class TensorShardMetadata(BaseShardMetadata): FILE: src/exo/utils/__init__.py function ensure_type (line 6) | def ensure_type[T](obj: Any, expected_type: Type[T]) -> T: # type: ignore function todo (line 12) | def todo[T]( FILE: src/exo/utils/banner.py function _is_first_run (line 13) | def _is_first_run() -> bool: function _mark_first_run_done (line 17) | def _mark_first_run_done() -> None: function print_startup_banner (line 22) | def print_startup_banner(port: int) -> None: FILE: src/exo/utils/channels.py class Sender (line 28) | class Sender[T](AnyioSender[T]): method clone (line 29) | def clone(self) -> "Sender[T]": method clone_receiver (line 34) | def clone_receiver(self) -> "Receiver[T]": class Receiver (line 41) | class Receiver[T](AnyioReceiver[T]): method clone (line 42) | def clone(self) -> "Receiver[T]": method clone_sender (line 47) | def clone_sender(self) -> Sender[T]: method collect (line 53) | def collect(self) -> list[T]: method receive_at_least (line 64) | async def receive_at_least(self, n: int) -> list[T]: method __enter__ (line 73) | def __enter__(self) -> Self: class _MpEndOfStream (line 77) | class _MpEndOfStream: class MpState (line 81) | class MpState[T]: method __init__ (line 82) | def __init__(self, max_buffer_size: float): method __getstate__ (line 93) | def __getstate__(self): class MpSender (line 100) | class MpSender[T]: method send_nowait (line 108) | def send_nowait(self, item: T) -> None: method send (line 119) | def send(self, item: T) -> None: method send_async (line 128) | async def send_async(self, item: T) -> None: method close (line 133) | def close(self) -> None: method join (line 141) | def join(self) -> None: method __enter__ (line 149) | def __enter__(self) -> Self: method __exit__ (line 152) | def __exit__( method __getstate__ (line 160) | def __getstate__(self) -> dict[str, Any]: class MpReceiver (line 167) | class MpReceiver[T]: method receive_nowait (line 175) | def receive_nowait(self) -> T: method receive (line 191) | def receive(self) -> T: method receive_async (line 207) | async def receive_async(self) -> T: method close (line 212) | def close(self) -> None: method join (line 220) | def join(self) -> None: method __iter__ (line 228) | def __iter__(self) -> Self: method __next__ (line 231) | def __next__(self) -> T: method __aiter__ (line 238) | def __aiter__(self) -> Self: method __anext__ (line 241) | async def __anext__(self) -> T: method __enter__ (line 248) | def __enter__(self) -> Self: method __exit__ (line 251) | def __exit__( method collect (line 259) | def collect(self) -> list[T]: method receive_at_least (line 270) | def receive_at_least(self, n: int) -> list[T]: method __getstate__ (line 279) | def __getstate__(self): class channel (line 285) | class channel[T]: # noqa: N801 method __new__ (line 288) | def __new__(cls, max_buffer_size: float = inf) -> tuple[Sender[T], Rec... class mp_channel (line 295) | class mp_channel[T]: # noqa: N801 method __new__ (line 299) | def __new__(cls, max_buffer_size: float = inf) -> tuple[MpSender[T], M... FILE: src/exo/utils/dashboard_path.py function find_resources (line 6) | def find_resources() -> Path: function _find_resources_in_repo (line 15) | def _find_resources_in_repo() -> Path | None: function _find_resources_in_bundle (line 24) | def _find_resources_in_bundle() -> Path | None: function find_dashboard (line 34) | def find_dashboard() -> Path: function _find_dashboard_in_repo (line 43) | def _find_dashboard_in_repo() -> Path | None: function _find_dashboard_in_bundle (line 52) | def _find_dashboard_in_bundle() -> Path | None: FILE: src/exo/utils/disk_event_log.py function _serialize_event (line 23) | def _serialize_event(event: Event) -> bytes: function _deserialize_event (line 27) | def _deserialize_event(raw: bytes) -> Event: function _unpack_header (line 37) | def _unpack_header(header: bytes) -> int: function _skip_record (line 41) | def _skip_record(f: BufferedReader) -> bool: function _read_record (line 50) | def _read_record(f: BufferedReader) -> Event | None: class DiskEventLog (line 62) | class DiskEventLog: method __init__ (line 72) | def __init__(self, directory: Path) -> None: method _cache_offset (line 85) | def _cache_offset(self, idx: int, offset: int) -> None: method _seek_to (line 91) | def _seek_to(self, f: BufferedReader, target_idx: int) -> None: method append (line 113) | def append(self, event: Event) -> None: method read_range (line 119) | def read_range(self, start: int, end: int) -> Iterator[Event]: method read_all (line 138) | def read_all(self) -> Iterator[Event]: method __len__ (line 150) | def __len__(self) -> int: method close (line 153) | def close(self) -> None: method _rotate (line 164) | def _rotate(source: Path, directory: Path) -> None: FILE: src/exo/utils/event_buffer.py class OrderedBuffer (line 4) | class OrderedBuffer[T]: method __init__ (line 12) | def __init__(self): method ingest (line 16) | def ingest(self, idx: int, t: T): method drain (line 28) | def drain(self) -> list[T]: method drain_indexed (line 39) | def drain_indexed(self) -> list[tuple[int, T]]: class MultiSourceBuffer (line 51) | class MultiSourceBuffer[SourceId, T]: method __init__ (line 57) | def __init__(self): method ingest (line 60) | def ingest(self, idx: int, t: T, source: SourceId): method drain (line 66) | def drain(self) -> list[T]: FILE: src/exo/utils/fs.py function delete_if_exists (line 12) | def delete_if_exists(filename: StrOrBytesPath) -> None: function ensure_parent_directory_exists (line 17) | def ensure_parent_directory_exists(filename: StrPath) -> None: function ensure_directory_exists (line 24) | def ensure_directory_exists(dirname: StrPath) -> None: function make_temp_path (line 31) | def make_temp_path(name: LiteralString) -> str: FILE: src/exo/utils/info_gatherer/info_gatherer.py function _get_thunderbolt_devices (line 46) | async def _get_thunderbolt_devices() -> set[str] | None: function _get_bridge_services (line 79) | async def _get_bridge_services() -> dict[str, str] | None: function _get_bridge_members (line 126) | async def _get_bridge_members(bridge_device: str) -> set[str]: function _find_thunderbolt_bridge (line 148) | async def _find_thunderbolt_bridge( function _is_service_enabled (line 162) | async def _is_service_enabled(service_name: str) -> bool | None: class StaticNodeInformation (line 182) | class StaticNodeInformation(TaggedModel): method gather (line 191) | async def gather(cls) -> Self: class NodeNetworkInterfaces (line 201) | class NodeNetworkInterfaces(TaggedModel): class MacThunderboltIdentifiers (line 205) | class MacThunderboltIdentifiers(TaggedModel): class MacThunderboltConnections (line 209) | class MacThunderboltConnections(TaggedModel): class RdmaCtlStatus (line 213) | class RdmaCtlStatus(TaggedModel): method gather (line 217) | async def gather(cls) -> Self | None: class ThunderboltBridgeInfo (line 235) | class ThunderboltBridgeInfo(TaggedModel): method gather (line 239) | async def gather(cls) -> Self | None: class NodeConfig (line 295) | class NodeConfig(TaggedModel): method gather (line 299) | async def gather(cls) -> Self | None: class MiscData (line 313) | class MiscData(TaggedModel): method gather (line 319) | async def gather(cls) -> Self: class NodeDiskUsage (line 323) | class NodeDiskUsage(TaggedModel): method gather (line 329) | async def gather(cls) -> Self: function _gather_iface_map (line 337) | async def _gather_iface_map() -> dict[str, str] | None: class InfoGatherer (line 373) | class InfoGatherer: method run (line 386) | async def run(self): method shutdown (line 410) | def shutdown(self): method _monitor_static_info (line 413) | async def _monitor_static_info(self): method _monitor_misc (line 424) | async def _monitor_misc(self): method _monitor_system_profiler_thunderbolt_data (line 435) | async def _monitor_system_profiler_thunderbolt_data(self): method _monitor_memory_usage (line 462) | async def _monitor_memory_usage(self): method _watch_system_info (line 480) | async def _watch_system_info(self): method _monitor_thunderbolt_bridge_status (line 492) | async def _monitor_thunderbolt_bridge_status(self): method _monitor_rdma_ctl_status (line 505) | async def _monitor_rdma_ctl_status(self): method _monitor_disk_usage (line 517) | async def _monitor_disk_usage(self): method _monitor_macmon (line 528) | async def _monitor_macmon(self, macmon_path: str): FILE: src/exo/utils/info_gatherer/macmon.py class _TempMetrics (line 9) | class _TempMetrics(BaseModel, extra="ignore"): class _MemoryMetrics (line 16) | class _MemoryMetrics(BaseModel, extra="ignore"): class RawMacmonMetrics (line 25) | class RawMacmonMetrics(BaseModel, extra="ignore"): class MacmonMetrics (line 46) | class MacmonMetrics(TaggedModel): method from_raw (line 51) | def from_raw(cls, raw: RawMacmonMetrics) -> Self: method from_raw_json (line 69) | def from_raw_json(cls, json: str) -> Self: FILE: src/exo/utils/info_gatherer/net_profile.py function check_reachability (line 17) | async def check_reachability( function check_reachable (line 81) | async def check_reachable( FILE: src/exo/utils/info_gatherer/system_info.py function get_os_version (line 12) | def get_os_version() -> str: function get_os_build_version (line 24) | async def get_os_build_version() -> str: function get_friendly_name (line 40) | async def get_friendly_name() -> str: function _get_interface_types_from_networksetup (line 59) | async def _get_interface_types_from_networksetup() -> dict[str, Interfac... function get_network_interfaces (line 93) | async def get_network_interfaces() -> list[NetworkInterfaceInfo]: function get_model_and_chip (line 120) | async def get_model_and_chip() -> tuple[str, str]: FILE: src/exo/utils/info_gatherer/tests/test_tb_parsing.py function test_tb_parsing (line 17) | async def test_tb_parsing(): FILE: src/exo/utils/keyed_backoff.py class KeyedBackoff (line 7) | class KeyedBackoff(Generic[K]): method __init__ (line 10) | def __init__(self, base: float = 0.5, cap: float = 10.0): method should_proceed (line 16) | def should_proceed(self, key: K) -> bool: method record_attempt (line 24) | def record_attempt(self, key: K) -> None: method reset (line 29) | def reset(self, key: K) -> None: FILE: src/exo/utils/phantom.py class _PhantomData (line 1) | class _PhantomData[*T]: FILE: src/exo/utils/power_sampler.py class PowerSampler (line 14) | class PowerSampler: method __init__ (line 15) | def __init__( method _take_sample (line 28) | def _take_sample(self) -> None: method run (line 32) | async def run(self) -> None: method result (line 39) | def result(self) -> PowerUsage: FILE: src/exo/utils/pydantic_ext.py class CamelCaseModel (line 13) | class CamelCaseModel(BaseModel): class FrozenModel (line 26) | class FrozenModel(BaseModel): class TaggedModel (line 36) | class TaggedModel(CamelCaseModel): method _serialize (line 38) | def _serialize(self, handler: SerializerFunctionWrapHandler): method _validate (line 44) | def _validate(cls, v: Any, handler: ValidatorFunctionWrapHandler) -> S... method __str__ (line 50) | def __str__(self) -> str: FILE: src/exo/utils/reactive.py class OnChange (line 9) | class OnChange[T](Protocol): method __call__ (line 10) | def __call__(self, old_value: T, new_value: T) -> None: ... class Reactive (line 13) | class Reactive[T]: method __init__ (line 14) | def __init__(self, initial_value: T, on_change: OnChange[T]): method value (line 19) | def value(self): method value (line 23) | def value(self, new_value: T): FILE: src/exo/utils/task_group.py class TaskGroup (line 11) | class TaskGroup: method is_running (line 15) | def is_running(self) -> bool: method cancel_tasks (line 18) | def cancel_tasks(self): method cancel_called (line 22) | def cancel_called(self) -> bool: method start_soon (line 26) | def start_soon[*T]( method queue (line 36) | def queue[*T]( method __aenter__ (line 46) | async def __aenter__(self) -> TaskGroupABC: method __aexit__ (line 56) | async def __aexit__( FILE: src/exo/utils/tests/test_event_log.py function log_dir (line 10) | def log_dir(tmp_path: Path) -> Path: function test_append_and_read_back (line 14) | def test_append_and_read_back(log_dir: Path): function test_read_range (line 30) | def test_read_range(log_dir: Path): function test_read_range_bounds (line 44) | def test_read_range_bounds(log_dir: Path): function test_empty_log (line 61) | def test_empty_log(log_dir: Path): function _archives (line 69) | def _archives(log_dir: Path) -> list[Path]: function test_rotation_on_close (line 73) | def test_rotation_on_close(log_dir: Path): function test_rotation_on_construction_with_stale_file (line 86) | def test_rotation_on_construction_with_stale_file(log_dir: Path): function test_empty_log_no_archive (line 99) | def test_empty_log_no_archive(log_dir: Path): function test_close_is_idempotent (line 110) | def test_close_is_idempotent(log_dir: Path): function test_successive_sessions (line 120) | def test_successive_sessions(log_dir: Path): function test_rotation_keeps_at_most_5_archives (line 143) | def test_rotation_keeps_at_most_5_archives(log_dir: Path): FILE: src/exo/utils/tests/test_mp_channel.py function foo (line 11) | def foo(recv: MpReceiver[str]): function bar (line 18) | def bar(send: MpSender[str]): function test_channel_ipc (line 32) | async def test_channel_ipc(): FILE: src/exo/utils/tests/test_power_sampler.py function _make_profile (line 12) | def _make_profile(sys_power: float) -> SystemPerformanceProfile: function single_node_sampler (line 21) | def single_node_sampler() -> PowerSampler: function multi_node_state (line 29) | def multi_node_state() -> dict[NodeId, SystemPerformanceProfile]: function test_single_sample (line 36) | async def test_single_sample(single_node_sampler: PowerSampler) -> None: function test_multi_node_averaging (line 51) | async def test_multi_node_averaging( function test_energy_calculation (line 66) | async def test_energy_calculation(single_node_sampler: PowerSampler) -> ... function test_changing_power_is_averaged (line 78) | async def test_changing_power_is_averaged() -> None: function test_empty_state (line 98) | async def test_empty_state() -> None: function test_result_stops_sampling (line 114) | async def test_result_stops_sampling() -> None: FILE: src/exo/utils/tests/test_tagged.py function test_plain_union_prefers_first_member_when_shapes_are_identical (line 8) | def test_plain_union_prefers_first_member_when_shapes_are_identical(): function test_tagged_union_serializes_and_deserializes_two_identical_shapes_correctly (line 23) | def test_tagged_union_serializes_and_deserializes_two_identical_shapes_c... function test_tagged_union_rejects_unknown_tag (line 46) | def test_tagged_union_rejects_unknown_tag(): function test_two_tagged_classes_with_different_shapes_are_independent_and_not_cross_deserializable (line 58) | def test_two_tagged_classes_with_different_shapes_are_independent_and_no... class Inner (line 87) | class Inner(TaggedModel): class Outer (line 91) | class Outer(TaggedModel): class Wrapper (line 95) | class Wrapper(TaggedModel): class Container (line 100) | class Container(TaggedModel): function test_single_level_tagging (line 105) | def test_single_level_tagging(): function test_nested_externally_tagged_union_serializes_recursively (line 115) | def test_nested_externally_tagged_union_serializes_recursively(): function test_two_level_nested_tagging (line 126) | def test_two_level_nested_tagging(): function test_three_level_nested_tagging (line 136) | def test_three_level_nested_tagging(): function test_lists_and_mixed_nested_structures (line 153) | def test_lists_and_mixed_nested_structures(): function test_no_double_tagging_on_repeated_calls (line 180) | def test_no_double_tagging_on_repeated_calls(): class L3A (line 193) | class L3A(TaggedModel): class L3B (line 197) | class L3B(TaggedModel): class L3C (line 201) | class L3C(TaggedModel): class L2A (line 208) | class L2A(TaggedModel): class L2B (line 212) | class L2B(TaggedModel): class L2C (line 216) | class L2C(TaggedModel): class L1A (line 223) | class L1A(TaggedModel): class L1B (line 227) | class L1B(TaggedModel): class L1C (line 231) | class L1C(TaggedModel): function test_tagged_union_is_fast (line 239) | async def test_tagged_union_is_fast(): FILE: src/exo/worker/engines/image/config.py class BlockType (line 6) | class BlockType(Enum): class TransformerBlockConfig (line 11) | class TransformerBlockConfig(BaseModel): class ImageModelConfig (line 19) | class ImageModelConfig(BaseModel): method total_blocks (line 30) | def total_blocks(self) -> int: method joint_block_count (line 34) | def joint_block_count(self) -> int: method single_block_count (line 40) | def single_block_count(self) -> int: method get_steps_for_quality (line 45) | def get_steps_for_quality(self, quality: str) -> int: FILE: src/exo/worker/engines/image/distributed_model.py class DistributedImageModel (line 24) | class DistributedImageModel: method __init__ (line 29) | def __init__( method from_bound_instance (line 76) | def from_bound_instance( method get_steps_for_quality (line 105) | def get_steps_for_quality(self, quality: Literal["low", "medium", "hig... method generate (line 109) | def generate( function initialize_image_model (line 176) | def initialize_image_model(bound_instance: BoundInstance) -> Distributed... FILE: src/exo/worker/engines/image/generate.py function parse_size (line 27) | def parse_size(size_str: ImageSize) -> tuple[int, int]: function warmup_image_generator (line 46) | def warmup_image_generator(model: DistributedImageModel) -> Image.Image ... function generate_image (line 69) | def generate_image( FILE: src/exo/worker/engines/image/models/__init__.py function get_config_for_model (line 48) | def get_config_for_model(model_id: str) -> ImageModelConfig: function create_adapter_for_model (line 69) | def create_adapter_for_model( FILE: src/exo/worker/engines/image/models/base.py class PromptData (line 25) | class PromptData(ABC): method prompt_embeds (line 28) | def prompt_embeds(self) -> mx.array: ... method pooled_prompt_embeds (line 32) | def pooled_prompt_embeds(self) -> mx.array: ... method negative_prompt_embeds (line 36) | def negative_prompt_embeds(self) -> mx.array | None: ... method negative_pooled_prompt_embeds (line 40) | def negative_pooled_prompt_embeds(self) -> mx.array | None: ... method get_encoder_hidden_states_mask (line 43) | def get_encoder_hidden_states_mask( method cond_image_grid (line 49) | def cond_image_grid( method conditioning_latents (line 61) | def conditioning_latents(self) -> mx.array | None: method kontext_image_ids (line 71) | def kontext_image_ids(self) -> mx.array | None: method get_batched_cfg_data (line 83) | def get_batched_cfg_data( method get_cfg_branch_data (line 103) | def get_cfg_branch_data( class ModelAdapter (line 124) | class ModelAdapter(ABC, Generic[ModelT, TransformerT]): method config (line 130) | def config(self) -> ImageModelConfig: method model (line 134) | def model(self) -> ModelT: method transformer (line 138) | def transformer(self) -> TransformerT: method hidden_dim (line 143) | def hidden_dim(self) -> int: ... method needs_cfg (line 147) | def needs_cfg(self) -> bool: method _get_latent_creator (line 152) | def _get_latent_creator(self) -> type: ... method get_joint_block_wrappers (line 155) | def get_joint_block_wrappers( method get_single_block_wrappers (line 172) | def get_single_block_wrappers( method slice_transformer_blocks (line 187) | def slice_transformer_blocks( method set_image_dimensions (line 203) | def set_image_dimensions(self, image_path: Path) -> tuple[int, int] | ... method create_latents (line 214) | def create_latents(self, seed: int, runtime_config: Config) -> mx.array: method decode_latents (line 230) | def decode_latents( method encode_prompt (line 262) | def encode_prompt( method compute_embeddings (line 267) | def compute_embeddings( method compute_text_embeddings (line 274) | def compute_text_embeddings( method compute_rotary_embeddings (line 283) | def compute_rotary_embeddings( method merge_streams (line 294) | def merge_streams( method apply_guidance (line 302) | def apply_guidance( method final_projection (line 322) | def final_projection( FILE: src/exo/worker/engines/image/models/flux/adapter.py class FluxPromptData (line 28) | class FluxPromptData(PromptData): method __init__ (line 29) | def __init__(self, prompt_embeds: mx.array, pooled_prompt_embeds: mx.a... method prompt_embeds (line 34) | def prompt_embeds(self) -> mx.array: method pooled_prompt_embeds (line 38) | def pooled_prompt_embeds(self) -> mx.array: method negative_prompt_embeds (line 42) | def negative_prompt_embeds(self) -> mx.array | None: method negative_pooled_prompt_embeds (line 46) | def negative_pooled_prompt_embeds(self) -> mx.array | None: method get_encoder_hidden_states_mask (line 49) | def get_encoder_hidden_states_mask(self, positive: bool = True) -> mx.... method cond_image_grid (line 53) | def cond_image_grid( method conditioning_latents (line 59) | def conditioning_latents(self) -> mx.array | None: method kontext_image_ids (line 63) | def kontext_image_ids(self) -> mx.array | None: method get_batched_cfg_data (line 66) | def get_batched_cfg_data( method get_cfg_branch_data (line 71) | def get_cfg_branch_data( class FluxModelAdapter (line 78) | class FluxModelAdapter(ModelAdapter[Flux1, Transformer]): method __init__ (line 79) | def __init__( method hidden_dim (line 95) | def hidden_dim(self) -> int: method needs_cfg (line 99) | def needs_cfg(self) -> bool: method _get_latent_creator (line 102) | def _get_latent_creator(self) -> type: method get_joint_block_wrappers (line 105) | def get_joint_block_wrappers( method get_single_block_wrappers (line 116) | def get_single_block_wrappers( method slice_transformer_blocks (line 126) | def slice_transformer_blocks( method encode_prompt (line 155) | def encode_prompt( method compute_embeddings (line 176) | def compute_embeddings( method compute_text_embeddings (line 185) | def compute_text_embeddings( method compute_rotary_embeddings (line 202) | def compute_rotary_embeddings( method apply_guidance (line 219) | def apply_guidance( FILE: src/exo/worker/engines/image/models/flux/kontext_adapter.py class FluxKontextPromptData (line 31) | class FluxKontextPromptData(PromptData): method __init__ (line 38) | def __init__( method prompt_embeds (line 51) | def prompt_embeds(self) -> mx.array: method pooled_prompt_embeds (line 55) | def pooled_prompt_embeds(self) -> mx.array: method negative_prompt_embeds (line 59) | def negative_prompt_embeds(self) -> mx.array | None: method negative_pooled_prompt_embeds (line 63) | def negative_pooled_prompt_embeds(self) -> mx.array | None: method get_encoder_hidden_states_mask (line 66) | def get_encoder_hidden_states_mask(self, positive: bool = True) -> mx.... method cond_image_grid (line 70) | def cond_image_grid( method conditioning_latents (line 76) | def conditioning_latents(self) -> mx.array | None: method kontext_image_ids (line 81) | def kontext_image_ids(self) -> mx.array | None: method get_cfg_branch_data (line 85) | def get_cfg_branch_data( method get_batched_cfg_data (line 96) | def get_batched_cfg_data( class FluxKontextModelAdapter (line 104) | class FluxKontextModelAdapter(ModelAdapter[Flux1Kontext, Transformer]): method __init__ (line 114) | def __init__( method hidden_dim (line 135) | def hidden_dim(self) -> int: method needs_cfg (line 139) | def needs_cfg(self) -> bool: method _get_latent_creator (line 142) | def _get_latent_creator(self) -> type: method get_joint_block_wrappers (line 145) | def get_joint_block_wrappers( method get_single_block_wrappers (line 156) | def get_single_block_wrappers( method slice_transformer_blocks (line 166) | def slice_transformer_blocks( method set_image_dimensions (line 194) | def set_image_dimensions(self, image_path: Path) -> tuple[int, int]: method create_latents (line 231) | def create_latents(self, seed: int, runtime_config: Config) -> mx.array: method encode_prompt (line 244) | def encode_prompt( method compute_embeddings (line 300) | def compute_embeddings( method compute_text_embeddings (line 309) | def compute_text_embeddings( method compute_rotary_embeddings (line 325) | def compute_rotary_embeddings( method apply_guidance (line 342) | def apply_guidance( FILE: src/exo/worker/engines/image/models/flux/wrappers.py class FluxModulationParams (line 23) | class FluxModulationParams(BaseModel): class FluxNormGateState (line 33) | class FluxNormGateState(BaseModel): class FluxJointBlockWrapper (line 40) | class FluxJointBlockWrapper(JointBlockWrapper[JointTransformerBlock]): method __init__ (line 41) | def __init__(self, block: JointTransformerBlock, text_seq_len: int): method _compute_qkv (line 50) | def _compute_qkv( method _compute_attention (line 139) | def _compute_attention( method _apply_output (line 152) | def _apply_output( class FluxSingleBlockWrapper (line 194) | class FluxSingleBlockWrapper(SingleBlockWrapper[SingleTransformerBlock]): method __init__ (line 197) | def __init__(self, block: SingleTransformerBlock, text_seq_len: int): method _compute_qkv (line 205) | def _compute_qkv( method _compute_attention (line 250) | def _compute_attention( method _apply_output (line 263) | def _apply_output( FILE: src/exo/worker/engines/image/models/qwen/adapter.py class QwenPromptData (line 27) | class QwenPromptData(PromptData): method __init__ (line 28) | def __init__( method prompt_embeds (line 41) | def prompt_embeds(self) -> mx.array: method pooled_prompt_embeds (line 45) | def pooled_prompt_embeds(self) -> mx.array: method negative_prompt_embeds (line 49) | def negative_prompt_embeds(self) -> mx.array: method negative_pooled_prompt_embeds (line 53) | def negative_pooled_prompt_embeds(self) -> mx.array: method get_encoder_hidden_states_mask (line 56) | def get_encoder_hidden_states_mask(self, positive: bool = True) -> mx.... method cond_image_grid (line 63) | def cond_image_grid( method conditioning_latents (line 69) | def conditioning_latents(self) -> mx.array | None: method kontext_image_ids (line 73) | def kontext_image_ids(self) -> mx.array | None: method get_batched_cfg_data (line 76) | def get_batched_cfg_data( method get_cfg_branch_data (line 140) | def get_cfg_branch_data( class QwenModelAdapter (line 159) | class QwenModelAdapter(ModelAdapter[QwenImage, QwenTransformer]): method __init__ (line 170) | def __init__( method hidden_dim (line 186) | def hidden_dim(self) -> int: method needs_cfg (line 190) | def needs_cfg(self) -> bool: method _get_latent_creator (line 194) | def _get_latent_creator(self) -> type: method get_joint_block_wrappers (line 197) | def get_joint_block_wrappers( method get_single_block_wrappers (line 208) | def get_single_block_wrappers( method slice_transformer_blocks (line 214) | def slice_transformer_blocks( method encode_prompt (line 223) | def encode_prompt( method compute_embeddings (line 249) | def compute_embeddings( method compute_text_embeddings (line 259) | def compute_text_embeddings( method compute_rotary_embeddings (line 282) | def compute_rotary_embeddings( method apply_guidance (line 304) | def apply_guidance( FILE: src/exo/worker/engines/image/models/qwen/edit_adapter.py class EditImageDimensions (line 27) | class EditImageDimensions: class QwenEditPromptData (line 35) | class QwenEditPromptData(PromptData): method __init__ (line 36) | def __init__( method prompt_embeds (line 55) | def prompt_embeds(self) -> mx.array: method pooled_prompt_embeds (line 59) | def pooled_prompt_embeds(self) -> mx.array: method negative_prompt_embeds (line 63) | def negative_prompt_embeds(self) -> mx.array: method negative_pooled_prompt_embeds (line 67) | def negative_pooled_prompt_embeds(self) -> mx.array: method get_encoder_hidden_states_mask (line 70) | def get_encoder_hidden_states_mask(self, positive: bool = True) -> mx.... method cond_image_grid (line 77) | def cond_image_grid(self) -> tuple[int, int, int] | list[tuple[int, in... method conditioning_latents (line 81) | def conditioning_latents(self) -> mx.array: method qwen_image_ids (line 85) | def qwen_image_ids(self) -> mx.array: method kontext_image_ids (line 89) | def kontext_image_ids(self) -> mx.array | None: method is_edit_mode (line 93) | def is_edit_mode(self) -> bool: method get_batched_cfg_data (line 96) | def get_batched_cfg_data( method get_cfg_branch_data (line 160) | def get_cfg_branch_data( class QwenEditModelAdapter (line 179) | class QwenEditModelAdapter(ModelAdapter[QwenImageEdit, QwenTransformer]): method __init__ (line 189) | def __init__( method config (line 206) | def config(self) -> ImageModelConfig: method model (line 210) | def model(self) -> QwenImageEdit: method transformer (line 214) | def transformer(self) -> QwenTransformer: method hidden_dim (line 218) | def hidden_dim(self) -> int: method needs_cfg (line 222) | def needs_cfg(self) -> bool: method _get_latent_creator (line 226) | def _get_latent_creator(self) -> type[QwenLatentCreator]: method get_joint_block_wrappers (line 229) | def get_joint_block_wrappers( method get_single_block_wrappers (line 240) | def get_single_block_wrappers( method slice_transformer_blocks (line 247) | def slice_transformer_blocks( method set_image_dimensions (line 256) | def set_image_dimensions(self, image_path: Path) -> tuple[int, int]: method create_latents (line 276) | def create_latents(self, seed: int, runtime_config: Config) -> mx.array: method encode_prompt (line 284) | def encode_prompt( method compute_embeddings (line 344) | def compute_embeddings( method compute_text_embeddings (line 354) | def compute_text_embeddings( method compute_rotary_embeddings (line 375) | def compute_rotary_embeddings( method apply_guidance (line 397) | def apply_guidance( method _compute_dimensions_from_image (line 411) | def _compute_dimensions_from_image( FILE: src/exo/worker/engines/image/models/qwen/wrappers.py class QwenStreamModulation (line 15) | class QwenStreamModulation(BaseModel): class QwenJointBlockWrapper (line 23) | class QwenJointBlockWrapper(JointBlockWrapper[QwenTransformerBlock]): method __init__ (line 24) | def __init__( method set_encoder_mask (line 40) | def set_encoder_mask(self, mask: mx.array | None) -> None: method _compute_qkv (line 44) | def _compute_qkv( method _compute_attention (line 140) | def _compute_attention( method _apply_output (line 163) | def _apply_output( FILE: src/exo/worker/engines/image/pipeline/block_wrapper.py class BlockWrapperMode (line 13) | class BlockWrapperMode(Enum): class BlockWrapperMixin (line 18) | class BlockWrapperMixin: method _init_cache_state (line 33) | def _init_cache_state(self, text_seq_len: int) -> None: method set_patch (line 40) | def set_patch( method set_text_seq_len (line 61) | def set_text_seq_len(self, text_seq_len: int) -> None: method _get_active_cache (line 64) | def _get_active_cache(self) -> ImagePatchKVCache | None: method _ensure_cache (line 67) | def _ensure_cache(self, img_key: mx.array) -> None: method _cache_full_image_kv (line 77) | def _cache_full_image_kv(self, img_key: mx.array, img_value: mx.array)... method _cache_patch_kv (line 83) | def _cache_patch_kv(self, img_key: mx.array, img_value: mx.array) -> N... method _get_full_kv (line 88) | def _get_full_kv( method reset_cache (line 95) | def reset_cache(self) -> None: class JointBlockWrapper (line 99) | class JointBlockWrapper(BlockWrapperMixin, ABC, Generic[BlockT]): method __init__ (line 110) | def __init__(self, block: BlockT, text_seq_len: int): method set_encoder_mask (line 114) | def set_encoder_mask(self, mask: mx.array | None) -> None: # noqa: B027 method __call__ (line 122) | def __call__( method _forward_caching (line 137) | def _forward_caching( method _forward_patched (line 159) | def _forward_patched( method _compute_qkv (line 192) | def _compute_qkv( method _compute_attention (line 202) | def _compute_attention( method _apply_output (line 207) | def _apply_output( class SingleBlockWrapper (line 216) | class SingleBlockWrapper(BlockWrapperMixin, ABC, Generic[BlockT]): method __init__ (line 225) | def __init__(self, block: BlockT, text_seq_len: int): method __call__ (line 229) | def __call__( method _forward_caching (line 241) | def _forward_caching( method _forward_patched (line 260) | def _forward_patched( method _compute_qkv (line 284) | def _compute_qkv( method _compute_attention (line 293) | def _compute_attention( method _apply_output (line 298) | def _apply_output( FILE: src/exo/worker/engines/image/pipeline/kv_cache.py class ImagePatchKVCache (line 4) | class ImagePatchKVCache: method __init__ (line 12) | def __init__( method update_image_patch (line 33) | def update_image_patch( method get_full_kv (line 47) | def get_full_kv( method reset (line 63) | def reset(self) -> None: FILE: src/exo/worker/engines/image/pipeline/runner.py class CfgBranch (line 32) | class CfgBranch: function calculate_patch_heights (line 40) | def calculate_patch_heights( function calculate_token_indices (line 54) | def calculate_token_indices( class DiffusionRunner (line 72) | class DiffusionRunner: method __init__ (line 80) | def __init__( method _init_cfg_topology (line 106) | def _init_cfg_topology( method _device_rank_for (line 184) | def _device_rank_for(self, cfg_rank: int, pipeline_rank: int) -> int: method _compute_assigned_blocks (line 197) | def _compute_assigned_blocks(self) -> None: method is_first_stage (line 232) | def is_first_stage(self) -> bool: method is_last_stage (line 236) | def is_last_stage(self) -> bool: method is_distributed (line 240) | def is_distributed(self) -> bool: method _get_effective_guidance_scale (line 243) | def _get_effective_guidance_scale(self) -> float | None: method _get_cfg_branches (line 248) | def _get_cfg_branches(self, prompt_data: PromptData) -> Iterator[CfgBr... method _combine_cfg_results (line 296) | def _combine_cfg_results(self, results: list[tuple[bool, mx.array]]) -... method _exchange_and_apply_guidance (line 309) | def _exchange_and_apply_guidance( method _apply_guidance (line 334) | def _apply_guidance(self, noise_pos: mx.array, noise_neg: mx.array) ->... method _ensure_wrappers (line 339) | def _ensure_wrappers( method _reset_all_caches (line 362) | def _reset_all_caches(self) -> None: method _set_text_seq_len (line 371) | def _set_text_seq_len(self, text_seq_len: int) -> None: method _calculate_capture_steps (line 379) | def _calculate_capture_steps( method generate_image (line 426) | def generate_image( method _run_diffusion_loop (line 501) | def _run_diffusion_loop( method _forward_pass (line 558) | def _forward_pass( method _diffusion_step (line 649) | def _diffusion_step( method _single_node_step (line 679) | def _single_node_step( method _create_patches (line 714) | def _create_patches( method _run_sync_pass (line 729) | def _run_sync_pass( method _sync_pipeline_step (line 904) | def _sync_pipeline_step( method _async_pipeline_step (line 980) | def _async_pipeline_step( method _run_single_patch_pass (line 1078) | def _run_single_patch_pass( FILE: src/exo/worker/engines/mlx/auto_parallel.py function flush_prefill_sends (line 73) | def flush_prefill_sends() -> None: function clear_prefill_sends (line 80) | def clear_prefill_sends() -> None: function eval_with_timeout (line 85) | def eval_with_timeout( class _LayerCallable (line 117) | class _LayerCallable(Protocol): method __call__ (line 125) | def __call__(self, x: mx.array, *args: object, **kwargs: object) -> mx... class CustomMlxLayer (line 128) | class CustomMlxLayer(nn.Module): method __init__ (line 131) | def __init__(self, original_layer: _LayerCallable): method original_layer (line 136) | def original_layer(self) -> _LayerCallable: method __getattr__ (line 142) | def __getattr__(self, name): class PipelineFirstLayer (line 150) | class PipelineFirstLayer(CustomMlxLayer): method __init__ (line 151) | def __init__( method __call__ (line 162) | def __call__(self, x: mx.array, *args: object, **kwargs: object) -> mx... class PipelineLastLayer (line 172) | class PipelineLastLayer(CustomMlxLayer): method __init__ (line 173) | def __init__( method __call__ (line 188) | def __call__(self, x: mx.array, *args: object, **kwargs: object) -> mx... function set_pipeline_prefill (line 227) | def set_pipeline_prefill(model: nn.Module, is_prefill: bool) -> None: function set_pipeline_queue_sends (line 233) | def set_pipeline_queue_sends(model: nn.Module, queue_sends: bool) -> None: function get_inner_model (line 239) | def get_inner_model(model: nn.Module) -> nn.Module: function get_layers (line 263) | def get_layers(inner_model_instance: nn.Module) -> list[_LayerCallable]: function _patch_hybrid_cache (line 276) | def _patch_hybrid_cache( function pipeline_auto_parallel (line 306) | def pipeline_auto_parallel( function patch_pipeline_model (line 433) | def patch_pipeline_model[T](model: T, group: mx.distributed.Group) -> T: function patch_tensor_model (line 462) | def patch_tensor_model[T](model: T) -> T: function tensor_auto_parallel (line 491) | def tensor_auto_parallel( class TensorParallelShardingStrategy (line 621) | class TensorParallelShardingStrategy(ABC): method __init__ (line 622) | def __init__( method shard_model (line 638) | def shard_model( class LlamaShardingStrategy (line 647) | class LlamaShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 648) | def shard_model( function _set_layers (line 677) | def _set_layers(model: nn.Module, layers: list[_LayerCallable]) -> None: class DeepSeekShardingStrategy (line 703) | class DeepSeekShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 704) | def shard_model( class ShardedMoE (line 772) | class ShardedMoE(CustomMlxLayer): method __init__ (line 775) | def __init__(self, layer: _LayerCallable): method __call__ (line 779) | def __call__(self, x: mx.array) -> mx.array: class GLM4MoeLiteShardingStrategy (line 788) | class GLM4MoeLiteShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 789) | def shard_model( class WrappedMiniMaxAttention (line 856) | class WrappedMiniMaxAttention(CustomMlxLayer): method __init__ (line 857) | def __init__(self, layer: _LayerCallable, group: mx.distributed.Group): method __call__ (line 861) | def __call__( class MiniMaxShardingStrategy (line 934) | class MiniMaxShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 935) | def shard_model( class QwenShardingStrategy (line 975) | class QwenShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 976) | def shard_model( class Glm4MoeShardingStrategy (line 1136) | class Glm4MoeShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 1137) | def shard_model( class GptOssShardingStrategy (line 1184) | class GptOssShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 1185) | def shard_model( class Step35ShardingStrategy (line 1227) | class Step35ShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 1228) | def shard_model( class NemotronHShardingStrategy (line 1272) | class NemotronHShardingStrategy(TensorParallelShardingStrategy): method shard_model (line 1273) | def shard_model( method _shard_mamba2_mixer (line 1316) | def _shard_mamba2_mixer(self, mixer: NemotronHMamba2Mixer, rank: int) ... FILE: src/exo/worker/engines/mlx/cache.py function _default_memory_threshold (line 23) | def _default_memory_threshold() -> float: class CacheSnapshot (line 39) | class CacheSnapshot: method __init__ (line 42) | def __init__( function snapshot_ssm_states (line 49) | def snapshot_ssm_states(cache: KVCacheType) -> CacheSnapshot: function _find_nearest_snapshot (line 60) | def _find_nearest_snapshot( function has_non_kv_caches (line 73) | def has_non_kv_caches(cache: KVCacheType) -> bool: class KVPrefixCache (line 78) | class KVPrefixCache: method __init__ (line 79) | def __init__(self, group: mx.distributed.Group | None): method clear (line 87) | def clear(self): method add_kv_cache (line 94) | def add_kv_cache( method update_kv_cache (line 109) | def update_kv_cache( method _get_snapshot (line 132) | def _get_snapshot( method get_kv_cache (line 148) | def get_kv_cache( method _evict_if_needed (line 211) | def _evict_if_needed(self): method get_memory_used_percentage (line 231) | def get_memory_used_percentage(self) -> float: function trim_cache (line 246) | def trim_cache( function encode_prompt (line 261) | def encode_prompt(tokenizer: TokenizerWrapper, prompt: str) -> mx.array: function _entry_length (line 273) | def _entry_length( function cache_length (line 285) | def cache_length(cache: KVCacheType) -> int: function get_prefix_length (line 290) | def get_prefix_length(prompt: mx.array, cached_prompt: mx.array) -> int: function get_available_memory (line 301) | def get_available_memory() -> Memory: function get_memory_used_percentage (line 306) | def get_memory_used_percentage() -> float: function make_kv_cache (line 312) | def make_kv_cache( FILE: src/exo/worker/engines/mlx/dsml_encoding.py function parse_dsml_output (line 35) | def parse_dsml_output(text: str) -> list[ToolCallItem] | None: FILE: src/exo/worker/engines/mlx/generator/batch_generate.py function _stop_sequences (line 44) | def _stop_sequences(task_params: TextGenerationTaskParams) -> list[str]: class _EngineTask (line 53) | class _EngineTask: class ExoBatchGenerator (line 72) | class ExoBatchGenerator: method __post_init__ (line 81) | def __post_init__(self) -> None: method has_work (line 89) | def has_work(self) -> bool: method submit (line 96) | def submit( method step (line 218) | def step(self) -> list[tuple[int, GenerationResponse]]: method cancel (line 350) | def cancel(self, uids: list[int]) -> None: method close (line 355) | def close(self) -> None: method _save_prefix_cache (line 358) | def _save_prefix_cache( FILE: src/exo/worker/engines/mlx/generator/generate.py class PrefillCancelled (line 65) | class PrefillCancelled(BaseException): function _has_pipeline_communication_layer (line 69) | def _has_pipeline_communication_layer(model: Model): function pipeline_parallel_prefill (line 76) | def pipeline_parallel_prefill( function prefill (line 193) | def prefill( function warmup_inference (line 308) | def warmup_inference( function ban_token_ids (line 378) | def ban_token_ids(token_ids: list[int]) -> Callable[[mx.array, mx.array]... function eos_ids_from_tokenizer (line 389) | def eos_ids_from_tokenizer(tokenizer: TokenizerWrapper) -> list[int]: function extract_top_logprobs (line 396) | def extract_top_logprobs( function mlx_generate (line 453) | def mlx_generate( FILE: src/exo/worker/engines/mlx/tests/test_batch_generate.py function _init_random (line 34) | def _init_random(model: nn.Module) -> None: function _run_b1_vs_b2 (line 47) | def _run_b1_vs_b2( function _make_tokenizer (line 150) | def _make_tokenizer() -> TokenizerWrapper: function test_batch_b2_llama (line 165) | def test_batch_b2_llama() -> None: function test_batch_b2_qwen35_moe (line 202) | def test_batch_b2_qwen35_moe() -> None: FILE: src/exo/worker/engines/mlx/utils_mlx.py function get_weights_size (line 71) | def get_weights_size(model_shard_meta: ShardMetadata) -> Memory: class ModelLoadingTimeoutError (line 84) | class ModelLoadingTimeoutError(Exception): class HostList (line 88) | class HostList(RootModel[list[str]]): method from_hosts (line 90) | def from_hosts(cls, hosts: list[Host]) -> "HostList": function mlx_distributed_init (line 94) | def mlx_distributed_init( function initialize_mlx (line 153) | def initialize_mlx( function load_mlx_items (line 166) | def load_mlx_items( function shard_and_load (line 216) | def shard_and_load( function get_tokenizer (line 288) | def get_tokenizer(model_path: Path, shard_metadata: ShardMetadata) -> To... function get_eos_token_ids_for_model (line 297) | def get_eos_token_ids_for_model(model_id: ModelId) -> list[int] | None: function load_tokenizer_for_model_id (line 328) | def load_tokenizer_for_model_id( function _normalize_tool_calls (line 416) | def _normalize_tool_calls(msg_dict: dict[str, Any]) -> None: function _collect_nested_property_names (line 438) | def _collect_nested_property_names(schema: dict[str, Any]) -> set[str]: function _schemas_lost_in_prompt (line 454) | def _schemas_lost_in_prompt(prompt: str, tools: list[dict[str, Any]]) ->... function _patch_lossy_chat_template (line 470) | def _patch_lossy_chat_template(template: str) -> str | None: function _needs_dsml_encoding (line 488) | def _needs_dsml_encoding(task_params: TextGenerationTaskParams) -> bool: function apply_chat_template (line 501) | def apply_chat_template( function detect_thinking_prompt_suffix (line 591) | def detect_thinking_prompt_suffix(prompt: str, tokenizer: TokenizerWrapp... function fix_unmatched_think_end_tokens (line 601) | def fix_unmatched_think_end_tokens( class NullKVCache (line 625) | class NullKVCache(KVCache): method __init__ (line 631) | def __init__(self, dtype: mx.Dtype = mx.float16): method state (line 639) | def state(self) -> tuple[mx.array, mx.array]: method state (line 644) | def state(self, v: tuple[mx.array, mx.array]) -> None: function mlx_force_oom (line 648) | def mlx_force_oom(size: int = 200000) -> None: function set_wired_limit_for_model (line 663) | def set_wired_limit_for_model(model_size: Memory): function mlx_cleanup (line 688) | def mlx_cleanup( function mx_any (line 698) | def mx_any(bool_: bool, group: Group | None) -> bool: function mx_barrier (line 708) | def mx_barrier(group: Group | None): function _parse_kimi_tool_calls (line 718) | def _parse_kimi_tool_calls(text: str): function mx_all_gather_tasks (line 756) | def mx_all_gather_tasks( FILE: src/exo/worker/main.py class Worker (line 52) | class Worker: method __init__ (line 53) | def __init__( method run (line 82) | async def run(self): method _forward_info (line 104) | async def _forward_info(self, recv: Receiver[GatheredInfo]): method _event_applier (line 115) | async def _event_applier(self): method plan_step (line 133) | async def plan_step(self): method shutdown (line 274) | def shutdown(self): method _start_runner_task (line 277) | async def _start_runner_task(self, task: Task): method _create_supervisor (line 283) | def _create_supervisor(self, task: CreateRunner) -> RunnerSupervisor: method _poll_connection_updates (line 293) | async def _poll_connection_updates(self): FILE: src/exo/worker/plan.py function plan (line 44) | def plan( function _kill_runner (line 68) | def _kill_runner( function _create_runner (line 91) | def _create_runner( function _model_needs_download (line 115) | def _model_needs_download( function _init_distributed_backend (line 141) | def _init_distributed_backend( function _load_model (line 191) | def _load_model( function _ready_to_warmup (line 232) | def _ready_to_warmup( function _pending_tasks (line 271) | def _pending_tasks( function _cancel_tasks (line 310) | def _cancel_tasks( FILE: src/exo/worker/runner/bootstrap.py function entrypoint (line 15) | def entrypoint( FILE: src/exo/worker/runner/image_models/runner.py function _is_primary_output_node (line 71) | def _is_primary_output_node(shard_metadata: ShardMetadata) -> bool: function _process_image_response (line 87) | def _process_image_response( function _send_traces_if_enabled (line 113) | def _send_traces_if_enabled( function _send_image_chunk (line 143) | def _send_image_chunk( class Runner (line 185) | class Runner: method __init__ (line 186) | def __init__( method update_status (line 222) | def update_status(self, status: RunnerStatus): method send_task_status (line 230) | def send_task_status(self, task: Task, status: TaskStatus): method acknowledge_task (line 235) | def acknowledge_task(self, task: Task): method main (line 238) | def main(self): method handle_task (line 257) | def handle_task(self, task: Task): FILE: src/exo/worker/runner/llm_inference/batch_generator.py class Cancelled (line 38) | class Cancelled: class Finished (line 42) | class Finished: class GeneratorQueue (line 46) | class GeneratorQueue[T]: method __init__ (line 47) | def __init__(self): method push (line 50) | def push(self, t: T): method gen (line 53) | def gen(self) -> Generator[T | None]: class InferenceGenerator (line 61) | class InferenceGenerator(ABC): method should_cancel (line 64) | def should_cancel(self, task_id: TaskId) -> bool: method warmup (line 71) | def warmup(self) -> None: ... method submit (line 74) | def submit( method step (line 80) | def step( method close (line 87) | def close(self) -> None: ... function _check_for_debug_prompts (line 95) | def _check_for_debug_prompts(task_params: TextGenerationTaskParams) -> N... class SequentialGenerator (line 113) | class SequentialGenerator(InferenceGenerator): method warmup (line 143) | def warmup(self): method submit (line 151) | def submit( method agree_on_tasks (line 159) | def agree_on_tasks(self) -> None: method agree_on_cancellations (line 165) | def agree_on_cancellations(self) -> None: method step (line 182) | def step( method _start_next (line 216) | def _start_next(self) -> None: method _send_error (line 239) | def _send_error(self, task: TextGeneration, e: Exception) -> None: method _build_generator (line 252) | def _build_generator(self, task: TextGeneration) -> Generator[Generati... method close (line 301) | def close(self) -> None: class BatchGenerator (line 306) | class BatchGenerator(InferenceGenerator): method __post_init__ (line 333) | def __post_init__(self) -> None: method warmup (line 341) | def warmup(self): method submit (line 349) | def submit( method agree_on_tasks (line 357) | def agree_on_tasks(self) -> None: method agree_on_cancellations (line 363) | def agree_on_cancellations(self) -> None: method step (line 380) | def step( method _apply_cancellations (line 441) | def _apply_cancellations( method _send_error (line 469) | def _send_error(self, task: TextGeneration, e: Exception) -> None: method _start_task (line 482) | def _start_task(self, task: TextGeneration) -> int: method close (line 527) | def close(self) -> None: FILE: src/exo/worker/runner/llm_inference/model_output_parsers.py function get_gpt_oss_encoding (line 28) | def get_gpt_oss_encoding(): function apply_all_parsers (line 33) | def apply_all_parsers( function parse_gpt_oss (line 65) | def parse_gpt_oss( function parse_deepseek_v32 (line 137) | def parse_deepseek_v32( function _could_be_dsml_prefix (line 281) | def _could_be_dsml_prefix(text: str) -> bool: function parse_thinking_models (line 301) | def parse_thinking_models( function parse_tool_calls (line 331) | def parse_tool_calls( FILE: src/exo/worker/runner/llm_inference/runner.py class ExitCode (line 71) | class ExitCode(str, Enum): class Runner (line 76) | class Runner: method __init__ (line 77) | def __init__( method update_status (line 118) | def update_status(self, status: RunnerStatus): method send_task_status (line 126) | def send_task_status(self, task_id: TaskId, task_status: TaskStatus): method acknowledge_task (line 131) | def acknowledge_task(self, task: Task): method main (line 134) | def main(self): method handle_first_task (line 145) | def handle_first_task(self, task: Task): method shutdown (line 244) | def shutdown(self, task: Task): method submit_text_generation (line 257) | def submit_text_generation(self, task: TextGeneration): method handle_generation_tasks (line 262) | def handle_generation_tasks(self, starting_task: TextGeneration): method send_response (line 321) | def send_response( class Builder (line 375) | class Builder: method build (line 383) | def build( FILE: src/exo/worker/runner/llm_inference/tool_parsers.py class ToolParser (line 10) | class ToolParser: method parse (line 15) | def parse( function _json_type_matches (line 26) | def _json_type_matches(value: Any, expected_type: str) -> bool: # pyrig... function _coerce_tool_arg_with_schema (line 46) | def _coerce_tool_arg_with_schema(value: Any, schema: dict[str, Any]) -> ... function _coerce_tool_calls_to_schema (line 142) | def _coerce_tool_calls_to_schema( function make_mlx_parser (line 186) | def make_mlx_parser( function _parse_json_calls (line 212) | def _parse_json_calls(text: str) -> list[ToolCallItem] | None: function _flatten (line 225) | def _flatten(p: dict[str, Any]) -> dict[str, str]: function make_json_parser (line 232) | def make_json_parser() -> ToolParser: function infer_tool_parser (line 240) | def infer_tool_parser(chat_template: str) -> ToolParser | None: FILE: src/exo/worker/runner/runner_supervisor.py class RunnerSupervisor (line 53) | class RunnerSupervisor: method create (line 73) | def create( method run (line 111) | async def run(self): method shutdown (line 117) | def shutdown(self): method start_task (line 147) | async def start_task(self, task: Task): method cancel_task (line 170) | async def cancel_task(self, task_id: TaskId): method _forward_events (line 188) | async def _forward_events(self): method __del__ (line 221) | def __del__(self) -> None: method _watch_runner (line 227) | async def _watch_runner(self) -> None: method _check_runner (line 234) | async def _check_runner(self, e: Exception) -> None: FILE: src/exo/worker/tests/unittests/conftest.py class FakeRunnerSupervisor (line 19) | class FakeRunnerSupervisor: class OtherTask (line 27) | class OtherTask(BaseTask): function get_pipeline_shard_metadata (line 33) | def get_pipeline_shard_metadata( function get_shard_assignments (line 53) | def get_shard_assignments( function get_mlx_ring_instance (line 65) | def get_mlx_ring_instance( function get_bound_mlx_ring_instance (line 81) | def get_bound_mlx_ring_instance( FILE: src/exo/worker/tests/unittests/test_mlx/conftest.py class MockLayer (line 24) | class MockLayer(nn.Module): method __init__ (line 25) | def __init__(self) -> None: method __call__ (line 30) | def __call__(self, x: mx.array, *args: object, **kwargs: object) -> mx... class PipelineTestConfig (line 35) | class PipelineTestConfig: function create_hostfile (line 42) | def create_hostfile(world_size: int, base_port: int) -> tuple[str, list[... function run_gpt_oss_pipeline_device (line 65) | def run_gpt_oss_pipeline_device( function run_gpt_oss_tensor_parallel_device (line 145) | def run_gpt_oss_tensor_parallel_device( FILE: src/exo/worker/tests/unittests/test_mlx/test_auto_parallel.py function run_pipeline_device (line 20) | def run_pipeline_device( function test_single_wrapper_delegates_attributes (line 69) | def test_single_wrapper_delegates_attributes() -> None: function test_composed_wrappers_delegate_attributes (line 77) | def test_composed_wrappers_delegate_attributes() -> None: function test_missing_attribute_raises (line 88) | def test_missing_attribute_raises() -> None: function test_composed_call_works (line 96) | def test_composed_call_works() -> None: FILE: src/exo/worker/tests/unittests/test_mlx/test_batch_vs_generate.py function _make_task (line 35) | def _make_task( function _collect_mlx_generate (line 52) | def _collect_mlx_generate( function _collect_batch_generate (line 75) | def _collect_batch_generate( function _assert_state_equal (line 102) | def _assert_state_equal(sa: object, sb: object, label: str) -> None: function _compare_cache_arrays (line 130) | def _compare_cache_arrays( function _safe_state (line 157) | def _safe_state(cache: object) -> list[object]: function _compare_snapshots (line 171) | def _compare_snapshots( class TestBatchVsGenerate (line 216) | class TestBatchVsGenerate: method _cleanup (line 220) | def _cleanup(self): method test_same_output_and_cache (line 230) | def test_same_output_and_cache(self, spec: ArchSpec) -> None: method test_concurrent_batch_completes (line 313) | def test_concurrent_batch_completes(self, spec: ArchSpec) -> None: FILE: src/exo/worker/tests/unittests/test_mlx/test_distributed_fix.py function _check_model_exists (line 16) | def _check_model_exists() -> bool: class DistributedTestResult (line 30) | class DistributedTestResult: method all_success (line 36) | def all_success(self) -> bool: function run_distributed_test (line 42) | def run_distributed_test( function run_pipeline_test (line 90) | def run_pipeline_test( function run_tensor_test (line 113) | def run_tensor_test( class TestPipelineParallelFix (line 134) | class TestPipelineParallelFix: method test_pipeline_single_layer_first_device (line 137) | def test_pipeline_single_layer_first_device(self) -> None: class TestPipelineSplitConfigurations (line 148) | class TestPipelineSplitConfigurations: method test_pipeline_splits (line 158) | def test_pipeline_splits( class TestPrefillStepSizeBoundaries (line 172) | class TestPrefillStepSizeBoundaries: method test_boundary_conditions (line 183) | def test_boundary_conditions( class TestTensorParallelFix (line 198) | class TestTensorParallelFix: method test_tensor_parallel (line 199) | def test_tensor_parallel(self) -> None: class TestTensorParallelBoundaries (line 209) | class TestTensorParallelBoundaries: method test_tensor_parallel_boundaries (line 220) | def test_tensor_parallel_boundaries( FILE: src/exo/worker/tests/unittests/test_mlx/test_kv_prefix_cache.py function _check_model_exists (line 29) | def _check_model_exists() -> bool: class TestGetPrefixLength (line 33) | class TestGetPrefixLength: method test_identical_arrays (line 34) | def test_identical_arrays(self): method test_no_common_prefix (line 39) | def test_no_common_prefix(self): method test_partial_prefix (line 44) | def test_partial_prefix(self): method test_prompt_longer_than_cached (line 49) | def test_prompt_longer_than_cached(self): method test_cached_longer_than_prompt (line 54) | def test_cached_longer_than_prompt(self): method test_single_token_match (line 59) | def test_single_token_match(self): method test_empty_prompt (line 64) | def test_empty_prompt(self): method test_empty_cached (line 69) | def test_empty_cached(self): method test_both_empty (line 74) | def test_both_empty(self): class TestKVPrefix (line 80) | class TestKVPrefix: method mock_tokenizer (line 82) | def mock_tokenizer(self): method test_starts_empty (line 90) | def test_starts_empty(self, mock_tokenizer): method test_clear_empties_cache (line 95) | def test_clear_empties_cache(self, mock_tokenizer): method test_clear_on_empty_cache (line 103) | def test_clear_on_empty_cache(self, mock_tokenizer): function _load_gpt_oss (line 109) | def _load_gpt_oss() -> tuple[Model, object]: class TestKVPrefixCacheWithModel (line 127) | class TestKVPrefixCacheWithModel: method model_and_tokenizer (line 129) | def model_and_tokenizer(self): method test_prefill_populates_cache (line 133) | def test_prefill_populates_cache(self, model_and_tokenizer): method test_add_and_get_exact_match (line 161) | def test_add_and_get_exact_match(self, model_and_tokenizer): method test_add_and_get_prefix_match (line 203) | def test_add_and_get_prefix_match(self, model_and_tokenizer): method test_stored_cache_not_mutated_after_get_and_generation (line 253) | def test_stored_cache_not_mutated_after_get_and_generation( method test_stored_cache_survives_repeated_get_mutate_cycles (line 300) | def test_stored_cache_survives_repeated_get_mutate_cycles( method test_mlx_generate_populates_cache (line 345) | def test_mlx_generate_populates_cache(self, model_and_tokenizer): method test_mlx_generate_second_call_gets_prefix_hit (line 376) | def test_mlx_generate_second_call_gets_prefix_hit(self, model_and_toke... method test_mlx_generate_long_prompt_updates_cache_in_place (line 414) | def test_mlx_generate_long_prompt_updates_cache_in_place(self, model_a... method test_mlx_generate_stored_cache_not_mutated (line 495) | def test_mlx_generate_stored_cache_not_mutated(self, model_and_tokeniz... method test_evicts_lru_entry_under_memory_pressure (line 534) | def test_evicts_lru_entry_under_memory_pressure(self, model_and_tokeni... FILE: src/exo/worker/tests/unittests/test_mlx/test_pipeline_prefill_callbacks.py function _model_card (line 32) | def _model_card() -> ModelCard: function _build_prompt (line 43) | def _build_prompt(tokenizer: Any, prompt_tokens: int) -> tuple[str, Any]: function _run_single_device (line 69) | def _run_single_device( function _run_pipeline_device (line 145) | def _run_pipeline_device( function _create_hostfile (line 231) | def _create_hostfile(world_size: int, base_port: int) -> str: function _run_single_device_test (line 238) | def _run_single_device_test(prompt_tokens: int, timeout: int = 120) -> d... function _run_pipeline_test (line 258) | def _run_pipeline_test( class TestPipelineNoDeadlock (line 328) | class TestPipelineNoDeadlock: method test_no_deadlock (line 354) | def test_no_deadlock( class TestPipelinePrefillCallbacks (line 371) | class TestPipelinePrefillCallbacks: method test_callbacks_match (line 379) | def test_callbacks_match(self, prompt_tokens: int) -> None: method test_output_matches (line 426) | def test_output_matches(self, prompt_tokens: int) -> None: class TestPipelineCallbacksStructure (line 460) | class TestPipelineCallbacksStructure: method test_callback_structure_matches_generate_step (line 463) | def test_callback_structure_matches_generate_step(self) -> None: FILE: src/exo/worker/tests/unittests/test_mlx/test_prefix_cache_architectures.py function _reduce_dict (line 50) | def _reduce_dict(cfg: dict[str, Any]) -> dict[str, Any]: function _reduce_config (line 58) | def _reduce_config(cfg: dict[str, Any]) -> dict[str, Any]: function _find_snapshot (line 98) | def _find_snapshot(hub_name: str) -> Path | None: function _copy_tokenizer (line 107) | def _copy_tokenizer(src: Path, dst: Path) -> None: function _build_model (line 120) | def _build_model(module_name: str, cfg: dict[str, Any]) -> Model: function _collect_tokens (line 133) | def _collect_tokens( class ArchSpec (line 159) | class ArchSpec: function _arch_available (line 191) | def _arch_available(spec: ArchSpec) -> bool: function _make_task (line 200) | def _make_task() -> TextGenerationTaskParams: class TestPrefixCacheArchitectures (line 232) | class TestPrefixCacheArchitectures: method _cleanup (line 236) | def _cleanup(self): method test_prefix_cache_exact_hit (line 246) | def test_prefix_cache_exact_hit(self, spec: ArchSpec) -> None: FILE: src/exo/worker/tests/unittests/test_mlx/test_tokenizers.py function is_tokenizer_file (line 41) | def is_tokenizer_file(filename: str) -> bool: function download_tokenizer_files (line 54) | async def download_tokenizer_files(model_id: ModelId) -> Path: function get_test_models (line 76) | def get_test_models() -> list[ModelCard]: function event_loop (line 97) | def event_loop(): function test_tokenizer_encode_decode (line 109) | async def test_tokenizer_encode_decode(model_card: ModelCard) -> None: function test_tokenizer_has_required_attributes (line 174) | async def test_tokenizer_has_required_attributes(model_card: ModelCard) ... function test_tokenizer_special_tokens (line 213) | async def test_tokenizer_special_tokens(model_card: ModelCard) -> None: function test_kimi_tokenizer_specifically (line 297) | async def test_kimi_tokenizer_specifically(): function test_glm_tokenizer_specifically (line 344) | async def test_glm_tokenizer_specifically(): FILE: src/exo/worker/tests/unittests/test_plan/test_download_and_loading.py function test_plan_requests_download_when_waiting_and_shard_not_downloaded (line 26) | def test_plan_requests_download_when_waiting_and_shard_not_downloaded(): function test_plan_loads_model_when_all_shards_downloaded_and_waiting (line 62) | def test_plan_loads_model_when_all_shards_downloaded_and_waiting(): function test_plan_does_not_request_download_when_shard_already_downloaded (line 113) | def test_plan_does_not_request_download_when_shard_already_downloaded(): function test_plan_does_not_load_model_until_all_shards_downloaded_globally (line 154) | def test_plan_does_not_load_model_until_all_shards_downloaded_globally(): FILE: src/exo/worker/tests/unittests/test_plan/test_runner_lifecycle.py function test_plan_kills_runner_when_instance_missing (line 27) | def test_plan_kills_runner_when_instance_missing(): function test_plan_kills_runner_when_sibling_failed (line 62) | def test_plan_kills_runner_when_sibling_failed(): function test_plan_creates_runner_when_missing_for_node (line 101) | def test_plan_creates_runner_when_missing_for_node(): function test_plan_does_not_create_runner_when_supervisor_already_present (line 135) | def test_plan_does_not_create_runner_when_supervisor_already_present(): function test_plan_does_not_create_runner_for_unassigned_node (line 168) | def test_plan_does_not_create_runner_for_unassigned_node(): FILE: src/exo/worker/tests/unittests/test_plan/test_task_forwarding.py function test_plan_forwards_pending_chat_completion_when_runner_ready (line 30) | def test_plan_forwards_pending_chat_completion_when_runner_ready(): function test_plan_does_not_forward_chat_completion_if_any_runner_not_ready (line 79) | def test_plan_does_not_forward_chat_completion_if_any_runner_not_ready(): function test_plan_does_not_forward_tasks_for_other_instances (line 128) | def test_plan_does_not_forward_tasks_for_other_instances(): function test_plan_ignores_non_pending_or_non_chat_tasks (line 174) | def test_plan_ignores_non_pending_or_non_chat_tasks(): function test_plan_returns_none_when_nothing_to_do (line 238) | def test_plan_returns_none_when_nothing_to_do(): FILE: src/exo/worker/tests/unittests/test_plan/test_warmup.py function test_plan_starts_warmup_for_accepting_rank_when_all_loaded_or_warming (line 27) | def test_plan_starts_warmup_for_accepting_rank_when_all_loaded_or_warmin... function test_plan_starts_warmup_for_rank_zero_after_others_warming (line 70) | def test_plan_starts_warmup_for_rank_zero_after_others_warming(): function test_plan_does_not_start_warmup_for_non_zero_rank_until_all_loaded_or_warming (line 111) | def test_plan_does_not_start_warmup_for_non_zero_rank_until_all_loaded_o... function test_plan_does_not_start_warmup_for_rank_zero_until_others_warming (line 150) | def test_plan_does_not_start_warmup_for_rank_zero_until_others_warming(): function test_plan_starts_warmup_for_connecting_rank_after_others_warming (line 211) | def test_plan_starts_warmup_for_connecting_rank_after_others_warming(): function test_plan_does_not_start_warmup_for_accepting_rank_until_all_loaded_or_warming (line 254) | def test_plan_does_not_start_warmup_for_accepting_rank_until_all_loaded_... function test_plan_does_not_start_warmup_for_connecting_rank_until_others_warming (line 295) | def test_plan_does_not_start_warmup_for_connecting_rank_until_others_war... FILE: src/exo/worker/tests/unittests/test_runner/test_dsml_e2e.py function _simulate_tokens (line 63) | def _simulate_tokens( class TestE2EStandardResponse (line 81) | class TestE2EStandardResponse: method test_plain_text_passthrough (line 84) | def test_plain_text_passthrough(self): class TestE2EToolCallResponse (line 124) | class TestE2EToolCallResponse: method test_realistic_tool_call_tokens (line 127) | def test_realistic_tool_call_tokens(self): method test_multiple_tool_calls_in_one_block (line 179) | def test_multiple_tool_calls_in_one_block(self): class TestE2EMultiTurnToolUse (line 220) | class TestE2EMultiTurnToolUse: method test_encode_multi_turn_with_tool_results (line 223) | def test_encode_multi_turn_with_tool_results(self): method test_multi_tool_results_encoding (line 280) | def test_multi_tool_results_encoding(self): class TestE2EThinkingAndToolCall (line 320) | class TestE2EThinkingAndToolCall: method test_thinking_then_tool_call (line 323) | def test_thinking_then_tool_call(self): method test_thinking_prompt_encoding (line 372) | def test_thinking_prompt_encoding(self): class TestE2ERoundTrip (line 399) | class TestE2ERoundTrip: method test_encoded_tool_call_is_parseable (line 402) | def test_encoded_tool_call_is_parseable(self): method test_encoded_multi_tool_call_round_trips (line 437) | def test_encoded_multi_tool_call_round_trips(self): class TestE2EEdgeCases (line 481) | class TestE2EEdgeCases: method test_dsml_marker_split_at_fullwidth_pipe (line 484) | def test_dsml_marker_split_at_fullwidth_pipe(self): method test_tool_call_with_nested_json_object (line 504) | def test_tool_call_with_nested_json_object(self): method test_text_with_angle_brackets_not_mistaken_for_dsml (line 529) | def test_text_with_angle_brackets_not_mistaken_for_dsml(self): method test_empty_model_response (line 547) | def test_empty_model_response(self): class TestE2EFullRoundTrip (line 560) | class TestE2EFullRoundTrip: method test_single_tool_full_flow_with_thinking (line 568) | def test_single_tool_full_flow_with_thinking(self): method test_multi_tool_full_flow (line 677) | def test_multi_tool_full_flow(self): method test_two_user_turns_reasoning_stripped (line 770) | def test_two_user_turns_reasoning_stripped(self): method test_chained_tool_calls_loop (line 841) | def test_chained_tool_calls_loop(self): FILE: src/exo/worker/tests/unittests/test_runner/test_event_ordering.py function make_nothin (line 61) | def make_nothin[T, U, V](res: T) -> Callable[[], T]: function assert_events_equal (line 108) | def assert_events_equal(test_events: Iterable[Event], true_events: Itera... function patch_out_mlx (line 115) | def patch_out_mlx(monkeypatch: pytest.MonkeyPatch): class FakeExoBatchGenerator (line 140) | class FakeExoBatchGenerator: method __init__ (line 141) | def __init__(self, *_args: object, **_kwargs: object) -> None: method has_work (line 146) | def has_work(self) -> bool: method submit (line 149) | def submit( method step (line 167) | def step(self) -> list[tuple[int, GenerationResponse]]: method cancel (line 172) | def cancel(self, uids: list[int]) -> None: method close (line 176) | def close(self) -> None: class EventCollector (line 181) | class EventCollector: method __init__ (line 182) | def __init__(self, on_event: Callable[[Event], None] | None = None) ->... method send (line 186) | def send(self, event: Event) -> None: method close (line 191) | def close(self) -> None: method join (line 194) | def join(self) -> None: class MockTokenizer (line 198) | class MockTokenizer: method decode (line 209) | def decode(_tokens: list[int]) -> str: method encode (line 213) | def encode(_text: str, add_special_tokens: bool = True) -> list[int]: class MockGroup (line 217) | class MockGroup: method rank (line 218) | def rank(self) -> int: method size (line 221) | def size(self) -> int: function _run (line 225) | def _run(tasks: Iterable[Task], send_after_ready: list[Task] | None = No... function test_events_processed_in_correct_order (line 276) | def test_events_processed_in_correct_order(patch_out_mlx: pytest.MonkeyP... FILE: src/exo/worker/tests/unittests/test_runner/test_glm_tool_parsing.py function _parse_args (line 13) | def _parse_args(text: str) -> list[tuple[str, str]]: function _parse_func_name (line 19) | def _parse_func_name(text: str) -> str: class TestGlmToolParsingWithClosingTags (line 27) | class TestGlmToolParsingWithClosingTags: method test_single_argument (line 30) | def test_single_argument(self): method test_multiple_arguments (line 38) | def test_multiple_arguments(self): method test_arguments_with_whitespace_between (line 47) | def test_arguments_with_whitespace_between(self): class TestGlmToolParsingMissingClosingTags (line 56) | class TestGlmToolParsingMissingClosingTags: method test_single_argument_no_closing (line 59) | def test_single_argument_no_closing(self): method test_multiple_arguments_no_closing (line 65) | def test_multiple_arguments_no_closing(self): method test_mixed_closing_tags (line 74) | def test_mixed_closing_tags(self): method test_value_with_trailing_whitespace (line 83) | def test_value_with_trailing_whitespace(self): method test_value_with_newlines_no_closing (line 88) | def test_value_with_newlines_no_closing(self): class TestGlmToolParsingEdgeCases (line 94) | class TestGlmToolParsingEdgeCases: method test_empty_value_with_closing (line 97) | def test_empty_value_with_closing(self): method test_value_with_json_content (line 102) | def test_value_with_json_content(self): method test_value_with_json_no_closing (line 107) | def test_value_with_json_no_closing(self): FILE: src/exo/worker/tests/unittests/test_runner/test_parse_gpt_oss.py function _make_gen_responses (line 85) | def _make_gen_responses( function _collect (line 104) | def _collect( function _get_tool_call (line 116) | def _get_tool_call( class TestParseGptOssRecipientPlacement (line 125) | class TestParseGptOssRecipientPlacement: method test_format_a_yields_tool_call (line 128) | def test_format_a_yields_tool_call(self): method test_format_b_yields_tool_call (line 135) | def test_format_b_yields_tool_call(self): method test_both_formats_produce_identical_tool_calls (line 142) | def test_both_formats_produce_identical_tool_calls(self): class TestParseGptOssThinkingThenToolCall (line 149) | class TestParseGptOssThinkingThenToolCall: method test_thinking_then_tool_call (line 152) | def test_thinking_then_tool_call(self): class TestParseGptOssMaxTokensTruncation (line 226) | class TestParseGptOssMaxTokensTruncation: method test_truncated_tool_call_yields_finish_reason (line 229) | def test_truncated_tool_call_yields_finish_reason(self): method test_truncated_tool_call_emits_partial_args (line 237) | def test_truncated_tool_call_emits_partial_args(self): method test_truncated_plain_text_still_works (line 243) | def test_truncated_plain_text_still_works(self): FILE: src/exo/worker/tests/unittests/test_runner/test_parse_tool_calls.py function _make_responses (line 12) | def _make_responses( function _dummier_parser (line 27) | def _dummier_parser(text: str) -> dict[str, Any]: class TestParseToolCalls (line 34) | class TestParseToolCalls: method test_closed_tool_call_works_normally (line 37) | def test_closed_tool_call_works_normally(self): method test_no_tool_call_passes_through (line 51) | def test_no_tool_call_passes_through(self): method test_failed_parse_yields_text (line 72) | def test_failed_parse_yields_text(self): method test_tool_schema_coerces_string_arguments_to_expected_types (line 91) | def test_tool_schema_coerces_string_arguments_to_expected_types(self): method test_schema_coercion_skips_unknown_tools (line 146) | def test_schema_coercion_skips_unknown_tools(self): FILE: src/exo/worker/tests/unittests/test_runner/test_runner_supervisor.py class _DeadProcess (line 20) | class _DeadProcess: method start (line 23) | def start(self) -> None: method is_alive (line 26) | def is_alive(self) -> bool: method join (line 29) | def join(self, _timeout: float | None = None) -> None: method terminate (line 32) | def terminate(self) -> None: method kill (line 35) | def kill(self) -> None: function test_check_runner_emits_error_chunk_for_inflight_text_generation (line 40) | async def test_check_runner_emits_error_chunk_for_inflight_text_generati... FILE: tests/get_all_models_on_cluster.py function mid (line 20) | def mid(x: dict[str, Any]) -> str | None: FILE: tests/headless_runner.py class Tests (line 46) | class Tests(BaseModel): function main (line 57) | async def main(): function kill (line 77) | def kill(ev: anyio.Event): function tb_detection (line 82) | async def tb_detection(): function list_models (line 91) | def list_models(): function run_test (line 103) | async def run_test(test: Tests): function ring_instance (line 148) | async def ring_instance(test: Tests, hn: str) -> Instance | None: function execute_test (line 189) | async def execute_test(test: Tests, instance: Instance, hn: str) -> list... function jaccl_instance (line 233) | async def jaccl_instance(test: Tests) -> MlxJacclInstance | None: FILE: tests/start_distributed_test.py function get_tb (line 26) | def get_tb(a: str) -> list[dict[str, Any]]: function get_models (line 31) | def get_models(a: str) -> set[str]: function run (line 36) | def run(h: str, a: str, body: bytes) -> None: FILE: tmp/gen_card.py function main (line 16) | async def main(): FILE: tmp/quantize_and_upload.py function get_model_class (line 33) | def get_model_class(model_name: str) -> type: function get_repo_name (line 54) | def get_repo_name(model_name: str, bits: int | None) -> str: function get_local_path (line 62) | def get_local_path(output_dir: Path, model_name: str, bits: int | None) ... function copy_source_repo (line 70) | def copy_source_repo( function load_and_save_quantized_model (line 103) | def load_and_save_quantized_model( function copy_source_metadata (line 134) | def copy_source_metadata( function upload_to_huggingface (line 159) | def upload_to_huggingface( function clean_local_files (line 214) | def clean_local_files(local_path: Path, dry_run: bool = False) -> None: function main (line 226) | def main() -> int: FILE: tmp/run_llm.py function stream_chat (line 9) | def stream_chat(host: str, query: str) -> None: function main (line 52) | def main() -> None: