first version of phl without dependencies