TITLE: How to define jet bundles algebraically?
QUESTION [11 upvotes]: Let $B\to X$ be a surjective submersion over the smooth integral scheme $X$ over $\mathbb{C}$. Associated to this we have in the $C^\infty$ world the notion of the $k$ jet-bundles $J_k(B)$, which are affine bundles over $X$. I wonder what the best way to define this notion in the setting of algebraic geometry is. If $B=TX$ there is an algebraic description on Wikipedia which makes sense, but I cannot figure out how to give a satisfactory definition in general.
I am fine with restricting to the case where $B$ is the spectrum of a sheaf of $\mathcal{O}_X$ algebras.
Edit: I am talking here about jet bundles in the sense of e.g. this wikipedia article.

REPLY [6 votes]: According to Mustață, Jet schemes of locally complete intersection canonical singularities, the $m$-th jet scheme of (the $\mathbb{C}$-scheme) $X$ is the scheme $J_m X$ over $X$ representing the functor $\mathrm{Sch} \to \mathrm{Set}$ given by
$$ S \mapsto \mathrm{Hom}(\Delta^m\times S,X)$$
where $\Delta^m:=\mathrm{Spec}\frac{\mathbb{C}[t]}{\langle t^{m+1} \rangle}\;.$
So the closed points of $J_m X$ are the morhisms of schemes $\Delta^m\to X$. And the fiber of $J_m X\to X$ over $x\in X$ has as set of closed points the set $\mathrm{Hom}(\mathcal{O}_{X,x}\;,\mathbb{C}[t]/\langle t^{m+1} \rangle)$.
Another way of seeing it is: let $\mathbf{F}:\mathrm{Sch}\to\mathrm{Sch}$ be the functor $\mathbf{F}(S)=\Delta^m\times S$, than it has a right adjoint given by $X\mapsto J_m X$.
Remark. According to the above construction we have $J_1 X=TX$, the tangent bundle (or total space of tangent sheaf if $X$ isn't smooth).