In the previous few segment, you saw that we need a structure using which we can represent the meaning of sentences.one such schematic structure (used widely by search enhines to index web pages) is schema .org.
Schema. org is a joint effort by Google, yahoo ,Bing and Yandex (Russian search engine) to create a large schema relating the most commonly occurring entities on web pages. the main purpose of the schema is to ease search engine querying and improve search performance.
For example , say a web page of a hotel (e.g. Hotel Ginger) contains the words ‘Ginger’ and ‘four stars’. How would a search engine indexing this page know whether the word ‘Ginger’ refers to the plant ginger or Hotel Ginger? Similarly, how would it know whether the phrase ‘four stars’ refers to the rating of a hotel or to astronomical stars?
To solve this problem, schema.org provides a way to explicitly specify the types of entities on web pages. For example, one can explicitly mention that ‘Ginger’ is the name of the hotel and specify various entities such as its rating, price etc. (example HTML shown below).
Even if you are not familiar with HTML, just notice the attributes itemtype=’Hotel’ and itemprop=’name’, ‘rating’ and ‘price’. These attributes explicitly mention that the text on the web page (in the section inside the <div>) is about a hotel, that the hotel’s name is Ginger, its rating is four stars and the price is INR 3500.
<div itemscope itemtype ="http://schema.org/Hotel">
<h1 itemprop="name">Ginger</h1>
<span>Rating: <span itemprop="rating">Four Star Hotel</span>
<span itemprop="price">INR 3500</span>
</div>
Huge schemas or ‘knowledge graphs’ of the world, such as schema.org, are quite important while building semantic processing engines (such as web search engines). Although you will not be working on such schemas/web-based search in this course, it is an important resource to know about.
You can read more about schema.org here:
- An example showing how a web page can use schema.org to specify entity types
- How banks and financial institutions can use schemas for marking up banks and their products
- Schema.org FAQs: The basics of schema.org (who, what, why etc.) answered concisely
- In the next section, you’ll learn about semantic associations.