TLA_str = """
We provide training logs for several reward functions derived from <task_short_desc> that utilize multi-objective reinforcement learning (MORL). To assist the user in further tuning the parameters of the reward function, a summary must be written for each log, highlighting the key messages based on the user requirements detailed below.

## Weights and Performance Results

The main objectives to be optimized for the task are:

<obj_description>

Below is the performance log that requires analysis: [HGH] indicates that higher values are preferable, whereas [LOW] indicates that lower values are preferable.

<weights_and_pref_res>

## Output format guide

We have provided multiple sets of weight parameters along with the performance training logs generated by training policies utilizing these weight parameters previously. Below, we present the format for outputting the performance summary:

First, a performance summary must be provided for each group, including the following sections:

- An analysis of each performance metric must include: (a) the initial metric value at the beginning of training; (b) the changing trend of the average value (AVG) of performance (e.g., steadily increasing/decreasing; increasing/decreasing but fluctuating, etc.); (c) the ratio of the final five values relative to the starting point. Additionally, provide a judgment on whether the user requirements are satisfied by comparing the final values to the numerical objectives. (e) The stability of the training process, which can be assessed by analyzing the standard deviation (STD) value.
- A summary of the analysis must be provided beforehand (it should be a single line, starting with `**Summarized Output:**` in bold), containing key observations and trends from the analysis that are likely to be of significant reference value to users, expressed in natural language. Additionally, indicate whether each user requirement has been met.

After completing the analysis of each group, the overall summary should be presented as a single paragraph. This output must be formatted as a section titled `### Overall Summary` and should include: (a) the user requirements in which each group performed well and poorly (all groups must be analyzed); (b) the overall performance and an assessment of whether all groups can meet user requirements. It is essential to include all pertinent information. 

Furthermore, in the context of multi-task optimization, an increase in one performance indicator may be accompanied by a decrease in another or several other indicators, or vice versa. It is important to observe this trend when presenting the summarized output and overall summary.
"""

TLA_str_example = """
## Format Example

A simple example is given below, illustrating some principles of summarization. To avoid revealing suggestions, the user requirements will be replaced with Requirement foo, Requirement bar, etc.

### Input

If the user requirements are as follows, where `foo` and `bar` serve as examples of requirements with numerical objectives, whereas `qux` represents a performance metric of relatively low priority:

```python
{'foo':'The number of xxx should be reduced to be zero.','bar':'The number of xxx should be reduced to be zero.','qux'：'This value may be optimized (lower is better).'}
```

If the training logs are as follows, where [HGH] indicates a preference for higher values, while [LOW] indicates a preference for lower values.

**Group 1：**
[LOW]AVG of performance metric of foo: [7.084, 7.072, 6.938, 6.439, 5.026, 4.294, 4.179, 3.057, 2.738, 2.856]
[LOW]STD of performance metric of foo [0.102, 0.107, 0.178, 0.534, 0.928, 1.011, 0.924, 0.816, 1.116, 1.387]
[LOW]AVG of performance metric of bar: [47.12, 21.72, 0.0, 0.0, 0.0, 0.0, 0.0, 2.24, 0.12, 0.0]
[LOW]STD of performance metric of bar: [72.25, 52.455, 0.0, 0.0, 0.0, 0.0, 0.0, 10.974, 0.588, 0.0]
[LOW]AVG of performance metric of qux: [103.712, 94.722, 82.755, 93.009, 97.038, 106.59, 108.709, 117.737, 123.717, 130.052]
[LOW]STD of performance metric of qux: [2.717, 8.953, 3.45, 9.467, 4.552, 7.497, 7.057, 6.949, 8.131, 7.78]

**Group 2：**
[LOW]AVG of performance metric of foo: [7.077, 7.04, 6.855, 6.42, 6.241, 5.916, 6.29, 5.933, 5.851, 5.909]
[LOW]STD of performance metric of foo: [0.106, 0.323, 0.457, 0.42, 0.543, 0.874, 0.534, 0.834, 0.895, 0.813]
[LOW]AVG of performance metric of bar: [15.44, 17.88, 2.68, 11.68, 4.36, 5.56, 1.8, 7.24, 5.56, 2.64]
[LOW]STD of performance metric of bar: [46.637, 34.88, 4.619, 16.121, 6.529, 8.796, 4.186, 13.616, 20.138, 6.793]
[LOW]AVG of performance metric of qux: [97.312, 78.045, 59.71, 57.478, 57.987, 57.005, 58.973, 61.522, 57.821, 60.494]
[LOW]STD of performance metric of qux: [3.923, 8.48, 4.306, 4.195, 3.642, 3.829, 3.917, 5.839, 3.777, 4.516]

### Example output (K=2)

**Group 1:**

- Requirement 'foo': The initial value is 7.08, and the average of the last five values decreases to approximately 3.0(~40%). However, there remains a significant gap between this outcome and the user requirement that demands this value must be reduced to zeros.
- Requirement 'bar': The initial value is 47.1, and the average of the last five values decreases to almost 0. The requirement is completely satisfied.
- Requirement 'qux': The initial value is 103.7, and the average of the last five values increase to approximately 120(~20%). This result is not satisfying.  

**Summarized Output:** The requirement foo is clearly optimized but not fully satisfactory, and the requirement bar is completely optimized, whereas the optimization of the performance metric qux is poor.

**Group 2: **

- Requirement 'foo': The initial value is 7.08, and the average of the last five values decreases to approximately 6.0(~15%). Compared to group 1, this requirement is poorly optimized.
- Requirement 'bar': The initial value is 15.44, and the average of the last five values decreases to approximately 3-5.  It's obviously optimized but remains a significant gap to the objective, and from the STD value we can infer that the stability outcome is poor.
- Requirement 'qux': The initial value is 97.3, and the average of the last five values increase to approximately 59(~40%). This requirement is obviously optimized. 

  **Summarized Output:** It is clearly optimized but there remains a significant gap to the objective, and from the STD value, we can infer that the stability outcome is poor.

### Overall Summary

The overall performance of group 1 is better than that of group 2. In group 1, requirement foo is clearly optimized although its performance does not meet the requirement, whereas requirement bar is fully optimized. However, group 2 shows better optimization for requirement qux. Overall, no group meets all the requirements.
"""
