If $A$ is a $k$-algebra, and $(T(M), j_M)$ denotes the tensor algebra of an $A$-bimodule $M$, $j_M: M \to T(M)$ the associated homomorphism of $A$-bimodules, how can I prove that $$T(M \oplus N)\cong T(M) \otimes_AT(N) $$
as $k$-algebras? I tried the following: define an homomorphism of $f:M \oplus N \to T(M) \otimes_AT(N)$ by $f(m,n)=j_M(m) \otimes j_N(n)$. Then, there is an unique homomorphism (of $k$-algebras and $A$-bimodules) $\bar{f}:T(M \oplus N) \to T(M) \otimes_AT(N)$ such that $\bar{f} \circ j_{M \oplus N}=f$.
Any ideas how to define an inverse $\bar{g}:T(M) \otimes_AT(N) \to T(M \oplus N)$?