Fixed recency
Node PostProcessor module.
FixedRecencyPostprocessor #
Bases: BaseNodePostprocessor
Fixed Recency post-processor.
This post-processor does the following steps orders nodes by date.
Assumes the date_key corresponds to a date field in the metadata.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
top_k
|
int
|
|
1
|
date_key
|
str
|
|
'date'
|
Source code in llama-index-core/llama_index/core/postprocessor/node_recency.py
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
|