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

Merge TripleStoreKnowledgeBase and TripleStore #497

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

Jean-KOUAGOU
Copy link
Collaborator

I have implemented a simple merge of TripleStore and TripleStoreKnowledgeBase. Tests work locally. Please review and merge

Copy link
Member

@Demirrr Demirrr left a comment

Choose a reason for hiding this comment

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

You didn't really merge TripleStoreKnowledgeBase and TripleStore but rather put already defined class of TripleStoreKnowledgeBase into TripleStore. What is the benefits of this ?

assert h
assert DLSyntaxObjectRenderer().render(h)
save_owl_class_expressions(h)
sparql = Owl2SparqlConverter().as_query("?x", h)
assert sparql
else:
pass
"""

Copy link
Member

Choose a reason for hiding this comment

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

Remove
if name == "main":
test_triplestore = TestTriplestore()
test_triplestore.test_remote_triplestore_dbpedia_tdl()

No need these three lines.

@@ -53,12 +52,16 @@ def test_remote_triplestore_dbpedia_tdl(self):
typed_neg = set(map(OWLNamedIndividual, map(IRI.create, examples["negative_examples"])))
lp = PosNegLPStandard(pos=typed_pos, neg=typed_neg)
h = model.fit(learning_problem=lp).best_hypotheses()
print(h)
Copy link
Member

Choose a reason for hiding this comment

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

No need to print

@@ -53,12 +52,16 @@ def test_remote_triplestore_dbpedia_tdl(self):
typed_neg = set(map(OWLNamedIndividual, map(IRI.create, examples["negative_examples"])))
lp = PosNegLPStandard(pos=typed_pos, neg=typed_neg)
h = model.fit(learning_problem=lp).best_hypotheses()
print(h)
assert h
assert DLSyntaxObjectRenderer().render(h)
save_owl_class_expressions(h)
sparql = Owl2SparqlConverter().as_query("?x", h)
assert sparql
else:
pass
Copy link
Member

Choose a reason for hiding this comment

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

pass is problematic. This is not a really test


def __init__(self, url: str=None):
assert url is not None, "url must be string"
self.g = TripleStoreReasonerOntology(url=url)
Copy link
Member

Choose a reason for hiding this comment

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

This is incorrect. We cannot have TripleStoreOntology, TripleStoreReasoner, and TripleStoreReasonerOntology, can we ?

@Jean-KOUAGOU
Copy link
Collaborator Author

Jean-KOUAGOU commented Nov 29, 2024 via email

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.

2 participants