{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/arxiv-2606-07289","title":"Closed-Form Spectral Regularization for Multi-Task Model Merging","arxiv_id":"2606.07289","date":"2026-06-05","proceeding":null,"authors":["Yongxian Wei","Runxi Cheng","Xingxuan Zhang","Li Shen","Chun Yuan","Peng Cui","Dacheng Tao"],"abstract":"Model merging combines several independently fine-tuned experts into a single multi-task model without any training data, reducing the storage, serving, and decentralized-development costs of large foundation models. State-of-the-art merging methods formulate merging as a layer-wise quadratic interference minimization problem. Although this problem admits an exact closed-form pseudoinverse solution, that solution underperforms hundreds of iterations of gradient descent in practice. The iterative loop dominates the cost of the pipeline, yet its effectiveness has remained unexplained. We revisit this regime and show that the iterative solver does not primarily act as an optimizer; rather, it serves as an implicit spectral regularizer for an ill-posed normal equation, where small-eigenvalue directions of the per-layer interference operator amplify proxy noise. Building on this finding, we formalize multi-task model merging as a noisy linear inverse problem and propose a spectral filtering estimator parameterized by a per-direction filter. We instantiate this estimator with SWUDI, a closed-form method that combines a soft exponential filter, which matches the gradient-flow trajectory of iterative descent, with a hard top-K truncation that suppresses noise-amplifying small-eigenvalue directions. Furthermore, we propose SWUDI-A, an adaptive variant that replaces the global rank hyperparameter with per-layer rank rules, further improving robustness across architectures. Both variants share a single symmetric eigendecomposition per linear layer and require no training data or optimizer state. Across four general benchmarks and a multimodal merging benchmark spanning VQA, Geometry, Chart, OCR, Grounding, and modality merging, our proposed spectral solvers match or outperform state-of-the-art merging methods. Crucially, they reduce wall-clock time by 28-72x and peak GPU memory by up to 50%.","url_abs":"https://arxiv.org/abs/2606.07289","url_pdf":"https://arxiv.org/pdf/2606.07289","source":{"archive":null,"snapshot":"2025-07-28","note":"not in the Papers with Code archive (frozen at the snapshot)","row_kind":"graph","title_abstract_authors_date":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license)"},"code_links":[],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":null,"mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2606.07289"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"mentioned_in_github":null,"is_official":null,"provenance":"deterministic:regex_extraction","mentioned_in_paper":null,"url":"https://github.com/WalkerWorldPeace/MLLMerging","reach":null}],"summary":{"ran":13,"ran_draft_wrong":3,"ran_fixture":2,"unverified":1},"by_repo_kind":{"found_in_text":{"samples":19,"ran":18,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"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"},"n_pointer_only_for_licence":19,"samples":[{"code_sha256_prefix":"57e95166ade5f25c","entry":"build_transform","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"InternVL/internvl_chat/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/InternVL/internvl_chat/model_merging.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"57e95166ade5f25c"}},{"code_sha256_prefix":"d086657e28ce7f38","entry":"cache_states","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/run_merge_baseline.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/run_merge_baseline.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"d086657e28ce7f38"}},{"code_sha256_prefix":"62fed5db332affd0","entry":"cache_states","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/run_merge_baseline_internvl.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/run_merge_baseline_internvl.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"62fed5db332affd0"}},{"code_sha256_prefix":"0d07817f34e79b4b","entry":"convert_box","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/grounding.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/grounding.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"0d07817f34e79b4b"}},{"code_sha256_prefix":"6dc77bb22fb9d660","entry":"dynamic_preprocess","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"InternVL/internvl_chat/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/InternVL/internvl_chat/model_merging.py","link_basis":"plan_row","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6dc77bb22fb9d660"}},{"code_sha256_prefix":"bd77f5f8067f18e9","entry":"find_closest_aspect_ratio","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"InternVL/internvl_chat/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/InternVL/internvl_chat/model_merging.py","link_basis":"harvester_set","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"bd77f5f8067f18e9"}},{"code_sha256_prefix":"dcafd602728bc51e","entry":"get_param_names_to_merge","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/model_merging.py","link_basis":"plan_row","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"dcafd602728bc51e"}},{"code_sha256_prefix":"b22f6cc19ab398f9","entry":"load_all","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/diff_merged_weights.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/diff_merged_weights.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b22f6cc19ab398f9"}},{"code_sha256_prefix":"4745bf56ff70c712","entry":"load_all_shards","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/rescale_multi.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/rescale_multi.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4745bf56ff70c712"}},{"code_sha256_prefix":"c722e6776be8c9ac","entry":"load_module","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/benchmark_mllm_merge_cost.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/benchmark_mllm_merge_cost.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c722e6776be8c9ac"}},{"code_sha256_prefix":"20f6ae118d68fdc8","entry":"lookup","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/diff_merged_weights.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/diff_merged_weights.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"20f6ae118d68fdc8"}},{"code_sha256_prefix":"5bd838966b120daf","entry":"mask_input_with_mask_rate","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/model_merging.py","link_basis":"plan_row","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"5bd838966b120daf"}},{"code_sha256_prefix":"78ad18c6bed292e3","entry":"mask_model_weights","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/baseline_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/baseline_merging.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"78ad18c6bed292e3"}},{"code_sha256_prefix":"840fb864701f8f6d","entry":"parse_text","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"ModelCompose/demo_app.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/ModelCompose/demo_app.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"840fb864701f8f6d"}},{"code_sha256_prefix":"1d7b10d84936c164","entry":"process_value_string","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/grounding.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/grounding.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1d7b10d84936c164"}},{"code_sha256_prefix":"4c8f7beb44c32119","entry":"resolve_dtype","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/run_merge_baseline.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/run_merge_baseline.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4c8f7beb44c32119"}},{"code_sha256_prefix":"23fb066c145e3d74","entry":"ties_merging","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/model_merging.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/model_merging.py","link_basis":"plan_row","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"23fb066c145e3d74"}},{"code_sha256_prefix":"d65d19229b71e75f","entry":"total_delta","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/diff_merged_weights.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/diff_merged_weights.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"d65d19229b71e75f"}},{"code_sha256_prefix":"3855144c1081b166","entry":"time_method","repo":"WalkerWorldPeace/MLLMerging","repo_kind":"found_in_text","path":"LLaMA-Factory/benchmark_mllm_merge_cost.py","file_url":"https://github.com/WalkerWorldPeace/MLLMerging/blob/HEAD/LLaMA-Factory/benchmark_mllm_merge_cost.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"3855144c1081b166"}}]},"arxiv_metadata":{"licence":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license)","fields":["title","abstract","authors","date"],"primary_category":"cs.LG","source":"arxiv_2026.jsonl"},"syntology_extracted_results":{"kind":"leaderboard_placements","source":"Syntology's leaderboard-shaped extractor over the paper's own arXiv-HTML tables: a model pointed at a cell, the number was read from that cell and checked against the board's metric, dataset, split and scale, and an independent check accepted the entry; not reviewed by the paper's authors or the archive's editors","extractor_model":"global.anthropic.claude-sonnet-4-5-20250929-v1:0","verifier_model":null,"prompt_sha":"fa63d4bb9d755694","coverage":{"sentence":"Syntology has checked 6,264 of the 9,581 papers on this site that are newer than the archive; results from the others appear after they are checked.","papers_newer_than_archive":9581,"papers_checked":6264},"entries":[],"not_placed":{"boards":1,"rejected_by_independent_check":0,"refused_by_a_rule":1,"check_did_not_answer":0,"proposed_without_a_cell":0,"declined_by_site":0}}}