A Controlled Natural Language Interface for Semantic MediaWiki

23
A Controlled Natural Language Interface for Semantic MediaWiki Jie Bao Rensselaer Polytechnic Institute Paul R. Smart, Nigel R. Shadbolt University of Southampton Dave Braines, Gareth Jones IBM UK ACITA 2009, Sep 23, 2009 University of Maryland

Transcript of A Controlled Natural Language Interface for Semantic MediaWiki

Page 1: A Controlled Natural Language Interface for Semantic MediaWiki

A Controlled Natural Language Interface for Semantic MediaWiki

Jie BaoRensselaer Polytechnic Institute

Paul R. Smart, Nigel R. ShadboltUniversity of Southampton

Dave Braines, Gareth JonesIBM UK

ACITA 2009, Sep 23, 2009 University of Maryland

Page 2: A Controlled Natural Language Interface for Semantic MediaWiki

Motivation

“The timely collection of facts obtained at the tactical (and even the interpersonal level) may help to create better operational decisions at all levels. The goal is to create networks of soldiers who are capable of collecting information within their sphere of influence and who can share this information with other members of the net in a timely fashion.”

---Defense Science Board. 2006 Summer Study on 21st Century Strategic Technology Vectors, Volume II, Critical Capabilities and Enabling Technologies. Office of the Under Secretary of Defense for Acquisition, Technology, and Logistics, Washington, DC, 2006.

2

Page 3: A Controlled Natural Language Interface for Semantic MediaWiki

Motivation

3

Shared Repository

Multinational Planning Teams

Military Platforms

Unmanned Vehicles

Analysts

Intelligent Agents/Assistants

Patrols / Field Reports

Non- MilitaryOrganizations

RemoteSensors

Page 4: A Controlled Natural Language Interface for Semantic MediaWiki

Key Requirements

• Collaboration Support– Can be used by a variety of different types of contributors – Supports cross-platform access

• Ease of Use– Requires least training– Provides simple user interface– Content ease to understand

• “Meaningful” Structure– Enables some automated processing of data (e.g., automated

data propagation)– Enables discovery of “hidden” knowledge from explicitly known

information.

4

Page 5: A Controlled Natural Language Interface for Semantic MediaWiki

Enabling Technologies

5

Semantic Wiki

ControlledNatural

Language

Every A is B …+

Page 6: A Controlled Natural Language Interface for Semantic MediaWiki

Semantic Wiki

Semantic Wiki

Multi-user content creation and editing

Browser-based, Cross-platformeasy to use

Support semantic annotations for automated processing and inference

Page 7: A Controlled Natural Language Interface for Semantic MediaWiki

Semantic MediaWiki (SMW)

• It is the most popular semantic wiki system extending MediaWiki (the Wikipedia’s platform)

7

Mediawiki: What you edit what you see

Page 8: A Controlled Natural Language Interface for Semantic MediaWiki

Semantic MediaWiki

8

SMW: What you edit(Modeling Script)

what you see

typed link (property)

To author knowledge

Page 9: A Controlled Natural Language Interface for Semantic MediaWiki

Semantic MediaWiki

9

SMW: What you edit(Querying Script)

what you see

To retrieve knowledge

Page 10: A Controlled Natural Language Interface for Semantic MediaWiki

Challenges

However, SMW is limited by Expressivity constraints

• No support for the full range of RDF/OWL• E.g., we can’t specify that “capital of” property should always link

a City to a Country (property domain and range)

Usability• Thinking in the “subject-property-object” fashion may not be

ease (as one may think!)• Based on our own experiments with entry-level users.

• Knowledge engineers may find it difficult to understand other’s contributions.

• Users may prefer different languages styles or even different natural languages.

Page 11: A Controlled Natural Language Interface for Semantic MediaWiki

Challenges

However, SMW is limited by Expressivity constraints

• No support for the full range of RDF/OWL• E.g., we can’t specify that “capital of” property should always link

a City to a Country (property domain and range)

Usability• Thinking in the “subject-property-object” fashion may not be

ease (as you may think!)• Based on our own experiments with entry-level users.

• Knowledge engineers may find it difficult to understand other’s contributions.

• Users may prefer different languages styles or even different natural languages.

By extending SMW with an OWL Meta-model

(introduced in details later)

By allowing modeling/representing knowledge using controlled natural language (CNL)

Page 12: A Controlled Natural Language Interface for Semantic MediaWiki

Controlled Natural Language

CNL

Every A is B…

Production of knowledge without using a formal logic.

Potential production and comprehension benefits

Multiple OWL-compliant CNLs are available:e.g. Rabbit, Sydney OWL Syntax, ACE-OWL

Page 13: A Controlled Natural Language Interface for Semantic MediaWiki

Controlled Natural Language

Example (In Rabbit syntax):• The “capital of" relationship can only have a “City" as a

subject.• The "capital of" relationship can only have a “Country"

as an object.

13

Instead of saying (In OWL Abstract Syntax)

ObjectProperty(ex:capital_ofdomain(ex:City) range(ex:Country))

Or (In Description Logics)

∀capital_of.T ⊆City ∀capital_of -.T ⊆ Country

Page 14: A Controlled Natural Language Interface for Semantic MediaWiki

Solution Summary

• Collaboration Support– Natively collaborative for a wiki– Web-based interface accessible from any device that has a

browser.

• Ease of Use– Simplify knowledge input using semi-automatically generated

forms– Multiple OWL-compliant CNLs: e.g. Rabbit (English, Chinese),

ACE-OWL

• “Meaningful” Structure– Meta-model do the translation between OWL and CNL, and

between OWL and SMW scripts– Query and inference supported.

14

Page 15: A Controlled Natural Language Interface for Semantic MediaWiki

Architecture

Wiki Database

Form Editor Interface CNL Interface CNL Editing

InterfaceRDF Export

Interface

RDF Model

RDF Import Semantic Query Interface

RDF Export

CNLGModule

SELECT ?xWHERE{

?x rdf:typeowl:Class}

Prototype system: http://tw.rpi.edu/proj/cnl

Page 16: A Controlled Natural Language Interface for Semantic MediaWiki

Class(Rabbit partial intersectionOf(animalrestriction(eat someValuesFrom(FreshVegetable)))

OWL: “Rabbit eats some fresh vegetable”

SMW OWL Meta Model

Us wiki templates to create OWL meta-model extensions for SMW

Form-based editing interface associated with templates

1

3 2

Page 17: A Controlled Natural Language Interface for Semantic MediaWiki

OWL Class Templates

17

Similarly, we have templates for properties and individuals

Page 18: A Controlled Natural Language Interface for Semantic MediaWiki

CNL Generation

{{#vardefine:label|{{CNL.getLabel|{{{1}}} }} }} {{#vardefine:super |

{{#ask: [[:{{{1|{{FULLPAGENAME}}}}}]] |?Category= |mainlabel=-|format=list|link=none }}

}}

{{#if: {{#var:super}} |{{#arraymap:{{#var:super}}|,|xxx|<li>Every[[:{{{1}}}{{!}}{{#var:label}}]] is a kind of

[[:xxx|{{CNL.getLabel|xxx}}]] }}|}}

Use SMW queries to retrieve knowledge statements in the OWL meta model

Construct sentences according to the syntax of the target CNL

Page 19: A Controlled Natural Language Interface for Semantic MediaWiki

Multiple CNL Support

Accommodating new CNLs requires relatively minor changes to the wiki script

Page 20: A Controlled Natural Language Interface for Semantic MediaWiki

I/O Support

• Allows importing of an RDF/OWL ontology• Exporting in three CNL syntaxes• Ontology in the meta-model can be exported in

RDF.

• Some limitations apply– Limitation supports for blank nodes– Datatypes– Ontology management (e.g. imports)

20

Page 21: A Controlled Natural Language Interface for Semantic MediaWiki

Related work

AceWikiDifferences:• underlying wiki system• editing interface• light-weight extensions• support for multiple CNLs• customization of target

CNLs

21

Tobias Kuhn (2008)

Page 22: A Controlled Natural Language Interface for Semantic MediaWiki

Related work

ROO

22

Vania Dimitrova et al. 2008

Differences:• Protégé-based vs. wiki-

based• Rabbit only vs. multiple

CNLs• Formal modeling only vs.

formal+informal modeling

Page 23: A Controlled Natural Language Interface for Semantic MediaWiki

Summary

• We have developed an OWL meta-model extension to SMW to support the representation of OWL ontologies

• We have provided a light-weight form-based interface to support ontology editing

• We have provided an RDF import mechanism to support the import of existing ontologies

• We have developed multiple CNL ‘verbalizers’ to support the serialization of semantic wiki content to CNLs

• Future work:– Improved expressvity– Enable users to create/customize CNL output– Implement wiki-based CNL editing capability

23

http://tw.rpi.edu/proj/cnl/