---
title: "Mining Idioms from Source Code — Allamanis 2014"
description: "The proposed system, Haggis, represents idioms as fragments of abstract syntax trees (ASTs). 55 references, cited by 23 papers here."
authors: ["Miltiadis Allamanis", "Charles Sutton"]
year: 2014
venue: "arXiv:1404.0417"
source: "https://arxiv.org/abs/1404.0417"
doi: "10.1145/2635868.2635901"
arxiv: "1404.0417"
licence: "arXiv — non-exclusive licence to distribute"
licence_url: "http://arxiv.org/licenses/nonexclusive-distrib/1.0/"
summary_licence: "Elamur Cosmic License"
canonical: "https://research.elamur.ai/free/en/papers/allamanis-2014-mining-idioms-source-code/"
---
[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/allamanis-2014-mining-idioms-source-code/)

[home](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2014](https://md.research.elamur.ai/free/en/papers/2014/page/2/) / Mining Idioms from Source Code

# Mining Idioms from Source Code

**Authors:** [Miltiadis Allamanis](https://md.research.elamur.ai/free/en/authors/miltiadis-allamanis/) and [Charles Sutton](https://md.research.elamur.ai/free/en/authors/charles-sutton/) · **Year:** 2014 · **Venue:** arXiv:1404.0417 · **Licence:** [arXiv — non-exclusive licence to distribute](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

**Links:** [Publisher's page](https://doi.org/10.1145/2635868.2635901) · [PDF](https://arxiv.org/pdf/1404.0417) · [DOI 10.1145/2635868.2635901](https://doi.org/10.1145/2635868.2635901) · [arXiv 1404.0417](https://arxiv.org/abs/1404.0417) · [OpenAlex](https://openalex.org/W2116272605)

**Citations:** 157 citations (OpenAlex, 2026-10-14) · [23](https://md.research.elamur.ai/free/en/papers/allamanis-2014-mining-idioms-source-code/cited-by/) in our library, of the 149,439 papers whose bibliographies we read

## Summary
The authors pose a new task: automatically finding code idioms. An idiom here is a syntactic fragment that recurs across different projects, serves a single semantic purpose and contains metavariables, such as a loop body or a variable name. Modern IDEs only allow such templates to be defined manually. As a result, a programmer who has just started working with a language or library is left without suggestions.

The proposed system, Haggis, represents idioms as fragments of abstract syntax trees (ASTs). It learns without supervision using a nonparametric Bayesian probabilistic tree substitution grammar (pTSG) borrowed from NLP. Haggis does not simply search for frequent subtrees. It keeps only those fragments that explain the corpus better, that is, that increase its probability under the model. This filters out templates that are common but meaningless.

The system was applied to popular open-source Java projects from GitHub. The idioms it found occur across different projects and in examples from StackOverflow. They describe object creation, exception handling and resource management. The work shows that statistical NLP methods are suitable for code analysis and can provide suggestions in an IDE.

## Key points
- 67% of the idioms found in the training projects from GitHub also appear in an independent set of code snippets from StackOverflow.
- Idioms can be suggested based on the imported packages alone. When suggestions are shown in 20% of cases, recall-at-rank-5 is 76%.
- Idioms can be general to the language (a loop over an array), tied to a library (closing an `android.database.Cursor` in a `finally` block) or project-specific. The association between idioms and packages was measured with lift on the examples of `android.location`, `android.net.wifi` and `org.hibernate`.
- Idioms differ from code clones: they recur across different projects and have "gaps" for expressions and blocks. What distinguishes them from API mining is their syntactic structure.
- Some idioms point to shortcomings of the language. An example is several consecutive `catch` blocks, which Java 7 replaced with the multi-catch construct.

*Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.*

## Institutions

- [University of Edinburgh](https://md.research.elamur.ai/free/en/universities/university-of-edinburgh/) — University, Edinburgh, United Kingdom · 396 works · 82,279 citations

📚 Shelves (3): [🖥️ Computer Science](https://md.research.elamur.ai/free/en/shelves/computer-science/) · 19,503 works · [🤖 Artificial Intelligence](https://md.research.elamur.ai/free/en/shelves/computer-science/artificial-intelligence/) · 18,805 works · [🗄️ Information Systems](https://md.research.elamur.ai/free/en/shelves/computer-science/information-systems/) · 1,888 works

🧭 Topics (2): [💻 Code & programming languages](https://md.research.elamur.ai/free/en/topics/code-and-programming/) · 194 works · [🧷 Idioms & multiword expressions](https://md.research.elamur.ai/free/en/topics/multiword-expressions/) · 223 works

## Cite

Cite as: Miltiadis Allamanis and Charles Sutton. 2014. Mining Idioms from Source Code. arXiv:1404.0417.

The paper itself, not this page. BibTeX from the library's record of the work.

```bibtex
@misc{allamanis2014mining,
  title = {{Mining Idioms from Source Code}},
  author = {Miltiadis Allamanis and Charles Sutton},
  year = {2014},
  doi = {10.1145/2635868.2635901},
  eprint = {1404.0417},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.1145/2635868.2635901}
}
```

- [← previous A Report on the DSL Shared Task 2014](https://md.research.elamur.ai/free/en/papers/zampieri-2014-report-dsl-shared-task/)
- [next → Learning part-of-speech taggers with inter-annotator agreement loss](https://md.research.elamur.ai/free/en/papers/plank-2014-learning-part-speech-taggers-inter/)
- [↑ back to papers of 2014](https://md.research.elamur.ai/free/en/papers/2014/page/2/)

## References

55 references, 1 of them with a card of ours. ↗ leads to the work, «find» searches for one we have no id for yet.

1. M. Acharya, T. Xie, J. Pei, and J. Xu. Mining API patterns as partial orders from source code: from usage scenarios to specifications. In Proceedings of the the 6th joint meeting of the European software engineering conference and the ACM SIGSOFT symposium on The foundations of software engineering,… [find](https://scholar.google.com/scholar?q=M%2E+Acharya%2C+T%2E+Xie%2C+J%2E+Pei%2C+and+J%2E+Xu%2E+Mining+API+patterns+as+partial+orders+from+source+code%3A+from+usage+scenarios+to+specifications%2E+In+Proceedings+of+the+the+6th+joint+meeting+of+the+European+softw)
2. M. Allamanis and C. Sutton. Mining source code repositories at massive scale using language modeling. In MSR, 2013. [find](https://scholar.google.com/scholar?q=M%2E+Allamanis+and+C%2E+Sutton%2E+Mining+source+code+repositories+at+massive+scale+using+language+modeling%2E+In+MSR%2C+2013%2E)
3. M. Allamanis, E. T. Barr, C. Bird, and C. Sutton. Learning natural coding conventions. arXiv preprint arXiv:1402.4182, 2014. — [arXiv:1402.4182](https://arxiv.org/abs/1402.4182) [find](https://scholar.google.com/scholar?q=M%2E+Allamanis%2C+E%2E+T%2E+Barr%2C+C%2E+Bird%2C+and+C%2E+Sutton%2E+Learning+natural+coding+conventions%2E+arXiv+preprint+arXiv%3A1402%2E4182%2C+2014%2E+%E2%80%94+%5BarXiv%3A1402%2E4182%5D%28https%3A%2F%2Farxiv%2Eorg%2Fabs%2F1402%2E4182%29)
4. A. Bacchelli. Mining challenge 2013: StackOverflow. In The 10th Working Conference on Mining Software Repositories, 2013. [find](https://scholar.google.com/scholar?q=A%2E+Bacchelli%2E+Mining+challenge+2013%3A+StackOverflow%2E+In+The+10th+Working+Conference+on+Mining+Software+Repositories%2C+2013%2E)
5. B. S. Baker. A program for identifying duplicated code. Computing Science and Statistics, pages 49–49, 1993. [find](https://scholar.google.com/scholar?q=B%2E+S%2E+Baker%2E+A+program+for+identifying+duplicated+code%2E+Computing+Science+and+Statistics%2C+pages+49%E2%80%9349%2C+1993%2E)
6. I. D. Baxter, A. Yahin, L. Moura, M. Sant’Anna, and L. Bier. Clone detection using abstract syntax trees. In Software Maintenance, 1998. Proceedings., International Conference on, pages 368–377. IEEE, 1998. [find](https://scholar.google.com/scholar?q=I%2E+D%2E+Baxter%2C+A%2E+Yahin%2C+L%2E+Moura%2C+M%2E+Sant%E2%80%99Anna%2C+and+L%2E+Bier%2E+Clone+detection+using+abstract+syntax+trees%2E+In+Software+Maintenance%2C+1998%2E+Proceedings%2E%2C+International+Conference+on%2C+pages+368%E2%80%93377%2E+IEEE%2C)
7. J. Campbell, A. Hindle, and J. N. Amaral. Syntax errors just aren’t natural: Improving error reporting with language models. [find](https://scholar.google.com/scholar?q=J%2E+Campbell%2C+A%2E+Hindle%2C+and+J%2E+N%2E+Amaral%2E+Syntax+errors+just+aren%E2%80%99t+natural%3A+Improving+error+reporting+with+language+models%2E)
8. S. Chuan. JavaScript Patterns Collection. [http://shichuan.github.io/javascript-patterns/](http://shichuan.github.io/javascript-patterns/), 2014. Visited Feb 2014. [↗](http://shichuan.github.io/javascript-patterns/)
9. T. Cohn, P. Blunsom, and S. Goldwater. Inducing tree-substitution grammars. The Journal of Machine Learning Research, 9999:3053–3096, 2010. [find](https://scholar.google.com/scholar?q=T%2E+Cohn%2C+P%2E+Blunsom%2C+and+S%2E+Goldwater%2E+Inducing+tree%2Dsubstitution+grammars%2E+The+Journal+of+Machine+Learning+Research%2C+9999%3A3053%E2%80%933096%2C+2010%2E)
10. R. Cottrell, R. J. Walker, and J. Denzinger. Semi-automating small-scale source code reuse via structural correspondence. In Proceedings of the 16th ACM SIG-SOFT International Symposium on Foundations of software engineering, pages 214–225. ACM, 2008. [find](https://scholar.google.com/scholar?q=R%2E+Cottrell%2C+R%2E+J%2E+Walker%2C+and+J%2E+Denzinger%2E+Semi%2Dautomating+small%2Dscale+source+code+reuse+via+structural+correspondence%2E+In+Proceedings+of+the+16th+ACM+SIG%2DSOFT+International+Symposium+on+Foundations)
11. Eclipse-Contributors. Eclipse JDT. eclipse.org/jdt, 2014. Visited Mar 2014. [find](https://scholar.google.com/scholar?q=Eclipse%2DContributors%2E+Eclipse+JDT%2E+eclipse%2Eorg%2Fjdt%2C+2014%2E+Visited+Mar+2014%2E)
12. J. I. Editors. Java Idioms. [http://c2.com/ppr/wiki/JavaIdioms/JavaIdioms.html](http://c2.com/ppr/wiki/JavaIdioms/JavaIdioms.html), 2014. Visited Feb 2014. [↗](http://c2.com/ppr/wiki/JavaIdioms/JavaIdioms.html)
13. R. Falke, P. Frenzel, and R. Koschke. Empirical evaluation of clone detection using syntax suffix trees. Empirical Software Engineering, 13(6):601–643, 2008. [find](https://scholar.google.com/scholar?q=R%2E+Falke%2C+P%2E+Frenzel%2C+and+R%2E+Koschke%2E+Empirical+evaluation+of+clone+detection+using+syntax+suffix+trees%2E+Empirical+Software+Engineering%2C+13%286%29%3A601%E2%80%93643%2C+2008%2E)
14. M. Gabel and Z. Su. A study of the uniqueness of source code. In Proceedings of the eighteenth ACM SIGSOFT international symposium on Foundations of software engineering, pages 147–156. ACM, 2010. [find](https://scholar.google.com/scholar?q=M%2E+Gabel+and+Z%2E+Su%2E+A+study+of+the+uniqueness+of+source+code%2E+In+Proceedings+of+the+eighteenth+ACM+SIGSOFT+international+symposium+on+Foundations+of+software+engineering%2C+pages+147%E2%80%93156%2E+ACM%2C+2010%2E)
15. A. Gelman, J. B. Carlin, H. S. Stern, D. B. Dunson, A. Vehtari, and D. B. Rubin. Bayesian data analysis. CRC Press, 2013. [find](https://scholar.google.com/scholar?q=A%2E+Gelman%2C+J%2E+B%2E+Carlin%2C+H%2E+S%2E+Stern%2C+D%2E+B%2E+Dunson%2C+A%2E+Vehtari%2C+and+D%2E+B%2E+Rubin%2E+Bayesian+data+analysis%2E+CRC+Press%2C+2013%2E)
16. S. J. Gershman and D. M. Blei. A tutorial on Bayesian nonparametric models. Journal of Mathematical Psychology, 56(1):1–12, 2012. [find](https://scholar.google.com/scholar?q=S%2E+J%2E+Gershman+and+D%2E+M%2E+Blei%2E+A+tutorial+on+Bayesian+nonparametric+models%2E+Journal+of+Mathematical+Psychology%2C+56%281%29%3A1%E2%80%9312%2C+2012%2E)
17. I. Grigorik. GitHub Archive. www.githubarchive.org, 2014. Visited Mar 2014. [find](https://scholar.google.com/scholar?q=I%2E+Grigorik%2E+GitHub+Archive%2E+www%2Egithubarchive%2Eorg%2C+2014%2E+Visited+Mar+2014%2E)
18. A. Hindle, E. T. Barr, Z. Su, M. Gabel, and P. Devanbu. On the naturalness of software. In ICSE, 2012. [find](https://scholar.google.com/scholar?q=A%2E+Hindle%2C+E%2E+T%2E+Barr%2C+Z%2E+Su%2C+M%2E+Gabel%2C+and+P%2E+Devanbu%2E+On+the+naturalness+of+software%2E+In+ICSE%2C+2012%2E)
19. N. L. Hjort. Bayesian nonparametrics. Number 28. Cambridge University Press, 2010. [find](https://scholar.google.com/scholar?q=N%2E+L%2E+Hjort%2E+Bayesian+nonparametrics%2E+Number+28%2E+Cambridge+University+Press%2C+2010%2E)
20. R. Holmes, R. J. Walker, and G. C. Murphy. Approximate structural context matching: An approach to recommend relevant examples. Software Engineering, IEEE Transactions on, 32(12):952–970, 2006. [find](https://scholar.google.com/scholar?q=R%2E+Holmes%2C+R%2E+J%2E+Walker%2C+and+G%2E+C%2E+Murphy%2E+Approximate+structural+context+matching%3A+An+approach+to+recommend+relevant+examples%2E+Software+Engineering%2C+IEEE+Transactions+on%2C+32%2812%29%3A952%E2%80%93970%2C+2006%2E)
21. F. Jacob and R. Tairas. Code template inference using language models. In Proceedings of the 48th Annual Southeast Regional Conference, page 104. ACM, 2010. [find](https://scholar.google.com/scholar?q=F%2E+Jacob+and+R%2E+Tairas%2E+Code+template+inference+using+language+models%2E+In+Proceedings+of+the+48th+Annual+Southeast+Regional+Conference%2C+page+104%2E+ACM%2C+2010%2E)
22. JetBrains. High-speed coding with Custom Live Templates. bit.ly/1o8R8Do, 2014. Visited Mar 2014. [find](https://scholar.google.com/scholar?q=JetBrains%2E+High%2Dspeed+coding+with+Custom+Live+Templates%2E+bit%2Ely%2F1o8R8Do%2C+2014%2E+Visited+Mar+2014%2E)
23. L. Jiang, G. Misherghi, Z. Su, and S. Glondu. Deckard: Scalable and accurate tree-based detection of code clones. In Proceedings of the 29th international conference on Software Engineering, pages 96–105. IEEE Computer Society, 2007. [find](https://scholar.google.com/scholar?q=L%2E+Jiang%2C+G%2E+Misherghi%2C+Z%2E+Su%2C+and+S%2E+Glondu%2E+Deckard%3A+Scalable+and+accurate+tree%2Dbased+detection+of+code+clones%2E+In+Proceedings+of+the+29th+international+conference+on+Software+Engineering%2C+pages+96%E2%80%93)
24. A. Jiménez, F. Berzal, and J.-C. Cubero. Frequent tree pattern mining: A survey. Intelligent Data Analysis, 14 (6):603–622, 01 2010. [find](https://scholar.google.com/scholar?q=A%2E+Jime%CC%81nez%2C+F%2E+Berzal%2C+and+J%2E%2DC%2E+Cubero%2E+Frequent+tree+pattern+mining%3A+A+survey%2E+Intelligent+Data+Analysis%2C+14+%286%29%3A603%E2%80%93622%2C+01+2010%2E)
25. T. Kamiya, S. Kusumoto, and K. Inoue. CCFinder: a multilinguistic token-based code clone detection system for large scale source code. Software Engineering, IEEE Transactions on, 28(7):654–670, 2002. [find](https://scholar.google.com/scholar?q=T%2E+Kamiya%2C+S%2E+Kusumoto%2C+and+K%2E+Inoue%2E+CCFinder%3A+a+multilinguistic+token%2Dbased+code+clone+detection+system+for+large+scale+source+code%2E+Software+Engineering%2C+IEEE+Transactions+on%2C+28%287%29%3A654%E2%80%93670%2C+2002%2E)
26. C. J. Kapser and M. W. Godfrey. “Cloning considered harmful” considered harmful: patterns of cloning in software. Empirical Software Engineering, 13(6):645– 692, 2008. [find](https://scholar.google.com/scholar?q=C%2E+J%2E+Kapser+and+M%2E+W%2E+Godfrey%2E+%E2%80%9CCloning+considered+harmful%E2%80%9D+considered+harmful%3A+patterns+of+cloning+in+software%2E+Empirical+Software+Engineering%2C+13%286%29%3A645%E2%80%93+692%2C+2008%2E)
27. M. Kim, V. Sazawal, D. Notkin, and G. Murphy. An empirical study of code clone genealogies. In ACM SIGSOFT Software Engineering Notes, volume 30, pages 187–196. ACM, 2005. [find](https://scholar.google.com/scholar?q=M%2E+Kim%2C+V%2E+Sazawal%2C+D%2E+Notkin%2C+and+G%2E+Murphy%2E+An+empirical+study+of+code+clone+genealogies%2E+In+ACM+SIGSOFT+Software+Engineering+Notes%2C+volume+30%2C+pages+187%E2%80%93196%2E+ACM%2C+2005%2E)
28. K. A. Kontogiannis, R. DeMori, E. Merlo, M. Galler, and M. Bernstein. Pattern matching for clone and concept detection. In Reverse engineering, pages 77–108. Springer, 1996. [find](https://scholar.google.com/scholar?q=K%2E+A%2E+Kontogiannis%2C+R%2E+DeMori%2C+E%2E+Merlo%2C+M%2E+Galler%2C+and+M%2E+Bernstein%2E+Pattern+matching+for+clone+and+concept+detection%2E+In+Reverse+engineering%2C+pages+77%E2%80%93108%2E+Springer%2C+1996%2E)
29. R. Koschke, R. Falke, and P. Frenzel. Clone detection using abstract syntax suffix trees. In Reverse Engineering, 2006. WCRE’06. 13th Working Conference on, pages 253–262. IEEE, 2006. [find](https://scholar.google.com/scholar?q=R%2E+Koschke%2C+R%2E+Falke%2C+and+P%2E+Frenzel%2E+Clone+detection+using+abstract+syntax+suffix+trees%2E+In+Reverse+Engineering%2C+2006%2E+WCRE%E2%80%9906%2E+13th+Working+Conference+on%2C+pages+253%E2%80%93262%2E+IEEE%2C+2006%2E)
30. I. Kuzborskij. Large-scale pattern mining of computer program source code. Master’s thesis, University of Edinburgh, 2011. [find](https://scholar.google.com/scholar?q=I%2E+Kuzborskij%2E+Large%2Dscale+pattern+mining+of+computer+program+source+code%2E+Master%E2%80%99s+thesis%2C+University+of+Edinburgh%2C+2011%2E)
31. Z. Li, S. Lu, S. Myagmar, and Y. Zhou. CP-Miner: Finding copy-paste and related bugs in large-scale software code. Software Engineering, IEEE Transactions on, 32(3):176–192, 2006. [find](https://scholar.google.com/scholar?q=Z%2E+Li%2C+S%2E+Lu%2C+S%2E+Myagmar%2C+and+Y%2E+Zhou%2E+CP%2DMiner%3A+Finding+copy%2Dpaste+and+related+bugs+in+large%2Dscale+software+code%2E+Software+Engineering%2C+IEEE+Transactions+on%2C+32%283%29%3A176%E2%80%93192%2C+2006%2E)
32. P. Liang, M. I. Jordan, and D. Klein. Type-based MCMC. In Human Language Technologies: The 2010 Annual Conference of the North American Chapter of the Association for Computational Linguistics, pages 573– 581. Association for Computational Linguistics, 2010. [find](https://scholar.google.com/scholar?q=P%2E+Liang%2C+M%2E+I%2E+Jordan%2C+and+D%2E+Klein%2E+Type%2Dbased+MCMC%2E+In+Human+Language+Technologies%3A+The+2010+Annual+Conference+of+the+North+American+Chapter+of+the+Association+for+Computational+Linguistics%2C+pages+)
33. C. J. Maddison and D. Tarlow. Structured generative models of natural source code. arXiv preprint arXiv:1401.0514, 2014. [find](https://scholar.google.com/scholar?q=C%2E+J%2E+Maddison+and+D%2E+Tarlow%2E+Structured+generative+models+of+natural+source+code%2E+arXiv+preprint+arXiv%3A1401%2E0514%2C+2014%2E)
34. A. Menon, O. Tamuz, S. Gulwani, B. Lampson, and A. Kalai. A machine learning framework for programming by example. In Proceedings of The 30th International Conference on Machine Learning, pages 187–195, 2013. [find](https://scholar.google.com/scholar?q=A%2E+Menon%2C+O%2E+Tamuz%2C+S%2E+Gulwani%2C+B%2E+Lampson%2C+and+A%2E+Kalai%2E+A+machine+learning+framework+for+programming+by+example%2E+In+Proceedings+of+The+30th+International+Conference+on+Machine+Learning%2C+pages+187%E2%80%9319)
35. K. P. Murphy. Machine learning: a probabilistic perspective. MIT Press, 2012. [find](https://scholar.google.com/scholar?q=K%2E+P%2E+Murphy%2E+Machine+learning%3A+a+probabilistic+perspective%2E+MIT+Press%2C+2012%2E)
36. T. T. Nguyen, H. A. Nguyen, N. H. Pham, J. M. Al-Kofahi, and T. N. Nguyen. Graph-based mining of multiple object usage patterns. In Proceedings of the the 7th joint meeting of the European software engineering conference and the ACM SIGSOFT symposium on The foundations of software engineering, pages… [find](https://scholar.google.com/scholar?q=T%2E+T%2E+Nguyen%2C+H%2E+A%2E+Nguyen%2C+N%2E+H%2E+Pham%2C+J%2E+M%2E+Al%2DKofahi%2C+and+T%2E+N%2E+Nguyen%2E+Graph%2Dbased+mining+of+multiple+object+usage+patterns%2E+In+Proceedings+of+the+the+7th+joint+meeting+of+the+European+software+en)
37. T. T. Nguyen, A. T. Nguyen, H. A. Nguyen, and T. N. Nguyen. A statistical semantic language model for source code. In FSE, 2013. [find](https://scholar.google.com/scholar?q=T%2E+T%2E+Nguyen%2C+A%2E+T%2E+Nguyen%2C+H%2E+A%2E+Nguyen%2C+and+T%2E+N%2E+Nguyen%2E+A+statistical+semantic+language+model+for+source+code%2E+In+FSE%2C+2013%2E)
38. Oracle. Java SE Documentation: Catching Multiple Exception Types and Rethrow-ing Exceptions with Improved Type Checking. [http://docs.oracle.com/javase/7/docs/technotes/guides/language/catch-multiple.html](http://docs.oracle.com/javase/7/docs/technotes/guides/language/catch-multiple.html), 2014. Visited Feb 2014. [↗](http://docs.oracle.com/javase/7/docs/technotes/guides/language/catch-multiple.html)
39. P. Orbanz and Y. W. Teh. Bayesian nonparametric models. In Encyclopedia of Machine Learning. Springer, 2010. [find](https://scholar.google.com/scholar?q=P%2E+Orbanz+and+Y%2E+W%2E+Teh%2E+Bayesian+nonparametric+models%2E+In+Encyclopedia+of+Machine+Learning%2E+Springer%2C+2010%2E)
40. M. Post and D. Gildea. Bayesian learning of a tree substitution grammar. In Proceedings of the ACL-IJCNLP 2009 Conference Short Papers, pages 45–48. Association for Computational Linguistics, 2009. [find](https://scholar.google.com/scholar?q=M%2E+Post+and+D%2E+Gildea%2E+Bayesian+learning+of+a+tree+substitution+grammar%2E+In+Proceedings+of+the+ACL%2DIJCNLP+2009+Conference+Short+Papers%2C+pages+45%E2%80%9348%2E+Association+for+Computational+Linguistics%2C+2009%2E)
41. E. Recommenders-Contributors. Eclipse Snip-Match. wiki.eclipse.org/Recommenders/Snipmatch, 2014. Visited Mar 2014. [find](https://scholar.google.com/scholar?q=E%2E+Recommenders%2DContributors%2E+Eclipse+Snip%2DMatch%2E+wiki%2Eeclipse%2Eorg%2FRecommenders%2FSnipmatch%2C+2014%2E+Visited+Mar+2014%2E)
42. M. Research. High-speed coding with Custom Live Templates. research.microsoft.com/apps/video/dl.aspx?id=208961, 2014. Visited Mar 2014. [find](https://scholar.google.com/scholar?q=M%2E+Research%2E+High%2Dspeed+coding+with+Custom+Live+Templates%2E+research%2Emicrosoft%2Ecom%2Fapps%2Fvideo%2Fdl%2Easpx%3Fid%3D208961%2C+2014%2E+Visited+Mar+2014%2E)
43. C. K. Roy and J. R. Cordy. A survey on software clone detection research. Technical report, Queen’s University at Kingston, Ontario, 2007. [find](https://scholar.google.com/scholar?q=C%2E+K%2E+Roy+and+J%2E+R%2E+Cordy%2E+A+survey+on+software+clone+detection+research%2E+Technical+report%2C+Queen%E2%80%99s+University+at+Kingston%2C+Ontario%2C+2007%2E)
44. C. K. Roy, J. R. Cordy, and R. Koschke. Comparison and evaluation of code clone detection techniques and tools: A qualitative approach. Science of Computer Programming, 74(7):470–495, 2009. [find](https://scholar.google.com/scholar?q=C%2E+K%2E+Roy%2C+J%2E+R%2E+Cordy%2C+and+R%2E+Koschke%2E+Comparison+and+evaluation+of+code+clone+detection+techniques+and+tools%3A+A+qualitative+approach%2E+Science+of+Computer+Programming%2C+74%287%29%3A470%E2%80%93495%2C+2009%2E)
45. J. Sethuraman. A constructive definition of Dirichlet priors. Technical report, DTIC Document, 1991. [find](https://scholar.google.com/scholar?q=J%2E+Sethuraman%2E+A+constructive+definition+of+Dirichlet+priors%2E+Technical+report%2C+DTIC+Document%2C+1991%2E)
46. Y. W. Teh. [A hierarchical Bayesian language model based on Pitman-Yor processes](https://md.research.elamur.ai/free/en/papers/teh-2006-hierarchical-bayesian-language-model-based/). In Proceedings of the 21st International Conference on Computational Linguistics and 44th Annual Meeting of the Association for Computational Linguistics, pages 985–992, 2006.
47. Y. W. Teh and M. I. Jordan. Hierarchical Bayesian nonparametric models with applications. In N. Hjort, C. Holmes, P. Müller, and S. Walker, editors, Bayesian Nonparametrics: Principles and Practice. Cambridge University Press, 2010. [find](https://scholar.google.com/scholar?q=Y%2E+W%2E+Teh+and+M%2E+I%2E+Jordan%2E+Hierarchical+Bayesian+nonparametric+models+with+applications%2E+In+N%2E+Hjort%2C+C%2E+Holmes%2C+P%2E+Mu%CC%88ller%2C+and+S%2E+Walker%2C+editors%2C+Bayesian+Nonparametrics%3A+Principles+and+Practice%2E+)
48. A. Termier, M.-C. Rousset, and M. Sebag. Treefinder: a first step towards XML data mining. In Data Mining, 2002. ICDM 2003. Proceedings. 2002 IEEE International Conference on, pages 450–457. IEEE, 2002. [find](https://scholar.google.com/scholar?q=A%2E+Termier%2C+M%2E%2DC%2E+Rousset%2C+and+M%2E+Sebag%2E+Treefinder%3A+a+first+step+towards+XML+data+mining%2E+In+Data+Mining%2C+2002%2E+ICDM+2003%2E+Proceedings%2E+2002+IEEE+International+Conference+on%2C+pages+450%E2%80%93457%2E+IEEE%2C+200)
49. R. Waldron. Principles of Writing Consistent, Idiomatic JavaScript. [https://github.com/rwaldron/idiomatic.js/](https://github.com/rwaldron/idiomatic.js/), 2014. Visited Feb 2014. [↗](https://github.com/rwaldron/idiomatic.js/)
50. J. Wang, Y. Dang, H. Zhang, K. Chen, T. Xie, and D. Zhang. Mining succinct and high-coverage API usage patterns from source code. In Mining Software Repositories (MSR), 2013 10th IEEE Working Conference on, pages 319–328. IEEE, 2013. [find](https://scholar.google.com/scholar?q=J%2E+Wang%2C+Y%2E+Dang%2C+H%2E+Zhang%2C+K%2E+Chen%2C+T%2E+Xie%2C+and+D%2E+Zhang%2E+Mining+succinct+and+high%2Dcoverage+API+usage+patterns+from+source+code%2E+In+Mining+Software+Repositories+%28MSR%29%2C+2013+10th+IEEE+Working+Conferen)
51. Wikibooks. More C++ Idioms. [http://en.wikibooks.org/wiki/More_C%2B%2B_Idioms](http://en.wikibooks.org/wiki/More_C%2B%2B_Idioms), 2013. Visited Feb 2014. [↗](http://en.wikibooks.org/wiki/More_C%2B%2B_Idioms)
52. C. K. Williams and C. E. Rasmussen. Gaussian Processes for Machine Learning, 2006. [find](https://scholar.google.com/scholar?q=C%2E+K%2E+Williams+and+C%2E+E%2E+Rasmussen%2E+Gaussian+Processes+for+Machine+Learning%2C+2006%2E)
53. M. J. Zaki. Efficiently mining frequent trees in a forest. In Proceedings of the eighth ACM SIGKDD international conference on Knowledge discovery and data mining, pages 71–80. ACM, 2002. [find](https://scholar.google.com/scholar?q=M%2E+J%2E+Zaki%2E+Efficiently+mining+frequent+trees+in+a+forest%2E+In+Proceedings+of+the+eighth+ACM+SIGKDD+international+conference+on+Knowledge+discovery+and+data+mining%2C+pages+71%E2%80%9380%2E+ACM%2C+2002%2E)
54. M. J. Zaki. Efficiently mining frequent trees in a forest: Algorithms and applications. Knowledge and Data Engineering, IEEE Transactions on, 17(8):1021–1035, 2005. [find](https://scholar.google.com/scholar?q=M%2E+J%2E+Zaki%2E+Efficiently+mining+frequent+trees+in+a+forest%3A+Algorithms+and+applications%2E+Knowledge+and+Data+Engineering%2C+IEEE+Transactions+on%2C+17%288%29%3A1021%E2%80%931035%2C+2005%2E)
55. H. Zhong, T. Xie, L. Zhang, J. Pei, and H. Mei. MAPO: Mining and recommending API usage patterns. In ECOOP 2009–Object-Oriented Programming, pages 318– 343. Springer, 2009. [find](https://scholar.google.com/scholar?q=H%2E+Zhong%2C+T%2E+Xie%2C+L%2E+Zhang%2C+J%2E+Pei%2C+and+H%2E+Mei%2E+MAPO%3A+Mining+and+recommending+API+usage+patterns%2E+In+ECOOP+2009%E2%80%93Object%2DOriented+Programming%2C+pages+318%E2%80%93+343%2E+Springer%2C+2009%2E)

*Updated 3 November 2026*
