I am wondering if there is something like hair or fiber tickling or irritating the back of her throat. If this is the case, you might see her periodically swallowing hard or try to clear her throat the way you might do if you had some post-nasal drip or a little "tickle" that you wish you could dislodge.
If it is related to her stomach itself--like something that causes her to wish she could vomit--then you might see her get a strange look on her face first, pulling the corners of her lips back a little first, and then do that weird breathing that dogs do before they vomit, followed by the retching stomach movements prior to the attempt to spit something up.
If you could let me know which one (of these two) it sounds/looks like, or tell me whether it sounds/looks like something else, I will write back with more specific suggestions. I will wait for your response.
Here's something very simple to try first, before you really worry--First, Take a piece of bread (for her size, probably 1/4 of a slice), moisten it slightly and form it into a mini-ball. Actually, make 2 or 3 of these. Then push them down her throat, one at a time, as if it is a pill. It may make her gag a little, but that's OK. As long as it is not so big she can't breathe, she won't choke, since bread is not solid. If there is a little fiber or hair in the back of her throat, the bread-ball will probably carry it down to her stomach. You could also look down the back of her throat by pushing on the back of her tongue the way a doctor would use a tongue depressor. Dogs don't have a uvula, but you may see an upside down triangle that is the epiglottis. (This covers the larynx when she swallows). You may also see the tonsils--if they look bean-shaped, rather than crescent-shaped, they may be inflamed.
Anyway, if the bread-balls don't help, and she continues to gag for more than another day, she should probably see her vet. That doesn't mean there is something serious going on, but it is best to be sure.
Some other simple things it could be are: irritation from chewing/swallowing rawhides (or pigs ears or Greenies, etc.), tonsillitis, pharyngitis. Occasionally, I have seen this kind of problem caused by an abscess (from a splinter), a piece of stuck plant material, a tumor (benign or malignant) of some sort, or other things. Fortunately, throat cancer in dogs is rare (unlike people), but it's still best to have it checked by your vet, who may even have to sedate her to get an adequate look, if the simple approach does not help.
Please let me know if you have any other questions, or need more help.