Search on the web for "Pirate 4x4 MEFI" An excellent article that is worth reading and in that is the magic link to the real MEFI 4/4B Diagnostic Manual. This is the bible for your engine. Download and print double sided since it is 336 pages. Put in a 3 ring binder and keep it close to your heart. Read it and you will know more than most about this engine.
But, since you have an intermittent problem it may not help all that much. The manual (and I) will tell you to get an engine scan (only Rinda equipment can do this). I bought a Rinda Techmate which was a good investment but perhaps you can find a mechanic or friend than can do the scan. If the engine actually shut down there should be some code thrown as a clue. If it is a sensor going in and out of range that is easy. But usually that will not shut down an engine. It sounds more like an electrical fault. I had one in one of the 2 large plugs going into the MEFI controller and it was intermittent. These kind of issues take careful inspection and some luck (the manual does show how to take the plugs apart). If you become convinced it is a sensor, then swaping with the good engine is the cheap and easy route. You can even swap the MEFI 4 if it is suspect. When the problem moves to the other engine, you know you have nailed it.
I would also pull the distributor cap on the offending engine to see if anything looks unusual under there. Lots of intermiittent, unusal activity when that get corroded.
And when you do find it, remember the rule of twin engines. The other one will have the same failure within a year. Fix them both.
Good Luck.