4. Given that the tetrahedron $ABCD$ is inscribed in sphere $O$, and $AD$ is the diameter of sphere $O$. If $\triangle ABC$ and $\triangle BCD$ are both equilateral triangles with side length 1, then the volume of tetrahedron $ABCD$ is ( ).
(A) $\frac{\sqrt{2}}{6}$
(B) $\frac{\sqrt{2}}{12}$
(C) $\frac{\sqrt{3}}{6}$
(D) $\frac{\sqrt{3}}{12}$
4. B.

From the problem, we know that the tetrahedron $ABCD$ has an isosceles right triangle $\triangle ABD$ as its base and a height of $\frac{\sqrt{2}}{2}$.
Therefore, $V=\frac{1}{3} \times \frac{\sqrt{2}}{2} \times \frac{1}{2}=\frac{\sqrt{2}}{12}$.