
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 a hyperbola $C$ with the equation $\frac{x^2}{a^2}-\frac{y^2}{b^2}=1$ (where $a>0$, $b>0$) and an eccentricity of $\sqrt{3}$, the left vertex is at $(-1,0)$.  
(1) Find the equation of the hyperbola;  
(2) It is known that the line $x-y+m=0$ intersects with the hyperbola $C$ at two distinct points $A$ and $B$, and the midpoint of the line segment $AB$ lies on the circle $x^2+y^2=5$. Find the value of $m$ and the length of the segment $AB$.

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