You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add native support for UNF and NOINDEX field attributes (#374)
Implements native support for Redis field attributes UNF (un-normalized form) and NOINDEX
to provide more control over field indexing and sorting behavior.
BREAKING CHANGE: None - all changes are backward compatible with default values
- Add `no_index` attribute to BaseFieldAttributes for all field types
- Add `unf` attribute to TextFieldAttributes and NumericFieldAttributes
- Both attributes default to False maintaining backward compatibility
Field Support:
- TextField: Supports both no_index and unf attributes
- NumericField: Supports both no_index and unf attributes
- TagField: Supports no_index attribute
- GeoField: Supports no_index attribute
Technical Implementation:
- NOINDEX implemented via redis-py's native no_index parameter
- UNF added via args_suffix manipulation with proper ordering
- Both attributes require sortable=True to take effect
- Special parsing logic handles Redis auto-adding UNF to sortable numeric fields
Fixes#374
0 commit comments