Skip to content

[ES|QL] Suggest adding curly braces after the WITH keyword for Rerank and Completion#243047

Merged
bartoval merged 6 commits intoelastic:mainfrom
bartoval:add_parens_after_with
Nov 17, 2025
Merged

[ES|QL] Suggest adding curly braces after the WITH keyword for Rerank and Completion#243047
bartoval merged 6 commits intoelastic:mainfrom
bartoval:add_parens_after_with

Conversation

@bartoval
Copy link
Contributor

Summary

#234488

iii
@bartoval bartoval self-assigned this Nov 14, 2025
@bartoval bartoval requested a review from a team as a code owner November 14, 2025 14:06
@bartoval bartoval force-pushed the add_parens_after_with branch from 3f0f4b7 to 16e5f02 Compare November 14, 2025 14:10
@bartoval bartoval added release_note:enhancement backport:skip This PR does not require backporting Feature:ES|QL ES|QL related features in Kibana Team:ESQL ES|QL related features in Kibana t// v9.3.0 labels Nov 14, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-esql (Team:ESQL)

@bartoval bartoval changed the title [ES|QL] Suggest inference id after the keyword with for Rerank and Completion Nov 14, 2025
@bartoval bartoval changed the title [ES|QL] Suggest Curly braces after the keyword with for Rerank and Completion Nov 14, 2025
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/esql-ast 608 609 +1

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
kbnUiSharedDeps-srcJs 4.0MB 4.0MB +554.0B
Unknown metric groups

API count

id before after diff
@kbn/esql-ast 799 800 +1

History

cc @bartoval

Copy link
Contributor

@stratoula stratoula left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't want to suggest the brackets
image

We want to add them immediately
meow

Otherwise you have a different behavior if you do

  • COMPETION --> select string --> WITH
  • Adding space after WITH (your PR)

We want them to behave the same

@bartoval
Copy link
Contributor Author

We don't want to suggest the brackets image

We want to add them immediately meow meow

Otherwise you have a different behavior if you do

  • COMPETION --> select string --> WITH
  • Adding space after WITH (your PR)

We want them to behave the same

mmm..The implemented behavior follows the same workflow as the original. Have you tried it?
Or are you telling me that after typing WITH and then adding the space, I have to insert {inference_Id: ""} directly into the editor?

@bartoval
Copy link
Contributor Author

... is that if you type WITH (and you dont select it from the autocomplete system) it doesnt show the suggestion after with

From the comment on the issue it seems to me that the idea is to have a suggestion after the space. Maybe the problem is just the choice of label for the suggestion? We can change it to inference_id. We can also insert all { inferende_id: ""} in one go. I had done it but it seemed like a different behavior from the current workflow

@stratoula
Copy link
Contributor

I have to insert {inference_Id: ""} directly into the editor?

That one! Yes I tried it!

From the comment on the issue it seems to me that the idea is to have a suggestion after the space.

I know that the description is confusing but what we need is to insert it directly as we do with the other flow

@bartoval bartoval force-pushed the add_parens_after_with branch from 09d1e2d to 24307c9 Compare November 17, 2025 11:58
Copy link
Contributor

@stratoula stratoula left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great, just a small change on the icon but I am approving as I dont need to check again

…y/complete_items.ts

Co-authored-by: Stratou <stratoula1@gmail.com>
@bartoval bartoval merged commit df21713 into elastic:main Nov 17, 2025
12 checks passed
eokoneyo pushed a commit to eokoneyo/kibana that referenced this pull request Dec 2, 2025
… and Completion (elastic#243047)

## Summary
elastic#234488

<img width="857" height="134" alt="iii"
src="https://github.com/user-attachments/assets/e28bb896-51f5-4faa-ab88-5950215429e9"
/>

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Stratou <stratoula1@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting Feature:ES|QL ES|QL related features in Kibana release_note:enhancement Team:ESQL ES|QL related features in Kibana t// v9.3.0

4 participants