paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Active Inductive Logic Programming for Code Search

面向代码搜索的主动归纳逻辑编程
ICSE 2019 IEEE/ACM 41st International Conference on Software Engineering (ICSE)2019匹配度 2/10 · 论文聚焦于用主动归纳逻辑编程从用户反馈中精化代码搜索查询,属于逻辑编程与开发者工具方向,但未涉及用户核心关注的静态分析、LLM/Agent 与程序分析的交叉、浮点程序分析或贝叶斯程序分析。引用 33 inbox
Aishwarya Sivaraman, Tianyi Zhang, Guy Van den Broeck, Miryung Kim
crossref: 2026-09-12dblp: 2026-09-12arxiv: 2026-09-12

AI 速览

一句话:提出交互式代码搜索技术 ALICE,用主动归纳逻辑编程从用户正负反馈中推断并精化逻辑查询。

现代代码搜索技术难以高效利用人工反馈,也难以表达代码的结构或语义属性。ALICE 将代码结构与语义建模为逻辑事实,并设计查询语言:给定带标注的代码示例,它从重要代码特征中自动抽取逻辑查询。用户把示例标为期望(正例)或不相关(负例),ALICE 便通过主动归纳逻辑编程推断能区分正负例的新查询,迭代精化搜索。模拟实验表明,ALICE 能快速消除大量假阳性,且对标注错误鲁棒;利用正负例并以嵌套程序结构作归纳偏置,有效提升查询精化。与已有交互式搜索技术相比,它无需手工构造搜索模式,却以更少迭代达到相近精确率与召回率;开发者案例研究显示其易用且能表达复杂模式。

问题
现代代码搜索难以高效整合人工反馈,也难以表达代码的结构或语义属性,导致查询精化困难。
方法
ALICE 用逻辑事实建模代码结构与语义,从用户标注的重要特征抽取逻辑查询,并通过主动归纳逻辑编程利用正负例推断区分性查询。
评估
通过模拟实验评估假阳性消除、标注错误鲁棒性及查询精化效果,并与已有交互式代码搜索比较;还开展真实开发者案例研究。
原文摘要(Abstract)

Modern search techniques either cannot efficiently incorporate human feedback to refine search results or cannot express structural or semantic properties of desired code. The key insight of our interactive code search technique ALICE is that user feedback can be actively incorporated to allow users to easily express and refine search queries. We design a query language to model the structure and semantics of code as logic facts. Given a code example with user annotations, ALICE automatically extracts a logic query from code features that are tagged as important. Users can refine the search query by labeling one or more examples as desired (positive) or irrelevant (negative). ALICE then infers a new logic query that separates positive examples from negative examples via active inductive logic programming. Our comprehensive simulation experiment shows that ALICE removes a large number of false positives quickly by actively incorporating user feedback. Its search algorithm is also robust to user labeling mistakes. Our choice of leveraging both positive and negative examples and using nested program structure as an inductive bias is effective in refining search queries. Compared with an existing interactive code search technique, ALICE does not require a user to manually construct a search pattern and yet achieves comparable precision and recall with much fewer search iterations. A case study with real developers shows that ALICE is easy to use and helps express complex code patterns.

链接与引用

DOI 原文 · arXiv · PDF(开放获取) · DBLP

BibTeX
@inproceedings{Sivaraman0BK19,
  title = {Active Inductive Logic Programming for Code Search},
  author = {Aishwarya Sivaraman and Tianyi Zhang and Guy Van den Broeck and Miryung Kim},
  booktitle = {ICSE},
  year = {2019},
  doi = {10.1109/icse.2019.00044}
}