Char the eggplants.
Place the eggplants directly on the gas burner flame (or under the broiler). Let each side char completely - it should be black and collapsing. This takes 5-8 minutes total, turning every 2 minutes. When fully charred, place in a bowl and cover with a plate or lid. Let steam 10 minutes.
Peel and shred.
Once cool enough to handle, remove the skin - it should slip off easily. Discard the skin. Cut off the ends. Using two forks, shred and mash the eggplant flesh. Some people prefer it very smooth, others like more texture. Drain any excess liquid.
Make the sofrito base.
Heat olive oil in a skillet over medium heat. Add the onion and pepper. Cook 4-5 minutes until soft and translucent. Add the garlic and cook 1 minute more until fragrant.
Add tomato and cook down.
Add the diced tomatoes or tomato sauce. Stir and cook 5 minutes until the tomatoes break down and the sofrito thickens. Season with oregano, salt, and pepper.
Fold in the eggplant.
Add the shredded eggplant to the sofrito and stir until everything is combined. Cook 3-5 minutes more over low heat, letting the flavors meld. Taste and adjust salt. Add cilantro off the heat. A splash of vinegar or lime at the end brightens the whole dish.
Serve.
Hot with white rice and habichuelas. Room temperature spread on casabe. Cold the next morning next to eggs. It works in every direction.