I'm not sure what your end goal is precisely but just to save you some trouble let me remind that showing what spell to press next is possible.
Making a button that will "intelligently" decide what to show and let you press it to cast that thing is
impossible
Addons cannot make combat decisions outside of what would be possible to
do with a macro.
All priority / rotation helpers (like for example Hekili) work under that principle "show not do", you still have to press the buttons.