The large box mounted under the saddle of my bike contains the batteries (two NiMH rechargeable D-cells) and main electronics (Arduino-type microcontroller) for the LED strips attached to the sides of the frame (front fork, top tube, seat stay) and on the rear reflector panel.
That custom extra lighting system is my own creation, I call it “Project Lux”.
The smaller box mounted to the top tube is the controls for those lights.
(The big black lump mounted to the down-tube is an ebike battery. The Project Lux lighting system does not connect electrically to the ebike system.)
Here’s what the inside of the box looks like: