
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 parametric equations of curve $C$ in the rectangular coordinate system $xOy$ as $\begin{cases}x=1+\sqrt{3}\cos\theta\\y=\sqrt{3}\sin\theta\end{cases}$ ($\theta$ is the parameter), establish a polar coordinate system with $O$ as the pole and the non-negative semi-axis of $x$ as the polar axis.

(I) Find the polar equation of curve $C$.

(II) The polar equation of line $l$ is $\rho\cos\left(\theta-\frac{\pi}{6}\right)=3\sqrt{3}$, and ray $OT$: $\theta=\frac{\pi}{3}\ (\rho>0)$ intersects curve $C$ at point $A$ and line $l$ at point $B$. Find the length of segment $AB$.

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