EmbodimentLanguageComprehension Classifier

From OpenCog
Jump to: navigation, search


THIS PAGE IS OBSOLETE

<< back

Classifier

This is the first step of the answering question process. Classifier is a module responsible for receiving the Relex input and determine the type of the question that was sent to the agent. Given the type of the question the agent will use different strategies to reasoning about it and then answer it.

Basically this module can classify two types of questions: about actions and about states. Questions about actions require that the agent know what is happening with the target of the question to answer it. Questions about states require that the agent know the characteristics of the question target object in order to answer it. Besides that, it will handle just two categories of questions: truth and W/H-questions. Truth, or yes/no, questions is simply answered with yes or no. OTOH W/H questions requires a more elaborate answer. Lets take a look at some examples.

Example of a truth and W/H questions and the Relex Frame output:

Are you angry?
Questioning:Message = angry
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = #you
// payload frames
Emotion_directed:Experiencer = #you
Emotion_directed:State = angry

Are you hungry?
Questioning:Message = hungry
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = #you
// payload frames
Biological_urge:Experiencer = #you
Biological_urge:State = hungry

Is that your best?
Questioning:Message = best
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = #you
// payload frames
Evaluative_comparison:Degree = best
Evaluative_comparison:Profiled_item = that
Evaluative_comparison:Standard_item = $qVar

Is the ball near the fountain? or Is the ball next to the fountain?
Questioning:Message = ball
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = ball
// payload frames
Locative_relation:Ground = fountain
Locative_relation:Figure = ball
Locative_relation:Relation_type = near

Is the blue ball near the fountain? or Is the blue ball next to the fountain?
Questioning:Message = ball
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = ball
// payload frames
Locative_relation:Ground = fountain
Locative_relation:Figure = ball
Locative_relation:Relation_type = near
Color:Color = blue
Color:Entity = ball

Is the ball blue?
Questioning:Message = blue
Questioning:Manner = truth-query
Questioning:Addressee = #you
Entity:Entity = ball
// payload frames
Color:Color = blue
Color:Entity = ball

While processing yes/no questions, some special cases can be handled by specific routines, but in most cases an algorithm must capture the frame instances that composes the question payload and try to find predicates or other Frames structures that matches them into the AtomTable. However a simple Pattern Match will not suffice, because the incoming Frames instances contains WordInstanceNodes in its elements and the Frames stored into the AtomTables has SemeNodes, as its elements values. Thus, a question resolution process will must be built to match the incoming frames with the stored frames. But this will be discussed in the Reasoner module.


What, Why, When, Who, Where, How, How many, How much:

What are you doing now? <- action question
Questioning:Message = doing
Questioning:Manner = what
Questioning:Addressee = #you
Entity:Entity = #you
Intentional_act:Agent = #you
Intentional_act:Act = $qVar
Intentional_act:Time = now <- (now, before, after)

What is near the fountain?
Questioning:Message = $qVar
Questioning:Manner = what
Questioning:Addressee = #you
Entity:Entity = $qVar
Locative_relation:Ground = fountain
Locative_relation:Figure = $qVar
Locative_relation:Relation_type = near

What is an instrument? <- state question is-a
Questioning:Message = instrument
Questioning:Manner = what
Questioning:Addressee = #you
Entity:Entity = instrument
Entity:Type = $qVar <- indicates what subtype of the general category the Entity belongs to

What color is the ball?
Questioning:Message = $qVar
Questioning:Manner = what
Questioning:Addressee = #you
Color:Color = $qVar
Color:Entity = ball

What is the color of the ball?
//Not working. Relex did not create interesting output for that....


Why your eyes are red?
Questioning:Message = eyes
Questioning:Manner = why
Questioning:Addressee = #you
Causation:Actor = eyes
Causation:Effect = red
Causation:Reason = $qVar
Causation:Means = are
// payload frames
State:Entity = eyes
State:State = red
Color:Color = red
Color:Entity = eyes
Possession:Owner = #you
Possession:Possession = eyes

When the train will arrive at the station?
Questioning:Message = train
Questioning:Manner = when
Questioning:Addressee = #you
Temporal_colocation:Time = $qVar
Temporal_colocation:Event = arrive
Temporal_colocation:Entity = train
Temporal_colocation:Landmark = station

Who is the man in black?
Questioning:Message = man
Questioning:Manner = who
Questioning:Addressee = #you
People:Person = $qVar
People:Descriptor = color <- resulted by 'in black'
Entity:Entity = man
// payload frames
Color:Entity = man
Color:Color = black

Where is your girlfriend?
Questioning:Message = girlfriend
Questioning:Manner = where
Questioning:Addressee = #you
Locative_relation:Ground = $qVar
Locative_relation:Figure = girlfriend
Locative_relation:Relation_type = $qVar1
// payload frames
Possessive:Possession = girlfriend
Possessive:Owner = #you

Where is the blue ball?


How can you dare with it?
Questioning:Message = dare
Questioning:Manner = how
Questioning:Addressee = #you
Means:Descriptor = $qVar
Means:Agent = #you
Means:Means = dare
Purpose:Agent = #you
Purpose:Goal = it
Purpose:Means = dare

How many questions do you have to me?
Questioning:Message = questions
Questioning:Manner = how_many
Questioning:Addressee = #you
Quantity:Individuals = questions
Quantity:Q_Prop = many
Quantity:Quantity = $qVar

How much money do you have?
Questioning:Message = money
Questioning:Manner = how_much
Questioning:Addressee = #you
Quantity:Individuals = money
Quantity:Q_Prop = much
Quantity:Quantity = $qVar

Note that the frames above the '// payload frames' mark are mandatory and those that comes bellow represents the characteristics of the specific given question.

A step of reference resolution will be needed to solve all nouns and pronouns dependencies, before starting processing the question.