mrfuxi/simple_search
A simple search API
README
This is a really basic search engine for Django. To use, simply add simple_search to INSTALLED_APPS
and register models for searching as follows:
class MyModel(Model):
field1 = models.CharField(max_length=1000)
class Search:
fields = [
"field1"
]
Then import simple_search.models.search and call:
search(MyModel, 'this is a "search string"')
search() can take pagination options. There is still plenty unimplemented (see the comment in models.py)
The ranking algorithm prioritises multiple word matches and uncommon matches.