0

First of all, I am new to the PDDL language. I am trying to write my own domain and problem files following different examples on the Internet. While experimenting a bit with an online solver, I got an error related to the usage of multiple definitions of the same predicate. However, in the predicate definition I use different types. Is this a normal behaviour of a standard PDDL solver or it is just the implementation at hand that is causing this error? Here is my example:

(on ?o1 - edge-tool ?o2 - table)
(on ?o1 - cooking-utensil ?o2 - table)
Bilal
  • 3,191
  • 4
  • 21
  • 49
teoML
  • 784
  • 4
  • 13
  • why you don't use different predicate names? – Bilal Mar 22 '22 at 17:29
  • I thought about this and yes - I could do it. However, I also assumed that the planners are clever enough to give another name to the predicates (internally) since the types are much different. Like in computer programming the concept of Function overloading. – teoML Mar 23 '22 at 12:55

1 Answers1

0

It is not allowed in general, but you can define a common type for the different types that are compatible with your predicate. If your predicate is meaningful with different types, it is because they have something in common that is worth being expressed in the type definitions.

In your case:

(:types
  movable_object
  edge-tool cooking-ustensil - movable_object
)
(:predicates
  (on ?o1 - movable_object ?o2 - table)
)
Victor Paléologue
  • 2,025
  • 1
  • 17
  • 27