Имя слота предопределено для всех классов, поэтому вам придется переименовать этот слот в вашем классе ATTRIBUTE во что-то другое (например, атрибут).Поскольку обработчики сообщений могут динамически изменять значение, назначаемое слоту, вам также необходимо включить динамическую проверку ограничений.
CLIPS (6.31 2/3/18)
CLIPS>
(defclass ATTRIBUTE
(is-a USER)
(slot attribute
(type STRING))
(slot value
(type INTEGER)))
CLIPS>
(defclass PROFILE
(is-a USER)
(multislot skill
(type INSTANCE)
(allowed-classes ATTRIBUTE)))
CLIPS> (set-dynamic-constraint-checking TRUE)
FALSE
CLIPS> (make-instance a1 of ATTRIBUTE)
[a1]
CLIPS> (make-instance p1 of PROFILE (skill 3))
[CSTRNCHK1] (3) for slot skill of instance [p1] found in put-skill primary in class PROFILE
does not match the allowed types.
[PRCCODE4] Execution halted during the actions of message-handler put-skill primary in class PROFILE
FALSE
CLIPS> (make-instance p1 of PROFILE (skill [a1]))
[p1]
CLIPS> (make-instance p2 of PROFILE (skill (instance-address [a1])))
[p2]
CLIPS> (defclass OTHER (is-a USER))
CLIPS> (make-instance o1 of OTHER)
[o1]
CLIPS> (make-instance p3 of PROFILE (skill [o1]))
[CSTRNCHK1] ([o1]) for slot skill of instance [p3] found in put-skill primary in class PROFILE
does not match the allowed classes.
[PRCCODE4] Execution halted during the actions of message-handler put-skill primary in class PROFILE
FALSE
CLIPS>