Facebook using new self-tuning machine learning for some services
Facebook Inc. is using a real-time, self-tuning machine learning technique dubbed Spiral to manage some services, the social network said in a blog post.
According to the company, self-tuning machine learning is the need of the hour as change in different services on the social network's back-end is rapid.
"The Facebook codebase is pushed to production every few hours — for example, new versions of the front end — as part of our continuous deployment process. In this dynamic world, trying to manually fine-tune services to maintain peak efficiency is impractical," the company's engineers said in the post.
They also said that it is too difficult to rewrite caching, admission or eviction policies and other manually tuned heuristics by hand. "We have to fundamentally change how we think about software maintenance," they said.
In order to tackle the issue and effectively optimise its services, the company came out with a self-tuning approach rather than relying on manually hard-coded heuristics and parameters.
"Instead of looking at charts and logs produced by the system to verify correct and efficient operation, engineers now express what it means for a system to operate correctly and efficiently in code," the engineers explained. "Today, rather than specify how to compute correct responses to requests, our engineers encode the means of providing feedback to a self-tuning system."
Explaining further, they said that the approach was similar to declarative programming which is used in Structured Query Language.
"SQL is a popular example of this approach: Instead of specifying how to compute the result of a complex query, an engineer just needs to specify what needs to be computed and then the engine figures out the optimal query and executes it," they wrote.
However, they said the Spiral approach had challenges. Engineers need to be very precise when declaring objectives of the programme.
"In our experience, precisely defining the desired outcome for self-tuning is one of the hardest parts of onboarding with Spiral. However, we also found that engineers tended to converge on clear and correct definitions after a few iterations," they said.