7. A sphere is circumscribed around the tetrahedron $ABCD$, and another sphere with radius 1 is tangent to the plane $ABC$ and the two spheres are internally tangent at point $D$. Given $AD=3, \cos \angle BAC=\frac{4}{5}, \cos \angle BAD=\cos \angle CAD=\frac{1}{\sqrt{2}}$, then the volume of the tetrahedron $ABCD$ is . $\qquad$
7. $\frac{18}{5}$.

First, prove that the height $D H$ of tetrahedron $A B C D$ is the diameter of another sphere.
As shown in Figure 3, let $D E \perp A B, D F \perp A C$, with the feet of the perpendiculars being $E, F$, respectively, then
$$
A E=A F=A D \cos \angle B A D=\frac{3}{\sqrt{2}}, \quad \cos \angle H A E=\cos \angle H A F=\sqrt{\frac{1+\cos \angle B A C}{2}}=\frac{3}{\sqrt{10}} .
$$

Thus,
$$
A H=\frac{A E}{\cos \angle H A E}=\sqrt{5}, \quad D H=\sqrt{A D^{2}-A H^{2}}=2 .
$$

Therefore, the center of the circumscribed sphere of the tetrahedron lies on $D H$. Hence, $A D=B D=C D$, then $A C=A B=2 A E=3 \sqrt{2}$, thus, $S_{\triangle A B C}=\frac{1}{2} A B \cdot A C \sin \angle B A C=\frac{27}{5}, V_{D-A B C}=\frac{1}{3} S_{\triangle A B C} \cdot D H=\frac{18}{5}$.