VertexAI class internal implementation for authentication.
Package
@google-cloud/vertexaiConstructors
(constructor)(project, location, apiEndpoint, googleAuthOptions)
constructor(project: string, location: string, apiEndpoint?: string | undefined, googleAuthOptions?: GoogleAuthOptions<import("google-auth-library/build/src/auth/googleauth").JSONClient> | undefined);
Constructs a new instance of the VertexAI_Preview
class
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
apiEndpoint |
string | undefined
|
googleAuthOptions |
GoogleAuthOptions<import("google-auth-library/build/src/auth/googleauth").JSONClient> | undefined
|
Properties
apiEndpoint
readonly apiEndpoint?: string | undefined;
googleAuth
protected googleAuth: GoogleAuth;
googleAuthOptions
readonly googleAuthOptions?: GoogleAuthOptions<import("google-auth-library/build/src/auth/googleauth").JSONClient> | undefined;
location
readonly location: string;
project
readonly project: string;
token
get token(): Promise<any>;
Get access token from GoogleAuth. Throws GoogleAuthError when fails. {Promise
Methods
getGenerativeModel(modelParams)
getGenerativeModel(modelParams: ModelParams): GenerativeModel;
Parameter | |
---|---|
Name | Description |
modelParams |
ModelParams
ModelParams Parameters to specify the generative model. {GenerativeModel} Instance of the GenerativeModel class. GenerativeModel |
Returns | |
---|---|
Type | Description |
GenerativeModel |