add composition data struct and HOF