Overview
Displays the access information for querying models in the current tenant.
Columns
field |
Type |
Is NULL |
Description |
|---|---|---|---|
| ENDPOINT_ID | int(20) | NO | Unique ID of the model access information. |
| ENDPOINT_NAME | varchar(128) | NO | The unique name for user-defined model access information. |
| AI_MODEL_NAME | varchar(128) | NO | The name of the AI model to which the access information belongs. |
| SCOPE | varchar(128) | NO | Reserved field. Default value: all. In the future, it can be used to implement model access information configuration across regions/availability zones (region/zone). |
| URL | varchar(2048) | NO | The URL for invoking the model. HTTP and HTTPS are supported. For example: https://dashscope.aliyuncs.com/compatible-mode/v1/embeddings. |
| ACCESS_KEY | varchar(2048) | NO | The API key used when calling the model. |
| PROVIDER | varchar(128) | NO | AI model vendors, such as openai, aliyun, deepseek, ollama etc. It is used for adapting the internal database API message format. If this parameter is empty, you must provide a UDF function; otherwise, an error will be returned. |
| REQUEST_MODEL_NAME | varchar(128) | YES | The user-defined model name in the request message body, for example, bge-m3-custom. |
| PARAMETERS | varchar(2048) | YES | Reserved field. Optional. It is used to configure additional parameters for the model call, such as context_window and max_output_tokens, to support batch operations. Example: {"context_window": 128000,"max_output_tokens": 8000}. |
| REQUEST_TRANSFORM_FN | varchar(64) | YES | Reserved field for constructing the request data sent to the AI model. If left empty, the system will determine the value based on the PROVIDER and the model type (embedding/rerank/completion) to send requests using the default message format. |
| RESPONSE_TRANSFORM_FN | varchar(64) | YES | Reserved field for parsing data returned by the AI model. If left empty, the system will use the PROVIDER and the model type (embedding/rerank/completion) is processed using the default response format. |
Sample query
Users can query the access information of AI models in their own tenants.
obclient [oceanbase]> SELECT * FROM oceanbase.DBA_OB_AI_MODEL_ENDPOINTS;
The query result is as follows:
+-------------+--------------------+---------------+-------+-------------------+------------------------------------------------------------------+----------+--------------------+------------+----------------------+-----------------------+
| ENDPOINT_ID | ENDPOINT_NAME | AI_MODEL_NAME | SCOPE | URL | ACCESS_KEY | PROVIDER | REQUEST_MODEL_NAME | PARAMETERS | REQUEST_TRANSFORM_FN | RESPONSE_TRANSFORM_FN |
+-------------+--------------------+---------------+-------+-------------------+------------------------------------------------------------------+----------+--------------------+------------+----------------------+-----------------------+
| 1 | my_model_endpoint1 | my_ai_model_1 | ALL | your ai model url | EAF8BD8998A38C94B9EA596257E8D05CE4B8309E7134F81A78CCB59D60C39846 | openai | text-embedding-v2 | NULL | NULL | NULL |
+-------------+--------------------+---------------+-------+-------------------+------------------------------------------------------------------+----------+--------------------+------------+----------------------+-----------------------+
1 row in set