It's important to understand, incidentally, that the nature of a benefit for Seneca is constituted by the intention of the giving and its effect on the mind, not by the nature of the thing given. Someone who gives small things nobly is giving greater benefit than someone who gives great things ignobly:
This man has given me but little, yet more he could not afford, while what that one has given is much indeed, but he hesitated, he put it off, he grumbled when he gave it, he gave it haughtily, or he proclaimed it aloud, and did it to please others, not to please the person to whom he gave it; he offered it to his own pride, not to me.
Seneca tells a story about the students of Socrates, who were giving him gifts. Each one brought a large gift until Aeschines, who was very poor. Aeschines said to Socrates, "I have nothing to give that is worthy of you; this is the only thing that makes me feel my poverty. I cannot therefore give you anything but myself, such as I am." To which Socrates replied, "You have given a very great gift; I will therefore try to return you to yourself a better man." As Seneca puts it, Aeschines's gift is as if he said, speaking to Fortune, that she had bestowed nothing of hers to give to Socrates, so he would instead give Socrates something that was his very own. It is not what is given that matters, but the spirit in which it is given. In the proper sense, benefits are mental goods.
Benefits are "the chief bond of human society", which is itself a dance of benefits (Seneca uses the dance of the Graces as an example of how the movement of benefit from person to person makes society ordered and beautiful). Ingratitude breaks up the dance, and the purpose of Seneca's work is to lay down rules for giving benefits and being a beneficiary in order to counter the corrosive effect of ingratitude. Seneca is not kidding when he considers ingratitude to be a very great evil; he insists that it is worse for a society than murder, theft, adultery, tyranny, sacrilege, and treachery, because it attacks the very capacity of a society to function at all, and, what is more, it is usually at the root of these things. The murderer, the adulterer, the thief, the tyrant: rarely do you find any one of these whose murder, adultery, theft, or oppression is not made possible by their ingratitude. We should therefore consider it the very worst possible thing in ourselves. At the same time, we should be ready to forgive it in others. Because benefits are mental or spiritual goods, when we benefit someone, we have already gotten all the good out of it. If I give you something out of good will toward you, and you never repay it, I have nonetheless received all the joy of the benefit, which was in the giving; your repayment would be, so to speak, simply a return benefit and a distinct and additional joy. You only benefit others, in a proper sense, if what you give is pleasing to give and is given with an eye to pleasing the other; to benefit someone is its own reward. If, for instance, you can save a decent person simply by raising a shout to save them, and you do, that is itself a thing of joy. No one actually injures you by their ingratitude. (And, although Seneca doesn't dwell on the point, it is sometimes the case that people just assess benefits differently, or don't realize at the time how deeply they are being benefited.) They do, however, injure themselves; and in the long run they injure society.
When receiving benefits, however, we should receive in much the same spirit with which the benefit is best given:
Some men not only give, but even receive benefit haughtily, a mistake into which we ought not to fall: for now let us cross over to the other side of the subject, and consider how men should behave when they receive benefits. Every function which is performed by two persons makes equal demands upon both: after you have considered what a father ought to be, you will perceive that there remains an equal task, that of considering what a son ought to be: a husband has certain duties, but those of a wife are no less important. Each of these give and take equally, and each require a similar rule of life, which, as Hecaton observes, is hard to follow: indeed, it is difficult for us to attain to virtue, or even to anything that comes near virtue: for we ought not only to act virtuously but to do so upon principle. We ought to follow this guide throughout our lives, and to do everything great and small according to its dictates: according as virtue prompts us we ought both to give and to receive.
One way to put it would be to say that we should always receive benefits in such a way as is consistent with the possibility of that gratitude developing into, or furthering, a close friendship of mutual good will. The connection of gratitude to friendship leads Seneca, interestingly, to argue that we should reserve gratitude for virtuous people; this requires the prior effort to avoid owing benefits to people who are not worthy of them. If a benefit is offered to you even by a king who has the character of a pirate, you should do what you can to refuse, and, if it is simply not in your power to refuse, you have no obligation of gratitude arising from it. It's an interesting argument given that Seneca was advisor to the Emperor Nero.
To avoid ingratitude, we should also always count the spirit in which the gift is given rather than what is given. If it is not given in a beneficiary spirit, we have no obligation of gratitude; but if even a very minor thing is given in a deeply generous spirit, we should be highly grateful. Ingratitude is measured by its disproportion to the discernible intention of the one who gave. When we receive we should do so with cheerfulness, and we should make very clear our gratitude, not hesitating to make public to others the generosity and benevolence of the one who gave. Openly dwelling on the joy of the benefit received is what the receiver does that corresponds to the giver's trying to determine what would give the receiver joy, and therefore is necessary for returning the benefit. But the gratitude is possible even if nothing physical can be done in return; merely receiving something in gratitude is not a return gift, any more than merely thinking about how much somebody would enjoy something is a gift. And gratitude is not about repayment itself, as if benefit were an exchange of commodities or a loan; to give is not a contract to receive in return, but is something done for its own sake. And having an attitude of genuine gratitude requires recognizing this. If the grateful person receives some great benefit and can return a similar or greater benefit, he will do so freely as part of his gratitude. This is, remember, a necessary part of benefit, that it is freely given. But to be genuinely grateful you also have to learn how just to receive a good thing even if you can never return a benefit adequate to it. When someone benefits you, in the proper sense, they do so because your joy in it makes them to have joy; the proper grateful response is to rejoice in the gift. The natural tendency to repayment is an expression of that joy. To benefit is to give joy to another for the joy of it; gratitude is the completion of the other person's act of benefiting, by responding with joy.
Jealousy, ambition, and greed are vices that naturally tend to spawn ingratitude; we should firmly reject anything even suggestive of these things in the receiving of a gift; when he talks about the main cause of ingratitude, he says(Book II, sect. 26), "It is caused by excessive self-esteem, by that fault innate in all mortals, of taking a partial view of ourselves and our own acts, by greed, or by jealousy." This self-esteem is perhaps ingrates often complain of the ingratitude of others. Despite its evil and corrosive effect on society, Seneca denies that ingratitude can be sanctioned by law: you can't cultivate gratitude by forcing people to recognize benefits. The reverse side of this is that law and custom should not force people not to benefit others, as they sometimes try to do (e.g., in some laws governing slavery, and Seneca's discussions of the ingratitude involved in Roman slavery are some of his best passages).
Aquinas's account of ingratitude (ST 2-2.107) is largely Senecan in nature. Aquinas sees gratitude as a potential part of justice, which means that it is like actively working for equality in an exchange, which is what justice is, but the exchange has a feature that makes it not quite the same as that. Gratitude deals with moral debts rather than legal debts, which in Aquinas's parlance means that the obligation, although real, is not a strict and well-defined one. It's a debt of love rather than reason, and there is no precise, definite way to repay it. Ingratitude, of course, is gratitude's corresponding vice of defect. It has three degrees, ascending in degrees of severity, which Aquinas derives from a brief comment by Seneca: failing to return a favor when you can, negligence in recognizing a failure received, and treating a kindness as an unkindness. Acts of the third degree of ingratitude are always mortal sins: they are not just failings or deficiencies in virtue, they are utterly inconsistent with it. One difference in Aquinas's view is that Aquinas is much more clear that we should do favors even for the ungrateful, only refusing to do so to those who are consistently and obtusely ungrateful. We should also be very slow to assume that someone is ungrateful. You can find predecessors for these in Seneca, but Aquinas emphasizes them for more for Christian reasons, of course.
The Senecan account of ingratitude also dominates the last major heyday of serious philosophical thought about ingratitude, namely, the Renaissance period. In this period the strong view of ingratitude -- that is one of the worst, and perhaps even the worst, evils in society -- is often called the 'Persian' view in this period, due to a passage in Xenophon's Cyropaedia:
And there is one charge the judges do not hesitate to deal with, a charge which is the source of much hatred among grown men, but which they seldom press in the courts, the charge of ingratitude. The culprit convicted of refusing to repay a debt of kindness when it was fully in his power meets with severe chastisement. They reason that the ungrateful man is the most likely to forget his duty to the gods, to his parents, to his fatherland, and his friends. Shamelessness, they hold, treads close on the heels of ingratitude, and thus ingratitude is the ringleader and chief instigator to every kind of baseness.
You'll notice that the Persian approach is non-Senecan. But they do agree about the evil of ingratitude for society, and this was widely held among Renaissance moral philosophers, on the basis of both Xenophon and Seneca. After the Renaissance we see a fading in the discussion of ingratitude. Obviously tropes of gratitude and ingratitude are still deeply rooted in Western society, but they are scattered and unsystematic, and it would probably be difficult to find many people who would accept the Senecan view that ingratitude is a form of social wrongdoing worse even than murder or theft. Perhaps this is because people do not regard society as the beneficiary network of possible friends that Seneca does. The change is a significant one.