> For the complete documentation index, see [llms.txt](https://docs.maiagent.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.maiagent.ai/tech/ja/quickstart/reranker.md).

# Reranker モデル

Reranker モデルによる検索後の段落の並べ替え、MaiAgent での Reranker の使い方、クラウドで有効なモデル、オンプレミスのモデル、自前サービスの URL のルールについて説明します。

## Reranker とは？ <a href="#what-is-reranker" id="what-is-reranker"></a>

Reranker は「並べ替え」に特化したモデルです。第1段階の検索（ベクトル検索とキーワード検索）は高速ですが、大まかな照合しかできません。Reranker は質問と各候補段落を組み合わせて関連度を個別に評価し、スコア順に並べ替えることで、質問への回答となる段落を上位に表示します。

{% stepper %}
{% step %}

### 初期検索 <a href="#first-stage" id="first-stage"></a>

ベクトル検索とキーワード検索で、ナレッジベースから候補段落をすばやく取得します。
{% endstep %}

{% step %}

### 再スコアリング <a href="#scoring" id="scoring"></a>

Reranker が「質問＋段落」を個別に照合し、各段落に関連度スコアを付けます。
{% endstep %}

{% step %}

### 絞り込み <a href="#selection" id="selection"></a>

スコア上位の段落を残し、類似度のしきい値を下回る段落を除外してから、大規模言語モデルに渡します。
{% endstep %}
{% endstepper %}

## MaiAgent での Reranker の使い方 <a href="#how-maiagent-uses-reranker" id="how-maiagent-uses-reranker"></a>

* ナレッジベースごとに Reranker モデルを選択し、<mark style="color:blue;">検索結果の並べ替えを有効にする (Reranking)</mark> スイッチで有効・無効を切り替えます（デフォルトは有効です）。
* 有効な場合、第1段階で <mark style="color:blue;">検索する段落数</mark> × プラットフォームで設定された倍率（デフォルトは7倍）の候補を取得します。Reranker で並べ替えた後、<mark style="color:blue;">検索する段落数</mark> の件数だけを残します。
* <mark style="color:blue;">類似度のしきい値（0～1）</mark> は Reranker のスコアに適用されるため、Reranker が有効な場合のみ機能します。
* 無効な場合、第1段階で直接 <mark style="color:blue;">検索する段落数</mark> の件数を取得し、並べ替えも類似度のしきい値の適用も行いません。

全体の流れは [RAG ナレッジベース検索システム](/tech/ja/quickstart/rag.md#rerank)をご覧ください。

## MaiAgent クラウドで有効なモデル <a href="#saas-models" id="saas-models"></a>

以下は2026年10月時点で本番環境で有効なモデルの一覧です。ナレッジベース作成時に選択できるモデルは、管理画面の表示をご確認ください。

| モデル（管理画面での名称）         | プロバイダー                     |
| --------------------- | -------------------------- |
| Cohere Rerank v3.5    | Cohere（`rerank-v3.5`）      |
| Cohere Rerank v4 Pro  | Cohere（`rerank-v4.0-pro`）  |
| Cohere Rerank v4 Fast | Cohere（`rerank-v4.0-fast`） |

## オンプレミスへのデプロイ <a href="#on-premise" id="on-premise"></a>

オンプレミスやプライベートクラウドでは、Reranker をローカルにデプロイできます（デプロイパッケージのモデルカタログには `jina-reranker-v2-base-multilingual` と `bge-reranker-v2-m3` が含まれ、GPU が必要です）。既存のモデルサービスやクラウドプロバイダーへの接続も可能です。利用可能なモデルと接続方法は[オンプレミスのモデルサービス接続](/tech/ja/platform-development/onprem-model-services.md#local-model-catalog)を、各クラウドプロバイダーの Reranker 対応状況は[クラウドモデル推論 API サービス](/tech/ja/platform-development/cloud-model-inference-api-service.md)をご覧ください。

{% hint style="warning" %}
**自前の Reranker サービスを使用する場合、URL に `/v1` を付けないでください**。付けると、ナレッジベース検索がすべて失敗します。URL のルールは[オンプレミスのモデルサービス接続：既存の OpenAI 互換モデルサービスへの接続](/tech/ja/platform-development/onprem-model-services.md#external-openai-compatible)をご覧ください。
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.maiagent.ai/tech/ja/quickstart/reranker.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
