Smart Sequence added

Smart sequence fully working.