AI Slop Code RIsk Monitor

THUDM/slime

slime is an LLM post-training framework for RL Scaling.

24.1 Elevated pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for THUDM/slime, a Python project with 8,629 GitHub stars. SynthScan examined 128,975 lines of code across 622 source files, recording 2079 pattern matches distributed across 20 syntactic categories. The legacy adjusted pattern signal is 24.1 (Elevated pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

24.1
Adjusted Signal
24.1
Raw Pattern Score
100%
Time Factor
2026-10-10
Last Push
8.6K
Stars
Python
Language
129.0K
Lines of Code
622
Files
2.1K
Pattern Hits
2026-10-12
Scan Date
0.25
HC Hit Rate

Risk Review · v3

Use each vector to guide manual verification of the underlying findings.

Cognitive Ownership Risk 43.6/100 · MEDIUM

Can maintainers explain intent, assumptions, and trade-offs? 1375 finding(s).

Hallucinated Dependency & Supply Chain Risk 20.2/100 · LOW

Are imports declared and package/API names verified? 238 finding(s).

Agent Over-Engineering Ratio 56.2/100 · HIGH

Are wrappers, guards, and repeated structures necessary? 1546 finding(s).

PR Review Velocity Impact 71.7/100 · HIGH

Which changes need focused human review? 2079 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 0HIGH 156MEDIUM 198LOW 1725

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 2079 distinct pattern matches across 20 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Hyper-Verbose Identifiers1062 hits · 1066 pts
SeverityFileLineSnippetContext
LOWtools/convert_torch_dist_to_hf_parallel.py60 def collect_from_storage_metadata(storage_item, base_path=""):CODE
LOWtools/trace_timeline_viewer.py55def _make_dummy_pickle_global(module_name: str, name: str) -> type[_MissingPickleObject]:CODE
LOWtools/trace_timeline_viewer.py330 def nearest_closed_ancestor_end(span: dict[str, Any]) -> float | None:CODE
LOWtools/convert_hf_to_int4_direct.py78def round_to_quantized_type_dtype(CODE
LOWslime/backends/megatron_utils/checkpoint.py32 def _init_from_local_shards_and_global_metadata( # type: ignore[override]CODE
LOW⚡slime/backends/megatron_utils/checkpoint.py104 def get_cpu_save_function_and_args(writer):CODE
LOWslime/backends/megatron_utils/memory.py7def configure_buffer_allocation(args):CODE
LOW⚡slime/backends/megatron_utils/arguments.py24def _is_allgather_cp_dsa_model(hf_config):CODE
LOW⚡slime/backends/megatron_utils/arguments.py32def _validate_allgather_cp_supported(args, hf_config=None):CODE
LOWslime/backends/megatron_utils/arguments.py151def _set_default_megatron_args(args):CODE
LOW⚡slime/backends/megatron_utils/model.py43def _disable_tqdm_for_non_main_rank() -> bool:CODE
LOW⚡slime/backends/megatron_utils/model.py51def _should_update_microbatch_pbar(model) -> bool:CODE
LOWslime/backends/megatron_utils/model.py63def _wrap_forward_step_with_microbatch_pbar(forward_step_func, pbar):CODE
LOWslime/backends/megatron_utils/model.py77def _with_rollout_top_p_token_keys(args: Namespace, keys: Sequence[str]) -> list[str]:CODE
LOWslime/backends/megatron_utils/model.py83def _iter_critic_output_layers(model: Sequence[DDP]):CODE
LOWslime/backends/megatron_utils/model.py98 def get_load_checkpoint_path_by_args(args, load_arg="load"):CODE
LOWslime/backends/megatron_utils/model.py128def _critic_output_layer_needs_reinit(args: Namespace, model: Sequence[DDP], role: str) -> bool:CODE
LOWslime/backends/megatron_utils/model.py175def _reinitialize_critic_output_layer(args: Namespace, model: Sequence[DDP]) -> None:CODE
LOWslime/backends/megatron_utils/model.py185def get_optimizer_param_scheduler(args: Namespace, optimizer: MegatronOptimizer) -> OptimizerParamScheduler:CODE
LOWslime/backends/megatron_utils/model.py245def _disable_distributed_optimizer_state_initialization(optimizer: MegatronOptimizer) -> None:CODE
LOWslime/backends/megatron_utils/model.py273def setup_model_and_optimizer(CODE
LOWslime/backends/megatron_utils/model.py719def should_disable_forward_pre_hook(args: Namespace) -> bool:CODE
LOWslime/backends/megatron_utils/model.py999def initialize_model_and_optimizer(CODE
LOWslime/backends/megatron_utils/loss.py89def get_rollout_top_p_logprob_kwargs(args: Namespace, batch: dict[str, Any]) -> dict[str, Any]:CODE
LOWslime/backends/megatron_utils/loss.py200def _allgather_cp_redistribute(CODE
LOWslime/backends/megatron_utils/loss.py529def get_log_probs_and_entropy(CODE
LOWslime/backends/megatron_utils/loss.py679def apply_opd_kl_to_advantages(CODE
LOWslime/backends/megatron_utils/loss.py720def compute_advantages_and_returns(args: Namespace, rollout_data: RolloutBatch) -> None:CODE
LOWslime/backends/megatron_utils/loss.py947def _slice_allgather_response_rows(CODE
LOWslime/backends/megatron_utils/loss.py973def get_score_centering_terms(args, batch, logits):CODE
LOWslime/backends/megatron_utils/model_provider.py282def wrap_model_provider_with_freeze(original_provider, args):CODE
LOWslime/backends/megatron_utils/transformer_engine.py10def patch_precision_aware_optimizer_checkpointing(optimizer):CODE
LOWslime/backends/megatron_utils/transformer_engine.py74def install_transformer_engine_extensions():CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py216def _finalize_distributed_shards(path: Path, local_state: dict[str, Any]) -> None:CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py313def _clear_existing_hf_weights(path: Path) -> None:CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py360def _raise_if_rank_zero_failed(context: str, error: str | None) -> None:CODE
LOWslime/backends/megatron_utils/sglang.py24def _reduce_tensor_with_cpu_support(tensor):CODE
LOWslime/backends/megatron_utils/sglang.py32def monkey_patch_torch_reductions():CODE
LOWslime/backends/megatron_utils/cp_utils.py13def get_logits_and_tokens_offset_with_cp(CODE
LOWslime/backends/megatron_utils/cp_utils.py279def _new_routed_experts_buffer(CODE
LOWslime/backends/megatron_utils/cp_utils.py318def _fill_padded_sample_range(CODE
LOWslime/backends/megatron_utils/cp_utils.py369def _fill_routed_experts_allgather_range(CODE
LOWslime/backends/megatron_utils/cp_utils.py408def _fill_routed_experts_cp_range(CODE
LOWslime/backends/megatron_utils/cp_utils.py458def prepare_routed_experts_for_routing_replay(CODE
LOWslime/backends/megatron_utils/server/megatron_server.py49def _normalize_label_token_ids(label_token_ids: Any, expected_length: int) -> list[list[int]] | None:CODE
LOWslime/backends/megatron_utils/server/megatron_server.py99 def set_train_parallel_config(self, config: dict):CODE
LOWslime/backends/megatron_utils/server/megatron_server.py626def _run_warmup_via_private_http(sample_manager, args):CODE
LOWslime/backends/megatron_utils/server/megatron_server.py672def run_megatron_dp_models_loop_worker(dp_rank, pp_size, sample_manager, actor_models):CODE
LOWslime/backends/megatron_utils/server/megatron_server.py708def _build_update_from_disk_fn(actor_model):CODE
LOWslime/backends/megatron_utils/server/arguments.py34def add_megatron_server_arguments(parser):CODE
LOWslime/backends/megatron_utils/server/arguments.py87def configure_megatron_server_args(args):CODE
LOWslime/backends/megatron_utils/server/arguments.py103def validate_megatron_server_args(args):CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py21def sample_from_vocab_parallel_logits_without_full_gather(CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py158def get_label_token_log_probs_from_vocab_parallel_logits(CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py268def _slice_response_rows_for_current_cp_rank(CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py303def _merge_allgather_cp_tensors(CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py352def _get_log_probs_and_optional_samples(CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py153def _compact_valid_rows_inplace(CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py289def _padded_expert_hidden_bytes(CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py1090def _configure_batch_invariant(deep_gemm: Any, deep_gemm_wrapper: Any) -> bool:CODE
1002 more matches not shown…
Decorative Section Separators140 hits · 506 pts
SeverityFileLineSnippetContext
MEDIUM⚡tools/analyze_profile.py189 # ─── Device Properties ──────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py197 # ─── CUDA/NCCL Info ─────────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py207 # ─── Kernel Analysis ────────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py320 # ─── Communication ──────────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py329 # ─── CPU overhead ───────────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py337# ─── Pretty print ──────────────────────────────────────────────────────────COMMENT
MEDIUM⚡tools/analyze_profile.py341 # ── Config ──────────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py23# ─── Color helpers ──────────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py65# ─── Data structures ───────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py235 # ─── GPU Utilization ────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py278 # ─── Per-stream analysis ────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py295 # ─── CUDA Graph analysis ───────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py352 # ── Timeline ────────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py363 # ── Kernel Breakdown ────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py382 # ── Top Kernels ─────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py390 # ── CUDA Graph ──────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py431 # ── CUDA Graph Location in Timeline ─────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py456 # ── GPU Idle Gaps ───────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py466 # ── Per-Stream ──────────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py484 # ── Communication ───────────────────────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py492 # ── Performance Bottleneck Summary ──────────────────────────────────COMMENT
MEDIUMtools/analyze_profile.py575 # ── Optimization Recommendations ────────────────────────────────────COMMENT
MEDIUMslime/agent/trajectory.py35# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py37# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py54# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py56# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py124# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py126# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py149# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py151# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py340# ===========================================================================COMMENT
MEDIUMslime/agent/trajectory.py342# ===========================================================================COMMENT
MEDIUMtests/test_rm_gpqa.py31# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_rm_gpqa.py33# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_gpqa.py88# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_gpqa.py90# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_sample.py30# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_sample.py32# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_sample.py175# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_sample.py177# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/_cp_dist_helpers.py139# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/_cp_dist_helpers.py157# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py34# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py37# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py63# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py65# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py82# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py84# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py121# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py123# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py149# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py151# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py186# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math_dapo.py188# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_metric_report.py55# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_metric_report.py65# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math.py37# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math.py39# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math.py76# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡tests/test_rm_math.py78# ---------------------------------------------------------------------------COMMENT
80 more matches not shown…
Cross-Language Confusion103 hits · 452 pts
SeverityFileLineSnippetContext
HIGH⚡tools/trace_timeline_viewer.py950 cursorTime: null,CODE
HIGH⚡tools/trace_timeline_viewer.py951 hoveredItem: null,CODE
HIGH⚡tools/trace_timeline_viewer.py952 selectedItem: null,CODE
HIGH⚡tools/trace_timeline_viewer.py1156 const lane = rowExpanded(row) ? (item.lane || 0) : 0;CODE
HIGH⚡tools/trace_timeline_viewer.py1165 let current = null;CODE
HIGH⚡tools/trace_timeline_viewer.py1171 clusters.push(current);CODE
HIGH⚡tools/trace_timeline_viewer.py1174 current.items.push(item);CODE
HIGH⚡tools/trace_timeline_viewer.py1344 const row = rowIdx >= 0 ? state.rows[rowIdx] : null;CODE
HIGH⚡tools/trace_timeline_viewer.py1345 if (row && rowExpanded(row)) {CODE
HIGH⚡tools/trace_timeline_viewer.py1347 y: laneTop(layout, item.lane || 0, scrollTop) + 2,CODE
HIGH⚡tools/trace_timeline_viewer.py1446 if (raw.start_attrs || raw.end_attrs) {CODE
HIGH⚡tools/trace_timeline_viewer.py1455 if (!attrs) return null;CODE
HIGH⚡tools/trace_timeline_viewer.py1459 if (v != null && v > 0) segs.push({ phase, duration: v });CODE
HIGH⚡tools/trace_timeline_viewer.py1459 if (v != null && v > 0) segs.push({ phase, duration: v });CODE
HIGH⚡tools/trace_timeline_viewer.py1501 const pdVirtualRole = attrs.timeline_pd_virtual_role || null;CODE
HIGH⚡tools/trace_timeline_viewer.py1501 const pdVirtualRole = attrs.timeline_pd_virtual_role || null;CODE
HIGH⚡tools/trace_timeline_viewer.py1503 if (!phases || (expanded && !pdVirtualRole)) return null;CODE
HIGH⚡tools/trace_timeline_viewer.py1547 const colorKey = attrs.timeline_pd_parent_name || item.name;CODE
HIGH⚡tools/trace_timeline_viewer.py1552 const pdVirtualRole = attrs.timeline_pd_virtual_role || null;CODE
HIGH⚡tools/trace_timeline_viewer.py1552 const pdVirtualRole = attrs.timeline_pd_virtual_role || null;CODE
HIGH⚡tools/trace_timeline_viewer.py1781 if (showText && labelWidthAvailable > 40) {CODE
HIGH⚡tools/trace_timeline_viewer.py1786 if (a.prompt_tokens != null) pdParts.push(`P:${a.prompt_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1786 if (a.prompt_tokens != null) pdParts.push(`P:${a.prompt_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1787 if (a.completion_tokens != null) pdParts.push(`D:${a.completion_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1787 if (a.completion_tokens != null) pdParts.push(`D:${a.completion_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1788 if (a.cached_tokens != null && a.cached_tokens > 0) pdParts.push(`cache:${a.cached_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1788 if (a.cached_tokens != null && a.cached_tokens > 0) pdParts.push(`cache:${a.cached_tokens}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1789 if (a.pd_prefill_forward_duration != null) pdParts.push(`pf:${(a.pd_prefill_forward_duration*1000).toFixCODE
HIGH⚡tools/trace_timeline_viewer.py1789 if (a.pd_prefill_forward_duration != null) pdParts.push(`pf:${(a.pd_prefill_forward_duration*1000).toFixCODE
HIGH⚡tools/trace_timeline_viewer.py1790 if (a.pd_decode_forward_duration != null) pdParts.push(`df:${(a.pd_decode_forward_duration*1000).toFixedCODE
HIGH⚡tools/trace_timeline_viewer.py1790 if (a.pd_decode_forward_duration != null) pdParts.push(`df:${(a.pd_decode_forward_duration*1000).toFixedCODE
HIGH⚡tools/trace_timeline_viewer.py1791 if (a.pd_transfer_speed_gb_s != null) pdParts.push(`${a.pd_transfer_speed_gb_s.toFixed(1)}GB/s`);CODE
HIGH⚡tools/trace_timeline_viewer.py1791 if (a.pd_transfer_speed_gb_s != null) pdParts.push(`${a.pd_transfer_speed_gb_s.toFixed(1)}GB/s`);CODE
HIGH⚡tools/trace_timeline_viewer.py1857 lines.push(`${key}: ${value}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1862 lines.push(`events: ${item.attrs?.total ?? 0}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1864 lines.push(`${name}: ${count}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1868 if (item.parent_span_name) lines.push(`parent: ${item.parent_span_name}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1870 lines.push(`start: ${niceDuration(item.start_ts - state.globalStart)}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1871 lines.push(`end: ${item.end_ts == null ? 'open' : niceDuration(item.end_ts - state.globalStart)}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1872 if (item.end_ts == null) {CODE
HIGH⚡tools/trace_timeline_viewer.py1873 lines.push(`display_end: ${niceDuration(item.display_end_ts - state.globalStart)}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1875 lines.push(`duration: ${item.end_ts == null ? 'open' : niceDuration(item.end_ts - item.start_ts)}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1877 lines.push(`time: ${niceDuration((item.ts ?? 0) - state.globalStart)}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1879 if (item.state === 'orphan_end') lines.push('warning: unmatched end event');CODE
HIGH⚡tools/trace_timeline_viewer.py1886 lines.push(`${key}: ${typeof value === 'object' ? JSON.stringify(value) : value}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1900 lines.push('── PD disaggregation ──');CODE
HIGH⚡tools/trace_timeline_viewer.py1902 lines.push(' [P] prefill instance');CODE
HIGH⚡tools/trace_timeline_viewer.py1903 pPhases.forEach(p => lines.push(fmtPhase(p)));CODE
HIGH⚡tools/trace_timeline_viewer.py1906 lines.push(' [D] decode instance');CODE
HIGH⚡tools/trace_timeline_viewer.py1907 dPhases.forEach(p => lines.push(fmtPhase(p)));CODE
HIGH⚡tools/trace_timeline_viewer.py1909 lines.push(` total phases: ${(totalDur * 1000).toFixed(1)}ms`);CODE
HIGH⚡tools/trace_timeline_viewer.py1917 lines.push(` ${label}: ${value.toFixed(2)} GB/s`);CODE
HIGH⚡tools/trace_timeline_viewer.py1919 lines.push(` ${label}: ${value.toFixed(1)} MB`);CODE
HIGH⚡tools/trace_timeline_viewer.py1921 lines.push(` ${label}: ${typeof value === 'object' ? JSON.stringify(value) : value}`);CODE
HIGH⚡tools/trace_timeline_viewer.py1929 const activeItem = state.hoveredItem || state.selectedItem;CODE
HIGH⚡tools/trace_timeline_viewer.py2090 if (absoluteY >= layout.top && absoluteY <= layout.top + layout.height) return idx;CODE
HIGH⚡tools/trace_timeline_viewer.py2096 if (!layout) return null;CODE
HIGH⚡tools/trace_timeline_viewer.py2102 let closestPoint = null;CODE
HIGH⚡tools/trace_timeline_viewer.py2111 if (distance <= radius && distance < closestPointDistance) {CODE
HIGH⚡tools/trace_timeline_viewer.py2124 if (localY < itemTop || localY > itemBottom) continue;CODE
43 more matches not shown…
Empty Error Handlers45 hits · 222 pts
SeverityFileLineSnippetContext
HIGHtools/convert_torch_dist_to_hf_parallel.py189except (ValueError, KeyError, OSError):CODE
HIGHtools/convert_hf_to_torch_dist.py36except Exception:CODE
HIGHtools/trace_timeline_viewer.py2341except KeyboardInterrupt:CODE
HIGHslime/backends/megatron_utils/checkpoint.py90except ImportError:CODE
HIGHslime/backends/megatron_utils/__init__.py38except RuntimeError:CODE
HIGHslime/backends/sglang_utils/sglang_engine.py419except requests.exceptions.RequestException:CODE
HIGHslime/backends/sglang_utils/sglang_engine.py89except requests.RequestException:CODE
HIGHslime/backends/sglang_utils/sglang_engine.py137except ValueError:CODE
HIGHslime/utils/arguments.py1785except (ValueError, TypeError):CODE
HIGHslime/utils/http_utils.py66except Exception:CODE
HIGHslime/utils/http_utils.py81except Exception:CODE
HIGHslime/agent/aiohttp_threaded.py40except Exception:CODE
HIGHslime/agent/adapters/common.py639except Exception:CODE
HIGHslime/rollout/fully_async_rollout.py238except Exception: # noqa: BLE001CODE
HIGHslime/rollout/rm_hub/math_utils.py360except Exception:CODE
HIGHslime/rollout/rm_hub/math_utils.py306except Exception:CODE
HIGHslime/data/transport.py386except asyncio.CancelledError:CODE
HIGHtests/test_qwen3_4B_external_pd.py83except OSError:CODE
HIGHtests/test_qwen3_4B_external_pd.py208except Exception:CODE
HIGHtests/fanout_test_helpers.py37except OSError:CODE
HIGHtests/test_qwen2.5_0.5B_opd_sglang.py71except Exception:CODE
HIGHtests/test_qwen2.5_0.5B_fanout_short.py68except FileNotFoundError:CODE
HIGHtests/test_straw_fully_async_recovery.py226except psutil.NoSuchProcess:CODE
HIGHtests/test_straw_fully_async_recovery.py214except psutil.NoSuchProcess:CODE
HIGHtests/test_straw_fully_async_recovery.py236except psutil.NoSuchProcess:CODE
HIGHtests/test_qwen2.5_0.5B_training_recovery.py368except ray.exceptions.RayActorError:CODE
HIGHtests/test_qwen2.5_0.5B_training_recovery.py301except ValueError:CODE
HIGHtests/test_server_control.py253except (asyncio.IncompleteReadError, ConnectionError):CODE
HIGHtests/ci/gpu_lock_exec.py51except subprocess.TimeoutExpired:CODE
HIGHtests/ci/gpu_lock_exec.py56except ProcessLookupError:CODE
HIGHtests/ci/gpu_lock_exec.py129except BlockingIOError:CODE
HIGHtests/ci/gpu_lock_exec.py63except ProcessLookupError:CODE
HIGHdocs/tests/test_browser.py24except (BrokenPipeError, ConnectionResetError):CODE
HIGHexamples/geo3k_vlm_multi_turn/rollout.py386except Exception:CODE
HIGHexamples/strands_sglang/subprocess_interpreter.py370except Exception:CODE
HIGHexamples/coding_agent_rl/generate.py333except Exception: # pragma: no cover - diag must never crashCODE
HIGHexamples/coding_agent_rl/swe.py436except OSError:CODE
HIGHexamples/retool/tool_sandbox.py190except Exception:CODE
HIGHexamples/retool/generate_with_retool.py127except (json.JSONDecodeError, KeyError, AttributeError):CODE
HIGHexamples/retool/generate_with_retool.py296except ImportError:CODE
HIGHslime_plugins/models/qwen3_5.py16except ImportError:CODE
HIGHslime_plugins/models/qwen3_next.py19except ImportError:CODE
HIGHslime_plugins/models/qwen3_5_vl_utils.py150except StopIteration:CODE
HIGHslime_plugins/models/qwen3_5_vl_utils.py155except StopIteration:CODE
HIGHslime_plugins/models/glm5/ops/indexer.py15except Exception:CODE
Excessive Try-Catch Wrapping166 hits · 188 pts
SeverityFileLineSnippetContext
LOWtrain.py120 except Exception:CODE
LOWtools/convert_torch_dist_to_hf_parallel.py142 except Exception as e:CODE
MEDIUMtools/convert_torch_dist_to_hf_parallel.py143 print(f"Error reading {rel_path}: {e}")CODE
LOWtools/convert_torch_dist_to_hf_parallel.py291 except Exception as e:CODE
MEDIUMtools/convert_torch_dist_to_hf_parallel.py292 print(f"Error processing {name}: {e}")CODE
MEDIUMtools/convert_torch_dist_to_hf_parallel.py132def read_file(rel_path, full_path, ops):CODE
LOWtools/profile_rollout.py12 except Exception as e:CODE
MEDIUMtools/profile_rollout.py13 print(f"Error fetching workers from router: {e}")CODE
LOWtools/profile_rollout.py31 except Exception as e:CODE
LOWtools/profile_rollout.py41 except Exception as e:CODE
MEDIUMtools/profile_rollout.py7def get_workers(router_url):CODE
MEDIUMtools/profile_rollout.py35def stop_profile(worker_url):CODE
LOWtools/convert_hf_to_torch_dist.py36 except Exception:CODE
LOWtools/convert_hf_to_int4.py37 except Exception as e:CODE
LOWslime/backends/megatron_utils/model_provider.py230 except Exception as e:CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py59 except Exception as e:CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py78 except Exception as e:CODE
LOWslime/backends/megatron_utils/server/megatron_server.py351 except Exception as e:CODE
LOWslime/backends/megatron_utils/server/megatron_server.py487 except Exception as e:CODE
LOWslime/backends/megatron_utils/server/megatron_server.py560 except Exception as e:CODE
LOWslime/backends/megatron_utils/server/megatron_server.py590 except Exception as e:CODE
LOWslime/backends/sglang_utils/server_control.py200 except Exception as e:CODE
LOWslime/backends/sglang_utils/server_control.py212 except Exception as e:CODE
LOWslime/backends/sglang_utils/sglang_engine.py295 except Exception as e:CODE
LOWslime/backends/sglang_utils/sglang_engine.py321 except Exception as e:CODE
LOWslime/backends/sglang_utils/engine_group.py39 except Exception as error:CODE
LOWslime/backends/sglang_utils/engine_group.py57 except Exception as error:CODE
LOWslime/backends/sglang_utils/external.py81 except Exception as exc:CODE
LOWslime/utils/reloadable_process_group.py518 except Exception as e:CODE
MEDIUMslime/utils/reloadable_process_group.py511def _wrap_low_level_call(check_memory=True):CODE
LOWslime/utils/processing_utils.py127 except Exception:CODE
LOWslime/utils/processing_utils.py147 except Exception:CODE
LOWslime/utils/health_monitor.py150 except Exception as error:CODE
LOWslime/utils/cleanup.py28 except Exception as error:CODE
MEDIUMslime/utils/cleanup.py25def run(self, description, function, *args, **kwargs):CODE
LOWslime/utils/http_utils.py66 except Exception:CODE
LOWslime/utils/http_utils.py81 except Exception:CODE
LOWslime/utils/http_utils.py125 except Exception as e:CODE
LOWslime/utils/http_utils.py209 except Exception as e:CODE
LOWslime/utils/http_utils.py352 except Exception as e:CODE
MEDIUMslime/utils/http_utils.py117def run_router(args):CODE
LOWslime/utils/accelerator/__init__.py87 except Exception as exc:CODE
LOWslime/utils/accelerator/__init__.py140 except Exception as exc:CODE
LOWslime/utils/accelerator/__init__.py193 except Exception as exc:CODE
MEDIUMslime/utils/accelerator/__init__.py133def _import_torch_npu() -> bool:CODE
MEDIUMslime/utils/accelerator/__init__.py186def _import_torch_supa() -> bool:CODE
LOWslime/agent/parsing.py77 except Exception:CODE
LOWslime/agent/sandbox.py250 except Exception as e:CODE
LOWslime/agent/sandbox.py278 except Exception as e:CODE
LOWslime/agent/sandbox.py306 except Exception as e:CODE
LOWslime/agent/sandbox.py386 except Exception:CODE
MEDIUMslime/agent/sandbox.py302def __aexit__(self, exc_type, exc, tb) -> None:CODE
LOWslime/agent/aiohttp_threaded.py40 except Exception:CODE
LOWslime/agent/adapters/common.py306 except Exception:CODE
LOWslime/agent/adapters/common.py379 except Exception:CODE
LOWslime/agent/adapters/common.py639 except Exception:CODE
LOWslime/agent/adapters/common.py660 except Exception as exc:CODE
LOW⚡slime/observability/trace_utils.py399 except Exception as exc:CODE
LOW⚡slime/observability/trace_utils.py409 except Exception as trace_exc:CODE
LOW⚡slime/observability/trace_utils.py415 except Exception as exc:CODE
106 more matches not shown…
Deep Nesting184 hits · 175 pts
SeverityFileLineSnippetContext
LOWtrain.py103CODE
LOWtools/convert_torch_dist_to_hf_parallel.py57CODE
LOWtools/convert_torch_dist_to_hf_parallel.py84CODE
LOWtools/convert_torch_dist_to_hf_parallel.py165CODE
LOWtools/convert_torch_dist_to_hf_parallel.py60CODE
LOWtools/convert_torch_dist_to_hf_parallel.py170CODE
LOWtools/analyze_profile.py184CODE
LOWtools/analyze_profile.py338CODE
LOWtools/trace_timeline_viewer.py168CODE
LOWtools/convert_k2_thinking_int4_to_bf16.py99CODE
LOWtools/fp8_cast_bf16.py44CODE
LOWtools/convert_torch_dist_to_hf.py106CODE
LOWtools/convert_to_hf.py28CODE
LOWslime/backends/megatron_utils/stateless_adam.py68CODE
LOWslime/backends/megatron_utils/model.py356CODE
LOWslime/backends/megatron_utils/model.py724CODE
LOWslime/backends/megatron_utils/model.py98CODE
LOWslime/backends/megatron_utils/loss.py103CODE
LOWslime/backends/megatron_utils/loss.py448CODE
LOWslime/backends/megatron_utils/loss.py720CODE
LOWslime/backends/megatron_utils/loss.py973CODE
LOWslime/backends/megatron_utils/model_provider.py115CODE
LOWslime/backends/megatron_utils/model_provider.py321CODE
LOWslime/backends/megatron_utils/model_provider.py139CODE
LOWslime/backends/megatron_utils/ci_utils.py11CODE
LOWslime/backends/megatron_utils/actor.py298CODE
LOWslime/backends/megatron_utils/actor.py449CODE
LOWslime/backends/megatron_utils/cp_utils.py408CODE
LOWslime/backends/megatron_utils/data.py14CODE
LOWslime/backends/megatron_utils/server/megatron_server.py672CODE
LOWslime/backends/megatron_utils/server/logprob_utils.py303CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py470CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py642CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py3100CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py910CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py2253CODE
LOW…/backends/megatron_utils/alignment/deepgemm_forward.py1057CODE
LOW…atron_utils/update_weight/update_weight_from_tensor.py378CODE
LOW…atron_utils/update_weight/update_weight_from_tensor.py195CODE
LOWslime/backends/megatron_utils/update_weight/common.py59CODE
LOWslime/backends/megatron_utils/update_weight/common.py129CODE
LOW…atron_utils/update_weight/hf_weight_iterator_direct.py174CODE
LOW…ime/backends/megatron_utils/megatron_to_hf/qwen3_vl.py5CODE
LOW…e/backends/megatron_utils/megatron_to_hf/minimax_m2.py6CODE
LOW…ime/backends/megatron_utils/megatron_to_hf/__init__.py37CODE
LOW…ime/backends/megatron_utils/megatron_to_hf/qwen3moe.py6CODE
LOWslime/backends/megatron_utils/megatron_to_hf/llama.py5CODE
LOWslime/backends/megatron_utils/megatron_to_hf/qwen3_5.py34CODE
LOWslime/backends/megatron_utils/megatron_to_hf/glm4.py5CODE
LOW…e/backends/megatron_utils/megatron_to_hf/deepseekv3.py6CODE
LOWslime/backends/megatron_utils/megatron_to_hf/glm4moe.py6CODE
LOW…e/backends/megatron_utils/megatron_to_hf/qwen3_next.py44CODE
LOWslime/backends/megatron_utils/megatron_to_hf/qwen2.py5CODE
LOW…atron_utils/megatron_to_hf/processors/quantizer_fp8.py10CODE
LOWslime/backends/sglang_utils/server_control.py17CODE
LOWslime/backends/sglang_utils/server_control.py106CODE
LOWslime/backends/sglang_utils/deployment.py79CODE
LOWslime/backends/sglang_utils/sglang_engine.py77CODE
LOWslime/backends/sglang_utils/engine_group.py477CODE
LOWslime/backends/sglang_utils/engine_group.py342CODE
124 more matches not shown…
Unused Imports127 hits · 123 pts
SeverityFileLineSnippetContext
LOWtools/trace_timeline_viewer.py9CODE
LOWslime/backends/megatron_utils/sglang.py18CODE
LOWslime/backends/megatron_utils/sglang.py45CODE
LOWslime/backends/megatron_utils/sglang.py47CODE
LOWslime/backends/megatron_utils/server/__init__.py3CODE
LOWslime/backends/megatron_utils/server/__init__.py3CODE
LOWslime/backends/megatron_utils/server/__init__.py3CODE
LOWslime/backends/megatron_utils/alignment/env.py10CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py14CODE
LOW…ckends/megatron_utils/alignment/layerwise_alignment.py3CODE
LOW…/backends/megatron_utils/alignment/deepgemm_forward.py15CODE
LOW…egatron_utils/alignment/deterministic_route_kernels.py8CODE
LOW…egatron_utils/update_weight/update_weight_from_disk.py1CODE
LOWslime/backends/megatron_utils/update_weight/__init__.py1CODE
LOW…n_utils/update_weight/update_weight_from_disk_delta.py1CODE
LOW…_utils/update_weight/update_weight_from_distributed.py1CODE
LOW…s/megatron_utils/megatron_to_hf/processors/__init__.py1CODE
LOWslime/backends/megatron_utils/hf_to_megatron/glm.py1CODE
LOWslime/backends/megatron_utils/hf_to_megatron/qwen3_5.py1CODE
LOWslime/backends/megatron_utils/hf_to_megatron/common.py1CODE
LOWslime/backends/megatron_utils/hf_to_megatron/qwen.py1CODE
LOW…ime/backends/megatron_utils/hf_to_megatron/deepseek.py1CODE
LOW…e/backends/megatron_utils/hf_to_megatron/qwen3_next.py1CODE
LOWslime/backends/sglang_utils/external.py3CODE
LOWslime/utils/routed_experts.py1CODE
LOWslime/utils/dp_schedule.py40CODE
LOWslime/utils/eval_config.py1CODE
LOWslime/utils/disk_delta.py1CODE
LOWslime/utils/accelerator/supa.py12CODE
LOWslime/utils/accelerator/__init__.py8CODE
LOWslime/utils/accelerator/npu.py7CODE
LOWslime/utils/accelerator/musa.py7CODE
LOWslime/utils/accelerator/cuda.py3CODE
LOWslime/utils/accelerator/base.py8CODE
LOWslime/utils/accelerator/torch_accelerator.py3CODE
LOWslime/agent/parsing.py3CODE
LOWslime/agent/trajectory.py10CODE
LOWslime/agent/sandbox.py9CODE
LOWslime/agent/aiohttp_threaded.py3CODE
LOWslime/agent/adapters/responses.py9CODE
LOWslime/agent/adapters/__init__.py3CODE
LOWslime/agent/adapters/__init__.py4CODE
LOWslime/agent/adapters/__init__.py5CODE
LOWslime/agent/adapters/__init__.py6CODE
LOWslime/agent/adapters/openai.py16CODE
LOWslime/agent/adapters/common.py13CODE
LOWslime/agent/adapters/anthropic.py17CODE
LOWslime/agent/harness/codex.py8CODE
LOWslime/agent/harness/__init__.py3CODE
LOWslime/agent/harness/__init__.py5CODE
LOWslime/agent/harness/__init__.py6CODE
LOWslime/agent/harness/__init__.py7CODE
LOWslime/agent/harness/__init__.py7CODE
LOWslime/agent/harness/common.py16CODE
LOWslime/agent/harness/claude_code.py3CODE
LOWslime/observability/trace_utils.py1CODE
LOWslime/rollout/sample_hooks.py1CODE
LOWslime/rollout/base_types.py1CODE
LOWslime/rollout/fully_async_rollout.py29CODE
LOWslime/rollout/rm_hub/ifbench.py1CODE
67 more matches not shown…
Modern Structural Boilerplate112 hits · 116 pts
SeverityFileLineSnippetContext
LOW⚡slime/backends/megatron_utils/checkpoint.py93logger = logging.getLogger(__name__)CODE
LOW⚡slime/backends/megatron_utils/checkpoint.py95__all__ = ["save_checkpoint"]CODE
LOWslime/backends/megatron_utils/initialize.py15logger = logging.getLogger(__name__)CODE
LOW⚡slime/backends/megatron_utils/arguments.py13__all__ = ["validate_args", "megatron_parse_args", "set_default_megatron_args"]CODE
LOW⚡slime/backends/megatron_utils/arguments.py15logger = logging.getLogger(__name__)CODE
LOW⚡slime/backends/megatron_utils/model.py40logger = logging.getLogger(__name__)CODE
LOWslime/backends/megatron_utils/model_provider.py103def _set_critic_output_layer(model: torch.nn.Module, config: TransformerConfig) -> None:CODE
LOWslime/backends/megatron_utils/ci_utils.py8logger = logging.getLogger(__name__)CODE
LOWslime/backends/megatron_utils/hf_checkpoint_saver.py13logger = logging.getLogger(__name__)CODE
LOWslime/backends/megatron_utils/actor.py59logger = logging.getLogger(__name__)CODE
LOWslime/backends/megatron_utils/actor.py628 def update_weights(self) -> None:CODE
LOWslime/backends/megatron_utils/sglang.py49__all__ = [CODE
LOWslime/backends/megatron_utils/server/__init__.py9__all__ = [CODE
LOW…kends/megatron_utils/alignment/deepgemm_moe_forward.py38logger = logging.getLogger(__name__)CODE
LOW…ckends/megatron_utils/alignment/layerwise_alignment.py14logger = logging.getLogger(__name__)CODE
LOW…/backends/megatron_utils/alignment/deepgemm_forward.py26logger = logging.getLogger(__name__)CODE
LOW…egatron_utils/update_weight/update_weight_from_disk.py66 def update_weights(self) -> None:CODE
LOW…ackends/megatron_utils/update_weight/expert_routing.py14__all__ = ["configure_expert_routing"]CODE
LOW…ackends/megatron_utils/update_weight/expert_routing.py17logger = logging.getLogger(__name__)CODE
LOW…atron_utils/update_weight/update_weight_from_tensor.py287 def update_weights(self) -> None:CODE
LOW…n_utils/update_weight/update_weight_from_disk_delta.py30logger = logging.getLogger(__name__)CODE
LOW…n_utils/update_weight/update_weight_from_disk_delta.py90 def update_weights(self) -> None:CODE
LOW…_utils/update_weight/update_weight_from_distributed.py103 def update_weights(self) -> None:CODE
LOW…atron_to_hf/processors/quantizer_compressed_tensors.py15logger = logging.getLogger(__name__)CODE
LOW…atron_to_hf/processors/quantizer_compressed_tensors.py18__all__ = ["quantize_params_compressed_tensors"]CODE
LOW…s/megatron_utils/megatron_to_hf/processors/__init__.py3__all__ = ["quantize_params", "remove_padding"]CODE
LOWslime/backends/sglang_utils/server_control.py10logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/deployment.py15logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/sglang_engine.py19logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/arguments.py8logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/engine_group.py15logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/external.py11logger = logging.getLogger(__name__)CODE
LOWslime/backends/sglang_utils/disaggregation.py11logger = logging.getLogger(__name__)CODE
LOW⚡slime/backends/sglang_utils/sglang_config.py8logger = logging.getLogger(__name__)CODE
LOWslime/utils/reloadable_process_group.py17logger = logging.getLogger(__name__)CODE
LOWslime/utils/async_utils.py5__all__ = ["AsyncPacer", "get_async_loop", "run"]CODE
LOWslime/utils/routed_experts.py13logger = logging.getLogger(__name__)CODE
LOWslime/utils/dp_schedule.py48logger = logging.getLogger(__name__)CODE
LOWslime/utils/arguments.py17logger = logging.getLogger(__name__)CODE
LOWslime/utils/processing_utils.py10logger = logging.getLogger(__name__)CODE
LOWslime/utils/health_monitor.py7logger = logging.getLogger(__name__)CODE
LOWslime/utils/cleanup.py6logger = logging.getLogger(__name__)CODE
LOWslime/utils/http_utils.py12logger = logging.getLogger(__name__)CODE
LOWslime/utils/data.py19__all__ = ["Dataset", "get_source"]CODE
LOWslime/utils/data.py21logger = logging.getLogger(__name__)CODE
LOWslime/utils/memory_utils.py12logger = logging.getLogger(__name__)CODE
LOWslime/utils/accelerator/__init__.py30logger = logging.getLogger(__name__)CODE
LOWslime/utils/accelerator/__init__.py356def set_accelerator(accelerator: Accelerator) -> None:CODE
LOWslime/utils/accelerator/__init__.py393def set_device(index: int | str | torch.device) -> None:CODE
LOWslime/utils/accelerator/__init__.py491def set_rng_state(state: torch.Tensor, device_arg: int | str | torch.device | None = None) -> None:CODE
LOWslime/utils/accelerator/base.py37 def set_device(self, index: int | str | torch.device) -> None:CODE
LOWslime/utils/accelerator/base.py127 def set_rng_state(self, state: torch.Tensor, device: int | str | torch.device | None = None) -> None:CODE
LOWslime/utils/accelerator/torch_accelerator.py13logger = logging.getLogger(__name__)CODE
LOWslime/utils/accelerator/torch_accelerator.py42 def set_device(self, index: int | str | torch.device) -> None:CODE
LOWslime/utils/accelerator/torch_accelerator.py144 def set_rng_state(self, state: torch.Tensor, device: int | str | torch.device | None = None) -> None:CODE
LOWslime/agent/parsing.py12logger = logging.getLogger(__name__)CODE
LOWslime/agent/trajectory.py23logger = logging.getLogger(__name__)CODE
LOWslime/agent/trajectory.py581__all__ = [CODE
LOWslime/agent/sandbox.py20logger = logging.getLogger(__name__)CODE
LOWslime/agent/adapters/__init__.py8__all__ = ["AnthropicAdapter", "BaseAdapter", "OpenAIAdapter", "ResponsesAdapter"]CODE
52 more matches not shown…
Structural Annotation Overuse37 hits · 58 pts
SeverityFileLineSnippetContext
LOWslime/utils/ppo_utils.py585 # Step 3: Compute returns on full response kl tensor.COMMENT
LOW⚡tests/ci/README.md11### Step 1: EnvCOMMENT
LOW⚡tests/ci/README.md18### Step 2: Prepare `/home/runner/externals`COMMENT
LOW⚡tests/ci/README.md28### Step 3: RunCOMMENT
LOW.claude/skills/add-rollout-function/SKILL.md20### Step 1: Choose the Right Starting PointCOMMENT
LOW.claude/skills/add-rollout-function/SKILL.md30### Step 2: Create the New Rollout ModuleCOMMENT
LOW.claude/skills/add-rollout-function/SKILL.md43### Step 3: Implement Train and Eval Branches ExplicitlyCOMMENT
LOW.claude/skills/add-rollout-function/SKILL.md70### Step 4: Keep Data Contract CompatibleCOMMENT
LOW.claude/skills/add-rollout-function/SKILL.md81### Step 5: Wire Through ArgumentsCOMMENT
LOW.claude/skills/add-reward-function/SKILL.md20### Step 1: Choose Reward ModeCOMMENT
LOW.claude/skills/add-reward-function/SKILL.md29### Step 2: Create Reward ModuleCOMMENT
LOW.claude/skills/add-reward-function/SKILL.md47### Step 3: Keep Reward Type ConsistentCOMMENT
LOW.claude/skills/add-reward-function/SKILL.md53### Step 4: Optional Reward Post-ProcessingCOMMENT
LOW.claude/skills/add-reward-function/SKILL.md71### Step 5: Wire and ValidateCOMMENT
LOW.claude/skills/add-eval-dataset-config/SKILL.md20### Step 1: Choose Config Entry MethodCOMMENT
LOW.claude/skills/add-eval-dataset-config/SKILL.md29### Step 2: Build YAML with Required FieldsCOMMENT
LOW.claude/skills/add-eval-dataset-config/SKILL.md54### Step 3: Understand Override PriorityCOMMENT
LOW.claude/skills/add-eval-dataset-config/SKILL.md68### Step 4: Wire Eval Function if NeededCOMMENT
LOW.claude/skills/add-eval-dataset-config/SKILL.md73### Step 5: Validate Parsing and RuntimeCOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md21### Step 1: Pick the Right Test PatternCOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md27### Step 2: Keep CI CompatibilityCOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md43### Step 3: Register Tests in GitHub CICOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md60### Step 4: Run Local ValidationCOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md67### Step 5: Keep Workflow Template as Source of TruthCOMMENT
LOW.claude/skills/add-tests-and-ci/SKILL.md80### Step 6: Provide Verifiable PR NotesCOMMENT
LOW.claude/skills/add-dynamic-filter/SKILL.md21### Step 1: Pick the Correct HookCOMMENT
LOW.claude/skills/add-dynamic-filter/SKILL.md28### Step 2: Implement the Function SignatureCOMMENT
LOW.claude/skills/add-dynamic-filter/SKILL.md66### Step 3: Preserve Group StructureCOMMENT
LOW.claude/skills/add-dynamic-filter/SKILL.md72### Step 4: Wire and ValidateCOMMENT
LOW.claude/skills/add-dynamic-filter/SKILL.md83### Step 5: Measure Side EffectsCOMMENT
LOWdocs/en/advanced/sglang-config.md267# Step 1: Launch SGLang engines externallyCOMMENT
LOWdocs/en/advanced/sglang-config.md271# Step 2: Connect slime to external enginesCOMMENT
LOWexamples/search-r1/README.md187### Step 1: Install CondaCOMMENT
LOWexamples/search-r1/README.md204### Step 2: Create Retriever EnvironmentCOMMENT
LOWexamples/search-r1/README.md222### Step 3: Download Index and CorpusCOMMENT
LOWexamples/search-r1/README.md240### Step 4: Start Local Retrieval ServerCOMMENT
LOWexamples/search-r1/README.md275### Step 5: Start TrainingCOMMENT
Self-Referential Comments15 hits · 40 pts
SeverityFileLineSnippetContext
MEDIUMslime/backends/megatron_utils/model_provider.py176 # Define the decoder block specCOMMENT
MEDIUMslime/backends/megatron_utils/model_provider.py184 # Define the decoder layer specCOMMENT
MEDIUMslime/utils/async_utils.py45# Create a background event loop threadCOMMENT
MEDIUMslime/utils/http_utils.py286 # Define the async actorCOMMENT
MEDIUMslime/rollout/rm_hub/__init__.py73 # This function is intended for remote or time-consuming reward model evaluation.COMMENT
MEDIUMdocs/build_all.sh11# Create a lightweight root index with auto redirect based on localStorage (done client side)COMMENT
MEDIUMexamples/tau-bench/trainable_agents.py213 # Initialize tracking variablesCOMMENT
MEDIUMexamples/strands_sglang/subprocess_interpreter.py186 # Create a temporary file with the modified sourceSTRING
MEDIUMexamples/strands_sglang/subprocess_interpreter.py352 # Create a temporary directory first to ensure we have writeSTRING
MEDIUM.github/workflows/pr-test.yml2# This file is auto-generated from the .j2 file via generate_github_workflows.py. Do not edit manually.COMMENT
MEDIUM.github/workflows/generate_github_workflows.py27 + "\n# This file is auto-generated from the .j2 file via generate_github_workflows.py. Do not edit manuaCODE
MEDIUMslime_plugins/models/qwen3_5.py203 # Define the decoder block specCOMMENT
MEDIUMslime_plugins/models/qwen3_next.py215 # Define the decoder block specCOMMENT
MEDIUMslime_plugins/models/glm5/glm5.py1015 # Define the decoder block specCOMMENT
MEDIUM…ime_plugins/rollout_buffer/generator/base_generator.py53 # Create a fresh payload for each attemptCOMMENT
AI Slop Vocabulary10 hits · 32 pts
SeverityFileLineSnippetContext
LOW…atron_utils/megatron_to_hf/processors/quantizer_fp8.py115 # for other parameters, we just return the original converted_named_paramsCOMMENT
LOWslime/backends/sglang_utils/engine_group.py233 # this group's engines may land on (conservative: just use global max).COMMENT
MEDIUMslime/agent/harness/codex.py34 # an unprivileged PRoot sandbox. Never use this harness directly on the host.COMMENT
MEDIUMslime/rollout/rm_hub/math_dapo_utils.py14# Adapted from https://github.com/EleutherAI/lm-evaluation-harness/blob/main/lm_eval/tasks/hendrycks_math/utils.pyCOMMENT
MEDIUM⚡tests/test_agent/test_harness.py209# §5 harness.run wires the steps in orderCOMMENT
MEDIUM⚡examples/coding_agent_rl/swe.py181# Workspace prep (agent sandbox, before harness.run)COMMENT
MEDIUM⚡examples/coding_agent_rl/swe.py235# Diff capture (agent sandbox, after harness.run)COMMENT
MEDIUMexamples/coding_agent_rl/swe.py386# Mirror of swebench.harness.run_evaluation.GIT_APPLY_CMDS: try each in order,COMMENT
MEDIUMexamples/retool/generate_with_retool.py100 # Use a more robust regex that handles nested bracesCOMMENT
MEDIUMexamples/retool/generate_with_retool.py370 # collapse), but reward_func's regex is whitespace-robust andCOMMENT
Docstring Block Structure5 hits · 25 pts
SeverityFileLineSnippetContext
HIGHslime/backends/sglang_utils/sglang_engine.py235Run /health_generate on the underlying SGLang HTTP server. Args: timeout: Timeout for the health reSTRING
HIGHexamples/tau-bench/openai_tool_adapter.py52 Parse sglang response to OpenAI compatible format Args: response: Raw response text from sSTRING
HIGHexamples/tau-bench/generate_with_tau.py101 Generate a complete agent-environment interaction trajectory for tau-bench. This is the main entry point for sSTRING
HIGHexamples/strands_sglang/subprocess_interpreter.py286Generates a temporary file with the given code, executes it, and deletes the file afterward. Args: STRING
HIGHexamples/strands_sglang/subprocess_interpreter.py440Executes a shell command in a subprocess and captures its output. Args: command (str): The shell coSTRING
Modern AI Meta-Vocabulary10 hits · 23 pts
SeverityFileLineSnippetContext
MEDIUMREADME.md97[Dressage](https://github.com/Accio-Lab/Dressage) — Alibaba Accio’s agentic RL framework, with Paddock, Sandbox, and ProCODE
MEDIUMREADME.md109[Relax](https://github.com/redai-infra/Relax) — RedAI Infra’s multimodal agentic RL framework, using Ray Serve, TransferCODE
MEDIUMtests/test_qwen3_4B_streaming_partial_rollout.py36 # loop is still the stock sglang one (semaphore, abort orchestration).COMMENT
MEDIUMdocs/zh/get_started/customization.md12| [`--custom-generate-function-path`](#custom-generate-function-path) | 仅覆盖生成步骤(例如用于 RAG 或工具调用)。 |CODE
MEDIUMdocs/zh/get_started/customization.md32## 通过 customization 接口实现 agentic workflowCOMMENT
MEDIUMdocs/en/get_started/customization.md12| [`--custom-generate-function-path`](#custom-generate-function-path) | Override only the generation step (e.g., for RAGCODE
MEDIUMexamples/multi_agent/run-qwen3-30B-A3B-multi-agent.sh57# multi-agent do not support eval for nowCOMMENT
MEDIUMexamples/tau-bench/README.md50 "agent_strategy": "tool-calling", # Select between ["tool-calling", "act", "react", "few-shot"], only tool-calling CODE
MEDIUMexamples/tau-bench/generate_with_tau.py25 "agent_strategy": "tool-calling", # Select between ["tool-calling", "act", "react", "few-shot"]CODE
MEDIUMexamples/strands_sglang/README.md3This example connects `slime` with [`strands-sglang`](https://github.com/horizon-rl/strands-sglang) (SGLang extension foCODE
Redundant / Tautological Comments14 hits · 19 pts
SeverityFileLineSnippetContext
LOWtools/convert_torch_dist_to_hf_parallel.py475 # Check if this is a linear_q_down_proj or linear_kv_down_proj keyCOMMENT
LOWslime/backends/megatron_utils/model.py560 # Set grad to zero.COMMENT
LOWslime/backends/megatron_utils/model_provider.py126 # Check if the custom provider supports vp_stage parameterCOMMENT
LOWslime/backends/megatron_utils/model_provider.py227 # Check if fp8_model_init supports preserve_high_precision_init_valCOMMENT
LOWexamples/tau-bench/trainable_agents.py326 # Check if doneCOMMENT
LOWexamples/strands_sglang/subprocess_interpreter.py195 # Check if command is availableSTRING
LOWexamples/strands_sglang/subprocess_interpreter.py208 # Check if command is availableSTRING
LOWexamples/search-r1/qa_em_format.py86 # Check if this is a tagCOMMENT
LOWexamples/retool/tool_sandbox.py242 # Return resultCOMMENT
LOWexamples/retool/generate_with_retool.py250 # Check if total length exceeds max context lengthCOMMENT
LOWexamples/retool/generate_with_retool.py352 # Check if maximum tool call count reachedCOMMENT
LOWslime_plugins/rollout_buffer/buffer.py77 # Check if module has TASK_TYPE constantCOMMENT
LOWslime_plugins/rollout_buffer/buffer.py82 # Check if module has run_rollout functionCOMMENT
LOW…ime_plugins/rollout_buffer/generator/base_generator.py216 # Check if instance_id should be skippedCOMMENT
AI Structural Patterns18 hits · 18 pts
SeverityFileLineSnippetContext
LOWtools/convert_hf_to_int4_direct.py120CODE
LOWslime/backends/megatron_utils/stateless_adam.py16CODE
LOW…atron_to_hf/processors/quantizer_compressed_tensors.py225CODE
LOWslime/backends/sglang_utils/sglang_engine.py395CODE
LOWslime/utils/distributed_utils.py55CODE
LOWslime/utils/data.py215CODE
LOWtests/test_qwen2.5_0.5B_pipeline_rl.py28CODE
LOWtests/test_qwen2.5_0.5B_training_recovery.py141CODE
LOWexamples/tau-bench/openai_tool_adapter.py109CODE
LOW…es/search-r1/local_dense_retriever/retrieval_server.py290CODE
LOWexamples/retool/tool_sandbox.py356CODE
LOWslime_plugins/models/qwen3_5_vl.py205CODE
LOWslime_plugins/models/qwen3_5.py153CODE
LOWslime_plugins/models/hf_attention.py65CODE
LOWslime_plugins/models/qwen3_next.py175CODE
LOWslime_plugins/models/glm5/glm5.py413CODE
LOW…ime_plugins/models/glm5/ops/tilelang_sparse_mla_bwd.py84CODE
LOWslime_plugins/rollout_buffer/buffer.py116CODE
Over-Commented Block17 hits · 17 pts
SeverityFileLineSnippetContext
LOWslime/utils/seqlen_balancing.py1# Copied from https://github.com/volcengine/verl/blob/468adf22c43b744348051fccd7a5d830c6c3c36a/verl/utils/seqlen_balanciCOMMENT
LOWslime/utils/routing_replay.py61 # SGLang's deterministic DeepSeek/GLM biased top-k usesCOMMENT
LOWslime/utils/data.py321 # flattened rollout batch (== its index in the rollout debug dump'sCOMMENT
LOWslime/rollout/rm_hub/math_dapo_utils.py1# Copyright 2024 Bytedance Ltd. and/or its affiliatesCOMMENT
LOWtests/test_loss_cp_invariance.py161COMMENT
LOWtests/_cp_dist_helpers.py41import sysCOMMENT
LOWtests/_cp_dist_helpers.py141# tests and the backward-grad-norm test. Keeping the data in one place soCOMMENT
LOWexamples/delta_weight_sync/run-glm4.7-30B-A3B-delta.sh1#!/bin/bashCOMMENT
LOWexamples/train_infer_mismatch_helper/mis.yaml1# Enable importance sampling, details refer to the comments of compute_mis_weights in mis.pyCOMMENT
LOWexamples/strands_sglang/subprocess_interpreter.py1# Copyright 2025-2026 Strands RL ContributorsCOMMENT
LOWexamples/search-r1/qa_em_format.py1# Adapt from https://github.com/PeterGriffinJin/Search-R1/blob/ceee7b89655ed52f205b9beb98e1190c3eedcfb0/verl/utils/rewarCOMMENT
LOW…es/search-r1/local_dense_retriever/retrieval_server.py1# Copyright 2024 Bytedance Ltd. and/or its affiliatesCOMMENT
LOWexamples/search-r1/local_dense_retriever/download.py1# Copyright 2024 Bytedance Ltd. and/or its affiliatesCOMMENT
LOWexamples/retool/generate_with_retool.py361 # Tool output is appended verbatim and can push total_length pastCOMMENT
LOWscripts/run-qwen2.5-0.5B-gb10-smoke.sh1#!/bin/bashCOMMENT
LOWscripts/low_precision/run-qwen3-30b-a3b-fp8.sh1#!/bin/bashCOMMENT
LOWslime_plugins/models/glm5/glm5.py121 with torch.no_grad():COMMENT
Cross-File Repetition3 hits · 15 pts
SeverityFileLineSnippetContext
HIGHtests/test_qwen3_4B_ppo_train_critic_only.py0megatron: - name: default role: critic overrides: lr: 1e-5 - name: default role: actor overrides: lr: 1e-6STRING
HIGHtests/test_qwen3_4B_ppo.py0megatron: - name: default role: critic overrides: lr: 1e-5 - name: default role: actor overrides: lr: 1e-6STRING
HIGHtests/test_qwen3_4B_ppo_disaggregate.py0megatron: - name: default role: critic overrides: lr: 1e-5 - name: default role: actor overrides: lr: 1e-6STRING
Fake / Example Data8 hits · 7 pts
SeverityFileLineSnippetContext
LOWslime/backends/sglang_utils/engine_group.py79 worker_type: str = "regular" # "regular", "prefill", "decode", or "placeholder"CODE
LOWslime/backends/sglang_utils/engine_group.py139 Placeholder groups (worker_type="placeholder") skip engine creation entirely.STRING
LOWslime/backends/sglang_utils/engine_group.py143 if self.args.debug_train_only or self.worker_type == "placeholder":CODE
LOWslime/backends/sglang_utils/engine_group.py337 values = {g.nodes_per_engine for g in self.server_groups if g.worker_type != "placeholder"}CODE
LOWslime/backends/sglang_utils/engine_group.py460 all_engines=[None] * num_engines if group_config.worker_type != "placeholder" else [],CODE
LOW⚡slime/backends/sglang_utils/sglang_config.py16 worker_type: One of "regular", "prefill", "decode", "placeholder",STRING
LOW⚡slime/backends/sglang_utils/sglang_config.py18 "placeholder" reserves GPU slots without creating engines.STRING
LOWslime/backends/sglang_utils/sglang_config.py37 valid_types = {"regular", "prefill", "decode", "placeholder", "encoder"}CODE
Slop Phrases2 hits · 5 pts
SeverityFileLineSnippetContext
MEDIUMslime/rollout/on_policy_distillation.py64 # If you have task rewards, you can add them here.COMMENT
MEDIUMexamples/on_policy_distillation/run-qwen3-8B-opd.sh9TEACHER_IP="127.0.0.1" # Use localhost here, you can change it to your IPCODE
Verbosity Indicators1 hit · 2 pts
SeverityFileLineSnippetContext
LOWslime/utils/ppo_utils.py585 # Step 3: Compute returns on full response kl tensor.COMMENT