Google launches Android Drag API, now available for apps

Android has long provided an activity recognition API that processes device sensor data with machine learning models in a battery-efficient way. Google is now offering an Android sleep API to create more wellness apps.

So much of what we do depends on a good night’s rest. Our phones have become great tools for making more informed decisions about our sleep. And by being informed about sleep habits, people can make better decisions about sleep during the day, which affects things like concentration and mental health.

Google’s new sleep API, which is part of the broader Android activity recognition API, analyzes the light and motion sensors of your phone with an AI model on the device to generate two pieces of information:

  • A “Sleep Confidence”, which is reported regularly (up to ten minutes)
  • A daily sleep segment, which is reported after a wake-up call is detected

With the introduction of this new tool, Google wants to save developers from ‘spending valuable engineering time combining sensor signals to determine when a user starts or ends activities such as sleep’, and note how:

These tracking algorithms are inconsistent between programs and when multiple programs independently and constantly monitor changes in user activity, battery life suffers.

End users will need to give permission for physical activity recognition before applications can access this data.

Google shows features similar to the sleep time mode in the Android Clock app and is working with the Sleep As Android app for today’s launch:

The new Sleep API offers us a fantastic opportunity to automatically detect it in the most battery-efficient way imaginable.

Sleep as Android Developers

The Sleep API is available with the latest version of Google Play Services on Android 10 and later, and can now be used by developers. If we look forward to it, Google will be working more on this API and in the future.

FTC: We use revenue to earn automatically affiliate links. More.


Check out 9to5Google on YouTube for more news:

Source