Main question
$$
\int_0^1{\frac{\sin \left( \pi x \right)}{x^x\left( 1-x \right) ^{1-x}}}\mathrm{d}x
$$
This is a famous integral. It can be evaluated by contour integration, and it equals to $\pi/e$.
I tried to generalized it, and I wrote
$$
I_{\alpha}=\int_0^{\alpha}{\frac{\sin \left( \pi x \right)}{x^x\left( \alpha -x \right) ^{\alpha -x}}}\mathrm{d}x
$$
here $\alpha\in\left(0,\infty\right)$. By substituting $x=\frac{\alpha}{e^t+1}$, $I_{\alpha}$ becomes
$$
\alpha ^{1-\alpha}\int_{-\infty}^{\infty}{\frac{e^{t\left( 1-\alpha \right)}}{\left( 1+e^t \right) ^{2-\alpha}}\sin \left( \frac{\alpha \pi}{e^t+1} \right) \exp \left( \frac{\alpha t}{e^t+1} \right)}\mathrm{d}x
$$
Or equivalently
$$
\alpha ^{1-\alpha}\int_{\infty}^{-\infty}{\frac{e^{t\left( 1-\alpha \right)}}{\left( 1+e^t \right) ^{2-\alpha}}\sin \left( \frac{-\alpha \pi}{e^t+1} \right) \exp \left( \frac{\alpha t}{e^t+1} \right)}\mathrm{d}x
$$
This implies
\begin{align*}
I_{\alpha}&=\alpha ^{1-\alpha}\Im \left\{ \int_{-\infty}^{\infty}{\frac{e^{t\left( 1-\alpha \right)}}{\left( 1+e^t \right) ^{2-\alpha}}\exp \left( \frac{\alpha \left( t+i\pi \right)}{e^t+1} \right)}\mathrm{d}x \right\}
\\&
=\alpha ^{1-\alpha}\Im \left\{ \int_{\infty}^{-\infty}{\frac{e^{t\left( 1-\alpha \right)}}{\left( 1+e^t \right) ^{2-\alpha}}\exp \left( \frac{\alpha \left( t-i\pi \right)}{e^t+1} \right)}\mathrm{d}x \right\}
\end{align*}
Then I tried to apply contour integration here.
$$
f\left( z \right) =\frac{e^{z\left( 1-\alpha \right)}}{\left( 1-e^z \right) ^{2-\alpha}}\exp \left( \frac{\alpha z}{1-e^z} \right)
$$
The contour I used

I integrate this contour clockwise. By residue theorem $$ \oint_C{f\left( z \right) \mathrm{d}z}=\int_{\psi _-}{+\int_{\psi _+}{+}\int_{\phi _-}{+}\int_{\phi _+}{f\left( z \right) \mathrm{d}z}}=2\pi i\mathrm{Res}\left[ f\left( z \right) ,0 \right] $$ The vertical parts actually vanish when $R$ approaches infinity. As for the horizontal part, since $$ f\left( x+i\pi \right) =\frac{e^{x\left( 1-\alpha \right)}e^{i\pi \left( 1-\alpha \right)}}{\left( 1+e^x \right) ^{2-\alpha}}\exp \left( \frac{x+i\pi}{1+e^x} \right) \\ f\left( x-i\pi \right) =\frac{e^{x\left( 1-\alpha \right)}e^{i\pi \left( \alpha -1 \right)}}{\left( 1+e^x \right) ^{2-\alpha}}\exp \left( \frac{x-i\pi}{1+e^x} \right) $$ therefore, by adding the horizontal part together, there is $$ \Im \left\{\int_{\psi _-}{+\int_{\psi _+}{f\left( z \right) \mathrm{d}z}}\right\} = \frac{2\cos \left( \pi \left( \alpha -1 \right) \right)}{\alpha ^{1-\alpha}} I_{\alpha} $$ So I have $$ I_{\alpha}=\alpha ^{1-\alpha}\Im \left\{ \frac{\pi i\mathrm{Res}\left[ f\left( z \right) ,0 \right]}{\cos \left( \pi \left( \alpha -1 \right) \right)} \right\} $$ Then I was stuck. How do I calculate this residue? It's somehow very difficult for me... Have I done anything worng?
Addendum 1
There are few questions stemmed form this question. Such as $$ J_{\alpha}=\int_0^{\alpha}{\frac{\sin \left( \pi x/\alpha \right)}{x^x\left( \alpha -x \right) ^{\alpha -x}}}\mathrm{d}x \\ K_{\alpha ,\beta}=\int_0^{\alpha}{\frac{\sin \left( \pi x \right)}{x^{x+\beta}\left( \alpha -x \right) ^{\alpha -x}}}\mathrm{d}x \\ L_{\alpha ,\beta}=\int_0^{\alpha}{\frac{\sin \left( \pi x/\alpha \right)}{x^{x+\beta}\left( \alpha -x \right) ^{\alpha -x}}}\mathrm{d}x $$ which I doubt a closed form even exist.
Another interesting thing, it seems that $$ K_{1,1}=\int_0^1{\frac{\sin \left( \pi x \right)}{x^{1+x}\left( 1-x \right) ^{1-x}}}\mathrm{d}x=\pi $$
Addendum 2
For $\alpha=n\in\mathbb{N}$, $e^{i\pi\left(1-\alpha\right)}$ and $e^{i\pi\left(\alpha-1\right)}$ actually evaluates in the same sign so the expression simplifies to
$$I_n=n ^{1-n}\Im \left\{ \pi i\mathrm{Res}\left[ f\left( z \right) ,0 \right]\right\} $$
and this actually evaluates to
$$I_n=\frac{\pi}{e}\delta_{n,1}$$
Given by what desmos graphed this seems to be truth
Plus, I was noted by the comment that my previous method has a branch cut problem. So I might want to modify contour $C$ a little bit to exclude the branch cut. I took a look at $f(z)$ and it seems that there're branch points in $i2\mathbb{Z}\pi$. My thought currently is to aim the brach of the ones bigger than $0$ upward and the rest of it downward and make a little "key hole branch" from below. Don't know if that works tho.
$\newcommand{\d}{\,\mathrm{d}}\newcommand{\I}{\mathcal{I}}\newcommand{\D}{\mathfrak{D}}\newcommand{\res}{\operatorname{Res}}$This is a partial answer that addresses a slightly different generalisation and the evaluation $\I_n=0$ for integer $n\ge2$.
Let's fix $\alpha>0$ and define $\beta:=\{\alpha\}$ the fractional part of $\alpha$. We could also use $\beta:=\{\alpha\}+n$ where $n$ is some fixed positive integer. This would generalise the results slightly but make the notation more difficult (more cases to handle, really).
The key point is that $\alpha-\beta$ will then be an integer, and exponentiation can be extended to a holomorphic function. I tried to experiment with different regularising terms to handle the original version of $K_{\alpha,\beta}$ but I had no luck. It is my belief that complex analysis cannot handle your question in full generality, and that any solution should at least involve some clever substitutions or series expansions that remove some of these problems. For example, if we could massage the integrand so that only one branch cut appears, this would be nice as a keyhole integration could become an option.
Enough waffle: here is my progress. $$\begin{align}\I(\alpha)&:=(-1)^{1+\lfloor\alpha\rfloor}\int_0^\alpha\frac{\sin\pi x}{x^x(\alpha-x)^{\lfloor\alpha\rfloor-x}}\d x\\&=\int_0^\alpha\frac{\sin\pi(x-\beta)}{x^{x-\beta}(\alpha-x)^{\alpha-x}}\d x\\&=\begin{cases}-\frac{\pi\alpha^2}{2}e^{-\alpha}&0<\alpha<1\\\pi e^{-\alpha}&1\le\alpha<2\\0&\alpha\ge2\end{cases}\end{align}$$
A nice side effect that follows from manipulation of the $0<\alpha<1$ case: $$\int_0^\alpha\sin(\pi s)(\alpha\cdot s^{-1}-1)^s\d s=\frac{\pi}{2}\cdot\alpha^2e^{-\alpha}$$Which will hold for all real $\alpha$.
In particular this is enough to show $\I_n=0$ when $n\ge2$, since $\beta=0$ when $\alpha$ is an integer. It is very surprising to me that the integral is always zero for larger $\alpha$, since the integrand is not actually symmetric when $\alpha\notin\Bbb Z$. Weird.
The method is as follows. Define logarithms $\log'$ by $0\le\arg z<2\pi$ and $\log$ by $-\pi\le\arg z<\pi$. Define $f:\Bbb C\to\Bbb C$ by: $$z\mapsto\frac{e^{i\pi(z-\beta)}}{z^{z-\beta}\cdot(\alpha-z)^{\alpha-z}}$$Where $z^{z-\beta}$ is computed with $\log'$ and $(\alpha-z)^{\alpha-z}$ is computed with $\log$. Then, using the fact that $\alpha-\beta\in\Bbb Z$, we can check that $f$ is holomorphic on $\Bbb C\setminus[0,\alpha]$. The two branch cuts on $[0,\infty),[\alpha,\infty)$ cancel each other out on $(\alpha,\infty)$. I will write up the details of that later, if you wish, but this is a standard setup in contour integration.
Then, we integrate around the "dogbone" contour $\D$ which consists of straight lines $i\epsilon\to\alpha+i\epsilon$, $\alpha-i\epsilon\to-i\epsilon$, and clockwise semicircles of radius $\epsilon$ that run $\alpha+i\epsilon\to\alpha-i\epsilon$ and $-i\epsilon\to i\epsilon$, where $\epsilon>0$ is fixed. $\D$ encloses the branch cut $[0,\alpha]$, so that $f$ is holomorphic on the exterior of $\D$. We then know that: $$\frac{1}{2i}\oint_{\D}f(z)\d z=\pi\cdot\res(f,\infty)$$
Fix $0<x<\alpha$. We can see that: $$\lim_{y\to0^+}f(x+iy)=\frac{e^{i\pi(x-\beta)}}{x^{x-\beta}\cdot(\alpha-x)^{\alpha-x}}$$Whereas: $$\lim_{y\to0^-}f(x+iy)=\frac{e^{-i\pi(x-\beta)}}{x^{x-\beta}\cdot(\alpha-x)^{\alpha-x}}$$
Because $\lim_{z\to0,\alpha}z\cdot f(z)=0$, it follows that as $\epsilon\to0^+$ the integrals around the semicircles of $\D$ vanish. Since shrinking $\epsilon\to0^+$ deforms $\D$ within the domain of holomorphy of $f$, doing this does not change the value of the integral.
We then get: $$\I(\alpha)=\frac{1}{2i}\oint_{\D}f(z)\d z=\pi\cdot\res(f,\infty)$$
So it remains to compute the residue. The residue at infinity is $(-1)$ multiplied by the $[z^{-1}]$ coefficient of $f$'s "power series at infinity". Since this series shall be valid for all $|z|>\alpha$, to determine these coefficients I can make my life easier and only consider real $z$. To that end, let $x>\alpha$ be real. We see easily that: $$f(x)\sim x^{\beta-\alpha}$$As $x\to\infty$. There are three cases: $\alpha-\beta=0,1$ or $\alpha-\beta\ge2$. These correspond to the three cases $0<\alpha<1$, $1\le\alpha<2$ and $\alpha\ge2$.
In the first case, we see $f$'s power series has a nonzero constant term and - since $f$ is bounded at infinity - must be of the form $a_0-\res(f,\infty)x^{-1}+a_2x^{-2}+\cdots$. Then I can identify: $$\res(f,\infty)=\lim_{x\to\infty}x^2\cdot f'(x)$$
Using: $$f(x)=x^{\beta-\alpha}(1-\alpha/x)^{x-\alpha},\,\text{$x>\alpha$ is real}$$I can compute the residue to be $-\frac{\alpha^2}{2}e^{-\alpha}$ when $\beta-\alpha=0$. This handles the first case.
In the second case, $\alpha-\beta=1$, I know the power series looks like $-\res(f,\infty)x^{-1}+a_2x^{-2}+\cdots$. To find the residue, I simply compute: $$\lim_{x\to\infty}-x\cdot f(x)=e^{-\alpha}$$
Giving the result for the second case.
In the final case, because $\beta-\alpha\le-2$ I know the power series looks like $a_2x^{-2}+\cdots$. The $[x^{-1}]$ coefficient is nonexistent: $\lim_{x\to\infty}x\cdot f(x)=0$ in this case. Therefore $\I(\alpha)=0$ if $\alpha\ge2$.
I hope that is at least interesting and I apologise that it isn't quite the generalisation you were expecting. I am hopeful for a better answer later.