1. A computer-implemented method comprising: maintaining, by a computer processor, in an online system: a plurality of feature expressions, where at least one of the feature expressions comprises an expression composing one or more other feature expressions of the plurality of feature expressions using operators, the expression capable of being processed by a computer processor to map a set of input values to an output value, wherein the feature expression evaluates to a value describing one or more entities in the online system, wherein the plurality of feature expressions can be modified by performing one or more of addition of a new feature expression, deletion of an existing feature expression, or update of an existing feature expression, wherein the modification to the plurality of feature expressions is performed while the online system is executing, and a set of policies, each policy comprising a precondition represented as a feature expression and a policy action, wherein the policy action is executed if the precondition is satisfied; receiving information describing one or more actions performed by users of the online system, each action associated with entities of the online system; and responsive to receiving information describing each action: evaluating each feature expression from the plurality of feature expressions, determining whether a precondition of a policy from the set of policies is satisfied based on feature expression of the precondition, and responsive to the precondition of the policy being satisfied, executing the corresponding policy action.
1. A computer-implemented method comprising: maintaining, by a computer processor, in an online system: a plurality of feature expressions, where at least one of the feature expressions comprises an expression composing one or more other feature expressions of the plurality of feature expressions using operators, the expression capable of being processed by a computer processor to map a set of input values to an output value, wherein the feature expression evaluates to a value describing one or more entities in the online system, wherein the plurality of feature expressions can be modified by performing one or more of addition of a new feature expression, deletion of an existing feature expression, or update of an existing feature expression, wherein the modification to the plurality of feature expressions is performed while the online system is executing, and a set of policies, each policy comprising a precondition represented as a feature expression and a policy action, wherein the policy action is executed if the precondition is satisfied; receiving information describing one or more actions performed by users of the online system, each action associated with entities of the online system; and responsive to receiving information describing each action: evaluating each feature expression from the plurality of feature expressions, determining whether a precondition of a policy from the set of policies is satisfied based on feature expression of the precondition, and responsive to the precondition of the policy being satisfied, executing the corresponding policy action. 7. The computer-implemented method of claim 1 , wherein the online system is a social networking system, wherein a particular feature expression comprises a sub-expression and an input to the particular feature expression comprises information identifying a first user and a second user, wherein evaluating the particular feature expression comprises: identifying other users connected to both the first user and the second user; and evaluating the sub-expression for each of the other users connected to both the first user and the second user.