I have a function that returns results that always can be represented as $p+q\,\pi^2+r\ln2+s\ln^22+t\sqrt2$ where $p,q,r,s,t\in\mathbb Q$. But the actual Mathematica expression returned not always in exactly this form, e.g. it can be
1/Sqrt + 1/54 (34 - 3 π^2 + (-8 + Log) Log)
It's not difficult to extract rational coefficients from this expression manually, but I need to process hundreds of expressions, so I want to make this process automated. How can I do this?