-
Notifications
You must be signed in to change notification settings - Fork 40
add missing q param for item search and collection-items search #267
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
base: main
Are you sure you want to change the base?
Conversation
Thanks @fmigneault I already started #263 but wanted to add tests before merging |
Hi @fmigneault - thanks for opening this PR. We intentionally left The free-text search extension is potentially very powerful but the current implementation is somewhat limited (see below). Perhaps cql2-json filters could help you achieve your goals? The The STAC API Free-Text Extension states:
We did not include any other fields in the pgstac implementation because there aren't any canonical text fields in the item spec and pgstac just stuffs all fields except I am really curious to understand the use-case for free-text search in items - can you share a bit more about the types of searches you are trying to enable? |
@hrodmn Potentially, text search could be done over all item properties as a global string, but I am aware it is not the case for now. I would not expect property-specific search using |
Sounds good, thanks for the additional context @fmigneault.
If your datasets are represented as STAC collections then adding a detailed
Yeah, we could just represent the whole |
We have a mixture of climate datasets that have >300K items in the same collection and some earth observation with machine learning annotations in the order of ~30K items/samples split into 3 collections (train, test, validate). Therefore, we need some level of granularity/flexibility to filter, but we can add common keywords like the class category, ML-specific details (eg: "train") or other similar common keywords to provide very rough search. Sometimes, we have use cases like users wanting to find "temperature" or "precipitation" information, but as non-experts just looking around, they are not aware that the actual variable is In the longer run, we are planing to integrate augmented search (eg: using LLM and whatnot), but the |
Related Issue(s):
Description:
Whether the
q
basic/advanced extension get moved/split/else, they currently defineq
parameter on other endpoints that are not handled by the API (only/collections?q=...
was handled.This adds the
q
parameter to/search
and/collections/{collection_id}/items
as well.PR Checklist:
pre-commit
hooks pass locallymake test
)make docs
)