In the current implementation, `r.type = () => x.word()`, the `x.word()` function matches words based on the regular expression `/^[A-Za-z][A-Za-z0-9_]*/`. This regex matches words that start with a letter (uppercase or lowercase) followed by zero or more occurrences of letters, digits, or underscores. However, this regex does not allow labels to start with a digit. So, labels like "702127fad3ec880f" or "5aa9624700f4dd96" would not be recognized as valid labels by the Cypher parser with the current implementation.
In the suggested modification, `r.type = () => match(/^[A-Za-z0-9][A-Za-z0-9_]*/) && x.sp()`, the regular expression `/^[A-Za-z0-9][A-Za-z0-9_]*/` is used instead. This regex allows labels to start with a letter (uppercase or lowercase), or a digit, followed by any combination of letters, digits, or underscores. commit
So, with the suggested modification, labels like "702127fad3ec880f" or "5aa9624700f4dd96" would be recognized as valid labels by the Cypher parser.
~
We use the modified r.type function in Parse Page Paragraphs and the Paragraph Recommendation Viewer, searchGraph function. See lineup