Let $X$ be an $S$-scheme. That is there exists a morphism of schemes $X \to S$, in particular we can view $X$ as a family over $S$.
Also, suppose that $X$ is a $k$ scheme, i.e there exists a morphism $X \to \operatorname{Spec} k$?
How would you describe the structure sheaf on $X$ as a scheme over $k$ vs. the structure sheaf on $X$ as a scheme over $S$?
More generally, I am a bit confused as to how the ring of functions on a scheme $X$ is affected by a scheme parameterizing $X$.
Maybe there exists something like a relative structure sheaf $\mathcal{O}_{X/S}$ vs. $\mathcal{O}_X$...
There is no such thing as "the structure sheaf on $X$ as a scheme over $S$" or "the structure sheaf on $X$ as a scheme over $k$". There's just the structure sheaf $\mathcal{O}_X$ of $X$ as a scheme, which does not depend on any base scheme.
The additional structure that a morphism $f:X\to S$ does give you on the structure sheaf is a morphism of sheaves of rings $f^{-1}\mathcal{O}_S\to\mathcal{O}_X$. In other words, it makes $\mathcal{O}_X$ not just a sheaf of rings but a sheaf of algebras over the sheaf of rings $f^{-1}\mathcal{O}_S$. (In the specific case that $S=\operatorname{Spec} k$ for a field $k$, the sheaf of rings $f^{-1}\mathcal{O}_S$ is just the constant sheaf $k$ on $X$, so this is equivalent to making $\mathcal{O}_X$ a sheaf of $k$-algebras.)