First thought would be heat but have you recently installed any new applications or tools? What type of environment are you using it in (i.e. office Home outdoors)? What model of laptop is it?
Are the lights on the power brick/adapter staying on when this happens? If the adapter is going bad it may not be charging the battery so when it (the power adapter) cuts out, the battery has no charge so the laptop shuts down.