Interface is useful for summarizing the contract (functions list with the body removed). Later we can try to craft contracts that imitate the target contract's input/output format.
Guessing main contract is useful for user interface suggestion when they load the contract, we auto select the main contract. It is also useful for testing where we focus on the main contract.
I think of this rule: the main contract is the one that is not abstract and does not have children. In case we have multiple contracts with the same property, we guess it's the longest contract.
Interface is useful for summarizing the contract (functions list with the body removed). Later we can try to craft contracts that imitate the target contract's input/output format.
Guessing main contract is useful for user interface suggestion when they load the contract, we auto select the main contract. It is also useful for testing where we focus on the main contract.
I think of this rule: the main contract is the one that is not abstract and does not have children. In case we have multiple contracts with the same property, we guess it's the longest contract.