Frameworks for Quantum Algorithms