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

[EuiIcon] Add tokenSparseVector #7257

Closed
carlosdelest opened this issue Oct 5, 2023 · 5 comments · Fixed by #7282
Closed

[EuiIcon] Add tokenSparseVector #7257

carlosdelest opened this issue Oct 5, 2023 · 5 comments · Fixed by #7282

Comments

@carlosdelest
Copy link
Member

sparse_vector field type is being included as part of Elasticsearch 8.11 (issue).

It would be good to provide a token in EUI for this field type.

We could make this a small variation of dense_vector so it highlights the similar use case and data type.

@cee-chen
Copy link
Member

cee-chen commented Oct 5, 2023

👋 Hey Carlos!! Long time no see! :)

@MichaelMarcialis @andreadelrio Can I loop y'all in on this one to respond on whether we do/don't want to do this, and if we do, what a potential design might look like?

@MichaelMarcialis
Copy link
Contributor

@carlosdelest, @cee-chen: I'd be happy to help make a token for sparse vector. Is my understanding correct that the difference between sparse and dense vector is that sparse vectors have mostly zero values and dense vectors have mostly non-zero values? If so, it might be wise for us to also update the existing dense vector icon to something more unique than the current array-like brackets icon. Just let me know if my understanding is correct and I can crank something out.

@carlosdelest
Copy link
Member Author

HI @MichaelMarcialis ! Your understanding is correct. Both are float vectors, but in a sparse vector most elements are zero.

Thanks for looking into this!

@MichaelMarcialis
Copy link
Contributor

@carlosdelest: Here's a quick stab at adding a sparse vector icon and updating the existing dense vector icon to match (showing both color and mono versions). Let me know if this will do the trick for you, and I'll put together an EUI PR to add it in. Thanks!

CleanShot 2023-10-12 at 15 42 10

@carlosdelest
Copy link
Member Author

@MichaelMarcialis , I love this! The concept is quite clear to me.

Maybe moving the sparse non-zero values closer to the center would help differentiate those from the square brackets? Something like:

image

Thanks for looking into this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants