Narcosis can, in part, be overcome by diet, but anything that decreases narcosis also increases the chance of a samba. Any substance which blocks your NMDA/AMPA/kainate receptors (in your brain) creates a narcosis effect and also decreases the chance of a samba or seizure. Anything which excites your NMDA/AMPA/kainate receptors decreases narcosis and increases the chance of a samba.
Alcohol = blocks NMDA receptors
Thiocyanate = excites AMPA/kainate receptors (thiocyanate can be found in kale and some cruciferous vegetables)
decaffeinated Green tea = blocks AMPA/kainate receptors
There are many other foods which have these effects as well, such as black pepper.
Of course, training can be used to some extent to prepare oneself for narcosis, and also hyperventilation (by decreasing CO2) decreases narcosis, but once again, hyperventilation increases the risk of samba/BO.
Another risky method to fight narcosis would be to become an alcoholic, and then cut out the alcohol some days before the record attempt. When you constantly drink alcohol, your NMDA receptors are always blocked/inhibited; as a result your body 'upregulates' your NMDA receptors to compensate. Then, when you cut out the alcohol, your brain becomes hyperactive (because the NMDA receptors are upregulated) and you risk seizures (some severe alcoholics can have seizures if they go cold turkey). Theoretically, someone in this alcohol-withdrawal state would be almost immune to narcosis because of hyperactive NMDA receptors.
It is also possible that repeated exposure to extreme narcosis would also upregulate the NMDA receptors, but it would be far more likely to occur with a scuba diver doing a long 'deep-air' dive, rather than a freediver who spends just minutes or seconds in the narked state.