ScriptableObject with instance-attached script

Hello there. I'm looking for help, because i want to create a very specific type of data.

For my game, i need Effect concept.

Let's say we imagine a first effect :

Fire. Fire deals damage to target for 10 sec each second.

Benumbed. Benumbed modify the speed stat of target for 6 sec.

I have multiple other idea and i'm trying to make an optimized workflow, allowing to quickly create new effects.

In some ways ScriptableObjects are exactly what i want. But the main con of it is that i cannot write an instance attached script. All Effects have share the common point of having a duration between 0 and infinity and they all have an OnApply function that just make things happend.

Here is the problem. While the duration is easy to serialize, allowing me to set a duration for each different effect, i cannot easily serialize the OnApply function, or callback.

What i want is a ScriptableObject, where i can write a specific and different callback for each individual instance of it.