{"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/robust-and-efficient-fine-tuning-of-llms-with","title":"Robust and Efficient Fine-tuning of LLMs with Bayesian Reparameterization of Low-Rank Adaptation","arxiv_id":"2411.04358","date":"2024-11-07","proceeding":null,"authors":["Ayan Sengupta","Vaibhav Seth","Arinjay Pathak","Natraj Raman","Sriram Gopalakrishnan","Tanmoy Chakraborty"],"abstract":"Large Language Models (LLMs) are highly resource-intensive to fine-tune due to their enormous size. While low-rank adaptation is a prominent parameter-efficient fine-tuning approach, it suffers from sensitivity to hyperparameter choices, leading to instability in model performance on fine-tuning downstream tasks. This paper highlights the importance of effective parameterization in low-rank fine-tuning to reduce estimator variance and enhance the stability of final model outputs. We propose MonteCLoRA, an efficient fine-tuning technique, employing Monte Carlo estimation to learn an unbiased posterior estimation of low-rank parameters with low expected variance, which stabilizes fine-tuned LLMs with only O(1) additional parameters. MonteCLoRA shows significant improvements in accuracy and robustness, achieving up to 3.8% higher accuracy and 8.6% greater robustness than existing efficient fine-tuning methods on natural language understanding tasks with pre-trained RoBERTa-base. Furthermore, in generative tasks with pre-trained LLaMA-1-7B, MonteCLoRA demonstrates robust zero-shot performance with 50% lower variance than the contemporary efficient fine-tuning methods. The theoretical and empirical results presented in the paper underscore how parameterization and hyperpriors balance exploration-exploitation in the low-rank parametric space, therefore leading to more optimal and robust parameter estimation during efficient fine-tuning.","url_abs":"https://arxiv.org/abs/2411.04358v2","url_pdf":"https://arxiv.org/pdf/2411.04358v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"robust-and-efficient-fine-tuning-of-llms-with","repo_url":"https://github.com/lcs2-iiitd/monteclora","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"jax","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"natural-language-understanding","task_name":"Natural Language Understanding"},{"task_slug":"parameter-estimation","task_name":"parameter estimation"},{"task_slug":"parameter-efficient-fine-tuning","task_name":"parameter-efficient fine-tuning"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2411.04358","atlas_url":"https://app.syntology.ai/?focus=2411.04358","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2411.04358"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/lcs2-iiitd/monteclora","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran_honours":2,"ran":5,"ran_draft_wrong":5,"unverified":7},"by_repo_kind":{"official":{"samples":16,"ran":9,"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":3,"samples":[{"code_sha256_prefix":"32380a050ca033d4","entry":"b2mb","repo":null,"repo_kind":null,"path":null,"file_url":null,"link_basis":"identical_code_first_harvested_elsewhere","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":true,"licence":null,"inline_ok":false,"mcp_get_code":{"code_sha256":"32380a050ca033d4"}},{"code_sha256_prefix":"ab306165fa74656c","entry":"build_tip_message","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/deprecate_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/deprecate_models.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"ab306165fa74656c"}},{"code_sha256_prefix":"56e674752db00649","entry":"generate_prompt","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"finetune.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/finetune.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":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"56e674752db00649"}},{"code_sha256_prefix":"0dbc7fc6c518d0fb","entry":"generate_prompt","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"generate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/generate.py","link_basis":"plan_row","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"0dbc7fc6c518d0fb"}},{"code_sha256_prefix":"1c6b8be890b6118a","entry":"generate_prompt","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"commonsense_evaluate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/commonsense_evaluate.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"1c6b8be890b6118a"}},{"code_sha256_prefix":"bdad3d08a6241ede","entry":"get_closest_label","repo":null,"repo_kind":null,"path":null,"file_url":null,"link_basis":"identical_code_first_harvested_elsewhere","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":null,"inline_ok":false,"mcp_get_code":{"code_sha256":"bdad3d08a6241ede"}},{"code_sha256_prefix":"3d999b95009c7537","entry":"get_config_class_from_processor_class","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/create_dummy_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/create_dummy_models.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"3d999b95009c7537"}},{"code_sha256_prefix":"938fc7c2422ef91d","entry":"get_list_of_repo_model_paths","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/models_to_deprecate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/models_to_deprecate.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"938fc7c2422ef91d"}},{"code_sha256_prefix":"051d790d9b197d9d","entry":"get_model_doc_path","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/deprecate_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/deprecate_models.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"051d790d9b197d9d"}},{"code_sha256_prefix":"0c0b81b081919d8e","entry":"get_processor_types_from_config_class","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/create_dummy_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/create_dummy_models.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"0c0b81b081919d8e"}},{"code_sha256_prefix":"d267d33e45b87bcd","entry":"levenshtein_distance","repo":null,"repo_kind":null,"path":null,"file_url":null,"link_basis":"identical_code_first_harvested_elsewhere","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":true,"licence":null,"inline_ok":false,"mcp_get_code":{"code_sha256":"d267d33e45b87bcd"}},{"code_sha256_prefix":"56a9466ff35b35bb","entry":"load_data","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"commonsense_evaluate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/commonsense_evaluate.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":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"56a9466ff35b35bb"}},{"code_sha256_prefix":"54b7273383fcfc2d","entry":"extract_model_info","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/deprecate_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/deprecate_models.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"54b7273383fcfc2d"}},{"code_sha256_prefix":"b176efb26f72e507","entry":"get_architectures_from_config_class","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"transformers/utils/create_dummy_models.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/transformers/utils/create_dummy_models.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"b176efb26f72e507"}},{"code_sha256_prefix":"93ae876f7bcc5547","entry":"main","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"commonsense_evaluate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/commonsense_evaluate.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"93ae876f7bcc5547"}},{"code_sha256_prefix":"2982bc8c318ebd42","entry":"main","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"evaluate.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/evaluate.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"2982bc8c318ebd42"}},{"code_sha256_prefix":"f440299af78ed374","entry":"replace_args_in_script","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"expt.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/expt.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"f440299af78ed374"}},{"code_sha256_prefix":"7852c586e42377d2","entry":"train","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"finetune.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/finetune.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"7852c586e42377d2"}},{"code_sha256_prefix":"0667181f616b34bb","entry":"write_temp_script","repo":"lcs2-iiitd/monteclora","repo_kind":"official","path":"expt.py","file_url":"https://github.com/lcs2-iiitd/monteclora/blob/HEAD/expt.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"0667181f616b34bb"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}