  It is well known that algebro-geometric solutions of the KdV hierarchy are
constructed from the Riemann theta functions associated with hyperelliptic
curves, and that soliton solutions can be obtained by rational (singular)
limits of the corresponding curves. In this paper, we discuss a class of KP
solitons in connections with space curves, which are labeled by certain types
of numerical semigroups. In particular, we show that some class of the
(singular and complex) KP solitons of the $l$-th generalized KdV hierarchy with
$l\ge 2$ is related to the rational space curves associated with the numerical
semigroup $\langle l,lm+1,\dots, lm+k\rangle$, where $m\ge 1$ and $1\le k\le
l-1$. We also calculate the Schur polynomial expansions of the $\tau$-functions
for those KP solitons. Moreover, we construct smooth curves by deforming the
singular curves associated with the soliton solutions. For these KP solitons,
we also construct the space curve from a commutative ring of differential
operators in the sense of the well-known Burchnall-Chaundy theory.
