## 5 The Labeling Algorithm for Four-Label Enumeration Stable Extension
### Four-Label Algorithm Description
If the labels are not legal, the label of the \(in\) argument causing the conflicting argument is set to \(must\_out\), and the algorithm continues to repeat the labeling transition operation until all arguments are legally labeled. The specific transition details are shown in Algorithm 4. **Definition 16**. : (_Contradictory Argument_): _Given an argumentation framework \(\Gamma=\langle A,R\rangle\) and argument \(a\in A\), let \(Lab:A\rightarrow\{in,out,must\_out,must\_in\}\) represent a mapping from arguments of the argumentation framework \(\Gamma\) to labels. If \(Lab(a)=must\_out\) and \(\{a\}^{-}=\varnothing\) or \(\forall b\in\{a\}^{-}\), \(Lab(b)\
eq blank\), then argument \(a\) is called a contradictory argument._  
**Definition 17**. : (_Alab-\(in\_transitions\)_): _Given an argumentation framework \(\Gamma=\langle A,R\rangle\) and arguments \(a,x,y\in A\), let \(Lab:A\rightarrow\{in,out,must\_out,must\_in\}\) represent a mapping from arguments of the argumentation framework \(\Gamma\) to labels. The blank label represents an unmarked argument. The specific transition rules are shown in Algorithm 3._  
**Definition 18**. : (_Alab-\(must\_out\)-transitions_): _Given an argumentation framework \(\Gamma=\langle A,R\rangle\) and arguments \(x,y\in A\), let \(Lab:A\rightarrow\{in,out,must\_out,must\_in\}\) represent a mapping from arguments of the argumentation framework \(\Gamma\) to labels. The blank label represents an unlabeled argument. The specific propagation rules are shown in Algorithm 4._```
Input:\(\Gamma=\langle A,R\rangle\), \(Lab:A\rightarrow\{\) blank, \(in\), \(out\), must_out, must_in\(\}\), \(S\subseteq A\); Output:\(Lab:A\rightarrow\{\) blank, \(in\), \(out\), must_out, must_in\(\}\);
1 begin
2\(Lab(a)\leftarrow\) in; /*\(a\in A^{*}\)/
3 foreach\(x\in\{a\}^{+}\) with \(Lab(x)\
eq out\)do
4 if\(Lab(x)\in\{\) blank, must_out\(\}\)then
5\(Lab(x)\gets out\);
6 foreach\(y\in\{x\}^{+}\)do
7 if\(y\) is eligible for must_inthen
8\(Lab(y)\leftarrow\) must_in;
9\(S\gets S\cup\{y\}\); /*S is a stack of arguments labeled as must_in. */
10
11 foreach\(x\in\{a\}^{-}\) with \(Lab(x)=blank\)do
12\(Lab(x)\leftarrow\) must_out;
13 ifLab is legalthen
14 foreach\(y\in\{x\}^{-}\)do
15 if\(y\) is eligible for must_inthen
16\(Lab(y)\leftarrow\) must_in;
17\(S\gets S\cup\{y\}\);
18
19
20 else
21 return false;
22
23
24
25
26
27
28 end if
29
30
31 end for
```

**Algorithm 3**4 lab-in-transitions

```
Input:\(\Gamma=\langle A,R\rangle\), \(Lab:A\rightarrow\{\) blank, \(in\), \(out\), must_out, must_in\(\}\), \(S\subseteq A\); Output:\(Lab:A\rightarrow\{\) blank, \(in\), \(out\), must_out, must_in\(\}\);
3 begin
4\(Lab(x)\gets\) must_out;
5 ifLab is legalthen
6 foreach\(y\in\{x\}^{-}\)do
7 if\(y\) is eligible for must_inthen
8\(Lab(y)\leftarrow\) must_in;
9\(S\leftarrow S\cup\{y\}\); /*S is a stack of arguments labeled as must_in. */
10
11
12 end if
13 return false;
14
```

**Algorithm 4**4 lab-must_out-transitions

In the evaluation of the result, first, it is checked whether all arguments have been labeled, and then it is checked whether any contradictory arguments exist. If neither condition is present, then the set of arguments labeled as \(in\) forms a stable extension. The final stable extension set \(E\) may be empty, may contain a single subset, or may contain multiple subsets. In summary, the algorithm introduces the _must_in_ label, providing more variety in argument labeling. This increases the length of the labeling propagation chain and reduces the search space. Therefore, the four-label algorithm proposed in this paper is more suitable for solving the stable extension problem compared to the two-label and three-label algorithms. ## 6 Experiment Analysis

### Experiment Setup

To accurately evaluate the performance of the proposed method, both the four-label method that we propose in this paper and the two-label method used for comparison were implemented on the ArgTools solver (which uses the three-label method).