Description:
The issue stems from the way parameters are parsed in the planning_editor_adaptor when one parameter is a substring of another. For instance, in the Floortile domain (see issue #55), the parameter '?c' was incorrectly parsed as '?c2' due to partial matches.
Solution
A regex-based solution has been implemented, which ensures exact matching of keys. The keys are ordered by length in descending order to prevent partial matches and ensure accurate replacement of parameters in actions.
Description: The issue stems from the way parameters are parsed in the planning_editor_adaptor when one parameter is a substring of another. For instance, in the Floortile domain (see issue #55), the parameter '?c' was incorrectly parsed as '?c2' due to partial matches.
Root cause: This misinterpretation is traced back to the code in predicate.py, lines 118-119: https://github.com/AI-Planning/planning-as-a-service/blob/3ef6c88d9d9b8f1cab1f092f1a2993ef06ecd1d1/server/api/adaptor/planning_editor_adaptor/action_plan_parser/predicate.py#L118-L119
Solution A regex-based solution has been implemented, which ensures exact matching of keys. The keys are ordered by length in descending order to prevent partial matches and ensure accurate replacement of parameters in actions.
Resolves #55