I am writing an app that include a scenario where I want a search using Siri like "Hey Siri, APP_NAME PHRASE" give any phrase using Siri and I need that PHRASE as Text to my app. I tried with custom intent but no luck. Is it possible to achieve with custom intent??
Related
I would like to be able to tell Siri "Hey Siri, play [app name]" for my radio app, and have it play a default station. What are the basic steps to achieve this? I'm not really looking for a Siri Shortcut per se, but built in "play" functionality. Is this possible?
You can achieve the following with Swift.
However, without any coding, Hey Siri, open [App Name] is possible automatically.
To add custom functionalities such as play a default station, please refer to this link
Could anyone enlighten me how does Siri recognise this sentence for Pinterest?
Pinterest: Find specific ideas you've saved: "Hey Siri, find women's
fashion Pins on Pinterest." https://www.imore.com/siri-apps-faq
I suspect its using INSearchForPhotosIntentHandling since the sentence has the closest reference to photos. The second thing I suspect is the use of Custom Vocabulary by swapping out "photo" with "Pins".
https://developer.apple.com/documentation/sirikit/registering_custom_vocabulary_with_sirikit
These are my current speculations for now, but I would like some clarity on this.
Use Case
I have an app that is centered around food reviews and I am hoping to integrate Siri to assist in Searching for food.
An example command:
"Hey Siri, find Japanese food in MY_APP."
"Hey Siri, find Japanese food reviews in MY_APP."
My keywords could be Food or Food Reviews or Reviews.
Siri process the request for your app based on the Intent that is supported by the app. There are only limited categories that is supported by Siri now.
So the siri know the vocabulary for these categories and it also uses your apps custom vocabulary to process the user given string to call the corresponding Intent from your extension.
IMO, you can consider reviews as notes and support INSearchForNotebookItemsIntentHandling by modifying the siri vocabulary.
Or the best way is to write to apple to add your corresponding domain in the siri's list of domains
According to Intents and thanks to this thread, I know that you can open your app via Siri with "Open [APP NAME]",
What I want to know is if it is possible to tell to Siri just only one word like 'Cheese' to open the Camera app or an other specific keyword set beforehand to open your own app using Siri.
Is it possible ? If yes, I have to use Intents to do that or there is another way ?
Siri runs on the OS level, so in order to use any intents you have set within your app, the user must specify your app.
"Get a ride with Lyft" or "Message Mom in Facebook" etc..
More examples in the doc:
https://developer.apple.com/sirikit/
You can use shortcuts app which comes inbuilt in all iOS devices, for knowing more about Siri Shortcuts refer below links.
https://developer.apple.com/documentation/sirikit/adding_user_interactivity_with_siri_shortcuts_and_the_shortcuts_app
https://www.pocket-lint.com/phones/news/apple/144718-what-is-siri-shortcuts-and-how-does-it-work
When I say "Translate English to Spanish" Siri opens the app Google Translate.
How does Siri know to launch this app and is it possible to register your app for certain keywords with Siri?
Usually you can open an app telling Siri something like:
"Open [APP NAME]"
My guess
In your case I guess Siri is not interpreting the sentence. When you say Translate English to Spanish Siri does try to understand what action should take and since no action with an hight Matching Rate is found then Siri tries to open the App having a name equals to the first word of your sentence.
Test 1
In Italian language the app is named Traduttore. When I say Traduci dall'italiano all'inglese (Translate English to Spanish) Siri does NOT open the translator because Traduttore does not match Traduci.
Test 2
If I say: Musica dall'italiano all'inglese (Music italian to english) which is not a real command, Siri does open the Music app.
Siri and third parties apps
Right now the interaction between Siri and third parties apps is pretty limited, however maybe in the future Apple will provide the tools for a deeper interaction.
Maybe something like what is happening with HomeKit where Apple created an interface to make Siri and Home Devices to talk each other.
You should look at Siri's custom vocabulary.
At the moment it is limited to your App's name and Apple specified domains e.g. Workouts or Ride Booking
But if you're lucky enough that your application falls within those categories you can map some more app specific terminology.
For example, if you had a rock climbing application, Ascent, you could start with a voice command similar to "Hey Siri, start climb" rather than "Hey Siri, start workout with Ascent"
All of your localized vocab choices should be placed into their appropriate language-specific project directories (.lproj).
I wants to share some text from my apple watch application to social media OR messaging apps . I found something from here - presentTextInputControllerWithSuggestions:allowedInputMode:completion:
I can able to show my text but not getting option to share my text like we found in UIactivityviewcontroller or share extension .
The method presentTextInputControllerWithSuggestions:allowedInputMode:completion: is useful to input text, for example by using voice input or by choosing from a list of suggestions.
If you want to share the selected text with someone else, send it to the iPhone app using the method openParentApplication... (more details here). Then on the iPhone, you have many possibilities that WatchKit currently does not offer.