
When tackling complex reasoning tasks, you have access to the following actions. Use them as needed to progress through your thought process.

[ASSESS]

[ADVANCE]

[VERIFY]

[SIMPLIFY]

[SYNTHESIZE]

[PIVOT]

[OUTPUT]

You should strictly follow the format below:

[ACTION NAME]

# Your action step 1

# Your action step 2

# Your action step 3

...

Next action: [NEXT ACTION NAME]


system
The function $f(x)= \frac{1}{2} - \frac{1}{2} \cos 2x$.

$(1)$ Find the smallest positive period of $f(x)$ and determine its parity;

$(2)$ Suppose for any $x \in \mathbb{R}$, we have $g(x+ \frac{\pi}{2})=g(x)$, and when $x \in [0, \frac{\pi}{2}]$, $g(x)= \frac{1}{2} -f(x)$. Find the expression of $g(x)$ in the interval $[-\pi, 0]$.

Present the answer in LaTex format: \boxed{Your answer}
user