This report summarizes scanner evidence for meituan-longcat/LongCat-Video, a Python project with 9,453 GitHub stars. SynthScan examined 14,027 lines of code across 41 source files, recording 109 pattern matches distributed across 11 syntactic categories. The legacy adjusted pattern signal is 9.7 (Moderate 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.
Use each vector to guide manual verification of the underlying findings.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-11-15.
Can maintainers explain intent, assumptions, and trade-offs? 83 finding(s).
Are imports declared and package/API names verified? 12 finding(s).
Are wrappers, guards, and repeated structures necessary? 75 finding(s).
Which changes need focused human review? 109 finding(s).
Run additional scans to build a history of the legacy pattern signal. Score changes are not a measure of AI adoption or code quality.
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.
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.
The scanner identified 109 distinct pattern matches across 11 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.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | run_demo_avatar_multi_audio_to_video.py | 44 | def extract_vocal_from_speech(source_path, vocal_separator, duration): | CODE |
| LOW | longcat_video/pipeline_longcat_video.py | 290 | def do_classifier_free_guidance(self): | STRING |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 472 | def do_classifier_free_guidance(self): | STRING |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 610 | def _resize_and_centercrop_tensor(self, mask: torch.Tensor, target_h: int, target_w: int, resize_mode: str = 'crop') | STRING |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 663 | def get_audio_embedding_whisper(self, speech_array, fps=25, device='cpu', sample_rate=16000, | STRING |
| LOW | longcat_video/audio_process/__init__.py | 14 | def get_audio_feature_extractor(checkpoint_path, model_type="avatar-v1.0"): | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 174 | def _attn_fwd_bsa_varlen_align( | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 290 | def _attn_bwd_dkdv_bsa_varlen( | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 428 | def _attn_bwd_dq_bsa_varlen_align( | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 505 | def _attn_bwd_dkdv_bsa_varlen_wrapper( | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 665 | def _attn_bwd_dq_bsa_varlen_wrapper( | CODE |
| LOW | …o/block_sparse_attention/flash_attn_bsa_varlen_mask.py | 816 | def _attn_bwd_dq_bsa_varlen_align_wrapper( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 87 | def get_tma_descriptor_kernel_param(self, name): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 97 | def create_mask_from_indices_kernel( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 116 | def create_mask_from_indices_triton( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 132 | def create_mask_from_indices_varlen(block_indices, N_cols_mask): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 152 | def create_indices_k_from_indices_q_varlen( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 213 | def get_select_indices_topk_from_score(score, sparsity): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 234 | def get_select_indices_cdf_from_score(score, cdf_threshold, sm_scale): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 246 | def get_select_indices_cdf_topk(q, k, sparsity, cdf_threshold): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 253 | def get_select_indices_cdf_topk_from_score(score, sparsity, cdf_threshold, sm_scale): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 279 | def get_select_indices_from_score(score, sparsity, cdf_threshold): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 290 | def attn_fwd_bsa_varlen_triton( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 343 | def attn_bwd_bsa_varlen_triton( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 464 | def make_block_indices_varlen_cp_list(block_indices, cp_size, num_blocks_k_full): | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 491 | def flash_attn_fwd_softmax_lse_correction( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 504 | def flash_attn_fwd_out_correction_init( | CODE |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 517 | def flash_attn_fwd_out_correction( | CODE |
| LOW | longcat_video/modules/longcat_video_dit.py | 234 | def _create_multi_lora_forward(self, module, loras): | CODE |
| LOW | …_video/modules/scheduling_flow_match_euler_discrete.py | 228 | def stretch_shift_to_terminal(self, t: torch.Tensor) -> torch.Tensor: | CODE |
| LOW⚡ | longcat_video/modules/autoencoder_kl_wan.py | 1173 | def enable_decoder_fused_padding(self) -> None: | STRING |
| LOW⚡ | longcat_video/modules/autoencoder_kl_wan.py | 1178 | def enable_decoder_cache_views(self) -> None: | STRING |
| LOW⚡ | longcat_video/modules/autoencoder_kl_wan.py | 1183 | def enable_encoder_fused_padding(self) -> None: | STRING |
| LOW⚡ | longcat_video/modules/autoencoder_kl_wan.py | 1188 | def enable_encoder_cache_views(self) -> None: | STRING |
| LOW | longcat_video/modules/quantization.py | 93 | def save_quantized_state_dict(model: nn.Module, save_dir: str, config_source_dir: Optional[str] = None): | CODE |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 415 | def _create_multi_lora_forward(self, module, loras): | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 280 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 282 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 309 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 311 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 344 | # ========================================= | COMMENT |
| MEDIUM | run_demo_avatar_single_audio_to_video.py | 346 | # ========================================= | COMMENT |
| MEDIUM | run_demo_avatar_multi_audio_to_video.py | 374 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_multi_audio_to_video.py | 376 | # ============================== | COMMENT |
| MEDIUM | run_demo_avatar_multi_audio_to_video.py | 442 | # ========================================= | COMMENT |
| MEDIUM | run_demo_avatar_multi_audio_to_video.py | 444 | # ========================================= | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | longcat_video/pipeline_longcat_video.py | 215 | CODE | |
| LOW | longcat_video/pipeline_longcat_video.py | 402 | CODE | |
| LOW | longcat_video/pipeline_longcat_video.py | 613 | CODE | |
| LOW | longcat_video/pipeline_longcat_video.py | 837 | CODE | |
| LOW | longcat_video/pipeline_longcat_video.py | 1098 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 389 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 760 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 992 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 1278 | CODE | |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 660 | CODE | |
| LOW | longcat_video/context_parallel/ulysses_wrapper.py | 150 | CODE | |
| LOW | longcat_video/context_parallel/ulysses_wrapper.py | 159 | CODE | |
| LOW | longcat_video/modules/longcat_video_dit.py | 130 | CODE | |
| LOW | …_video/modules/scheduling_flow_match_euler_discrete.py | 91 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 550 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 832 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 1005 | CODE | |
| LOW | longcat_video/modules/blocks.py | 69 | CODE | |
| LOW | longcat_video/modules/lora_utils.py | 24 | CODE | |
| LOW | longcat_video/modules/avatar/attention.py | 287 | CODE | |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 25 | CODE | |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 98 | CODE | |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 200 | CODE | |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 461 | CODE | |
| LOW | longcat_video/modules/avatar/blocks.py | 9 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | run_streamlit.py | 70 | CODE | |
| LOW | run_demo_avatar_single_audio_to_video.py | 36 | CODE | |
| LOW | run_demo_avatar_multi_audio_to_video.py | 98 | CODE | |
| LOW | longcat_video/pipeline_longcat_video.py | 1340 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 389 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 1278 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 1650 | CODE | |
| LOW | longcat_video/utils/bukcet_config.py | 91 | CODE | |
| LOW | longcat_video/modules/longcat_video_dit.py | 211 | CODE | |
| LOW | longcat_video/modules/attention.py | 50 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 254 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 285 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 550 | CODE | |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 1329 | CODE | |
| LOW | longcat_video/modules/avatar/attention.py | 61 | CODE | |
| LOW | longcat_video/modules/avatar/attention.py | 118 | CODE | |
| LOW | longcat_video/modules/avatar/attention.py | 447 | CODE | |
| LOW | …ngcat_video/modules/avatar/longcat_video_dit_avatar.py | 392 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 1 | CODE | |
| LOW | longcat_video/pipeline_longcat_video_avatar.py | 5 | CODE | |
| LOW | longcat_video/audio_process/torch_utils.py | 3 | CODE | |
| LOW | longcat_video/audio_process/torch_utils.py | 9 | CODE | |
| LOW | longcat_video/audio_process/torch_utils.py | 11 | CODE | |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 14 | CODE | |
| LOW | longcat_video/block_sparse_attention/bsa_interface.py | 16 | CODE | |
| LOW | longcat_video/modules/rope_3d.py | 5 | CODE | |
| LOW | longcat_video/modules/lora_utils.py | 7 | CODE | |
| LOW | longcat_video/modules/lora_utils.py | 8 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | longcat_video/modules/attention.py | 245 | attn_bias = xformers.ops.fmha.attn_bias.BlockDiagonalMask.from_seqlens([N] * B, kv_seqlen) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | run_streamlit.py | 80 | except Exception as e: | CODE |
| LOW | longcat_video/utils/prompt_enhancer.py | 144 | except Exception as e: | CODE |
| LOW | longcat_video/utils/prompt_enhancer.py | 181 | except Exception as e: | CODE |
| LOW | longcat_video/modules/lora_utils.py | 117 | except Exception as e: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …_video/modules/scheduling_flow_match_euler_discrete.py | 1 | # Copyright 2025 Stability AI, Katherine Crowson and The HuggingFace Team. All rights reserved. | COMMENT |
| LOW | longcat_video/modules/autoencoder_kl_wan.py | 1 | # Copyright 2025 The Wan Team and The HuggingFace Team. All rights reserved. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | longcat_video/modules/quantization.py | 76 | # Check if this module should be skipped | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | README.md | 30 | <img src='assets/title_placeholder.svg' alt="placeholder"> | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | longcat_video/modules/autoencoder_kl_wan.py | 474 | # Create the components | STRING |