Smoothness of space of morphisms from a curve to a locally complete intersection Let $C$ be an irreducible smooth project curve over $\mathbb C$ and $Y$ a variety over $\mathbb C$ locally of complete intersection.  Write $Y^{\text sm}$ for the smooth locus of $Y$.  Consider the 'space' of morphisms $f: C \rightarrow Y$ that 'generically take values in $Y^{\text sm}$', i.e. $f(c) \in Y^{\text sm}$ for all but finitely many points $c$ in $C$.
Does anyone know if this 'space' of morphisms is smooth or not?  If the answer is yes, could you please suggest some references?  If the answer is no, then is it possible to, say, impose extra conditions to make the 'space' smooth?  Thank you very much for your help!
 A: If $C$ has genus $> 2$, even if $C$ has general moduli, even if $Y$ is $\mathbb{P}^n$, typically the Hom scheme, $\text{Hom}(C,\mathbb{P}^n),$ is singular.  This sometimes surprises people when they first study Hom schemes, since the Gieseker-Petri theorem is a smoothness theorem that (until you realize what is happening) seems to contradict this phenomenon.  
For instance, consider a general curve $C$ of genus $3$.  Consider morphisms from $C$ to $\mathbb{P}^2$ whose degree with respect to $\mathcal{O}(1)$ equals $4$.  Consider such a morphism $f$ where the image is a line, and where the pullback of $\mathcal{O}(1)$ is the dualizing sheaf.  
There is one irreducible component of $\text{Hom}(C,\mathbb{P}^2)$ of dimension $8$ containing $[f]$ that parameterizes morphisms that pullback $\mathcal{O}(1)$ to an invertible sheaf that is isomorphic to the dualizing sheaf.  There is a second irreducible component, also of dimension $8$, whose general point parameterizes a morphism with image equal to a line and that pulls back $\mathcal{O}(1)$ be a general invertible sheaf of degree $4$ on $C$.  Thus, $\text{Hom}(C,\mathbb{P}^2)$ is reducible at $[f]$, hence it singular at $[f]$.
