First pass at prioritization middleware, AR:B hooks, & tests