我真的很生气!我需要使用 rdf lib 为图形创建查询。这是查询:
queryCompetence = """prefix context: <http://www.ontologydesignpatterns.org/ont/mine/context.owl#>
select ?score where { <""" + \
str(elem) + """> context.hasProperty ?MyProperty. ?MyProperty ttt:hasScore ?score}."""
其中 elem 是一个 URI。我收到错误:“ParseException: Expected "}" (at char 129), (line:2, col:51)",对应于查询中 elem URI 的开头。谁能帮我?