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

Create querying mixin #262

Merged
merged 2 commits into from
Aug 31, 2022
Merged

Create querying mixin #262

merged 2 commits into from
Aug 31, 2022

Conversation

Mec-iS
Copy link
Contributor

@Mec-iS Mec-iS commented Aug 31, 2022

Current behaviour

All the methods are stacked in the kglab module and it makes it difficult to handle.

New expected behaviour

Implement mixins for different functionalities in different modules:

  • namespace management (ontology, controlled vocabularies)
  • graph construction
  • serialization
  • SPARQL querying implemented by this PR
  • SHACL validation
  • inference based on OWL-RL, RDFS, SKOSby creating a mixin

@ceteri let me know if this is ok. The only problem I see is that the credits for writing the code are moved to the developer that created the mixin. So if you want to keep the credits to the developer that wrote the code in the first place he/she will have to create the mixins by himself. Let me know if this is a problem.

Change logs

  • Add querying module that incapsulates querying for KnowledgeGraph
  • Move querying out of KnowledgeGraph into QueryingMixin

@Mec-iS Mec-iS requested review from ceteri and tomaarsen August 31, 2022 12:01
Copy link
Collaborator

@ceteri ceteri left a comment

Choose a reason for hiding this comment

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

Awesome, thank you @Mec-iS!

Using mixin design pattern is a great fit for this refactoring of kglab, and alleviates some of the problems I'd encountered early (in the comment thread about instance members)

@ceteri ceteri merged commit 0742277 into DerwenAI:main Aug 31, 2022
@tomaarsen
Copy link
Contributor

Looks good! Well done.

@Mec-iS Mec-iS deleted the refactor-use-mixins branch August 31, 2022 21:26
@ceteri ceteri added this to the Refactor KnowledgeGraph class milestone Aug 31, 2022
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.

3 participants