OSM: code organize