Abstract:A computational mechanism for context-free language parsing is proposed in this paper, which is called role inverse algorithm. The mechanism is based on the assignment of appropriate roles to categories according to their contexts. A kind of effectual 搇ook ahead?function is introduced into chart parsing by this mechanism at acceptable cost. As a result, lots of useless arcs in a chart can be avoided, so that a parsing process is accelerated. This mechanism can be used in many applications, such as natural language processing.