As Geoff already pointed out in the comments, the connection between a molecular orbital theory (MO) point of view and a Lewis picture (LT) is tenuous at best.
Maybe the best example for this is the mentioned $\ce{{}^{-}CN}$ and obviously the isoelectronic $\ce{CO}$. But there are many more molecules.
In the MO point of view the electron pair which can be donated to an acceptor orbital is of course the highest occupied molecular orbital (HOMO). Often this comes with the more trivial notation of "lone pair", based on the coefficients of a certain element in that orbital (percentage contribution). In the case of $\ce{CO}$ this becomes fairly obvious, but since this is not the question at hand I will only focus on the isoelectronic counterpart.
Please consider the above MO scheme only as a sketch, it is not to scale and contributions were estimated only be a quick browse of the output file. I also did not compensate the calculation for the negative charge, so even the bonding orbitals are antibonding with respect to fragmentation. But it shall still provide the point.
We can clearly see that the highest coefficient of the HOMO is at the carbon end, this is consistent with the fact, that it will most likely bond with this end to a more electropositive element. But this is, however, not a real lone pair since it is $\sigma$ bonding and also has quite a big coefficient at the nitrogen end. (In $\ce{CO}$ the difference is much bigger.)
Below that we see the two $\pi$ orbitals, followed again by two $\sigma$ orbitals. All five orbitals make up the bonding of the molecules and determine also its reactivity.
Now in the Lewis theory picture this is quite different. We traditionally describe it as a carbon oxygen $\sigma$ bond, two carbon oxygen $\pi$ bonds, a oxygen lone pair and a carbon lone pair. All made up from some kind of hybrid orbitals. In computational chemistry we can analyse the wave function and obtain localised orbitals. One of these methods is natural bond orbital theory (NBO). I have carried that out and sketched the common bonding picture along with it:
While this picture is also consistent with a valence bond theory (VB) approach, it explains bonding in a different way than MO theory. However, the conclusions we will ultimately get are essentially the same.
It shall be noted, that MO theory and VB theory are complementary theories, but the different explanations should not be mixed, even when the conclusions are essentially the same.