Consider an element $X\in\mathfrak g$ of some Lie algebra $\mathfrak g$. I understand that $\mathfrak g$ can be represented via its action on other elements of the same algebra, as $\operatorname{ad}(X)Y\equiv[X,Y]$, so that $\operatorname{ad}(X)\in\operatorname{GL}(\mathfrak g)$.
One often considers things such as the trace of these objects (e.g. when considering the Killing form), or more generally the "matrix elements" of operators such as $\operatorname{ad}(X)$.
However, I usually don't see any direct mention of the inner product with respect to which these things are defined. To properly define what something such as $\operatorname{ad}(X)_{ij}$ is, don't I need to be able to define uniquely the coefficient of the generator $X_i$ in the decomposition of $[X,X_j]$ (denoting with $\{X_i\}$ the elements of some basis for the algebra)?
Is there a canonical choice of such inner product? And on a similar note, do we just usually assume that the basis of the Lie algebra is orthonormal (or at least orthogonal) with respect to this inner product?
Consider $\mathfrak{sl}_2$ with basis $\{e,f,h\}$. You have $$ad(e)(e)=0,\;\;\;ad(e)(f)=h,\;\;\;ad(e)(h)=-2e$$ so the matrix of $ad(e)$ in this basis is $$ \begin{pmatrix}0&0&-2\\0&0&0\\0&1&0\end{pmatrix} $$ which has trace 0.
You can check that the matrix for $ad(h)$ is $$ \begin{pmatrix}2&0&0\\0&-2&0\\0&0&0\end{pmatrix} $$ which again has trace 0. Can you do $ad(f)$?