SNSW Unit - 1
SNSW Unit - 1
UNIT - I
Thinking and Intelligent Web Applications, The Information Age ,The World Wide Web, Limitations
of Today‘s Web, The Next Generation Web, Machine Intelligence, Artificial Intelligence, Ontology,
Inference engines, Software Agents, Berners-Lee www, Semantic Road Map, Logic on the semantic
Web.
UNIT I:
Web Intelligence:
1. Thinking and Intelligent Web Applications,
2. The Information Age ,
3. The World Wide Web,
4. Limitations of Today’s Web,
5. The Next Generation Web,
6. Machine Intelligence,
7. Artificial Intelligence,
8. Ontology,
9. Inference engines,
10.Software Agents,
11.Berners-Lee www,
12.Semantic Road Map,
13.Logic on the semantic Web.
In general, thinking can be a complex process that uses concepts, their interrelationships, and
inference or deduction, to produce new knowledge. However, thinking is often used to describe such
disparate acts as memory recall, arithmetic calculations, creating stories, decision making, puzzle
solving, and so on.
The term ―intelligence‖ can be applied to non human entities as we do in the field of Artificial
Intelligence (AI). But frequently we mean something somewhat different than in the case of human
intelligence. For example, a person who performs difficult arithmetic calculations quickly and
accurately would be considered as intelligent. But, a computer that could perform the same
calculations faster and with greater accuracy would not be considered as an intelligent.
Human thinking involves complicated interactions within the biological components of the brain,
and that the process of learning is also an important element of human intelligence.
Software applications perform tasks that are sufficiently complex and human-like that the term
Dept. of CSE, RGAN Page|1
Semantic Web and Social Networks IV B.Tech I Sem (R20)
―intelligent‖ may be appropriate. But, Artificial Intelligent (AI) is the science of machines
simulating intelligent behavior. The concept of intelligent application on the World Wide Web takes
the advantages of AI technologies in order to enhance applications and make them to behave in more
intelligent ways.
Here, question arises regarding Web intelligence or intelligent software applications on the World
Wide Web. The World Wide Web can be described as an interconnected network of networks. The
present day Web consists not only of the interconnected networks, servers, and clients, but also the
multimedia hypertext representation of vast quantities of information distributed over an immense
global collection of electronic devices with software services being provided over the Web.
The current Web consists of static data representations that are designed for direct human access and
use.
Over the past decades, human beings have experienced two global revolutionary changes: the
Agricultural Revolution and the Industrial Revolution. Each revolutionary change not onlyenhanced
the access of human resources but also freed the individuals to achieve higher level cultural and
social goals.
In addition, over the past half century, the technological inventions of the Information Age may in
fact be of such scope as to represent a third revolutionary change i.e., the Information Revolution.
The issue that the ―rapidly changing world of the Information Age be considered a global
revolutionary change on the scale of earlier revolutions‖ can be solved by comparing the changes
associated with the Agricultural Revolution with the Industrial Revolution.
Before the agriculture revolution, human beings move to warmer regions in the winter season
and back to colder regions in the summer seasons. Human beings were able to migrate to all locations
on the earth as they have the flexibility of human species and the capability to create adaptable
human cultures.
The adaptable human‘s cultures survived and thrived in every environmental niche on the planet by
fishing, herding and foroging.
Human beings lived to stay permanently in a single location as soon as they discovered the possibility
of cultivating crops. The major implementation of a non migratory life style is that small portion of
land could be exploited intensively for long periods of time. Another implication is the agricultural
communities concentrated the activities into one or two cucle periods associated with growing and
harvesting the crops. This new life style allowed individuals to save their resources and spend on
their other activities. In additions it created a great focus on the primary necessity of planting,
nurturing and harvesting the crops. The individual become very conscious of time. A part from
these, they become reliant on the following:
1. Special skills and knowledge associated with agricultural production.
2. Storage and protection of food supplies.
3. Distribution of products within the community to ensure adequate substenance.
4. Sufficient seed for the near life cycle‘s planning. This life style is different from hunter-
gatherer life styles.
The agricultural revolution slowly moved across villages and regions introducing land cultivation
as well as a new way of life.
During agricultural revolution human and animal muscle were used to produce the energyrequired
to run the economy. As soon as the French revolution came into existence millions of horses and
oxen produced the power required to run the economy.
6. These are just a few examples of how the Semantic Web can be used in the Information Age. As the
Semantic Web continues to develop, we can expect to see even more innovative applications that will
improve our lives in many ways.
The WWW project was initiated by CERN (European laboratory for particle physics) to create a
system to handle distributed resources necessary for Scientific Research. The WWW today is a
distributed client-server service, in which a client using a browser can be access a service using a
server. However, the service provided is distributed over many locations called Websites.
The web consists of many web pages that incorporate text, graphics, sound, animation and other
multimedia components. These web pages are connected to one another by hypertext. In a hypertext
environment the information is stored using the concept of pointers. WWW uses a concept of HTTP
which allows communicate between a web browser and web server. The web page can be created by
using a HTML. This language has some commands while which are used to inform the web browser
about the way of displaying the text, graphics and multimediafiles. HTML also has some commands
through which we can give links to the webpages.
The WWW today is a distributed client-server, in which a client using a web browser can access a
service using a server.
Working of a web:
Web page is a document available on World Wide Web. Web Pages are stored on web server and
can be viewed using a web browser.
WWW works on client- server approach. Following steps explains how the web works:
1. User enters the URL (say, http://www.mrcet.ac.in) of the web page in the address bar ofweb
browser.
2. Then browser requests the Domain Name Server for the IP address corresponding to
www.mrcet.ac.in.
ARPANET
Licklider, a psychologist and computer scientist put out the idea in 1960 of a network of
computers connected together by "wide-band communication lines" through which they could share
data and information storage.
Licklider was hired as the head of computer research by the Defense Advanced Research Projects
Agency (DARPA), and his small idea took off.
The first ARPANET link was made on October 29, 1969, between the University of California and
the Stanford Research Institute. Only two letters were sent before the system crashed, but that was
all the encouragement the computer researchers needed. The ARPANET became a high-speed
digital postoffice as people used it to collaborate on research projects. It was a distributed system of
―many-to-many‖ connections.
Robert Kahn of DARPA and Vinton Cerf of Stanford University worked together on a solution, and
in 1977, the internet protocol suite was used to seamlessly link three different networks.
The mid-1980s marked a boom in the personal computer and superminicomputer industries. The
combination of inexpensive desktop machines and powerful, network-ready servers allowed many
companies to join the Internet for the first time.Corporations began to use the Internet to
communicate with each other and with their customers.
These three events were the introduction of the World Wide Web, the widespread availability of the
graphical browser, and the unleashing of commercialization.
In 1991, World Wide Web was created by Timothy Berners Lee in 1989at
CERN in Geneva. World Wide Web came into existence as a proposal by him, to allow researchers
to work together effectively and efficiently at CERN. Eventually it became World Wide Web.
The following diagram briefly defines evolution of World Wide Web:
The Web combined words, pictures, and sounds on Internet pages and programmers saw the potential
for publishing information in a way that could be as easy as using a word processor, butwith the
richness of multimedia.
Berners-Lee and his collaborators laid the groundwork for the open standardsof theWeb. Their
efforts included the Hypertext Transfer Protocol (HTTP) linking Web documents, the Hypertext
Markup Language (HTML) for formatting Web documents, and the Universal Resource Locator
(URL) system for addressing Web documents.
The primary language for formatting Web pages is HTML. With HTML the author describes what
a page should look like, what types of fonts to use, what color the text should be, where paragraph
marks come, and many more aspects of the document. All HTML documents are created by using
tags.
In 1993, Marc Andreesen and a group of student programmers at NCSA (the National Center for
Supercomputing Applications located on the campus of University of Illinois at Urbana Champaign)
developed a graphical browser for the World Wide Web called Mosaic, which he later reinvented
commercially as Netscape Navigator.
WWW Architecture
WWW architecture is divided into several layers as shown in the following diagram:
DATA INTERCHANGE
Resource Description Framework (RDF) framework helps in defining core representation of
data for web. RDF represents data about resource in graph form.
TAXONOMIES
RDF Schema (RDFS) allows more standardized description of taxonomies
and other ontological constructs.
ONTOLOGIES
Web Ontology Language (OWL) offers more constructs over RDFS. It comes in following
three versions:
• OWL Lite for taxonomies and simple constraints.
• OWL DL for full description logic support.
• OWL for more syntactic freedom of RDF
RULES
RIF and SWRL offers rules beyond the constructs that are available from
RDFs and OWL. Simple Protocol and RDF Query Language (SPARQL) is SQL like language
used for querying RDF data and OWL Ontologies.
CRYPTOGRAPHY
Cryptography means such as digital signature for verification of the origin of sources is used.
2. The web today donot have the ability of machine understanding and processing of web- based
information.
3. The web is characterized by textual data augmented web services as it involves human assistance
and relies on the intevoperation and inefficient exchange of the two competing propritery server
frameworks.
5. The web todau is limited to manual keyboard searches as HTML do not have the abilityto exploit
by information retrieval techniques.
Semantic Web agents could utilize metadata, ontologies, and logic to carry out its tasks. Agents are
pieces of software that work autonomously and proactively on the Web to perform certain tasks. In
most cases, agents will simply collect and organize information. Agents on the Semantic Web will
receive some tasks to perform and seek information from Web resources, while communicating with
other Web agents, in order to fulfill its task.
ARTIFICIAL INTELLIGENCE
Artificial intelligence (AI) is the intelligence of machines and the branch of computer science that
aims to create it. AI textbooks define the field as
"the study and design of intelligent agents" where an intelligent agent is a system that perceives
its environment and takes actions that maximize its chances of success. John McCarthy, who
coined the term in 1955, defines it as "the science and engineering of making intelligent
machines."
Intelligent agent:
Programs, used extensively on the Web, that perform tasks such as retrieving and delivering
information and automating repetition More than 50 companies are currently developing
intelligent agent software or services, including Firefly and WiseWire.
Agents are designed to make computing easier. Currently they are used as Web browsers, news
retrieval mechanisms, and shopping assistants. By specifying certain parameters, agents will
"search" the Internet and return the results directly back to your PC.
Branches of AI
Here's a list, but some branches are surely missing, because no-one has identified them yet.
Logical AI
What a program knows about the world in general the facts of the specific situation in which it must
act, and its goals are all represented by sentences of some mathematical logical language.
Dept. of CSE, RGAN Page|10
Semantic Web and Social Networks IV B.Tech I Sem (R20)
The program decides what to do by inferring that certain actions are appropriate for achieving its
goals.
Search
AI programs often examine large numbers of possibilities, e.g. moves in a chess game orinferences
by a theorem proving program. Discoveries are continually made about how to do this more
efficiently in various domains.
Pattern recognition
When a program makes observations of some kind, it is often programmed to compare what it sees
with a pattern. For example, a vision program may try to match a pattern of eyes and a nose in a
scene in order to find a face.
Representation
Facts about the world have to be represented in some way. Usually languages of mathematical
logic are used.
Inference
From some facts, others can be inferred. Mathematical logical deduction is adequate for some
purposes, but new methods of non-monotonic inference have been added to logic since the
1970s. The simplest kind of non-monotonic reasoning is default reasoning in which a conclusion is
to be inferred by default, but the conclusion can be withdrawn if there is evidence to the contrary
Common sense knowledge and reasoning
This is the area in which AI is farthest from human-level, in spite of the fact that it has been an active
research area since the 1950s. While there has been considerable progress, e.g. in developing systems
of non-monotonic reasoning and theories of action, yet more new ideas are needed.
Learning from experience
Programs do that. Programs can only learn what facts or behaviors their formalisms can represent,
and unfortunately learning systems are almost all based on very limited abilities to represent
information.
Planning
Planning programs start with general facts about the world (especially facts about the effects of
actions), facts about the particular situation and a statement of a goal. From these, they generatea
strategy for achieving the goal. In the most common cases, the strategy is just a sequence of actions.
Epistemology
This is a study of the kinds of knowledge that are required for solving problems in the world.
Ontology
Ontology is the study of the kinds of things that exist. In AI, the programs and sentences deal with
various kinds of objects, and we study what these kinds are and what their basic properties are.
Emphasis on ontology begins in the 1990s.
Genetic programming
Genetic programming is a technique for getting programs to solve a task by mating random Lisp
programs and selecting fittest in millions of generations.
Applications of AI
Game playing
You can buy machines that can play master level chess for a few hundred dollars. There is some AI
in them, but they play well against people mainly through brute force computation--looking at
hundreds of thousands of positions. To beat a world champion by brute force and known reliable
heuristics requires being able to look at 200 million positions per second.
Speech recognition
In the 1990s, computer speech recognition reached a practical level for limited purposes. Thus United
Airlines has replaced its keyboard tree for flight information by a system using speech recognition
of flight numbers and city names. It is quite convenient. On the the other hand, whileit is possible to
instruct some computers using speech, most users have gone back to thekeyboard and the mouse as
still more convenient.
Understanding natural language
Just getting a sequence of words into a computer is not enough. Parsing sentences is not enough
either. The computer has to be provided with an understanding of the domain the text is about, and
this is presently possible only for very limited domains.
Computer vision
The world is composed of three-dimensional objects, but the inputs to the human eye and computers'
TV cameras are two dimensional. Some useful programs can work solely in two dimensions, but full
computer vision requires partial three-dimensional information that is not just a set of two-
dimensional views. At present there are only limited ways of representing three- dimensional
information directly, and they are not as good as what humans evidently use.
Expert systems
A "knowledge engineer'' interviews experts in a certain domain and tries to embody theirknowledge
in a computer program for carrying out some task. How well this works depends on whether the
intellectual mechanisms required for the task are within the present state of AI. When this turned
out not to be so, there were many disappointing results.
One of the first expert systems was MYCIN in 1974, which diagnosed bacterial infections of the
blood and suggested treatments. It did better than medical students or practicing doctors, provided
its limitations were observed. Namely, its ontology included bacteria, symptoms, and treatments and
did not include patients, doctors, hospitals, death, recovery, and events occurring in time. Its
interactions depended on a single patient being considered. Since the experts consulted by the
knowledge engineers knew about patients, doctors, death, recovery, etc., it is clear that the
knowledge engineers forced what the experts told them into a predetermined framework. In the
present state of AI, this has to be true. The usefulness of current expert systems depends on their
users having common sense.
Heuristic classification
One of the most feasible kinds of expert system given the present knowledge of AI is to put some
information in one of a fixed set of categories using several sources of information. An example is
advising whether to accept a proposed credit card purchase. Information is available about the owner
of the credit card, his record of payment and also about the item he is buying and about the
establishment from which he is buying it (e.g., about whether there have been previous credit card
frauds at this establishment).
ONTOLOGY
Ontologies are considered one of the pillars of the Semantic Web, although they do not have a
universally accepted definition. A (Semantic Web) vocabulary can be considered as a special form
of (usually light-weight) ontology.
“Ontology is a formal specification of a shared conceptualization”
In the context of computer & information sciences, ontology defines a set of representational
primitives with which to model a domain of knowledge or discourse. The representational
primitives are typically classes (or sets), attributes (or properties), and relationships (or relations
among class members).
The definitions of the representational primitives include information about their meaning and
constraints on their logically consistent application. In the context of database systems, ontology can
be viewed as a level of abstraction of data models, analogous to hierarchical and relational models,
but intended for modeling knowledge about individuals, their attributes, and their relationships to
other individuals.
Ontologies are typically specified in languages that allow abstraction away from data structures and
implementation strategies;
In practice, the languages of ontologies are closer in expressive power to first-order logic than
languages used to model databases. For this reason, ontologies are said to be at the ―semantic‖
level, whereas database schema are models of data at the ―logical‖ or ―physical‖ level. Due to
their independence from lower level data models, ontologies are used for integrating heterogeneous
databases, enabling interoperability among disparate systems, and specifying interfaces to
independent, knowledge-based services.
In the technology stack of the Semantic Web standards, ontologies are called out as an explicit layer.
There are now standard languages and a variety of commercial and open source tools for creating
and working with ontologies.
• Ontology defines (specifies) the concepts, relationships, and other distinctions that are relevant for
modeling a domain.
• The specification takes the form of the definitions of representational vocabulary (classes, relations,
and so forth), which provide meanings for the vocabulary and formal constraints on its coherent use.
KEY APPLICATIONS
Ontologies are part of the W3C standards stack for the Semantic Web, in which they are used to
specify standard conceptual vocabularies in which to exchange data among systems, provide
services for answering queries, publish reusable knowledge bases, and offer services to facilitate
interoperability across multiple, heterogeneous systems and databases.
The key role of ontologies with respect to database systems is to specify a data modeling
representation at a level of abstraction above specific database designs (logical or physical), so
that data can be exported, translated, queried, and unified across independently developed systems
and services. Successful applications to date include database interoperability, cross database
search, and the integration of web services.
INFERENCE ENGINE
Inference means A conclusion reached on the basis of evidence and reasoning.
In computer science, and specifically the branches of knowledge engineering and
artificial intelligence, an inference engine is a “computer program that tries to
derive answers from a knowledge base”. It is the "brain" that expert systems
use to reason about the information in the knowledge base for the ultimate
purpose of formulating new conclusions. Inference engines are considered to be a special
case of reasoning engines, which can use more general methods of reasoning.
Architecture
The separation of inference engines as a distinct software component stems from the typical
production system architecture. This architecture relies on a data store,
1. An interpreter. The interpreter executes the chosen agenda items by applying the
corresponding base rules.
2. A scheduler. The scheduler maintains control over the agenda by estimating the effects of
applying inference rules in light of item priorities or other criteria on the agenda.
3. A consistency enforcer. The consistency enforcer attempts to maintain a consistent
representation of the emerging solution.
Logic:
In logic, a rule of inference, inference rule, or transformation rule is the act of drawing a
conclusion based on the form of premises interpreted as a function which takes premises,analyses
their syntax, and returns a conclusion (or conclusions). For example, the rule of inference modus
ponens takes two premises, one in the form of "If p then q" and another in the form of "p" and returns
the conclusion "q". Popular rules of inference include modus ponens, modus tollens from
propositional logic and contraposition.
Expert System
In artificial intelligence, an expert system is a computer system that emulates the decision-
making ability of a human expert. Expert systems are designed to solve complex problems by
reasoning about knowledge, like an expert, and not by following the procedure of a developer as is
the case in conventional programming.
• An inference engine is a key component of an expert system or a rule-based system that processes
information and draws conclusions based on a set of predefined rules and knowledge. It's responsible for
making deductions, predictions, and decisions by applying logical reasoning to the available data. Here's
a simplified architecture of an inference engine along with an example:
Inference Engine Architecture:
Knowledge Base: This is where all the relevant information and rules are stored. It includes both factual
knowledge and rules that dictate how the system should draw conclusions.
Working Memory: This is a temporary storage area that holds the current state of the system, including
the facts and data relevant to the current inference process.
Rule Engine: The rule engine is responsible for evaluating the rules against the data in the working
memory. It selects applicable rules based on the current state and activates them for further processing.
Matcher: The matcher component matches the conditions specified in the activated rules against the facts
in the working memory.
Inference Mechanism: Once the matching is done, the inference mechanism determines which rules to
fire (execute) based on the matched conditions. This process might involve chaining rules, backward
reasoning, forward chaining, or other strategies.
Dept. of CSE, RGAN Page|14
Semantic Web and Social Networks IV B.Tech I Sem (R20)
Aggregator: If multiple rules fire and produce conflicting conclusions, the aggregator resolves the
conflicts and determines the final conclusion.
Response Generator: The response generator produces the output or actions based on the conclusions
drawn by the inference engine. It could be generating a diagnosis, providing recommendations, or
initiating specific actions.
Example of an Inference Engine: Medical Diagnosis System
Let's consider a simplified example of a medical diagnosis system that uses an inference
engine to determine potential illnesses based on symptoms.
1.Knowledge Base:
Rules for symptoms and illnesses (e.g., If fever AND cough, then possible diagnosis: flu)
Facts about the patient's symptoms (e.g., fever: present, cough: present)
2.Working Memory:
Current symptoms and patient data
3.Rule Engine:
Selects rules that are relevant to the patient's symptoms (e.g., fever AND cough rule)
4.Matcher:
Checks if the patient's symptoms match the conditions specified in the rule
5.Inference Mechanism:
Determines that the patient's symptoms match the "fever AND cough" rule
Fires the rule and concludes that the patient might have the flu
6.Aggregator:
No conflicts in this example, so no aggregation needed
7.Response Generator:
Generates an output saying, "Based on the symptoms, the patient might have the flu.
Further tests are recommended."
In this scenario, the inference engine processed the patient's symptoms using the rules in
the knowledge base to arrive at a potential diagnosis. This is a simplified example, but it
demonstrates the basic architecture and functioning of an inference engine in an expert
system.
SOFTWARE AGENT
In computer science, a software agent is a software program that acts for a user or other
program in a relationship of agency, which derives from the Latin agere (to do): an agreement to
act on one's behalf.
The basic attributes of a software agent are that
• Agents are not strictly invoked for a task, but activate themselves,
• Agents may reside in wait status on a host, perceiving context,
• Agents may get to run status on a host upon starting conditions,
• Agents do not require interaction of user,
• Agents may invoke other tasks including communication.
Examples:In the context of software agents, there are four key dimensions that help define their
characteristics: persistence, autonomy, social ability, and reactivity. Let's explore each of these
dimensions with examples:
Persistence: Persistence refers to the ability of an agent to continue its operation over time, even when
its environment or user interactions change. Persistent agents are capable of retaining information and
adapting to evolving circumstances.
Example: Email Filters
Agent: An email filter software.
Persistence: The email filter continuously monitors incoming emails and learns from the user's
interactions. It adapts its filtering rules over time to classify emails as spam or legitimate based on the
user's preferences.
Autonomy: Autonomy characterizes the level of independence and decision-making capability of an
agent. An autonomous agent can make decisions and take actions without constant human intervention.
Example: Autonomous Lawn Mower
Agent: An autonomous lawn mower robot.
Autonomy: The robot navigates the lawn, detects obstacles, and determines its mowing path without
human intervention. It can adjust its route to avoid obstacles and return to its charging station when its
battery is low.
Social Ability: Social ability pertains to an agent's capability to interact and communicate effectively
with other agents or human users. Socially able agents can understand and use communication
conventions for collaboration.
Example: Multiplayer Game AI
Agent: An AI-controlled character in a multiplayer video game.
Social Ability: The AI character interacts with both human players and other AI characters. It responds
to player actions, communicates within the game world, and cooperates or competes with other players
and AI agents.
Reactivity: Reactivity refers to an agent's responsiveness to changes in its environment or user inputs.
Reactive agents can perceive changes and act promptly based on the available information.
Example: Traffic Management System
Agent: A traffic management software controlling traffic signals.
Reactivity: The system continuously monitors traffic conditions through sensors and cameras. It adjusts
traffic signal timings in real-time based on traffic flow to optimize traffic movement and minimize
congestion.
These dimensions collectively contribute to the overall behavior and functionality of software agents.
Agents with a combination of these characteristics can perform a wide range of tasks, from basic data
processing to complex decision-making in dynamic environments.
Phase 1: Create a shared vocabulary of terms and concepts. This can be done by identifying the key
concepts that are relevant to the domain of the semantic web application, and then defining each concept
in a way that is clear and unambiguous.
Phase 2: Create a set of ontologies that define the relationships between the concepts in the shared
vocabulary. Ontologies are formal representations of knowledge, and they can be used to represent the
meaning of data in a way that is machine-readable.
Phase 3: Annotate the data with the ontologies. This means adding semantic tags to the data so that it
can be interpreted by machines.
This is just a simple example of a semantic roadmap, and the specific steps involved will vary
depending on the specific application. However, this roadmap provides a general overview of the
process of building a semantic web application.
A semantic roadmap for a healthcare application might include the following phases:
1. Identify the key concepts in healthcare, such as patient, doctor, and medication.
2. Define each concept in a way that is clear and unambiguous.
3. Create ontologies that define the relationships between the concepts.
4. Annotate healthcare data with the ontologies.
Develop tools and applications that can use the semantic healthcare data to make recommendations,
provide patient care, or manage clinical trials.
A semantic roadmap for a retail application might include the following phases:
1. Identify the key concepts in retail, such as product, customer, and order.
2. Define each concept in a way that is clear and unambiguous.
3. Create ontologies that define the relationships between the concepts.
4. Annotate retail data with the ontologies.
Develop tools and applications that can use the semantic retail data to make recommendations,
personalize marketing campaigns, or optimize inventory management.
In other words, the Semantic Web cannot find answers, it cannot even check that an answer is
correct, but it can follow a simple explanation that an answer is correct. The Semantic Web as
a source of data would permit many kinds of automated reasoning systems to function,
but itwould not be a reasoning system itself.
The objective of the Semantic Web therefore, is to provide a framework that expresses both
data and rules for reasoning for Web-based knowledge representation. Adding logic to
the Web means using rules to make inferences, choose courses of action, and answering
questions. A combination of mathematical and engineering issues complicates this task. The
logic must be powerful enough to describe complex properties of objects, but not so powerful
that agents canbe tricked by being asked to consider a paradox.
Logic is used in the Semantic Web to represent the meaning of data and to reason about that data.
One way to think about logic on the Semantic Web is as a way of creating a "contract" between the
data and the user. The data is represented in a way that is machine-readable, and the logic provides
the rules for how that data can be interpreted.
Here is an example of a logical statement that could be used on the Semantic Web:
The rdf:type predicate is used to indicate that the subject of the statement (in this case, <dog>) is of
the type of the object of the statement (in this case, <mammal>).
This statement can be used to reason about other statements about dogs. For example, we could
infer that the following statement is also true:
This is because the first statement tells us that all dogs are mammals, and the second statement
simply says that some mammals exist.
Logic can be used to represent a wide variety of concepts on the Semantic Web, including
relationships between entities, properties of entities, and rules about how entities can be used. It is a
powerful tool that can be used to make the web more meaningful and easier to use.
Here are some other examples of logical statements that could be used on the Semantic Web:
These statements can be used to build more complex knowledge graphs that can be used for a
variety of purposes, such as making recommendations, providing customer support, or automating
business processes.
The logic of the SemanticWeb is proceeding in a step-by-step approach building one layer on
topof another. Three important technologies for developing the Semantic Web are,
1) Resource Description Framework 2) Ontology 3) Web Ontology Language
Ex:
<book> rdf:type <physicalObject> ;
dc:title "The Lord of the Rings" ;
dc:creator <author> .
This statement says that the resource with the URI <book> is of the type <physicalObject>, has a title of "The Lord
of the Rings", and has a creator with the URI <author>.
Dublin Core is a set of metadata terms that are used to describe resources, such as books, articles,
websites, and images
The rdf:type predicate is used to indicate the type of the resource. In this case, the resource is of the type
<physicalObject>, which is a generic type for physical objects.
The dc:title predicate is used to indicate the title of the resource. In this case, the title of the resource is "The Lord of
the Rings".
The dc:creator predicate is used to indicate the creator of the resource. In this case, the creator of the resource is the
resource with the URI <author>.
This is just a simple example of an RDF statement, and the specific syntax will vary depending on the RDF serialization format
being used. However, this example should give you a basic understanding of how RDF statements are structured.
This statement says that the resource with the URI <person> is of the type <mortal> and knows the resource with the URI
<friend>.
The specific URI that is used will depend on the specific application that is using the ontology.
This statement says that the resource with the URI <product> is of the type <merchandise> and has a price of 100.
This statement says that the resource with the URI <organization> is of the type <legalEntity> and has a member
with the URI <employee>.
• Ex2
In OWL, rdf:type is a property that is used to specify the type of an individual. The rdf:type property
has two arguments: the subject of the property is the individual, and the object of the property is the
class that the individual belongs to.
For example, the following RDF triple specifies that the individual <person> is an instance of the
class Human:
<person> rdf:type Human.
The rdf:type property is a fundamental property in OWL. It is used to define the structure of an
ontology and to reason about the relationships between different classes and individuals.
This triple specifies that the individual <John> is an instance of the class foaf:Person. The foaf:Person
class is defined in the Friend of a Friend (FOAF) vocabulary, which is a vocabulary for describing
people and their relationships.
In this example, the rdf:type property is used to state that the individual <John> is a person. This
information can be used to reason about the relationships between <John> and other people, such as
<Mary>, who is also a person.
Here is another example of an RDF triple that uses the rdf:type property:
This triple specifies that the individual <book1> is an instance of the class
dcterms:BibliographicResource. The dcterms:BibliographicResource class is defined in the Dublin
Core Metadata Terms vocabulary, which is a vocabulary for describing bibliographic resources.
In this example, the rdf:type property is used to state that the individual <book1> is a bibliographic
resource. This information can be used to reason about the relationships between <book1> and other
bibliographic resources, such as <book2>.
2. Ontology
Ontology is an agreement between software agents that exchange information. Thus, the required
information is obtained by such an agreement in order to interpret the structure as well as
understand the exchanged data and a vocabulary that is used in the exchanges.
Using ontology, agents can exchange new information can be inferred by applying and extending
the logical rules present in the ontology.
An ontology that is complex enough to the useful for complex exchanges of information will
suffer from the possibility of logical inconsistencies. This is considered as a basic consequence
of the insights of Godel‘s incompleteness theorem.
Ex:
Class: Book
SubClassOf: PhysicalObject
Property: title
Property: author
Property: genre
Class: Person
SubClassOf: LivingThing
Property: name
Property: age
Property: nationality
Class: Library
SubClassOf: Building
Property: hasBook
Property: hasEmployee
Class: Employee
SubClassOf: Person
Property: worksAt
This ontology defines the concepts of Book, Person, Library, and Employee. It also defines the
properties of these concepts, such as the title property of Book and the name property of Person.
This is just a simple example of an ontology, and the specific content will vary depending on the
specific domain of the ontology. However, this example should give you a basic understanding of
how ontologies are structured.
• The Friend of a Friend (FOAF) ontology: This ontology defines concepts related to people and their relationships, such as Person, Friend,
and Workmate.
• The Gene Ontology (GO) ontology: This ontology defines concepts related to genes and their functions, such as Gene, Protein,
and Biological Process.
• The Medical Subject Headings (MeSH) ontology: This ontology defines concepts related to medical topics, such as Disease, Symptom,
and Treatment.
• Class: Person
• SubClassOf: LivingThing
• Property: name
• Property: age
• Property: nationality
• Property: knows
•
• Class: Book
• SubClassOf: PhysicalObject
• Property: title
• Property: author
• Property: genre
• Property: writtenIn
•
• Class: Library
• SubClassOf: Building
• Property: hasBook
• Property: hasEmployee
•
• Class: Employee
• SubClassOf: Person
• Property: worksAt
• This ontology defines the concepts of Person, Book, Library, and Employee. It also defines the properties of these concepts, such
as the knows property of Person and the writtenIn property of Book.
• This ontology can be used to represent the meaning of data on the Semantic Web. For example, we could represent the statement "John knows
Mary" as an RDF statement as follows:
• This statement says that the resource with the URI <John> is of the type <Person> and knows the resource with the URI <Mary>.
• The ontology can also be used to reason about the data. For example, we could infer that Mary also knows John, because the knows property is
symmetric.
OWL is a powerful tool for representing and reasoning about knowledge. It is used in a wide variety
of applications, including:
• Search engines: OWL can be used to represent the semantic meaning of web pages, which can be
used to improve the results of search queries.
• Knowledge management systems: OWL can be used to represent the knowledge of an organization,
which can be used to improve decision making and collaboration.
• Decision support systems: OWL can be used to represent the decision rules of an organization, which
can be used to automate decision making.
• Natural language processing: OWL can be used to represent the knowledge of a language, which can
be used to improve the performance of natural language processing tasks.
• here is a simple example of an OWL ontology for a simple owl domain:
• This ontology defines three classes: Owl, Bird, and hasFeathers. It also defines one object property: hasFeathers. The
hasFeathers property specifies that an owl has feathers.
• The @prefix statements in your example define two namespace prefixes: rdfs and owl. A namespace prefix is a short abbreviation that is
used to refer to a longer URI. In this case, the rdfs prefix is used to refer to the URI http://www.w3.org/2000/01/rdf-
schema#, and the owl prefix is used to refer to the URI http://www.w3.org/2002/07/owl#.
• The rdfs namespace is used for the RDF Schema vocabulary, which is a vocabulary for describing the structure
of RDF data. The owl namespace is used for the Web Ontology Language (OWL), which is a more expressive
language for describing knowledge.
• The @prefix statements are used to make the ontology more readable and concise. By using prefixes, we can
avoid having to write out the full URIs for each term.
• This is just a simple example of an OWL ontology. There are many other ways to represent knowledge in
OWL. The specific way that you choose to represent your knowledge will depend on the specific application
that you are using OWL for.