4. As shown in Figure 1, the radius of the semicircle $\odot 0$ is $1, A C \perp A B$ at point $A, B D \perp A B$ at point $B$, and $A C=2, B D=3, P$. is any point on the semicircle. Then the maximum area of the closed figure $A B D P C$ is $\qquad$
4. $\frac{5+\sqrt{5}}{2}$.

As shown in Figure 5, construct $C E \perp B D$ at point $E$. Then
$\triangle C E D \cong \triangle C A O$.
Thus, $\angle O C D=90^{\circ}$.
When the area $S$ of pentagon $A B D P C$ is maximized, to minimize the area of $\triangle C P D$, the height $P H$ of $\triangle C P D$ must be minimized, and
$$
O P+P H \geqslant O H \geqslant O C,
$$

then the minimum height $P H$ is $O C-O P=\sqrt{5}-1$.
It is also easy to see that $C D=\sqrt{5}$, hence
$$
=5-\frac{\sqrt{5}(\sqrt{5}-1)}{2}=\frac{5+\sqrt{5}}{2} \text {. }
$$