Hi i am trying to create an ios app and i want to add a feature where user presses a button, asks a question and gets a voice reply along with the reply text displayed on the screen. Anyone knows how i can do this? would appreciate any kind of resources
The starting points for this are speech recognition and speech synthesis, but of which are internal Apple frameworks - but fairly readily available.
- Speech synthesis in AVFoundation
- Speech framework
- Tutorial that includes speech recognition using the above framework.
Be aware that's just the starting point!
There's a whole 'nother field specialization - and not many public APIs - around converting a string a text into a nuanced request for information and getting relevant results (aka "search"). Quite a lot of how you solve that ends up relying on if you're dealing with structured or unstructured data (formal data in structures vs. blobs of text) and some aspects leverage ML pretty heavily to infer topics or alignment of query to relevant content against an index of that content you're using to reply from.
This forum is only about the Swift language. Apple has requested that questions/comments about their proprietary frameworks should be asked on the Apple developer forums .
For tips about which iOS frameworks might help you with a particular task, please ask on the Apple forums/StackOverflow/Reddit/Twitter/etc.