The problem is that in the decorator, you just get the compiled function. So you can modify the bytecode but not operate on the AST anymore.
I thought about this and wrote a patch for CPython that it also stores the original AST of any compiled function in the function object.
Some discussion about this: