Apple announces new ways to build intelligence into your iphone and ipad apps