Skip to content

Commit c6ad6aa

Browse files
committed
Update chat feature to chatCompletions and fix Tabs formatting
- Change experimental feature name from 'chat' to 'chatCompletions' - Fix Tabs component usage to use Tabs.Container and Tabs.Content - Update all documentation references to use chatCompletions terminology - Maintain consistent provider configurations across all examples
1 parent 298ac04 commit c6ad6aa

File tree

4 files changed

+64
-64
lines changed

4 files changed

+64
-64
lines changed

guides/ai/getting_started_with_chat.mdx

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ description: Learn how to implement AI-powered conversational search in your app
66

77
import { Warning, Note } from '/snippets/notice_tag.mdx'
88

9-
This guide walks you through implementing Meilisearch's chat feature to create conversational search experiences in your application.
9+
This guide walks you through implementing Meilisearch's chatCompletions feature to create conversational search experiences in your application.
1010

1111
<Warning>
12-
The chat feature is experimental and must be enabled before use. See [experimental features](/reference/api/experimental_features) for activation instructions.
12+
The chatCompletions feature is experimental and must be enabled before use. See [experimental features](/reference/api/experimental_features) for activation instructions.
1313
</Warning>
1414

1515
## Prerequisites
@@ -18,30 +18,30 @@ Before starting, ensure you have:
1818
- Meilisearch instance running (v1.15.1 or later)
1919
- An API key from an LLM provider (OpenAI, Azure OpenAI, Mistral, Gemini, or access to a vLLM server)
2020
- At least one index with searchable content
21-
- The chat experimental feature enabled
21+
- The chatCompletions experimental feature enabled
2222

2323
## Quick start
2424

25-
### 1. Enable the chat feature
25+
### 1. Enable the chatCompletions feature
2626

27-
First, enable the chat experimental feature:
27+
First, enable the chatCompletions experimental feature:
2828

2929
```bash
3030
curl \
3131
-X PATCH 'http://localhost:7700/experimental-features' \
3232
-H 'Authorization: Bearer MASTER_KEY' \
3333
-H 'Content-Type: application/json' \
3434
--data-binary '{
35-
"chat": true
35+
"chatCompletions": true
3636
}'
3737
```
3838

39-
### 2. Configure a chat workspace
39+
### 2. Configure a chatCompletions workspace
4040

4141
Create a workspace with your LLM provider settings. Here are examples for different providers:
4242

43-
<Tabs>
44-
<Tab label="OpenAI">
43+
<Tabs.Container labels={["OpenAI", "Azure OpenAI", "Mistral", "Gemini", "vLLM"]}>
44+
<Tabs.Content label="OpenAI">
4545
```bash
4646
curl \
4747
-X PUT 'http://localhost:7700/chats/my-assistant/settings' \
@@ -54,8 +54,8 @@ Create a workspace with your LLM provider settings. Here are examples for differ
5454
"prompt": "You are a helpful assistant. Answer questions based only on the provided context."
5555
}'
5656
```
57-
</Tab>
58-
<Tab label="Azure OpenAI">
57+
</Tabs.Content>
58+
<Tabs.Content label="Azure OpenAI">
5959
```bash
6060
curl \
6161
-X PUT 'http://localhost:7700/chats/my-assistant/settings' \
@@ -69,8 +69,8 @@ Create a workspace with your LLM provider settings. Here are examples for differ
6969
"prompt": "You are a helpful assistant. Answer questions based only on the provided context."
7070
}'
7171
```
72-
</Tab>
73-
<Tab label="Mistral">
72+
</Tabs.Content>
73+
<Tabs.Content label="Mistral">
7474
```bash
7575
curl \
7676
-X PUT 'http://localhost:7700/chats/my-assistant/settings' \
@@ -83,8 +83,8 @@ Create a workspace with your LLM provider settings. Here are examples for differ
8383
"prompt": "You are a helpful assistant. Answer questions based only on the provided context."
8484
}'
8585
```
86-
</Tab>
87-
<Tab label="Gemini">
86+
</Tabs.Content>
87+
<Tabs.Content label="Gemini">
8888
```bash
8989
curl \
9090
-X PUT 'http://localhost:7700/chats/my-assistant/settings' \
@@ -97,8 +97,8 @@ Create a workspace with your LLM provider settings. Here are examples for differ
9797
"prompt": "You are a helpful assistant. Answer questions based only on the provided context."
9898
}'
9999
```
100-
</Tab>
101-
<Tab label="vLLM">
100+
</Tabs.Content>
101+
<Tabs.Content label="vLLM">
102102
```bash
103103
curl \
104104
-X PUT 'http://localhost:7700/chats/my-assistant/settings' \
@@ -111,10 +111,10 @@ Create a workspace with your LLM provider settings. Here are examples for differ
111111
"prompt": "You are a helpful assistant. Answer questions based only on the provided context."
112112
}'
113113
```
114-
</Tab>
115-
</Tabs>
114+
</Tabs.Content>
115+
</Tabs.Container>
116116

117-
### 3. Send your first chat request
117+
### 3. Send your first chatCompletions request
118118

119119
Now you can start a conversation:
120120

learn/ai_powered_search/conversational_search_with_chat.mdx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ description: Learn how to implement AI-powered conversational search using Meili
66

77
import { Warning } from '/snippets/notice_tag.mdx'
88

9-
Meilisearch's chat feature enables AI-powered conversational search, allowing users to ask questions in natural language and receive direct answers based on your indexed content. This feature transforms the traditional search experience into an interactive dialogue.
9+
Meilisearch's chatCompletions feature enables AI-powered conversational search, allowing users to ask questions in natural language and receive direct answers based on your indexed content. This feature transforms the traditional search experience into an interactive dialogue.
1010

1111
<Warning>
12-
The chat feature is experimental and must be enabled through [experimental features](/reference/api/experimental_features). API specifications may change in future releases.
12+
The chatCompletions feature is experimental and must be enabled through [experimental features](/reference/api/experimental_features). API specifications may change in future releases.
1313
</Warning>
1414

1515
## What is conversational search?
@@ -22,7 +22,7 @@ Conversational search allows users to:
2222

2323
This approach bridges the gap between traditional search and modern AI experiences, making information more accessible and intuitive to find.
2424

25-
## How chat differs from traditional search
25+
## How chatCompletions differs from traditional search
2626

2727
### Traditional search workflow
2828
1. User enters keywords
@@ -37,21 +37,21 @@ This approach bridges the gap between traditional search and modern AI experienc
3737

3838
## RAG implementation simplified
3939

40-
The chat feature implements a complete Retrieval Augmented Generation (RAG) pipeline in a single API endpoint. Traditional RAG implementations require:
40+
The chatCompletions feature implements a complete Retrieval Augmented Generation (RAG) pipeline in a single API endpoint. Traditional RAG implementations require:
4141

4242
- Multiple LLM calls for query optimization
4343
- Separate vector database for semantic search
4444
- Custom reranking solutions
4545
- Complex pipeline management
4646

47-
Meilisearch's chat consolidates these into one streamlined process:
47+
Meilisearch's chatCompletions consolidates these into one streamlined process:
4848

4949
1. **Query understanding**: Automatically transforms questions into optimal search parameters
5050
2. **Hybrid retrieval**: Combines keyword and semantic search for superior relevance
5151
3. **Answer generation**: Uses your chosen LLM to generate responses
5252
4. **Context management**: Maintains conversation history automatically
5353

54-
## When to use chat vs traditional search
54+
## When to use chatCompletions vs traditional search
5555

5656
### Use conversational search when:
5757
- Users need direct answers to specific questions
@@ -67,7 +67,7 @@ Meilisearch's chat consolidates these into one streamlined process:
6767

6868
## Architecture overview
6969

70-
The chat feature operates through workspaces, which are isolated configurations for different use cases or tenants. Each workspace can:
70+
The chatCompletions feature operates through workspaces, which are isolated configurations for different use cases or tenants. Each workspace can:
7171

7272
- Use different LLM providers (OpenAI, Azure OpenAI, Mistral, Gemini, vLLM)
7373
- Apply custom prompts
@@ -93,7 +93,7 @@ The chat feature operates through workspaces, which are isolated configurations
9393

9494
## Security considerations
9595

96-
The chat feature integrates with Meilisearch's existing security model:
96+
The chatCompletions feature integrates with Meilisearch's existing security model:
9797

9898
- **API key permissions**: Chat only accesses indexes visible to the provided API key
9999
- **Tenant tokens**: Support for multi-tenant applications
@@ -102,6 +102,6 @@ The chat feature integrates with Meilisearch's existing security model:
102102

103103
## Next steps
104104

105-
- [Get started with chat implementation](/guides/ai/getting_started_with_chat)
106-
- [Explore the chat API reference](/reference/api/chats)
105+
- [Get started with chatCompletions implementation](/guides/ai/getting_started_with_chat)
106+
- [Explore the chatCompletions API reference](/reference/api/chats)
107107
- [Learn about experimental features](/reference/api/experimental_features)

reference/api/chats.mdx

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ import { Warning } from '/snippets/notice_tag.mdx'
1010
The `/chats` route enables AI-powered conversational search by integrating Large Language Models (LLMs) with your Meilisearch data. This feature allows users to ask questions in natural language and receive contextual answers based on your indexed content.
1111

1212
<Warning>
13-
The chat feature is experimental and must be enabled through [experimental features](/reference/api/experimental_features). To enable it, set `"chat": true` in your experimental features configuration.
13+
The chatCompletions feature is experimental and must be enabled through [experimental features](/reference/api/experimental_features). To enable it, set `"chatCompletions": true` in your experimental features configuration.
1414
</Warning>
1515

16-
## Chat workspace object
16+
## ChatCompletions workspace object
1717

1818
```json
1919
{
@@ -25,11 +25,11 @@ The chat feature is experimental and must be enabled through [experimental featu
2525

2626
| Name | Type | Description |
2727
| :--------------- | :----- | :---------------------------------------------------------------------------------------------- |
28-
| **`workspace`** | String | Unique identifier for the chat workspace |
28+
| **`workspace`** | String | Unique identifier for the chatCompletions workspace |
2929
| **`createdAt`** | String | Creation date of the workspace, represented in [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format |
3030
| **`updatedAt`** | String | Latest update date of the workspace, represented in [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format |
3131

32-
## Chat settings object
32+
## ChatCompletions settings object
3333

3434
```json
3535
{
@@ -111,8 +111,8 @@ data: [DONE]
111111

112112
### Example
113113

114-
<Tabs>
115-
<Tab label="cURL">
114+
<Tabs.Container labels={["OpenAI", "Azure OpenAI", "Mistral", "Gemini", "vLLM"]}>
115+
<Tabs.Content label="cURL">
116116
```bash
117117
curl \
118118
-X POST 'http://localhost:7700/chats/customer-support/chat/completions' \
@@ -129,8 +129,8 @@ data: [DONE]
129129
"stream": true
130130
}'
131131
```
132-
</Tab>
133-
<Tab label="JavaScript">
132+
</Tabs.Content>
133+
<Tabs.Content label="JavaScript">
134134
```javascript
135135
const response = await fetch('http://localhost:7700/chats/customer-support/chat/completions', {
136136
method: 'POST',
@@ -161,8 +161,8 @@ data: [DONE]
161161
console.log(chunk);
162162
}
163163
```
164-
</Tab>
165-
</Tabs>
164+
</Tabs.Content>
165+
</Tabs.Container>
166166

167167
## Update chat settings
168168

@@ -195,8 +195,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
195195

196196
### Examples
197197

198-
<Tabs>
199-
<Tab label="OpenAI">
198+
<Tabs.Container labels={["OpenAI", "Azure OpenAI", "Mistral", "Gemini", "vLLM"]}>
199+
<Tabs.Content label="OpenAI">
200200
```bash
201201
curl \
202202
-X PUT 'http://localhost:7700/chats/customer-support/settings' \
@@ -209,8 +209,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
209209
"prompt": "You are a helpful customer support assistant."
210210
}'
211211
```
212-
</Tab>
213-
<Tab label="Azure OpenAI">
212+
</Tabs.Content>
213+
<Tabs.Content label="Azure OpenAI">
214214
```bash
215215
curl \
216216
-X PUT 'http://localhost:7700/chats/customer-support/settings' \
@@ -224,8 +224,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
224224
"prompt": "You are a helpful customer support assistant."
225225
}'
226226
```
227-
</Tab>
228-
<Tab label="Mistral">
227+
</Tabs.Content>
228+
<Tabs.Content label="Mistral">
229229
```bash
230230
curl \
231231
-X PUT 'http://localhost:7700/chats/customer-support/settings' \
@@ -238,8 +238,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
238238
"prompt": "You are a helpful customer support assistant."
239239
}'
240240
```
241-
</Tab>
242-
<Tab label="Gemini">
241+
</Tabs.Content>
242+
<Tabs.Content label="Gemini">
243243
```bash
244244
curl \
245245
-X PUT 'http://localhost:7700/chats/customer-support/settings' \
@@ -252,8 +252,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
252252
"prompt": "You are a helpful customer support assistant."
253253
}'
254254
```
255-
</Tab>
256-
<Tab label="vLLM">
255+
</Tabs.Content>
256+
<Tabs.Content label="vLLM">
257257
```bash
258258
curl \
259259
-X PUT 'http://localhost:7700/chats/customer-support/settings' \
@@ -266,8 +266,8 @@ Returns the updated settings object. Note that `apiKey` is write-only and will n
266266
"prompt": "You are a helpful customer support assistant."
267267
}'
268268
```
269-
</Tab>
270-
</Tabs>
269+
</Tabs.Content>
270+
</Tabs.Container>
271271

272272
## Get chat settings
273273

@@ -295,15 +295,15 @@ Returns the settings object without the `apiKey` field.
295295

296296
### Example
297297

298-
<Tabs>
299-
<Tab label="cURL">
298+
<Tabs.Container labels={["OpenAI", "Azure OpenAI", "Mistral", "Gemini", "vLLM"]}>
299+
<Tabs.Content label="cURL">
300300
```bash
301301
curl \
302302
-X GET 'http://localhost:7700/chats/customer-support/settings' \
303303
-H 'Authorization: Bearer MASTER_KEY'
304304
```
305-
</Tab>
306-
</Tabs>
305+
</Tabs.Content>
306+
</Tabs.Container>
307307

308308
## List chat workspaces
309309

@@ -329,15 +329,15 @@ List all available chat workspaces. Results can be paginated using query paramet
329329

330330
### Example
331331

332-
<Tabs>
333-
<Tab label="cURL">
332+
<Tabs.Container labels={["OpenAI", "Azure OpenAI", "Mistral", "Gemini", "vLLM"]}>
333+
<Tabs.Content label="cURL">
334334
```bash
335335
curl \
336336
-X GET 'http://localhost:7700/chats?limit=10' \
337337
-H 'Authorization: Bearer MASTER_KEY'
338338
```
339-
</Tab>
340-
</Tabs>
339+
</Tabs.Content>
340+
</Tabs.Container>
341341

342342
#### Response: `200 OK`
343343

reference/api/experimental_features.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ The experimental API route is not compatible with all experimental features. Con
2626
"containsFilter": false,
2727
"editDocumentsByFunction": false,
2828
"network": false,
29-
"chat": false
29+
"chatCompletions": false
3030
}
3131
```
3232

@@ -37,7 +37,7 @@ The experimental API route is not compatible with all experimental features. Con
3737
| **`containsFilter`** | Boolean | `true` if feature is active, `false` otherwise |
3838
| **`editDocumentsByFunction`** | Boolean | `true` if feature is active, `false` otherwise |
3939
| **`network`** | Boolean | `true` if feature is active, `false` otherwise |
40-
| **`chat`** | Boolean | `true` if feature is active, `false` otherwise |
40+
| **`chatCompletions`** | Boolean | `true` if feature is active, `false` otherwise |
4141

4242
## Get all experimental features
4343

@@ -58,7 +58,7 @@ Get a list of all experimental features that can be activated via the `/experime
5858
"containsFilter": false,
5959
"editDocumentsByFunction": false,
6060
"network": false,
61-
"chat": false
61+
"chatCompletions": false
6262
}
6363
```
6464

@@ -87,6 +87,6 @@ Setting a field to `null` leaves its value unchanged.
8787
"containsFilter": false,
8888
"editDocumentsByFunction": false,
8989
"network": false,
90-
"chat": false
90+
"chatCompletions": false
9191
}
9292
```

0 commit comments

Comments
 (0)