Could somebody please explain the two logic gates with only the one input, A and B, respectively??
It is a NAND gate, with a box just before it.
What is this box?
Why only one input?
The box isn't a box, it shows that the signal goes to both inputs of the 2-input NAND gate. The fact that the line is slightly thicker (as thick as the lines used for drawing the NAND symbols) shows that whoever made the drawing didn't have a clue.
A better drawing would be: