Class PathValue2KGConvert

java.lang.Object
cn.net.pap.neo4j.util.kg.PathValue2KGConvert

public class PathValue2KGConvert extends Object
  • Constructor Details

    • PathValue2KGConvert

      public PathValue2KGConvert()
  • Method Details

    • convertToKnowledgeGraph

      public static Map<String,Object> convertToKnowledgeGraph(List<List<org.neo4j.driver.internal.value.PathValue>> shortestPaths)
      将 List<List> shortestPaths 类型的数据转换为 知识图谱需要的数据结构
      Parameters:
      shortestPaths -
      Returns:
    • convertToKnowledgeGraph2

      public static Map<String,Object> convertToKnowledgeGraph2(List<org.neo4j.driver.internal.value.PathValue> pathValues, String relationKey)
      Parameters:
      pathValues -
      relationKey - 取得是关系部分的属性标签,比如如果是 红楼梦 数据的话,关系类型的属性是 type
      Returns: