Let $V$ be the vector space of functions that are smooth $0$: they have derivatives of all orders. Every $f\in V$ can be (locally) expanded into a Taylor series, as $$f(x)=f(0)+f'(0)x+\frac{f''(0)}{2}x^2+\dots$$
At the same time, suppose $H$ is a (separable) Hilbert space whose intersection with $V$ is dense in the latter, and, moreover, that in fact $f\in H$ too. Pick any orthonormal basis $\{e_j\}_{j\in J}$. Then $f$ has a generalized Fourier expansion $$f=\sum_{j\in J}{\langle e_j,f\rangle e_j}$$ (For which argument is antilinear, I follow the physicist's convention.)
There are many Hilbert spaces with a polynomial orthonormal basis; Wikipedia has a whole article about them. Write $$e_j(x)=\sum_{n=0}^{\infty}{c_{j,n}x^n}$$ where only finitely-many coefficients are nonzero.
Ideally, the generalized Fourier expansion above will converge rearrangeably. We can then "collect terms" into a series $$f(x)=\sum_{j\in J}{\langle e_j,f\rangle c_{j,0}}+\left(\sum_{j\in J}{\langle e_j,f\rangle c_{j,1}}\right)x+\left(\sum_{j\in J}{\langle e_j,f\rangle c_{j,2}}\right)x^2+\dots$$ Does there exist a Hilbert space for which we can recover Taylor's formula: $$\sum_{j\in J}{c_{j,n}\langle e_j,f\rangle}=\frac{f^{(n)}(0)}{n!}\text{?}$$
(Based on a recent deleted question.)
Yes, or no, or also yes. It all depends on whether your functions are of a real or complex variable, and how wildly you can imagine a Hilbert space. But before I begin, a spot of notation: let $p_n(x)=x^n$.
The complex-variable case
Functions smooth at $0$ are necessarily analytic on a neighborhood thereof. Suppose that said neighborhood is large enough to contain the closed unit disk $\mathbb{D}$; then we can compute that our inner product explicitly.
Since $$f=\sum_{n=0}^\infty{\frac{f^{(n)}(0)}{n!}p_n}$$ we must have $\langle p_n,f\rangle=\frac{f^{(n)}(0)}{n!}$. Now write $g(z)=\sum_{n=0}^\infty{a_nx^n}$. Then, by Cauchy's formula, \begin{align*} \langle g,f\rangle&=\left\langle\sum_{n=0}^\infty{a_np_n},f\right\rangle \\ &=\sum_{n=0}^\infty{\frac{\overline{a_n}f^{(n)}(0)}{n!}} \\ &=\frac{1}{2\pi i}\sum_{n=0}^\infty{\oint_{\partial\mathbb{D}}{\frac{\overline{a_n}}{z^{n+1}}f(z)\,dz}} \\ &=\frac{1}{2\pi i}\oint_{\partial\mathbb{D}}{\sum_{n=0}^\infty{\frac{\overline{a_nz^n}}{z}f(z)}\,dz} \\ &=\frac{1}{2\pi i}\oint_{\partial\mathbb{D}}{\overline{g(z)}f(z)\,\frac{dz}{z}} \end{align*} since $\overline{z}z=1$ on the contour.
Conversely, one can begin with that inner product directly: it is straightforward to verify that it is an inner product (taking the complex conjugate of the differential is the same as changing variables to $z^{-1}$…or just traversing the contour in the opposite direction). But then $$\langle p_n,f\rangle=\frac{1}{2\pi i}\oint_{\partial\mathbb{D}}{\overline{z}^nf(z)\,\frac{dz}{z}}=\frac{1}{2\pi i}\oint_{\partial\mathbb{D}}{\frac{f(z)}{z^{n+1}}\,dz}=\frac{f^{(n)}(0)}{n!}$$ again by Cauchy's formula.
Lastly, the technical details: does this inner product make the space of "analytic functions on $\mathbb{D}$" Hilbert? Yes, because we can compute the value at any point on the interior from the boundary via Cauchy's theorem and a Möbius transform. Thus convergence in $L^2$ on the boundary implies in fact uniform convergence on the interior. And is that Hilbert space dense in $V$? Yes, because it contains all polynomials.
The real-variable case
Ideally, $$\langle p_n,p_m\rangle=\delta_{n,m}$$ where $\delta$ is Kronecker's delta; as much holds in the complex-variable case. But one cannot hope for so simple a result, for then $$1=\langle p_m,p_m\rangle=\langle p_{2m},p_0\rangle=0$$ for any nonzero $m$.
Worse, the existence of bump functions inhibits any relaxation to other families of orthogonal polynomials. To be precise, given any open set $U$ disjoint from $0$, there exists a bump function $\phi$ supported on $U$. Adding $\phi$ to $f$ changes the values of $f$ on $U$, but does not modify $f$'s Taylor series away from $U$.
Formally, the "Maclaurin series map" $M$, which sends each function in $V$ to its corresponding Maclaurin series, factors through the stalk at the origin: the quotient vector space $\mathcal{G}$ in which we identify elements of $V$ that coincide on any neighborhood of $0$. (I have chosen the letter $\mathcal{G}$, because elements of that vector space are often called "germs of functions.")
But expansion in a generalized Fourier series is an isometric map. Rearrangement is not isometric, but it is bijective, because a rearranged series can always be "unrearranged." Identifying along the composite bijection, $H$ must intersect $\mathcal{G}$ densely in both vector spaces.
Thus we have no hope of writing an inner product on $H$ that is "just" an integral; any measure for such an integral would be supported at precisely $\{0\}$. Indeed, let $\delta_0^{(n)}:\mathcal{G}\to\mathbb{R}$; $$\delta_0^{(n)}(f)=f^{(n)}(0)$$ Then the span of $\{\delta_0^{(n)}\}_n$ is dense in $\mathcal{G}^*$. Any inner product must be built out of derivatives at $0$ alone.
Much like the complex case, figuring out the inner product is now just an computation: represent each element of $\mathcal{G}$ by the sequence of derivatives at $0$; thus \begin{gather*} f=(f(0),f'(0),f''(0),\dots) \\ p_0=(1,0,0,\dots) \\ p_1=(0,1,0,\dots) \\ p_2=(0,0,2,\dots) \\ p_n=(\dots,0,n!,\dots) \end{gather*} where the $n!$ appears in the $n$th coordinate (with zero-based indexing). We seek a bilinear form on these infinite sequences such that $$\langle p_n,f\rangle=\frac{f^{(n)}(0)}{n!}\text{;}$$ it is immediate that $$\langle f,g\rangle=\sum_{n=0}^{\infty}{\frac{f^{(n)}(0)g^{(n)}(0)}{n!^2}}$$ will do the job.