-
Notifications
You must be signed in to change notification settings - Fork 24
update HACCP_term regex to required FOODON, add multivalue example #802
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?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -3703,13 +3703,14 @@ slots: | |||||
| title: Hazard Analysis Critical Control Points (HACCP) guide food safety term | ||||||
| examples: | ||||||
| - value: tetrodotoxic poisoning [FOODON:03530249] | ||||||
| - value: tetrodotoxic poisoning[FOODON:03530249]; neurotoxic shellfish poisoning[FOODON:03530246] | ||||||
| keywords: | ||||||
| - food | ||||||
| - term | ||||||
| slot_uri: MIXS:0001215 | ||||||
| multivalued: true | ||||||
| range: string | ||||||
| pattern: ^([^\s-]{1,2}|[^\s-]+.+[^\s-]+) \[[a-zA-Z]{2,}:[a-zA-Z0-9]\d+\]$ | ||||||
| pattern: ^.+\s*\[FOODON:\d+\](;\s*\[FOODON:\d+\])*$ | ||||||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This regex requires FOODON ontology. Is this what we want?
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks! Please use the pattern
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Did you intentionally remove the white-space between the label and the term id? I don't think that's consistent with other ontology term patterns in MIxS
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @turbomam So, the white space is supposed to be there? I thought I had it set to be valid with or without it... does it matter? If so, I'll make sure I correct it. Just tell me which is correct. Looking at the submission schema the white space should be there. So I can make that update to the regex.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. From your comment here : #802 (comment)
That regex ... are you sure that's right?? Or am I missing something about the formatting of the value for "lead poisoning [FOODON:03530243]" ? I think it needs to be
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. decision, the regex in the 2nd image is good. I'll test this and confirm then finish this PR. Discussed 12/03
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I forgot to escape the square brackets around FOODON with backslashes
|
||||||
| pattern: ^.+\s*\[FOODON:\d+\](;\s*\[FOODON:\d+\])*$ | |
| pattern: ^[^;]+\s*\[FOODON:\d+\](;\s*[^;]+\s*\[FOODON:\d+\])*$ |


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.
The new multi-value example uses
;as a delimiter and omits the space before[(e.g.,poisoning[FOODON:...]). In this schema, multi-term free-text fields typically document/illustrate pipe-separated values (|), e.g.dietary_claim_usedescription (around mixs.yaml:5761-5763) andanimal_feed_equipexample...|...(around mixs.yaml:4216). Consider updating this example to use|and the canonicaltermLabel [TERM:ID]spacing, or explicitly document that;and optional spacing are intended forHACCP_term.