WP2: Advanced anaerobic wastewater treatment to maximize energy products