This paper identifies the output gap using the theoretical definition of the gap within a Phillips curve in the spirit of the New Keynesian framework. Using Peruvian data for the period 1980:1-2005:4, the results indicate a very flat slope of the Phillips curve but the output gap is large and persistent. Furthermore, the output gap is not correlated with the stochastic trend which is similar to the assumption used in the unobserved components model. The forward-looking component is estimated at 39% indicating a key role of this component in the inflation for a emerging country like Peru which is an economy partially dollarized using an inflation targeting scheme. The model is extended to include information coming from the unemployment rate but the results are very similar indicating poor additional information in the unemployment rate to identify the output gap. In order to compare, other estimations of the output gap are performed. The results show strong differences and the closer measure is the one obtained using the unobserved component model and the simple quadratic trend.