-
Notifications
You must be signed in to change notification settings - Fork 3
Added a choice of target between strings or official nomenclatures #2
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
Conversation
In progress
Add solar bodies name : https://planetarynames.wr.usgs.gov/Page/Planets
Added a choice of target between strings or official nomenclatures of https://planetarynames.wr.usgs.gov/Page/Planets
|
@jlaura can you review also? @J-Christophe In general, I am a fan of enumerations, but it also might be too limiting here and require regular updates. Currently, we are dealing with a PDS3 to PDS4 migration (for old Voyager data), where no target is specified and we painfully stuck with our current enumerations needing an update to be pushed into the PDS4 information model. Not hard, but takes time. Is there some magical schema rule to have a recommended list, but allow it to be free-text? Also the list on https://planetarynames.wr.usgs.gov/Page/Planets is a good place to start, but is probably doesn't have everything we need. For example, soon we will need Psyche (and should the Sun be there)? |
|
Is there some magical schema rule to have a recommended list, but allow it
to be free-text?
I think I did that. A recommended list is an enumeration but with the
"oneof", you can choose for each element of the array of ssys : one of the
recommended list or a free text.
Maybe, we need a special namespace related to the recommended list to show
that the name is "standard". In this way, provider can see the difference
in the json between recommended element and free text.
The interest between the two concepts is that the software could implement
a feature related to an enum but cannot do it / difficult to do if the text
is free (this is my case). A free text is only good for displaying
information but not for processing that information.
Also the list on https://planetarynames.wr.usgs.gov/Page/Planets is a good
place to start, but is probably doesn't have everything we need. For
example, soon we will need Psyche (and should the Sun be there)?
True. Sun should be added. It is not a problem to add an element in the
enumeration with the time.
However, modifying an element of the enum is not a good idea (because
software could use a specific name for processing the information). If
there is a need to do that , it is better to add a version number somewhere.
Jean-Christophe
|
jlaura
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies that this languished for so long. I had not realized that it was open! I have a single comment that I think will clean up the schema a small bit. Let me know what your thoughts are!
| "type": "array", | ||
| "minItems": 1, | ||
| "items": { | ||
| "oneOf": [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not believe that this needs to make use of oneOf. I think just:
"type":"array",
"minItems": 1,
"items": {
"type":"string",
"enum": [
"Mercury",
"Venus",
"..."
]
},
"additionalItems": falseThat should force at least one item from the enum be in the targets list.
|
With #6, I don't know that having an enum limited to planet name makes sense any longer. Perhaps the correct thing to do is to update the documentation to link to the IVOA list of targets (which is itself a list of resources of targets). Thoughts? |
I am fine with a smaller enumerated list (or using a longer list provided from elsewhere) as long as we can still enter a free text string. Above Jean-Christophe states, "A recommended list is an enumeration but with the "oneof", you can choose for each element of the array of ssys : one of the recommended list or a free text." |
|
If this is from a list or free text, my preference is to have this be an update to the README and not a 'sort of enum/free form' field. It seems we either do schema level validation or we don't This would be a partial validation that, from my perspective, doesn't make sense. I would propose that we update the README to include something like: The best practice is to use the official designation of the target as defined by IAU. This parameter is case sensitive (mixing lower/upper cases) and all values must use the standard spelling and case; unusual characters (such as intermediate spaces) are allowed, except quotes (preferably changed to _ , which is the single-character wildcard in TAP queries). Data providers must be aware that services which do not use the IAU designations might not be accessible by the clients. (From https://www.ivoa.net/documents/EPNTAP/20201027/WD-epntap-2.0-20201027.html#tth_sEc2.1.3) Other best practices are listed below: |
|
OK, README is a good idea. +1 |
|
Closing in favor of #7. Please have a look at that PR! |
Hi Trent,
I think it is important to add a controlled vocabulary for solar bodies name so that software can understand the semantic. I use the name of the planet when I am doing a drag n drop of the STAC catalog on my apps. According to the solar body name, I show a different background map.
So, I have modified a little bit your schema for adding this feature:
Added a choice of target between strings or official nomenclatures from https://planetarynames.wr.usgs.gov/Page/Planets.
Basically, this addition should not break your previous schema. It simply adds the choice between using for each element of the array a free string or an element of the controlled vocabulary from https://planetarynames.wr.usgs.gov/Page/Planets.
It should be great and very useful if you could propose this extension in https://stac-extensions.github.io/
Thanks,
Jean-Christophe