project-lux / lux-marklogic

Code, issues, and resources related to LUX MarkLogic
Other
3 stars 2 forks source link

Add missing relation names #206

Open brent-hartwig opened 3 months ago

brent-hartwig commented 3 months ago

Problem Description: The related lists configuration generator reported missing names against release1.20 (below). The impact is that the frontend is not given a value to label these related items for specific relations.

2024-07-01 15:03:43.470 Warning: Relations without a label:
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] created-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] encountered-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedCreation-aboutAgent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedCreation-createdBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedCreation-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedCreation-publishedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedProduction-encounteredBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedProduction-producedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] influencedProduction-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] produced-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] published-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToAgent] subjectOfAgent-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedCreation-aboutConcept
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedCreation-classification
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedCreation-language
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedProduction-classification
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedProduction-material
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToConcept] influencedProduction-producedUsing
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-containingSet-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-containingSet-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] curated-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] encountered-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] encountered-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] influencedCreation-carriedBy-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] produced-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToEvent] produced-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToPlace] influencedCreation-aboutPlace
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToPlace] influencedCreation-createdAt
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToPlace] influencedCreation-publishedAt
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToPlace] influencedProduction-encounteredAt
2024-07-01 15:03:43.470 Warning:+        [agent.relatedToPlace] influencedProduction-producedAt
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] classificationOfItem-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] classificationOfWork-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] languageOf-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] materialOfItem-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] subjectOfConcept-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToAgent] usedToProduce-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfItem-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfItem-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] materialOfItem-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] materialOfItem-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] usedToProduce-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [concept.relatedToEvent] usedToProduce-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [place.relatedToAgent] createdHere-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [place.relatedToAgent] encounteredHere-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [place.relatedToAgent] producedHere-productionInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [place.relatedToAgent] publishedHere-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [place.relatedToAgent] subjectOfPlace-creationInfluencedBy
2024-07-01 15:03:43.470 Warning:+        [place.relatedToEvent] encounteredHere-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [place.relatedToEvent] encounteredHere-memberOf-memberOf-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [place.relatedToEvent] producedHere-memberOf-containingSet-usedForEvent
2024-07-01 15:03:43.470 Warning:+        [place.relatedToEvent] producedHere-memberOf-memberOf-usedForEvent

Expected Behavior/Solution: Configure a name for each of the above within relationNames.mjs.

Requirements: See above.

Needed for promotion: If an item on the list is not needed, it should be crossed off but not removed.

~- [ ] Wireframe/Mockup - Mike~

UAT/LUX Examples: The above listing can be mapped to specific related lists on specific entity pages. Within a related list, the data also impacts which relations show.

Dependencies/Blocks: This ticket neither blocks nor is blocked by another.

Related Github Issues: Found by #190.

Related links: Spreadsheet of Missing Relation Names https://docs.google.com/spreadsheets/d/1vn4KHd2vDS9ahEJXt_Sg_5ITwuDeUfyUKB4iT8PShP8/edit?gid=0#gid=0

Wireframe/Mockup: Not needed.

brent-hartwig commented 2 months ago

@roamye, has this ticket been triaged? Since 1 Jul 24, we picked up another 40, taking us up to 105 relationships for each UI labels are not defined. Is the UI still using relationship labels provided by the backend? If so, what does it default to? Thank you.

2024-07-23 13:36:06.567 Warning: Relations without a label:
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] created-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] encountered-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedCreation-aboutAgent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedCreation-createdBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedCreation-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedCreation-publishedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedProduction-encounteredBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedProduction-producedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] influencedProduction-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] produced-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] published-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToAgent] subjectOfAgent-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedCreation-aboutConcept
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedCreation-classification
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedCreation-language
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedProduction-classification
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedProduction-material
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToConcept] influencedProduction-producedUsing
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] created-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] created-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] created-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-containingSet-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-containingSet-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-containsWorks-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] curated-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] encountered-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] encountered-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] encountered-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedCreation-carriedBy-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedCreation-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedCreation-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedCreation-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedProduction-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] influencedProduction-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] produced-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] produced-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] produced-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] published-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] published-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] published-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] subjectOfAgent-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] subjectOfAgent-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToEvent] subjectOfAgent-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToPlace] influencedCreation-aboutPlace
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToPlace] influencedCreation-createdAt
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToPlace] influencedCreation-publishedAt
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToPlace] influencedProduction-encounteredAt
2024-07-23 13:36:06.567 Warning:+        [agent.relatedToPlace] influencedProduction-producedAt
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] classificationOfItem-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] classificationOfWork-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] languageOf-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] materialOfItem-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] subjectOfConcept-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToAgent] usedToProduce-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfItem-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfItem-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfItem-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-containsWorks-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfSet-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfWork-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfWork-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] classificationOfWork-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] languageOf-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] languageOf-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] languageOf-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] materialOfItem-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] materialOfItem-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] materialOfItem-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] subjectOfConcept-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] subjectOfConcept-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] subjectOfConcept-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] usedToProduce-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] usedToProduce-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [concept.relatedToEvent] usedToProduce-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToAgent] createdHere-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [place.relatedToAgent] encounteredHere-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [place.relatedToAgent] producedHere-productionInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [place.relatedToAgent] publishedHere-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [place.relatedToAgent] subjectOfPlace-creationInfluencedBy
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] createdHere-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] createdHere-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] createdHere-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] encounteredHere-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] encounteredHere-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] encounteredHere-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] producedHere-carries-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] producedHere-memberOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] producedHere-memberOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] publishedHere-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] publishedHere-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] publishedHere-partOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] subjectOfPlace-partOf-containingSet-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] subjectOfPlace-partOf-memberOf-usedForEvent
2024-07-23 13:36:06.567 Warning:+        [place.relatedToEvent] subjectOfPlace-partOf-usedForEvent

cc: @clarkepeterf

clarkepeterf commented 2 months ago

@prowns @jffcamp @roamye I think we should prioritize this. If these relationships are not labeled, they could show up with strange labels on the frontend

clarkepeterf commented 2 months ago

@brent-hartwig if there is no label, ML sends the first relationship split into words:

function getRelationName(relationKey) {
  if (RELATION_NAMES[relationKey]) {
    return RELATION_NAMES[relationKey];
  }
  const idx = relationKey.indexOf('-');
  const firstTerm = idx > -1 ? relationKey.substring(0, idx) : relationKey;
  return utils.uppercaseFirstCharacter(utils.camelCaseToWords(firstTerm));
}
brent-hartwig commented 2 months ago

Ah, yes. More code I forgot I wrote 😆

roamye commented 2 months ago

@brent-hartwig @clarkepeterf -

Hi, no this hasn't been triaged. I have moved the status to prioritization review which will be reviewed by CORE team sometime in the week of August 5th. If this cannot wait till then please let me know. I can reach out to Jeff/Rob/Sarah and ask if they can review/prioritize sooner.

Do we currently have an example of where one of these strange labels show up on the front end?

cc: @prowns, @jffcamp

brent-hartwig commented 2 months ago

@roamye, I don't have a good example offhand but recommend this be marked as blocked by #233. Once that is resolved, we should review the latest list of relations that do not have labels.

roamye commented 1 month ago

8/7 UAT: This requires an example for it to be prioritized as important. For now it will move into backlog as a minor priority.

brent-hartwig commented 1 month ago

@roamye, here's one within Andy Warhol's related locations list:

image

brent-hartwig commented 1 month ago

And one from painting's related people and groups list:

image

prowns commented 1 month ago

@roamye - can we convert this list into a spreadsheet to work on it?

brent-hartwig commented 1 month ago

@roamye, here are the values as a list you can paste into a spreadsheet: 206-as-a-list.txt

roamye commented 1 month ago

pasted into here: https://docs.google.com/spreadsheets/d/1vn4KHd2vDS9ahEJXt_Sg_5ITwuDeUfyUKB4iT8PShP8/edit?gid=0#gid=0

is it beneficial to know its current label? I thought no as it follows a formula (as listed in Peters comment), but I added a column in there in case it is.

prowns commented 1 month ago

@brent-hartwig - is there a way to isolate which values do not have relation names?

brent-hartwig commented 1 month ago

[!NOTE] A related lists stats script that's better than the one in this comment was since written. Once merged from the release1.26 branch into the main branch, the link will be https://github.com/project-lux/lux-marklogic/blob/main/scripts/relatedListStats.js.

Good morning, @prowns. The list of 104 relations provided on 8 Aug were the ones at that time without names. That list appears to have included relations that would be added by #94. The current list of relations without names or #94 has 74 items: 206-on-20240821-without-94.txt. The current list with #94 has 142 items: 206-on-20240821-with-94.txt. I'll leave it to you as to which to pursue at this time but both are different than the list presently in @roamye's spreadsheet.

@clarkepeterf, the 142 got me wondering if the related lists were getting a little out of hand. An entity page may request three or four in the search-will-match context, and we have an existing optimization mechanism (#202). The other aspect is when the full list is requested, which is definitely when all of the requested list's triple searches are performed. To mark where we are at, I captured the number of relations by list with and without #94 below. The increase is limited to events, which is the entity LUX has the fewest documents for. We also have a couple monitoring tests that can help us detect an uptick in timeouts and data cap hits. In summary, we may not need to do anything about this now, other than have awareness.

Without #94:

{
  "agent":{
    "relatedToAgent":25,
    "relatedToConcept":21,
    "relatedToEvent":23,
    "relatedToPlace":18
  },
  "concept":{
    "relatedToAgent":21,
    "relatedToConcept":18,
    "relatedToEvent":21,
    "relatedToPlace":15
  },
  "place":{
    "relatedToAgent":18,
    "relatedToConcept":15,
    "relatedToEvent":12,
    "relatedToPlace":13
  }
}

With #94

{
  "agent":{
    "relatedToAgent":25,
    "relatedToConcept":21,
    "relatedToEvent":50,
    "relatedToPlace":18
  },
  "concept":{
    "relatedToAgent":21,
    "relatedToConcept":18,
    "relatedToEvent":43,
    "relatedToPlace":15
  },
  "place":{
    "relatedToAgent":18,
    "relatedToConcept":15,
    "relatedToEvent":31,
    "relatedToPlace":13
  }
}

Less the setting of config, below is the script I used. config should be set to the value of RELATED_LISTS_CONFIG.lux.

const results = {};
Object.keys(config).forEach((scope) => {
  results[scope] = {};
  Object.keys(config[scope]).forEach((term) => {
    results[scope][term] = config[scope][term].searchConfigs.length;
  });
});
results;