Fix mixup in IndexSpace and SequenceSpace
Fix small mistakes
Add tests for SequenceSpace