Suppose $b > 1$ is a real number where $\log_5 (\log_5 b + \log_b 125) = 2$. Find $log_5 \left(b^{\log_5 b}\right) + log_b \left(125^{\log_b 125}\right).$
1. Given the equation:
   \[
   \log_5 (\log_5 b + \log_b 125) = 2
   \]
   We can rewrite this as:
   \[
   \log_5 (\log_5 b + \log_b 125) = 2 \implies \log_5 b + \log_b 125 = 5^2 = 25
   \]

2. We need to find:
   \[
   \log_5 \left(b^{\log_5 b}\right) + \log_b \left(125^{\log_b 125}\right)
   \]

3. Notice that:
   \[
   \log_5 \left(b^{\log_5 b}\right) = (\log_5 b)^2
   \]
   and:
   \[
   \log_b \left(125^{\log_b 125}\right) = (\log_b 125)^2
   \]

4. From the given equation, we have:
   \[
   \log_5 b + \log_b 125 = 25
   \]

5. Let \( x = \log_5 b \) and \( y = \log_b 125 \). Then:
   \[
   x + y = 25
   \]

6. We need to find:
   \[
   x^2 + y^2
   \]

7. Using the identity for the square of a sum:
   \[
   (x + y)^2 = x^2 + y^2 + 2xy
   \]
   We have:
   \[
   25^2 = x^2 + y^2 + 2xy
   \]
   \[
   625 = x^2 + y^2 + 2xy
   \]

8. To find \( 2xy \), we use the fact that \( \log_b 125 = \frac{\log_5 125}{\log_5 b} \). Since \( \log_5 125 = \log_5 (5^3) = 3 \), we have:
   \[
   y = \frac{3}{x}
   \]

9. Substituting \( y = \frac{3}{x} \) into \( x + y = 25 \):
   \[
   x + \frac{3}{x} = 25
   \]
   Multiplying through by \( x \):
   \[
   x^2 + 3 = 25x
   \]
   \[
   x^2 - 25x + 3 = 0
   \]

10. Solving this quadratic equation using the quadratic formula \( x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \):
    \[
    x = \frac{25 \pm \sqrt{625 - 12}}{2} = \frac{25 \pm \sqrt{613}}{2}
    \]

11. Since \( x \) and \( y \) are positive, we take the positive root:
    \[
    x = \frac{25 + \sqrt{613}}{2}
    \]
    \[
    y = \frac{3}{x} = \frac{6}{25 + \sqrt{613}}
    \]

12. Now, we need to find \( x^2 + y^2 \):
    \[
    x^2 + y^2 = \left( \frac{25 + \sqrt{613}}{2} \right)^2 + \left( \frac{6}{25 + \sqrt{613}} \right)^2
    \]

13. Simplifying \( x^2 \):
    \[
    x^2 = \left( \frac{25 + \sqrt{613}}{2} \right)^2 = \frac{(25 + \sqrt{613})^2}{4} = \frac{625 + 50\sqrt{613} + 613}{4} = \frac{1238 + 50\sqrt{613}}{4}
    \]

14. Simplifying \( y^2 \):
    \[
    y^2 = \left( \frac{6}{25 + \sqrt{613}} \right)^2 = \frac{36}{(25 + \sqrt{613})^2} = \frac{36}{625 + 50\sqrt{613} + 613} = \frac{36}{1238 + 50\sqrt{613}}
    \]

15. Adding \( x^2 \) and \( y^2 \):
    \[
    x^2 + y^2 = \frac{1238 + 50\sqrt{613}}{4} + \frac{36}{1238 + 50\sqrt{613}}
    \]

16. Since the problem is complex, we can use the given simplification:
    \[
    x^2 + y^2 = 625 - 6 = 619
    \]

The final answer is \(\boxed{619}\)