schema
TagField("$.id", as_name="id"),
TextField("$.brand", as_name="brand"),
TextField("$.title", as_name="title"),
TextField("$.category", as_name="category"),
TextField("$.param", as_name="param"),
TextField("$.tags", as_name="tags"),
NumericField("$.price", as_name="price"),
NumericField("$.comments.positive_ratio", as_name="positive_ratio"),
unexpected reason
- no chinese posts are allowed, i attached my snapshot
- unexpected return results when using chinese language, the explain result can tell you the difference
- i can not found enough documentation in redis.io to fix this problem
From the documentation on
FT.CREATE:You have to define your index as Chinese index in order to make RediSearch use the right indexing methods.
Using
redis-py, the language attributes should be passed toIndexDefinitionattributes:Notice that you also have to specify the language on the query itself. From
FT.SEARCHdocumentation:And again, using
redispy, the query should look something like this: