Introducing NuGet Concierge

Introducing NuGet Concierge

Rate This
  • Comments 8

Twelve weeks ago, the Azure Applications Platform & Tools team welcomed us, three college sophomores, Jaspreet Bagga, Jeremiah Jekich, and Melissa McNeill, to Microsoft.

As Explorer Interns, we were given the opportunity to experience the three primary disciplines here at Microsoft: Program Manager, Software Development Engineer, and Software Development Engineer in Test. Rotating positions throughout the course of development, we were able to experience what life is like working in the developer tools division. We were given the opportunity to contribute to one of Visual Studio’s great tools, the NuGet package manager.

Package Discovery

For developers, discovering NuGet packages can be a daunting process. The best way to do so is either via word of mouth or online search. However, your friends aren’t always available when you’re looking for a new package at 3:00 in the morning. You could try to search online, but you’d need to spend unnecessary amounts of time sifting through the results before finding a package that may be helpful. We recognize that this time is better spent actually developing software. We wanted to create an accessible service to deliver package recommendations using real world data about how developers use packages.

clip_image002

NuGet Concierge

Thus was born NuGet Concierge, a package recommendation service that recommends packages to developers based on the packages currently being used in their project. We envisioned developers being able to upload their project’s packages.config file to the NuGet Concierge website, which would then present them with a list of packages they may find useful. Something along the lines of “Most projects that use Package A also use Package B.”

So, at the beginning of the summer, we put out a call to the community via Twitter, asking for developers to upload their projects’ packages.config files to help seed our newly conceived recommendation service. We asked, and you delivered! Armed with a collection of over 350 packages.config files, we set to work bringing NuGet Concierge to life.

Implementation

The first step was to translate the collected .config files into a structure that would allow us to analyze the relationships between packages. How often are individual packages used? But, more importantly, how are packages used together?

So, we took the community’s .config files and parsed them, using them to construct a graph. In doing so, we tracked the number of times a package was used, a value we referred to as the package’s “popularity.” We also tracked how many times two packages were used together, which we referred to as the packages’ “pairing frequency.”

Determining Relationships

Let’s say we have two packages, EntityFramework and jQuery. By looking at our graph, we know the popularity of EntityFramework and the popularity of jQuery, as well as the pairing frequency between the two. In order to determine the strength of EntityFramework’s relationship with jQuery, we take the pairing frequency between the two and divide it by the popularity of EntityFramework. This gives us the percentage of time EntityFramework is used with jQuery. If we want to know how strongly jQuery is associated with EntityFramework, we simply take the pairing frequency and divide it by the popularity of jQuery.

clip_image004

Making Recommendations

Suppose a developer has a packages.config file that contains knockoutjs. In order to make recommendations, we look at all packages used with knockoutjs that are not currently in use in the developer’s project. In this case, let’s say knockoutjs is associated with Newtonsoft.Json and Modernizr at association strengths of 91% and 87% respectively. We would recommend Newtonsoft.Json first, followed by Modernizr.

clip_image006

With NuGet Concierge, we made every effort to enable improvements over time. When users upload their packages.config file, we present them with the option to contribute their file to the NuGet Concierge dataset. This increases the pool of .config files from which we generate our graph. This means that our recommendations become more accurate the more NuGet Concierge is used.

Additionally once users are presented with recommendations, they have the option to “Like” or “Dislike” each recommendation by giving it a thumbs up or a thumbs down. This information gets stored and allows us to analyze the usefulness of the recommendations we are making. If we find some packages are being recommended at a high association strength, but most users deem them unhelpful, we can adjust the system to recommend the packages at more appropriate strengths. Likewise, we can give a strength boost to packages recommended at low association strengths but deemed helpful by the community.

clip_image008

NuGet Concierge’s Potential

When looking to the future, we see NuGet Concierge as a fully integrated part of NuGet, having a presence in the Gallery, Visual Studio’s Manage NuGet Packages dialog, and the Package Manager Console. The greatest part of NuGet Concierge is the data powering it. The ability to reference real data about how packages are actively used together opens up a world of opportunities that can potentially help NuGet better serve developers.

Exploring Microsoft and NuGet

As Explorer Interns, we are proud to be able to say we helped pioneer a new feature of NuGet. Though NuGet Concierge is in its infancy, it is a service that can be utilized today. In line with the rest of NuGet, it is an open source project that can be contributed to by members of the community. The three of us have grown a lot as developers over the past three months, and it will be fun to watch NuGet Concierge grow as we continue with our education.

When we first arrived, we had no experience developing with web technologies or building developer tools. We have been repeatedly amazed by the breadth of technologies used in the web space, and it has been an honor to contribute to a team that helps improve developer experiences.

The Explore Microsoft Program and the Azure Applications Platform & Tools team provided us with an amazing opportunity to learn from the best and it was an invaluable experience that has inspired us to continue pursuing a future in technology and software development.

Leave a Comment
  • Please add 7 and 7 and type the answer here:
  • Post
  • Looks great, although the data is quite limited at the moment and hence some suggestions don't seem to have much of a correlation (eg. I got "100% of projects using MySql.Data also use Modernizr"). Fantastic idea though! :)

  • I second the comment of Daniel Lo Nigro

  • If you're hitting "Get Recommendations" the first time without choosing a config file, there is a YSOD ( Happens with Firefox, Chrome ) (URL: concierge.nuget.org/.../PostForRecommendations )

    Otherwise, it looks promising once more data is available.

  • Fantastic idea.  I can see this becoming part of anybodies workflow, especially when working in a new area/techology.

  • Great idea. But I wonder what the use case is... Should I upload my config after I've added my first package? When i'm done w/ development and have all the packages I need pulled in and working?

    If the former, how do you know where I'm "headed" with my dev to recommend packages?

    If the latter, what do I tell my boss about needing to possibly re-work some things even though I'm done because I found packages I can use to better my stuff?

    Just thinking out loud. I like the idea, but it almost seems like a manual "Clippy" for .Net ("It looks like you're writing a web service, would you like to see some useful packages?") but since it's manual, it loses its usefulness...

  • I like this. There are many NuGet packages which can work really well in tandem with others, but have no dependency. For example, an application using Simple.Data can really benefit from ImpromptuInterface; some developers know that, but many don't. If Concierge can highlight cases like these, then that's awesome.

    If it can be integrated into Visual Studio, maybe with an option to always share packages.config and to re-call Concierge when a new package is added to a project, then even better.

    Well done to the interns who wrote this first version. A great start.

  • This is awesome. Since NuGet was born I love it! And now there is an opportunity to improve it beyond publishing libraries. I will post about it on my blog to promote it in the Spanish-speaker community!

  • very nice to read it and currently in use in the developer’s project.

Page 1 of 1 (8 items)