Differences between version 5 and previous revision of Infomer.
Other diffs: Previous Major Revision, Previous Author, or view the Annotated Edit History
Newer page: | version 5 | Last edited on Friday, December 20, 2002 12:27:40 am | by PerryLorier | Revert |
Older page: | version 4 | Last edited on Friday, December 20, 2002 12:16:05 am | by PerryLorier | Revert |
@@ -38,9 +38,8 @@
# Now with the target out of the way, begin stripping prefixes and conjunctions etc.
delims = [["?", ".", "and", ","]
- pronouns = [["your"]
for d in delims:
line = string.replace(line, d, ".")
@@ -59,11 +58,8 @@
ntext = string.join(words, " ")
- if target != None:
- for p in pronouns:
- string.replace(ntext, p, target + "'s")
parse_sentence(who, target, ntext)
!!Parse_sentance
This function's job is to take a sentance and clean it up, replacing "you" with "Isomer is", removing little words, and rearranging any sentances to make more sense to the bot. For example this function should be able to take: