To the fifth one proceeds thus. It seems that gifts are not connected. For the apostle says, I Cor. XII, To some is given through the Spirit, word of wisdom, to others word of knowledge according to the same Spirit. But wisdom and knowledge are enumerated among gifts of the Holy Spirit. Therefore gifts of the Holy Spirit are given to different ones, and are not connected with each other in the same one.
Further, Augustine says, in De Trin. XIV, that most of the faithful are not rich in knowledge, although they are rich with faith itself. But faith is accompanied by some of the gifts -- at least the gift of fear. Therefore it seems that gifts are not connected in one and the same.
Further, Gregory says, in Moral. I, that wisdom is less if it lacks intellection, and intellection is exceedinly useless if it does not subsist from wisdom. Counsel is base if it is missing the work of fortitude, and fortitude is destroyed unless supported by counsel. Knowledge is nothing if it does not have the usefulness of piety; piety is exceedingly useless if it lacks the judgment [discretione] of knowledge. Fear itself, as well, if it does not have these virtues, does not rise up for any work of good action. From which it seems that one gift can be had without having another. Therefore gifts of the Holy Spirit are not connected.
But contrariwise is what Gregory premises [praemittit], saying that in this banquet of sons, they in turn fed each other. Now by the sons of Job, of whom he speaks, are designated gifts of the Holy Spirit. Therefore gifts of the Holy Spirit are connected, in that they reinforce one another.
I reply that it must be said that the truth of this is easily able to be had from the premises [praemissis]. For it was said above that just as the striving impulses are disposed through moral virtues in relation to the governance of reason [regimen rationis], so all impulses of the soul are disposed through gifts in relation to the Holy Spirit changing them. But the Holy Spirit dwells in us through charity, according to Rom. V, The charity of God is diffused through our hearts through the Holy Spirit, who is given to us, just as our reason is completed through prudence. Wherefore, just as moral virtues are connected to each other in prudence, so gifts of the Holy Spirit are connected to each other in charity, so that whoever has charity has all the gifts of the Holy Spirit, none of which can be had without charity.
To the first therefore it must be said that wisdom and knowledge are able to be considered one way according as they are gratuitously given graces [gratiae gratis datae], to wit, insofar as someone abounds in cognition of divine and human things, so as to be able to instruct the faithful and confute adversaries. And so the apostle speaks there of wisdom and knowledge, whence mention is made expressly [signanter] of the word of wisdom and of knowledge. In another way they are able to be taken as they are gifts of the Holy Spirit. And thuswise wisdom and knowledge are nothing other than sorts of completions of the human mind according to which one is disposed toward following the instigation of the Holy Spirit in cognition of divine and human things. And thus it is obvious that gifts are in all those having charity.
To the second it must be said that Augustine speaks there of knowledge, expositing the aforesaid authority of the apostle, whence he speaks of knowledge taken in the aforesaid way, according as it is gratuitously given grace. This is obvious from what he adds, For it is one thing to know in such a way as a human being ought to believe in order to reach blessed, which is not other than eternal, life, but another to know in the sort of way to aid the pious and defend against the impious, which the apostle seems to name by word of knowledge.
To the third it must be said that, just as in one way the connection of cardinal virtues is from one's being completed somehow by another, as was said above, so Gregory in the same way wishes to prove the connection of the gifts, in that one is not able to be completed without another. Whence he premises [praemittit] by saying that each is exceedingly destitute if one virtue does not support [suffragetur] another. Therefore it is not given to be understand that one gift is able to be without another, but that intellection, if it were without wisdom, would not be gift, just as temperance, if it were without justice, would not be virtue.
[St. Thomas Aquinas, ST 2-1.68.5, my translation. The Dominican Fathers translation is here, the Latin is here.]
In article 4, which I didn't translate, the Gifts are enumerated: wisdom, intellection/understanding, knowledge, counsel, piety, fortitude, fear. Some significant points in this article, which gives us more information about how the Gifts work as habitudes, are:
(1) The analogy, given in the body and in the reply to objection 3, between the connexio, the connection or joining or meeting, of the cardinal virtues in prudence and the connexio of the Gifts in charity.
(2) The reason that the Gifts ultimately meet in charity rather than in one of the Gifts like (say) wisdom is that they are open specifically to the Holy Spirit working in us, and the Holy Spirit working in us is charity. Thus the Gifts arise from the Holy Spirit giving us the ability to respond and cooperate with the divine love that unifies us with God.
(3) The Gifts should not be confused with gifts of grace in the sense of 'gratuitously given graces'. While it's not entirely clear from the brief comments in the replies to the objection, elsewhere it is explained more fully that the Gifts of the Holy Spirit are for us to be moved by the Holy Spirit, but gratuitously given graces are for us to aid others. Another way to put it is that the Gifts make us one with Christ (indeed, they are literally the Messianic graces, which Christ has properly and which he extends to us as part of our participation in Him); gratuitously given graces help lead others to Christ.