  Let $X$ be a scheme of finite type over a finite field $k$, and let $\mathcal
L X$ denote its arc space; in particular, $\mathcal L X(k) = X(k[[t]])$. Using
the theory of Grinberg, Kazhdan, and Drinfeld on the finite-dimensionality of
singularities of $\mathcal L X$ in the neighborhood of non-degenerate arcs, we
show that a canonical "basic function" can be defined on the non-degenerate
locus of $\mathcal L X(k)$, which corresponds to the trace of Frobenius on the
stalks of the intersection complex of any finite-dimensional model. We then
proceed to compute this function when $X$ is an affine toric variety or an
"$L$-monoid". Our computation confirms the expectation that the basic function
is a generating function for a local unramified $L$-function; in particular, in
the case of an $L$-monoid we prove a conjecture formulated by the second-named
author.
