-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[NL-to-ESQL] refactor and improve the task's workflow #192850
[NL-to-ESQL] refactor and improve the task's workflow #192850
Conversation
Great to see you dumb this down for the mere mortals @pgayvallet !!! |
/ci |
/ci |
/ci |
Pinging @elastic/appex-ai-infra (Team:AI Infra) |
@elasticmachine merge upstream |
💛 Build succeeded, but was flaky
Failed CI StepsTest FailuresMetrics [docs]Public APIs missing exports
History
To update your PR or re-run it, just comment with: |
## Summary Some cleanup and minor enhancements, just to get my hands on that part of the code. evaluation framework was run against gemini1.5, claude-sonnet and GPT-4, with a few improvements ### Cleanup - Refactor the code to improve readability and maintainability ### Improvements - Add support for keyword aliases (turns out, some models asks for `STATS...BY` and not `STATS`) - Add (naive for now) support for suggestion (to try to influence the model on using some function instead of others, e.g group by time with BUCKET instead of DATE_TRUNC) - Generate "this command does not exist" documentation when the model request a missing command (help making it understand it shouldn't use the command, e.g gpt-4 was hallucinating a `REVERSE` command) --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> (cherry picked from commit 0fc191a)
💔 Some backports could not be created
Note: Successful backport PRs will be merged automatically after passing CI. Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
…2850) (#193207) # Backport This will backport the following commits from `main` to `8.x`: - [[NL-to-ESQL] refactor and improve the task's workflow (#192850)](#192850) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Pierre Gayvallet","email":"pierre.gayvallet@elastic.co"},"sourceCommit":{"committedDate":"2024-09-17T16:54:36Z","message":"[NL-to-ESQL] refactor and improve the task's workflow (#192850)\n\n## Summary\r\n\r\nSome cleanup and minor enhancements, just to get my hands on that part\r\nof the code.\r\n\r\nevaluation framework was run against gemini1.5, claude-sonnet and GPT-4,\r\nwith a few improvements\r\n\r\n### Cleanup\r\n\r\n- Refactor the code to improve readability and maintainability\r\n\r\n### Improvements\r\n\r\n- Add support for keyword aliases (turns out, some models asks for\r\n`STATS...BY` and not `STATS`)\r\n- Add (naive for now) support for suggestion (to try to influence the\r\nmodel on using some function instead of others, e.g group by time with\r\nBUCKET instead of DATE_TRUNC)\r\n- Generate \"this command does not exist\" documentation when the model\r\nrequest a missing command (help making it understand it shouldn't use\r\nthe command, e.g gpt-4 was hallucinating a `REVERSE` command)\r\n\r\n---------\r\n\r\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"0fc191aa320db4b7949f1c2d47a273a5362029c8","branchLabelMapping":{"^v9.0.0$":"main","^v8.16.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-major","Team:Obs AI Assistant","ci:project-deploy-observability","v8.16.0","Team:AI Infra"],"title":"[NL-to-ESQL] refactor and improve the task's workflow","number":192850,"url":"https://github.com/elastic/kibana/pull/192850","mergeCommit":{"message":"[NL-to-ESQL] refactor and improve the task's workflow (#192850)\n\n## Summary\r\n\r\nSome cleanup and minor enhancements, just to get my hands on that part\r\nof the code.\r\n\r\nevaluation framework was run against gemini1.5, claude-sonnet and GPT-4,\r\nwith a few improvements\r\n\r\n### Cleanup\r\n\r\n- Refactor the code to improve readability and maintainability\r\n\r\n### Improvements\r\n\r\n- Add support for keyword aliases (turns out, some models asks for\r\n`STATS...BY` and not `STATS`)\r\n- Add (naive for now) support for suggestion (to try to influence the\r\nmodel on using some function instead of others, e.g group by time with\r\nBUCKET instead of DATE_TRUNC)\r\n- Generate \"this command does not exist\" documentation when the model\r\nrequest a missing command (help making it understand it shouldn't use\r\nthe command, e.g gpt-4 was hallucinating a `REVERSE` command)\r\n\r\n---------\r\n\r\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"0fc191aa320db4b7949f1c2d47a273a5362029c8"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/192850","number":192850,"mergeCommit":{"message":"[NL-to-ESQL] refactor and improve the task's workflow (#192850)\n\n## Summary\r\n\r\nSome cleanup and minor enhancements, just to get my hands on that part\r\nof the code.\r\n\r\nevaluation framework was run against gemini1.5, claude-sonnet and GPT-4,\r\nwith a few improvements\r\n\r\n### Cleanup\r\n\r\n- Refactor the code to improve readability and maintainability\r\n\r\n### Improvements\r\n\r\n- Add support for keyword aliases (turns out, some models asks for\r\n`STATS...BY` and not `STATS`)\r\n- Add (naive for now) support for suggestion (to try to influence the\r\nmodel on using some function instead of others, e.g group by time with\r\nBUCKET instead of DATE_TRUNC)\r\n- Generate \"this command does not exist\" documentation when the model\r\nrequest a missing command (help making it understand it shouldn't use\r\nthe command, e.g gpt-4 was hallucinating a `REVERSE` command)\r\n\r\n---------\r\n\r\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"0fc191aa320db4b7949f1c2d47a273a5362029c8"}},{"branch":"8.x","label":"v8.16.0","branchLabelMappingKey":"^v8.16.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Pierre Gayvallet <pierre.gayvallet@elastic.co>
Summary
Some cleanup and minor enhancements, just to get my hands on that part of the code.
evaluation framework was run against gemini1.5, claude-sonnet and GPT-4, with a few improvements
Cleanup
Improvements
STATS...BY
and notSTATS
)REVERSE
command)