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

推理机设置isA逻辑,并在上位词设置rule,其下位词不会继承上位词的规则吗 #424

Open
ganhb opened this issue Dec 17, 2024 · 2 comments
Assignees

Comments

@ganhb
Copy link

ganhb commented Dec 17, 2024

@youdonghai 您好,我在测试类FilmBaseTestData
我在概念增加了isA关系,代码如下:

    schema.put(
            "PopularFilmStar",
            Convert2ScalaUtil.toScalaImmutableSet(Sets.newHashSet("id", "age", "name", "gender")));
    schema.put(
        "PopularFilmStar_isA_FilmStar",//把popularFilmStart的上位词为FilmStart
        Convert2ScalaUtil.toScalaImmutableSet(Sets.newHashSet()));

并在实例图FilmGraphGeneratorTopK中,把L1_1_start的label改成popularFilmStart,代码如下:

     constructionVertex("L1_1_star", "FilmStar", "age", 60, "gender", "男"),
//改成如下
     constructionVertex("L1_1_star", "PopularFilmStar", "age", 60, "gender", "男"),

执行查询KgReasonerTopKFilmTest.test1为什么得到的结论变成L1_2_star 而不是L1_1_start;
不应该设置成isA,应该继承上位词所有的规则吗

@bader1000
Copy link

@youdonghai您好,我测在试类FilmBaseTestData我在概念增加了isA关系,代码如下:

    schema.put(
            "PopularFilmStar",
            Convert2ScalaUtil.toScalaImmutableSet(Sets.newHashSet("id", "age", "name", "gender")));
    schema.put(
        "PopularFilmStar_isA_FilmStar",//把popularFilmStart的上位词为FilmStart
        Convert2ScalaUtil.toScalaImmutableSet(Sets.newHashSet()));

并在实例图FilmGraphGeneratorTopK中,把L1_1_start的label改成popularFilmStart,代码如下:

     constructionVertex("L1_1_star", "FilmStar", "age", 60, "gender", "男"),
//改成如下
     constructionVertex("L1_1_star", "PopularFilmStar", "age", 60, "gender", "男"),

执行查询KgReasonerTopKFilmTest.test1为什么得到的结论变成L1_2_star ولا وأيدم إغاني أول_1_start;应该设置成isA،应该继承上位词所有的规则

@narutohyc
Copy link

@caszkgui 同问

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

No branches or pull requests

4 participants