Mylyn + Code Recommenders = Task + Context–aware Intelligent Code Completion

As a frequent reader of this blog, you already know that Code Recommenders is all about helping developers to use existing APIs correctly. It does so by analyzing thousands of sample applications and extracts patterns how other developers used that API before and enhances your code completion with neat percentage values that give you pointers which methods you are likely to use next.

You probably also know that Mylyn Tasks is about clean UIs. To keep your UI clean, Mylyn for example removes elements from the package explorer which are irrelevant for the current task you are working on and thus removes the clutter that may distract you from your goal. It also boosts code completion proposals to the top that are more interesting than others. All purely based on the knowledge which methods or types developers (who worked on that very same task before) used or looked at.

Both tools foster knowledge transfer between developers and help to speed up your development but both are based on fundamentally different data: Code Recommenders leverages the knowledge of the masses by analyzing gigabytes of source code to make its recommendations; Mylyn relies on the navigation/use history of the local team experts that worked on that task before.

Introduced that way, it sounds obvious to ask “why not combining both technologies?” And well, I’m happy to say that we made a first step towards leveraging the best of both worlds: With Code Recommenders 2.0.6 we published an experimental Mylyn Integration for Code Recommenders that (in addition to Code Recommenders’ own relevance assessments) incorporates Mylyn’s Interestingness Measure to boost proposals even for APIs Code Recommenders has no data for - but Mylyn has because developers were using tasks.

So, in the end you get the best of both worlds: As soon as Mylyn deems a Java element interesting enough and puts it into the context, Code Recommenders will now recommend it:

Cool stuff!


You can install the Code Recommenders Mylyn Integration from the Code Recommenders milestones update site. You only have to make sure Mylyn is already installed in your Eclipse.

Enjoy - and as this feature is quite experimental, please let us know what you think about it at this feature’s Bugzilla bug, or via Twitter, Google+ or the mailing lists/forum.

Update Site


Pharme623's picture

Nice post. I was checking constantly this blog and I am impressed! Extremely useful information specially the last part bacdddbegeef

Add new comment