Here's a concept. Create a GENDER variable. Have the variable set so that a value of 1 will signify male and a value of 2 will signify female.
Then, you can just do this:
%%GENDER%=%1%he%%%%GENDER%=%2%she%%%
If you do something like that for all pronouns and such, you can give the player the option to choose the character's sex. Actually, I believe several users (Sindriv, BerkaZerka, etc.) have used this technique.