This paper describes an algorithm optimizing the discovery process for composed semantic web services. The algorithm can be used to improve discovery of appropriate component services at invocation time. It performs semantic matchmaking of goals of a composed service to appropriate component services at publishing time. The semantic discovery problem at invocation time is therefore reduced to a selection problem from a list of available (already discovered) component services matching a goal of the composed service.