From this error message, we understand that the expression that you are trying to enter for item field formula is invalid.
Step 1: Go to the Document Settings.
Step 2: Click on Add Custom Fields.
Step 3: Edit the item field for which you want to add the formula.
Step 4: Enter the Valid Expression >> Click on Save.