Skip to content

Commit ec9b5fb

Browse files
Merge pull request #189 from nvillahermosa-mdb/DOCSP-43580-byo-llm
DOCSP-43580 BYO LLM
2 parents 491a367 + 352cd5f commit ec9b5fb

File tree

6 files changed

+352
-20
lines changed

6 files changed

+352
-20
lines changed

source/code-generation.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ application code:
2929
- Supports
3030

3131
* - Query Converter
32-
- Converts SQL based relational database code to function with
33-
MongoDB. The converted code takes into consideration the mapping
32+
- Uses Generative AI to convert SQL-based relational database code to work
33+
with MongoDB. The converted code takes into consideration the mapping
3434
rules and schema transformations defined in your project.
3535
-
3636
- SQL queries

source/code-generation/query-converter.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,22 @@ Query Converter
1010
:depth: 1
1111
:class: singlecol
1212

13-
Use Query Converter to convert SQL statements, views, and stored
13+
Query Converter uses Generative AI to convert SQL statements, views, and stored
1414
procedures to MongoDB syntax. Relational Migrator considers the mapping
1515
rules and schema transformations defined in your project when converting
1616
your SQL code.
1717

18+
.. important::
19+
20+
Query Converter is disabled by default. You must :ref:`opt-in and enable the
21+
feature <rm-enable-query-converter>` to use it.
22+
1823
.. toctree::
1924
:hidden:
2025
:titlesonly:
2126

2227
AI & Data Usage </code-generation/query-converter/ai-and-data-usage-information>
28+
Set AI Provider and LLM </code-generation/query-converter/set-query-converter-llm>
2329
Enable Query Converter </code-generation/query-converter/enable-query-converter>
2430
Convert Queries </code-generation/query-converter/convert-queries>
2531
Convert Stored Procedures </code-generation/query-converter/convert-stored-procedures>

source/code-generation/query-converter/ai-and-data-usage-information.txt

Lines changed: 43 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,54 @@ AI and Data Usage Information
1010
:depth: 1
1111
:class: singlecol
1212

13-
The Query Converter feature is powered by Generative AI
14-
(Gen AI), and may give inaccurate responses. Please see our `Generative AI FAQ
13+
Query Converter is powered by Generative AI
14+
(Gen AI), and may give inaccurate responses. Please see the `Generative AI FAQ
1515
<https://dochub.mongodb.org/core/faq-ai-features>`__
1616
for more information about Gen AI in MongoDB products.
1717

1818
Third Party Providers
1919
---------------------
2020

21-
Query Converter currently uses the `Azure OpenAI Service
21+
By default, Query Converter uses the GPT-4o model with the `Azure OpenAI
22+
Service
2223
<https://azure.microsoft.com/en-us/products/ai-services/openai-service>`__
23-
hosted by Microsoft. This is subject to change in the future.
24+
hosted by Microsoft. You can :ref:`configure Relational Migrator to use a
25+
different AI provider or Large Language Model (LLM)<rm-query-converter-set-llm>`.
26+
27+
.. _rm-supported-llms:
28+
29+
Supported Providers and LLMs
30+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
31+
32+
MongoDB tests Query Converter with the following AI providers and models:
33+
34+
.. list-table::
35+
header-rows: 1
36+
37+
* - Provider
38+
- Models
39+
40+
* - `Microsoft Azure OpenAI <https://azure.microsoft.com/en-us/products/ai-services/openai-service>`__
41+
- `GPT-4o <https://platform.openai.com/docs/models#gpt-4o>`__, `GPT-4 <https://platform.openai.com/docs/models#gpt-4-turbo-and-gpt-4>`__
42+
43+
* - `OpenAI <https://platform.openai.com/docs/overview>`__
44+
- `GPT-4o <https://platform.openai.com/docs/models#gpt-4o>`__, `GPT-4 <https://platform.openai.com/docs/models#gpt-4-turbo-and-gpt-4>`__
45+
46+
* - `Amazon Bedrock <https://aws.amazon.com/bedrock/>`__
47+
- `Claude 3.5 (Sonnet) <https://docs.anthropic.com/en/api/claude-on-amazon-bedrock>`__, `Mistral Large <https://docs.mistral.ai/deployment/cloud/aws/>`__
48+
49+
* - `GCP Vertex AI <https://cloud.google.com/vertex-ai>`__
50+
- `Gemini 1.5 Pro <https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models>`__
51+
52+
* - Self-managed local/Cloud
53+
- `Llama 3.1 405B <https://www.llama.com/docs/getting_the_models>`__
54+
55+
.. note::
56+
57+
You can configure Query Converter to run models on different providers,
58+
like running Llama 3.1 on Blackrock AWS, but MongoDB provides no
59+
performance or stability guarantees for these configurations.
60+
2461

2562
How Your Data is Used
2663
---------------------
@@ -52,8 +89,7 @@ your data to be stored, you have the option to opt out:
5289
Disable Query Converter
5390
-----------------------
5491

55-
Query Converter is available in the Relational Migrator UI once you have
56-
:ref:`enabled the query converter feature <rm-enable-query-converter>`.
92+
Query Converter is only available if you :ref:`enable it <rm-enable-query-converter>`.
5793
If you no longer want to use the feature, you can ignore it and no data
58-
will be sent to generative AI models. If needed, you can hide the
94+
is sent to generative AI models. If needed, you can hide the
5995
feature by clearing all browser data for the Relational Migrator host.

source/code-generation/query-converter/enable-query-converter.txt

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ Enable Query Converter
1010
:depth: 1
1111
:class: singlecol
1212

13-
You can use the query converter to convert SQL statements, views, and
14-
stored procedures to MongoDB syntax. The query converter considers the
13+
You can use Query Converter to convert SQL statements, views, and
14+
stored procedures to MongoDB syntax. Query Converter considers the
1515
mapping rules and schema transformations defined in your project when
1616
converting your SQL code.
1717

1818
Before You Begin
1919
----------------
2020

21-
Before you can use the query converter, you must sign in to your Atlas
21+
Before you can use Query Converter, you must sign in to your Atlas
2222
account in Relational Migrator. For details, see :ref:`rm-atlas-log-in`.
2323

2424
Steps
@@ -27,7 +27,7 @@ Steps
2727
.. procedure::
2828
:style: normal
2929

30-
.. step:: Navigate to the query converter pane
30+
.. step:: Navigate to the Query Converter pane
3131

3232
From the :guilabel:`Code Generation` tab, click the
3333
:guilabel:`Query Converter` pane.
@@ -36,14 +36,12 @@ Steps
3636

3737
.. step:: (Optional) Review telemetry preferences
3838

39-
Telemetry data about the source and converted queries are
40-
temporarily stored by MongoDB to improve the query converter
41-
feature. If you do not want your data to be stored, you have
42-
the option to opt out:
39+
Telemetry data about source and converted queries is
40+
temporarily stored by MongoDB to improve Query Converter. If you don't want your data stored, you can opt out:
4341

4442
.. include:: /includes/fact-disable-query-converter.rst
4543

46-
.. step:: Enable the query converter feature
44+
.. step:: Enable Query Converter
4745

4846
Click :guilabel:`Start Using Query Converter`.
4947
The :guilabel:`Query Converter` pane is displayed.

0 commit comments

Comments
 (0)