
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 that $x^{2}+x-6=\left(x+3\right)\left(x-2\right)$, let $x^{2}+x-6=0$, then $\left(x+3\right)\left(x-2\right)=0$, $x=-3$ or $x=2$. Conversely, $x=2$ makes the polynomial $x^{2}+x-6$ equal to $0$. Using the above reading material to solve:

$(1)$ If $x-4$ is a factor of the polynomial $x^{2}+mx+8$, find the value of $m$;

$(2)$ If $\left(x-1\right)$ and $\left(x+2\right)$ are factors of the polynomial $x^{3}+ax^{2}-5x+b$, find the values of $a$ and $b$;

$(3)$ Under the conditions of $(2)$, the factorization of the polynomial $x^{3}+ax^{2}-5x+b$ is ______.

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