I think you need to develop your anaerobic power capacity. Going off the front (OTF) will require a tremendous amount of anaerobic power. You also have to be able to tolerate lactic acid buildup which is the byproduct of short, high intensity anaerobic efforts like gapping OTF. Lactic acid lowers blood and intramuscular PH(power/potential of hydrogen).
Most people hear about PH in shampoos and stuff like that. The scale goes from 0-14, 7 is neutral. Lower values inicate higher acidity. Normal stomach acid has a 1.5-3.5 PH.
Blood is normally around a PH of 7. Excessive lactate buildup will lower this value.
Even blood PH in the high 6's will start to impair performance. The muscle cells contact optimally under a very narrow PH range. When the PH gets too low, the cells don't contract as forcefully. Less force = less power. If you really blow yourself up, you won't be able to get back on someone's wheel even at the back of the pack. This sounds like what happened.
You could do 30-60 second intervals at the hardest pace to complete the time, with an equal recovery period (1-1). 60 seconds hard, 60 seconds easy, etc. Typical goals for workouts of this type are 10-15 minutes of "work." Start off with only 3-5 minutes of "work" to start. If you are attempting 60 seconds efforts and can only hold 40 seconds, you are going too hard. This workout will develop your anaerobic power capacity, and generate tons of lactate.
You could also do 20 seconds hard, 20 seconds easy. Repeat for 20 minutes or so. There are many variations.
You may feel physically sick in your stomach or liver from a hard interval workout like this. After a while, you will be more powerful and be able to tolerate high lactic-acid environments. The next time you attack OTF, you may have to drop back, but this time you will be able to get back on without any problems. A well-trained rider can go OTF several times after recovering in the pack. Sometimes, the 5th time you attack to establish a break is the one that finally works!!!
Interval workouts are very taxing mentally as well. I think it's almost harder to get your head into them rather than your legs. For this reason, I recomend finding a few very fast training rides per week and blow yourself up on them. Attack, blow up, recover in the pack, attack, recover, blow up, and so on. You will get better quickly without burning yourself out mentally.
If you are really strong mentally, you can do them with great success indoors on a trainer. Be sure to use a VERY powerful fan to cool you if you choose this method!!!
It is mandatory to recover well between these workouts do no more than 2 a week and with at least 48 hrs of recovery in between.
Good Luck!!!