Skip to content
Commit c9acf678 authored by Tony Mak's avatar Tony Mak
Browse files

Allow NotificationAssistantService to suggest smart replies

If the apps has provided their own choices, they will be used, as opposed
to the "smart replies" from NAS.
Otherwise, smart replies will be applied to the notifications
with a freeform RemoteInput but without choices.

The smart reply model is not ready yet, so canned response is hardcoded
and it is disabled by default. To test it out, run
adb shell setprop persist.sys.smart_replies_experiment true
Also, to get rid of the target >= P SDK requirement, you may want to run:
adb shell settings put global smart_replies_in_notifications_flags enabled=true,max_squeeze_remeasure_attempts=3,requires_targeting_p=false

Test: atest SystemUITests
Test: atest frameworks/base/services/tests/uiservicestests/src/com/android/server/notification/NotificationListenerServiceTest.java
Test:
1. adb shell setprop persist.sys.smart_replies_experiment true
2. adb shell settings put global smart_replies_in_notifications_flags enabled=true,max_squeeze_remeasure_attempts=3,requires_targeting_p=false
3. Send a message to myself, observe the hardcoded smart replies.

Bug: 111674540

Change-Id: Ia61a77faef7c4dcba0501abfec80e3e8cc7274e4
parent 9a64ba26
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment