First, I'm not defending the Capitol Police, just trying to explain their actions.
The Capitol Police are a self contained entity who fall directly under the control of Congress. They are not D.C. cops. As such their training is inconsistent, and we saw this yesterday where on one side of the Capitol Building their riot team was beating the crap out of protesters while on the other side the officers caved as MAGA goons breached their poorly constructed perimeter.
Once inside the officers clearly had no idea what to do, and clearly had zero leadership. Obviously there is a huge gap in training, and planning for this kind of event by the Capitol Police command. If you watch the videos it is clear that the officers inside the building are the B and C-Teams. Worse, the Capitol Police were genuinely caught off guard, which means they ignored thousands of warnings about people converging on Washington to do this very thing. This means the Capitol Police command element is incompetent, and ultimately this falls back onto their employer, the US Congress.
To be fair, or to play Devil's Advocate, once inside the mob didn't destroy everything in sight. In fact there is video of them staying inside the velvet ropes of the rotunda. Windows were broken, and the chamber was breached, but let's be honest - had this been an Antifa/BLM raid the building would have burned. So when the cops are outnumbered the move is to de-escalate. The building has good security cameras (at least I hope so), and those idiots also live-streamed their actions on their personal social media accounts which will allow the FBI to roll them up. As it was, the mob left the building without the SWAT teams rolling in, and everyone is left to ponder the day's events.
My personal belief, and this is not based on any evidence, just emotion, is that the Capitol Police took a lot of heat over their actions this summer, and they responded by over-applying the new riot playbook to rub it in their command, and employer's face.