• Home
  • Search
  • InferCG: Enhancing Python Call Graph Generation via Static Analysis and Large Language Models
  • https://doi.org/10.1145/3799990Copy DOI Icon

InferCG: Enhancing Python Call Graph Generation via Static Analysis and Large Language Models

Show More
  • Abstract
  • Literature Map
  • References
  • Similar Papers
Abstract

Call graph construction serves as a foundational component in Python static analysis and software engineering. However, it faces significant challenges due to the language's unique characteristics. That is, the dynamic typing system, extensive use of third-party libraries, and runtime-dependent behaviors in Python create substantial obstacles for traditional static analysis methods. Although these methods typically achieve high precision, they suffer from low recall, making it difficult to strike a balance between soundness and precision. In this paper, we present InferCG , a hybrid framework that addresses these limitations by combining coarse-grained static analysis with large language model (LLM)–based semantic reasoning. InferCG first constructs a high-recall candidate call set using permissive name- and arity-based matching, and then employs powerful LLMs such as DeepSeek and Qwen to semantically filter implausible edges. This two-stage design balances recall and precision without requiring dynamic execution or extensive type annotations. Experiments on curated open-source Python projects and the DyPyBench benchmark demonstrate that InferCG outperforms state-of-the-art static tools, which achieves up to 13.9% improvement in average recall and a 5.0% gain in average F1 score over PyCG. Moreover, in a real-world vulnerable-function detection scenario, InferCG enables more accurate reachability analysis than dependency-based tools.

Similar Papers
  • Research Article
  • Citations1

Logical and Physical Optimizations for SQL Query Execution over Large Language Models

  • Jun 17, 2025
  • Proceedings of the ACM on Management of Data
  • Dario Satriani +5
  • Research Article
  • Citations1

Large Language Model Powered Symbolic Execution

  • Oct 09, 2025
  • Proceedings of the ACM on Programming Languages
  • Yihe Li +2
  • Research Article

LLM-IARE: An Input-Aware Resilience Estimation Methodology for LLMs under Hardware Transient Faults

  • Feb 09, 2026
  • ACM Transactions on Design Automation of Electronic Systems
  • Jiajia Jiao +4
  • Research Article
  • Citations56

Generative AI in cybersecurity: A comprehensive review of LLM applications and vulnerabilities

  • Jan 01, 2025
  • Internet of Things and Cyber-Physical Systems
  • Mohamed Amine Ferrag +7
  • Research Article

Analyzing LLM-generated code according to four ISO/IEC 5055:2021 categories

  • Jan 01, 2025
  • IEEE Access
  • Rasmus Krebs +1
  • Research Article

Auto-Coding Collaborative Dialogue from Classrooms with Open LLMs Using Zero-Short Prompting

  • Dec 04, 2025
  • International Conference on AI Research
  • Wenting Sun +1
  • Research Article

Automation Frameworks for End-to-End Testing of Large Language Models (LLMs)

  • Apr 30, 2025
  • Journal of Information Systems Engineering and Management
  • Reena Chandra
  • Research Article

From Editorial Records to Structured Provenance Information: Documenting Warrant in Knowledge Organization Systems Using Large Language Models

  • Jun 25, 2025
  • Knowledge Organization
  • Yi-Yun Cheng +1
  • Research Article
  • Citations1

Challenges and Solutions in Applying Large Language Models to Guideline-Based Management Planning and Automated Medical Coding in Health Care: Algorithm Development and Validation

  • Nov 10, 2025
  • JMIR Biomedical Engineering
  • Peter Sarvari +5
  • Research Article

Is AI Really Intelligent? Practical Insights from Real-World Use of Generative AI

  • Apr 20, 2026
  • International Journal of Arts, Humanities & Social Science
  • Dr Khaled El Tannir
  • Research Article
  • Citations70

Large Language Model for Vulnerability Detection and Repair: Literature Review and the Road Ahead

  • May 27, 2025
  • ACM Transactions on Software Engineering and Methodology
  • Xin Zhou +3
  • Research Article
  • Citations55

Large Language Models for Cyber Security: A Systematic Literature Review

  • Sep 29, 2025
  • ACM Transactions on Software Engineering and Methodology
  • Hanxiang Xu +8
  • Research Article

Retrieval augmented generation based dynamic prompting for few-shot biomedical named entity recognition using large language models

  • Aug 25, 2025
  • Research Square
  • Yao Ge +3
  • Research Article

Malware Analysis Education Meets LLMs: Understanding Student Use of LLMs in Malware Analysis Education

  • Jan 01, 2026
  • International Journal of Information and Education Technology
  • Orçun Çetin +1
  • Research Article

ICAM-Trans: Implicit-Context-Aware Multi-Agent Framework for Function-Level Code Translation

  • Apr 21, 2026
  • ACM Transactions on Software Engineering and Methodology
  • Ruolin Chen +4
Cactus Communications logo

Copyright 2026 Cactus Communications. All rights reserved.