owned this note
owned this note
Published
Linked with GitHub
# Meso Research Plan for Termination Fee
###### tags: `Meso-Research`
:::info
Up to date by October 2021
:::
Meso Research Plans are living documents that indicates a general area of inquiry around one specific topic. Sections/items are not exhaustive and will be added over time.
## Goal
- To create a FIP outlining changes to the Termination Fee that work from 'first principles' as compared with the current _ad hoc_ approach.
- Sub-goals include:
- how to adjust the cap on the number of days' block reward to penalize,
- answering whether or not the initial consensus pledge should also be penalized (as it is much larger than the initial storage pledge),
- what functional form parameters (e.g. the 1/2 'discount') should be updated/removed,
- ...
## Context
- The termination fee is levied whenever:
1. a storage provider manually exercises the termination of a sector before its expiration, or
2. the protocol registers a faulty state for 14 consecutive days for a sector.
- Currently, the termination fee is min. 20 days and max. 90 days of expected block reward, i.e. the initial storage pledge amount and then a (capped) assessment based upon the lifetime of the sector.
- The termination fee currently disincentivizes upgrading a sector from committed capacity to deal (data) storage solely to recoup termination fee savings, by ensuring that the termination fee for an upgraded sector is at least as large as for a non-upgraded sector.
## Importance
- Incentives for both storage providers and data providers are potentially heavily impacted by the termination fee's structure.
- If the empirically-observed termination fee frequency is considered to be too high, adjusting the termination fee upward should be assessed for possible incentive impact.
## Knowledge Applications
- Related to storage provider preferences and optimization
- Related to data provider risk tolerance (preferences) and trust
- Related to legal requirements (e.g. GDPR "right to be forgotten") imposed upon storage provider when data provider wishes data to be removed
## Directions
- Theoretical framework to understand change in storage provision following an increase in the termination fee
- Theoretical framework to understand change in deal fees resulting from an increase in the termination fee
- Analysis of legal requirements for removal of data in response to client request (e.g. GDPR)
- EDA assessing existing manual terminations and attempting to classify reasons for termination (if possible)
## Reward function follow-up
Using the reward function specification from the [Insurance mechanism with finite time](https://hackmd.io/@R02mDHrYQ3C4PFmNaxF5bw/H1LzmEVVF) analysis, the role of the termination fee as a _numeraire_ of the fault reward structure can be specified and analyzed.
As a motivating example, consider the polynomial reward function $R$ that is used to assess fault fees up to the termination time $x_{max}$:
$$
R(x) := -Fx + (c + a x^{\alpha} + b x^{\beta}), \qquad x \in [0,x_{max}].
$$
The termination fee $TF$ is a terminal condition lump-sum penalty that is assessed whenever the realized fault recovery time, $x$, exceeds the termination time $x_{max}$. Thus, the total reward $V$, which is a random variable, is:
$$
V(x) := R(x) \chi_{x \leq x_{max}} + TF \chi_{x > x_{max}},
$$
where $\chi_{event}$ is an indicator function equaling $1$ when an $event$ is TRUE and $0$ otherwise.
The expected reward to a miner under the fault duration $X$ exponential probability distribution
$$
\Pr(X \leq x | \lambda) := \lambda \int_0^x e^{-\lambda x}dx
$$
is then
$$
\mathbb{E}_\lambda(V) = \lambda \int_0^\infty V(x) e^{\lambda x}dx = \lambda \int_0^{x_{max}} (-Fx + c + a x^\alpha + b x^\beta) e^{\lambda x}dx + TF \lambda \int_{x_{max}}^\infty e^{\lambda x}dx.
$$
This has the analytical solution:
$$
\mathbb{E}_\lambda(V) = (c - TF)\left ( 1 - e^{-\lambda x_{max}} \right ) - F \left ( \frac{1}{\lambda} - e^{-\lambda x_{max}} \left (x_{max} + \frac{1}{\lambda} \right ) \right ) + \\
a \lambda^{-\alpha} \gamma(1+\alpha, \lambda x_{max}) + b \lambda^{-\beta} \gamma(1+\beta, \lambda x_{max}),
$$
where $\gamma(a,x)$ is the incomplete Gamma function:
$$
\gamma(a,x):= \int_0^x e^{-t} t^{a - 1} dt, \qquad \operatorname{Re}(a) > 0.
$$
This can be simplified slightly to yield:
$$
\mathbb{E}_\lambda(V) = (c - TF)\left ( 1 - e^{-\lambda x_{max}} \right ) - F \left ( \frac{1}{\lambda} - e^{-\lambda x_{max}} \left (x_{max} + \frac{1}{\lambda} \right ) \right ) + \\
\int_0^{\lambda x_{max}} e^{-t} \left (at^\alpha + bt^\beta \right ) dt.
$$
Recall from the [Insurance mechanism with finite time](https://hackmd.io/@R02mDHrYQ3C4PFmNaxF5bw/H1LzmEVVF) analysis that the polynomial parameters $(a,b,\alpha,\beta)$ may be chosen according to a set of constraints fixing e.g the initial discount, minimum reward time, and reward at termination. To this parameter list may be added the termination fee time $x_{max}$, and the termination fee amount $TF$, and the total vector of parameters:
$$
\pi := (a, b, \alpha, \beta, x_{max}, TF)
$$
may be selected using both the constraints above _and_ desired risk/reward tradeoff balancing the termination fee against the reward from recovering before termination.
For example, if it were desired for the miner to expect no excess penalty or reward for faults under normal operating conditions, _whatever their duration_, then one would select a parameter vector $\pi^*$ such that
$$
\mathbb{E}_\lambda(V | \pi^*) = 0.
$$
Naturally there are other constraints that apply to the specification of the termination fee, but they can be examined in light of their effect on the expected reward, both for faults distributed under normal operating conditions, and for faults distributed when a shock occurs.