Probing Pretrained Models of Source Code
Not on the map. Why?
Abstract (arXiv)
Deep learning models are widely used for solving challenging code processing tasks, such as code generation or code summarization. Traditionally, a specific model architecture was carefully built to solve a particular code processing task. However, recently general pretrained models such as CodeBERT or CodeT5 have been shown to outperform task-specific models in many applications. While pretrained models are known to learn complex patterns from data, they may fail to understand some properties of source code. To test diverse aspects of code understanding, we introduce a set of diagnosting probing tasks. We show that pretrained models of code indeed contain information about code syntactic structure and correctness, the notions of identifiers, data flow and namespaces, and natural language naming. We also investigate how probing results are affected by using code-specific pretraining objectives, varying the model size, or finetuning.
Key facts. Cited by 26 papers in the map (data through 7 Oct 2026). Builds on 26 of its 52 references that are in the map. First posted on arXiv 16 Feb 2022.
Builds on
26 of 52 references.
References · 26
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,160
- 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,266
- 2021Evaluating Large Language Models Trained on Codecited by 8,053
- 2019BART: Denoising Sequence-to-Sequence Pre-training for Natural Language Generation, Translation, and Comprehensioncited by 5,874
- 2019Optuna: A Next-generation Hyperparameter Optimization Frameworkcited by 2,455
- 2020CodeBERT: A Pre-Trained Model for Programming and Natural Languagescited by 1,286
- 2016Understanding intermediate layers using linear classifier probescited by 1,279
- 2015Aligning Books and Movies: Towards Story-like Visual Explanations by Watching Movies and Reading Bookscited by 1,041
- 2021CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generationcited by 890
- 2021Probing Classifiers: Promises, Shortcomings, and Advancescited by 831
14 more
- 2021CodeXGLUE: A Machine Learning Benchmark Dataset for Code Understanding and Generationcited by 732
- 2019CodeSearchNet Challenge: Evaluating the State of Semantic Code Searchcited by 638
- 2020GraphCodeBERT: Pre-training Code Representations with Data Flowcited by 600
- 2018What you can cram into a single vector: Probing sentence embeddings for linguistic propertiescited by 452
- 2019What do you learn from context? Probing for sentence structure in contextualized word representationscited by 436
- 2021Unified Pre-training for Program Understanding and Generationcited by 361
- 2020Unsupervised Translation of Programming Languagescited by 262
- 2020Intermediate-Task Transfer Learning with Pretrained Models for Natural Language Understanding: When and Why Does It Work?cited by 127
- 2020Improved Code Summarization via a Graph Neural Networkcited by 79
- 2021AVATAR: A Parallel Corpus for Java-Python Program Translationcited by 59
- 2021Discourse Probing of Pretrained Language Modelscited by 38
- 2021What do pre-trained code models know about code?cited by 36
- 2019On the Linguistic Representational Power of Neural Machine Translation Modelscited by 34
- 2020Empirical Study of Transformers for Source Codecited by 13
Built on by
Citing papers per year: 2022: 4; 2023: 7; 2024: 6; 2025: 6; 2026: 3.
26 papers.
Sort:
By area:
- 2024Astraios: Parameter-Efficient Instruction Tuning Code Large Language Modelscited by 23
- 2023Towards Efficient Fine-tuning of Pre-trained Code Models: An Experimental Study and Beyondcited by 20
- 2022AST-Probe: Recovering abstract syntax trees from hidden representations of pre-trained language modelscited by 16
- 2023Exploring the Robustness of Large Language Models for Solving Programming Problemscited by 16
- 2022Unveiling Code Pre-Trained Models: Investigating Syntax and Semantics Capacitiescited by 9
- 2023Evaluating and Explaining Large Language Models for Code Using Syntactic Structurescited by 9
- 2024AI Coders Are Among Us: Rethinking Programming Language Grammar Towards Efficient Code Generationcited by 8
- 2022CAT-probing: A Metric-based Approach to Interpret How Pre-trained Models for Programming Language Attend Code Structurecited by 6
- 2024On the Limitations of Embedding Based Methods for Measuring Functional Correctness for Code Generationcited by 6
- 2022SimSCOOD: Systematic Analysis of Out-of-Distribution Generalization in Fine-tuned Source Code Modelscited by 5
- 2023Substance or Style: What Does Your Image Embedding Know?cited by 5
- 2024Meta-Models: An Architecture for Decoding LLM Behaviors Through Interpreted Embeddings and Natural Languagecited by 5
14 more
- 2024A Critical Study of What Code-LLMs (Do Not) Learncited by 4
- 2025ObscuraCoder: Powering Efficient Code LM Pre-Training Via Obfuscation Groundingcited by 4
- 2023Towards Understanding What Code Language Models Learnedcited by 3
- 2023Pop Quiz! Do Pre-trained Code Models Possess Knowledge of Correct API Names?cited by 3
- 2024Structure-aware Fine-tuning for Code Pre-trained Modelscited by 3
- 2025Mechanistic Interpretability of Code Correctness in LLMs via Sparse Autoencoderscited by 3
- 2025Neuron-Guided Interpretation of Code LLMs: Where, Why, and How?cited by 3
- 2025Localized Calibrated Uncertainty in Code Language Modelscited by 3
- 2023INSPECT: Intrinsic and Systematic Probing Evaluation for Code Transformerscited by 2
- 2025Analyzing Latent Concepts in Code Language Modelscited by 1
- 2026Tool-Call Dependency Structure is Linearly Decodable in LLM Agent Residual Streamscited by 1
- 2025Toward Neurosymbolic Program Comprehensioncited by 0
- 2026Latent Programming Horizons in Coding Agentscited by 0
- 2026TypeProbe: Recovering Type Representations from Hidden States of Pre-trained Code Modelscited by 0
- 2026TypeProbe: Recovering Type Representations from Hidden States of Pre-trained Code Models9 Jul 2026
- 2026Latent Programming Horizons in Coding Agents6 Jul 2026
- 2026Tool-Call Dependency Structure is Linearly Decodable in LLM Agent Residual Streams25 May 2026
- 2025Localized Calibrated Uncertainty in Code Language Models31 Dec 2025
- 2025Neuron-Guided Interpretation of Code LLMs: Where, Why, and How?23 Dec 2025
- 2025Mechanistic Interpretability of Code Correctness in LLMs via Sparse Autoencoders3 Oct 2025
- 2025Analyzing Latent Concepts in Code Language Models1 Oct 2025
- 2025ObscuraCoder: Powering Efficient Code LM Pre-Training Via Obfuscation Grounding27 Mar 2025
- 2025Toward Neurosymbolic Program Comprehension3 Feb 2025
- 2024Meta-Models: An Architecture for Decoding LLM Behaviors Through Interpreted Embeddings and Natural Language3 Oct 2024
- 2024A Critical Study of What Code-LLMs (Do Not) Learn17 Jun 2024
- 2024On the Limitations of Embedding Based Methods for Measuring Functional Correctness for Code Generation26 Apr 2024
14 more
- 2024AI Coders Are Among Us: Rethinking Programming Language Grammar Towards Efficient Code Generation25 Apr 2024
- 2024Structure-aware Fine-tuning for Code Pre-trained Models11 Apr 2024
- 2024Astraios: Parameter-Efficient Instruction Tuning Code Large Language Models1 Jan 2024
- 2023INSPECT: Intrinsic and Systematic Probing Evaluation for Code Transformers8 Dec 2023
- 2023Pop Quiz! Do Pre-trained Code Models Possess Knowledge of Correct API Names?14 Sep 2023
- 2023Evaluating and Explaining Large Language Models for Code Using Syntactic Structures7 Aug 2023
- 2023Substance or Style: What Does Your Image Embedding Know?10 Jul 2023
- 2023Exploring the Robustness of Large Language Models for Solving Programming Problems26 Jun 2023
- 2023Towards Understanding What Code Language Models Learned20 Jun 2023
- 2023Towards Efficient Fine-tuning of Pre-trained Code Models: An Experimental Study and Beyond11 Apr 2023
- 2022Unveiling Code Pre-Trained Models: Investigating Syntax and Semantics Capacities20 Dec 2022
- 2022SimSCOOD: Systematic Analysis of Out-of-Distribution Generalization in Fine-tuned Source Code Models10 Oct 2022
- 2022CAT-probing: A Metric-based Approach to Interpret How Pre-trained Models for Programming Language Attend Code Structure7 Oct 2022
- 2022AST-Probe: Recovering abstract syntax trees from hidden representations of pre-trained language models23 Jun 2022
- 2024Astraios: Parameter-Efficient Instruction Tuning Code Large Language Modelscited by 23
- 2023Towards Efficient Fine-tuning of Pre-trained Code Models: An Experimental Study and Beyondcited by 20
- 2022AST-Probe: Recovering abstract syntax trees from hidden representations of pre-trained language modelscited by 16
- 2023Exploring the Robustness of Large Language Models for Solving Programming Problemscited by 16
- 2022Unveiling Code Pre-Trained Models: Investigating Syntax and Semantics Capacitiescited by 9
- 2023Evaluating and Explaining Large Language Models for Code Using Syntactic Structurescited by 9
- 2022CAT-probing: A Metric-based Approach to Interpret How Pre-trained Models for Programming Language Attend Code Structurecited by 6
- 2024On the Limitations of Embedding Based Methods for Measuring Functional Correctness for Code Generationcited by 6
- 2022SimSCOOD: Systematic Analysis of Out-of-Distribution Generalization in Fine-tuned Source Code Modelscited by 5
- 2023Substance or Style: What Does Your Image Embedding Know?cited by 5
- 2024Meta-Models: An Architecture for Decoding LLM Behaviors Through Interpreted Embeddings and Natural Languagecited by 5
- 2024A Critical Study of What Code-LLMs (Do Not) Learncited by 4
12 most cited of 23 All 23 (JSON)
- 2026TypeProbe: Recovering Type Representations from Hidden States of Pre-trained Code Models9 Jul 2026
- 2025Localized Calibrated Uncertainty in Code Language Models31 Dec 2025
- 2025Neuron-Guided Interpretation of Code LLMs: Where, Why, and How?23 Dec 2025
- 2025Mechanistic Interpretability of Code Correctness in LLMs via Sparse Autoencoders3 Oct 2025
- 2025Analyzing Latent Concepts in Code Language Models1 Oct 2025
- 2025ObscuraCoder: Powering Efficient Code LM Pre-Training Via Obfuscation Grounding27 Mar 2025
- 2025Toward Neurosymbolic Program Comprehension3 Feb 2025
- 2024Meta-Models: An Architecture for Decoding LLM Behaviors Through Interpreted Embeddings and Natural Language3 Oct 2024
- 2024A Critical Study of What Code-LLMs (Do Not) Learn17 Jun 2024
- 2024On the Limitations of Embedding Based Methods for Measuring Functional Correctness for Code Generation26 Apr 2024
- 2024Structure-aware Fine-tuning for Code Pre-trained Models11 Apr 2024
- 2024Astraios: Parameter-Efficient Instruction Tuning Code Large Language Models1 Jan 2024
12 newest of 23 All 23 (JSON)