working on code to infer details