
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
Given the function $f\left(x\right)=a(2^{x}+x^{2})+2^{-x}$ defined on $R$ is an even function, where $a\in R$.  
$(1)$ Find the value of $a$;  
$(2)$ If the inequality $mf\left(x\right)\leqslant 2^{-x}+mx^{2}+m-1$ holds for all $x\in \left(0,+\infty \right)$, find the range of real number $m$.

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