Simple rules
This commit is contained in:
parent
798d04eb15
commit
553763793b
10519
dev-0/out.tsv
Normal file
10519
dev-0/out.tsv
Normal file
File diff suppressed because it is too large
Load Diff
21
first_take.py
Normal file
21
first_take.py
Normal file
@ -0,0 +1,21 @@
|
||||
import sys
|
||||
|
||||
|
||||
for line in sys.stdin:
|
||||
_, _, _, _, _, _, l_context, r_context = line.split("\t")
|
||||
|
||||
prev_word = l_context.split()[-1]
|
||||
next_word = r_context.split()[0]
|
||||
|
||||
if prev_word == "United" and next_word == "of":
|
||||
print("States:0.9 :0.1")
|
||||
elif prev_word == "used":
|
||||
print("to:0.5 it:0.3 :0.2")
|
||||
elif prev_word.lower() == "in":
|
||||
print("the:0.7 a:0.1 an:0.1 :0.1")
|
||||
elif prev_word.lower() == "i":
|
||||
print("am:0.3 was:0.3 have:0.3 :0.1")
|
||||
elif prev_word.lower() in ["he", "she", "it"]:
|
||||
print("is:0.3 was:0.3 has:0.3 :0.1")
|
||||
else:
|
||||
print("the:0.5 a:0.2 an:0.2 :0.1")
|
7414
test-A/out.tsv
Normal file
7414
test-A/out.tsv
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user