improving terminal mappings