Monday, February 25, 2019

grammar - When to respond to "you" with "I" or "Me" from sentence context



I'm writing a program that responds to sentences, but I'm running into an issue:




You write: I like that you like me.




Program responds: What do you think makes you like that me like you?



You write: I like that you are my best friend.



Program responds: I also like that me are your best friend .




In simple cases, switching 'you' to 'me' and me to 'you' works fine, but in this case it isn't grammatically correct.




Under what circumstances should 'you' become 'I', and how can I tell from sentence context/wording? Can you think of more cases in which you/me,my/your cant be interchanged?


Answer



Have a look at the first two rows of the table on pronoun case at OWL:



Pronouns as Subjects  Pronouns as Objects  Pronouns that show Possession
I me my (mine)
you you your (yours)


The second-person singular has the same form whether used as a subject (you) or an object (you). The first-person singular has different forms—I as subject and me as object.




In mathematical terms, the mapping of these first-person pronouns (I/me) to their second-person equivalents (you/you) is not one-to-one, so there's no inverse that maps the word you back to a single first-person pronoun.



To answer your question, there will be endless cases where you would need to be replaced with I (subjective case) and endless cases where you would need to be replaced with me (objective case). The context you need is the case of the pronoun you. I have no experience trying to algorithmically parse natural language at this level, but I gather it's not trivial.



Bear in mind that you can also be plural, so you may need to consider we/us (first-person plural) in addition to I/me.


No comments:

Post a Comment