Skip to content
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

Feature/equivalent properties #454

Merged
merged 5 commits into from
Apr 17, 2023
Merged

Feature/equivalent properties #454

merged 5 commits into from
Apr 17, 2023

Conversation

zonotope
Copy link
Contributor

Closes #453

@zonotope zonotope added this to the 3.0.0-alpha2 milestone Apr 17, 2023
@zonotope zonotope requested a review from a team April 17, 2023 13:08
@zonotope zonotope self-assigned this Apr 17, 2023
Copy link
Contributor

@dpetran dpetran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to summarize my understanding of how this works:

When we're adding vocabulary flakes, if we see equivalentProperty we will add an entry for both the predicate and its object to our schema map. Then during query time we will check if the predicate has any equivalent properties and resolve the flakes for those predicates as well.

Looks good!

@zonotope
Copy link
Contributor Author

Just to summarize my understanding of how this works:

When we're adding vocabulary flakes, if we see equivalentProperty we will add an entry for both the predicate and its object to our schema map. Then during query time we will check if the predicate has any equivalent properties and resolve the flakes for those predicates as well.

Looks good!

That's right. There's one additional nuance where we also make sure to add entries to the schema for all the other predicates already defined to be equivalent for both the subject and object of the equivalent property flakes. That ensures that if someone says that a is an equivalent property b, and later that b is an equivalent property of c, then the system also treats a as an equivalent property of c.

The last assertion in the fluree.db.query.property-test/equivalent-properties-test checks for this.

@zonotope zonotope merged commit ffdf9a9 into main Apr 17, 2023
@zonotope zonotope deleted the feature/equivalent-properties branch April 17, 2023 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement Equivalent Properties
2 participants