Home > Archive > Prolog > November 2005 > Making a query using a typed questions?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Making a query using a typed questions?
|
|
| psing008@gmail.com 2005-11-02, 6:58 pm |
| I have an assignment in school.
I need to do several operation on a huge family tree. Like, getting the
father of X, grand-mother of Y...
I don't have a problem with that part.
Here's what I don't get:
The user can only ask a question by asking a typed question. For
instance, I can't type "father(X,Mary)". Instead, I need to type "Who
is the father of Mary?" and then the anwser should appear.
There's 3 types of questions and they don't change, so I don't need a
complete parser. Also, I'm assuming if you know one, you can do the
other.
Thanks.
| |
| Torkel Franzen 2005-11-02, 6:58 pm |
| psing008@gmail.com writes:
> The user can only ask a question by asking a typed question. For
> instance, I can't type "father(X,Mary)". Instead, I need to type "Who
> is the father of Mary?" and then the anwser should appear.
You need to introduce suitable operators.
| |
| psing008@gmail.com 2005-11-02, 6:58 pm |
| Hi, I'm sorry I'm not that good in prolog. I don't know what "suitable
operators" are. Could you give me an example?
Torkel Franzen wrote:
>
> You need to introduce suitable operators.
| |
| Nick Wedd 2005-11-02, 6:58 pm |
| Try looking up "operator" in a Prolog manual.
In message <1130963493.542422.171870@z14g2000cwz.googlegroups.com>,
psing008@gmail.com writes
>Hi, I'm sorry I'm not that good in prolog. I don't know what "suitable
>operators" are. Could you give me an example?
>
>
>
>Torkel Franzen wrote:
>
--
Nick Wedd nick@maproom.co.uk
| |
|
| psing008@gmail.com a écrit :
> Hi, I'm sorry I'm not that good in prolog. I don't know what "suitable
> operators" are. Could you give me an example?
>
>
>
> Torkel Franzen wrote:
>
>
>
I think his teacher wants him to write a small dcg which include some
kind of semantic parse in order to get the answer the same way we can
get a syntactic parse. For short wh question like this it's really
doable....
|
|
|
|
|