MCPcopy Create free account

hub / github.com/unslothai/unsloth / functions

Functions18,583 in github.com/unslothai/unsloth

↓ 41 callersFunction_blocked
(code: str, *, expect_phrase: str)
studio/backend/tests/test_sandbox_tools.py:23
↓ 40 callersMethod_estimate_kv_cache_bytes
Estimate KV cache VRAM for a given context length. 5-path architecture-aware estimation: 1. MLA -- compressed KV latent + RoPE
studio/backend/core/inference/llama_cpp.py:2733
↓ 40 callersMethodall
(self)
studio/backend/plugins/data-designer-github-repo-seed/src/data_designer_github_repo_seed/scraper_impl/state_store.py:48
↓ 39 callersFunctionrefresh
()
studio/frontend/src/components/assistant-ui/thread.tsx:3707
↓ 39 callersMethodwrite
(self, data)
tests/utils/run_none_detect_tests.py:36
↓ 38 callersMethod_already_in_target_state
True iff the live server already satisfies these load kwargs. Mirrors ``routes/inference.py:_request_matches_loaded_settings`` but co
studio/backend/core/inference/llama_cpp.py:6671
↓ 38 callersFunctionevaluate_file_security
Block a load when HF's security scan flags unsafe serialized files. Call UNCONDITIONALLY before any load (independent of trust_remote_code): a ma
studio/backend/utils/security/file_security.py:268
↓ 37 callersMethodactive_count
(self, *, subject: Optional[str] = None)
studio/backend/core/inference/api_monitor.py:264
↓ 37 callersMethoddetach
(self)
tests/test_multi_image_grpo_chunking.py:134
↓ 36 callersMethodcancel
Hard stop. We terminate the subprocess. Quick + reliable.
studio/backend/core/data_recipe/jobs/manager.py:194
↓ 35 callersFunction_send_status
Send a status update to the parent process.
studio/backend/core/training/worker.py:3156
↓ 35 callersMethodfrom_pretrained
(*args, **kwargs)
studio/backend/tests/test_mlx_inference_backend.py:52
↓ 35 callersFunctionisRecord
(value: unknown)
studio/frontend/src/features/recipe-studio/utils/import/helpers.ts:6
↓ 35 callersFunctionlinux_cuda_choice_from_release
( host: HostInfo, release: PublishedReleaseBundle, preferred_runtime_line: str | None = None,
studio/install_llama_prebuilt.py:2214
↓ 35 callersFunctionok
(msg: str)
tests/studio/studio_api_smoke.py:55
↓ 35 callersMethodtolist
(self)
tests/test_raw_text.py:83
↓ 34 callersFunction_send_response
Send a response to the parent process; stamps ``ts`` if absent.
studio/backend/core/inference/worker.py:69
↓ 34 callersMethodget_peft_model
(model, *args, **kwargs)
unsloth/models/loader.py:917
↓ 34 callersMethodload_progress
Return live model-load progress, or None if not loading. During warm-up llama-server mmaps weight shards into page cache before pushi
studio/backend/core/inference/llama_cpp.py:1483
↓ 34 callersFunctionmock_linux_runtime
(monkeypatch, lines)
tests/studio/install/test_selection_logic.py:246
↓ 34 callersFunctionmock_windows_runtime
(monkeypatch, lines)
tests/studio/install/test_selection_logic.py:255
↓ 34 callersMethodmodel_dump
(self)
studio/backend/hub/tests/conftest.py:18
↓ 33 callersFunction_add_doc
( conn, scope, doc_id, filename, sha, texts, *, status = "completed", toke
studio/backend/tests/test_rag_whole_document.py:37
↓ 33 callersFunction_collect_events
(generator, max_events = 200)
studio/backend/tests/test_safetensors_tool_loop.py:270
↓ 33 callersFunctionensure_dir
(path: Path)
studio/backend/hub/utils/paths.py:89
↓ 33 callersFunctioninfo
(s)
tests/studio/playwright_chat_ime_i18n.py:84
↓ 33 callersMethodkill
(self)
studio/backend/hub/tests/test_model_services.py:1962
↓ 33 callersMethodread
(self, n: int = -1)
tests/security/test_scan_packages.py:1325
↓ 33 callersMethodwait
(self, timeout = None)
studio/backend/hub/tests/test_model_services.py:1959
↓ 32 callersMethod_emit
(self, text: str)
studio/backend/core/inference/_html_to_md.py:88
↓ 32 callersFunction_is_same_origin_request
True when Origin is missing or matches request's scheme://host:port. Missing Origin counts as same-origin (top-level GETs omit it). Both sides
studio/backend/main.py:1354
↓ 32 callersMethod_mtp_draft_kv_bytes
Draft KV cache bytes at n_ctx, sized from GGUF dims (K and V types are independent). Separate drafter (Gemma): its own KV via _estimate_kv_cac
studio/backend/core/inference/llama_cpp.py:2904
↓ 32 callersFunction_reset_db
(tmp_path, monkeypatch)
studio/backend/tests/test_mcp_servers.py:10
↓ 32 callersFunctioncompute_activation_bytes
( arch: ModelArchConfig, batch_size: int, seq_len: int, gradient_checkpointing: str, is_lo
studio/backend/utils/hardware/vram_estimation.py:1106
↓ 32 callersMethoddecode
Unified decode — dispatches to the right codec decoder.
studio/backend/core/inference/audio_codecs.py:296
↓ 32 callersMethodexec_module
(self, module)
tests/test_vllm_broken_detection.py:43
↓ 32 callersFunctionfail
Record a failure but keep running so we report ALL failures. `msg` must be credential-free.
tests/studio/studio_api_smoke.py:59
↓ 31 callersMethod_find
()
studio/backend/tests/test_sandbox_tools.py:350
↓ 31 callersFunction_mk
( sev, pkg, fname, check, evidence = "evidence", )
tests/security/test_scan_packages.py:325
↓ 31 callersFunction_send
(event_type, **kwargs)
studio/backend/core/training/worker.py:1370
↓ 31 callersFunctionfast_linear_forward
( proj, X, temp_lora = None, out = None, )
unsloth/kernels/utils.py:1022
↓ 31 callersMethodgenerate_chat_completion_with_tools
(self, **kwargs)
studio/backend/tests/test_gguf_tool_non_streaming.py:112
↓ 30 callersFunction_drive
(coro)
studio/backend/tests/test_gemini_provider.py:46
↓ 30 callersMethod_estimate_mtp_overhead_bytes
MTP draft reserve at ``n_ctx`` = draft KV (grows with ctx) + separate- drafter weights + (MTP + MLA only) a duplicated target KV context. The
studio/backend/core/inference/llama_cpp.py:2946
↓ 30 callersMethod_fit_context_to_vram
Return the largest context length that fits in GPU VRAM. Budget caps occupancy at ``_CTX_FIT_VRAM_FRACTION`` of the card: an absolute
studio/backend/core/inference/llama_cpp.py:3029
↓ 30 callersFunction_replace_openai_citation_markers
Rewrite `\\ue200cite\\ue202SOURCE_ID[\\ue202LOCATOR]\\ue201` markers into `[[N]](URL)` per resolvable id. Multi-source markers expand to one link
studio/backend/core/inference/external_provider.py:135
↓ 30 callersMethodexec_module
(self, module)
studio/backend/core/_torchao_stub.py:80
↓ 30 callersFunctionis_bfloat16_supported
()
unsloth/__init__.py:204
↓ 30 callersFunctionstrip_shadowing_flags
Strip flags that shadow first-class Studio settings. Used when inheriting a previous load's ``llama_extra_args`` so an inherited `-c 4096` ca
studio/backend/core/inference/llama_server_args.py:419
↓ 29 callersFunction_host
(node_os: str, node_arch: str)
tests/studio/install/test_install_node_prebuilt_logic.py:30
↓ 29 callersFunction_make_backend
(monkeypatch, streams: list[list[str]], payloads: list[dict])
studio/backend/tests/test_llama_cpp_tool_loop.py:36
↓ 29 callersFunction_ok
(code: str)
studio/backend/tests/test_sandbox_tools.py:19
↓ 29 callersFunctioncompute_model_weights_bytes
( arch: ModelArchConfig, training_method: str, load_in_4bit: bool )
studio/backend/utils/hardware/vram_estimation.py:840
↓ 29 callersFunctionfinalize
( key: string, outcome: Terminal, opts: { bytes?: number; error?: string | null } = {}, )
studio/frontend/src/features/hub/download-manager/poll-loop.ts:244
↓ 29 callersFunctionisChatThreadDeleted
(threadId: string)
studio/frontend/src/features/chat/utils/chat-thread-tombstones.ts:104
↓ 29 callersFunctionreadFastApiError
( response: Response, fallbackPrefix: string = "Request failed", )
studio/frontend/src/lib/format-fastapi-error.ts:43
↓ 29 callersFunctionshoot
(name)
tests/studio/playwright_chat_ui.py:194
↓ 28 callersMethodQueue
(self)
studio/backend/tests/test_training_pump_resilience.py:442
↓ 28 callersFunction_drive
Drive the post-metadata portion of load_model with stubbed inputs. Mirrors llama_cpp.py:1137-1296 to assert the built command, without subpro
studio/backend/tests/test_llama_cpp_context_fit.py:116
↓ 28 callersFunction_is_valid_repo_id
(repo_id: str)
studio/backend/routes/models.py:37
↓ 28 callersMethod_payloads
(lines, event_name)
studio/backend/tests/test_responses_tool_passthrough.py:1025
↓ 28 callersFunction_run_hook
(model = "some/model")
studio/backend/tests/test_openai_auto_switch.py:74
↓ 28 callersFunctionfail
(m)
tests/studio/playwright_chat_ui.py:70
↓ 28 callersFunctionpublic_model_id
Return a clean, path-free public id for *identifier*. - Local GGUF path -> the file stem with ``.gguf`` stripped, e.g. ``/srv/models/Qwen3-
studio/backend/core/inference/model_ids.py:42
↓ 28 callersFunctionsend
(message)
studio/backend/tests/test_logging_middleware.py:53
↓ 28 callersMethodstart
( self, *, endpoint: str, method: str, model: str, prompt: str
studio/backend/core/inference/api_monitor.py:101
↓ 28 callersFunctiontoastError
(message: string, description?: string)
studio/frontend/src/shared/toast.ts:10
↓ 28 callersMethodwrite
(self, data)
studio/backend/run.py:898
↓ 28 callersMethodwrite
(self, message)
unsloth/import_fixes.py:85
↓ 27 callersFunction_backend_from_gguf
Create a LlamaCppBackend with parsed GGUF metadata from given fields. `general` injects extra `general.*` metadata, to verify the dynamic SWA
studio/backend/tests/test_kv_cache_estimation.py:123
↓ 27 callersMethod_stream_openai_responses
Call OpenAI's /v1/responses endpoint and translate its SSE stream back into OpenAI Chat Completions chunk format. The Respon
studio/backend/core/inference/external_provider.py:4500
↓ 27 callersFunction_studio_mod
()
unsloth_cli/tests/test_studio_run_short_alias_clashes.py:35
↓ 27 callersFunctionadd_to_comparison
Record a model's perplexity in the comparison tracker.
tests/utils/perplexity_eval.py:39
↓ 27 callersFunctionppl_model
(model, tokenizer, dataset)
tests/utils/perplexity_eval.py:9
↓ 26 callersMethod_build_speculative_flags
Return the llama-server flag list for the requested spec mode. Side effects: sets ``self._speculative_type`` (resolved internal emit)
studio/backend/core/inference/llama_cpp.py:6367
↓ 26 callersFunction_capture
Install a MockTransport, drive one streamed call, return body+lines.
studio/backend/tests/test_anthropic_fast_mode_edge.py:63
↓ 26 callersFunction_error_sse_line
Format an error as an SSE data line in OpenAI error format.
studio/backend/core/inference/external_provider.py:6236
↓ 26 callersFunction_file
( name: str, size_on_disk: int, *, blob_path: str | None = None, )
studio/backend/tests/test_cached_gguf_routes.py:41
↓ 26 callersFunction_sse
(event_name: str, payload: dict)
studio/backend/routes/inference.py:8289
↓ 26 callersMethod_stream_anthropic
Call the Anthropic Messages API and translate its SSE to OpenAI format. Anthropic SSE event types: content_block_delta →
studio/backend/core/inference/external_provider.py:1625
↓ 26 callersMethodfeed
Process one generator event, return SSE strings.
studio/backend/core/inference/anthropic_compat.py:297
↓ 26 callersMethodpoll
(self)
studio/backend/hub/tests/test_model_services.py:1956
↓ 25 callersFunction_backend_label
Return the user-facing backend name for API responses. ROCm hosts stay ``DeviceType.CUDA`` internally (ROCm reuses ``torch.cuda.*``), but "cu
studio/backend/utils/hardware/hardware.py:77
↓ 25 callersFunction_ollama_template
(name: str)
unsloth/chat_templates.py:52
↓ 25 callersFunction_patch_status
Patch huggingface_hub.model_info to return one fixed security_repo_status.
studio/backend/tests/test_file_security.py:21
↓ 25 callersFunction_touch
(path: Path)
studio/backend/tests/test_detect_mmproj_file.py:37
↓ 25 callersFunction_windows_hidden_subprocess_kwargs
Return Windows-only subprocess kwargs that suppress console windows.
studio/install_python_stack.py:1416
↓ 25 callersFunctioncheck_dataset_for_missing_videos
Direct import when possible, else AST extraction from vision.py.
tests/test_video_path_validation.py:50
↓ 25 callersMethodcommand
(self, *args, **kwargs)
tests/studio/test_cli_repo_variant.py:28
↓ 25 callersFunctionformatMetricValue
(value: number | null | undefined)
studio/frontend/src/features/recipe-studio/components/executions/executions-view-helpers.ts:155
↓ 25 callersFunctionlistStoredChatThreads
( args: ThreadListArgs = {}, )
studio/frontend/src/features/chat/utils/chat-history-storage.ts:566
↓ 25 callersMethodwait
(self, timeout = None)
studio/backend/tests/test_tensor_parallel.py:133
↓ 24 callersFunction_build_external_messages
Convert ChatMessage list to OpenAI-compatible dicts for external providers. Behaviour per content-part type: - `text`: always preserved.
studio/backend/routes/inference.py:4567
↓ 24 callersFunction_make_fake_gate
Callable mimicking transformers' lru_cache-decorated gates. Tracks call count and exposes `cache_clear`. Flip `.next_return` to mimic install
studio/backend/tests/test_training_worker_flash_attn.py:643
↓ 24 callersMethodappend_reply
(self, entry_id: Optional[str], text: str)
studio/backend/core/inference/api_monitor.py:130
↓ 24 callersMethoddetect_audio_type
Detect audio/TTS codec; swallows errors (use _strict to distinguish).
studio/backend/core/inference/llama_cpp.py:9180
↓ 24 callersMethodend
Signal generation is complete.
studio/backend/core/inference/inference.py:110
↓ 24 callersFunctionfast_rms_layernorm
( layernorm, X: torch.Tensor, gemma: bool = False, )
unsloth/kernels/rms_layernorm.py:245
↓ 24 callersFunctionget_connection
Get a connection to the auth database, creating tables if needed.
studio/backend/auth/storage.py:100
↓ 24 callersFunctioninfo
(s: str)
tests/studio/playwright_extra_ui.py:53
← previousnext →101–200 of 18,583, ranked by callers