## 2 System Architecture and Problem Formulation
### Design of MOBA-CV-SARSA  
Incorporating the multi-objective bat algorithm into the adaptive tuning of hyperparameters for the SARSA learning algorithm and considering the constraints of edge computing (CVs), we introduce MOBA-CV-SARSA, depicted in Figure 5, where A, B, and C are non-dominated solutions in the multi-object optimization; D is a dominated solution. This study introduces MOBA-CV-SARSA, aiming to optimize task-offloading decisions for achieving equilibrium between network latency and energy consumption, as depicted in Figure 6. It preserves the bat algorithm's framework while elevating it to a multi-objective bat algorithm using non-dominated sorting and crowding distance. Additionally, it incorporates SARSA with reinforcement learning to autonomously fine-tune the multi-objective bat algorithm's hyperparameters and offers multi-objective decision making for thorough solution comparisons. This decision will evaluate the bat population's rank first and then the crowding distance [14] if the bats have the same rank in each iteration. Post-iteration sorting is conducted based on energy consumption to extend the network's longevity. Bats with smaller energy expenditures will be prioritized. This is because this paper hopes to extend the life of the network and does not want the device to fail prematurely due to insufficient power. Therefore, this decision is included before outputting the final result. That is, if bats at the same level have the same crowding distance at the same time, they will be sorted according to energy consumption in the final optimized population. Figure 5: MOBA-CV-SARA’s overall structure. Initially, Figure 6 delineates the population's initialization settings [2]. Each row symbolizes a bat (\(X_{\text{lions}},X_{\text{lions}}=\{x_{1},x_{2},\ldots,x_{\text{N}}\}\)), with N indicating the bat's dimensionality, equivalent to the overall count of smart devices (S). The total population consists of npop rows, signifying the aggregate number of bats. Each bat encapsulates task-offloading decisions across dimensions. The first bat performs local computation for all device tasks, whereas the second conducts remote computation. B\({}_{\text{s}}\) reflects the outcome following the conversion of all functions of the sth device to remote computation, as defined by Equation (1). In each iteration, the loudness (A\({}_{\text{i}}\)) and pulse emission rate (r\({}_{\text{i}}\)) of the bats undergo initial updates. According to Reference [15], optimal performance occurs when the loudness value (\(\alpha\)) and pulse emission rate value (\(\gamma\)) fall within the range of 0.9 to 0.98. This study conducts a brute force experiment with 8250 trials and statistical analyses to determine the optimal values for MOBA-CV by combining and examining \(\alpha\) and \(\gamma\). Multiple experiments are required to obtain suitable \(\alpha\) and \(\gamma\) hyperparameters for loudness and pulse emission rate. Hence, this paper proposes a multi-objective bat algorithm (MOBA-CV-SARSA) that employs reinforcement learning SARSA to streamline the cumbersome parameter experimentation process. SARSA treats the \(\alpha\) and \(\gamma\) values used for bat updates as actions, where actions taken under specific states yield corresponding rewards. The subsequent section will present the customized reward function. The primary objective of this research is to minimize both the total delay time (13) (denoted by f\({}_{1}\)) and energy consumption (14) (denoted by f\({}_{2}\)). However, SARSA pursues the maximization of the reward value. To prevent infinite values as the objective function becomes zero, a small positive value (e\({}_{1}\), e\({}_{2}\)) is inclusively added to each objective function. Subsequently, these reciprocated values undergo multiplication with corresponding weights (\(\omega_{1}\), \(\omega_{2}\)). Considering the absence of units, the energy consumption value (f\({}_{2}\)) generally exceeds the delay time value (f\({}_{1}\)) threefold.