Is there an API to get a word’s category?
e.g.,
word: "joke"; caetgory (retrieved from API) : "Entertainment",
word: "united states"; category(retrieved from API): "countries"
word:"jay leno"; category"celebrities(retrieved from API)",
and so on...
Categorization is always highly subjective. If you wish to use mainstream appproaches, try Wordnet (http://wordnet.princeton.edu/). It’s used by most workers in Natural Language Processing. Here’s an example
Here’s what you get for “joke”
Note that “hypernym” is a broader term and can be used as a category.
For people you can try Wikipedia and scrape the infobox (not much fun – I have spent a lot of time doing it). Better to try DBPedia.
Here is the Wikipedia infobox for Jay Leno:
I don’t know whether that has been captured for DBPedia. If so you will get some good categorization