How does Betterloot work?

Betterloot is a very simple, but very buggy plugin. If you selectively remove unnecessary junk from boxes, and set the number of items to 1-3, then this completely breaks the vanilla logic of component spawning in them. In the vanilla version of the game, a component has a 100% chance of spawning in any of the boxes. Also, more than 1 weapon or 1 piece of clothing cannot spawn in a box. After editing, components begin to spawn 1 time in 10 boxes, and weapons and clothing take up the entire loot line. How can I simply increase the number of components by 2 and custom remove junk from them so that it does not break the vanilla logic?

I know about Alphaloot, but it seems to me that it is built on the same logic as Betterloot and does not solve the problem.

If you are using a plugin for loot you would not be interested in the vanilla logic, If you want vanilla loot dont use loot plugins.

I need vanilla logic and garbage removal in it, but this plugin breaks the logic when removing garbage. Now I'm trying to solve the problem through Magicloot, but I also have problems with adding items to the blacklist. Even if there are items in the list, they still continue to spawn in boxes.