Rough implementation of history
History function full implemented