Adding in generic Q solver framework