{"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/clipping-the-deception-adapting-vision","title":"CLIPping the Deception: Adapting Vision-Language Models for Universal Deepfake Detection","arxiv_id":"2402.12927","date":"2024-02-20","proceeding":null,"authors":["Sohail Ahmed Khan","Duc-Tien Dang-Nguyen"],"abstract":"The recent advancements in Generative Adversarial Networks (GANs) and the emergence of Diffusion models have significantly streamlined the production of highly realistic and widely accessible synthetic content. As a result, there is a pressing need for effective general purpose detection mechanisms to mitigate the potential risks posed by deepfakes. In this paper, we explore the effectiveness of pre-trained vision-language models (VLMs) when paired with recent adaptation methods for universal deepfake detection. Following previous studies in this domain, we employ only a single dataset (ProGAN) in order to adapt CLIP for deepfake detection. However, in contrast to prior research, which rely solely on the visual part of CLIP while ignoring its textual component, our analysis reveals that retaining the text part is crucial. Consequently, the simple and lightweight Prompt Tuning based adaptation strategy that we employ outperforms the previous SOTA approach by 5.01% mAP and 6.61% accuracy while utilizing less than one third of the training data (200k images as compared to 720k). To assess the real-world applicability of our proposed models, we conduct a comprehensive evaluation across various scenarios. This involves rigorous testing on images sourced from 21 distinct datasets, including those generated by GANs-based, Diffusion-based and Commercial tools.","url_abs":"https://arxiv.org/abs/2402.12927v1","url_pdf":"https://arxiv.org/pdf/2402.12927v1.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":"clipping-the-deception-adapting-vision","repo_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"deepfake-detection","task_name":"DeepFake Detection"},{"task_slug":"face-swapping","task_name":"Face Swapping"}],"methods":[{"method_slug":"clip","method_name":"CLIP"},{"method_slug":"diffusion","method_name":"Diffusion"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2402.12927","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2402.12927"}},"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/sohailahmedkhan/CLIPping-the-Deception","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":7,"unverified":1},"by_repo_kind":{"official":{"samples":8,"ran":7,"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":0,"samples":[{"code_sha256_prefix":"ba26afd892405335","entry":"compute_ci95","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"parse_test_res.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/parse_test_res.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ba26afd892405335"}},{"code_sha256_prefix":"86961d87fd5fab69","entry":"cv2_jpg","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"evaluate.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/evaluate.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"86961d87fd5fab69"}},{"code_sha256_prefix":"31ffd8a568aedb1b","entry":"get_parsed_args","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"eval_utils.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/eval_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"31ffd8a568aedb1b"}},{"code_sha256_prefix":"d98d700edf758730","entry":"get_parsed_args","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"eval_utils_zero_shot.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/eval_utils_zero_shot.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d98d700edf758730"}},{"code_sha256_prefix":"8a2cf73c650cccb3","entry":"get_parsed_args_adapter","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"eval_utils_adapter.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/eval_utils_adapter.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8a2cf73c650cccb3"}},{"code_sha256_prefix":"17051b90ed637049","entry":"get_parsed_args_fine_tuned","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"eval_utils_fine_tuned.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/eval_utils_fine_tuned.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"17051b90ed637049"}},{"code_sha256_prefix":"cf8392ad485272eb","entry":"train_model","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"trainer.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/trainer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"cf8392ad485272eb"}},{"code_sha256_prefix":"13b29f1ac0b39a10","entry":"build_model","repo":"sohailahmedkhan/CLIPping-the-Deception","repo_kind":"official","path":"clip/model.py","file_url":"https://github.com/sohailahmedkhan/CLIPping-the-Deception/blob/HEAD/clip/model.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"13b29f1ac0b39a10"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}