Suppose that $G$ is a torsion-free nilpotent group. It is a classical fact that if $g,h \in G$ have powers that commute, then $g$ and $h$ must commute. So if there are integers $m,n$ such that $[g^m,h^n] = 1$, then $[g,h] = 1$. This is usually proved as a consequence of the fact that torsion-free nilpotent groups have unique roots (see the chapter on nilpotent groups in Fundamentals of the Theory of Groups, by M. I. Kargapolov , J. I. Merzljakov). Note that the torsion-freeness is obviously a necessary condition for this property to hold.
I am wondering if this identity extends to higher commutators. For $g_1, \dots, g_n \in G$, inductively define $[g_1, \dots, g_n] = [[g_1, \dots, g_{n-1}],g_n]$, where $[g_1,g_2] = g_1^{-1}g_2^{-1}g_1g_2$ has the usual meaning. Given elements $g_i$ in a torsion-free nilpotent group $G$ and integers $k_i$, my question is whether $$[g_1^{k_1}, \dots, g_n^{k_n}] = 1 \quad \Rightarrow \quad [g_1, \dots, g_n] = 1.$$ I have tried proving this by induction on $n$, with no success. One can also approach this by induction on the nilpotency class of $G$, but I haven't gotten very far with this either. Indeed if $[g_1^{k_1}, \dots, g_n^{k_n}] = 1$ in $G$, then the same equation holds in the torsion-free nilpotent group $G/Z(G)$ of lower nilpotency class. Hence, we obtain that $[g_1, \dots, g_n]$ is central in $G$. We also know that $g_n$ commutes with $[g_1^{k_1},\dots,g_{n-1}^{k_{n-1}}]$, but I don't see how to continue.