updated main func spec