Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hook for pre-processing the LLM-generated SQL before execution. #155

Closed
xtructure opened this issue Jan 17, 2024 · 1 comment · Fixed by #157
Closed

Hook for pre-processing the LLM-generated SQL before execution. #155

xtructure opened this issue Jan 17, 2024 · 1 comment · Fixed by #157
Assignees
Labels
enhancement New feature or request

Comments

@xtructure
Copy link

Add an optional callback to the Vanna API so that the SQL that is generated by an LLM can be examined/modified prior to execution.

@zainhoda zainhoda self-assigned this Jan 17, 2024
@zainhoda zainhoda added the enhancement New feature or request label Jan 17, 2024
@zainhoda zainhoda linked a pull request Jan 17, 2024 that will close this issue
@zainhoda
Copy link
Contributor

You can now override this method to add your own validation:

def extract_sql(self, llm_response: str) -> str:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

Successfully merging a pull request may close this issue.

2 participants