This is a good idea. I think what you'd want to do is override the generate_sql function and store the question with the "related" metadata and the generated sql somewhere:
https://github.com/vanna-ai/vanna/blob/main/src/vanna/base/b...
We're going to be adding a generic logging function soon and fairly soon what you're talking about could just be a custom logger.