Papers › EraseSAE: Surgical Concept Erasure in Text-to-Video Diffusion Models via Sparse Autoencoders

EraseSAE: Surgical Concept Erasure in Text-to-Video Diffusion Models via Sparse Autoencoders

3 Sep 2026arXiv:2609.03629added by Syntology

Xinghao Wang, Dong Li, Wei Yu, Yingwei Pan, Tao Gong, Qi Chu, Nenghai Yu, Ting Yao

Title, abstract, authors and date from arXiv's metadata (CC0); this paper is not in the Papers with Code archive (frozen 2025-07-28).

Recent advances in text-to-video (T2V) diffusion models have demonstrated remarkable generative capabilities, yet their reliance on loosely curated training data raises pressing safety and copyright concerns. Concept erasure offers a principled remedy by removing unwanted semantics from pretrained models while preserving remaining concepts. However, existing approaches typically operate at a coarse granularity misaligned with the fine-grained, distributed nature of concept representations, leading to incomplete removal or degraded generation quality. We argue that surgical erasure fundamentally requires intervention at the level of monosemantic features, where each unit encodes a single interpretable concept. To this end, we propose EraseSAE, a novel framework that leverages sparse autoencoders to achieve surgical concept erasure in DiT-based T2V diffusion models via a principled decompose-attribute-erase pipeline. We first introduce the Partitioned Convolutional Sparse Autoencoder, which decomposes dense spatiotemporal activations into disentangled, interpretable sparse features while preserving spatiotemporal coherence. A contrastive attribution mechanism then contrasts activations from paired prompts to isolate concept-specific feature kernels. At inference, timestep-resolved spatiotemporal masks derived from the identified kernels confine erasure to regions where the target concept is active, leaving unrelated content intact. Extensive experiments across diverse diffusion models and concept erasure tasks demonstrate that EraseSAE achieves precise and robust concept removal with minimal quality degradation, substantially outperforming state-of-the-art methods. The code is available at https://github.com/HiDream-ai/EraseSAE.

PaperPDFCode Syntology ran

In Syntology View this paper on Syntology, its page in Syntology's graph. That page adds which of its functions are also present in other papers' code Syntology holds, with dates, and its dated run record as JSON and a README badge. It also lists the repositories linked to the paper, the abstract and the calls for agents.

Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, on Syntology's MCP service (how to connect):

Code

Syntology 24 code samples harvested from 1 repository linked to this paper: 23 ran (of which 0 constructed an object rather than computing a result; 19 with no instrument failure: 0 honoured, 1 violated, 18 with no contract checked; 4 where Syntology's instrument failed) · 1 unverified. Where Syntology's instrument failed: 4 where our contract draft was wrong; failures of Syntology's instrument, not of the code.

By repository: found in paper text by Syntology: 24 samples from 1 repository, 23 ran (19 with no instrument failure; 4 where Syntology's instrument failed). The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

Levels written on 2026-09-26 (UTC): the dates Syntology's graph wrote each sample's verification level, not when the code executed.

HiDream-ai/EraseSAE found in paper text by SyntologySyntology: 24 samples, 23 ran (4 instrument-failed) · 1 unverified report

Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

24 samples harvested: 23 ran (of which 0 constructed an object rather than computing a result; 19 with no instrument failure: 0 honoured, 1 violated, 18 with no contract checked; 4 where Syntology's instrument failed) · 1 unverified. “Where Syntology's instrument failed” counts failures of Syntology's instrument, not of the code. Syntology's record for this page last changed ; when this build read Syntology's graph is in the build record. That date is not when the samples ran.

1ran · violated contract
4ran · our draft was wrong
18ran
1unverified

Licence: 24 of the 24 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from HiDream-ai/EraseSAE. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. A line beginning “fixture:” under a sample that ran gives the arguments Syntology's fixture called the sample with, each as name:type/rank/element kind (? where none was recorded), and the type of what the fixture's run returned, exactly as the harness recorded them; the arguments and the returned type were recorded by two separate runs of the same fixture. No output value is shown, and a returned type says nothing about whether the output was right. “Level recorded” gives the UTC date when Syntology's graph wrote the sample's verification level, not when the code executed; where the level was written before Syntology's graph kept that date, the row says “level recorded, date not recorded”. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself. “Our draft was wrong” and “the contract check could not run” are failures of Syntology's instrument, not of the code: the sample ran on Syntology's synthesized input, and then the drafted contract did not describe it, or the check itself raised an error (RAISES), lacked a dependency (DEP_MISSING) or ran out of time (TIMEOUT); hover the label for which. A metamorphic tier, where shown, is evidence of the output's shape, not that the sample implements the method.

Each sample ends with its code_sha256. A sample's code_sha256 is Syntology's identity for that exact code. It is printed in full (16 hexadecimal characters for every sample in this build), and get_code(code_sha256="…") takes it exactly as printed. An agent calls it on Syntology's MCP service (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples are grouped by repository: a repository marked official first, then by how directly the repository is tied to the paper, then in the archive's order; never by how many ran. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of six reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar); this paper's copy was not located, so its licence is not recorded; or this paper's copy is cleared, but the stored copy of the same code that Syntology serves is not. Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

A function or class name links to its page when the name occurs in the harvested code of at least 5 papers; the name is a string, not an identity.

HiDream-ai/EraseSAE found in paper text by Syntology 24 samples, 23 ran (4 instrument-failed) · 1 unverified
activation_references_for_kernels inference/cli_utils.py ran no licence file found · pointer only · b2e81a1edccffb1a · report fixture: signature identity_map:dict/0/?, target_identity:str/0/str, kernels:list/1/int · returned list · level recorded 2026-09-26
binarize_attention_mask model/attention_masks.py ran no licence file found · pointer only · 90dc9ff2abfdc2d3 · report fixture: signature mask:Tensor/3/float, quantile:float/0/float, dilation:int/0/int · returned Tensor · level recorded 2026-09-26
build_penalty_mask model/celebrity_partitioned_sae.py ran no licence file found · pointer only · e1b1606d33030e87 · report fixture: signature labels:Tensor/1/int, mask:Tensor/5/float, f_id:Tensor/5/float, raw_model:callable/0/?, is_5d:bool/0/bool · returned Tensor · level recorded 2026-09-26
calculate_aux_loss model/celebrity_partitioned_sae.py ran no licence file found · pointer only · 802b53bdfe8de1fc · report fixture: signature raw_model:callable/0/?, out:dict/0/?, residual:Tensor/4/float, branch:str/0/str, valid_mask:Tensor/4/float · returned Tensor · level recorded 2026-09-26
capture_effective_mask inference/mask_artifacts.py ran no licence file found · pointer only · 2e3b3b46446742c4 · report fixture: signature pipe:MockPipe/0/?, step_index:int/0/int · returned dict · level recorded 2026-09-26
checkpoint_pointer_path model/checkpoint_io.py ran no licence file found · pointer only · 00665b8a9cafb385 · report fixture: signature root:PosixPath/0/?, layer_name:str/0/str, checkpoint_type:str/0/str · returned PosixPath · level recorded 2026-09-26
compute_cross_attention_mask model/attention_masks.py ran no licence file found · pointer only · 83a19197727095ac · report fixture: signature query:Tensor/3/float, key:Tensor/3/float, token_idx:Tensor/1/int, head_num:int/0/int, text_len:int/0/int, height:int/0/int, width:int/0/int, text_first:bool/0/bool, query_chunk_size:int/0/int, key_chunk_size:int/0/int, use_fp16:bool/0/bool · returned Tensor · level recorded 2026-09-26
create_dataloader_for_layer training/cog_celebs.py ran no licence file found · pointer only · 324a38e38c776a3d · report fixture: signature data_root_dir:str/0/str, mean:Tensor/2/float, std:Tensor/2/float, layer_name:str/0/str, batch_size:int/0/int, rank:int/0/int, world_size:int/0/int, target_celebs:list/1/str · returned tuple · level recorded 2026-09-26
create_dataloader_for_layer training/cog_nudity.py ran no licence file found · pointer only · 0001b6cf0099e7f8 · report fixture: signature data_root_dir:str/0/str, mean:Tensor/1/float, std:Tensor/1/float, layer_name:str/0/str, batch_size:int/0/int, rank:int/0/int, world_size:int/0/int, target_celebs:list/1/str · returned tuple · level recorded 2026-09-26
get_partition_schedule model/partition_objectives.py ran no licence file found · pointer only · 831d18d1d3b9d7c8 · report fixture: signature epoch:int/0/int, total_epochs:int/0/int, leak_start_fraction:float/0/float · returned dict · level recorded 2026-09-26
get_warmup_schedule model/celebrity_partitioned_sae.py ran no licence file found · pointer only · 42334cbdfccc3fce · report fixture: signature epoch:int/0/int, total_epochs:int/0/int, leak_start_fraction:float/0/float · returned dict · level recorded 2026-09-26
load_checkpoint_model_config model/checkpoint_io.py ran no licence file found · pointer only · e03692116e99085d · report fixture: signature checkpoint:PosixPath/0/?, layer_name:str/0/str, checkpoint_type:str/0/str · returned dict · level recorded 2026-09-26
load_json in 344 papers configs/config_loader.py ran · our draft was wrong no licence file found · pointer only · 30180de1929a7196 · report fixture: signature path:str/0/str · returned dict · level recorded 2026-09-26
ordered_concepts_from_map inference/cli_utils.py ran · our draft was wrong no licence file found · pointer only · b50e656309cf3492 · report fixture: signature identity_map:dict/0/? · returned list · level recorded 2026-09-26
parse_target_layers training/cog_celebs.py ran · our draft was wrong fingerprinted no licence file found · pointer only · 999a197347fe9545 · report fixture: signature layer_str:str/0/str · returned list · level recorded 2026-09-26
partition_contrastive_loss model/partition_objectives.py ran no licence file found · pointer only · 91b39df4bc1a1f77 · report fixture: signature z_id_pre:Tensor/4/float, labels:Tensor/1/int, target_mask:Tensor/5/float, n_id_per_partition:int/0/int, k_id:int/0/int, margin:float/0/float · returned Tensor · level recorded 2026-09-26
partition_leakage_loss model/partition_objectives.py ran no licence file found · pointer only · b9834b84275567cf · report fixture: signature z_id_pre:Tensor/4/float, labels:Tensor/1/int, target_mask:Tensor/5/float, n_id_per_partition:int/0/int, k_id:int/0/int, margin:float/0/float · returned Tensor · level recorded 2026-09-26
resolve_layer_checkpoint model/checkpoint_io.py ran no licence file found · pointer only · 501b2ce1d7e5728c · report fixture: signature checkpoint_dir:str/0/str, layer_name:str/0/str, checkpoint:NoneType/0/?, checkpoint_type:str/0/str · returned PosixPath · level recorded 2026-09-26
run_global_stats_collection training/cog_celebs.py ran no licence file found · pointer only · 5c74a4b4c803a3d2 · report fixture: signature root_dir:str/0/str, layer_name:str/0/str, data_dim:int/0/int · returned tuple · level recorded 2026-09-26
run_global_stats_collection training/cog_nudity.py ran no licence file found · pointer only · fb2776e47bf70228 · report fixture: signature root_dir:str/0/str, layer_name:str/0/str, data_dim:int/0/int · returned tuple · level recorded 2026-09-26
save_step_mask_artifacts inference/mask_artifacts.py ran · our draft was wrong no licence file found · pointer only · d36772ddde1f91a1 · report fixture: signature snapshots:list/1/dict, video_path:PosixPath/0/? · returned PosixPath · level recorded 2026-09-26
str2bool in 533 papers configs/config_loader.py ran · violated contract no licence file found · pointer only · dc7f0b127bbc5656 · report fixture: signature value:str/0/str · returned bool · level recorded 2026-09-26
validated_target_kernels inference/cli_utils.py ran no licence file found · pointer only · 0acb1ed2b9e34902 · report fixture: signature identity_map:dict/0/?, target_identity:str/0/str, assigned_start:int/0/int, assigned_end:int/0/int, score_threshold:float/0/float · returned list · level recorded 2026-09-26
get_model_path in 22 papers configs/config_loader.py unverified no licence file found · pointer only · 119b201cd050d212 · report

Results from the paper

The Papers with Code archive ends with its 2025-07-28 snapshot. This paper's arXiv identifier, 2609.03629, was issued in September 2026, after that date, so the archive has no leaderboard rows for it.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections