Group freely generated by monoid There are several ways to define the group freely generated by a monoid, all of which (necessarily) produce isomorphic groups. One way starts with a presentation of the monoid, and simply reinterprets this as a presentation of the group. Another way is to formally adjoin the inverse of every element of the monoid.  Yet another approach is to do something akin to the construction of the field of fractions of a ring, by considering equivalence classes of pairs of elements in the monoid.  (Actually what I had in mind for that last one only works in the commutative case.)
As far as I can tell, all of these approaches involve making drastic changes to the underlying sets, and I am wondering whether there is a way of doing this that literally extends the underlying set. More formally, I ask the following:

Question. Given a set $S$ together with a multiplication $m$ and an identity $e$
  satisfying the monoid axioms, how do we explicitly construct (in terms of $S,m,e$) a set $T$, a multiplication $m'$, and an inverse $i$ such that:
  
  
*
  
*$S\subseteq T$
  
*$m'|_{S\times S}=m$
  
*$(T,m',i,e)$ is a group
  

For example, any such construction would presumably embed the additive monoid $\mathbb N$ in $\mathbb Z$, whereas the multiplicative monoid $\mathbb N^{\times}$ would presumably be embedded in $\mathbb Q^+$.
It will be a nice bonus if this construction is functorial (i.e., there is a way of extending the definition such that it associates to each monoid homomorphism a group homomorphism between the constructed groups).

This question is motivated by some variations in which I do know of such a construction: namely, the construction of free monoids on a set and free groups on a set. The former case, which I will shortly describe, is quite simple and elegant while the latter case is more ugly and complicated. So I was wondering if there was a nicer way to "factorize" the construction of a free group into two pieces, each nicer on their own than the composite: first build the free monoid on the set, then build the free group on the constructed monoid.
The free monoid construction. Given a set $S$, let
$$
S^\star=\bigsqcup_{n=0}^{\infty}S^n.
$$
Turn $S^\star$ into a monoid by defining a multiplication $m\colon S^n\times S^m\to S^{n+m}$ in the obvious way (i.e. concatenation of tuples). The identity is the unique element of $S^0$. This construction is functorial in an obvious way.
The free group construction. I won't spell out the details since they are ugly. Given the generating set $S$, one considers a subset of
$$
\bigsqcup_{n=0}^{\infty}(S\sqcup S)^n
$$
consisting of "reduced words" (where the second copy of $S$ is thought of as formal inverses to the first copy of $S$) and the multiplication consists of concatenation followed by reduction. This is also functorial, but requires some work to show this explicitly.
One more comment: a (functorial) answer to my question will yield (after composing with the forgetful functor from groups to monoids) an interesting monad in the category of monoids, whose Eilenberg-Moore category is equivalent to the category of groups. (This is actually what I am trying to find an explicit description for, but I have phrased my question in a more elementary way since I think it better focuses the question on where my difficulties lie.)
 A: The left adjoint of the forgetful functor $\mathfrak{G}roup\to\mathfrak{M}onoid$ is the "universal enveloping group functor" (rather than "free group", which already has a meaning). In the commutative case, it is sometimes called the "Grothendieck group of the monoid", since Grothendieck re-discovered the construction independently and it became known to many through his work. Given a monoid $S$ (in fact, you can do this with a semigroup), it is a group $T$ and a monoid morphism $\phi\colon S\to T$ such that any monoid morphism $u\colon S\to G$ into a group will factor through $\phi$: there exists a unique group homomorphism $f\colon T\to G$ such that $u=f\phi$.
Now, $\phi$ need not be an embedding. In fact, $\phi$ is an embedding if and only if $S$ is a cancellation monoid${}^1$: for all $a,b,c\in S$, if $ab=ac$ then $b=c$ and if $ba=ca$, then $b=c$. It should be clear that this is necessary, since that will hold in $T$. The fact that it is also sufficient follows from any of the usual constructions. Since $S$ embeds into a group if and only if it embeds into $T$, and you cannot hope to find a realization of $T$ with $S\subseteq T$ unless $\phi$ is an embedding, we require this condition for your request to even be possible.

${}^1$ Cancellative is necessary and sufficient in the commutative case. It is necessary in the noncommutative case, but not sufficient. Necessary and sufficient conditions are derived by Mal'cev in Uber die Einbettung von assoziativen Systemen in Gruppen (Russian, German summary) Mat. Sb. N.S. 6 (1939) 331-336 MR 2, 7d; and *Uber die Einbettung von assoziativen Systemen in Gruppen, II (Russian, German summary) Mat. Sb. N.S. 8 (1940) 251-264, MR 2 128b. They are described in P.M. Cohn's Universal Algebra, 2nd edition, Reidel 1981, MR 82j:08001, Section VII.3.

I mistakenly wrote it was necessary and sufficient in all cases.

One of course can construct the monoid $T$ to technically contain $S$ as a submonoid; any of the usual constructions will do that, by identifying $S$ with $\phi(S)$ and taking $T'=(T\setminus \phi(S))\sqcup S$. Not sure that you gain anything doing this "formally" instead of simply nominally identifying $S$ with $\phi(S)$ when $\phi$ is one-to-one. 
I also note, as mentioned in the comments, that George Bergman has proven that  for every positive integer $n$ there exists a group $G$ and a submonoid $M$ of $G$ such that (i) $M(M^{-1})\cdots M^{(-1)^n}=G$; but (ii) $G\neq M(M^{-1})\cdots M^{(-1)^{n-1}}$. So the "complexity" of an element of $G$ in terms of how many alternating factors of $M$ and their inverses cannot be bound in general (in the commutative case,  it of course suffices to look at $MM^{-1}$). 
