# QoS-Based Pattern Recognition Approach for Web Service Discovery: Ar_WSDS
## 4 Overall Design of Ar_WSDS  
The Ar_WSDS architecture shown in Figure 4 includes eight steps. First, the input of the system, whose function is to read the data and create the \(WS_{g}\) set, corresponds to the input of the system. Second, loading the ACM defines the service syntax requirements and the QoS parameters at the atomic and composed level (resulting service after composition). Third, it defines the dynamic creation of the recognition modules that conform to the ACM, through the two strategies set up in Ar_WSDS (as discussed in the next section). Fourth, matching by service name is performed, allowing the system to reduce its search space and limit its analysis to QoS. Fifth is the execution of the recognition modules, which enables the selection of the most appropriate services according to the user's QoS requirements. Figure 4: Ar_WSDS workflow. Figure 3: Web service assembly structure. Sixth, the candidate services are set up. Finally, in the seventh and eighth stages, the SP establishes the set of services that satisfy each node and whose union maximizes the user's quality level, defined as the value of their composed service. Below, the system definitions and the semantic notations used in Ar_WSDS, as a series of components that identify the system within the PRTM environment, are provided. A pattern (\(\rho\)) is an entity represented by a \(WS_{g_{i}}\) to be recognized through the parameters within the QoST set. Based on the decomposition of \(\rho\), the set of atomic signals, named \(S()\), is generated. \(S()\) contains information about each \(WS_{g_{i}}\), and the recognition modules classify the service as a candidate if it complies with the assembly and QoS characteristics. An optimal WS is the service that is closest to its QoS parameter specified in the composition model. SP is a subset of optimal web services, and the system recognizes 0 or \(n\) pathways. If its value is 0, it means that some service did not comply with its respective QoS parameter. Therefore, an ACM node will not have any associated services. Figure 5 shows an example of the Ar_WSDS system, where the inputs are the specifications \(WS_{g}\) and the ACM. Then, the recognition modules discover and select the most suitable WS for the model node. Finally, the system creates the SP, in order to satisfy the requirements provided in the ACM. A recognition module, symbolized as \(\Gamma\), consists of a set of software components that recognize a pattern and its signals. Due to the modularity and architecture of the Ar_WSDS, these modules are dynamic (i.e., automatically adaptable to the parameters of each \(WS_{i}\) of the composition model). Equation (2) formalizes the recognition modules:  
\[\Gamma=\big{\{}\Gamma_{i,j}\mid\Gamma_{i,j}\in QoS_{i,j}\big{\}}, \tag{2}\]  
where  
Figure 5: Example of Ar_WSDS operation. 1. \(\Gamma_{i,j}\) is a recognition module for service \(i\) of its QoS parameter \(j\), and
2. \(QoS_{i,j}\) corresponds to QoS parameter value \(j\) of service \(i\). **Definition 4**. : _A WS ranking, symbolized as \(\varphi\), is a value of the degree or weight of importance of a web service candidate once the \(\Gamma\) modules recognize it._  
Hence, \(\varphi_{i,j}\) has a value of 1 when the value for \(QoS_{i,j}\) of the \(WS_{S_{i}}\) is categorized as the most optimal, and a value of \(n\) when it is further away from the optimal WS. **Definition 5**. : _The matching recognition function, represented as \(M()\), evaluates whether the name of the service described in set \(WS_{T}\) has a matching correspondence in the set \(WS_{g}\), in which case, its result is true, and it is false otherwise._  
\[\exists_{x}\{x\mid x\in WS_{c}\leftrightarrow M\big{(}WS_{g}\big{)}=true\}. \tag{3}\]  
Equation (3) shows the function \(M()\), which aims to minimize the search space between the \(WS_{g}\) and to create the primary candidates (elements detonated as \(x\)). These are WSs to be treated by the recognition modules, which analyze each value of their QoS. **Definition 6**.