Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2020-03-23 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
-+-
 Reporter:  Andrii Soldatenko|Owner:  Hannes
 |  Ljungberg
 Type:  New feature  |   Status:  closed
Component:  contrib.postgres |  Version:  master
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"0b51a4f8946178daf469bec4cbedbc02a23cf814" 0b51a4f]:
 {{{
 #!CommitTicketReference repository=""
 revision="0b51a4f8946178daf469bec4cbedbc02a23cf814"
 Fixed #28194 -- Added support for normalization and cover density to
 SearchRank.
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.c78a62b070c2bdd33572b4e7e7914dfa%40djangoproject.com.


Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2020-03-23 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
-+-
 Reporter:  Andrii Soldatenko|Owner:  Hannes
 |  Ljungberg
 Type:  New feature  |   Status:  assigned
Component:  contrib.postgres |  Version:  master
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by felixxm):

 * needs_better_patch:  1 => 0
 * version:  1.11 => master
 * stage:  Accepted => Ready for checkin


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.0295b84f3fbdcd23a8db1129d2fd4926%40djangoproject.com.


Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2020-03-22 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
-+-
 Reporter:  Andrii Soldatenko|Owner:  Hannes
 |  Ljungberg
 Type:  New feature  |   Status:  assigned
Component:  contrib.postgres |  Version:  1.11
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Simon Charette):

 * owner:  Andrii Soldatenko => Hannes Ljungberg
 * needs_better_patch:  0 => 1
 * has_patch:  0 => 1


Comment:

 https://github.com/django/django/pull/12597

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.2f2c9cdc4a4c95bb2895626081256e50%40djangoproject.com.


Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2017-05-15 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
-+-
 Reporter:  Andrii Soldatenko|Owner:  Andrii
 |  Soldatenko
 Type:  New feature  |   Status:  assigned
Component:  contrib.postgres |  Version:  1.11
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Andrii Soldatenko):

 * status:  new => assigned
 * owner:  nobody => Andrii Soldatenko


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.f27284119ffb0d0bdf1c725af3464905%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2017-05-15 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
---+
 Reporter:  Andrii Soldatenko  |Owner:  nobody
 Type:  New feature|   Status:  new
Component:  contrib.postgres   |  Version:  1.11
 Severity:  Normal |   Resolution:
 Keywords: | Triage Stage:  Accepted
Has patch:  0  |  Needs documentation:  0
  Needs tests:  0  |  Patch needs improvement:  0
Easy pickings:  0  |UI/UX:  0
---+
Changes (by Tim Graham):

 * stage:  Unreviewed => Accepted


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.499606ddb114450381b147ff9300f175%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #28194: Add search rank cd function and normalization for Postgres full text search

2017-05-11 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
---+--
 Reporter:  Andrii Soldatenko  |Owner:  nobody
 Type:  New feature|   Status:  new
Component:  contrib.postgres   |  Version:  1.11
 Severity:  Normal |   Resolution:
 Keywords: | Triage Stage:  Unreviewed
Has patch:  0  |  Needs documentation:  0
  Needs tests:  0  |  Patch needs improvement:  0
Easy pickings:  0  |UI/UX:  0
---+--
Changes (by Andrii Soldatenko):

 * type:  Uncategorized => New feature
 * component:  Uncategorized => contrib.postgres


--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.491324f740c6860a637e20440bfad26f%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


[Django] #28194: Add search rank cd function and normalization for Postgres full text search

2017-05-11 Thread Django
#28194: Add search rank cd function and normalization for Postgres full text 
search
-+
   Reporter:  Andrii Soldatenko  |  Owner:  nobody
   Type:  Uncategorized  | Status:  new
  Component:  Uncategorized  |Version:  1.11
   Severity:  Normal |   Keywords:
   Triage Stage:  Unreviewed |  Has patch:  0
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+
 It would be great to have cover density ranking for the given document
 vector and query function `ts_rank_cd`. It helps to order search results
 with different normalization strategies.

 Also add `normalization` parameter option that specifies whether and how a
 document's length should impact its rank.

 >0 (the default) ignores the document length
 >1 divides the rank by 1 + the logarithm of the document length
 >2 divides the rank by the document length
 >4 divides the rank by the mean harmonic distance between extents (this is
 implemented only by ts_rank_cd)
 >8 divides the rank by the number of unique words in document
 >16 divides the rank by 1 + the logarithm of the number of unique words in
 document
 >32 divides the rank by itself + 1


 Now you can do something like this:

 {{{
 class SearchRankCD(SearchRank):
 function = 'ts_rank_cd'

 def __init__(self, vector, query, normalization=0, **extra):
 super(SearchRank, self).__init__(
 vector, query, normalization, **extra)

 query = SearchQuery('messenger')

 Application.objects.annotate(
 rank=SearchRankCD(
 F('search_vector_title'), query,
 normalization=2)  # 2 divides the rank by the document length
 ).filter(search_vector_title=query).order_by('-rank')
 }}}

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/059.67311c5a813d5077386725ebcf281f61%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.