{"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-2511-05064","title":"Order-Level Attention Similarity Across Language Models: A Latent Commonality","arxiv_id":"2511.05064","date":"2025-11-07","proceeding":"NeurIPS","authors":["Jinglin Liang","Jin Zhong","Shuangping Huang","Yunqing Hu","Huiyuan Zhang","Huifang Li","Lixin Fan","Hanlin Gu"],"abstract":"In this paper, we explore an important yet previously neglected question: Do context aggregation patterns across Language Models (LMs) share commonalities? While some works have investigated context aggregation or attention weights in LMs, they typically focus on individual models or attention heads, lacking a systematic analysis across multiple LMs to explore their commonalities. In contrast, we focus on the commonalities among LMs, which can deepen our understanding of LMs and even facilitate cross-model knowledge transfer. In this work, we introduce the Order-Level Attention (OLA) derived from the order-wise decomposition of Attention Rollout and reveal that the OLA at the same order across LMs exhibits significant similarities. Furthermore, we discover an implicit mapping between OLA and syntactic knowledge. Based on these two findings, we propose the Transferable OLA Adapter (TOA), a training-free cross-LM adapter transfer method. Specifically, we treat the OLA as a unified syntactic feature representation and train an adapter that takes OLA as input. Due to the similarities in OLA across LMs, the adapter generalizes to unseen LMs without requiring any parameter updates. Extensive experiments demonstrate that TOA's cross-LM generalization effectively enhances the performance of unseen LMs. Code is available at https://github.com/jinglin-liang/OLAS.","url_abs":"https://arxiv.org/abs/2511.05064","url_pdf":"https://arxiv.org/pdf/2511.05064","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":"https://app.syntology.ai/?focus=2511.05064","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2511.05064"}},"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/jinglin-liang/OLAS","reach":{"status":"ok"}}],"summary":{"ran_draft_wrong":5,"unverified":11},"by_repo_kind":{"found_in_text":{"samples":16,"ran":5,"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":16,"samples":[{"code_sha256_prefix":"d9def42110729a85","entry":"conv1x1","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet.py","link_basis":"harvester_set","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":"d9def42110729a85"}},{"code_sha256_prefix":"d5cd7ffe2dc51b21","entry":"conv1x1","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/modified_represnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/modified_represnet.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":"d5cd7ffe2dc51b21"}},{"code_sha256_prefix":"160bb14bd76201b4","entry":"conv3x3","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet.py","link_basis":"harvester_set","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":"160bb14bd76201b4"}},{"code_sha256_prefix":"fac5364e2f53c6db","entry":"conv3x3","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet_cbam.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet_cbam.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":"fac5364e2f53c6db"}},{"code_sha256_prefix":"1907f2ae25449f39","entry":"conv3x3","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/modified_represnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/modified_represnet.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":"1907f2ae25449f39"}},{"code_sha256_prefix":"93ba74ac3c903901","entry":"cal_dp_loss","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_model.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_model.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":"93ba74ac3c903901"}},{"code_sha256_prefix":"ad5b8493137884f1","entry":"combine_attention_orders","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_utils.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_utils.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":"ad5b8493137884f1"}},{"code_sha256_prefix":"7d7d7520c89b7a9f","entry":"get_interested_mask","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_utils.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_utils.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":"7d7d7520c89b7a9f"}},{"code_sha256_prefix":"6bc8fcce934a8ab0","entry":"get_outliers_mask","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_utils.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_utils.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":"6bc8fcce934a8ab0"}},{"code_sha256_prefix":"abec4c7afc0e1c8f","entry":"is_causal_lm","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_model.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_model.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":"abec4c7afc0e1c8f"}},{"code_sha256_prefix":"9a210759d5a7dd98","entry":"preprocess_ola","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"models/ola_model.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/models/ola_model.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":"9a210759d5a7dd98"}},{"code_sha256_prefix":"8eb956355f7c42ca","entry":"resnet18","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet.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":"8eb956355f7c42ca"}},{"code_sha256_prefix":"4742faeabce1f66b","entry":"resnet18","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/ucir_resnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/ucir_resnet.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":"4742faeabce1f66b"}},{"code_sha256_prefix":"9d7277889d69cf2d","entry":"resnet18_cbam","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet_cbam.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet_cbam.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":"9d7277889d69cf2d"}},{"code_sha256_prefix":"ecaa7ca05d715804","entry":"resnet18_rep","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/modified_represnet.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/modified_represnet.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":"ecaa7ca05d715804"}},{"code_sha256_prefix":"9eb3d43ee2e8ae7d","entry":"resnet34_cbam","repo":"jinglin-liang/OLAS","repo_kind":"found_in_text","path":"convs/resnet_cbam.py","file_url":"https://github.com/jinglin-liang/OLAS/blob/HEAD/convs/resnet_cbam.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":"9eb3d43ee2e8ae7d"}}]},"arxiv_metadata":{"licence":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license)","fields":["title","abstract","authors","date"],"primary_category":"cs.CL","source":"arxiv_api"},"syntology_extracted_results":null}