4. Let set $A=\left\{(x, y) \mid y=x^{2}\right\}, B=$ $\left\{(x, y) \mid x^{2}+(y-m)^{2}=1\right\}$. If $A \cap B \neq \varnothing$, then the range of values for $m$ is $\qquad$.
4. $\left[-1, \frac{5}{4}\right]$.

From $A \cap B \neq \varnothing$, we know that the system of equations
$$
\left\{\begin{array}{l}
y=x^{2}, \\
x^{2}+(y-m)^{2}=1
\end{array}\right.
$$

has real solutions.
Solution 1: Substitute (1) into (2) to eliminate $x^{2}$, we get
$$
y+(y-m)^{2}=1 \text {, }
$$

which simplifies to $y^{2}+(1-2 m) y+\left(m^{2}-1\right)=0$.
By $0 \leqslant \Delta=(1-2 m)^{2}-4\left(m^{2}-1\right)=5-4 m$, we solve to get $m \leqslant \frac{5}{4}$.
From (1) and (2), we also know
$$
(y-m)^{2} \leqslant 1, y \geqslant 0 \text {. }
$$

Thus, $-1 \leqslant y-1 \leqslant m \leqslant y+1$.
Combining (3) and (4), we get
$$
-1 \leqslant m \leqslant \frac{5}{4} \text {. }
$$

Note: $m \geqslant-1$ is easily overlooked, and can be considered with the help of Figure 3.
Solution 2: Convert (2) into the parametric equations
$$
\left\{\begin{array}{l}
x=\cos \alpha, \\
y=m+\sin \alpha .
\end{array}\right.
$$

Substitute into (1), we get
$$
m+\sin \alpha=\cos ^{2} \alpha,
$$

which simplifies to
$$
\begin{array}{l}
m=\cos ^{2} \alpha-\sin \alpha \\
=1-\sin ^{2} \alpha-\sin \alpha \\
=\frac{5}{4}-\left(\sin \alpha+\frac{1}{2}\right)^{2} .
\end{array}
$$

When $\sin \alpha=-\frac{1}{2}$, $m_{\text {max }}=\frac{5}{4}$;
When $\sin \alpha=1$, $m_{\min }=-1$.
Therefore, $-1 \leqslant m \leqslant \frac{5}{4}$.