{"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/detecting-and-mitigating-hallucination-in","title":"Detecting and Mitigating Hallucination in Large Vision Language Models via Fine-Grained AI Feedback","arxiv_id":"2404.14233","date":"2024-04-22","proceeding":null,"authors":["Wenyi Xiao","Ziwei Huang","Leilei Gan","Wanggui He","Haoyuan Li","Zhelun Yu","Fangxun Shu","Hao Jiang","Linchao Zhu"],"abstract":"The rapidly developing Large Vision Language Models (LVLMs) have shown notable capabilities on a range of multi-modal tasks, but still face the hallucination phenomena where the generated texts do not align with the given contexts, significantly restricting the usages of LVLMs. Most previous work detects and mitigates hallucination at the coarse-grained level or requires expensive annotation (e.g., labeling by proprietary models or human experts). To address these issues, we propose detecting and mitigating hallucinations in LVLMs via fine-grained AI feedback. The basic idea is that we generate a small-size sentence-level hallucination annotation dataset by proprietary models, whereby we train a hallucination detection model which can perform sentence-level hallucination detection, covering primary hallucination types (i.e., object, attribute, and relationship). Then, we propose a detect-then-rewrite pipeline to automatically construct preference dataset for training hallucination mitigating model. Furthermore, we propose differentiating the severity of hallucinations, and introducing a Hallucination Severity-Aware Direct Preference Optimization (HSA-DPO) for mitigating hallucination in LVLMs by incorporating the severity of hallucinations into preference learning. Extensive experiments demonstrate the effectiveness of our method.","url_abs":"https://arxiv.org/abs/2404.14233v2","url_pdf":"https://arxiv.org/pdf/2404.14233v2.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":"detecting-and-mitigating-hallucination-in","repo_url":"https://github.com/Mr-Loevan/HSA-DPO","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok"}}],"tasks":[{"task_slug":"attribute","task_name":"Attribute"},{"task_slug":"hallucination","task_name":"Hallucination"},{"task_slug":"sentence","task_name":"Sentence"}],"methods":[{"method_slug":"align","method_name":"ALIGN"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2404.14233","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2404.14233"}},"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":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Mr-Loevan/HSA-DPO","reach":{"status":"ok"}}],"summary":{"ran_draft_wrong":2,"ran":1,"unverified":5},"by_repo_kind":{"official":{"samples":8,"ran":3,"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":8,"samples":[{"code_sha256_prefix":"592b3c1a88f93d7c","entry":"expand2square","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/llava/mm_utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/llava/mm_utils.py","link_basis":"harvester_set","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":"592b3c1a88f93d7c"}},{"code_sha256_prefix":"c774723322f1f9c6","entry":"find_all_linear_names","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/train_dpo.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/train_dpo.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":"c774723322f1f9c6"}},{"code_sha256_prefix":"c3ee9d07c900dd55","entry":"load_image_from_base64","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/llava/mm_utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/llava/mm_utils.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":"c3ee9d07c900dd55"}},{"code_sha256_prefix":"f4334934ee795269","entry":"is_transformers_greater_than","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/trainer/import_utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/trainer/import_utils.py","link_basis":"harvester_set","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":"f4334934ee795269"}},{"code_sha256_prefix":"616ffbdc154ed2d8","entry":"maybe_zero_3","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/train_dpo.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/train_dpo.py","link_basis":"harvester_set","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":"616ffbdc154ed2d8"}},{"code_sha256_prefix":"37899f22fb191b37","entry":"pretty_print_semaphore","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/llava/utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/llava/utils.py","link_basis":"harvester_set","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":"37899f22fb191b37"}},{"code_sha256_prefix":"344dff4791fd1381","entry":"process_images","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/llava/mm_utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/llava/mm_utils.py","link_basis":"harvester_set","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":"344dff4791fd1381"}},{"code_sha256_prefix":"f9939a84b9a65279","entry":"violates_moderation","repo":"Mr-Loevan/HSA-DPO","repo_kind":"official","path":"hsa_dpo/models/llava-v1_5/llava/utils.py","file_url":"https://github.com/Mr-Loevan/HSA-DPO/blob/HEAD/hsa_dpo/models/llava-v1_5/llava/utils.py","link_basis":"harvester_set","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":"f9939a84b9a65279"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}