keyvalue function

Coerce to a keyvalue object