Add OS spec. Refactor