Skip to content

Commit

Permalink
Merge'
Browse files Browse the repository at this point in the history
  • Loading branch information
DillonOLeary committed Nov 16, 2019
2 parents b30f0a7 + f3bcda5 commit 18797f8
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 1 deletion.
Binary file modified backend/nlp/__pycache__/tokenizer.cpython-37.pyc
Binary file not shown.
27 changes: 26 additions & 1 deletion backend/nlp/bckend_integr_testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,33 @@ def test_accuracy():
test_file.close()


def test_structure():
test_set_claims = os.path.join(CWD_FOLDER, 'testing_set', 'simdiff.txt')
f_claim = open(test_set_claims, 'r', errors='replace')

claims = [line for line in f_claim]
f_claim.close()


test_set_links = os.path.join(CWD_FOLDER, 'testing_set', 'simdiffsents.txt')
f_text = open(test_set_links, 'r', errors='replace')

text = [line for line in f_text]
f_text.close()

predict = []
for x in range(len(claims)):

predict.append(nlp.predict(claims[x], text[x], 1))

for x in range(len(claims)):
print(text[x])
print(predict[x])


if "__main__":
test_controller()
test_accuracy()
#test_accuracy()
#test_structure()


8 changes: 8 additions & 0 deletions backend/nlp/testing_set/simdiff.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
cat ate mouse
I like cats
Parrots are a type of pet
A horse a horse my kingdom for a horse
yes yes yes
Vilian, I have done thy mother
You know him better than I
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
8 changes: 8 additions & 0 deletions backend/nlp/testing_set/simdiffsents.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
mouse ate cat food
I dislike cats
Fish like hand types of pets
A cow a cow my kingdom for no cow
no no no
Villian, your father is wonderful
You know him better than me
eight eight color sit amen, constructor phisphing lite, did do sigmoid tempest incidient it labors it colour magna aqua.

0 comments on commit 18797f8

Please sign in to comment.