framework logic