Intuitively, $\frac{\sum w_i a_i}{\sqrt{\sum w_i^2 b_i}}$ looks like a ratio between a $L_1$ norm and $L_2$ norm.
To provide motivation, we consider i.i.d. $(x_i, y_i)$ and $\text{Var}[x_i] = \sigma_{i}^2, \text{Var}[x_i] = \tau_{i}^2, \text{Cov}[x_i, y_i] = r_{i}$. We wish to find the linear combination of $\sum w_i x_i$ such that $\text{Cor}[\sum w_i x_i, \sum y_i]$ is maximized.
$$ \text{Cor}\left[\sum w_i x_i, \sum y_i \right] \propto \frac{\sum w_i \text{Cov}[x_i, y_i]}{\sqrt{\sum w_i^2 \text{Var}[x_i]}} = \frac{\sum w_i r_i}{\sqrt{\sum w_i^2 \sigma_i^2}} $$