LlamaIndex Postprocessor Integration: Xinference Rerank
Xorbits Inference (Xinference) is an open-source platform to streamline the operation and integration of a wide array of AI models.
You can find a list of built-in rerank models in Xinference from its document Rerank Models
To learn more about Xinference in general, visit https://inference.readthedocs.io/en/stable/models/model_abilities/rerank.html
Installation
pip install llama-index-postprocessor-xinference-rerank
Usage
Parameters Description:
model: Model uid not model name, sometimes they may be the same (e.g.,bge-reranker-base).base_url: base url of Xinference (e.g.,http://localhost:9997).top_n: Top n nodes to return from reranker. (default 5).
Nodes Rerank Example
from llama_index.postprocessor.xinference_rerank import XinferenceRerank
xi_model_uid = "xinference model uid"
xi_base_url = "xinference base url"
xi_rerank = XinferenceRerank(
top_n=5,
model=xi_model_uid,
base_url=xi_base_url,
)
def test_rerank_nodes(nodes, query_str):
response = xi_rerank.postprocess_nodes(nodes, query_str)
Metadata
Release files for llama-index-postprocessor-xinference-rerank 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| llama_index_postprocessor_xinference_rerank-0.5.0.tar.gz | 4.5 kB | Without provenance | Details for llama_index_postprocessor_xinference_rerank-0.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| llama_index_postprocessor_xinference_rerank-0.5.0-py3-none-any.whl | Python 3 | none | any | Details for llama_index_postprocessor_xinference_rerank-0.5.0-py3-none-any.whl |
Total release size: 8.7 kB
Release files / llama_index_postprocessor_xinference_rerank-0.5.0.tar.gz
| Download URL | llama_index_postprocessor_xinference_rerank-0.5.0.tar.gz |
|---|---|
| Size | 4.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8cae41b80185e720bee33a1f68000827b11aa8ca70cf4b658dd913d2043068b2
|
|
BLAKE2b-256 checksum How to use checksums |
8d1b3bb3124958cc303a2556a3e7b445dded857021e7325b2360fb3141d8603d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / llama_index_postprocessor_xinference_rerank-0.5.0-py3-none-any.whl
| Download URL | llama_index_postprocessor_xinference_rerank-0.5.0-py3-none-any.whl |
|---|---|
| Size | 4.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fd960d203d428992a6e2aeaae464fded76993fbab0620712494dfb954debbc8e
|
|
BLAKE2b-256 checksum How to use checksums |
7d95e8e9b4ac824536b98ea9527449c26b81ace366a404a7f9167dbca2b7a5a0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for llama-index-postprocessor-xinference-rerank 0.5.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.