DFKI-NI / mobipick_labs

Other
4 stars 1 forks source link

add handover action to tables demo domain #33

Closed marcvinci closed 1 year ago

marcvinci commented 1 year ago
alexander-sung commented 1 year ago

If an item is perceived, is it considered as not (yet) offered? So I understand the changes to perceive() in tables_demo_api.py.

Edit: It's also in your description. ^^ However, this could cause problems if an offered item is perceived again "unintentionally", don't you think?

alexander-sung commented 1 year ago

About the item having been offered, I actually have no better idea for the general case because it really depends on the situation.

For the InCoRAP use-case, would it make sense not to discard the item_offered fluent on pick or perceive but instead treat it as a separate, explicit action?

alexander-sung commented 1 year ago

Although, it probably does not look as nice, I'd like to change the wording for the verb "to hand over" in contrast to the "handover" noun. There were inconsistencies before, so this is an opportunity to resolve them.

Other than the points addressed before, the demos also run well on my side.

marcvinci commented 1 year ago

However, this could cause problems if an offered item is perceived again "unintentionally", don't you think?

Yes, this will be the case if the offered item is placed again on one of the tables or inside a box. At least the item cannot be perceived unintentionally in the persons hand, since it uses the "on" and "in" facts to remove the item_offered fact.

For the InCoRAP use-case, would it make sense not to discard the item_offered fluent on pick or perceive but instead treat it as a separate, explicit action?

Yes, for InCoRAP the handover action will probably only be executed once for each item, but my reasoning behind the removal of the fluent after perceiving or picking up, is to have a more general case, where we can hand items over to a person and if that item is requested again and also found again on a table, the action can be repeated.

alexander-sung commented 1 year ago

A good thought. I just think it's really hard to say what the more general case is. Hopefully nobody will wonder about the item _offered fluent being cleared again but indeed, the item in question would need to be placed into the scene again, that's true.

One more thought about discarding on pick: The planner won't be able to plan to pick up the item again for handover unless that is also reflected in the UP action, so you probably want to add self.pick_item.add_effect(self.item_offered(item), False) also for consistency, right?

Edit: Actually, no - still doesn't seem to be meaningful. Currently, I prefer to remove it from the pick action and leave it for perceive with the reasoning you provided. I'm still open for better solutions, though. Please also add the reasoning as comment if you want to keep it for perceive.