Microsoft CEO Satya Nadella at a company event in San Francisco in 2014.

Microsoft has developed open-source software for crafting artificial intelligence models. But in recent months, the company has changed course, opting to work more closely with Facebook and contribute to the development of Facebook's own flavor of free AI software.

Microsoft hasn't made a big deal about the change. But it reflects a willingness to back software that comes from other major technology companies, rather than focusing only on its own platforms.

Google is the company behind the most popular open-source AI software, TensorFlow, which became available in late 2015. Microsoft put its Cognitive Toolkit, or CNTK, software on GitHub and gave it a more permissive open-source license in early 2016, and Facebook came out PyTorch, its answer to TensorFlow, later in 2016.

The Microsoft system has strengths, particularly for building speech recognition systems, but PyTorch has gained adoption quickly and has some interesting technical features of its own, Microsoft's chief technology officer, Kevin Scott, told CNBC in an interview this week.

Last year, Scott met with Facebook's chief technology officer, Mike Schroepfer, and decided it would be good for the companies to attempt to "defrag some of the complexity" in the ecosystem of software that people can use to train AI models. In Sept. 2017 Facebook and Microsoft together introduced ONNX, a piece of open-source software for exporting models trained with one AI software framework, like Microsoft's Cognitive Toolkit, so that they can be used to make predictions with other frameworks, like Facebook's PyTorch.

"We have to be able to actually contribute back to the community," he said.

The reality is there are just too many AI frameworks out there, said Sai Soundararaj, cofounder and CEO of AI start-up FloydHub. The start-up's cloud service has supported Microsoft's Cognitive Toolkit, but it hasn't gotten much use from customers, Soundararaj said.

Microsoft hasn't abandoned Cognitive Toolkit, even as it's focusing more on other projects. The Microsoft software still receives updates.

But the direction is clear. "The momentum of community, really, is around PyTorch and TensorFlow, and so that's where were throwing the bulk of our emphasis," said Eric Boyd, Microsoft's corporate vice president of AI platform. "Having community adoption is hugely important."

The move around Cognitive Toolkit is part of a recent trend at Microsoft to embrace technology from outside the company. It has embraced Linux, making it accessible from within Windows 10 and creating a Linux version of its SQL Server database software. It has reduced its efforts around Windows for mobile devices and ramped up development of applications for Apple's iOS and Google's Android. And Microsoft stopped developing its own big-data software, Dryad, and threw its support around the Hadoop open-source tools.