-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding equative type sentences #149
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -906,6 +906,53 @@ public boolean test_comparatives() | |
report(rc, "Comparatives"); | ||
return rc; | ||
} | ||
|
||
public boolean test_equatives() | ||
{ | ||
boolean rc = true; | ||
//Equative:two entities one feature | ||
rc &= test_sentence ("Amen's hair is as long as Ben's.", | ||
"_poss(hair, Amen)\n"+ | ||
"_predadj(hair, long)\n"+ | ||
"_as(long, hair)\n"+ | ||
"_than(Amen, Ben)\n"); | ||
|
||
rc &= test_sentence ("Amen’s hair is same as Ben’s.", | ||
"_poss(hair, Amen)\n"+ | ||
"_predadj(hair, same)\n"+ | ||
"_as(same, hair)\n"+ | ||
"_than(Amen, Ben)\n"); | ||
|
||
rc &= test_sentence ("Jack’s hair color is similar to that of Ben’s.", | ||
"_poss(color, Jack)\n"+ | ||
"_nn(color, hair)\n"+ | ||
"_predadj(color, similar)\n"+ | ||
"of(that, Ben)\n"+ | ||
"to(similar, that)\n"+ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. is this of(that, Ben) and to(similar, that) correct and needed? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about the sentence "Jack’s hair color is similar to Ben's" ? |
||
"_as(similar, color)\n"+ | ||
"_than(Jack, Ben)\n"); | ||
|
||
rc &= test_sentence ("Jack is as intelligent as Ben.", | ||
"_predadj(Jack, intelligent)\n"+ | ||
"_as(intelligent, Jack)\n"+ | ||
"_than(Jack, Ben)\n"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If you want to keep consistence with the normal comparative representations, it should be like:
but I guess this is too deep for RelEx... So I think we can use:
|
||
|
||
rc &= test_sentence ("The book’s color is same as that of the pen’s.", | ||
"_poss(color, book)\n"+ | ||
"_predadj(color, same)\n"+ | ||
"of(that, pen)\n"+ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. also this one? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Its does seem a bit awkward, but I don't see a lot of choices ... maybe @ruiting has something to say. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. First, I think the sentence should be "The book's is the same as that of the pen's.", right?
|
||
"_as(same, color)\n"+ | ||
"_than(book, pen)\n"); | ||
|
||
rc &= test_sentence ("The snail is running exactly as fast as the cheetah.", | ||
"_predadj(snail, run)\n"+ | ||
"_as(fast, run)\n"+ | ||
"_advmod(fast, exactly)\n"+ | ||
"_than(snail, cheetah)\n"); | ||
|
||
report(rc, "Equatives"); | ||
return rc; | ||
} | ||
|
||
public boolean test_conjunctions() | ||
{ | ||
|
@@ -1145,6 +1192,7 @@ public void runTests() { | |
|
||
rc &= ts.test_determiners(); | ||
rc &= ts.test_comparatives(); | ||
rc &= ts.test_equatives(); | ||
rc &= ts.test_extraposition(); | ||
rc &= ts.test_conjunctions(); | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ruiting @linas is "_as(long, hair)" should be "_as(long, Ben)"?
coz dependencies comes as below right?
prep(long, as)
pobj(as, Ben)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand why it should be _as(long, Ben)? So first, the head of comparison entity is "hair" instead of "Ben". Second, if we want to keep all the comparatives representations consistent, we should use: