command parsing overhaul