...provided by the will to avoid liability for debts?
Acceptance of inheritance includes acceptance, including unfulfilled obligations of the testator (fulfilment of debt obligations).
To avoid debt, you can write a written refusal to accept the inheritance.