Add JS code generation examples
What does this MR do and why?
Add JS code generation examples
No of examples included import nor export statements which might ew result to skip those parts even in empty files. This commit adds 2 examples that include both import and exports
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Comparison results for EXPORT_TO=more_js_examples_results.csv RAILS_TOKEN="glpat-xxxxxxxxxxx-xx" RAILS_URL=http://gdk.test:3000/api/v4/code_suggestions/completions ruby run.rb snippets/generation/javascript
jaccard similarity | jaccard similarity with 2 new examples | similarity score | similarity score with new examples |
---|---|---|---|
0.329 | 0.64 | 0.9392687098 | 0.9799325744 |
0.933 | 0.936 | 0.9999943719 | 0.9999943719 |
0.835 | 0.848 | 0.974817784 | 0.974817784 |
0.406 | 0.395 | 0.9421041379 | 0.9418777674 |
How to set up and validate locally
Create new JS file and add comment
//Generate an express API endpoint to welcome users
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.