An infinite simple continued fraction

$$\frac{1}{b_1 + \frac{1}{b_2 + \frac{1}{b_3+\dots}}} (b_i\in\mathbb Z)$$

is irrational. Now for a generalized continued fraction:

$$\frac{a_1}{b_1 + \frac{a_2}{b_2 + \frac{a_3}{b_3+\dots}}} (a_i,b_i\in\mathbb Z),$$

the same conclusion is apparently not valid. Legendre gave a sufficient condition for irrationality:

$$|a_i|<|b_i|$$

for any $i$ large enough.

Can this result be strengthened in any way? Especially, might it hold for $a_i, b_i\in\mathbb Q$?

Also, can anyone give an example of an infinite generalized continued fraction that converges to a rational, showing that some condition on the $a_i, b_i$ is needed for irrationality?

positiveintegers. $\endgroup$