oci-generativeaiinference 2.77.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.txt +89 -0
- package/NOTICE.txt +1 -0
- package/README.md +22 -0
- package/THIRD_PARTY_LICENSES.txt +576 -0
- package/index.d.ts +27 -0
- package/index.js +50 -0
- package/index.js.map +1 -0
- package/lib/client.d.ts +113 -0
- package/lib/client.js +376 -0
- package/lib/client.js.map +1 -0
- package/lib/model/choice.d.ts +45 -0
- package/lib/model/choice.js +60 -0
- package/lib/model/choice.js.map +1 -0
- package/lib/model/cohere-llm-inference-request.d.ts +106 -0
- package/lib/model/cohere-llm-inference-request.js +73 -0
- package/lib/model/cohere-llm-inference-request.js.map +1 -0
- package/lib/model/cohere-llm-inference-response.d.ts +43 -0
- package/lib/model/cohere-llm-inference-response.js +73 -0
- package/lib/model/cohere-llm-inference-response.js.map +1 -0
- package/lib/model/dedicated-serving-mode.d.ts +35 -0
- package/lib/model/dedicated-serving-mode.js +59 -0
- package/lib/model/dedicated-serving-mode.js.map +1 -0
- package/lib/model/embed-text-details.d.ts +61 -0
- package/lib/model/embed-text-details.js +75 -0
- package/lib/model/embed-text-details.js.map +1 -0
- package/lib/model/embed-text-result.d.ts +48 -0
- package/lib/model/embed-text-result.js +36 -0
- package/lib/model/embed-text-result.js.map +1 -0
- package/lib/model/generate-text-details.d.ts +35 -0
- package/lib/model/generate-text-details.js +68 -0
- package/lib/model/generate-text-details.js.map +1 -0
- package/lib/model/generate-text-result.d.ts +38 -0
- package/lib/model/generate-text-result.js +64 -0
- package/lib/model/generate-text-result.js.map +1 -0
- package/lib/model/generated-text.d.ts +55 -0
- package/lib/model/generated-text.js +68 -0
- package/lib/model/generated-text.js.map +1 -0
- package/lib/model/index.d.ts +57 -0
- package/lib/model/index.js +80 -0
- package/lib/model/index.js.map +1 -0
- package/lib/model/llama-llm-inference-request.d.ts +94 -0
- package/lib/model/llama-llm-inference-request.js +61 -0
- package/lib/model/llama-llm-inference-request.js.map +1 -0
- package/lib/model/llama-llm-inference-response.d.ts +39 -0
- package/lib/model/llama-llm-inference-response.js +73 -0
- package/lib/model/llama-llm-inference-response.js.map +1 -0
- package/lib/model/llm-inference-request.d.ts +29 -0
- package/lib/model/llm-inference-request.js +79 -0
- package/lib/model/llm-inference-request.js.map +1 -0
- package/lib/model/llm-inference-response.d.ts +29 -0
- package/lib/model/llm-inference-response.js +79 -0
- package/lib/model/llm-inference-response.js.map +1 -0
- package/lib/model/logprobs.d.ts +46 -0
- package/lib/model/logprobs.js +36 -0
- package/lib/model/logprobs.js.map +1 -0
- package/lib/model/on-demand-serving-mode.d.ts +35 -0
- package/lib/model/on-demand-serving-mode.js +59 -0
- package/lib/model/on-demand-serving-mode.js.map +1 -0
- package/lib/model/serving-mode.d.ts +29 -0
- package/lib/model/serving-mode.js +79 -0
- package/lib/model/serving-mode.js.map +1 -0
- package/lib/model/summarize-text-details.d.ts +82 -0
- package/lib/model/summarize-text-details.js +82 -0
- package/lib/model/summarize-text-details.js.map +1 -0
- package/lib/model/summarize-text-result.d.ts +48 -0
- package/lib/model/summarize-text-result.js +36 -0
- package/lib/model/summarize-text-result.js.map +1 -0
- package/lib/model/token-likelihood.d.ts +39 -0
- package/lib/model/token-likelihood.js +36 -0
- package/lib/model/token-likelihood.js.map +1 -0
- package/lib/request/embed-text-request.d.ts +36 -0
- package/lib/request/embed-text-request.js +15 -0
- package/lib/request/embed-text-request.js.map +1 -0
- package/lib/request/generate-text-request.d.ts +36 -0
- package/lib/request/generate-text-request.js +15 -0
- package/lib/request/generate-text-request.js.map +1 -0
- package/lib/request/index.d.ts +25 -0
- package/lib/request/index.js +22 -0
- package/lib/request/index.js.map +1 -0
- package/lib/request/summarize-text-request.d.ts +36 -0
- package/lib/request/summarize-text-request.js +15 -0
- package/lib/request/summarize-text-request.js.map +1 -0
- package/lib/response/embed-text-response.d.ts +30 -0
- package/lib/response/embed-text-response.js +15 -0
- package/lib/response/embed-text-response.js.map +1 -0
- package/lib/response/generate-text-response.d.ts +30 -0
- package/lib/response/generate-text-response.js +15 -0
- package/lib/response/generate-text-response.js.map +1 -0
- package/lib/response/index.d.ts +25 -0
- package/lib/response/index.js +22 -0
- package/lib/response/index.js.map +1 -0
- package/lib/response/summarize-text-response.d.ts +30 -0
- package/lib/response/summarize-text-response.js +15 -0
- package/lib/response/summarize-text-response.js.map +1 -0
- package/package.json +29 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generative AI Service Inference API
|
|
3
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
4
|
+
|
|
5
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
6
|
+
|
|
7
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
8
|
+
|
|
9
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
10
|
+
|
|
11
|
+
* OpenAPI spec version: 20231130
|
|
12
|
+
*
|
|
13
|
+
*
|
|
14
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
15
|
+
* Do not edit the class manually.
|
|
16
|
+
*
|
|
17
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
18
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
19
|
+
*/
|
|
20
|
+
import * as model from "../model";
|
|
21
|
+
/**
|
|
22
|
+
* The model's serving mode is on-demand serving on a shared infrastructure.
|
|
23
|
+
*/
|
|
24
|
+
export interface OnDemandServingMode extends model.ServingMode {
|
|
25
|
+
/**
|
|
26
|
+
* The unique ID of a model to use. Can use list Models API to list available models.
|
|
27
|
+
*/
|
|
28
|
+
"modelId": string;
|
|
29
|
+
"servingType": string;
|
|
30
|
+
}
|
|
31
|
+
export declare namespace OnDemandServingMode {
|
|
32
|
+
function getJsonObj(obj: OnDemandServingMode, isParentJsonObj?: boolean): object;
|
|
33
|
+
const servingType = "ON_DEMAND";
|
|
34
|
+
function getDeserializedJsonObj(obj: OnDemandServingMode, isParentJsonObj?: boolean): object;
|
|
35
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Generative AI Service Inference API
|
|
4
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
5
|
+
|
|
6
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
7
|
+
|
|
8
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
9
|
+
|
|
10
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
11
|
+
|
|
12
|
+
* OpenAPI spec version: 20231130
|
|
13
|
+
*
|
|
14
|
+
*
|
|
15
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
16
|
+
* Do not edit the class manually.
|
|
17
|
+
*
|
|
18
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
19
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
20
|
+
*/
|
|
21
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
22
|
+
if (k2 === undefined) k2 = k;
|
|
23
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
24
|
+
}) : (function(o, m, k, k2) {
|
|
25
|
+
if (k2 === undefined) k2 = k;
|
|
26
|
+
o[k2] = m[k];
|
|
27
|
+
}));
|
|
28
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
29
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
30
|
+
}) : function(o, v) {
|
|
31
|
+
o["default"] = v;
|
|
32
|
+
});
|
|
33
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
34
|
+
if (mod && mod.__esModule) return mod;
|
|
35
|
+
var result = {};
|
|
36
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
37
|
+
__setModuleDefault(result, mod);
|
|
38
|
+
return result;
|
|
39
|
+
};
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.OnDemandServingMode = void 0;
|
|
42
|
+
const model = __importStar(require("../model"));
|
|
43
|
+
var OnDemandServingMode;
|
|
44
|
+
(function (OnDemandServingMode) {
|
|
45
|
+
function getJsonObj(obj, isParentJsonObj) {
|
|
46
|
+
const jsonObj = Object.assign(Object.assign({}, (isParentJsonObj ? obj : model.ServingMode.getJsonObj(obj))), {});
|
|
47
|
+
return jsonObj;
|
|
48
|
+
}
|
|
49
|
+
OnDemandServingMode.getJsonObj = getJsonObj;
|
|
50
|
+
OnDemandServingMode.servingType = "ON_DEMAND";
|
|
51
|
+
function getDeserializedJsonObj(obj, isParentJsonObj) {
|
|
52
|
+
const jsonObj = Object.assign(Object.assign({}, (isParentJsonObj
|
|
53
|
+
? obj
|
|
54
|
+
: model.ServingMode.getDeserializedJsonObj(obj))), {});
|
|
55
|
+
return jsonObj;
|
|
56
|
+
}
|
|
57
|
+
OnDemandServingMode.getDeserializedJsonObj = getDeserializedJsonObj;
|
|
58
|
+
})(OnDemandServingMode = exports.OnDemandServingMode || (exports.OnDemandServingMode = {}));
|
|
59
|
+
//# sourceMappingURL=on-demand-serving-mode.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"on-demand-serving-mode.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/model/on-demand-serving-mode.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;;;;;;;;;;;;;;;;;;;;AAEH,gDAAkC;AAelC,IAAiB,mBAAmB,CAuBnC;AAvBD,WAAiB,mBAAmB;IAClC,SAAgB,UAAU,CAAC,GAAwB,EAAE,eAAyB;QAC5E,MAAM,OAAO,mCACR,CAAC,eAAe,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAE,KAAK,CAAC,WAAW,CAAC,UAAU,CAAC,GAAG,CAAyB,CAAC,GACpF,EAAE,CACN,CAAC;QAEF,OAAO,OAAO,CAAC;IACjB,CAAC;IAPe,8BAAU,aAOzB,CAAA;IACY,+BAAW,GAAG,WAAW,CAAC;IACvC,SAAgB,sBAAsB,CACpC,GAAwB,EACxB,eAAyB;QAEzB,MAAM,OAAO,mCACR,CAAC,eAAe;YACjB,CAAC,CAAC,GAAG;YACL,CAAC,CAAE,KAAK,CAAC,WAAW,CAAC,sBAAsB,CAAC,GAAG,CAAyB,CAAC,GACxE,EAAE,CACN,CAAC;QAEF,OAAO,OAAO,CAAC;IACjB,CAAC;IAZe,0CAAsB,yBAYrC,CAAA;AACH,CAAC,EAvBgB,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAuBnC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generative AI Service Inference API
|
|
3
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
4
|
+
|
|
5
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
6
|
+
|
|
7
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
8
|
+
|
|
9
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
10
|
+
|
|
11
|
+
* OpenAPI spec version: 20231130
|
|
12
|
+
*
|
|
13
|
+
*
|
|
14
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
15
|
+
* Do not edit the class manually.
|
|
16
|
+
*
|
|
17
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
18
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* The model's serving mode, which could be on-demand serving or dedicated serving.
|
|
22
|
+
*/
|
|
23
|
+
export interface ServingMode {
|
|
24
|
+
"servingType": string;
|
|
25
|
+
}
|
|
26
|
+
export declare namespace ServingMode {
|
|
27
|
+
function getJsonObj(obj: ServingMode): object;
|
|
28
|
+
function getDeserializedJsonObj(obj: ServingMode): object;
|
|
29
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Generative AI Service Inference API
|
|
4
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
5
|
+
|
|
6
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
7
|
+
|
|
8
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
9
|
+
|
|
10
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
11
|
+
|
|
12
|
+
* OpenAPI spec version: 20231130
|
|
13
|
+
*
|
|
14
|
+
*
|
|
15
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
16
|
+
* Do not edit the class manually.
|
|
17
|
+
*
|
|
18
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
19
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
20
|
+
*/
|
|
21
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
22
|
+
if (k2 === undefined) k2 = k;
|
|
23
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
24
|
+
}) : (function(o, m, k, k2) {
|
|
25
|
+
if (k2 === undefined) k2 = k;
|
|
26
|
+
o[k2] = m[k];
|
|
27
|
+
}));
|
|
28
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
29
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
30
|
+
}) : function(o, v) {
|
|
31
|
+
o["default"] = v;
|
|
32
|
+
});
|
|
33
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
34
|
+
if (mod && mod.__esModule) return mod;
|
|
35
|
+
var result = {};
|
|
36
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
37
|
+
__setModuleDefault(result, mod);
|
|
38
|
+
return result;
|
|
39
|
+
};
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.ServingMode = void 0;
|
|
42
|
+
const model = __importStar(require("../model"));
|
|
43
|
+
const common = require("oci-common");
|
|
44
|
+
var ServingMode;
|
|
45
|
+
(function (ServingMode) {
|
|
46
|
+
function getJsonObj(obj) {
|
|
47
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
48
|
+
if (obj && "servingType" in obj && obj.servingType) {
|
|
49
|
+
switch (obj.servingType) {
|
|
50
|
+
case "DEDICATED":
|
|
51
|
+
return model.DedicatedServingMode.getJsonObj(jsonObj, true);
|
|
52
|
+
case "ON_DEMAND":
|
|
53
|
+
return model.OnDemandServingMode.getJsonObj(jsonObj, true);
|
|
54
|
+
default:
|
|
55
|
+
if (common.LOG.logger)
|
|
56
|
+
common.LOG.logger.info(`Unknown value for: ${obj.servingType}`);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
return jsonObj;
|
|
60
|
+
}
|
|
61
|
+
ServingMode.getJsonObj = getJsonObj;
|
|
62
|
+
function getDeserializedJsonObj(obj) {
|
|
63
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
64
|
+
if (obj && "servingType" in obj && obj.servingType) {
|
|
65
|
+
switch (obj.servingType) {
|
|
66
|
+
case "DEDICATED":
|
|
67
|
+
return model.DedicatedServingMode.getDeserializedJsonObj(jsonObj, true);
|
|
68
|
+
case "ON_DEMAND":
|
|
69
|
+
return model.OnDemandServingMode.getDeserializedJsonObj(jsonObj, true);
|
|
70
|
+
default:
|
|
71
|
+
if (common.LOG.logger)
|
|
72
|
+
common.LOG.logger.info(`Unknown value for: ${obj.servingType}`);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
return jsonObj;
|
|
76
|
+
}
|
|
77
|
+
ServingMode.getDeserializedJsonObj = getDeserializedJsonObj;
|
|
78
|
+
})(ServingMode = exports.ServingMode || (exports.ServingMode = {}));
|
|
79
|
+
//# sourceMappingURL=serving-mode.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"serving-mode.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/model/serving-mode.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;;;;;;;;;;;;;;;;;;;;AAEH,gDAAkC;AAClC,qCAAsC;AAStC,IAAiB,WAAW,CA2C3B;AA3CD,WAAiB,WAAW;IAC1B,SAAgB,UAAU,CAAC,GAAgB;QACzC,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,IAAI,GAAG,IAAI,aAAa,IAAI,GAAG,IAAI,GAAG,CAAC,WAAW,EAAE;YAClD,QAAQ,GAAG,CAAC,WAAW,EAAE;gBACvB,KAAK,WAAW;oBACd,OAAO,KAAK,CAAC,oBAAoB,CAAC,UAAU,CACL,OAAQ,EAC7C,IAAI,CACL,CAAC;gBACJ,KAAK,WAAW;oBACd,OAAO,KAAK,CAAC,mBAAmB,CAAC,UAAU,CACL,OAAQ,EAC5C,IAAI,CACL,CAAC;gBACJ;oBACE,IAAI,MAAM,CAAC,GAAG,CAAC,MAAM;wBAAE,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,sBAAsB,GAAG,CAAC,WAAW,EAAE,CAAC,CAAC;aAC1F;SACF;QACD,OAAO,OAAO,CAAC;IACjB,CAAC;IApBe,sBAAU,aAoBzB,CAAA;IACD,SAAgB,sBAAsB,CAAC,GAAgB;QACrD,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,IAAI,GAAG,IAAI,aAAa,IAAI,GAAG,IAAI,GAAG,CAAC,WAAW,EAAE;YAClD,QAAQ,GAAG,CAAC,WAAW,EAAE;gBACvB,KAAK,WAAW;oBACd,OAAO,KAAK,CAAC,oBAAoB,CAAC,sBAAsB,CACjB,OAAQ,EAC7C,IAAI,CACL,CAAC;gBACJ,KAAK,WAAW;oBACd,OAAO,KAAK,CAAC,mBAAmB,CAAC,sBAAsB,CACjB,OAAQ,EAC5C,IAAI,CACL,CAAC;gBACJ;oBACE,IAAI,MAAM,CAAC,GAAG,CAAC,MAAM;wBAAE,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,sBAAsB,GAAG,CAAC,WAAW,EAAE,CAAC,CAAC;aAC1F;SACF;QACD,OAAO,OAAO,CAAC;IACjB,CAAC;IApBe,kCAAsB,yBAoBrC,CAAA;AACH,CAAC,EA3CgB,WAAW,GAAX,mBAAW,KAAX,mBAAW,QA2C3B"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generative AI Service Inference API
|
|
3
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
4
|
+
|
|
5
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
6
|
+
|
|
7
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
8
|
+
|
|
9
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
10
|
+
|
|
11
|
+
* OpenAPI spec version: 20231130
|
|
12
|
+
*
|
|
13
|
+
*
|
|
14
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
15
|
+
* Do not edit the class manually.
|
|
16
|
+
*
|
|
17
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
18
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
19
|
+
*/
|
|
20
|
+
import * as model from "../model";
|
|
21
|
+
/**
|
|
22
|
+
* Details for the request to summarize text.
|
|
23
|
+
*/
|
|
24
|
+
export interface SummarizeTextDetails {
|
|
25
|
+
/**
|
|
26
|
+
* The input string to be summarized.
|
|
27
|
+
*/
|
|
28
|
+
"input": string;
|
|
29
|
+
"servingMode": model.DedicatedServingMode | model.OnDemandServingMode;
|
|
30
|
+
/**
|
|
31
|
+
* The OCID of compartment that the user is authorized to use to call into the Generative AI service.
|
|
32
|
+
*/
|
|
33
|
+
"compartmentId": string;
|
|
34
|
+
/**
|
|
35
|
+
* Whether or not to include the original inputs in the response.
|
|
36
|
+
*/
|
|
37
|
+
"isEcho"?: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* A number that sets the randomness of the generated output. Lower temperatures mean less random generations.
|
|
40
|
+
* <p>
|
|
41
|
+
Use lower numbers for tasks with a correct answer such as question answering or summarizing. High temperatures can generate hallucinations or factually incorrect information. Start with temperatures lower than 1.0, and increase the temperature for more creative outputs, as you regenerate the prompts to refine the outputs.
|
|
42
|
+
* Note: Numbers greater than Number.MAX_SAFE_INTEGER will result in rounding issues.
|
|
43
|
+
*/
|
|
44
|
+
"temperature"?: number;
|
|
45
|
+
/**
|
|
46
|
+
* A free-form instruction for modifying how the summaries get generated. Should complete the sentence \"Generate a summary _\". For example, \"focusing on the next steps\" or \"written by Yoda\".
|
|
47
|
+
*/
|
|
48
|
+
"additionalCommand"?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Indicates the approximate length of the summary. If \"AUTO\" is selected, the best option will be picked based on the input text.
|
|
51
|
+
*/
|
|
52
|
+
"length"?: SummarizeTextDetails.Length;
|
|
53
|
+
/**
|
|
54
|
+
* Indicates the style in which the summary will be delivered - in a free form paragraph or in bullet points. If \"AUTO\" is selected, the best option will be picked based on the input text.
|
|
55
|
+
*/
|
|
56
|
+
"format"?: SummarizeTextDetails.Format;
|
|
57
|
+
/**
|
|
58
|
+
* Controls how close to the original text the summary is. High extractiveness summaries will lean towards reusing sentences verbatim, while low extractiveness summaries will tend to paraphrase more.
|
|
59
|
+
*/
|
|
60
|
+
"extractiveness"?: SummarizeTextDetails.Extractiveness;
|
|
61
|
+
}
|
|
62
|
+
export declare namespace SummarizeTextDetails {
|
|
63
|
+
enum Length {
|
|
64
|
+
Short = "SHORT",
|
|
65
|
+
Medium = "MEDIUM",
|
|
66
|
+
Long = "LONG",
|
|
67
|
+
Auto = "AUTO"
|
|
68
|
+
}
|
|
69
|
+
enum Format {
|
|
70
|
+
Paragraph = "PARAGRAPH",
|
|
71
|
+
Bullets = "BULLETS",
|
|
72
|
+
Auto = "AUTO"
|
|
73
|
+
}
|
|
74
|
+
enum Extractiveness {
|
|
75
|
+
Low = "LOW",
|
|
76
|
+
Medium = "MEDIUM",
|
|
77
|
+
High = "HIGH",
|
|
78
|
+
Auto = "AUTO"
|
|
79
|
+
}
|
|
80
|
+
function getJsonObj(obj: SummarizeTextDetails): object;
|
|
81
|
+
function getDeserializedJsonObj(obj: SummarizeTextDetails): object;
|
|
82
|
+
}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Generative AI Service Inference API
|
|
4
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
5
|
+
|
|
6
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
7
|
+
|
|
8
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
9
|
+
|
|
10
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
11
|
+
|
|
12
|
+
* OpenAPI spec version: 20231130
|
|
13
|
+
*
|
|
14
|
+
*
|
|
15
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
16
|
+
* Do not edit the class manually.
|
|
17
|
+
*
|
|
18
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
19
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
20
|
+
*/
|
|
21
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
22
|
+
if (k2 === undefined) k2 = k;
|
|
23
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
24
|
+
}) : (function(o, m, k, k2) {
|
|
25
|
+
if (k2 === undefined) k2 = k;
|
|
26
|
+
o[k2] = m[k];
|
|
27
|
+
}));
|
|
28
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
29
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
30
|
+
}) : function(o, v) {
|
|
31
|
+
o["default"] = v;
|
|
32
|
+
});
|
|
33
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
34
|
+
if (mod && mod.__esModule) return mod;
|
|
35
|
+
var result = {};
|
|
36
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
37
|
+
__setModuleDefault(result, mod);
|
|
38
|
+
return result;
|
|
39
|
+
};
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.SummarizeTextDetails = void 0;
|
|
42
|
+
const model = __importStar(require("../model"));
|
|
43
|
+
var SummarizeTextDetails;
|
|
44
|
+
(function (SummarizeTextDetails) {
|
|
45
|
+
let Length;
|
|
46
|
+
(function (Length) {
|
|
47
|
+
Length["Short"] = "SHORT";
|
|
48
|
+
Length["Medium"] = "MEDIUM";
|
|
49
|
+
Length["Long"] = "LONG";
|
|
50
|
+
Length["Auto"] = "AUTO";
|
|
51
|
+
})(Length = SummarizeTextDetails.Length || (SummarizeTextDetails.Length = {}));
|
|
52
|
+
let Format;
|
|
53
|
+
(function (Format) {
|
|
54
|
+
Format["Paragraph"] = "PARAGRAPH";
|
|
55
|
+
Format["Bullets"] = "BULLETS";
|
|
56
|
+
Format["Auto"] = "AUTO";
|
|
57
|
+
})(Format = SummarizeTextDetails.Format || (SummarizeTextDetails.Format = {}));
|
|
58
|
+
let Extractiveness;
|
|
59
|
+
(function (Extractiveness) {
|
|
60
|
+
Extractiveness["Low"] = "LOW";
|
|
61
|
+
Extractiveness["Medium"] = "MEDIUM";
|
|
62
|
+
Extractiveness["High"] = "HIGH";
|
|
63
|
+
Extractiveness["Auto"] = "AUTO";
|
|
64
|
+
})(Extractiveness = SummarizeTextDetails.Extractiveness || (SummarizeTextDetails.Extractiveness = {}));
|
|
65
|
+
function getJsonObj(obj) {
|
|
66
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {
|
|
67
|
+
"servingMode": obj.servingMode ? model.ServingMode.getJsonObj(obj.servingMode) : undefined
|
|
68
|
+
});
|
|
69
|
+
return jsonObj;
|
|
70
|
+
}
|
|
71
|
+
SummarizeTextDetails.getJsonObj = getJsonObj;
|
|
72
|
+
function getDeserializedJsonObj(obj) {
|
|
73
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {
|
|
74
|
+
"servingMode": obj.servingMode
|
|
75
|
+
? model.ServingMode.getDeserializedJsonObj(obj.servingMode)
|
|
76
|
+
: undefined
|
|
77
|
+
});
|
|
78
|
+
return jsonObj;
|
|
79
|
+
}
|
|
80
|
+
SummarizeTextDetails.getDeserializedJsonObj = getDeserializedJsonObj;
|
|
81
|
+
})(SummarizeTextDetails = exports.SummarizeTextDetails || (exports.SummarizeTextDetails = {}));
|
|
82
|
+
//# sourceMappingURL=summarize-text-details.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summarize-text-details.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/model/summarize-text-details.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;;;;;;;;;;;;;;;;;;;;AAEH,gDAAkC;AA6ClC,IAAiB,oBAAoB,CA2CpC;AA3CD,WAAiB,oBAAoB;IACnC,IAAY,MAKX;IALD,WAAY,MAAM;QAChB,yBAAe,CAAA;QACf,2BAAiB,CAAA;QACjB,uBAAa,CAAA;QACb,uBAAa,CAAA;IACf,CAAC,EALW,MAAM,GAAN,2BAAM,KAAN,2BAAM,QAKjB;IAED,IAAY,MAIX;IAJD,WAAY,MAAM;QAChB,iCAAuB,CAAA;QACvB,6BAAmB,CAAA;QACnB,uBAAa,CAAA;IACf,CAAC,EAJW,MAAM,GAAN,2BAAM,KAAN,2BAAM,QAIjB;IAED,IAAY,cAKX;IALD,WAAY,cAAc;QACxB,6BAAW,CAAA;QACX,mCAAiB,CAAA;QACjB,+BAAa,CAAA;QACb,+BAAa,CAAA;IACf,CAAC,EALW,cAAc,GAAd,mCAAc,KAAd,mCAAc,QAKzB;IAED,SAAgB,UAAU,CAAC,GAAyB;QAClD,MAAM,OAAO,mCACR,GAAG,GACH;YACD,aAAa,EAAE,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC,UAAU,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS;SAC3F,CACF,CAAC;QAEF,OAAO,OAAO,CAAC;IACjB,CAAC;IATe,+BAAU,aASzB,CAAA;IACD,SAAgB,sBAAsB,CAAC,GAAyB;QAC9D,MAAM,OAAO,mCACR,GAAG,GACH;YACD,aAAa,EAAE,GAAG,CAAC,WAAW;gBAC5B,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC,sBAAsB,CAAC,GAAG,CAAC,WAAW,CAAC;gBAC3D,CAAC,CAAC,SAAS;SACd,CACF,CAAC;QAEF,OAAO,OAAO,CAAC;IACjB,CAAC;IAXe,2CAAsB,yBAWrC,CAAA;AACH,CAAC,EA3CgB,oBAAoB,GAApB,4BAAoB,KAApB,4BAAoB,QA2CpC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generative AI Service Inference API
|
|
3
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
4
|
+
|
|
5
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
6
|
+
|
|
7
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
8
|
+
|
|
9
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
10
|
+
|
|
11
|
+
* OpenAPI spec version: 20231130
|
|
12
|
+
*
|
|
13
|
+
*
|
|
14
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
15
|
+
* Do not edit the class manually.
|
|
16
|
+
*
|
|
17
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
18
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* Summarize text result to return to caller.
|
|
22
|
+
*/
|
|
23
|
+
export interface SummarizeTextResult {
|
|
24
|
+
/**
|
|
25
|
+
* A unique identifier for this SummarizeTextResult.
|
|
26
|
+
*/
|
|
27
|
+
"id": string;
|
|
28
|
+
/**
|
|
29
|
+
* The original input. Only included if \"isEcho\" set to true.
|
|
30
|
+
*/
|
|
31
|
+
"input"?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Summary result corresponding to input.
|
|
34
|
+
*/
|
|
35
|
+
"summary": string;
|
|
36
|
+
/**
|
|
37
|
+
* The OCID of the model used in this inference request.
|
|
38
|
+
*/
|
|
39
|
+
"modelId"?: string;
|
|
40
|
+
/**
|
|
41
|
+
* The version of the model.
|
|
42
|
+
*/
|
|
43
|
+
"modelVersion"?: string;
|
|
44
|
+
}
|
|
45
|
+
export declare namespace SummarizeTextResult {
|
|
46
|
+
function getJsonObj(obj: SummarizeTextResult): object;
|
|
47
|
+
function getDeserializedJsonObj(obj: SummarizeTextResult): object;
|
|
48
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Generative AI Service Inference API
|
|
4
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
5
|
+
|
|
6
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
7
|
+
|
|
8
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
9
|
+
|
|
10
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
11
|
+
|
|
12
|
+
* OpenAPI spec version: 20231130
|
|
13
|
+
*
|
|
14
|
+
*
|
|
15
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
16
|
+
* Do not edit the class manually.
|
|
17
|
+
*
|
|
18
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
19
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
20
|
+
*/
|
|
21
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
+
exports.SummarizeTextResult = void 0;
|
|
23
|
+
var SummarizeTextResult;
|
|
24
|
+
(function (SummarizeTextResult) {
|
|
25
|
+
function getJsonObj(obj) {
|
|
26
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
27
|
+
return jsonObj;
|
|
28
|
+
}
|
|
29
|
+
SummarizeTextResult.getJsonObj = getJsonObj;
|
|
30
|
+
function getDeserializedJsonObj(obj) {
|
|
31
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
32
|
+
return jsonObj;
|
|
33
|
+
}
|
|
34
|
+
SummarizeTextResult.getDeserializedJsonObj = getDeserializedJsonObj;
|
|
35
|
+
})(SummarizeTextResult = exports.SummarizeTextResult || (exports.SummarizeTextResult = {}));
|
|
36
|
+
//# sourceMappingURL=summarize-text-result.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summarize-text-result.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/model/summarize-text-result.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;AA+BH,IAAiB,mBAAmB,CAWnC;AAXD,WAAiB,mBAAmB;IAClC,SAAgB,UAAU,CAAC,GAAwB;QACjD,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,OAAO,OAAO,CAAC;IACjB,CAAC;IAJe,8BAAU,aAIzB,CAAA;IACD,SAAgB,sBAAsB,CAAC,GAAwB;QAC7D,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,OAAO,OAAO,CAAC;IACjB,CAAC;IAJe,0CAAsB,yBAIrC,CAAA;AACH,CAAC,EAXgB,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAWnC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generative AI Service Inference API
|
|
3
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
4
|
+
|
|
5
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
6
|
+
|
|
7
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
8
|
+
|
|
9
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
10
|
+
|
|
11
|
+
* OpenAPI spec version: 20231130
|
|
12
|
+
*
|
|
13
|
+
*
|
|
14
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
15
|
+
* Do not edit the class manually.
|
|
16
|
+
*
|
|
17
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
18
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* An object that contains the returned token and its corresponding likelihood.
|
|
22
|
+
*/
|
|
23
|
+
export interface TokenLikelihood {
|
|
24
|
+
/**
|
|
25
|
+
* A word, part of a word, or a punctuation.
|
|
26
|
+
* <p>
|
|
27
|
+
For example, apple is a token and friendship is made up of two tokens, friend and ship. When you run a model, you can set the maximum number of output tokens. Estimate three tokens per word.
|
|
28
|
+
*
|
|
29
|
+
*/
|
|
30
|
+
"token"?: string;
|
|
31
|
+
/**
|
|
32
|
+
* The likelihood of this token during generation. Note: Numbers greater than Number.MAX_SAFE_INTEGER will result in rounding issues.
|
|
33
|
+
*/
|
|
34
|
+
"likelihood"?: number;
|
|
35
|
+
}
|
|
36
|
+
export declare namespace TokenLikelihood {
|
|
37
|
+
function getJsonObj(obj: TokenLikelihood): object;
|
|
38
|
+
function getDeserializedJsonObj(obj: TokenLikelihood): object;
|
|
39
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Generative AI Service Inference API
|
|
4
|
+
* OCI Generative AI is a fully managed service that provides a set of state-of-the-art, customizable large language models (LLMs) that cover a wide range of use cases for text generation, summarization, and text embeddings.
|
|
5
|
+
|
|
6
|
+
Use the Generative AI service inference API to access your custom model endpoints, or to try the out-of-the-box models to [generate text](#/en/generative-ai-inference/latest/GenerateTextResult/GenerateText), [summarize](#/en/generative-ai-inference/latest/SummarizeTextResult/SummarizeText), and [create text embeddings](#/en/generative-ai-inference/latest/EmbedTextResult/EmbedText).
|
|
7
|
+
|
|
8
|
+
To use a Generative AI custom model for inference, you must first create an endpoint for that model. Use the [Generative AI service management API](/#/en/generative-ai/latest/) to [create a custom model](#/en/generative-ai/latest/Model/) by fine-tuning an out-of-the-box model, or a previous version of a custom model, using your own data. Fine-tune the custom model on a [fine-tuning dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/). Then, create a [hosting dedicated AI cluster](#/en/generative-ai/latest/DedicatedAiCluster/) with an [endpoint](#/en/generative-ai/latest/Endpoint/) to host your custom model. For resource management in the Generative AI service, use the [Generative AI service management API](/#/en/generative-ai/latest/).
|
|
9
|
+
|
|
10
|
+
To learn more about the service, see the [Generative AI documentation](/iaas/Content/generative-ai/home.htm).
|
|
11
|
+
|
|
12
|
+
* OpenAPI spec version: 20231130
|
|
13
|
+
*
|
|
14
|
+
*
|
|
15
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
16
|
+
* Do not edit the class manually.
|
|
17
|
+
*
|
|
18
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
19
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
20
|
+
*/
|
|
21
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
+
exports.TokenLikelihood = void 0;
|
|
23
|
+
var TokenLikelihood;
|
|
24
|
+
(function (TokenLikelihood) {
|
|
25
|
+
function getJsonObj(obj) {
|
|
26
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
27
|
+
return jsonObj;
|
|
28
|
+
}
|
|
29
|
+
TokenLikelihood.getJsonObj = getJsonObj;
|
|
30
|
+
function getDeserializedJsonObj(obj) {
|
|
31
|
+
const jsonObj = Object.assign(Object.assign({}, obj), {});
|
|
32
|
+
return jsonObj;
|
|
33
|
+
}
|
|
34
|
+
TokenLikelihood.getDeserializedJsonObj = getDeserializedJsonObj;
|
|
35
|
+
})(TokenLikelihood = exports.TokenLikelihood || (exports.TokenLikelihood = {}));
|
|
36
|
+
//# sourceMappingURL=token-likelihood.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token-likelihood.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/model/token-likelihood.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;AAsBH,IAAiB,eAAe,CAW/B;AAXD,WAAiB,eAAe;IAC9B,SAAgB,UAAU,CAAC,GAAoB;QAC7C,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,OAAO,OAAO,CAAC;IACjB,CAAC;IAJe,0BAAU,aAIzB,CAAA;IACD,SAAgB,sBAAsB,CAAC,GAAoB;QACzD,MAAM,OAAO,mCAAQ,GAAG,GAAK,EAAE,CAAE,CAAC;QAElC,OAAO,OAAO,CAAC;IACjB,CAAC;IAJe,sCAAsB,yBAIrC,CAAA;AACH,CAAC,EAXgB,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAW/B"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
*
|
|
4
|
+
* OpenAPI spec version: 20231130
|
|
5
|
+
*
|
|
6
|
+
*
|
|
7
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
8
|
+
* Do not edit the class manually.
|
|
9
|
+
*
|
|
10
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
11
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
12
|
+
*/
|
|
13
|
+
import * as model from "../model";
|
|
14
|
+
import common = require("oci-common");
|
|
15
|
+
/**
|
|
16
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.77.1/generativeaiinference/EmbedText.ts.html |here} to see how to use EmbedTextRequest.
|
|
17
|
+
*/
|
|
18
|
+
export interface EmbedTextRequest extends common.BaseRequest {
|
|
19
|
+
/**
|
|
20
|
+
* Details for generating the embed response.
|
|
21
|
+
*/
|
|
22
|
+
"embedTextDetails": model.EmbedTextDetails;
|
|
23
|
+
/**
|
|
24
|
+
* A token that uniquely identifies a request so it can be retried in case of a timeout or
|
|
25
|
+
* server error without risk of executing that same action again. Retry tokens expire after 24
|
|
26
|
+
* hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
|
27
|
+
* has been deleted and purged from the system, then a retry of the original creation request
|
|
28
|
+
* might be rejected.
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
"opcRetryToken"?: string;
|
|
32
|
+
/**
|
|
33
|
+
* The client request ID for tracing.
|
|
34
|
+
*/
|
|
35
|
+
"opcRequestId"?: string;
|
|
36
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
*
|
|
4
|
+
*
|
|
5
|
+
* OpenAPI spec version: 20231130
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
9
|
+
* Do not edit the class manually.
|
|
10
|
+
*
|
|
11
|
+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
|
|
12
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
//# sourceMappingURL=embed-text-request.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"embed-text-request.js","sourceRoot":"","sources":["../../../../../lib/generativeaiinference/lib/request/embed-text-request.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG"}
|