You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Protege Cellfie前缀使用问题:如何为个体、对象属性及其值域声明前缀?

Protege Cellfie前缀声明报错修正方法

在使用Protege的Cellfie工具导入内容时,尝试为个体、对象属性及其值域声明前缀时代码报错,直接使用IRI <ontologies/linkingOntology#calculatedUsing>也未解决问题,报错代码如下:

Individual: @A* (mm:prefix = "ontologies/SDWOWL#")
Facts: calculatedUsing (mm:prefix = "ontologies/linkingOntology#") @B* (mm:prefix = "ontologies/otherOntology")

问题原因

Facts行中对象属性的前缀声明语法错误——(mm:prefix = ...)仅适用于个体的前缀绑定,不能直接用于对象属性。

修正方案

方案1:直接使用完整IRI

给对象属性指定完整的IRI路径,同时补全值域前缀的#保证格式正确:

Individual: @A* (mm:prefix = "ontologies/SDWOWL#")
Facts: <ontologies/linkingOntology#calculatedUsing> @B* (mm:prefix = "ontologies/otherOntology#")

方案2:全局声明前缀后简化引用

先通过Prefix指令全局定义各本体前缀,再在代码中直接引用,更适合多场景复用:

Prefix: sdw = "ontologies/SDWOWL#"
Prefix: link = "ontologies/linkingOntology#"
Prefix: other = "ontologies/otherOntology#"

Individual: @A* (mm:prefix = sdw)
Facts: link:calculatedUsing @B* (mm:prefix = other)

内容的提问来源于stack exchange,提问作者Antônio Antunes

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.02 16:32:38