Ok, so "Hi a Mhairi." Is "Hi Mairi.". "Hi" is just "Hi" "a" makes "Mairi" vocative, which turns it into "Mhairi" because it's a feminine noun.
"Ciamar a tha d' uan." I think is "How is your lamb"
And I have no idea what "A bheil e a' feithamh ort" means. (Correct me if I'm wrong)
That is pretty good analysis. There are a coupe of points that I hope you will not mind me raising as we are here to learn. One is a very subtle point about how to translate in different situations, and has nothing to do with you analysis of the Gaelic, and the other is a very common misunderstanding caused by the usual way way that lenition is taught – in my view what you have misunderstood is good evidence that the usual teaching needs altered.
Firstly, there has been a lot of discussion about whether you should translate names. The consensus is that you should normally leave Gaelic names as they are, or at most take the accent off, as you have done. But there is a problem here. This whole discussion is based on a nursery rhyme that uses Mary in the original, so I would say that only in this situation you should translate Màiri as Mary.
Secondly, it is commonly taught that 'feminine nouns lenite'. This causes people to lenite feminine nouns, or fail to lenite other words in all sorts of inappropriate places. In the plural is one of the most common errors, and you thinking that it is only happening here because Màiri is feminine is another. In Gaelic it is almost always the previous word that causes the lenition and two of the words that cause lenition are
- the feminine singular definite article (that does not apply here)
- the vocative partice a regardless of number or gender
So here the a is indeed causing the lenition, but it is nothing to do with Mary being a single female. It would apply equally to James (a Sheumais) or all your friends (a chàirdean).
A bheil e a' feithamh ort means 'Is he waiting for you?' For the original story, including evidence that wee girl was called by the English form Mary and that the lamb was male, see here.