paper-with-me

Papers

CodeTrek: Flexible Modeling of Code using an Extensible Relational Representation

2021-09-29 · ICLR 2022 4 · Pardis Pashakhanloo, Aaditya Naik, Yuepeng Wang, Hanjun Dai, Petros Maniatis, Mayur Naik

Designing a suitable representation for code-reasoning tasks is challenging in aspects such as the kinds of program information to model, how to combine them, and how much context to consider. We propose CodeTrek, a deep learning approach that addresses these challenges by representing codebases as databases that conform to rich relational schemas. The relational representation not only allows CodeTrek to uniformly represent diverse kinds of program information, but also to leverage program-analysis queries to derive new semantic relations, which can be readily incorporated without further architectural engineering. CodeTrek embeds this relational representation using a set of walks that can traverse different relations in an unconstrained fashion, and incorporates all relevant attributes along the way. We evaluate CodeTrek on four diverse and challenging Python tasks: variable misuse, exception prediction, unused definition, and variable shadowing. CodeTrek achieves an accuracy of 91%, 63%, 98%, and 94% on these tasks respectively, and outperforms state-of-the-art neural models by 2-19% points.

📄 PDF Abstract BibTeX

Code (1)

ppashakhanloo/CodeTrek 공식 구현 pytorch

Tasks

Exception typeVariable misuse

Similar Papers 제목 키워드 기반

Flexibly Scaling Large Language Models Contexts Through Extensible Tokenization

2024-01-15 · Ninglu Shao, Shitao Xiao, Zheng Liu, Peitian Zhang

Large language models (LLMs) are in need of sufficient contexts to handle many critical applications, such as retrieval augmented generation and few-shot learning. However, due to the constrained window size, the LLMs ca…

Few-Shot LearningLanguage ModelingLanguage ModellingRetrieval-augmented Generation

Extensible Embedding: A Flexible Multipler For LLM's Context Length

2024-02-18 · Ninglu Shao, Shitao Xiao, Zheng Liu, Peitian Zhang

Large language models (LLMs) call for extension of context to handle many critical applications. However, the existing approaches are prone to expensive costs and inferior quality of context extension. In this work, we p…

Language ModelingLanguage Modelling

Relational VAE: A Continuous Latent Variable Model for Graph Structured Data

2021-06-30 · NeurIPS 2021 12 · Charilaos Mylonas, Imad Abdallah, Eleni Chatzi

Graph Networks (GNs) enable the fusion of prior knowledge and relational reasoning with flexible function approximations. In this work, a general GN-based model is proposed which takes full advantage of the relational mo…

Meta-LearningRelational Reasoning

Relational Sentence Embedding for Flexible Semantic Matching

2022-12-17 · Bin Wang, Haizhou Li

We present Relational Sentence Embedding (RSE), a new paradigm to further discover the potential of sentence embeddings. Prior work mainly models the similarity between sentences based on their embedding distance. Becaus…

RelationSemantic Textual SimilaritySentenceSentence Embedding+2

Relational World Knowledge Representation in Contextual Language Models: A Review

2021-04-12 · EMNLP 2021 11 · Tara Safavi, Danai Koutra

Relational knowledge bases (KBs) are commonly used to represent world knowledge in machines. However, while advantageous for their high degree of precision and interpretability, KBs are usually organized according to man…

World Knowledge