figuring out code for attributes vs qualitative states vs logic rules