嵌入时效性
节点后处理器模块。
EmbeddingRecencyPostprocessor #
嵌入新近度后处理器。
参数
名称 | 类型 | 描述 | 默认值 |
---|---|---|---|
embed_model
|
BaseEmbedding
|
|
<动态>
|
date_key
|
str
|
|
'date'
|
similarity_cutoff
|
float
|
|
0.7
|
query_embedding_tmpl
|
str
|
|
'提供当前文档。\n----------------\n{context_str}\n----------------\n给定此文档,我们希望找到包含相似上下文的文档。\n请注意,这些文档比当前文档旧,这意味着某些细节可能已更改。\n但是,高层上下文应该相似。\n'
|
源代码位于 llama-index-core/llama_index/core/postprocessor/node_recency.py
中
94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 |
|