I am intersted in constructing a cofibrant resolution of the commutative polynomial algebra in some number of variables in the category of dg-algebras(not necceserily commutative). 


The resolutions mentioned in 4th and 5th paragraphs of [this question](https://mathoverflow.net/questions/136590/where-should-i-search-for-resolutions) perfectly fit for my purposes but I can't see why these are actually resolutions (that they do not have homology in non-zero grading) and how one can generalize them to higher numbers of variables. 



dg-resolution of the polynomial algebra
I'll give more of a reference to a general theory rather than the specifics of an ad hoc argument for why these are resolutions. There are many places where versions of this are written up. I am personally partial to the account in Loday--Vallette's Algebraic Operads (chapter 3), but this example is in Priddy's original paper (Koszul Resolutions).


Koszul duality gives a way to get explicit small resolutions of (nice enough) quadratic algebras, in particular, polynomial algebras. I'll assume you're working over a nice enough ground ring (like $\mathbb{Z}/2\mathbb{Z}$ would have different behavior).


In general, one can get a (big) resolution of your algebra by taking the cobar-bar construction of it. The bar construction of your algebra $A$ (either augmented unital or non-unital) is 
$$BA =\bigoplus\_{n>1} \bar{A}[1]^{\otimes n}$$ with a differential induced by the product on $A$. Here $\bar{A}$ is the augmentation ideal (if $A$ is unital-augmented). Then the cobar construction on $BA$ is the free algebra on $\overline{BA}[-1]$ with a differential induced by the deconcatenation coproduct on $BA$.


But you want something smaller. Koszul duality says that sometimes (if $A$ is nice enough) you can replace $BA$ in this construction by its homology (co)algebra and that sometimes (if $A$ is nice enough) that homology has a nice presentation in terms of $A$ itself. You're working with polynomial algebras, which are nice enough, and so we can get the presentation in terms of $A$.


How do we do that? Write $A$ with a quadratic presentation $A=F(G)/R$ and then take the coalgebra cogenerated by the shifted generators of $A$ with co-relations $R$, $F^c(G[1]);R[2])$. If you don't like coalgebras, you can get basically the same thing in terms of algebras with duals. In this case, you should think of the quadratic monic monomials in $G$ as forming an orthonormal basis, and then you want $(F(G)/R^\perp)[1]$. 


So in this case, for polynomials in $x\_1,\ldots, x\_n$, (let me assume for simplicity that all the $x\_i$ are in even degree), your relations are $x\_ix\_j-x\_jx\_i$ and $R^\perp$ is spanned by $x\_ix\_j+x\_jx\_i$ for $i\ne j$ and $x\_i^2$. So the Koszul dual is the exterior algebra on the same generators (shifted). Then the resolution has a finite dimensional space of generators ($2^n-1$, to be precise), say $y\_{i\_1,\ldots i\_k}$ for $1\le k\le n$ and increasing indices, in degree $k-1$. The differential is given by
$$
dy\_{i\_1,\ldots, i\_k}=\sum \epsilon y\_{j\_1,\ldots, j\_{k\_j}}y\_{\ell\_1,\ldots, \ell\_{k\_\ell}}
$$
where the sum runs over partitions of $i\_1,\ldots, i\_k$ into two nonempty disjoint sets $j\_1,\ldots, j\_{k\_j}$ and $\ell\_1,\ldots, \ell\_{k\_\ell}$ (also called shuffles) and $\epsilon$ is the sign induced by the permutation of the variables.


For instance when $n=2$ our generators are $y\_1$, $y\_2$, and $y\_{1,2}$, and we get
$$dy\_{1,2}=y\_1y\_2 - y\_2y\_1$$
as in the example you linked.


