Use Swift to interpret unstructured data from Hacker News  

Use cognitive APIs to gain insight into tech trends on Hacker News with a twist

Last updated | By Ishan Gulane


Getting insights from large amounts of unstructured data sources is getting easier to do because of machine-learning technologies. Learn how to pull data points — concepts, entities, categories, keywords, sentiment, emotion, etc. — from Hacker News articles using natural-language service calls from a Swift-based application.


“Natural Language Processing (NLP) is a field that covers computer understanding and manipulation of human language, and it’s ripe with possibilities for news-gathering,” Anthony Pesce said in Natural Language Process in the kitchen. NLP enables developers to organize and structure knowledge to perform tasks such as named entity recognition, relationship extraction, sentiment analysis, and speech recognition. The application of NLP is being used in many fields, including medicine, law, and others where there are vast amounts of unstructured data users need to quickly pull information from.

Typically, we have seen applications that utilize NLP APIs built in Python or Node.js. This journey has a twist by introducing you to embedding machine-learning capabilities in a Swift-based application. You will use the Watson™ Natural Language Understanding API to interpret unstructured text from Hacker News to identify the latest trends and key topic areas discussed by developers. You will see how easy it is to call this service from a Swift application.


  1. The user deploys the application to IBM Cloud®.
  2. Application loads the data from the Hacker News API.
  3. The user interacts with the application UI using a browser.
  4. When the user performs any action, UI calls the server application API, which uses the Watson NLU service to analyze the respective news article.

Related Blogs

Leveraging the power of AI at Unite Berlin

Last week, from June 19 – 21, we were at Unity’s premiere in Berlin: Unite 2018. This conference brought together Unity’s video game and development community. Unity touches 770 million gamers all over the world and is the market leader for consumer AR and VR use cases and is also rapidly emerging as the market...

Continue reading Leveraging the power of AI at Unite Berlin

Are You Developers? WeAreDevelopers, 2018

Earlier this year, we attended the WeAreDevelopers World Congress conference in Vienna. Named Europe’s largest playground for developers, founded as recently as 2015, the Congress has truly grown from strength to strength. From May 16th – 18th there were 8,000 participants, 250+ speakers, 100+ sponsors, who all convened in Austria’s capital for 3 days of...

Continue reading Are You Developers? WeAreDevelopers, 2018

Related Links


Building secure server-side Swift apps for Cloud