Judge to decide whether to allow plea agreement avoiding pri