Docs: correct wrong URL for related_questions HTTP API (#7507)

### What problem does this PR solve?

Correct wrong URL for related_questions HTTP API. #7282

### Type of change

- [x] Documentation Update
This commit is contained in:
Yongteng Lei 2025-05-08 09:32:21 +08:00 committed by GitHub
parent 7b57ab5dea
commit 014a1535f2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -14,7 +14,7 @@ A complete reference for RAGFlow's RESTful API. Before proceeding, please ensure
--- ---
| Code | Message | Description | | Code | Message | Description |
|------|-----------------------|----------------------------| | ---- | --------------------- | -------------------------- |
| 400 | Bad Request | Invalid request parameters | | 400 | Bad Request | Invalid request parameters |
| 401 | Unauthorized | Unauthorized access | | 401 | Unauthorized | Unauthorized access |
| 403 | Forbidden | Access denied | | 403 | Forbidden | Access denied |
@ -172,7 +172,9 @@ Failure:
"message": "The last content of this conversation is not from user." "message": "The last content of this conversation is not from user."
} }
``` ```
--- ---
### Create agent completion ### Create agent completion
**POST** `/api/v1/agents_openai/{agent_id}/chat/completions` **POST** `/api/v1/agents_openai/{agent_id}/chat/completions`
@ -406,7 +408,7 @@ curl --request POST \
- `"parser_config"`: (*Body parameter*), `object` - `"parser_config"`: (*Body parameter*), `object`
The configuration settings for the dataset parser. The attributes in this JSON object vary with the selected `"chunk_method"`: The configuration settings for the dataset parser. The attributes in this JSON object vary with the selected `"chunk_method"`:
- If `"chunk_method"` is `"naive"`, the `"parser_config"` object contains the following attributes: - If `"chunk_method"` is `"naive"`, the `"parser_config"` object contains the following attributes:
- `"auto_keywords"`: `int` - `"auto_keywords"`: `int`
- Defaults to `0` - Defaults to `0`
- Minimum: `0` - Minimum: `0`
- Maximum: `32` - Maximum: `32`
@ -420,7 +422,7 @@ curl --request POST \
- Maximum: `2048` - Maximum: `2048`
- `"delimiter"`: `string` - `"delimiter"`: `string`
- Defaults to `"\n"`. - Defaults to `"\n"`.
- `"html4excel"`: `bool` Indicates whether to convert Excel documents into HTML format. - `"html4excel"`: `bool` Indicates whether to convert Excel documents into HTML format.
- Defaults to `false` - Defaults to `false`
- `"layout_recognize"`: `string` - `"layout_recognize"`: `string`
- Defaults to `DeepDOC` - Defaults to `DeepDOC`
@ -429,9 +431,9 @@ curl --request POST \
- `"task_page_size"`: `int` For PDF only. - `"task_page_size"`: `int` For PDF only.
- Defaults to `12` - Defaults to `12`
- Minimum: `1` - Minimum: `1`
- `"raptor"`: `object` RAPTOR-specific settings. - `"raptor"`: `object` RAPTOR-specific settings.
- Defaults to: `{"use_raptor": false}` - Defaults to: `{"use_raptor": false}`
- `"graphrag"`: `object` GRAPHRAG-specific settings. - `"graphrag"`: `object` GRAPHRAG-specific settings.
- Defaults to: `{"use_graphrag": false}` - Defaults to: `{"use_graphrag": false}`
- If `"chunk_method"` is `"qa"`, `"manuel"`, `"paper"`, `"book"`, `"laws"`, or `"presentation"`, the `"parser_config"` object contains the following attribute: - If `"chunk_method"` is `"qa"`, `"manuel"`, `"paper"`, `"book"`, `"laws"`, or `"presentation"`, the `"parser_config"` object contains the following attribute:
- `"raptor"`: `object` RAPTOR-specific settings. - `"raptor"`: `object` RAPTOR-specific settings.
@ -3167,10 +3169,12 @@ Failure:
### Related Questions ### Related Questions
**POST** `/api/v1/conversation/related_questions` **POST** `/v1/conversation/related_questions`
Generates five to ten alternative question strings from the user's original query to retrieve more relevant search results. Generates five to ten alternative question strings from the user's original query to retrieve more relevant search results.
This operation requires a `Bearer Login Token`, typically expires with in 24 hours. You can find the it in the browser request easily.
:::tip NOTE :::tip NOTE
The chat model dynamically determines the number of questions to generate based on the instruction, typically between five and ten. The chat model dynamically determines the number of questions to generate based on the instruction, typically between five and ten.
::: :::
@ -3178,10 +3182,10 @@ The chat model dynamically determines the number of questions to generate based
#### Request #### Request
- Method: POST - Method: POST
- URL: `/api/v1/conversation/related_questions` - URL: `/v1/conversation/related_questions`
- Headers: - Headers:
- `'content-Type: application/json'` - `'content-Type: application/json'`
- `'Authorization: Bearer <YOUR_API_KEY>'` - `'Authorization: Bearer <YOUR_LOGIN_TOKEN>'`
- Body: - Body:
- `"question"`: `string` - `"question"`: `string`
@ -3189,9 +3193,9 @@ The chat model dynamically determines the number of questions to generate based
```bash ```bash
curl --request POST \ curl --request POST \
--url http://{address}/api/v1/conversation/related_questions \ --url http://{address}/v1/conversation/related_questions \
--header 'Content-Type: application/json' \ --header 'Content-Type: application/json' \
--header 'Authorization: Bearer <YOUR_API_KEY>' \ --header 'Authorization: Bearer <YOUR_LOGIN_TOKEN>' \
--data ' --data '
{ {
"question": "What are the key advantages of Neovim over Vim?" "question": "What are the key advantages of Neovim over Vim?"
@ -3351,3 +3355,4 @@ Failure:
``` ```
--- ---