sparql2al: translating sparql - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · sparql2al:...

113

Upload: trinhbao

Post on 06-Sep-2018

260 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756
Page 2: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

SPARQL2AL: Translating SPARQL

Queries to Arabic Language

Submitted By:

Omar Salah El-Radie 120120756

Supervised By:

Dr. Iyad M. Alagha

A Thesis Submitted as Partial Fulfillment of the Requirements for

the Degree of Master in Information Technology

1436 H – Oct 2015

Islamic University-Gaza

Deanery of Graduate Studies

Faculty of Information Technology

Page 3: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756
Page 4: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

i

Abstract

With the wide spread of Open Linked Data and Semantic Web technologies, a

larger amount of data is published on the Web in the RDF and OWL format. This data

can be queried and retrieved using the Semantic Web Query Language SPARQL.

SPARQL is one of the three core technologies of the Semantic Web beside OWL and

RDF. However, SPARQL cannot be understood by naïve users and it is not directly

accessible to humans, and thus, they will not be able to check whether the retrieved

answers truly correspond to the intended information needed. Because natural

language generation from RDF data has recently become an important topic for

research, this has led to the development of various systems generating natural

language text from knowledge bases.

This work proposes an approach to translate SPARQL to the Arabic language.

It introduces the SPARQL2AL system that can interface to any Arabic ontology, get a

SPARQL query as an input and retrieve valid Arabic statements. While few efforts

proposed approaches to transform SPARQL queries to the natural language, most of

these efforts focused on English domain. To convert SPARQL to Arabic natural

language the SPARQL query passes through several phases; firstly, translations of

query terms are extracted from the ontology, assuming that there exists an ontology of

domain terms on which we run SPARQL queries to retrieve data. Secondly, we define

a set of Arabic language dependencies to identify how query terms are mapped to

Arabic sentences. Thirdly, define a set of rules to transform parts of SPARQL to

Arabic sentences. Finally, we remove redundancies, group the results and output the

Arabic statement.

The proposed system has been tested with a sample ontology and a query set

consisting of 40 SPARQL queries. The accuracy of this system is 0.85

Keywords: Arabic Language Generation, Natural Language Processing, Semantic

Web, SPARQL

Page 5: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

ii

الملخص

مع االنتشار الواسع للـ :نظام ترجمة استعالمات سباركل الى استعالمات اللغة العربية

Open linked Data و تكنولوجيا الويب الداللي، تنشر كمية كبيرة من البيانات على الشبكة

. هذه البيانات يمكن االستعالم عنها و استرجاعها RDFو OWLالعنكبوتية على شكل

تقنياتهي واحدة من ثالث SPARQL(. SPARQLباستخدام لغة استعالمات الويب الداللي )

ال يمكن فهمها SPARQL. بالرغم من ذلك، RDFو OWLاساسية للويب الداللي الى جانب

التعامل معها لعامة الناسو ال يمكن (الغير خبراء في هذا المجال) المبتدئين بواسطة االشخاص

توافق االجوبة المسترجعة للبيانات ودقة بسهولة، و مع ذلك، لن يكون باستطاعتهم فحص صحة

اصبحت مؤخرا موضوع RDFمن بيانات شريةالبالمراد الحصول عليها. و ألن توليد اللغة

، قاد هذا الى تطور انظمة متعددة في توليد نصوص اللغة الطبيعية من قواعدالعلمي مهم للبحث

معروفة. بيانات

ونقدم في الى اللغة العربية. SPARQLهذا العمل يهدف لبدء الخطوة االولى نحو دعم ترجمة

كمدخل و يسترجع جمل query SPARQLم يستخدحيث SPARQL2ALنظام هذا البحث

عربية صحيحة.

للغة الطبيعية، SPARQLجهود حثيثة لتحويل استعالمات وبالرغم من ان هناك العديد من

لمعلوماتنا، لم يبذل أي جهد لبحث تحويل معظم هذه الجهود تتركز على اللغة االنجليزية. طبقا

الى لغة عربية طبيعية SPARQLالى نصوص عربية. لتحويل SPARQLاستعالمات

تمر من خالل مراحل عديدة؛ أوال، يتم تجزئة االستعالم لمجموعة من SPARQL)مفهومة(،

بشروط معينة بحيث يتم تشغيل استعالمات ا االنطولوجيات، على افتراض وجود انطولوجي

SPARQL وعة من التبعيات العربية. ثالثا، تعريف السترجاع البيانات. ثانيا، يتم تعريف مجم

الى جمل عربية. سيكون النظام متاح للتجريب SPARQLمجموعة من القوانين لتحويل اجزاء

من قبل المستخدمين.

وكانت عملية التقييم بناء على اختبار بواسطة نماذج انطولوجية و النظام المقترح تم تجريبه

.0.85دقة النظام هي وكانت نتيجة تعالم مختلف. اس 04مجموعة تجريبية تتكون من

Page 6: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

iii

Dedication

To my Father’s Soul

To my beloved Mother

To my brothers & Sisters…

To my Dear Friends

Page 7: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

iv

Acknowledgements

Thanks and praise to Allah Almighty for guidance and

help to complete this thesis. This thesis would not exist

without the help, advice, inspiration, and encouragement

of many people.

I would like to thank my supervisor Dr. Iyad Alaga for

his time, patience, and understanding. I would also like

to thank him for his advice during the period of study

and his support on the general direction of this thesis and

for the many questions he asked me to verify that I'm still

on the right side.

I would like to thank my teachers in Information

Technology collage.

I am very grateful to my dear Mother without her

encouragement I can't do this work.

Thanks, brothers and sisters for all things you do for me,

your pray, patience, motivation and continues support.

Lastly, but certainly not least, I want to thank my friends,

for their moral support during this study.

Omar S. El-Radie

Sep., 2015

Page 8: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

v

Table of Contents Abstract ......................................................................................................................................................... i

ii ............................................................................................................................................................ الملخص

Table of Figures ......................................................................................................................................... vii

Table of Tables ......................................................................................................................................... viii

List of Abbreviations .................................................................................................................................. ix

Chapter 1: Introduction .............................................................................................................................. 1

1.1 Statement of the problem ...................................................................................................................... 2

1.2 Objectives ............................................................................................................................................... 2

1.2.1 Main objective ..................................................................................................................................... 2

1.2.2 Specific objectives ............................................................................................................................... 2

1.3 Significance of the thesis ....................................................................................................................... 3

1.4 Scope and limitations of the research .................................................................................................. 3

1.5 Research Methodology .......................................................................................................................... 4

1.6 Thesis Structure ..................................................................................................................................... 7

Chapter 2: Background .............................................................................................................................. 8

2.1 Semantic Web ........................................................................................................................................ 8

2.2 RDF and RDFS ...................................................................................................................................... 9

2.3 Ontology ................................................................................................................................................. 9

2.4 OWL ..................................................................................................................................................... 11

2.5 SPARQL ............................................................................................................................................... 11

2.5.1 Introducing the Triple Pattern ........................................................................................................ 12

2.5.2 Structure of a SPARQL Query ....................................................................................................... 14

2.5.4 Return Clauses .................................................................................................................................. 16

2.6 Natural Language Processing (NLP) ................................................................................................. 16

2.7 Natural Language Processing (NLP) in the Arabic language .......................................................... 17

2.7.1 Language Dependencies ................................................................................................................... 20

2.7.2 NPL toolkit “Arabic Toolkit Service (ATKS): ............................................................................... 22

2.7.2.1 What is Arabic Toolkit Service (ATKS)? .................................................................................... 22

2.7.2.2 Sarf API .......................................................................................................................................... 23

2.8 Summary .............................................................................................................................................. 24

Chapter 3: Related Work ......................................................................................................................... 25

3.1 SPARQL to Natural Language: ......................................................................................................... 25

3.2 Natural Language to SPARQL in English ...................................................................................... 26

3.3 Arabic Natural Language Interfaces to the Semantic Web: ......................................................... 27

Chapter 04: SPARQL2AL System ........................................................................................................... 29

4.1 Overview ............................................................................................................................................... 29

4.2 Knowledge Base (The Ontology) ........................................................................................................ 30

4.3 Query Processing ................................................................................................................................. 35

4.4 Define The Rules: ................................................................................................................................ 41

4.5 Natural Language Processing (NLP) ................................................................................................. 43

4.5 Postprocessing ...................................................................................................................................... 44

Chapter 5: Case Studies ............................................................................................................................ 46

5.1 Overview ............................................................................................................................................... 46

5.2 Tools and Programs ............................................................................................................................ 46

5.3 Subject is a variable: ........................................................................................................................... 47

5.4 Object is variable: ................................................................................................................................ 49

5.5 Query has a UNION clause: ............................................................................................................... 51

5.4 Summary .............................................................................................................................................. 54

Chapter 6: Experimental Results and Evaluation .................................................................................. 55

6.1 Overview ............................................................................................................................................... 55

6.2 Objectives ............................................................................................................................................. 55

Page 9: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

vi

6.3 Preliminary Evaluation ...................................................................................................................... 55

6.4 Results................................................................................................................................................... 59

6.5 Discussion ............................................................................................................................................. 63

6.6 System Limitation: .............................................................................................................................. 66

6.7 Summary .............................................................................................................................................. 67

Chapter 7: Conclusion and Future Work ............................................................................................... 68

References: ................................................................................................................................................. 69

Appendix A: OWL Source Code: ............................................................................................................. 72

Page 10: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

vii

Table of Figures Figure 1.1: General SPARQL2AL Components. ...................................................................................... 4

Figure 1.2: Ontologies Property To Store The Arabic Translation. ....................................................... 4

Figure 2.1: Part of The Hierarchy Of The Ontology and Their Relations. .......................................... 10

Figure 2.2: A Classification of Arabic Words According to the Part of Speech .................................. 19

Figure 2.3: A Graphical Representation Of The Stanford Dependencies For The Sentence .............. 20

Figure 2.4: Types of Dependences ............................................................................................................ 21

Figure 2.5: Arabic SARF example ........................................................................................................... 23

Figure 2.6: Arabic SARF example2 ......................................................................................................... 24

Figure 4.1: General SPARQL2AL Components ..................................................................................... 29

Figure 4.2: Translating SPARQL to Arabic Language (SPARQL2AR) Architecture ........................ 30

Figure 4.3: Pathology Ontology Design ................................................................................................... 31

Figure 4.4: An Excerpt of The Disease Ontology ................................................................................... 32

Figure 4.5: Ontology Classes in Protégé .................................................................................................. 33

Page 11: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

viii

Table of Tables Table 2.1: Arabic SARF ............................................................................................................................ 24

Table 4.1: The Size of The Ontology ........................................................................................................ 31

Table 4.2 Our Ontology Classes ............................................................................................................... 33

Table 4.3: The Object Properties in Our Arabic Ontology ................................................................... 34

Table 4.4: Dependencies Used by SPARQL2NL. The dependencies which are part of our

extension of the stanford dependencies are marked with an asterisk. ......................................... 38

Table 4.5: Arabic Dependences Table ..................................................................................................... 39

Table 6.1: Questions That Were Tested And Built Queries ................................................................... 55

Table 6.2: Depicts The Number of Questions And Their Results ......................................................... 60

Table 6.3: Questions That Were Tested, Built Queries And System Translation Result .................... 60

Page 12: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

ix

List of Abbreviations

SPARQL SPARQL Protocol and RDF Query Language

SW Semantic Web

NL Natural Language

NLP Natural Language Processing

POST Part of Speech Tagging

OWL Web Ontology Language

RDF Resource Description Framework

RDFS Resource Description Framework Schema

URIs Uniform Resource Identifiers

IR Information Retrieval

ATKs Arabic Toolkit Service

XML Extensible Markup Language

DG Dependency Grammar

DoO Dictionary of Ontology

Page 13: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

1

Chapter 1: Introduction

The Semantic Web is the next generation of the current Web, and with the

dramatic growth of the Linked Data Web in the past few years, an increased amount

of RDF data is published as Linked Data[1]. Intuitive ways of accessing this have

become more and more essential as a growing number of applications rely on RDF

data as well as on the W3C standard SPARQL for querying this data[2].The word

semantic as it is implies meaning or understanding. Thus, the fundamental difference

between Semantic Web technologies and other technologies related to data (such as

relational databases or the World Wide Web) is that the Semantic Web is concerned

with the meaning, but not the structure of data.

SPARQL (pronounced as "sparkle") is the query language for the Semantic

Web. Along with RDF and OWL, it is one of three core technologies of the Semantic

Web. SPARQL enables Web applications and agents to query the Web, likewise the

SQL is used to query the database Tables[3].

While SPARQL has proven to be a powerful tool in the hands of experienced

users, it remains difficult to understand for lay users, as SPARQL cannot be

understood by naïve users and it is not directly accessible to humans, and thus, they

will not be able to check whether the retrieved answers truly correspond to the

intended information needed. So, we aim to enable inexperienced users who have

limited experience with the Semantic Web logic to read SPARQL query in a natural

language. We address this drawback by presenting SPARQL2NL, a an approach to

translate SPARQL queries to Arabic and therewith bridge the gap between the query

language understood by semantic data backbend’s, i.e. SPARQL, and that of the end

users.

Arabic is one of the largest members of the Semitic language family and is

spoken by nearly 500 million people worldwide[4]. It is one of the six official UN

languages. Despite its cultural, religious, and political significance, Arabic has

received comparatively little attention in modern computational linguistics. While

many efforts proposed approaches to transform SPARQL queries to natural language

sentences[5], most these efforts focused on the English domain. To our knowledge, no

Page 14: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

2

effort has been done to investigate the transformation of SPARQL queries to Arabic

text.

In this research, we propose an approach to translate SPARQL to Arabic

language. The approach should work with any domain ontology represented in Arabic

language. Our proposed system uses ontology-based reasoning and natural language

processing to represent all information that is necessary for the user to understand the

query. The proposed approach has been tested with a sample ontology and a query set

consisting of 40 different queries. The Performance is measured using Precision,

Recall and accuracy.

1.1 Statement of the problem

Enormous amount of data is published on the Web in the Resource

Description Framework (RDF) and The W3C Web Ontology Language

(OWL) format.

This data can be queried and retrieved using SPARQL.

SPARQL queries cannot be understood by naïve users and it is not

directly accessible to humans.

They will not be able to check whether the retrieved answers truly

correspond to the intended information need.

Also Expert users can use the system to check their query validation

1.2 Objectives

1.2.1 Main objective

The main objective of this research is to propose an approach to generate a

valid Arabic language representation for a SPARQL query.

1.2.2 Specific objectives

Study the current approaches to translate SPARQL to natural

languages, and examine their feasibility to be used for the Arabic

language.

Page 15: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

3

Define the rules of conversion from RDF triples to Arabic sentences.

Define the Arabic dependencies for building relations and valid

sentences from RDF triples.

Develop a system that takes SPARQL queries as input and produces

NL sentences as output.

Evaluate the proposed approach by testing it with different SPARQL

queries.

1.3 Significance of the thesis

1. To our knowledge, this is the first work that supports the translation of

SPARQL to Arabic. To our knowledge, no effort has been done to

investigate the transformation of SPARQL queries to Arabic text.

2. The proposed system aims to enable naïve users who have limited

experience with the Semantic Web logic to read SPARQL query in

natural language. The aim is to present all information that is necessary

for the user to understand the content of the query.

Experienced users can also use the proposed approach to validate SPARQL

queries by converting them to NL and determine if they match the NL representation.

1.4 Scope and limitations of the research

1. The proposed approach will only focus on the translation of SPARQL

queries to Arabic language. Other languages such as English are out of

scope.

2. The approach assumes that Arabic translations of the ontology terms

are provided, either inside the ontology or in a supplementary

dictionary. Due to the lack of Arabic ontologies, we will design a

sample ontology that will contain Arabic translations of all ontology

terms. The sample ontology will be used to test our approach.

Page 16: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

4

3. The proposed approach will work on simple SPARQL queries.

Complex queries that involve filter and optional sections will be

considered in our future work.

4. The approach will be assessed by or based on the understandability of

the output Arabic text. However, it does not guarantee the perfection

and soundness of the Arabic grammatical and structural rules. The

output text is considered to be acceptable if it is easy to understand by

naïve users regardless of any minor grammatical or structural mistakes

in the structure.

1.5 Research Methodology The goal of our approach is to generate a valid natural language representation

of an arbitrary SPARQL query. The approach we use consists of fuor steps to

translate SPARQL queries to Arabic. Our proposed system is based on an Ontology

which models the target domain of knowledge. The core of our system is the approach

we propose to transform SPARQL into Arabic language queries. The proposed system

will be described using flowcharts, algorithms, figures and Tables.

Our system enables users to enter SPARQL queries and the system will return

the translation in Arabic directly to users, depending on the domain of the Arabic

Ontology that is used. We mean by Arabic ontology; an ontology that is built in

Arabic language or that are populated with Arabic translations of English terms. We

can’t use resoning in this system because our gaol is translate SPARQL to Arabic

language not data retreval.

The process of translating SPARQL into Arabic language System

(SPARQL2AL) has four stages; the main stages in order are Query Processing, Rule

Definition, Natrual Processing Language and Translation Retrieval. Each stage

has some inputs, generally taken from an earlier stage, and produces output that is fed

into the next stage. Figure 1.1 shows these stages.

Figure 1.1: General SPARQL2AL Components

SPARQL Query

Query Processing

Define

The RulesNPL Postprocessing

Arabic sentence retrieval

Page 17: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

5

We assume that there exists an ontology of domain terms on which we run

SPARQL queries to retrieve data from. The ontology should include Arabic

translation of each term. We use the rdfs:label property to store the Arabic translation

of each domain term as shown in figure 1.2.

Figure .1 2: ontologies property to store the Arabic translation.

Example 1 :

SELECT ?x WHERE ?x. rdf:type ont:disease . ?x ont:infects ont:organ. ont:organ ont:hasName “Pancreas”.

Step 1: Extract the Arabic translations of all words in the query from the

ontology. As mentioned earlier, we assume that translations are stored using the

rdfs:label property. We also perform stopword removal, stemming and part of speech

tagging on the extracted Arabic words. For example, the output of this step is as the

following:

ont:disease -> مرض

ont:infects -> (جذر يصيب) صيب

ont:organ -> عضو

ont:hasName -> اسم

Pancreas -> بنكرياس

Disease

مرض

infects rdfs:label

rdfs:label

يصيب عضو

rdfs:label

Organ

Diabetes Pancreas

Classes

Individuals infects

rdfs:label

rdfs:label

البنكرياس

السكر

السكر

Page 18: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

6

Then define a set of Arabic language dependencies. A language dependency

defines a relationship between words that occurs frequency in Arabic text. For

example, the dependency

subj(صيب ,مرض) refers to the relationship between a subject and a verb

obj(صيب ,بنكرياس) refers to the relationship between a verb and an object.

nn (مرض ,السكر) :A noun compound modifier is used to modify a head noun by

the means of another noun. For instance nn (مرض ,السكر) stands for مرض السكر.

We aim to define a set of dependencies for Arabic language. Table shows a set

of proposed dependencies that we inspired from the Stanford dependencies.

Step 2: Define a set of rules to transform parts of SPARQL to Arabic

sentences. In the following, we present a sample rule:

Rule: F(s p o) where p is a verb => subj (F(p),F(s))^obj(F(p),F(o))

S, p and o stands for subject, predicate and object respectively. This rule means

that if the predicate is verb, then it is transformed to a natural language by using

a concatenation of subj and obj dependencies.

For example, given the following triple:

<ont:disease > <ont:infects ><ont:organ >

On applying the rule, we get:

F(s p o)=> F(<ontUri: disease > < ont:infects ><ont: organ >)

F(<ontUri: disease > < ont:infects >) ^ F(< ont:infects > <ont:organ>)

يصيب عضو ^ مرض يصيب

مرض يصيب عضو (After removing redundancy)

Step 3: Apply NLP if need it to retrieve valid Arabic query, we will use Arabic

Toolkit Services (ATKs) as main NLP tool.

Step 4: Postprocessing: consists of two processes aggregation and grouping.

Then retrieve the Arabic query.

Page 19: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

7

1.6 Thesis Structure

The thesis consists of seven chapters organized as follows:

Chapter 2: Focuses on the background and theoretical concepts.

Chapter 3: discusses related work.

Chapter 4: Presents the approach to translate SPARQL to Arabic.

Chapter5: discusses case studies of sample SPARQL queries and how they are

converted to NL by applying our approach.

Chapter 6: Is devoted to the experiments, evaluation of the proposed approach and

discussion of the results.

Chapter 7: Concludes the thesis and states of the future work.

Page 20: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

8

Chapter 2: Background

This chapter presents the background and theoretical concepts of translating

SPARQL to Arabic language. The fundamentals of semantic web (SW) and its

technologies are briefly introduced.

2.1 Semantic Web

In 2001 Tim Berners-Lee [7], the inventor of the World Wide Web, outlined

the concept called ‘the semantic web. This was his vision for the next stage in using

networked computers to help people create the meaning. The key point is that

semantics (meaning) of Web content are explicitly represented and processed. This

aim will be achieved by the combination of the following technologies [8]:

Explicit Meta-Data: Web content will carry its meaning “on its sleeve”

through appropriate semantic markup.

Ontologies: They will describe semantic relationships between terms,

and will serve as the foundation for establishing a shared

understanding between applications.

Logical Reasoning: Automated reasoning-enabled tools will make use

of the information provided with meta-data and ontologies.

The Semantic Web is the next generation of the current Web in which

computers can interpret the meaning of the web content because of explicit semantics

provided in markup. The Semantic Web components are deployed in the layers of

Web technologies and specifications. The idea of the Semantic Web is to apply

advanced knowledge technologies in order to fill the knowledge gap between a human

and a machine. This means providing knowledge in the forms that computers can

readily process .This knowledge can either be information which is already described

in the content of the Web pages, but difficult to extract or additional background

knowledge which can help to answer queries in some way. The semantic web is

characterized by a healthy environment of stable, broadly implemented core standard

technologies complemented by a number of continually emerging new standards.

Adopters of semantic web technologies can choose from a wide range of commercial

and open source interoperable tools and systems [7].

Page 21: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

9

2.2 RDF and RDFS

Resource Description Framework (RDF) is a framework for representing

information about resources in a graph form. Since it was primarily intended for

representing metadata about WWW resources, it is built around resources with a

Uniform Resource Identifier (URI). RDF documents are written in XML, the XML

language used by RDF is called RDF/XML. By using XML, RDF information can

easily be exchanged between different types of computers using different kinds of

operating systems and application languages. Information is represented by the triples

subject-predicate-object in RDF. All of the elements of the triple are resources with

the exception of the last element, an object that can be also a literal. The Literal in the

RDF sense is a constant string value such as a string or a number[9]

Many ontologies exist for RDF. They are usually defined using the Web

Ontology Language (OWL) or, in a simpler fashion, using the RDF Schema (RDFS)

system. The RDF Schema is a semantic extension of RDF. It provides mechanisms

for describing groups of related resources and the relationships between these

resources. In RDFS, predefined Web resources are: rdfs: Class, rdfs: Resource, and

rdf: Property which can be used to declare classes, resources, and properties

respectively. These resources are used to determine characteristics of other resources,

such as the domains and ranges of properties[10].

2.3 Ontology

The word “ontology” is used with different meanings in different

communities. The term ontology derives from Greek, with “onto” meaning “being”,

and “logos” usually interpreted as “science”; so that ontology, as traditionally

understood, is the science or study of being[11]. Genesereth and Nilsson defined

Ontology as an explicit specification of a set of objects, concepts, and other entities

which are presumed to exist in some area of interest and the relationships that holding

them. Ontology is a shared conceptualization with a clear hierarchy and a strong

support for logical consequences shown in figure 2.1. It contains a set of specific and

clearly described classes or concepts, property of the concepts, slot, restriction, facet

and a series of instance related to one class, which combines to the knowledge

storage. Class is the core of ontology, which describes the concepts in some domain.

Slot describes the property of the class and the instance[12]. Ontologies are often

Page 22: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

10

equated with taxonomic hierarchies of classes, but class definitions, and the

subsumption relation, but ontologies need not be limited to these forms. Ontologies

are also not limited to conservative definitions, that is, definitions in the traditional

logic sense that only introduce terminology and do not add any knowledge about the

world[13]. To specify the conceptualization, one needs to state axioms that do

constrain the possible interpretations of the defined terms.

Figure 02.1: Part of the Hierarchy of the Ontology and Their Relations [13]

Ontologies play an increasingly important role in knowledge management and

are used as a standard knowledge representation for the Semantic Web. By ontology,

the users can connect with each other using a common understanding of a domain.

This helps in understanding the concepts of the domain and also helps the machine to

interpret the definitions of concepts in the domains as well as the relations between

them[14]. To Access structured data in the form of ontologies training and learning

formal query languages are required (e.g., SeRQL or SPARQL) which poses

significant difficulties for non-expert users. Tools needed for creating, editing and

Page 23: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

11

querying ontologies are widely developed to date. However, an initial barrier for

using these tools is in the required background knowledge of the field [15].

2.4 OWL

The Web Ontology Language (OWL) is as a standard (W3C recommendation) for

expressing ontologies in the Semantic Web[16]. The OWL language facilitates greater

machine-understandability of Web resources than that supported by RDFS by adding

additional constructors for building class and property descriptions (vocabulary) and

new axioms (constraints), along with a formal semantics [10].

2.5 SPARQL

SPARQL (pronounced "sparkle", an acronym for SPARQL Protocol and RDF

Query Language) is the RDF query language, that is a query language for databases,

which is able to retrieve and manipulate data stored in the Resource Description

Framework format [17].

SPARQL is the standardized query language for RDF, the same way as SQL is

the standardized query language for relational databases. There are some similarities

because it shares several keywords such as SELECT, WHERE, etc. It also has new

keywords that you have never seen in a SQL world such as OPTIONAL, FILTER and

others [18].

SPARQL is powerful, flexible, and it allows the use of RDF, with all of its

advantages over traditional databases. However, SPARQL query construction has

been described as “absurdly difficult”, and even experienced users may struggle with

it. For this reason, various methods have been suggested to aid in SPARQL query

generation, including assisted query construction [19].

The W3C standard query language SPARQL let people access a growing

collection of public and private data. Whether this data is a part of a semantic web

project or a combination of data from two relational databases on different platforms,

SPARQL is making it easier to access this data using both open source and

commercial software.

Page 24: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

12

SPARQL is based on RDF graph patterns and subgraph matching: The basic

building block for SPARQL queries is called basic graph pattern (BGP)[20]. A BGP

is a set of triple patterns which are RDF triples that may contain query variables at the

subject, predicate, and object position. More complex query patterns are unions of

pattern, optional patterns, filter expressions, etc. Query results in SPARQL are

defined based on graph pattern matching: Each element of the result is a set of

variable bindings that, basically, represents a matching subgraph in the queried RDF

graph [20].

SPARQL is built upon the concept of a triple pattern, which is written as a

subject, a predicate, and an object, and has to be terminated with a full stop. A

SPARQL triple pattern can include variables: or the entire subject, the predicate, and

the object values in the triple pattern can be a variable[21].

2.5.1 Introducing the Triple Pattern

RDF is built on the triple, a 3-tuple consisting of a subject, a predicate, and an

object. Likewise, SPARQL is built on the triple pattern, which also consists of a

subject, a predicate and an object. In fact the RDF triple is also a SPARQL triple

pattern[22]. In A triple from our data expressed by using the SPARQL triple pattern

syntax looks like this example[23]:

<http://www.daml.org/2003/01/periodictable/PeriodicTable#Na> Table:name

"sodium".

A triple pattern is written as a subject, a predicate, and an object and is

terminated by a full stop. URIs, e.g. for identifying resources, are written inside angle

brackets. Literal strings are denoted with either double or single quotes. While

properties, like a name, can be identified by their URI, it's more common to use

a qname-style syntax to improve readability[24]. Later in the tutorial I'll show you

how to associate a prefix with URI using a mechanism very similar to XML

namespaces.

SPARQL specifies a number of handy abbreviations for writing complex triple

patterns. Both the basic syntax and abbreviations borrow heavily from Turtle, a very

terse RDF serialization alternative to RDF/XML. Turtle can be as a text, rather than

XML format, to express RDF very succinctly. Instead of making an exhaustive of all

Page 25: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

13

of the SPARQL syntax shortcuts here, we'll introduce them throughout the examples

contained in this and later tutorials [25].

The triple pattern mentioned above is fine for demonstrating syntax but isn't

very useful as a query. If we know all the data, there's no need to run a query.

However, unlike a triple, a triple pattern can include variables[26]. Any or all of the

subject, predicate, and object values in the triple pattern may be replaced by a

variable. Variables are used to indicate data items of interest that will be returned by a

query [27]. The next example shows a pattern that uses variables in place of both the

subject and the object:

?element Table:name ?name.

Since a variable (which has in SPARQL an alternative spelling the $ character,

like $element) matches any value, this pattern will match any RDF resource that has

a name property. Each triple that matches the pattern will bind an actual value from

the RDF dataset to each of the variables[25]. For example, there is a binding of this

pattern to our dataset where the element variable is bound

to<http://www.daml.org/2003/01/periodictable/Periodictable#Cl and

the name variable is "chlorine."

In SPARQL all possible bindings are considered, so if a resource has multiple

instances of a given property, then multiple bindings will be found. Which one is a

good thing to remember if you end up with more data than expected in your query

results?

At this point you may wonder if it's legal for a triple pattern to include only

variables. Well, it is:

?subjecut ?predicate ?object.

This pattern matches all triples in an RDF graph.

Triple patterns can also be combined to describe more complex patterns,

known as graph patterns. These will be clearer when if it’s seen within the context of

some sample queries. So let's look at the basic structure of our first SPARQL

query[28].

Page 26: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

14

While SPARQL has proven to be a powerful tool in the hands of experienced

users, it remains difficult to understand for naive users. Many applications offer a

form-based environment for naive users for accessing databases familiar with the

database schema or a structured query language. User interactions are translated into

structured queries and executed. However, as a user, is unlikely to know the

underlying semantic connections among the fields presented in a form, it is often

useful to provide with a textual explanation of the query. To address this drawback

approaches such as question answering [3], keyword search [4] and search by

example [5] aim to hide SPARQL and RDF from the user. Yet, these approaches still

have constructed SPARQL queries to address their data backend, without providing

lay users with a possibility to check whether the retrieved answers indeed correspond

to the intended information needed.

2.5.2 Structure of a SPARQL Query

A SPARQL query comprises, in order [29]:

• Prefix declarations, for abbreviating URIs

• Dataset definition, stating what RDF graph(s) are being queried

• A result clause, identifying what information is to return from the query

• The query pattern, specifying what to query about the underlying dataset

• Query modifiers, slicing, ordering, and otherwise rearranging query results

# prefix declarations

PREFIX foo: <http://example.com/resources/>

# dataset definition

FROM ...

# result clause

SELECT ...

# query pattern

WHERE {

Page 27: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

15

}

# query modifiers

ORDER BY ...

The following SPARQL query has all the major components from SPARQL:

PREFIX foaf: <http://xmlns.com/foaf/0.1/>

SELECT ?name

FROM <http://example.com/dataset.rdf>

WHERE {

?x foaf:name ?name .

}

ORDER BY ?name

Let's look at each component in turn.

The PREFIX keyword describes prefix declarations for abbreviating URIs. Without

the prefix, you would have to use the entire URI in the query

(<http://xmlns.com/foaf/0.1/name>)[27]. Create a prefix by using a string (foaf) to

reference a part of the URI (<http://xmlns.com/foaf/0.1/>). When you use the

abbreviation (foaf:name), it appends the string after the colon (:) to the URI that is

referenced by the prefix string.

The SELECT keyword is the most popular of 4 possible return clauses (more on the

others later). If you've used SQL, SELECT serves quite the same function in

SPARQL, which is simply to return data matching some conditions[30]. In particular,

SELECT queries return data represented in a simple table, where each matching result

is a row, and each column is the value for a specific variable. Using our SPARQL

query above in which we SELECT ?name, the result would be a table with one

column and as many rows as the query has matched. The variable ?x is not returned.

The FROM keyword defines the RDF dataset which is being queried. There is an

optional clause, FROM NAMED, which is used when you want to query a named

graph.

The WHERE clause specifies the query graph pattern to be matched. This is the heart

of the query. A graph pattern, as it was mentioned above, is, in essence, RDF with

variables.

Page 28: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

16

Finally, ORDER BY is one of the several possible solution modifiers, which are used

to rearrange the query results. Other solution modifiers are LIMIT and OFFSET.

2.5.4 Return Clauses

In addition to SELECT, there are three other very important return clauses that you

can use: ASK, DESCRIBE, and CONSTRUCT.

ASK queries check if there is at least one result for a given query pattern. The result is

true or false[31].

DESCRIBE queries returns an RDF graph that describes a resource. The

implementation of this return form is up to each query engine, so you won't see it used

as often as other return clauses[31].

CONSTRUCT queries returns an RDF graph that is created from a template specified

as part of the query itself[31]. That is, a new RDF graph is created by taking the

results of a query pattern and filling in the values of variables that occur in the

construct template. CONSTRUCT is used to transform RDF data (for example into a

different graph structure and with a different vocabulary from the source data).

CONSTRUCT queries are useful if you have RDF data that was automatically

generated and would like to transform it by using well-known vocabularies, or if you

have RDF data with the vocabulary from one ontology but you need to translate it into

another ontology. After SELECT this is the most common type of a query in practice,

and the major reason for agreeing on every aspect of the OWL ontology ahead of time

is not necessary. Translation by using CONSTRUCT is relatively cheap.

2.6 Natural Language Processing (NLP) Natural Language processing is the branch of computer science focused on

developing systems that allow computers to communicate with people using everyday

language, as well as the field of Artificial Intelligence and linguistics, and it is

primarily concerned on interaction between computer and human languages in terms

of theoretical results and practical applications and on information sharing. Now

information is exchanging as it has never been before and sharing information is

Page 29: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

17

becoming the leading theme in the domain of the NLP system [32]. Known as

Computational Linguistics, this also concerns with how computational methods can

benefit in the understanding of human language.

Morphological analysis techniques form the basis of the most natural language

processing systems. Such techniques are very useful for many applications, such as

information retrieval, text categorization, dictionary automation, text compression,

data encryption, automatic translation and computer-aided instruction [33].

Morphological analysis gives the most important information for a part-of speech

tagger to select the most suiTable analysis for a given on text [34].There is a couple of

open source natural language processing software, some of them are OpenNLP,

Stanford parser, MS NPL toolkit etc.

2.7 Natural Language Processing (NLP) in the Arabic language

The Arabic language is currently the sixth most widely spoken language in the

world. It is the mother tongue of about 500 million of peoples. Arabic is an official

language in more than 22 countries. Since it is also the language of the religious

instruction in Islam, much more speakers have at least a passive knowledge of the

language. The direction of writing is from right to left, and the Arabic alphabet

consists of 28 letters. Most Arabic words are morphologically derived from a list of

roots; most of these roots are three constants [35].

The Arabic language differs from other natural languages such as the English

language, it owns features that are not found in other languages. NLP in the Arabic

language is still in its initial stage compared with the work in the English language,

which has already benefited from the extensive research in this area. There are some

aspects that slow down progress in Arabic NLP compared with the accomplishments

in English and European languages [36].These aspects include:

The absence of diacritics in the written text causes ambiguity and therefore,

complex morphological rules are required to identify the tokens and parse in

the text.

The direction of the writing of the script is from right to left and some of the

characters change their shapes based on their location in the word.

Page 30: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

18

Capital letters are not used in Arabic, which makes it hard to identify proper

names, abbreviations, and this creates increased ambiguity and especially

complicates such tasks as Information Extraction in general and Named Entity

Recognition in particular.

The major difference is that Arabic is mainly highly inflectional and

derivational, which makes a morphological analysis a very complex task while

English and other languages are concatenate.

In addition to the above mentioned linguistic issues, there is also a lack of

Arabic corpora, lexicons, and machine-readable dictionaries, which are essential to

advance research in different areas.

The importance of the Arabic language processing tools has dramatically

increased in the last decade because of the huge increment of Arabic digital content

on the internet, and in internet users who speak Arabic. This fact increases the

importance of creating language processing tools that can process this content, and

interact with these users in better ways. A Morphological analysis is an important step

in the Arabic language processing because of the complex morphological structure of

Arabic where we have infixes along with prefixes and suffixes. In addition, each

prefix or suffix may have its own syntactical tag; this means that we have to use the

result of the morphological analysis stage in higher stages of Arabic processing like

POS-tagging, syntactical analysis [37].

The stemming algorithm is a computational process that gathers all words

sharing the same stem and having some semantic relation. The main objective of the

stemming process is to remove all possible affixes and thus reduce the word to its

stem. It is normally used for document matching and classification by using it to

convert all likely forms of the word in the input document to the form in the reference

document [33].

Arabic stemming algorithms can be classified, according to the desired level of

analysis, as either stem-based or root-based algorithms. Stem-based algorithms,

remove prefixes and suffixes from the Arabic words, while root-based algorithms

reduce stems to roots. Light stemming refers to the process of stripping off a small set

of prefixes and/or suffixes without trying to deal with infixes or recognizing patterns

and finding roots [38].

Page 31: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

19

Khoja and Garside[39]developed an effective stemmer depending on simpler

linguistic rules, this approach (1) removes prefixes and suffixes, then (2) matches the

remaining word against the patterns to extract the root, and finally (3) checks whether

the extracted root is a valid root using an Arabic roots dictionary. Khoja stemmer is

considered as a high performance stemmer.

Arabic grammarians traditionally analyze all Arabic words into three main

parts-of-speech. three major part-of-speech[as adjective] categories in the Arabic

language i.e. nouns, verbs and particles (in Arabic, Ism (اسم), Fi’l (فعل ) and Harf (

.respectively) , Figure 2.2 shows the major part of speech categories [28] (حرف

Figure 2.2: A Classification of Arabic Words According to the Part of Speech

A Particle in Arabic is a voice-based segment of excerpts of throat or tongue

or lips. Such as: on, in, of )على ، في ، من(. The Particle class includes: prepositions,

adverbs, conjunctions, and interjections. A Verb is a word that indicates an action or

state connected with the notion of time. The Verb is divided into three Classes: Past

tense )فعل ماضي(, present tense )فعل حاضر(, and ordered tense )قال، :such as , فعل امر()

، قل( يقول . A Noun or ism is a word that indicates the meaning by itself without being

connected with the notion of time, and that describes a person, location, or an idea,

such as (Ali, Maca, and Bird), in Arabic ( علي،مكة،)عصفور [35].

Tokenization is very important in natural language processing. It can be seen

as a preparation stage for all other natural language processing tasks. Tokenization is

the task of separating out words (morphemes) from running text. It (sometimes also

called segmentation) refers to the division of a word into clusters of consecutive

morphemes, one of which typically corresponds to the word stem, usually including

Arabic Word

كلمة عربية

Noun اسم Verb فعل Particle حرف

Page 32: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

20

inflectional morphemes. We can use blanks (white space) to tokenize the

sentence/input sequence on the basis of whitespaces, but there are hard cases. This

definition is for the English language, but in Arabic the situation is different. In

discussion of tokenization, it is important to remember that there is no single optimal

tokenization. What is optimal for IR may not be true for SMT. Also, what is optimal

for a specific SMT implementation may not be the same for another one [40].

2.7.1 Language Dependencies Dependency is a class of modern syntactic theories that are all based on the

dependency relation (as opposed to the constituency relation). Dependency is the

notion that linguistic units, e.g. words, are connected to each other by directed links.

The (finite) verb is taken to be the structural center of clause structure. All other

syntactic units (words) are either directly or indirectly connected to the verb in terms

of the directed links as shown in Figure2.3, which are called dependencies.

Dependency grammar (DG) is distinct from phrase structure grammars

(constituency grammars).

Figure 2.3: A Graphical Representation of the Stanford Dependencies for the Sentence[41]

Dependency is a one-to-one correspondence: for every element (e.g. word or morph)

in the sentence, there is exactly one node in the structure of that sentence that

corresponds to that element. The result of this one-to-one correspondence is that

dependency grammars are word (or morph) grammars. All that exist are the elements

and the dependencies that connect the elements into a structure. This situation should

be compared with the constituency relation of phrase structure grammars. The

Page 33: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

21

Constituency is a one-to-one-or-more correspondence, which means that, for every

element in a sentence, there are one or more nodes in the structure that correspond to

that element. The result of this difference is that dependency structures are minimal

compared to their constituency structure counterparts.

Semantic dependencies:

Semantic dependencies are understood in terms of predicates and their arguments.

The arguments of a predicate are semantically dependent on that predicate. Often,

semantic dependencies overlap with and point in the same direction as syntactic

dependencies. At times, however, semantic dependencies can point in the opposite

direction of syntactic dependencies, or they can be entirely independent of syntactic

dependencies. The hierarchy of words in the following examples in Figure .02 shows

standard syntactic dependencies, whereas the arrows indicate semantic dependencies

Figure 2.4: Types of Dependences [41]

After extract all triple patterns and extract all Arabic labels we need a way to

rearrange retrieved word to make correct and valid statement so the best way to

rearrange the words is to use dependency but we need special dependencies for

Arabic Language so we will create it; some words after extraction we can’t rearrange

directly such as (ال يحمل) we can’t find relation between the words to generate valid

sentence without use dependences neg(يحمل , ال ) so to make relation between this

Page 34: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

22

words we need dependences that’s will be clear in Interpretation of SPARQL queries

to Arabic language steps.

2.7.2 NPL toolkit “Arabic Toolkit Service (ATKS): In our research we will use NPL toolkit “Arabic Toolkit Service (ATKS) as an

NPL tool

2.7.2.1 What is Arabic Toolkit Service (ATKS)?

The Advanced Technology Lab in Cairo has developed the Arabic Toolkit

Service (ATKS) as a set of NLP components targeting Arabic language. The

component suite includes a full-fledged morphological analyzer (Sarf), a spellchecker,

an auto corrector, and discretize, a named entity recognizer (NER), a colloquial to

Arabic converter, and a part-of-speech (POS) tagger. These components have been

integrated into multiple Microsoft products and services, such as Windows, Office,

Bing, Exchange, SharePoint, and Windows Phone. The Arabic Toolkit Service

(ATKS) avails these components in the form of web services and associated APIs

hosted on Windows Azure[42].

But we will use one of most important Arabic NLP technologies in our

research SARF (morphological analyzer)

SARF (morphological analyzer):

Figure 2.2 shows an Arabic SARF example

Page 35: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

23

Figure 2.5: Arabic SARF Example [43]

Morphological analysis

Sarf provides all possible morphological analyses for an input Arabic word.

Each analysis consists of the discretized word and the morphological breakdown of

the analysis in terms of prefixes, stem, and suffixes. The stem is further decomposed

into its root and morphological pattern. Moreover, each analysis carries the part of

speech and a set of morphosyntactic features such as gender and number. The

analyses are ranked to reflect the actual language used of each analysis.

Awareness of input diacritics

Input text diacritics are noted during analysis. Diacritics found in the input

will be used as a filter on the generated analyses, but if the input diacritics are

determined to be wrong, they are ignored.

2.7.2.2 Sarf API

The Sarf API is available through a SOAP interface, which supports client-

application scenarios and a rich .NET client programming model. Developers can use

their development technology of choice with this interface. To add a reference to a

SOAP web service in Visual Studio 2008 and later, right-click on the project and Add

Service Reference to https://atks.microsoft.com/Services/SarfService.svc. This will

generate the proxy code in a SarfServiceClient class in the project. Two examples

Figure 2.6 and Table 2.1 are shown below

Page 36: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

24

Figure 2.6: Arabic SARF example 2 [43]

Table 2.1 are shown below explane the previous example in figure 2.6.

Table 2.1: Arabic SARF [43]

2.8 Summary In this chapter, we have presented a background for this research. We

discussed the semantic web (SW) and its technologies, Ontologies and its

technologies and we defined the ontology and explained the steps that must follow to

build it, RDF, OWL SPARQL, concepts of NLP including tokenization, stemming,

POS and the importance of them in the field of translating SPARQL to NL. We

explained the difference between Arabic NLP and English language. Additionally, we

defined the ontology and explained the steps that must follow to build it.

Page 37: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

25

Chapter 3: Related Work

In this chapter, different related works are studied and investigated. We will

discuss the three sections of the related work; first section focuses on SPARQL to NL

approaches, the second section is about NL to SPARQL and the third section is about

Arabic Semantic Web Applications for question answering, information retrieval and

Ontology construction.

3.1 SPARQL to Natural Language:

A plenty of research has explored SPARQL to Natural Language systems by using

different approaches. The most important approaches are discussed in the following:

1- SPARQL2NL [6]: the authors present an approch that can convert SPARQL

to a natural language in the English language. This approach allows to

verbalize SPARQL queries, convert the queries into the natural language. In

addition to generating verbalizations, it can also explain the output of queries

by providing a natural language description of the reasons that led to each

element of the result set being selected.

2- SPARTIQULATION [43]:The authors described an approach to verbalize

SPARQL queries in order to create natural language expressions that are

readable and understandable by the human user. These expressions are helpful

with having search engines that generate SPARQL queries for user-provided

natural language questions or keywords. Displaying verbalizations of the

generated queries to a user enables him to check whether the right question

has been understood this aprroch depend on Query graph representation, Main

entity identification, Query graph transformation, Message types , and

Document plan. Meanwhile the approach enables verbalization of only a

subset of SPARQL 1.1.

3- Keyword-driven SPARQL-Query Generation [44]: this research is

considered as athe first step towards the user-friendly querying of the Data

Web with using rich semantic structures. authors presented a novel approach

Page 38: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

26

for constructing SPARQL queries based on user-supplied keywords.By

intertwining keyword interpretation and query generation with the available

background knowledge.

All the above approaches explored the translation from SPARQL to

English NL. Our approach is different in terms of translating SPARQL to

Arabic language.

3.2 Natural Language to SPARQL in English

A plenty of research has explored Natural Language to SPARQL systems

using different approaches. Some of these approaches are briefly discussed in the

following.

1- Querix [45]: is an ontology-based question answering system which relies

on clarification dialogs in case of ambiguities. This system contains user

interface, ontology manager, query analyzer, matching center, query

generator, dialog component and ontology access layer.

2- SPARQL Assist Language Neutral Query Composer [46]:is an

interface to the Semantic Web that is capable of learning the user's jargon

in order to improve his experience by the time. Their learning mechanism

is good in a way that it uses ontology reasoning to learn more generic

patterns, which could be reused after for the questions with the similar

context.

3- PANTO [47]: is a Portable natural language interface to Ontologies which

accepts input as a natural language form and the output is in the SPARQL

query. It is based on the triple-based model in which parse tree is

constructed for the data model using the off-the-shelf Standford parser.

The performance of PANTO at the maximum has 88.05% Precision.

Page 39: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

27

4- AquaLog [46]: In this system two major models are used as Linguistic

Component which is used to convert the NL questions into the Query-

triple format and Relation Similarity Service (RSS) which takes the Query

Triple into the Onto-Triple form. The average percentage of successive

answers is 63.5 %.

While all the previous efforts focused on translating NL to SPARQL, our

approach has the opposite goal, which is to translate SPARQL to NL. While

NL to SPARQL approaches are useful for desiging NL interfaces for the

Semantic Web, SPARQL to NL approaches generally have the goal of

enabling both naïve and experienced users to understand and validate

SPARQL queries.

3.3 Arabic Natural Language Interfaces to the Semantic Web:

In this section we will talk about Arabic Semantic Web Apps that includes

question answering, information retrieval and Ontology construction.

1- An Ontology-Based Arabic Question Answering System [48]:The

core of the system is the approach we propose to translate Arabic NL

queries into SPARQL. The approach makes intensive use of the

ontology semantics to translate the user query into RDF triple patterns

and infer any missing components to build up a complete SPARQL

query. The proposed approach can process queries of different

complexities and structures.

2- AQAS[ 53]:is a knowledge-based QA system that extracts answers

only from structured data and not from a raw text (not structured text

written in a natural language);to our knowledge, no evaluation results

have been published for the AQAS system.

3- QARAB [36]: is an Arabic QA system that uses Information Retrieval

(IR) and Natural Language Processing (NLP) techniques. QARAB

firstly treats the incoming question as a “bag of words” against which

the index file is searched to obtain a list of ranked documents that

Page 40: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

28

possibly contain the answer. The QARAB system reached a precision

of 97.3% and also a recall of 97.3%.

4- ArabiQA [50]:is an Arabic QA system that employed the Java

Information Retrieval System, a passage retrieval system to search the

relevant passages. And the (used) Arabic Named Entity Recognition

system called ANERsys is used to identify and classify named entities

within the passages retrieved. The precision is 83.3%.

5- DefArabicQA [51]: is an Arabic Definition Question Answering

System that tackled the definition type of questions. They identified

the candidate definitions, then used heuristic rules, and after they

extracted the candidate definitions, their evaluation was not good

enough as they tested only 50 organization definition questions and the

answers were assessed by only one Arabic speaker.

The previous different approches in this section worked on semantinc fields

for different applications: some of them are for translation NL into SPARQL, other

apps are for information retrieval, but no one research works on translateionof

SPARQL into the Arabic language. So we focus on this field.

3. 4 Summary

In this chapter we presented an overview about the question answering system.

This chapter is divided into three sections. In the first section we focuses only on

SPARQL to NL approaches for the English language, because no research was

covered with the Arabic field. In the second section we discuss a NL to SPARQL

system. Third section is about Arabic Semantic Web Apps that include question

answering, information retrieval and Ontology construction. Researches and

development in the area of SPARQL to the Arabic language needed because no

research was covered with the Arabic field.

Page 41: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

29

Chapter 04: SPARQL2AL System

4.1 Overview

This chapter discusses the design of the prototype we built to translate

SPARQL queries to Arabic. Our proposed system is based on an Ontology which

models the target domain of knowledge. The core of our system is the approach we

propose to transform SPARQL into Arabic language queries. The proposed system

will be described using flowcharts, algorithms, figures and Tables.

Our system enables users to enter SPARQL queries and the system will return

the translation in Arabic directly to users, depending on the domain of the Arabic

Ontology that is used. We mean by Arabic ontology; an ontology that is built in

Arabic language or that are populated with Arabic translations of English terms. We

can’t use resoning in this system because our gaol is translate SPARQL to Arabic

language not data retreval.

The process of translating SPARQL into Arabic language System

(SPARQL2AL) has four stages; the main stages in order are Query Processing, Rule

Definition, Natrual Processing Language and Translation Retrieval. Each stage

has some inputs, generally taken from an earlier stage, and produces output that is fed

into the next stage. Each stage is explained subsequently in a separate section in this

chapter. Figure 4.1 shows these stages, and a detailed flow chart of SPARQL into

Arabic language is shown in Figure 4.2.

Figure 4.1: General SPARQL2AL Components

SPARQL Query

Query Processing

Define

The RulesNPL Postprocessing

Arabic sentence retrieval

Page 42: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

30

Figure 04.2: Translating SPARQL to Arabic Language (SPARQL2AR) Architecture

4.2 Knowledge Base (The Ontology)

Before disscuss the SPARQL2AL Syastem we prepare the Knowledge Base which

consists of the ontology and the RDF store. The proposed translation system is

generic that it should accept any domain ontology represented in Arabic language.

But, due to the lack of mature ontologies that were built using Arabic language, an

Ontology that covers a restricted domain of knowledge from the science of Pathology

was used as showen in appendix A [52]. That ontology has been used ”علم األمراض“

throughout this thesis to discuss the proposed approach.

There are various tools available for developing ontologies like Hozo, DOML,

and AltovaSemantic Works etc. We have used Protégé which is one of the most

widely used ontology development editor that defines ontology concepts (classes),

Page 43: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

31

properties, taxonomies, various restrictions and class instances. It also supports

several ontology representation languages, including OWL [29], where understanding

ontology is an important task in our work and Arabic Ontology Domain .

1) Overview of Ontology

The selected Pathology ontology contains general characteristics that are

represented in OWL. Information about the diseases can be added or deleted easily

without affecting the overall structure of the ontology whether at the level of classes

or properties. So it can be reused by other applications interested in the same domain.

Figure 4.3 shows the overall structure of the selected Ontology.

Figure 4.3: Pathology Ontology Design [48]

The selected ontology contains classes, object and data properties, and instances, the

number of each is depicted in Table 4.1.

Table .4 1: The Size of the Ontology

Domain and Scope of the Ontology Pathology “علم االمراض”

Number of Classes 12

Number of Object Properties 9

Number of Data Properties 1

Number of Instances 149

Page 44: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

32

Figure 4.2 depicts an excerpt of the ontology showing the ontology classes (e.g.

:Cure, :Disease, :Symptom, :Organ) as well as the inter-relationships between (e.g.

object properties).The prefix “ont:” denotes the ontology’s base uri. Arabic

translations of all class and property names are stored using the rdfs:label property

which is not shown in the Figure 4.0 for simplicity. Arabic names are retrieved and

used to SPARQL query, in the ontology content. We stress that the SPARQL2AR

system can be easily configured to use any ontology as long as the Arabic translation

of its content is supplied.

Figure 4.4: An Excerpt of the Disease Ontology

2) Classes and Class Hierarchy of Ontology

The selected ontology classes were studied and modified so they can be

suiTable for our system; such as adding an Arabic translation of each class as a label

when class does not have one, these labels will be shown in the Arabic statements

Page 45: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

33

obtained from the translation. Main classes and their labels are depicted in Table 4.2

below with a brief description.

Table 4.2 Our Ontology Classes

No. Class /Arabic Class /English Description

Disease It is a medical condition associated with المرض 1

specific symptoms and signs

Reason factors cause diseases from an external source المسببات 2

or internal dysfunctions

Symptom It is a departure from normal function or األعراض 3

feeling which is noticed by a patient

Organ It is a collection of tissues joined in a العضو 4

structural unit to serve a common function

Diagnose It is the identification of the nature and cause التشخيص 5

of a certain phenomenon

Cure It is the end of a medical condition; the العالج 6

procedure that ends the medical condition

Figure 4.2 depicts the Ontology Classes.

Figure 4.5: Ontology Classes in Protégé

Page 46: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

34

3) The Properties of Classes

All properties used to link instances of ontology classes are illustrated in Table 4.3.

Table .4 3: The Object Properties in Our Arabic Ontology

No. Object

property/

AR

Object

property /EN

Domain Range

المرض االعراض symptom_of اعراض_ل 1

االعراض المرض has_symptom له_اعراض 2

المسببات المرض caused_by بسبب 3

المرض المسببات causes يسبب 4

المرض العضو infected_by يصاب_ب 5

العضو المرض infects يصيب 6

المرض العالج cures يعالج 7

العالج المرض cured_by ب_يعالج 8

المرض التشخيص diagnoses يشخص 9

التشخيص المرض diagnosed_by ب_يشخص 11

The ontology contains the schema and is often stored in the RDF file. The

RDF store contains the data annotated with the ontology which are in the format of

RDF triples. Note that our system is designed to keep the data separated from the

ontology which should remain intact and reusable then extract the Arabic labels of all

triple parts in the query from the ontology contents. As mentioned earlier in the

system components, we assume that translations are stored using the rdfs:label

property. All the contents of the ontology and the RDF store are retrieved,

preprocessed and stored in the Dictionary of Ontology (DoO). DoO is a data structure

that stores all the ontology content in memory. It is used to enable fast access to

ontology content without having to read from the ontology file.

Page 47: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

35

4.3 Query Processing

The goal of the Query Processing step is to generate easily legible natural

language representations of SPARQL queries. Query processing is carried out in three

steps: Identification of variable types, normalization and identification of Arabic

Dependencies.

In the following we will discuss the query processing sections:

1- Identification of variable types

A SPARQL query contains one or more variables. These variables often refer

to the target words that follow the question words in the natural language queries. The

first step of the translation process is to interpret these variables by identifying their

datatypes. For example, the query: “SELECT ?x WHERE ?x :cures :Diabetes” has

one variable, i.e. x, which refers to a medication or a cure. After identifying the

datatype of the variable x, the Arabic question can be constructed as the following: “ ما

is the data type of the variable x in the SPARQL "عالج" where the word ”هو عالج ...

query.

To identify the data types of SPARQL variables, the following steps are

followed:

1- We extract all triple patterns that match: ?x rdf:type C, where C is an

ontology class. The class C represents the type of the variable ?x. We also

process the query to find if the query has a UNION, OPTIONAL, FILTER

and LIMIT. If none of the statements are part of a UNION statement, we

assign the conjunction (AND) of all C to ?x. Otherwise, we assign the

disjunction (OR) to ?x of all C such that the UNION statements contain no

other statements.

2- A SPARQL query may not contain the pattern: ?x rdf:type C. In this case,

we refer to the ontology semantics to identify the type of the variables. For

example, the query “SELECT ?x WHERE {?x :infects :Liver}” does not

contain the pattern: ?x rdf:type C. However, the type of ?x can be

determined by inspecting the domain property :infects which ?x is linked

to. By referring to the ontology, we find that the property :infects has the

domain :Disease. Therefore, the class:Disease will be chosen as the data

Page 48: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

36

type of ?x since ?x belongs to the domain of :infects. Therefore, the Arabic

question will start with: “... ما هو المرض” where "المرض" is the Arabic

translation of the class :Disease.

The following examples illustrates how the above procedure is applied:

In example 1, we need to determine the type of the variable ?var so that we

can identify the question targets. The query in this example does not contain the

triple: ?var rdf:type C. Therefore, we apply the second step of the above approach,

which is to analyze the property :infects. Since the variable ?var denotes the subject of

the property :infects, we determine all ontology classes that belong to the domain of

the property. This will result in the class :Disease. Therefore, the type of the ?var is

identified as :Disease. We then extract the Arabic translation of the :Disease class, i.e.

is (المرض) which is supposed to be stored in the ontology. The Arabic word ,المرض

then used to constructed the sentence: ما هو المرض ...؟.

Notice that the domain of the property :infects may contain one or more classes. In

this case, we determine the types of other occurrences of the variable ?var in other

triples, and choose the most common type. For example, in the query: “SELECT ?var

WHERE { ?var :hasCategory “Viral_Infection” . :Antibiotic :cures ?var }”. The

property :hasCategory has multiple classes in its domain such as :Cure and :Disease.

Therefore, it is not sufficient to determine the type of ?var. In this case, we refer to

the other triple (:Antibiotic :cures ?var) to determine the type of ?var in it. The

property :cures has the class :Disease in its range. The class :Disease is the common

class between the two triples. Thus, it is selected to denote the type of the variable

?var.

2- Normalization

One SPARQL feature that often leads to queries that are difficult to

understand the UNION statements. Text normalization is the process by which a text

is transformed in some ways to make it consistent to ensure that we generate easily

PREFIX Ont: <http://www.iugaza.edu.ps/ar2sparql#>

SELECT ?var WHERE {?var Ont:infects Ont:Pancrias}

Example1: Simple SPARQL query

Page 49: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

37

legible natural language representations of SPARQL queries. The input queries are

normalized by transforming any disjunctions (i.e. UNION statements) into two

queries, translating each query and joining them by disjunctions (OR) then retrieving

complete Arabic Translated statement.

In the following we show a general example of normalizing a sample query:

SELECT ?d WHERE { ?d ont:infects ont:pancreas. {?d ont:caused_by ont:Lack_of_insulin} UNION {?d ont:has_symptom ont:thirst} }

After finding the type of the variable ?d, which is :Disease, , the query returns

the UNION of two graph patterns. The first pattern is: Ont:Disease :caused_by

:Lack_of_insulin, and the second pattern is Ont:Disease :has:symptom ont:thirst. Each

triple pattern is translated separately and then (OR) is added between them. The

translation result is: العطش هما المرض الذي يصيب البنكرياس ويسببه نقص االنسولين أو يسبب .

Afterwards, redundancy is resolved by omitting the second occurrence of the verb

ما المرض الذي :so that the query becomes better readable. This results in the query ”يسببه“

يصيب البنكرياس ويسببه نقص االنسولين أو العطش؟

3- Identification of Arabic Dependencies

A language dependency defines a relationship between words that occur

frequently in Arabic text. For example, the dependency

subj(يصيب ,مرض) refers to the relationship between a subject and a verb

obj(يصيب ,بنكرياس) refers to the relationship between a verb and an object.

nn (مرض ,السكر) :A noun compound modifier is used to modify a head noun by

the means of another noun. For instance nn (مرض ,السكر) stands forمرض السكر.

After extracting all triple patterns and all Arabic labels, we need a way to rearrange

retrieved words to make correct and valid statement. Words can be linked by referring

language dependencies which define rules for linking words to produce valid and

correct clauses.

Researches in English domain have often relied on well-known dependencies such

as Stanford language dependencies. However, English dependencies cannot be

directly used for Arabic language which uses different structures. Therefore, we

Page 50: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

38

adapted Stanford dependencies for Arabic language. Table 4.4 shows the original

Stanford dependencies which Table 4.5 shows the Arabic language dependencies

we devised.

Table 4.4: Dependencies used by SPARQL2NL. The Dependencies Which Are Part Of Our Extension of the Stanford Dependencies Are Marked With An Asterisk[6].

Dependency Explanation

Amod Represents the adjectival modifier dependency. For example amod (ROSE,

WHITE) stands for white rose.

Cc Stands for the relation between a conjunct and a given conjunction (in most

cases and or or). For example, in the sentence John eats an apple and a pear,

cc(PEAR, AND)holds. We mainly use this construct to specify reduction and

replacement rules.

Conj* Used to build the conjunction of two phrase elements, e.g. conj(subj(EAT,

JOHN),subj(DRINK, MARY)) stands for John eats and Mary drinks. Conj is

not to be confused with the logical conjunction ^, which we use to state that

two dependencies hold in the same sentence.

example subj(EAT, JOHN) ^ obj(EAT, FISH) is to be read as John eats fish.

Disj*

Used to build the disjunction of two phrase elements, similarly to conj.

Obj Dependency between a verb and its direct object, for example obj(EAT,

APPLE) expresses to eat an/the apple.

Nn The noun compound modifier is used to modify a head noun by the means of

another noun. For instance nn(FARMER,JOHN) stands for farmer John.

Poss Expresses a possessive dependency between two lexical items, for example

poss(JOHN, DOG) express John's dog.

prep_X Stands for the preposition X, where X can be any preposition, such as via, of,

in and between.

prepc_X Clausal modifier, used to modify a verb or noun phrases by a clause

introduced by some preposition X, e.g. prep such as(PEOPLE, c) represents

people such that c, where c is some clause, e.g. their year of birth is 1950.

Root Marks the root of a sentence, e.g. the verb. For example ROOT(EAT) ^

subj(EAT, JOHN) means John eats. The root of the sentence will not always

be stated explicitly in our formalization.

Subj Relation between subject and verb, for example subj(BE,JOHN) expresses

John is.

Page 51: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

39

Table 4.5: Arabic Dependences Table

Dependency Explanation

Nn A noun compound modifier is used to modify a head noun by the means of

another noun. For instance nn(التفاحة ,الحمراء) stands for التفاحة الحمراء.

Subj Relation between subject and verb, for example

subj(صعد , أحمد) expresses أحمد صعد السلم.

Obj The direct object of a verb phrase Dependency between a verb and its direct

object, for example obj(التفاحة,أكل) expresses to الولد أكل التفاحة.

Cc Coordination is the relation between an element of a conjunct and the

coordinating conjunction word of the conjunct(in most cases and or or).

cc(و,أمين)هذا الرجل قوي وأمين

cc(أو ,ايقافه) تشغيل البحث اآلمن أو إيقافهيمكن

Conj A conjunct is Used to build the conjunction of two phrase elements. For

example conj (أمين ,قوي) هذا رجل قوي وأمين

Disj

Amod An adjectival modifier of a noun phrase is any adjectival phrase that serves to

modify the meaning of the noun phrase. Represents the adjectival modifier

dependency.

For example amod(منير,القمر)stands for القمر منير.

Poss The possession modifier relation holds between the head of an NP and its

possessive determiner, or a genitive’s complement. Expresses a possessive

dependency between two lexical items, for example poss(الدكتور ,حاسوب) express

.هذا حاسوب الدكتور

prepFX Stands for the preposition X, where X can be any preposition, such as ، في، من

الى ....

Neg Negation modifier: The negation modifier is the relation between a negative

word and the word it modifies. For example neg(ال،يحتوي) هذا الكتاب ال يحتوي على

تاريخ االندلس

Number An element of compound number is a part of a number phrase or currency

amount. For example (10, مليون)

Page 52: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

40

Dem Demonstrative Pronouns: demonstrative Pronouns represent a thing or things.

For example dem(المرض, الذي ماهو المرض الذي يصيب (

WH

We use question words to ask certain types of questions. We often refer to them

as WH words because they include the letters WH

For example WH( هو,ما) ما هو المرض

The following example illustrates how Arabic dependencies are used when

interpreting SPARQL. Assume we have the following SPARQL query:

SELECT ?var ?x WHERE ?var ont:hasSymptoms ?x. ?var ont:infects ?organ. ?organ

ont:hasName “liver”.

We first determine the types of all variables in the query. These variables areas the

following:

?var’s class type is => :Disease

?x’s class type is => :Symptoms

?organ’s class type is => :Organ

We then extract the Arabic translations of All query words and identified types. The

resulting Arabic words are as the following:

We then refer to the dependencies in Table 4.5 on order to link consecutive words.

We then identify the following dependencies from Table 4.5:

nn(أعراض ، المرض)

subj(يصيب، المرض)

Disease

مرض

hasSymptoms

له عرض

Symptoms

عرض

Disease

مرض

Infects

يصيب

Liver

الكبد

Page 53: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

41

obj)يصيب، الكبد(

dem)المرض، الذي(

Another example:

SELECT ?name WHERE ?employee ont:hasName ?name. FILTER NOT EXIST {?employee

ont:degree “Bachelor”}

The following dependencies are determined by referring to Table 4.5.

nn(أسماء، الموظفين)

dem(الموظفين، الذين)

neg(يحملون، ال)

poss(درجة، البكالوريوس)

subj( موظفين، يحملونال )

obj(يحلمون، درجة)

4.4 Define The Rules:

In this section, we define a set of rules to capture Arabic dependencies from a

SPARQL query. These rules are as the following:

s, p and o stand for subject, predicate and object respectively. This rule means that if

the predicate is a verb and the subject is a variable, then it is transformed to a natural

language by using a concatenation of subj, obj dependencies from Table 4.5 and other

dependencies if need that.

Rule1: 𝝆 (s p o) where p is a verb and subject is variable =>

subj (𝝆 (p), 𝝆 (s))^obj(𝝆 (p), 𝝆 (o))

Page 54: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

42

Given the following triple:

{?var ont:infects ont:organ}

<?var ont:infects ont:organ>

?var class type =>ont:disease (مرض)

On applying Rule1, we get:

F(s p o)=> F(<ont:disease ont:infects ont:organ >)

subj (<ont: disease ><ont:infects>) ^ obj (<ont:infects><ont:organ>)

يصيب عضو ^ مرض يصيب

مرض يصيب عضو (After removing redundancy).

<ont:Al-Aghani-book><ont:auther><ontUri:AlAsphahani >

𝜌 (s p o)=>𝜌 (<ontUri:Al-Aghani-book><ont:auther><ontUri:AlAsphahani >

Poss(𝜌(ont:auther), 𝜌(ontUri:Al-Aghani-book))^ 𝜌(ontUri:AlAsphahani )

Poss(األغاني، مؤلف) ^ األصفهاني

^ مؤلف األغاني هواألصفهاني^

األصفهانيمؤلف األغاني هو

This rule means that if the query has two triples, one variable and predicate is a verb,

then it is transformed to a natural language by using a concatenation of subj, obj

dependencies and other dependencies if need that then join between two triple by

using conjunction (AND و"" ). But if the query has a UNION clause we use disj

dependency.

Rule3: 𝝆 (s p o) where p is a verb and subject is variable in two triple=>

subj(𝝆 (p),𝝆 (s)) ^ dobj(𝝆 (p),𝝆 (o))^conj(𝜌(subj(𝜌 (p), 𝜌 (s)) ^ dobj(𝜌 (p), 𝜌 (o))))

Rule2:𝜌(s p o) where p is a noun =>poss(𝜌(p), 𝜌 (s))^ 𝜌(o)

Page 55: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

43

subj(𝝆 (p),𝝆 (s)) ^ obj(𝝆 (p),𝝆 (o))^disj(𝜌(subj(𝜌 (p), 𝜌 (s)) ^ obj(𝜌 (p), 𝜌 (o))))

Given the following triple:

{?var ont:infects ont:Pancreas . ?var ont:causes ont:indigestion }

?var class type =>ont:disease (مرض)

<?var(مرض), :infects (يصيب), : Pancreas (بنكرياس), :causes

.< (عسر الهضم)indigestion:(يسبب)

On applying the rule04, we get:

𝜌 (<ont: disease ont:infects ont: Pancreas>)conj𝜌 (<ont: disease ont:causes

ont:indigestion>)

subj (<ont: disease ><ont:infects>) ^obj(<ont:infects><ont:Pancreas>^conj

^subj (<ont: disease ><ont:causes >) ^obj(<ont:causes ><ont:indigestion>

يصيب عضو ^ مرض يصيب ^ و ^ يسبب مرض (الهضم,عسر )nn ^ يسبب ^

مرض يصيب البنكرياس ^ مرض يسبب عسر الهضم

مرض يصيب البنكرياس ويسبب عسر الهضم (After removing redundancy).

𝝆(?var rdf:type y)) nn(𝝆(y),?var) .

<ont:diabetes> rdf:type <ont:disease>

𝜌(s p o) =>𝜌(ont:diabetes rdf:type ont:Disease)=>nn( (ont:diabetes),

(ont:Disease) )=>مرض السكر

4.5 Natural Language Processing (NLP)

After identifying the language dependencies from the previous step, the next

step is to combine and structure sentence parts to formulate a valid Arabic sentence.

However, there are few linguistic challenges that we need to handle. These challenges

are as the following:

Rule4: 𝝆 (s p o) where p isrdf:type and subject or object is variable

nn(𝜌 (s), 𝜌 (o))

<ontUri:diabetes> rdf:type <ontUri:disease>

𝜌(sp o) =>𝜌(ontUri:diabetes rdf:type

ontUri:Disease)=>nn(𝜌(ontUri:diabetes), 𝜌(ontUri:Disease) )=> مرض

السكر

Page 56: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

44

1- Determining passive and active voice: sometimes we need to reformat the

property to cope with the variable. For example, in the query SELECT ?x

WHERE {:Diabetes :infects ?x}, the predicate :infects is translated to “يصيب”

which is an active voice verb. However, we need the passive voice of this verb,

i.e. "يصاب بـ" in order to have a valid translation “ما العضو الذي يصاب بالسكر”.

2- Determine the gender (masculine or feminine): occasionally we need to change

the property to cope with the variable. For example, in the query SELECT ?x

WHERE { :Bacteria:causes?x }, the predicate :infects is translated to “يسبب”

which is a masculine depends on subject and object values. However, if the

subject value refers to feminine, we need to change the predicate value of

feminine value, i.e. "تسبب" ; Also, sometimes we need to reformat the pronoun to

cope the subject value if the subject is masculine the pronoun will be “ماهو” ,and if

the subject is feminine, so we need to reformat it to the feminine value “ماهي”in

order to have a valid translation “ البكتيريا تسبب مرضما هي ”.

3- Determine singular and plural nouns: sometimes we need to reformat the property

to cope with the variable. For example, in the query SELECT ?x WHERE

{:Diabetes :has_symptom ?x}, the predicate : has_symptom is translated to

which is a singular voice. However, we need the plural voice of this ”عرض“

property, i.e. "أعراض" in order to have a valid translation “ يالسكر أعراضما ”.

Thus we use natural Language Processing (NLP) tools that perform linguistic

analysis to help in understanding the user’s query and matching sections in

documents. This is an important task of question and document processing; we will

use NPL toolkit “Arabic Toolkit Service (ATKS) for Natural Language Processing.

Microsoft Arabic Toolkit Services (ATKS) is one of the best natural processing

language tools and we use ATKS in our approach as a main NPL tool to know if a

variable is masculine or feminine, single or popular, active or passive(Maghool), and

other NPL processing.

4.5 Postprocessing

This step consists of two major components: Aggregation and Grouping:

Aggregation means removing redundancies and collapsing information that is too

Page 57: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

45

verbose. Grouping is described by Dalianis & Hovy[53] as the process of collecting

clauses with common elements and then collapsing the common elements. We use

grouping after applying the rules as an example:

يصيب عضو ^ مرض يصيب ^ أو ^ يسبب مرض (الهضم,عسر )nn ^ يسبب ^

Now applying grouping step:

مرض يصيب البنكرياس ^ مرض يسبب عسر الهضم

مرض يصيب البنكرياس و مرض يسبب عسر الهضم

Now applying Aggregation step we get the final result as a valid Arabic sentence:

مرض يصيب البنكرياس ويسبب عسر الهضم

Page 58: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

46

Chapter 5: Case Studies

5.1 Overview

In this Chapter, we discuss the implementation of the SPARQL2AL system.

We also present full case studies that apply the approach of translating SPARQL to

natural language.

5.2 Tools and Programs For developing the Translation SPARQL to Arabic System, we need different

components at different phases for retrieving correct statement sentences. These

components will be used to understand the query semantics, the relationships between

SPARQL query components, to transform the triple patterns to the Arabic sentences.

For this reason, we used various kinds of open source software tools. The

SPARQL2AL was implemented in Java. To implement SPARQL2AL system and

documentation of the thesis, the following tools are used:

The Ontology, we use an existing Pathology Domain ontology [52].

For ontology modification, we used Protégé -5.0.0

(http://protege.stanford.edu/) which is a free, open source tool for

editing and managing Ontologies. The developments and

implementation of our Pathology Domain ontology is explained in

Section 4.1 (Ontology Development)[52].

To implement the queries, Jena framework is used. Jena is a Java

toolkit which provides an API for creating and manipulating RDF

models. Jena sources can be retrieved at http://jena.sourceforge.net/.

Java Development Kit (JDK) 1.8: A software development package

from Sun Microsystems that implements the basic set of tools needed

to write, test and debug Java applications.

Eclipse Standard/SDK: this is the program which helps us to build and

finish the system implementation using java language.

We use NLP toolkit “Arabic Toolkit Service (ATKS) NLP

(http://research.microsoft.com/en-us/projects/atks) for normalization,

tokenization, POS tagging and SARF (morphological analyzer).

Page 59: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

47

Microsoft Word 2013: this is the main program used to write the

documentation of the system.

A SPARQL query may have one or more triple patterns with one or more

variables. A variables in SPARQL can be a subject, a predicate or an object. In the

follow section, we different cases of variables and explain how they are translated.

5.3 Subject is a variable: In the following example, the subject is a variable and SPARQL query has one

triple pattern:

𝛒(s p o) subject is a variable and SPARQL query has one pattern:

𝜌(𝜌(?var) 𝜌(:infects) 𝜌(:Pancreas)).

We apply the steps explained in Chapter 4 as the following:

Step 1: Find the variable type and extract the Arabic label:

Step 2: Extract Arabic labels process after finding the variable type is: <?var(مرض),

:infects (يصيب), :Pancreas (بنكرياس)> then replace variable by its class and match every

part with its Arabic label:

SELECT ?var {?var ont:infects ont:Pancreas}

Variable class is “Disease” Class label is “مرض”

Infects

يصيب

?var

Disease

مرض

Pancreas

بنكرياس

Page 60: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

48

:Disease :infects :Pancreas

Step 3: Building association based on the dependencies when the subject is variable

we use rule1:

We use Rule1:𝜌 (s p o)) where p is a verb=>subj(𝜌 (p), 𝜌 (s)) ^ obj(𝜌 (p), 𝜌 (o))

<?var ont:infects ont:Pancreas >

𝜌 (s p o)=>𝜌 (𝜌(ont:disease(𝜌( ont:infects( 𝜌(ont: Pancreas()

subj(<ont:disease >< ont:infects >) ^obj(< ont:infects ><ont:Pancreas >)

subj( يصيب,مرض) ^ obj(بنكرياس,يصيب)

بنكرياسيصيب ^ مرض يصيب

Step 4: We apply NLP techniques to make the query linguistically correct. We check

the subject type (variable class) if it is masculine or feminine and change predicate

part depending on that. If the variable is a masculine, then the predicate will becomes

is used, but if the variable is a feminine, to ”الذي“ and opportunity connector ”يصيب”

the predicate becomes “تصيب” and opportunity connector ”التي” is used. We also

check if the variable refers to a singular or plural noun. If it is singular, we use the

verb “يصيب”, but if it is plural, we used the verb “يصيبون”.

Step 5: In this step, generated Arabic sentences are grouped and aggregated.

Redundant words are also removed. The SPARQL query after translating to Arabic

Language becomes:

بنكرياسيصيب ^ مرض يصيب

After applying the grouping, aggregation and removing redundancy, we joined the

two patterns using AND “و”to achieve the goal and retrieve the complete translation

then translating to Arabic Language becomes:

ما المرض الذي يصيب يصيب البنكرياس

بنكرياسمرض يصيب

Step 6: The Arabic translation clause is generated by firstly finding the class labels

that directly follows the question word. The final result is:

Page 61: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

49

If the input query has two or more triples we apply the same previous steps but using

Rule3 and add opportunity connector such as “AND, و”.

5.4 Object is variable: 𝝆(s p o) where p is a verb, Object a is variable and SPARQL query has one

pattern. The following example has a variable object:

PREFIX ont: http://www.semanticweb.org/omar/ontologies/2014/10/untitled-

ontology-2#>

The query is translated to natural language as the following:

Step 1: Find the variable type:

Step 2: The output of the label mapping process after finding the variable type is:

<: Pancreas (بنكرياس), :infected_by (يصاب ب),?var (مرض)>.

Replace the variable by its class and match every part with its Arabic label:

𝜌(: Pancreas, 𝑖𝑛𝑓𝑒𝑐𝑡𝑒𝑑𝑏𝑦 , ? 𝑣𝑎𝑟) =>𝜌(: Pancreas )˄𝜌(: 𝑖𝑛𝑓𝑒𝑐𝑡𝑒𝑑_𝑏𝑦)˄𝜌(? var)

=>?var rdf:type : disease. :Pancreas :infected_by ?var

{?var ont:infects ont:Pancreas}

ما المرض الذي يصيب البنكرياس؟

SELECT ?var WHERE {ont:Pancrias ont:infected_by ?var }

Variable class is “Disease” Class label is “مرض”

Page 62: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

50

𝜌(: Pancreas , ∶ 𝑖𝑛𝑓𝑒𝑐𝑡𝑒𝑑_𝑏𝑦, : 𝐷𝑖𝑠𝑒𝑎𝑠𝑒)

البنكرياس يصاب ب مرض

Step 3: The ontology labels are extracted for a complete triple pattern: A subject

.appear in sequence (مرض) and an object (يصاب ب) a predicate ,(بنكرياس)

Rule 1:𝜌 (s p o)) where p is a verb=>subj(𝜌 (p), 𝜌 (s)) ^ obj(𝜌 (p), 𝜌 (o))

<ont:Pancreas ont:infected_by?var>

𝜌 (s p o)=>𝜌 (𝜌(ont:Pancreas (( ont:infected_by ( 𝜌(ont: disease ()

subj(<ont:Pancreas><ont:infected_by>)^ obj(<ont:infected_by><ont:disease>)

subj(بنكرياس, اب بيص ) ^ obj( اب بيص (مرض,

مرض اب بيص ^ بنكرياسيصاب ب

مرض يصاب ب مرض

Step 4: Apply natural language processing as the following: the object (variable

class) is checked if it is masculine or feminine, and change predicate depending on the

result. If the variable is masculine, the predicate will become “يصيب” and opportunity

connector “الذي”, but if the variable is feminine, the predicate becomes “تصيب” and

opportunity connector ”التي” issued . But when the object is variable to translate

complete and correct Arabic sentence we can’t say “ مرض ب يصاب الذي البنكرياس ما ”or

“ المرض ما ب يصاب البنكرياس ”we can solve this by two ways

Now find the predicate inverse and replace the inverse by the predicate, we may

use Jena features as getInverse();to get the inverse of required part.

Pancreas

البنكرياس

infected_by

يصاب ب

Disease

مرض

Page 63: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

51

Or again use ATKS to get Maghool verb or current predicate by using

getMa3loomVerbs (predicate)

Then use return value as new predicate output.

Step 5: now apply the grouping and aggregation in the previous case, the SPARQL

query after translating to Arabic Language becomes:

؟المرض الذي يصيب يصيب البنكرياسا م

After applying the grouping, aggregation and removing redundancy to achieve the

goal and retrieve the complete translation then translating to Arabic Language

becomes:

عسر الهضم(يسبب و البنكرياسيصيب )مرض

Step 6: The Arabic translation clause is generated by Firstly, finding the class labels

that directly follows the question word and putting variable class label in the

beginning of the Arabic sentence after question word. In our example, the SPARQL

query after translating to Arabic Language becomes:

؟المرض الذي يصيب البنكرياسا م

5.5 Query has a UNION clause: 𝝆 (s p o) where query has a UNION clause

PREFIX ont: http://www.semanticweb.org/omar/ontologies/2014/10/untitled-

ontology-2#

{ont:Pancrias ont:infected_by ?var}

ما المرض الذي يصيب البنكرياس؟

SELECT ?var WHERE{{ ont:Pancrias ont:infected_by ?var} UNION {?var ont:cause ont:Indigestion}}

Page 64: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

52

Step 1: Find the variable type:

Step 2: The ontology labels are extracted for a complete triple pattern: A subject

appear in sequence in the first (بنكرياس) and an object (يصيب) a predicate ,(مرض)

pattern and the subject(مرض) predicate(يسبب) object(عسر الهضم), then replacing triple

pattern parts with label of class. Translate each GP separately.

Step 3: in UNION case we will define group graph patterns GP.

𝜌(UNION(GP1,GP2)) )=> disj(𝜌(GP1), 𝜌(GP2))

So we will define two GPs first: GP1 for triples before a UNION clause and GP2 for

triples after a UNION clause.

Then: Build association based on the dependencies when subject is variable we use

new rule:

Rule4:𝜌 (s p o)) where p is a verb=>subj(𝜌 (p), 𝜌 (s)) ^ obj(𝜌 (p), 𝜌

(o))^disj(𝜌(subj(𝜌 (p), 𝜌 (s)) ^ obj(𝜌 (p), 𝜌 (o))))

<?var><ont:infects ><ont:Pancreas >disj (<?var><ont:causes

><ont:indigestion>)

𝜌 (s p o)=>𝜌 (𝜌(ont:disease(𝜌( ont:infects( 𝜌(ont: Pancreas()disj𝜌 (𝜌(ont:disease(𝜌(

ont:causes ( 𝜌(ont: indigestion ( )

subj(<ont:disease >< ont:infects >) ^ obj(< ont:infects ><ont:Pancreas >) disj

subj(<ont:disease >< ont:causes>) ^ obj(< ont:infects ><ont:indigestion>)

Variable class is “Disease” Class label is “مرض”

?var

Disease

مرض

Infects

يصيب

Pancreas

البنكرياس

?var

Disease

مرض

Causes

يسبب

Indigestion

عسر الهضم

Page 65: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

53

subj( يصيب,مرض) ^ obj(بنكرياس,يصيب)disj subj( يسبب,مرض) ^ obj(عسر ,يسبب

(الهضم

(؟مرض )يسبب :عسر الهضم( ؟مرض)^ و:يصيب :البنكرياس:

After replacing the variable with label of a class now check the subject (variable

class) if masculine or feminine and change predicate part depending on the result

above by using Microsoft Arabic Toolkit Services (ATKS) to check if the variable is a

masculine then the predicate will be using the class label صيبي and opportunity

connector الذي But, if the variable is feminine we will change predicate to تصيب and

opportunity connector التي in the first pattern and in the second triple => الذي يسبب +

else = التي يسبب + Now, we need to aggregate the GPs to join the two GPs with OR in

Arabic “أو”

Step 4: now apply the grouping and aggregation in the previous case, the SPARQL

query after translating to Arabic Language becomes:

عسر الهضمما المرض الذي يسبب أو المرض الذي يصيب البنكرياسا م

After apply the grouping, aggregation and remove redundancy then join the two

patterns we use OR in Arabic “أو”to achieve to goal and retrieve the complete

translation then translating to Arabic Language becomes:

وما المرض الذي يسبب عسر الهضم(أو^ المرض الذي يصيب البنكرياس(ا )م(

يسبب عسر الهضم(أو البنكرياس)مرضيصيب

Step 5: The Arabic translation clause is generated by firstly, finding the class labels

that directly follow the question word. In our example, the SPARQL query after

translating to Arabic Language becomes:

أو يسبب عسر الهضم المرض الذي يصيب البنكرياسا م

{{ ont:Pancrias ont:infected_by ?var} UNION {?var ont:cause ont:Indigestion}

ما المرض الذي يصيب البنكرياس أو يسبب عسر الهضم

Page 66: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

54

5.4 Summary In the previous sections, the process on interpreting the SPARQL query into

Arabic language was discussed. Note that one or more of the discussed procedures

may be used according to the complexity and completeness of the SPARQL query.

Finding all variable types and labels and output of the label mapping process after

finding the variable type to preparing the NPL, and we used Microsoft Arabic Toolkit

Services (ATKS) to process all natural processing language like finding masculine or

feminine and using ATKS to get the popular of terms in Arabic language. Check verbs

and get passive “Maghool” verb then determine dependencies between multiple

queries linked with conjunctions. After applying the previous steps, the system then

generate complete and correct Arabic statements.

Page 67: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

55

Chapter 6: Experimental Results and Evaluation

6.1 Overview

This chapter presents the evaluation of our work. Firstly, we state the tools and

programs used to test the proposed system. The evaluation is explained next. At the

end of the chapter we will discuss our results.

6.2 Objectives The main goal of this evaluation is to assess the system’s ability to translate

SPARQL queries to valid Arabic language statements and measure the system

accuracy.

6.3 Preliminary Evaluation

As for comparison and contrast with other methods, we are not aware of any

previous work that uses ontologies for translating SPARQL2AR. Therefore, we

cannot compare or contrast our methodology with other researches.

In this chapter, we present the preliminary evaluation of our system to

determine whether it translates SPARQL queries to valid and correct Arabic language

statements.

SPAQRL query has many statuses that have one pattern triple, more than

query, union, optional or limit clause. We performed an experiment to demonstrate

sample results. Our experiment depends on the data in the domain ontology presented

in Chapter 0.The dataset we used for evaluation consisted of 04 questions from

dataset in [52]. Table 6.1 shows these questions. It also shows the ideal SPARQL

queries that represent these question.

Our system was evaluated by inputting the SPARQL queries of these 40

questions and compare the generated Arabic statements with the questions in Table

6.1.

Table 6.1: Questions That Were Tested and Built Queries

QN Question Query

1 الكبد؟ يصيب الذي المرض ما

SELECT ?x WHERE

{?x ont:infects ont:liver}

2 القلب؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:heart}

3 البنكرياس؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:pancreas}

Page 68: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

56

4 الزهري؟ بمرض اإلصابة سبب ما

SELECT ?s WHERE{

?s ont:causes ont:Syphilis}

5 الرئتين؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:lung}

6 السكر؟ مرض أعراض ما

SELECT ?x WHERE

{ ont:Diabetes ont:has_symptom ?x}

7 ما المرض الذي يصيب القلب وله اكثر من عرض؟

SELECT ?x ?s WHERE

?x ont:infects ont:heart

?x ont:has_symptom ?s filter (?s > 1)}

8 ؟ المتكيسة الكلية مرض أعراض ما

SELECT ?x WHERE

{ ont:Polycystic_kidney ont:has_symptom

?x}

9 القلب؟ عضلة اعتالل مسببات ما

SELECT ?x WHERE

{?x ont:causes ont:cardiomyopathy}

10 الجلد؟ سرطان يشخص كيف

SELECT ?x WHERE

{ont:Skin_Cancer ont:Diagnose ?x}

11 ؟ما هي االمراض المعدية

SELECT ?x WHERE

{?x rdfs:subClassOf ont:infectious_agent}

12 يشخص؟ وكيف التيفوئيد مرض أسباب ما

SELECT ?x WHERE

{ont:Tetanus ont:Diagnose ?x}

13 الكزاز؟ لمرض المستخدم التشخيص ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Typhoid.

ont:Typhoid ont:Diagnose ?x}

14 أعراضه؟ وما الصداف مسببات ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Psoriasis.

ont:Psoriasis ont:has_symptom ?x}

15 التستوستيرون؟ هرمون تحليل يشخص ما

SELECT ?s WHERE

{ont:Testosterone ont:Diagnose ?s }

16 ؟ ال تسبب ألم للمعدة التي ودويةاأل ما

SELECT ?x WHERE

{?x rdf:type ont: cure .

FILTER NOT EXISTS

{?x ont: causes ont:Stomach_pain}}

17 اإلنفلونزا؟ وعالج أعراض ما

SELECT ?x ?s WHERE

{ont:Influenza ont:has_symptom ?x.

ont:Influenza ont:cured_by ?s}

25 التدخين؟ يسببها التي األمراض ما

SELECT ?d WHERE

Page 69: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

57

{ont:Smoking ont:causes ?d}

19 األلمانية؟ الحصبة وأعراض أسباب ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Rubella.

ont:Rubella ont:has_symptom ?x}

20 النغف مرض وأعراض أسباب أذكر

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Myiasis.

ont:Myiasis ont:has_symptom ?x}

21 والقيئ ؟ االسهال أعراضه ومن األمعاء يصيب الذي المرض ما

SELECT ?x WHERE {

?x ont:infects ont:small_intestine.

?x ont:has_symptom ont:vomiting.

?x ont:has_symptom ont:Diarrhea }

22 النفسية؟ األمراض من الالإراودي التبول هل

SELECT ?d WHERE {

ont:Enuresis rdf:type ?d}

23 بنكرياس يصيب الذي المرض ما

الهضم عسر يسبب و

SELECT ?disease WHERE {

{ont:Pancrias ont:infected_by ?disease}

OPTIONAL

{?disease ont:cause ont:Indigestion}

}

24 سي؟ بي سي بفحص تشخص التي األمراض ما

SELECT ?s WHERE

{ont:CBC ont:Diagnose ?s}

22 الهضم؟ عسر يسببال و الكبد يصيب الذي المرض ما

SELECT ?x WHERE

{?x ont:infects ont:liver.

{ FILTER NOT EXISTS

?x ont:causes ont:Indigestion}}

26 ودرجة وارتفاع األنسولين نقص يسبب الذي المرض ما

الحرارة ودرجة ارتفاع الحرارة؟ويسببه

SELECT ?s WHERE{

?s ont:caused_by ont:Lack_of_insulin.

?s ont:caused_by ont:high_temperature

27 فالجيل؟ ودواء يعالج ماذا

SELECT ?s WHERE

{?s ont:cured_by ont:Flagyl}

28 ما أفضل عالج لمرض السكري

SELECT ?d WHERE {

?d ont:cure_for ont: Diabetes }

29 الجدري؟ يعالج كيف

SELECT ?c WHERE

{?c ont:cure_for ont:Smallpox}

30 القلب؟ جراحات أنواع بعض أذكر

SELECT ?c WHERE

{?c rdf:type ont:heart_surgery}

31 األنسولين نقص يسببه بنكرياس يصيب الذي المرض ما و

SELECT ?d WHERE {

Page 70: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

58

أو

العطش عرضه

?d ont:infects ont:pancreas.

{?d ont:caused_by ont:Lack_of_insulin}

UNION

{?d ont:has_symptom ont:thirst} }

32 و ناألنسولي نقص يسببه و بنكرياس يصيب الذي المرض ما

العطش عرضه

SELECT ?d WHERE {

?d ont:infects ont:pancreas.

{?d ont:caused_by ont:Lack_of_insulin}

OPTIONAL

{?d ont:has_symptom ont:thirst} }

33 الدم؟ ضغط ارتفاع أعراضها من التي األمراض

SELECT ?x WHERE

{ont:high_blood_pressure ont:symptom_of ?x }

30 الهضم عسر يسبب أو بنكرياس يصيب الذي المرض ما

SELECT ?d WHERE {

{ont:pancreas ont:infected_by ?d}

UNION

{?d ont:causes ont:Indigestion}}

32 النفسية األمراض بعض أذكر

SELECT ?d WHERE {

?d rdf:type ont:mental}

33 اإلجهاض؟ تسبب التي األودوية ما

SELECT ?s WHERE

{?s ont:causes ont:Abortion}

33 التوحد؟ أعراض ما

SELECT ?x WHERE

{ont:Autism ont:has_symptom ?x }

33 ؟بالسي تي شخصوي الرئة تصيب التي األمراض بعض ذكر

SELECT ?d WHERE

{ont:lung ont:infected_by ?d.

?d ont:Diagnose ont:CT}

33 ماهي االمراض التي تصيب الدم وعرضها ارتفاع ضغط الدم

ضربات القلبوتسبب عدم انتظام

SELECT ?b WHERE

{?b ont:infects ont:blood.

?b ont:causes ont:arrhythmias.

?b ont:has_symptom ont:high_blood_pressure }

04

أعراضها من وليس األسهال أعراضها من التي األمراض ما

الحرارة؟ ودرجة ارتفاع

SELECT ?x WHERE { ?x ont:causes

ont:Indigestion. {FILTER NOT EXISTS ?x

ont:causes ont:high_temperature }}

These 00 queries were carefully chosen to test the different routes of the

algorithm used to translate SPARQL queries to Arabic language. The questions varied

in complexity and structure.

Page 71: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

59

For example, some queries can be directly translated to Arabic language with

simple natural language processing e.g.(SELECT ?xWHERE {?x ont:infects

ont:liver} ؟الكبدما األمراض التي تصيب ). Some questions cannot be directly translated

into Arabic language, and thus the system should infer missing or imply components

before being able to transform the queries. The following example is more complex

because it has multiple “triples” and has more than one variable, so we need to find

two class types, and to find their Arabic labels (e.g. SELECT ?s ?xWHERE { ?s

ont:causes ont:Myiasis. ont:Myiasis ont:has_symptom ?x} وأعراض أسباب أذكر

النغف ؟ مرض ).

Other queries with more complexity have many “triple” pattern with multiple

variables and may have a UNION clause. For example: ( SELECT ?d WHERE {

{ont:Pancrias ont:infected_by ?d}

UNION

{?d ont:cause ont:Indigestion }

الهضم عسر يسبب بنكرياس أو يصيب الذي المرض ما { ) or optional clause e.g. (

SELECT ?disease WHERE {

{ont:Pancrias ont:infected_by ?disease}

OPTIONAL

{?disease ont:cause ont:Indigestion}}

الهضم عسر يسبب بنكرياس و الذي يصيب المرض ما ).

Hence, we cannot deal with all queries in the same way which applying the same

rules. However, we deal with every query independently, depending on its

requirements and its complexity, we should infer missing or implied components

before being able to transform the queries to a valid Arabic statements.

6.4 Results Table 6.3 shows the answers generated by the system along with the ideal answers.

The column on the right shows the validation results given by the human experts.

Overall, the expert found that 30 out of the 40 queries were relatively correct and gave

the same meaning of the original query (see Table 6.2). Of the correctly-validated

queries, 10 queries were assessed as valid although they did not exactly match with

the ideal query. This is because they delivered the intended meaning as indicated by

the expert. 3 queries were assessed as incorrect by the expert.

Looking at the SPARQL queries generated by the system, we found that they

sometimes differ slightly from the original queries. Some generated queries contained

the same words with different format, e.g. التوحد ل عرض الذي العرض ما . However, this does

Page 72: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

60

not necessarily mean that the generated queries were incorrect. Therefore, we cannot

directly match the system results with the gold standard due to these slight

differences.

Table 6.2: Translation Results

Two of the system queries were incorrect and were difficult to understand by

the expert. The system did not give any answer to the remaining two queries.

Table 6.3: Questions That Were Tested, Built Queries, System Translation Result, and Human Expert Judgment.

QN Question Query System Translation H.E. J

1 الكبد؟ يصيب الذي المرض ما

SELECT ?x WHERE

{?x ont:infects ont:liver} يصيب الذي الفيروسي المرض ما

الكبد

2 القلب؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:heart} القلب يصيب الذي المرض ما

3 البنكرياس؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:pancreas} بنكرياس يصيب الذي المرض ما

4 الزهري؟ بمرض اإلصابة سبب ما

SELECT ?s WHERE{

?s ont:causes ont:Syphilis} الزهري يسبب الذي السبب ما

5 الرئتين؟ تصيب التي األمراض ما

SELECT ?x WHERE

{?x ont:infects ont:lung} يصيب الذي الفيروسي المرض ما

الرئة

6 السكر؟ مرض أعراض ما

SELECT ?x WHERE

{ ont:Diabetes ont:has_symptom ?x} السكري ل الذي عرض العرض ما

7 ما المرض الذي يصيب القلب وله اكثر

من عرض؟

SELECT ?x ?s WHERE

?x ont:infects ont:heart

?x ont:has_symptom ?s filter (?s > 1)}

ماما المرض الذي يصيب القلب

ل القلب عرض الذي العرض

X

8 ؟ المتكيسة الكلية مرض أعراض ما

SELECT ?x WHERE

{ ont:Polycystic_kidney

ont:has_symptom ?x}

الكلية ل عرض الذي العرض ما

المتكيسة

9 القلب؟ عضلة اعتالل مسببات ما

SELECT ?x WHERE

{?x ont:causes ont:cardiomyopathy} ةعضل اعتالل يسبب الذي العرض ما

القلب

10 الجلد؟ سرطان يشخص كيف

SELECT ?x WHERE

{ont:Skin_Cancer ont:Diagnose ?x} x سرطان يشخص الذي التشخيص ما

Total questions Correct Results Incorrect Results

40 34 6

Page 73: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

61

الجلد

11 ؟االمراض المعديةما هي

SELECT ?x WHERE

{?x rdfs:subClassOf

ont:infectious_agent}

معدي مرض ماأنواع

12 وكيف التيفوئيد مرض أسباب ما

يشخص؟

SELECT ?x WHERE

{ont:Tetanus ont:Diagnose ?x} تيفوئيد يشخص الذي السبب ما

يدتيفوئ يسبب الذي التشخيص ما

13 الكزاز؟ لمرض المستخدم التشخيص ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Typhoid.

ont:Typhoid ont:Diagnose ?x}

الكزاز يشخص الذي التشخيص ما

14 أعراضه؟ وما الصداف مسببات ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Psoriasis.

ont:Psoriasis ont:has_symptom ?x}

صدفية ل عرض الذي العرض ما

صدفية يسبب الذي السبب ما

15 هرمون تحليل يشخص ما

التستوستيرون؟

SELECT ?s WHERE

{ont:Testosterone ont:Diagnose ?s } يشخصه الذي جيني المرض ما

التستوستيرون هرمون

16 ؟ ال تسبب ألم للمعدة التي ودويةاأل ما

SELECT ?x WHERE

{?x rdf:type ont: cure .

FILTER NOT EXISTS

{?x ont: causes ont:Stomach_pain}}

؟ تسبب ألم للمعدة التي ودويةاأل ما X

17 اإلنفلونزا؟ وعالج أعراض ما

SELECT ?x ?s WHERE

{ont:Influenza ont:has_symptom

?x.

ont:Influenza ont:cured_by ?s}

إنفلونزا ل عرض الذي العرض ما

إنفلونزا ل عالج الذي العالج ماو

18 التدخين؟ يسببها التي األمراض ما

SELECT ?d WHERE

{ont:Smoking ont:causes ?d} التدخين يسببه الذي المرض ما

19 األلمانية؟ الحصبة وأعراض أسباب ما

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Rubella.

ont:Rubella ont:has_symptom ?x}

الحصبة يسبب الذي السبب ما

األلمانية

الحصبة ل عرض الذي العرض ما

األلمانية

20 النغف مرض وأعراض أسباب أذكر

SELECT ?s ?x WHERE

{ ?s ont:causes ont:Myiasis.

ont:Myiasis ont:has_symptom ?x}

النغف يسبب الذي السبب ما

النغف ل عرض الذي العرض ما

21 ومن األمعاء يصيب الذي المرض ما

والقيئ ؟ االسهال أعراضه

SELECT ?x WHERE {

?x ont:infects ont:small_intestine.

?x ont:has_symptom ont:vomiting.

األمعاء يصيب الذي المرض ما

عرضه و اإلسهال عرضه الدقيقة و

القيئ

Page 74: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

62

?x ont:has_symptom ont:Diarrhea }

22 األمراض من الالإراودي التبول هل

النفسية؟

SELECT ?d WHERE {

ont:Enuresis rdf:type ?d} من نوع الالإراودي التبول هل ?d X

23 بنكرياس يصيب الذي المرض ما

الهضم عسر يسبب و

SELECT ?disease WHERE {

{ont:Pancrias ont:infected_by ?disease}

OPTIONAL

{?disease ont:cause ont:Indigestion}

}

بنكرياس يصيب الذي المرض ما

الهضم عسر يسبب و

24 يب سي بفحص تشخص التي األمراض ما

سي؟

SELECT ?s WHERE

{ont:CBC ont:Diagnose ?s} يس بي سي يشخصه الذي المرض ما

22 بيسبال و الكبد يصيب الذي المرض ما

الهضم؟ عسر

SELECT ?x WHERE

{?x ont:infects ont:liver.

{ FILTER NOT EXISTS

?x ont:causes ont:Indigestion}}

يسبب الذي الفيروسي المرض ما

الكبد يصيب و الهضم عسر

X

26 ناألنسولي نقص يسبب الذي المرض ما

ارتفاع الحرارة؟ويسببه ودرجة وارتفاع

الحرارة ودرجة

SELECT ?s WHERE{

?s ont:caused_by ont:Lack_of_insulin.

?s ont:caused_by

ont:high_temperature}

نقص يسببه الذي المرض ما

األنسولين

الحرارة ودرجة ارتفاع يسببه و

27 فالجيل؟ ودواء يعالج ماذا

SELECT ?s WHERE

{?s ont:cured_by ont:Flagyl} فالجيل ب يعالج الذي المرض ما

28 ما أفضل عالج لمرض السكري

SELECT ?d WHERE {

?d ont:cure_for ont: Diabetes } X ما عالج مرض السكري

29 الجدري؟ يعالج كيف

SELECT ?c WHERE

{?c ont:cure_for ont:Smallpox} الجدري ل الذي عالج الدواء ما

30 القلب؟ جراحات أنواع بعض أذكر

SELECT ?c WHERE

{?c rdf:type ont:heart_surgery} القلب جراحة ماأنواع

31 ببهيس بنكرياس يصيب الذي المرض ما

األنسولين نقص و

أو

العطش عرضه

SELECT ?d WHERE {

?d ont:infects ont:pancreas.

{?d ont:caused_by ont:Lack_of_insulin}

UNION

{?d ont:has_symptom ont:thirst} }

نقص يسببه الذي المرض ما

األنسولين

بنكرياس يصيب و

أو

العطش عرضه

32 ببهيس و بنكرياس يصيب الذي المرض ما

العطش عرضه و األنسولين نقص

SELECT ?d WHERE {

?d ont:infects ont:pancreas.

{?d ont:caused_by ont:Lack_of_insulin}

نقص يسببه الذي المرض ما

األنسولين

بنكرياس يصيب و

Page 75: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

63

OPTIONAL

{?d ont:has_symptom ont:thirst} } العطش عرضه و

33 ضغط ارتفاع أعراضها من التي األمراض

الدم؟

SELECT ?x WHERE

{ont:high_blood_pressure

ont:symptom_of ?x }

ضغط ارتفاع عرضه الذي المرض ما

الدم

30 أو بنكرياس يصيب الذي المرض ما

الهضم عسر يسبب

SELECT ?d WHERE {

{ont:pancreas ont:infected_by ?d}

UNION

{?d ont:causes ont:Indigestion}}

بنكرياس يصيب الذي المرض ما

أو

الهضم عسر يسبب الذي المرض ما

32 النفسية األمراض بعض أذكر

SELECT ?d WHERE {

?d rdf:type ont:mental} النفسي المرض ماأنواع

33 اإلجهاض؟ تسبب التي األودوية ما

SELECT ?s WHERE

{?s ont:causes ont:Abortion} االجهاض يسبب الذي الدواء ما

33 التوحد؟ أعراض ما

SELECT ?x WHERE

{ont:Autism ont:has_symptom ?x } التوحد ل عرض الذي العرض ما

33 الرئة تصيب التي األمراض بعض ذكر

؟بالسي تي شخصوي

SELECT ?d WHERE

{ont:lung ont:infected_by ?d.

?d ont:Diagnose ont:CT}

يصيب الذي الفيروسي المرض ما

الرئة

تي سي ويشخصه

33 ماهي االمراض التي تصيب الدم

وعرضها ارتفاع ضغط الدموتسبب عدم

ضربات القلبانتظام

SELECT ?b WHERE

{?b ont:infects ont:blood.

?b ont:causes ont:arrhythmias.

?b ont:has_symptom

ont:high_blood_pressure }

الدم يصيب الذي المرض ما

الدم ضغط ارتفاع عرضه و

القلب ضربات انتظام عدم يسبب و

04

األسهال أعراضها من التي األمراض ما

ودرجة ارتفاع أعراضها من وليس

الحرارة؟

SELECT ?x WHERE { ?x ont:causes

ont:Indigestion. {FILTER NOT EXISTS

?x ont:causes ont:high_temperature }}

عسر الهضم يسبب الذي المرض ما

الدم ضغط ارتفاع يسببص و

X

Results showed that the system can correctly translate 33 out of the 04

questions as shown in Table 3.3 depicts the number of questions and their results.

6.5 Discussion In the following discussion, we picked example SPARQL queries that were

correctly translated to Arabic Sentence and showed how the system translated them.

We also discuss some of the queries that the system could not correctly translate.

Page 76: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

64

In query No.7 SELECT ?x ?s WHERE ?x ont:infects ont:heart. ?x

ont:has_symptom ?s filter (?s > 1)} ما المرض الذي يصيب القلب وله اكثر من عرض؟ . The

result generated by the system was: ” ل القلب عرض الذي العرض ماما المرض الذي يصيب القلب ”.

This query has not been translated correctly due to the FILTER clause which is not

supported in our system.

In query No.16 SELECT ?x WHERE {?x rdf:type ont: cure .{ FILTER NOT EXISTS

{?x ont: causes ont:Stomach_pain}} ؟ تسبب ألم للمعدة ال التي ودويةاأل ما . The result

generated by the system was: ” ؟ تسبب ألم للمعدة التي ودويةاأل ما ”. Notice that the system

ignored the negative clause in this query because the still can’t deal with NOT

EXISTS FILTER clause.

In query No. 22 SELECT ?d WHERE {ont:Enuresis rdf:type ?d} من الالإراودي التبول هل

النفسية؟ األمراض after running the system the result retrieved was “ الالإراودي نوع التبول هل

d”. The system cannot translate the predicate because it does not recognize the name?من

space rdf:. It was only configured to process entities that has the ont name space (The

name space used in our domain ontology). This error can be easily recovered by

enabling the system to process other types of name spaces..

In query No. 25 SELECT ?x WHERE {?x ont:infects ont:liver.{ FILTER NOT

EXISTS ?x ont:causes ont:Indigestion}} الهضم؟ عسر يسببال و الكبد يصيب الذي المرض ما .

The result generated by the system was:“ الهضم عسر يسبب و الكبد يصيب الذي المرض ما ”. Again,

the system ignored the negative clause.

In query No. 28 SELECT ?d WHERE {?d ont:cure_for ont: Diabetes } ما أفضل عالج

ما عالج مرض السكري :The result generated by the system was . لمرض السكري . Notice that

the system ignore the superlative word أفضل. Our approach is not currently able to

handle superlative/comparative words..

In query No. 40 in Table 6.3 (e.g. SELECT ?x WHERE { ?x ont:causes

ont:Indigestion. {FILTER NOT EXISTS ?x ont:causes ont:high_temperature }} ما

الحرارة؟ ودرجة ارتفاع أعراضها من وليس األسهال أعراضها من التي األمراض ) The result generated by the

system was: “ الدم ضغط ارتفاع يسببو الهضم عسر الذي يسبب المرض ما ” . Again, the system could

not translate the word “ليس”.

After getting the 40 queries answers we found that 10 answers did not match with the

gold standard in questions dataset, but they were assessed as valid by the human

expert. The expert indicated that he could understand the intent of these questions

even though they did not match with the ideal sentences. In the following, we explain

the correct answers that do not match with gold standard after getting the human

expert judgment:

In query No. 11 “SELECT ?x WHERE {?x rdfs:subClassOf ont:infectious_agent} ما

؟هي االمراض المعدية ” the result from system was “ معدي مرض ماأنواع ”. The system translate

Page 77: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

65

the query correct but not match with gold standard question and give the same

meaning.

In query No. 35 “SELECT ?d WHERE {?d rdf:type ont:mental} النفسية األمراض بعض أذكر

“ the result from system was ”؟ النفسي المرض ماأنواع ”. The system translate the query

correct but not match with gold standard question and give the same meaning.

In query No. 17 e.g.( “SELECT ?x ?s WHERE ont:Influenza ont:has_symptom ?x.

ont:Influenza ont:cured_by ?s} اإلنفلونزا؟ وعالج أعراض ما ). The result after

running the system” إنفلونزا ل الذي عرض العرض ما إنفلونزا ل الذي عالج العالج ما ” the system

translated every triple pattern separately.

The system removed redundancy and retrieved valid and correct answer but in the

previous example. In query No. 17 in first triple ont:Influenza ont:has_symptom

?x the system retrieve إنفلونزا ل الذي عرض العرض ما the first label “العرض” the Arabic

label of the variable class type “symptom” after the system found the variable class

and extract the Arabic label, it replaced the Arabic label“العرض” by the variable class

type; the second label”عرض ل ” the Arabic label of the object proparity

“has_symptom“ and the Arabic label of the object proparity “has_symptom“ is

so after retrieving all of triple translation the result look like having a ”عرض ل“

redundancy عرض and عرض ل => إنفلونزا ل الذي عرض العرض ما .

The second triple has the same note ont:Influenza ont:cured_by ?s the system

retrieve اإنفلونز ل الذي عالج العالج ما the first label “العالج” the Arabic label of the variable

class type “cure” after the system find the variable class and extracted the Arabic

label, it replaced the Arabic label“العالج” by the variable class type; the second label”

ل عالج ” the Arabic label of the object property “cured_by “ and the Arabic label of

the object property “cured_by “ is “ ل عالج ” so after retrieving all of triple translation

the result look like having a redundancy عالج and ل عالج => إنفلونز ل الذي عالج العالج ما .

We test all queries to check redundancy errors on In query No. 23 SELECT ?disease

WHERE {{ont:Pancrias ont:infected_by ?disease}

OPTIONAL {?disease ont:cause ont:Indigestion}}

الهضم عسر يسبب بنكرياس و يصيب الذي المرض ما in this example the query is more

complex because it has optional clause and we will check redundancy after running

the system. The result was retrieved as الهضم عسر يسبب بنكرياس و يصيب الذي المرض ما

after showing the result in the first triple when the system retrieved the variable class

type “disease” and extracted the Arabic label of it “المرض” and in second triple when

the system retrieved the variable class type also was “disease” and extracted the

Arabic label of it “المرض” so the system directly removed the redundancy of the

variable class type which was also “disease” and extracted the Arabic label of it

from the second triple translation and retrieved all of query translation after ”المرض“

removing all redundancy=> ضماله عسر يسبب و بنكرياس يصيب الذي المرض ما so we

emphasis that the system can deal with redundancy removal directly.

Page 78: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

66

Despite these errors, we want to know if these answers are understandable for humans

or not, so a human expert was needed to measure the adequacy and accuracy of the

generated answers.

After expert testing of the retrieved answers, he found that the system answers

also don’t match the gold standard in dataset, so these answers were considered

incorrect and after completing the testing the system and the human expert judgments,

30 out of the 40 queries were found to be correct, This indicate that they gave the

same meaning of the original query.

Now, in order to calculate the accuracy of the system and the experiment.

Accuracy

The accuracy of systems for translation SPARQL to Arabic Language:

Accuracy = 34/40 = 0.85

The system accuracy is 0.825

6.6 System Limitation: The system has some limitations. The above results highlight some of the system

strengths and limitations which we can be summarized as follows:

Negation: when question has negation expression our system has lack to deal

with these queries. If we analyze query No. 40 in Table 6.3 (e.g. SELECT ?x

WHERE { ?x ont:causes ont:Indigestion. {FILTER NOT EXISTS ?x

ont:causes ont:high_temperature }} من وليس األسهال أعراضها من التي األمراض ما

الحرارة؟ ودرجة ارتفاع أعراضها ) The result after running the system “ ضغط ارتفاع و يسبب

الهضم عسر يسببالذي المرض ما الدم ” because the still can’t deal with NOT EXISTS

FILTER clause.

Pronouns: when question has pronouns the system has lake to deal with these

queries if we take query No. 4 in Table 6.3 (e.g. SELECT ?s ?x WHERE{ ?s

ont:causes ont:Psoriasis. ont:Psoriasis ont:has_symptom ?x} مسببات ما

أعراضه؟ وما الصداف ). The result after running the system “ صدفية يسبب الذي السبب ما ما

صدفية ل عرض الذي العرض ” so the system can’t directly retrieve اعراضه the

system deal with second query as new triple and retrieve all triple parts and

translate them to Arabic.

Comparative and superlative words: the system still can’t deal with

comparatives (e.g. افضل عالج لمرض السكرما ) system cannot translate query that

has comparative clause. In future work we will work on this case.

Page 79: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

67

In a future work, we aim to test the system with different domains of

knowledge and different query cases to ensure its portability feature (i.e. the ability to

interface to different ontologies). We will give more effort to improve the system

ability to deal with comparatives. We will also test it with users and human experts.

Also, we will try to identify more rules for complex SPARQL queries

6.7 Summary This chapter, talked about realization, experimental results and evaluation of

the proposed system. The first, explained the components that were used in our

SPARQL to Arabic language system and showed the role of each component. In the

second section, we presented the tools and programs used in our work. The third we

presented the questions that were tested and the results that generated from the

system. The fourth, we presented the evaluation for our model showing that the

system can correctly answer 33 out of the 00 questions. The fifth section, discussed

the results.

Page 80: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

68

Chapter 7: Conclusion and Future Work

In this research, we have developed a model for SPARQL2AL system based

on Ontology that transforms SPARQL queries to NL statements in Arabic. The

system is designed to be ontology-portable. This ontology-based model uses ontology

components for matching with users’ queries. Our model consists of several

components which are Knowledge base, Data Processing, Query Processing, Define

the Rules and Translation Retrieval.

The process of constructing from the SPARQL query to NL query contains

procedures based on the complexity and completeness of the SPARQL query. Also,

rules were defined to capture dependencies between the query terms. We support that

with examples that cover all different types of procedures.

Experiments were performed to test the system for interpreting SPARQL

queries to NL queries in Arabic. The questions that have been tested depend on the

data in ontology domain. In the evaluation process, the results that generated from the

system show that the system can correctly answer 33 out of the 04queries.

The main contribution of this research is that using the ontology can support

the process of translating SPARQL queries to a valid Arabic language statements.

Since only a prototype of the proposed system is implemented, in a future

work we look forward to implementing a complete system. Success of our proposed

prototype encourages us to look for ways to increase the scope of this research to

include more types of queries such as negation, pronouns, and comparative phrases.

In addition, we are looking forward to extend the ontology by adding more data and

semantic information. Also, we are looking forward to increase our rules and

procedures of the SPARQL query to cover the largest amount of cases and obtain

more accurate results.

Page 81: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

69

References: [1] A. Ngonga, C. Unger, J. Lehmann, and D. Gerber, “SPARQL2NL –

Verbalizing SPARQL queries Categories and Subject Descriptors,” pp. 329–

332.

[2] C. Unger and L. Bühmann, “Template-based question answering over RDF

data,” Proc. 21st Int. Conf. World Wide Web, pp. 639–648, 2012.

[3] J. Perez, M. Arenas, and C. Gutierrez, “Semantics and Complexity of

SPARQL,” 2006.

[4] S. Green, M. Galley, and C. D. Manning, “Improved Models of Distortion

Cost for Statistical Machine Translation,” Hum. Lang. Technol. 2010 Annu.

Conf. North Am. Chapter Assoc. Comput. Linguist., vol. 5, pp. 867–875,

2010.

[5] M. Sander, U. Waltinger, M. Roshchin, and T. Runkler, “Ontology-Based

Translation of Natural Language Queries to SPARQL,” pp. 42–48, 2014.

[6] A. Ngonga, C. Unger, J. Lehmann, and D. Gerber, “Sorry , I don ’ t speak

SPARQL – Translating SPARQL Queries into Natural Language,” Www, pp.

977–987, 2013.

[7] B. Tim Lee, J. Hendler, and O. Lassila, “The Semantic Web,” Sci. Am. Featur.

Artic. Semant. Web, no. May, pp. 1–5, 2001.

[8] “Semantic Web Fundamentals.” [Online]. Available: http://what-when-

how.com/information-science-and-technology/semantic-web-fundamentals/.

[Accessed: 12-Oct-2015].

[9] “W3C. Resource Description Framework.” [Online]. Available:

http://www.w3.org/TR/2004/REC-rdf-concepts-20040210/.

[10] J. Z. Pan and I. Horrocks, “RDFS ( FA ): Connecting RDF ( S ) and OWL

DL,” Knowl. Creat. Diffus. Util., vol. 19, pp. 192–206, 2007.

[11] a Bäck, S. Vainikainen, C. Södergård, and H. Juhola, “Semantic Web

Technologies in Knowledge Management.,” Elpub, pp. 269–278, 2003.

[12] V. Jain and M. Singh, “Ontology Development and Query Retrieval using

Protégé Tool,” Int. J. Intell. Syst. Appl., vol. 5, no. August, pp. 67–75, 2013.

[13] “What is an Ontology?” [Online]. Available: http://www-

ksl.stanford.edu/kst/what-is-an-ontology.html.

[14] S. Ou, C. Orasan, D. Mekhaldi, and L. Hasler, “Automatic question pattern

generation for ontology-based question answering,” Proc. 21st Int. Florida

Artif. Intell. Res. Soc. Conf., pp. 183–188, 2008.

[15] D. Damljanovic, V. Tablan, K. Bontcheva, R. Court, and P. Street, “A Text-

based Query Interface to OWL Ontologies,” Proc. Int. Conf. Lang. Resour.

Eval. (LREC 2008), pp. 205–212, 2008.

[16] J. Z. Pan and I. Horrocks, “OWL-Eu: Adding customised datatypes into

OWL,” Web Semant., vol. 4, no. 1, pp. 29–39, 2006.

[17] “JSONP SPARQL.” [Online]. Available:

https://www.drupal.org/project/jsonp_sparql. [Accessed: 27-Jul-2015].

[18] “Introduction to: SPARQL.” [Online]. Available:

http://www.dataversity.net/introduction-to-sparql/. [Accessed: 27-Jul-2015].

[19] L. McCarthy, L. McCarthy, B. Vandervalk, and M. Wilkinson, “SPARQL

Assist Language Neutral Query Composer,” Nat. Preced., pp. 4–6, 2010.

[20] “SPARQL Query Language for RDF.” [Online]. Available:

http://www.w3.org/TR/rdf-sparql-query/. [Accessed: 27-Jul-2015].

[21] B. L. Yu, A Developer’s Guide to the Semantic Web. .

Page 82: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

70

[22] S. Metzler and P. Miettinen, “On Defining SPARQL with Boolean Tensor

Algebra,” no. Section 6, pp. 1–15, 2015.

[23] I. O’Reilly Media, “Introducing SPARQL: Querying the Semantic Web.”

[Online]. Available: http://www.xml.com/pub/a/2005/11/16/introducing-

sparql-querying-semantic-web-tutorial.html?page=2. [Accessed: 27-Jul-2015].

[24] M. Stocker and A. Seaborne, “SPARQL Basic Graph Pattern Optimization

Using Selectivity Estimation,” Proc. 17th Int. Conf. World Wide Web, pp.

595–604, 2008.

[25] B. Reasoning, “CS2007 Reasoner/SPARQL Lab – v1.0 16 Feb 2009,” 2009.

[26] M. Jarrar and M. D. Dikaiakos, “Querying the Data Web,” pp. 58–67, 2010.

[27] “SPARQL By Example,” 2009. [Online]. Available:

http://www.w3.org/2009/Talks/0615-qbe/. [Accessed: 27-Jul-2015].

[28] I. Kollia and B. Glimm, “Optimizing SPARQL query answering over OWL

ontologies,” J. Artif. Intell. Res., vol. 48, pp. 253–303, 2013.

[29] L. Feigenbaum, “SPARQL By Example A Tutorial Why SPARQL ? Structure

of a SPARQL Query.” pp. 1–53, 2011.

[30] S. O. Wonghong Jang, “Learning Sparql,” p. 256, 2011.

[31] J. Sequeda, “SPARQL 101.” [Online]. Available:

https://supportcenter.cambridgesemantics.com/semantic-university/sparql-101.

[Accessed: 27-Jul-2015].

[32] R. J. Mooney, “Natural Language Processing Humor and Ambiguity,” pp. 1–

20.

[33] I. a. Al-Sughaiyer and I. a. Al-Kharashi, “Arabic morphological analysis

techniques: A comprehensive survey,” J. Am. Soc. Inf. Sci. Technol., vol. 55,

no. 3, pp. 189–213, 2004.

[34] M. Sawalha, E. Atwell, and M. a M. Abushariah, “SALMA: Standard arabic

language morphological analysis,” 2013 1st Int. Conf. Commun. Signal

Process. Their Appl. ICCSPA 2013, 2013.

[35] R. Al-shalabi, G. Kanaan, B. Al-sarayreh, K. Khanfar, A. Al-ghonmein, H.

Talhouni, and S. Al-azazmeh, “Proper Noun Extracting Algorithm for Arabic

Language,” pp. 1–9, 2009.

[36] B. Hammo and S. Lytinen, “QARAB: A Question Answering System to

Support the Arabic Language,” ACL2002Computational Approaches to Semit.

Lang., p. 11, 2002.

[37] M. Gridach and N. Chenfour, “Developing a New Approach for Arabic

Morphological Analysis and Generation,” no. 1, p. 18, 2011.

[38] H. K. Al Ameed, S. O. Al Ketbi, a. a. Al-Kaabi, K. Al Shebli, N. Al Shamsi,

N. H. Al Nuaimi, and S. S. Al Muhairi, “Arabic light stemmer: A new

enhanced approach,” Second Int. Conf. Innov. Inf. Technol., pp. 1–9, 2005.

[39] S. Khoja and R. Garside, “Stemming Arabic Text,” 1999. [Online]. Available:

http://www.comp.lancs.ac.uk/computing/users/khoja/stemmer.ps.

[40] A. H. Aliwy, “Arabic Morphosyntactic Raw Text Part of Speech Tagging

System,” no. January, 2013.

[41] M. De Marneffe and C. D. Manning, “Stanford typed dependencies manual,”

20090110 Httpnlp Stanford, vol. 40, no. September, pp. 1–22, 2010.

[42] A. T. L. Cairo, “Arabic Toolkit Service (ATKS).” [Online]. Available:

http://research.microsoft.com/en-us/projects/atks/. [Accessed: 27-Jul-2015].

[43] B. Ell, D. Vrandečić, and E. Simperl, “SPARTIQULATION: Verbalizing

SPARQL queries,” CEUR Workshop Proc., vol. 913, pp. 50–60, 2012.

Page 83: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

71

[44] S. Shekarpour, A. N. Ngomo, D. Gerber, and C. Stadler, “Keyword-driven

SPARQL-Query Generation Leveraging Background Knowledge.”

[45] E. Kaufmann, A. Bernstein, and R. Zumstein, “Querix: A Natural Language

Interface to Query Ontologies Based on Clarification Dialogs,” 5th ISWC, no.

November, pp. 980–981, 2006.

[46] V. Lopez, V. Uren, E. Motta, and M. Pasin, “AquaLog: An ontology-driven

question answering system for organizational semantic intranets,” Web

Semant., vol. 5, pp. 72–105, 2007.

[47] C. Wang, M. Xiong, Q. Zhou, and Y. Yu, “PANTO: A Portable Natural

Language Interface to Ontologies,” Eswc, vol. 4519, pp. 473–487, 2007.

[48] A. W. AbuTaha, “An Ontology-Based Arabic Question Answering System,”

Islamic University-Gaza, 2015.

[49] and H. H. F. Mohammed, Khaled Nasser, “A knowledge based Arabic

question answering system (AQAS),” ACM SIGART Bull., vol. 4, pp. 21–30,

1993.

[50] P. Rosso, Y. Benajiba, and a Lyhyaoui, “Towards an Arabic Question

Answering system,” Proc. 4th Conf. Sci. …, 2006.

[51] O. Trigui, L. H. Belguith, and P. Rosso, “DefArabicQA : Arabic Definition

Question Answering System,” 2004.

[52] I. M. AlAgha, “Ontology Dataset,” 2014. [Online]. Available:

https://code.google.com/p/ar2sparql/.

[53] H. and E. H. H. Dalianis, “Aggregation in natural language generation,” Nat.

Lang. Gener. an artificial Intell. Perspect., pp. 88–105, 1996.

Page 84: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

72

Appendix A: OWL Source Code: <?xml version="1.0"?> <!DOCTYPE rdf:RDF [ <!ENTITY owl "http://www.w3.org/2002/07/owl#" > <!ENTITY xsd "http://www.w3.org/2001/XMLSchema#" > <!ENTITY rdfs "http://www.w3.org/2000/01/rdf-schema#" > <!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#" > ]> <rdf:RDF xmlns="http://www.iugaza.edu.ps/ar2sparql#" xml:base="http://www.iugaza.edu.ps/ar2sparql" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:owl="http://www.w3.org/2002/07/owl#" xmlns:xsd="http://www.w3.org/2001/XMLSchema#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"> <owl:Ontology rdf:about="http://www.iugaza.edu.ps/ar2sparql"/> <!-- /////////////////////////////////////////////////////////////////////////////////////// // // Object Properties // /////////////////////////////////////////////////////////////////////////////////////// --> <!-- http://www.iugaza.edu.ps/ar2sparql#Diagnose --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#Diagnose"> <rdfs:label>يشخصه</rdfs:label> <owl:inverseOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnose"/> </owl:ObjectProperty>

Page 85: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

73

<!-- http://www.iugaza.edu.ps/ar2sparql#caused_by --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#caused_by"> <rdf:type rdf:resource="&owl;TransitiveProperty"/> <rdfs:label>يسببه</rdfs:label> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#causes --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#causes"> <rdf:type rdf:resource="&owl;TransitiveProperty"/> <rdfs:label>يسبب</rdfs:label> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <owl:inverseOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#caused_by"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#cure_for --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#cure_for"> <rdfs:label> ل عالج </rdfs:label> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#cured_by --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#cured_by"> <rdfs:label> ب يعالج </rdfs:label> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <owl:inverseOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cure_for"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#has_symptom --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#has_symptom"> <rdfs:label>عرضه</rdfs:label> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#infected_by -->

Page 86: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

74

<owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#infected_by"> <rdfs:label> ب يصاب </rdfs:label> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#infects --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#infects"> <rdfs:label>يصيب</rdfs:label> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <owl:inverseOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#infected_by"/> </owl:ObjectProperty> <!-- http://www.iugaza.edu.ps/ar2sparql#symptom_of --> <owl:ObjectProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#symptom_of"> <rdfs:label> ل عرض </rdfs:label> <rdfs:range rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:domain rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <owl:inverseOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#has_symptom"/> </owl:ObjectProperty> <!-- /////////////////////////////////////////////////////////////////////////////////////// // // Data properties // /////////////////////////////////////////////////////////////////////////////////////// --> <!-- http://www.iugaza.edu.ps/ar2sparql#description --> <owl:DatatypeProperty rdf:about="http://www.iugaza.edu.ps/ar2sparql#description"/> <!-- /////////////////////////////////////////////////////////////////////////////////////// // // Classes // /////////////////////////////////////////////////////////////////////////////////////// -->

Page 87: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

75

<!-- http://www.iugaza.edu.ps/ar2sparql#Cure --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Cure"> <rdfs:label>عالج</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Diagnosis --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"> <rdfs:label>تشخيص</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Disease"> <rdfs:label>مرض</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Heart_Disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Heart_Disease"> <rdfs:label> القلب مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Organ --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Organ"> <rdfs:label>عضو</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"> <rdfs:label> الطفيلي مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#infectious_agent"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#Skin_Disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Skin_Disease"> <rdfs:label> جلدي مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:Class>

Page 88: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

76

<!-- http://www.iugaza.edu.ps/ar2sparql#Symptom --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#Symptom"> <rdfs:label>عرض</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#bacterial_disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"> <rdfs:label> البكتيري مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#infectious_agent"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#blood_test --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#blood_test"> <rdfs:label> دم فحص </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#cause --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#cause"> <rdfs:label>سبب</rdfs:label> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#digestive --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#digestive"> <rdfs:label>هضمي</rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#drug --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#drug"> <rdfs:label>دواء</rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#genetic -->

Page 89: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

77

<owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#genetic"> <rdfs:label> جيني مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#heart_surgery --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#heart_surgery"> <rdfs:label> القلب جراحة </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#surgery"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#infectious_agent --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#infectious_agent"> <rdfs:label> معدي مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#mental --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#mental"> <rdfs:label> النفسي مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#physiotherapy --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#physiotherapy"> <rdfs:label> طبيعي عالج </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#respiratory --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#respiratory"> <rdfs:label> سيتنف </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#surgery --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#surgery"> <rdfs:label>جراحة</rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> </owl:Class>

Page 90: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

78

<!-- http://www.iugaza.edu.ps/ar2sparql#urinary --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#urinary"> <rdfs:label>بولي</rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> </owl:Class> <!-- http://www.iugaza.edu.ps/ar2sparql#viral_disease --> <owl:Class rdf:about="http://www.iugaza.edu.ps/ar2sparql#viral_disease"> <rdfs:label> الفيروسي مرض </rdfs:label> <rdfs:subClassOf rdf:resource="http://www.iugaza.edu.ps/ar2sparql#infectious_agent"/> </owl:Class> <!-- /////////////////////////////////////////////////////////////////////////////////////// // // Individuals // /////////////////////////////////////////////////////////////////////////////////////// --> <!-- http://www.iugaza.edu.ps/ar2sparql#AIDS --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#AIDS"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label>اإليدز</rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Body_aches"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diarrhea"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Fatigue"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Fever"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Nausea"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Abortion --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Abortion"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label>االجهاض</rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mifepristone"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Acne -->

Page 91: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

79

<owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Acne"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> الشباب حب </rdfs:label> <cured_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Flagyl"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Angelman_syndrome --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Angelman_syndrome"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> انجلمان متالزمة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Antibiotic --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Antibiotic"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> <rdfs:label> حيوي مضاد </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Autism --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Autism"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mental"/> <rdfs:label>التوحد</rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#communication_problems"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Back_pain --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Back_pain"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الظهر ألم </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Blood_analysis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Blood_analysis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> دم تحليل </rdfs:label> </owl:NamedIndividual>

Page 92: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

80

<!-- http://www.iugaza.edu.ps/ar2sparql#Body_aches --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Body_aches"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الجسم آالم </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#C-Reactive_Protein --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#C-Reactive_Protein"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> التفاعلي سي بروتين </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#CBC --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#CBC"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> سي بي سي </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#blood_cancer"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#CT --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#CT"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> تي سي </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Chills --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Chills"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>قشعريرة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Cholera --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Cholera"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>الكوليرا</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Color_blindness -->

Page 93: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

81

<owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Color_blindness"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> اناأللو عمي </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#color_points"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Coma --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Coma"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الغيبوبة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Conduct_Disorder --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Conduct_Disorder"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mental"/> <rdfs:label> السلوك اضطراب </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Cough --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Cough"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>كحة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Creatinine --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Creatinine"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>كرياتينين</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Crohn --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Crohn"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label>كرون</rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diarrhea"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#small_intestine"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#vomiting"/> </owl:NamedIndividual>

Page 94: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

82

<!-- http://www.iugaza.edu.ps/ar2sparql#Dehydration --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Dehydration"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الجفاف</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Depression --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Depression"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mental"/> <rdfs:label>االكتئاب</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Diabetes --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Diabetes"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label>السكري</rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Body_aches"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Fatigue"/> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Lack_of_insulin"/> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#high_temperature"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#pancreas"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#thirst"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Diarrhea --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Diarrhea"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>اإلسهال</rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Myiasis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Difficult_swallowing --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Difficult_swallowing"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> البلع صعوبة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Down_syndrome --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Down_syndrome">

Page 95: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

83

<rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> داون متالزمة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Endoscopy --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Endoscopy"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> الطبي المنظار </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Enuresis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Enuresis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mental"/> <rdfs:label> الالإرادي التبول </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Fatigue --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Fatigue"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>إرهاق</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Fever --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Fever"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الحمى</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Fibrinogen --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Fibrinogen"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>الفيبرينوجين</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Flagyl --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Flagyl"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Cure"/> <rdfs:label>فالجيل</rdfs:label> <cure_for rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Acne"/> </owl:NamedIndividual>

Page 96: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

84

<!-- http://www.iugaza.edu.ps/ar2sparql#Genetic_factor --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Genetic_factor"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label> الورائي العامل </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Psoriasis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Glucose --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Glucose"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>جلوكوز</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Gonorrhea --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Gonorrhea"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>السيالن</rdfs:label> <rdfs:label xml:lang="ar">السيالن</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#HDL --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#HDL"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> الكثافة عالي الدهني البروتين </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Headache --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Headache"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الصداع</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Helminthiasis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Helminthiasis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"/> <rdfs:label> الطفيلية الديدان </rdfs:label> </owl:NamedIndividual>

Page 97: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

85

<!-- http://www.iugaza.edu.ps/ar2sparql#Hemoglobin --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Hemoglobin"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>هيموجلوبين</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Hepatitis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Hepatitis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label> الوبائي الكبد إلتهاب </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Indigestion"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#liver"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Indigestion --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Indigestion"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الهضم عسر </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Infection --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Infection"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label>العدوى</rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Rubella"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Influenza --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Influenza"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label>إنفلونزا</rdfs:label> <cured_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Antibiotic"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Sore_throat"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Trachea"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Klinefelter_syndrome --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Klinefelter_syndrome"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> كالينفلتر متالزمة </rdfs:label>

Page 98: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

86

</owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#LDL --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#LDL"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> الكثافة منخفض الدهني البروتين </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Lack_of_insulin --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Lack_of_insulin"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label> األنسولين نقص </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diabetes"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Lever_function --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Lever_function"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> الكبد وظائف </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Lung_Cancer --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Lung_Cancer"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> الرئة سرطان </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Endoscopy"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Lupus --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Lupus"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> ئبةالذ </rdfs:label> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Malaria --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Malaria"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"/> <rdfs:label>المالريا</rdfs:label> </owl:NamedIndividual>

Page 99: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

87

<!-- http://www.iugaza.edu.ps/ar2sparql#Measles --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Measles"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label>الحصبة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#MelaFind --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#MelaFind"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>المالفايند</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Mumps --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Mumps"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label>النكاف</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Muscle_cramps --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Muscle_cramps"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> عضلية تقلصات </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cardiomyopathy"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Myiasis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Myiasis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"/> <rdfs:label>النغف</rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diarrhea"/> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_larvae"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#stomach_pain"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Nausea --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Nausea"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>غثيان</rdfs:label> </owl:NamedIndividual>

Page 100: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

88

<!-- http://www.iugaza.edu.ps/ar2sparql#Neck_pain --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Neck_pain"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الرقبة ألم </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Paracetamol --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Paracetamol"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#drug"/> <rdfs:label>باراسيتامول</rdfs:label> <cure_for rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Smallpox"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Parasitic_larvae --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Parasitic_larvae"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label> طفيلية يرقات </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Myiasis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Pediculosis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Pediculosis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"/> <rdfs:label>القمل</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Plague --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Plague"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>الطاعون</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Pneumonia --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Pneumonia"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label> الرئة إلتهاب </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#CT"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#lung"/>

Page 101: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

89

</owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Poly_Cystic_Ovaries --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Poly_Cystic_Ovaries"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> المبايض تكيس تالزمةم </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Polycystic_kidney --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Polycystic_kidney"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> المتكيسة الكلية </rdfs:label> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Fatigue"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Fever"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#itching"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#thirst"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Prostate-Specific_Antigen --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Prostate-Specific_Antigen"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> محددة البروستات مستضد </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Psoriasis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Psoriasis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label>صدفية</rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Genetic_factor"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#itching"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Rabies --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Rabies"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label> الكلب داء </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Indigestion"/> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#high_temperature"/> </owl:NamedIndividual>

Page 102: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

90

<!-- http://www.iugaza.edu.ps/ar2sparql#Rubella --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Rubella"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label> األلمانية الحصبة </rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Infection"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Running_nose --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Running_nose"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> األنف سيالن </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Salmonellae --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Salmonellae"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label>السالمونيال</rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Typhoid"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Scabies --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Scabies"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Parasitic_Disease"/> <rdfs:label>الجرب</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Schizophrenia --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Schizophrenia"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#mental"/> <rdfs:label>الفصام</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Sexual_relation --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Sexual_relation"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label> الجنسية العالقة </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Syphilis"/> </owl:NamedIndividual>

Page 103: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

91

<!-- http://www.iugaza.edu.ps/ar2sparql#Shock --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Shock"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الصدمة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Skin --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Skin"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الجلد</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Acne"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Pediculosis"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Psoriasis"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Scabies"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin_Cancer"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Smallpox"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Vitiligo"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#rash"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Skin_Cancer --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Skin_Cancer"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> الجلد سرطان </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#MelaFind"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Smallpox --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Smallpox"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label>جدري</rdfs:label> <cured_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Paracetamol"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Smoking --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Smoking"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label>التدخين</rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Lung_Cancer"/> </owl:NamedIndividual>

Page 104: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

92

<!-- http://www.iugaza.edu.ps/ar2sparql#Sodium_Level --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Sodium_Level"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> الصوديوم مستوى </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Sore_throat --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Sore_throat"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الحلق احتقان </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Stomach --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Stomach"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>المعدة</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#stomach_pain"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Syphilis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Syphilis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>الزهري</rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Sexual_relation"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Testosterone --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Testosterone"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> التستوستيرون هرمون </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Poly_Cystic_Ovaries"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Tetanus --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Tetanus"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>الكزاز</rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Blood_analysis"/> </owl:NamedIndividual>

Page 105: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

93

<!-- http://www.iugaza.edu.ps/ar2sparql#Thyroid_Stimulating_Hormone --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Thyroid_Stimulating_Hormone"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> ةالدرقي الغدة تنشيط هرمون </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Trachea --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Trachea"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label> الهوائية القصبة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Tuberculosis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Tuberculosis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>السل</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Turner_syndrome --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Turner_syndrome"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> تيرنر متالزمة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Typhoid --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Typhoid"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label>تيفوئيد</rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Salmonellae"/> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Urine_anlysis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Urea --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Urea"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label>يوريا</rdfs:label> </owl:NamedIndividual>

Page 106: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

94

<!-- http://www.iugaza.edu.ps/ar2sparql#Urine_anlysis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Urine_anlysis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> البول تحليل </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Vision_loss --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Vision_loss"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> البصر فقدان </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#Vitiligo --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#Vitiligo"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label>البهاق</rdfs:label> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Skin"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#abdominal_cramps --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#abdominal_cramps"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> معوية تقلصات </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#anthrax --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#anthrax"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#bacterial_disease"/> <rdfs:label> الخبيثة الجمرة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#arrhythmias --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#arrhythmias"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> القلب ضربات انتظام عدم </rdfs:label> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#heart"/> </owl:NamedIndividual>

Page 107: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

95

<!-- http://www.iugaza.edu.ps/ar2sparql#blood --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#blood"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الدم</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#blood_cancer"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#blood_cancer --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#blood_cancer"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> الدم سرطان </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Blood_analysis"/> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#arrhythmias"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#blood"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#high_blood_pressure"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#blurred_vision --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#blurred_vision"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الرؤية وضوح عدم </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#cardiomyopathy --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#cardiomyopathy"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> القلب عضلة اعتالل </rdfs:label> <caused_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Muscle_cramps"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#heart"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#cardiovascular --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#cardiovascular"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Disease"/> <rdfs:label> ائيوع قلبي مرض </rdfs:label> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#heart"/> <has_symptom rdf:resource="http://www.iugaza.edu.ps/ar2sparql#high_blood_pressure"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#color_points -->

Page 108: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

96

<owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#color_points"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diagnosis"/> <rdfs:label> مختلفة الوان تقاط </rdfs:label> <Diagnose rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Color_blindness"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#communication_problems --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#communication_problems"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> التواصل مشاكل </rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Autism"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#constipation --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#constipation"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>اإلمساك</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#delayed_speech_development --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#delayed_speech_development"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الكالم تطور تأخر </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#esophagus --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#esophagus"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>المريء</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#fauces --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#fauces"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الحلق</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#heart -->

Page 109: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

97

<owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#heart"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>القلب</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#arrhythmias"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cardiomyopathy"/> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cardiovascular"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#high_blood_pressure --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#high_blood_pressure"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الدم ضغط ارتفاع </rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cardiovascular"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#high_temperature --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#high_temperature"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#cause"/> <rdfs:label> الحرارة درجة ارتفاع </rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diabetes"/> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Rubella"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#itching --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#itching"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>الحكة</rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Psoriasis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#kidney --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#kidney"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الكلية</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#large_intestine --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#large_intestine"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/>

Page 110: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

98

<rdfs:label> الغليظة األمعاء </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#larynx --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#larynx"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>حنجرة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#liver --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#liver"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الكبد</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Hepatitis"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#loss_of_appetite --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#loss_of_appetite"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الشهية فقدان </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#lung --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#lung"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الرئة</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Pneumonia"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#mifepristone --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#mifepristone"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#drug"/> <rdfs:label>الميفيبريستون</rdfs:label> <causes rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Abortion"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#mouth --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#mouth"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/>

Page 111: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

99

<rdfs:label>الفم</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#open_heart_surgery --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#open_heart_surgery"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#heart_surgery"/> <rdfs:label> مفتوح قلب جراحة </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#pancreas --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#pancreas"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>بنكرياس</rdfs:label> <infected_by rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diabetes"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#pharynx --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#pharynx"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>البلعوم</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#poliomyelitis --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#poliomyelitis"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#viral_disease"/> <rdfs:label> األطفال شلل </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#rash --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#rash"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> جلدي طفح </rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#small_intestine --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#small_intestine"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label> الدقيقة األمعاء </rdfs:label> </owl:NamedIndividual>

Page 112: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

100

<!-- http://www.iugaza.edu.ps/ar2sparql#stomach_pain --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#stomach_pain"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> المعدة ألم </rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Myiasis"/> <infects rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Stomach"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#thirst --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#thirst"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>العطش</rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Diabetes"/> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#ureters --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#ureters"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>الحالب</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#urinary_bladder --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#urinary_bladder"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Organ"/> <rdfs:label>المثانة</rdfs:label> </owl:NamedIndividual> <!-- http://www.iugaza.edu.ps/ar2sparql#vomiting --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#vomiting"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label>القيئ</rdfs:label> <symptom_of rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Myiasis"/> </owl:NamedIndividual> - <!-- http://www.iugaza.edu.ps/ar2sparql#weight_loss --> <owl:NamedIndividual rdf:about="http://www.iugaza.edu.ps/ar2sparql#weight_loss"> <rdf:type rdf:resource="http://www.iugaza.edu.ps/ar2sparql#Symptom"/> <rdfs:label> الوزن فقدان </rdfs:label>

Page 113: SPARQL2AL: Translating SPARQL - غزةlibrary.iugaza.edu.ps/thesis/117030.pdf · SPARQL2AL: Translating SPARQL Queries to Arabic Language Submitted By: Omar Salah El-Radie 120120756

101

</owl:NamedIndividual> </rdf:RDF> <!-- Generated by the OWL API (version 3.5.0) http://owlapi.sourceforge.net -->