Facebook tweaks its algorithms to improve Graph Search; comment search coming

Facebook (s fb) is trying to improve the algorithms and expand the reach of its Graph Search function. Sriram Sankar, engineering manager on the social network’s search infrastructure team, detailed its plans in a blog post the company published on Thursday. While Graph Search still isn’t available to every Facebook user, its evolution is worth following, as it’s a large-scale implementation that could offer lessons for startups and enterprises dealing with continually growing databases.
Since its release to a select few users in January, Graph Search has caught attention for privacy reasons and for being less than ideal for marketers. Ordinary users have noticed shortcomings, too — searches don’t take status updates and comments into account, and results might turn up information that’s just not up to date. After attending a briefing on Graph Search at Facebook’s headquarters in Menlo Park, Calif., I pointed to a few of the improvements engineers were kicking around.
Thursday’s blog post suggests that engineers are making progress:

“We are also extending our search capabilities to do better text processing and ranking and have better mobile and internationalization support. Finally, we are also working on building a completely new vertical to handle searching posts and comments.”

As Facebook users play around with Graph Search, Facebook can observe how it’s used — and take user feedback — and adjust accordingly. One way to see if the work is paying off is click-through rate, Sankar writes. Once engineers come up with a possible means to improve the algorithms, they test it, try it out on a small group of users and then compare results.
So, almost two months after the Graph Search beta launch, how is it ranking search results? Exact algorithms are not publicly available. But here are some character traits that give a sense of how they work:

  • The search engine for querying Unicorn, the database underlying Graph Search, doesn’t have to spit out exactly what you ask it to. It can consider several factors on the back end before serving up results that you might actually find more relevant: how far away you are from places you search for, such as restaurants; how many degrees of Facebook-friend separation are there between you and the people you search for; how similar search results are to search queries; and what you have searched for in the past.
  • Unicorn brings together results in no specific order. But then they get ranked by their scores, which require metadata to be associated with each person, place or thing searchable with Graph Search.
  • When you start typing in a search string — take the words “people who live in s,” for example — Graph Search uses natural-language processing to make suggestions for searches of places that start with the letter s, rather than people whose names start with s.
  • Instead of offering search results based on the highest scores alone, Unicorn eliminates duplicates. For instance, a bunch of pictures of Mark Zuckerberg might not be what a user had in mind when she searched for “photos of Facebook employees.”
  • If results include people, places and things, not just one of those, then Unicorn needs to normalize the results and put them all in the best possible order.
  • Queries combine more than one of those elements — say, restaurants that friends like” — require Unicorn to score both restaurants and friends and share data between the two scoring efforts.

It’s nice to see that engineers are trying to improve Graph Search. The product could become more fun and useful. But there’s plenty more work to do, so don’t be caught off guard when Facebook announces further adjustments in coming months. With such a visible product, Facebook will have to keep making improvements, and that’s all the better for developers looking to refine search engines of their own.
This post was updated at 10:59 a.m. to correct the spelling of Facebook employee Sriram Sankar’s name.