refactoring and state cache fixes
implemented fragment filters