1. 5. 5. ** The domain of the function $f(x)$ is $(0,1)$, and the rule of correspondence is
$$
f(x)=\left\{\begin{array}{ll}
x, & \text { if } x \text { is irrational, } \\
\frac{p+1}{q}, & \text { if } x=\frac{p}{q}, p, q \in \mathbf{N}^{*},(p, q)=1, p<q .
\end{array}\right.
$$

Find the maximum value of $f(x)$ in the interval $\left(\frac{7}{8}, \frac{8}{9}\right)$.