From 0a6d2ee1651c91e688ca3b8792f80ad6d3d7027d Mon Sep 17 00:00:00 2001 From: clarifai-prod Date: Tue, 10 Dec 2024 15:31:42 +0000 Subject: [PATCH] GRPC clients version 10.11.0 --- VERSION | 2 +- google/api/client_pb.js | 36 +- package.json | 2 +- proto/clarifai/api/resources.proto | 61 + proto/clarifai/api/resources_pb.d.ts | 106 ++ proto/clarifai/api/resources_pb.js | 850 ++++++++++- proto/clarifai/api/service.proto | 102 +- proto/clarifai/api/service_grpc_pb.d.ts | 51 + proto/clarifai/api/service_grpc_pb.js | 101 ++ proto/clarifai/api/service_pb.d.ts | 182 +++ proto/clarifai/api/service_pb.js | 1517 +++++++++++++++++++- proto/clarifai/api/service_processed.proto | 102 +- 12 files changed, 3097 insertions(+), 15 deletions(-) diff --git a/VERSION b/VERSION index 38ec5db..7258702 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -10.10.2 +10.11.0 diff --git a/google/api/client_pb.js b/google/api/client_pb.js index 389e3db..e84e1a6 100644 --- a/google/api/client_pb.js +++ b/google/api/client_pb.js @@ -3288,7 +3288,8 @@ proto.google.api.GoSettings.prototype.toObject = function(opt_includeInstance) { */ proto.google.api.GoSettings.toObject = function(includeInstance, msg) { var f, obj = { - common: (f = msg.getCommon()) && proto.google.api.CommonLanguageSettings.toObject(includeInstance, f) + common: (f = msg.getCommon()) && proto.google.api.CommonLanguageSettings.toObject(includeInstance, f), + renamedServicesMap: (f = msg.getRenamedServicesMap()) ? f.toObject(includeInstance, undefined) : [] }; if (includeInstance) { @@ -3330,6 +3331,12 @@ proto.google.api.GoSettings.deserializeBinaryFromReader = function(msg, reader) reader.readMessage(value,proto.google.api.CommonLanguageSettings.deserializeBinaryFromReader); msg.setCommon(value); break; + case 2: + var value = msg.getRenamedServicesMap(); + reader.readMessage(value, function(message, reader) { + jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", ""); + }); + break; default: reader.skipField(); break; @@ -3367,6 +3374,10 @@ proto.google.api.GoSettings.serializeBinaryToWriter = function(message, writer) proto.google.api.CommonLanguageSettings.serializeBinaryToWriter ); } + f = message.getRenamedServicesMap(true); + if (f && f.getLength() > 0) { + f.serializeBinary(2, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString); + } }; @@ -3407,6 +3418,29 @@ proto.google.api.GoSettings.prototype.hasCommon = function() { }; +/** + * map renamed_services = 2; + * @param {boolean=} opt_noLazyCreate Do not create the map if + * empty, instead returning `undefined` + * @return {!jspb.Map} + */ +proto.google.api.GoSettings.prototype.getRenamedServicesMap = function(opt_noLazyCreate) { + return /** @type {!jspb.Map} */ ( + jspb.Message.getMapField(this, 2, opt_noLazyCreate, + null)); +}; + + +/** + * Clears values from the map. The map will be non-null. + * @return {!proto.google.api.GoSettings} returns this + */ +proto.google.api.GoSettings.prototype.clearRenamedServicesMap = function() { + this.getRenamedServicesMap().clear(); + return this; +}; + + /** * List of repeated fields within this message type. diff --git a/package.json b/package.json index 94e2c0e..07f52bc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "clarifai-nodejs-grpc", - "version": "10.10.2", + "version": "10.11.0", "description": "The official Clarifai Node.js gRPC client", "main": "src/index.js", "repository": "https://github.com/Clarifai/clarifai-javascript-grpc", diff --git a/proto/clarifai/api/resources.proto b/proto/clarifai/api/resources.proto index 1290ba3..3ddf476 100644 --- a/proto/clarifai/api/resources.proto +++ b/proto/clarifai/api/resources.proto @@ -1467,6 +1467,8 @@ message Model { Source source = 36; // Creator of Model string creator = 37; + + int32 version_count = 38; } // A link to a html/markdown/text file that stores reference material tied to a model. @@ -1878,6 +1880,9 @@ message ModelVersion { // number of inputs in the model version uint32 total_input_count = 6; + // When a model has already been trained externally, you can upload + // it directly to the platform as a model version directly by + // setting the PretrainedModelConfig PretrainedModelConfig pretrained_model_config = 7; // Detailed training stats. @@ -1960,6 +1965,10 @@ message PretrainedModelConfig { // version 1 folder that contains model files (onnx graph, torch script, python BE model, and etc.) string model_zip_url = 6; // Whether to overwrite the model for the existing internal id + // If this is a local dev model that runs external to the platform, set this to true. + // This helps during development of models before uploading them to the platform. + // These models MUST run in an associated compute cluster with cluster_type = "local-dev" + bool local_dev = 8; } // TrainStats @@ -4846,6 +4855,15 @@ enum EventType { ORGANIZATION_TEAM_APP_ADD = 112 [(clarifai.api.utils.description) = "Organization team applications added"]; ORGANIZATION_TEAM_APP_REMOVE = 113 [(clarifai.api.utils.description) = "Organization team applications removed"]; + + // Event types related to modules: 200 - 299 + MODULE_CREATE = 200 [(clarifai.api.utils.description) = "Modules created"]; + MODULE_UPDATE = 201 [(clarifai.api.utils.description) = "Modules updated"]; + MODULE_DELETE = 202 [(clarifai.api.utils.description) = "Modules deleted"]; + + MODULE_VERSION_CREATE = 203 [(clarifai.api.utils.description) = "Module versions created"]; + MODULE_VERSION_UPDATE = 204 [(clarifai.api.utils.description) = "Module versions updated"]; + MODULE_VERSION_DELETE = 205 [(clarifai.api.utils.description) = "Module versions deleted"]; } @@ -4856,6 +4874,9 @@ message AuditLogTarget { User user = 1; Role role = 2; Team team = 3; + App app = 4; + Module module = 5; + ModuleVersion module_version = 6; } } @@ -4926,6 +4947,46 @@ message WorkflowVersionEvaluationTemplate { } +// LogEntry is a single technical log entry (e.g. service log, stack traces, etc). +message LogEntry { + // Text of the log entry. + string message = 1; + + // The type of log entry. Examples: model, agent, build, training. + string log_type = 2; + + // URL to log file or stream. + string url = 3; + + // Deprecated metadata fields. + reserved 4, 5, 6, 7, 8; + + // Who and where the metrics are from. + ComputeSourceMetadata meta = 9; +} + +// ComputeSourceMetadata describes the source of something computed. The who and where. +message ComputeSourceMetadata { + reserved 5; + // The user app id, if any. + UserAppIDSet user_app_id = 1; + + // The Model ID, if any. + string model_id = 2; + + // The Version ID, if any. + string model_version_id = 3; + + // Workflow Id, if any. + string workflow_id = 4; + + // Compute Cluster, Nodepool, Runner. + string compute_cluster_id = 6; + string nodepool_id = 7; + string runner_id = 8; +} + + diff --git a/proto/clarifai/api/resources_pb.d.ts b/proto/clarifai/api/resources_pb.d.ts index 169e47e..e7f3e7a 100644 --- a/proto/clarifai/api/resources_pb.d.ts +++ b/proto/clarifai/api/resources_pb.d.ts @@ -2663,6 +2663,8 @@ export class Model extends jspb.Message { setSource(value: Model.Source): Model; getCreator(): string; setCreator(value: string): Model; + getVersionCount(): number; + setVersionCount(value: number): Model; serializeBinary(): Uint8Array; toObject(includeInstance?: boolean): Model.AsObject; @@ -2706,6 +2708,7 @@ export namespace Model { licenseType: LicenseType, source: Model.Source, creator: string, + versionCount: number, } export enum Source { @@ -3553,6 +3556,8 @@ export class PretrainedModelConfig extends jspb.Message { setOutputFieldsMap(value?: google_protobuf_struct_pb.Struct): PretrainedModelConfig; getModelZipUrl(): string; setModelZipUrl(value: string): PretrainedModelConfig; + getLocalDev(): boolean; + setLocalDev(value: boolean): PretrainedModelConfig; serializeBinary(): Uint8Array; toObject(includeInstance?: boolean): PretrainedModelConfig.AsObject; @@ -3569,6 +3574,7 @@ export namespace PretrainedModelConfig { inputFieldsMap?: google_protobuf_struct_pb.Struct.AsObject, outputFieldsMap?: google_protobuf_struct_pb.Struct.AsObject, modelZipUrl: string, + localDev: boolean, } } @@ -8650,6 +8656,21 @@ export class AuditLogTarget extends jspb.Message { getTeam(): Team | undefined; setTeam(value?: Team): AuditLogTarget; + hasApp(): boolean; + clearApp(): void; + getApp(): App | undefined; + setApp(value?: App): AuditLogTarget; + + hasModule(): boolean; + clearModule(): void; + getModule(): Module | undefined; + setModule(value?: Module): AuditLogTarget; + + hasModuleVersion(): boolean; + clearModuleVersion(): void; + getModuleVersion(): ModuleVersion | undefined; + setModuleVersion(value?: ModuleVersion): AuditLogTarget; + getTargetCase(): AuditLogTarget.TargetCase; serializeBinary(): Uint8Array; @@ -8667,6 +8688,9 @@ export namespace AuditLogTarget { user?: User.AsObject, role?: Role.AsObject, team?: Team.AsObject, + app?: App.AsObject, + module?: Module.AsObject, + moduleVersion?: ModuleVersion.AsObject, } export enum TargetCase { @@ -8674,6 +8698,9 @@ export namespace AuditLogTarget { USER = 1, ROLE = 2, TEAM = 3, + APP = 4, + MODULE = 5, + MODULE_VERSION = 6, } } @@ -8871,6 +8898,79 @@ export namespace WorkflowVersionEvaluationTemplate { } +export class LogEntry extends jspb.Message { + getMessage(): string; + setMessage(value: string): LogEntry; + getLogType(): string; + setLogType(value: string): LogEntry; + getUrl(): string; + setUrl(value: string): LogEntry; + + hasMeta(): boolean; + clearMeta(): void; + getMeta(): ComputeSourceMetadata | undefined; + setMeta(value?: ComputeSourceMetadata): LogEntry; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): LogEntry.AsObject; + static toObject(includeInstance: boolean, msg: LogEntry): LogEntry.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: LogEntry, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): LogEntry; + static deserializeBinaryFromReader(message: LogEntry, reader: jspb.BinaryReader): LogEntry; +} + +export namespace LogEntry { + export type AsObject = { + message: string, + logType: string, + url: string, + meta?: ComputeSourceMetadata.AsObject, + } +} + +export class ComputeSourceMetadata extends jspb.Message { + + hasUserAppId(): boolean; + clearUserAppId(): void; + getUserAppId(): UserAppIDSet | undefined; + setUserAppId(value?: UserAppIDSet): ComputeSourceMetadata; + getModelId(): string; + setModelId(value: string): ComputeSourceMetadata; + getModelVersionId(): string; + setModelVersionId(value: string): ComputeSourceMetadata; + getWorkflowId(): string; + setWorkflowId(value: string): ComputeSourceMetadata; + getComputeClusterId(): string; + setComputeClusterId(value: string): ComputeSourceMetadata; + getNodepoolId(): string; + setNodepoolId(value: string): ComputeSourceMetadata; + getRunnerId(): string; + setRunnerId(value: string): ComputeSourceMetadata; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): ComputeSourceMetadata.AsObject; + static toObject(includeInstance: boolean, msg: ComputeSourceMetadata): ComputeSourceMetadata.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: ComputeSourceMetadata, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): ComputeSourceMetadata; + static deserializeBinaryFromReader(message: ComputeSourceMetadata, reader: jspb.BinaryReader): ComputeSourceMetadata; +} + +export namespace ComputeSourceMetadata { + export type AsObject = { + userAppId?: UserAppIDSet.AsObject, + modelId: string, + modelVersionId: string, + workflowId: string, + computeClusterId: string, + nodepoolId: string, + runnerId: string, + } +} + export enum WorkflowModelUseCase { WORKFLOW_MODEL_USE_CASE_NOT_SET = 0, CLASSIFICATION = 1, @@ -9034,4 +9134,10 @@ export enum EventType { ORGANIZATION_TEAM_MEMBER_REMOVE = 111, ORGANIZATION_TEAM_APP_ADD = 112, ORGANIZATION_TEAM_APP_REMOVE = 113, + MODULE_CREATE = 200, + MODULE_UPDATE = 201, + MODULE_DELETE = 202, + MODULE_VERSION_CREATE = 203, + MODULE_VERSION_UPDATE = 204, + MODULE_VERSION_DELETE = 205, } diff --git a/proto/clarifai/api/resources_pb.js b/proto/clarifai/api/resources_pb.js index ef4a675..ace7ef2 100644 --- a/proto/clarifai/api/resources_pb.js +++ b/proto/clarifai/api/resources_pb.js @@ -84,6 +84,7 @@ goog.exportSymbol('proto.clarifai.api.CommitmentValue', null, global); goog.exportSymbol('proto.clarifai.api.CommitmentValue.CommitmentType', null, global); goog.exportSymbol('proto.clarifai.api.ComputeCluster', null, global); goog.exportSymbol('proto.clarifai.api.ComputeInfo', null, global); +goog.exportSymbol('proto.clarifai.api.ComputeSourceMetadata', null, global); goog.exportSymbol('proto.clarifai.api.Concept', null, global); goog.exportSymbol('proto.clarifai.api.ConceptCount', null, global); goog.exportSymbol('proto.clarifai.api.ConceptExtraInfo', null, global); @@ -175,6 +176,7 @@ goog.exportSymbol('proto.clarifai.api.LabelOrder', null, global); goog.exportSymbol('proto.clarifai.api.LayerShape', null, global); goog.exportSymbol('proto.clarifai.api.LicenseScope', null, global); goog.exportSymbol('proto.clarifai.api.LicenseType', null, global); +goog.exportSymbol('proto.clarifai.api.LogEntry', null, global); goog.exportSymbol('proto.clarifai.api.LossCurveEntry', null, global); goog.exportSymbol('proto.clarifai.api.Mask', null, global); goog.exportSymbol('proto.clarifai.api.MetricsSummary', null, global); @@ -4906,6 +4908,48 @@ if (goog.DEBUG && !COMPILED) { */ proto.clarifai.api.WorkflowVersionEvaluationTemplate.displayName = 'proto.clarifai.api.WorkflowVersionEvaluationTemplate'; } +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.LogEntry = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.clarifai.api.LogEntry, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.LogEntry.displayName = 'proto.clarifai.api.LogEntry'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.ComputeSourceMetadata = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.clarifai.api.ComputeSourceMetadata, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.ComputeSourceMetadata.displayName = 'proto.clarifai.api.ComputeSourceMetadata'; +} @@ -24591,7 +24635,8 @@ proto.clarifai.api.Model.toObject = function(includeInstance, msg) { image: (f = msg.getImage()) && proto.clarifai.api.Image.toObject(includeInstance, f), licenseType: jspb.Message.getFieldWithDefault(msg, 35, 0), source: jspb.Message.getFieldWithDefault(msg, 36, 0), - creator: jspb.Message.getFieldWithDefault(msg, 37, "") + creator: jspb.Message.getFieldWithDefault(msg, 37, ""), + versionCount: jspb.Message.getFieldWithDefault(msg, 38, 0) }; if (includeInstance) { @@ -24760,6 +24805,10 @@ proto.clarifai.api.Model.deserializeBinaryFromReader = function(msg, reader) { var value = /** @type {string} */ (reader.readString()); msg.setCreator(value); break; + case 38: + var value = /** @type {number} */ (reader.readInt32()); + msg.setVersionCount(value); + break; default: reader.skipField(); break; @@ -25011,6 +25060,13 @@ proto.clarifai.api.Model.serializeBinaryToWriter = function(message, writer) { f ); } + f = message.getVersionCount(); + if (f !== 0) { + writer.writeInt32( + 38, + f + ); + } }; @@ -25868,6 +25924,24 @@ proto.clarifai.api.Model.prototype.setCreator = function(value) { }; +/** + * optional int32 version_count = 38; + * @return {number} + */ +proto.clarifai.api.Model.prototype.getVersionCount = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 38, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.clarifai.api.Model} returns this + */ +proto.clarifai.api.Model.prototype.setVersionCount = function(value) { + return jspb.Message.setProto3IntField(this, 38, value); +}; + + @@ -32289,7 +32363,8 @@ proto.clarifai.api.PretrainedModelConfig.toObject = function(includeInstance, ms var f, obj = { inputFieldsMap: (f = msg.getInputFieldsMap()) && google_protobuf_struct_pb.Struct.toObject(includeInstance, f), outputFieldsMap: (f = msg.getOutputFieldsMap()) && google_protobuf_struct_pb.Struct.toObject(includeInstance, f), - modelZipUrl: jspb.Message.getFieldWithDefault(msg, 6, "") + modelZipUrl: jspb.Message.getFieldWithDefault(msg, 6, ""), + localDev: jspb.Message.getBooleanFieldWithDefault(msg, 8, false) }; if (includeInstance) { @@ -32340,6 +32415,10 @@ proto.clarifai.api.PretrainedModelConfig.deserializeBinaryFromReader = function( var value = /** @type {string} */ (reader.readString()); msg.setModelZipUrl(value); break; + case 8: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setLocalDev(value); + break; default: reader.skipField(); break; @@ -32392,6 +32471,13 @@ proto.clarifai.api.PretrainedModelConfig.serializeBinaryToWriter = function(mess f ); } + f = message.getLocalDev(); + if (f) { + writer.writeBool( + 8, + f + ); + } }; @@ -32487,6 +32573,24 @@ proto.clarifai.api.PretrainedModelConfig.prototype.setModelZipUrl = function(val }; +/** + * optional bool local_dev = 8; + * @return {boolean} + */ +proto.clarifai.api.PretrainedModelConfig.prototype.getLocalDev = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 8, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.clarifai.api.PretrainedModelConfig} returns this + */ +proto.clarifai.api.PretrainedModelConfig.prototype.setLocalDev = function(value) { + return jspb.Message.setProto3BooleanField(this, 8, value); +}; + + /** * List of repeated fields within this message type. @@ -71101,7 +71205,7 @@ proto.clarifai.api.ProcessingInfo.prototype.setProcessingId = function(value) { * @private {!Array>} * @const */ -proto.clarifai.api.AuditLogTarget.oneofGroups_ = [[1,2,3]]; +proto.clarifai.api.AuditLogTarget.oneofGroups_ = [[1,2,3,4,5,6]]; /** * @enum {number} @@ -71110,7 +71214,10 @@ proto.clarifai.api.AuditLogTarget.TargetCase = { TARGET_NOT_SET: 0, USER: 1, ROLE: 2, - TEAM: 3 + TEAM: 3, + APP: 4, + MODULE: 5, + MODULE_VERSION: 6 }; /** @@ -71153,7 +71260,10 @@ proto.clarifai.api.AuditLogTarget.toObject = function(includeInstance, msg) { var f, obj = { user: (f = msg.getUser()) && proto.clarifai.api.User.toObject(includeInstance, f), role: (f = msg.getRole()) && proto.clarifai.api.Role.toObject(includeInstance, f), - team: (f = msg.getTeam()) && proto.clarifai.api.Team.toObject(includeInstance, f) + team: (f = msg.getTeam()) && proto.clarifai.api.Team.toObject(includeInstance, f), + app: (f = msg.getApp()) && proto.clarifai.api.App.toObject(includeInstance, f), + module: (f = msg.getModule()) && proto.clarifai.api.Module.toObject(includeInstance, f), + moduleVersion: (f = msg.getModuleVersion()) && proto.clarifai.api.ModuleVersion.toObject(includeInstance, f) }; if (includeInstance) { @@ -71205,6 +71315,21 @@ proto.clarifai.api.AuditLogTarget.deserializeBinaryFromReader = function(msg, re reader.readMessage(value,proto.clarifai.api.Team.deserializeBinaryFromReader); msg.setTeam(value); break; + case 4: + var value = new proto.clarifai.api.App; + reader.readMessage(value,proto.clarifai.api.App.deserializeBinaryFromReader); + msg.setApp(value); + break; + case 5: + var value = new proto.clarifai.api.Module; + reader.readMessage(value,proto.clarifai.api.Module.deserializeBinaryFromReader); + msg.setModule(value); + break; + case 6: + var value = new proto.clarifai.api.ModuleVersion; + reader.readMessage(value,proto.clarifai.api.ModuleVersion.deserializeBinaryFromReader); + msg.setModuleVersion(value); + break; default: reader.skipField(); break; @@ -71258,6 +71383,30 @@ proto.clarifai.api.AuditLogTarget.serializeBinaryToWriter = function(message, wr proto.clarifai.api.Team.serializeBinaryToWriter ); } + f = message.getApp(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.clarifai.api.App.serializeBinaryToWriter + ); + } + f = message.getModule(); + if (f != null) { + writer.writeMessage( + 5, + f, + proto.clarifai.api.Module.serializeBinaryToWriter + ); + } + f = message.getModuleVersion(); + if (f != null) { + writer.writeMessage( + 6, + f, + proto.clarifai.api.ModuleVersion.serializeBinaryToWriter + ); + } }; @@ -71372,6 +71521,117 @@ proto.clarifai.api.AuditLogTarget.prototype.hasTeam = function() { }; +/** + * optional App app = 4; + * @return {?proto.clarifai.api.App} + */ +proto.clarifai.api.AuditLogTarget.prototype.getApp = function() { + return /** @type{?proto.clarifai.api.App} */ ( + jspb.Message.getWrapperField(this, proto.clarifai.api.App, 4)); +}; + + +/** + * @param {?proto.clarifai.api.App|undefined} value + * @return {!proto.clarifai.api.AuditLogTarget} returns this +*/ +proto.clarifai.api.AuditLogTarget.prototype.setApp = function(value) { + return jspb.Message.setOneofWrapperField(this, 4, proto.clarifai.api.AuditLogTarget.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.AuditLogTarget} returns this + */ +proto.clarifai.api.AuditLogTarget.prototype.clearApp = function() { + return this.setApp(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.AuditLogTarget.prototype.hasApp = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional Module module = 5; + * @return {?proto.clarifai.api.Module} + */ +proto.clarifai.api.AuditLogTarget.prototype.getModule = function() { + return /** @type{?proto.clarifai.api.Module} */ ( + jspb.Message.getWrapperField(this, proto.clarifai.api.Module, 5)); +}; + + +/** + * @param {?proto.clarifai.api.Module|undefined} value + * @return {!proto.clarifai.api.AuditLogTarget} returns this +*/ +proto.clarifai.api.AuditLogTarget.prototype.setModule = function(value) { + return jspb.Message.setOneofWrapperField(this, 5, proto.clarifai.api.AuditLogTarget.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.AuditLogTarget} returns this + */ +proto.clarifai.api.AuditLogTarget.prototype.clearModule = function() { + return this.setModule(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.AuditLogTarget.prototype.hasModule = function() { + return jspb.Message.getField(this, 5) != null; +}; + + +/** + * optional ModuleVersion module_version = 6; + * @return {?proto.clarifai.api.ModuleVersion} + */ +proto.clarifai.api.AuditLogTarget.prototype.getModuleVersion = function() { + return /** @type{?proto.clarifai.api.ModuleVersion} */ ( + jspb.Message.getWrapperField(this, proto.clarifai.api.ModuleVersion, 6)); +}; + + +/** + * @param {?proto.clarifai.api.ModuleVersion|undefined} value + * @return {!proto.clarifai.api.AuditLogTarget} returns this +*/ +proto.clarifai.api.AuditLogTarget.prototype.setModuleVersion = function(value) { + return jspb.Message.setOneofWrapperField(this, 6, proto.clarifai.api.AuditLogTarget.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.AuditLogTarget} returns this + */ +proto.clarifai.api.AuditLogTarget.prototype.clearModuleVersion = function() { + return this.setModuleVersion(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.AuditLogTarget.prototype.hasModuleVersion = function() { + return jspb.Message.getField(this, 6) != null; +}; + + /** * List of repeated fields within this message type. @@ -72842,6 +73102,578 @@ proto.clarifai.api.WorkflowVersionEvaluationTemplate.prototype.clearWorkflowVers }; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.LogEntry.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.LogEntry.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.LogEntry} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.LogEntry.toObject = function(includeInstance, msg) { + var f, obj = { + message: jspb.Message.getFieldWithDefault(msg, 1, ""), + logType: jspb.Message.getFieldWithDefault(msg, 2, ""), + url: jspb.Message.getFieldWithDefault(msg, 3, ""), + meta: (f = msg.getMeta()) && proto.clarifai.api.ComputeSourceMetadata.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.LogEntry} + */ +proto.clarifai.api.LogEntry.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.LogEntry; + return proto.clarifai.api.LogEntry.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.LogEntry} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.LogEntry} + */ +proto.clarifai.api.LogEntry.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setMessage(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setLogType(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setUrl(value); + break; + case 9: + var value = new proto.clarifai.api.ComputeSourceMetadata; + reader.readMessage(value,proto.clarifai.api.ComputeSourceMetadata.deserializeBinaryFromReader); + msg.setMeta(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.LogEntry.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.LogEntry.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.LogEntry} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.LogEntry.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getMessage(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getLogType(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getUrl(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } + f = message.getMeta(); + if (f != null) { + writer.writeMessage( + 9, + f, + proto.clarifai.api.ComputeSourceMetadata.serializeBinaryToWriter + ); + } +}; + + +/** + * optional string message = 1; + * @return {string} + */ +proto.clarifai.api.LogEntry.prototype.getMessage = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.LogEntry} returns this + */ +proto.clarifai.api.LogEntry.prototype.setMessage = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string log_type = 2; + * @return {string} + */ +proto.clarifai.api.LogEntry.prototype.getLogType = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.LogEntry} returns this + */ +proto.clarifai.api.LogEntry.prototype.setLogType = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional string url = 3; + * @return {string} + */ +proto.clarifai.api.LogEntry.prototype.getUrl = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.LogEntry} returns this + */ +proto.clarifai.api.LogEntry.prototype.setUrl = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + +/** + * optional ComputeSourceMetadata meta = 9; + * @return {?proto.clarifai.api.ComputeSourceMetadata} + */ +proto.clarifai.api.LogEntry.prototype.getMeta = function() { + return /** @type{?proto.clarifai.api.ComputeSourceMetadata} */ ( + jspb.Message.getWrapperField(this, proto.clarifai.api.ComputeSourceMetadata, 9)); +}; + + +/** + * @param {?proto.clarifai.api.ComputeSourceMetadata|undefined} value + * @return {!proto.clarifai.api.LogEntry} returns this +*/ +proto.clarifai.api.LogEntry.prototype.setMeta = function(value) { + return jspb.Message.setWrapperField(this, 9, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.LogEntry} returns this + */ +proto.clarifai.api.LogEntry.prototype.clearMeta = function() { + return this.setMeta(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.LogEntry.prototype.hasMeta = function() { + return jspb.Message.getField(this, 9) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.ComputeSourceMetadata.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.ComputeSourceMetadata} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ComputeSourceMetadata.toObject = function(includeInstance, msg) { + var f, obj = { + userAppId: (f = msg.getUserAppId()) && proto.clarifai.api.UserAppIDSet.toObject(includeInstance, f), + modelId: jspb.Message.getFieldWithDefault(msg, 2, ""), + modelVersionId: jspb.Message.getFieldWithDefault(msg, 3, ""), + workflowId: jspb.Message.getFieldWithDefault(msg, 4, ""), + computeClusterId: jspb.Message.getFieldWithDefault(msg, 6, ""), + nodepoolId: jspb.Message.getFieldWithDefault(msg, 7, ""), + runnerId: jspb.Message.getFieldWithDefault(msg, 8, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.ComputeSourceMetadata} + */ +proto.clarifai.api.ComputeSourceMetadata.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.ComputeSourceMetadata; + return proto.clarifai.api.ComputeSourceMetadata.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.ComputeSourceMetadata} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.ComputeSourceMetadata} + */ +proto.clarifai.api.ComputeSourceMetadata.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.clarifai.api.UserAppIDSet; + reader.readMessage(value,proto.clarifai.api.UserAppIDSet.deserializeBinaryFromReader); + msg.setUserAppId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setModelId(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setModelVersionId(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowId(value); + break; + case 6: + var value = /** @type {string} */ (reader.readString()); + msg.setComputeClusterId(value); + break; + case 7: + var value = /** @type {string} */ (reader.readString()); + msg.setNodepoolId(value); + break; + case 8: + var value = /** @type {string} */ (reader.readString()); + msg.setRunnerId(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.ComputeSourceMetadata.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.ComputeSourceMetadata} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ComputeSourceMetadata.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getUserAppId(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.clarifai.api.UserAppIDSet.serializeBinaryToWriter + ); + } + f = message.getModelId(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getModelVersionId(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } + f = message.getWorkflowId(); + if (f.length > 0) { + writer.writeString( + 4, + f + ); + } + f = message.getComputeClusterId(); + if (f.length > 0) { + writer.writeString( + 6, + f + ); + } + f = message.getNodepoolId(); + if (f.length > 0) { + writer.writeString( + 7, + f + ); + } + f = message.getRunnerId(); + if (f.length > 0) { + writer.writeString( + 8, + f + ); + } +}; + + +/** + * optional UserAppIDSet user_app_id = 1; + * @return {?proto.clarifai.api.UserAppIDSet} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getUserAppId = function() { + return /** @type{?proto.clarifai.api.UserAppIDSet} */ ( + jspb.Message.getWrapperField(this, proto.clarifai.api.UserAppIDSet, 1)); +}; + + +/** + * @param {?proto.clarifai.api.UserAppIDSet|undefined} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this +*/ +proto.clarifai.api.ComputeSourceMetadata.prototype.setUserAppId = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.clearUserAppId = function() { + return this.setUserAppId(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.hasUserAppId = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional string model_id = 2; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getModelId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setModelId = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional string model_version_id = 3; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getModelVersionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setModelVersionId = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + +/** + * optional string workflow_id = 4; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getWorkflowId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setWorkflowId = function(value) { + return jspb.Message.setProto3StringField(this, 4, value); +}; + + +/** + * optional string compute_cluster_id = 6; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getComputeClusterId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setComputeClusterId = function(value) { + return jspb.Message.setProto3StringField(this, 6, value); +}; + + +/** + * optional string nodepool_id = 7; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getNodepoolId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setNodepoolId = function(value) { + return jspb.Message.setProto3StringField(this, 7, value); +}; + + +/** + * optional string runner_id = 8; + * @return {string} + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.getRunnerId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ComputeSourceMetadata} returns this + */ +proto.clarifai.api.ComputeSourceMetadata.prototype.setRunnerId = function(value) { + return jspb.Message.setProto3StringField(this, 8, value); +}; + + /** * @enum {number} */ @@ -73064,7 +73896,13 @@ proto.clarifai.api.EventType = { ORGANIZATION_TEAM_MEMBER_ADD: 110, ORGANIZATION_TEAM_MEMBER_REMOVE: 111, ORGANIZATION_TEAM_APP_ADD: 112, - ORGANIZATION_TEAM_APP_REMOVE: 113 + ORGANIZATION_TEAM_APP_REMOVE: 113, + MODULE_CREATE: 200, + MODULE_UPDATE: 201, + MODULE_DELETE: 202, + MODULE_VERSION_CREATE: 203, + MODULE_VERSION_UPDATE: 204, + MODULE_VERSION_DELETE: 205 }; goog.object.extend(exports, proto.clarifai.api); diff --git a/proto/clarifai/api/service.proto b/proto/clarifai/api/service.proto index 9d134c7..41ff664 100644 --- a/proto/clarifai/api/service.proto +++ b/proto/clarifai/api/service.proto @@ -3749,6 +3749,22 @@ service V2 { } + // List Available Cloud Providers + rpc ListCloudProviders (ListCloudProvidersRequest) returns (MultiCloudProviderResponse) { + option (google.api.http) = { + get: "/v2/cloud_providers" + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + } + + // List Regions for given Cloud Provider + rpc ListCloudRegions (ListCloudRegionsRequest) returns (MultiCloudRegionResponse) { + option (google.api.http) = { + get: "/v2/cloud_providers/{cloud_provider.id}/regions" + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + } + // Get InstanceTypes given Cloud Provider and Region rpc ListInstanceTypes (ListInstanceTypesRequest) returns (MultiInstanceTypeResponse) { option (google.api.http) = { @@ -3974,6 +3990,28 @@ service V2 { } + rpc ListLogEntries (ListLogEntriesRequest) returns (MultiLogEntryResponse) { + option (google.api.http) = { + // Endpoint to list runner logs. + get: "/v2/users/{user_app_id.user_id}/compute_clusters/{compute_cluster_id}/nodepools/{nodepool_id}/runners/{runner_id}/{log_type}/logs" + // TODO: add convenience endpoint for /users/{user_id}/runners/{runner_id}. + // TODO: add endpoint for runner replicas. + // Endpoint to list compute cluster's agent logs. + additional_bindings { + get: "/v2/users/{user_app_id.user_id}/compute_clusters/{compute_cluster_id}/{log_type}/logs" + } + // Endpoint to list builder logs. + additional_bindings { + get: "/v2/users/{user_app_id.user_id}/apps/{user_app_id.app_id}/models/{model_id}/versions/{model_version_id}/{log_type}/logs" + } + // TODO: add endpoint for workflow. + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + + option (clarifai.auth.util.cl_depending_scopes) = LogEntries_Get; + } + + } @@ -5228,6 +5266,34 @@ message ListModelInputsRequest { +message ListLogEntriesRequest { + reserved 8; + // (optional URL parameter) The page number. Pagination is used to split the results into chunks. + // Defaults to 1. + uint32 page = 1; + // (optional URL parameter) The number of results that will be contained in each page. Defaults + // to 128. + uint32 per_page = 2; + + // The type of log entry. Examples: model, agent, build, training. + string log_type = 3; + + // Who the logs are for. + // The user app id, if a user produced the logs. + clarifai.api.UserAppIDSet user_app_id = 4; + // The Model ID, if a model produced the logs. + string model_id = 5; + // The Version ID, if a model version produced the logs. + string model_version_id = 6; + // Workflow Id, if a workflow produced the logs. + string workflow_id = 7; + + // Where the logs came from. + string compute_cluster_id = 9; + string nodepool_id = 10; + string runner_id = 11; +} + // GetKeyRequest message GetKeyRequest { clarifai.api.UserAppIDSet user_app_id = 1; @@ -5316,7 +5382,7 @@ message GetModelRequest { // ListModelsRequest message ListModelsRequest { - reserved 4; + reserved 4, 32; clarifai.api.UserAppIDSet user_app_id = 1; // (optional URL parameter) The page number. Pagination is used to split the results into chunks. // Defaults to 1. @@ -5325,7 +5391,7 @@ message ListModelsRequest { // to 128. uint32 per_page = 3; - // (optional URL parameter) List of additional fields to be included in the response. Currently supported: all, stars, outputs, presets + // (optional URL parameter) List of additional fields to be included in the response. Currently supported: all, stars, outputs, presets, counts repeated string additional_fields = 19; // Sorting options: @@ -6004,6 +6070,11 @@ message MultiOutputResponse { clarifai.api.status.Status status = 1; // For each input processed during model prediction we create one output. repeated Output outputs = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +}// MultiLogEntryResponse +message MultiLogEntryResponse { + clarifai.api.status.Status status = 1; + // Log entries. + repeated LogEntry log_entries = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; } // ListScopesRequest @@ -6846,6 +6917,12 @@ message ListTasksRequest { // (optional) task IDs to filter on repeated string ids = 9; + + // (optional) input source type to filter + TaskInputSource.TaskInputSourceType input_source_type = 10; + + // (optional) ids of input source to be filtered + repeated string input_source_ids = 11; } // Request to patch a list of tasks. @@ -7815,6 +7892,25 @@ message MultiTrainingTimeEstimateResponse { repeated google.protobuf.Duration training_time_estimates = 2; } +// List Cloud Providers +message ListCloudProvidersRequest {} + +message MultiCloudProviderResponse { + clarifai.api.status.Status status = 1; + repeated CloudProvider cloud_providers = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +} + +// List CloudProvider Regions +message ListCloudRegionsRequest { + // The cloud provider to list compute clusters for. + CloudProvider cloud_provider = 1; +} + +message MultiCloudRegionResponse { + clarifai.api.status.Status status = 1; + repeated string regions = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +} + // List InstanceTypes message ListInstanceTypesRequest { // The cloud provider to list compute clusters for. @@ -8014,3 +8110,5 @@ message MultiWorkflowEvaluationTemplateResponse { + + diff --git a/proto/clarifai/api/service_grpc_pb.d.ts b/proto/clarifai/api/service_grpc_pb.d.ts index c6ac13d..205fcb4 100644 --- a/proto/clarifai/api/service_grpc_pb.d.ts +++ b/proto/clarifai/api/service_grpc_pb.d.ts @@ -236,6 +236,8 @@ interface IV2Service extends grpc.ServiceDefinition { @@ -2226,6 +2229,24 @@ interface IV2Service_IPostModelVersionsTrainingTimeEstimate extends grpc.MethodD responseSerialize: grpc.serialize; responseDeserialize: grpc.deserialize; } +interface IV2Service_IListCloudProviders extends grpc.MethodDefinition { + path: "/clarifai.api.V2/ListCloudProviders"; + requestStream: false; + responseStream: false; + requestSerialize: grpc.serialize; + requestDeserialize: grpc.deserialize; + responseSerialize: grpc.serialize; + responseDeserialize: grpc.deserialize; +} +interface IV2Service_IListCloudRegions extends grpc.MethodDefinition { + path: "/clarifai.api.V2/ListCloudRegions"; + requestStream: false; + responseStream: false; + requestSerialize: grpc.serialize; + requestDeserialize: grpc.deserialize; + responseSerialize: grpc.serialize; + responseDeserialize: grpc.deserialize; +} interface IV2Service_IListInstanceTypes extends grpc.MethodDefinition { path: "/clarifai.api.V2/ListInstanceTypes"; requestStream: false; @@ -2379,6 +2400,15 @@ interface IV2Service_IListWorkflowEvaluationTemplates extends grpc.MethodDefinit responseSerialize: grpc.serialize; responseDeserialize: grpc.deserialize; } +interface IV2Service_IListLogEntries extends grpc.MethodDefinition { + path: "/clarifai.api.V2/ListLogEntries"; + requestStream: false; + responseStream: false; + requestSerialize: grpc.serialize; + requestDeserialize: grpc.deserialize; + responseSerialize: grpc.serialize; + responseDeserialize: grpc.deserialize; +} export const V2Service: IV2Service; @@ -2602,6 +2632,8 @@ export interface IV2Server { postRunnerItemOutputs: grpc.handleUnaryCall; processRunnerItems: grpc.handleBidiStreamingCall; postModelVersionsTrainingTimeEstimate: grpc.handleUnaryCall; + listCloudProviders: grpc.handleUnaryCall; + listCloudRegions: grpc.handleUnaryCall; listInstanceTypes: grpc.handleUnaryCall; getComputeCluster: grpc.handleUnaryCall; listComputeClusters: grpc.handleUnaryCall; @@ -2619,6 +2651,7 @@ export interface IV2Server { deleteDeployments: grpc.handleUnaryCall; postAuditLogSearches: grpc.handleUnaryCall; listWorkflowEvaluationTemplates: grpc.handleUnaryCall; + listLogEntries: grpc.handleUnaryCall; } export interface IV2Client { @@ -3278,6 +3311,12 @@ export interface IV2Client { postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; + listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; + listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; + listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; @@ -3329,6 +3368,9 @@ export interface IV2Client { listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; + listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; + listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; + listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; } export class V2Client extends grpc.Client implements IV2Client { @@ -3986,6 +4028,12 @@ export class V2Client extends grpc.Client implements IV2Client { public postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; public postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; public postModelVersionsTrainingTimeEstimate(request: proto_clarifai_api_service_pb.PostModelVersionsTrainingTimeEstimateRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiTrainingTimeEstimateResponse) => void): grpc.ClientUnaryCall; + public listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + public listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + public listCloudProviders(request: proto_clarifai_api_service_pb.ListCloudProvidersRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudProviderResponse) => void): grpc.ClientUnaryCall; + public listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; + public listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; + public listCloudRegions(request: proto_clarifai_api_service_pb.ListCloudRegionsRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiCloudRegionResponse) => void): grpc.ClientUnaryCall; public listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; public listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; public listInstanceTypes(request: proto_clarifai_api_service_pb.ListInstanceTypesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiInstanceTypeResponse) => void): grpc.ClientUnaryCall; @@ -4037,4 +4085,7 @@ export class V2Client extends grpc.Client implements IV2Client { public listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; public listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; public listWorkflowEvaluationTemplates(request: proto_clarifai_api_service_pb.ListWorkflowEvaluationTemplatesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiWorkflowEvaluationTemplateResponse) => void): grpc.ClientUnaryCall; + public listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; + public listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; + public listLogEntries(request: proto_clarifai_api_service_pb.ListLogEntriesRequest, metadata: grpc.Metadata, options: Partial, callback: (error: grpc.ServiceError | null, response: proto_clarifai_api_service_pb.MultiLogEntryResponse) => void): grpc.ClientUnaryCall; } diff --git a/proto/clarifai/api/service_grpc_pb.js b/proto/clarifai/api/service_grpc_pb.js index 3d2f098..95aa5c7 100644 --- a/proto/clarifai/api/service_grpc_pb.js +++ b/proto/clarifai/api/service_grpc_pb.js @@ -1015,6 +1015,28 @@ function deserialize_clarifai_api_ListBulkOperationsRequest(buffer_arg) { return proto_clarifai_api_service_pb.ListBulkOperationsRequest.deserializeBinary(new Uint8Array(buffer_arg)); } +function serialize_clarifai_api_ListCloudProvidersRequest(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.ListCloudProvidersRequest)) { + throw new Error('Expected argument of type clarifai.api.ListCloudProvidersRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_ListCloudProvidersRequest(buffer_arg) { + return proto_clarifai_api_service_pb.ListCloudProvidersRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_clarifai_api_ListCloudRegionsRequest(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.ListCloudRegionsRequest)) { + throw new Error('Expected argument of type clarifai.api.ListCloudRegionsRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_ListCloudRegionsRequest(buffer_arg) { + return proto_clarifai_api_service_pb.ListCloudRegionsRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + function serialize_clarifai_api_ListCollaborationsRequest(arg) { if (!(arg instanceof proto_clarifai_api_service_pb.ListCollaborationsRequest)) { throw new Error('Expected argument of type clarifai.api.ListCollaborationsRequest'); @@ -1246,6 +1268,17 @@ function deserialize_clarifai_api_ListLabelOrdersRequest(buffer_arg) { return proto_clarifai_api_service_pb.ListLabelOrdersRequest.deserializeBinary(new Uint8Array(buffer_arg)); } +function serialize_clarifai_api_ListLogEntriesRequest(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.ListLogEntriesRequest)) { + throw new Error('Expected argument of type clarifai.api.ListLogEntriesRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_ListLogEntriesRequest(buffer_arg) { + return proto_clarifai_api_service_pb.ListLogEntriesRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + function serialize_clarifai_api_ListModelConceptsRequest(arg) { if (!(arg instanceof proto_clarifai_api_service_pb.ListModelConceptsRequest)) { throw new Error('Expected argument of type clarifai.api.ListModelConceptsRequest'); @@ -1587,6 +1620,28 @@ function deserialize_clarifai_api_MultiBulkOperationsResponse(buffer_arg) { return proto_clarifai_api_service_pb.MultiBulkOperationsResponse.deserializeBinary(new Uint8Array(buffer_arg)); } +function serialize_clarifai_api_MultiCloudProviderResponse(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.MultiCloudProviderResponse)) { + throw new Error('Expected argument of type clarifai.api.MultiCloudProviderResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_MultiCloudProviderResponse(buffer_arg) { + return proto_clarifai_api_service_pb.MultiCloudProviderResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_clarifai_api_MultiCloudRegionResponse(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.MultiCloudRegionResponse)) { + throw new Error('Expected argument of type clarifai.api.MultiCloudRegionResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_MultiCloudRegionResponse(buffer_arg) { + return proto_clarifai_api_service_pb.MultiCloudRegionResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + function serialize_clarifai_api_MultiCollaborationsResponse(arg) { if (!(arg instanceof proto_clarifai_api_service_pb.MultiCollaborationsResponse)) { throw new Error('Expected argument of type clarifai.api.MultiCollaborationsResponse'); @@ -1851,6 +1906,17 @@ function deserialize_clarifai_api_MultiLabelOrderResponse(buffer_arg) { return proto_clarifai_api_service_pb.MultiLabelOrderResponse.deserializeBinary(new Uint8Array(buffer_arg)); } +function serialize_clarifai_api_MultiLogEntryResponse(arg) { + if (!(arg instanceof proto_clarifai_api_service_pb.MultiLogEntryResponse)) { + throw new Error('Expected argument of type clarifai.api.MultiLogEntryResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_clarifai_api_MultiLogEntryResponse(buffer_arg) { + return proto_clarifai_api_service_pb.MultiLogEntryResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + function serialize_clarifai_api_MultiModelCheckConsentResponse(arg) { if (!(arg instanceof proto_clarifai_api_service_pb.MultiModelCheckConsentResponse)) { throw new Error('Expected argument of type clarifai.api.MultiModelCheckConsentResponse'); @@ -6557,6 +6623,30 @@ postModelVersionsTrainingTimeEstimate: { responseSerialize: serialize_clarifai_api_MultiTrainingTimeEstimateResponse, responseDeserialize: deserialize_clarifai_api_MultiTrainingTimeEstimateResponse, }, + // List Available Cloud Providers +listCloudProviders: { + path: '/clarifai.api.V2/ListCloudProviders', + requestStream: false, + responseStream: false, + requestType: proto_clarifai_api_service_pb.ListCloudProvidersRequest, + responseType: proto_clarifai_api_service_pb.MultiCloudProviderResponse, + requestSerialize: serialize_clarifai_api_ListCloudProvidersRequest, + requestDeserialize: deserialize_clarifai_api_ListCloudProvidersRequest, + responseSerialize: serialize_clarifai_api_MultiCloudProviderResponse, + responseDeserialize: deserialize_clarifai_api_MultiCloudProviderResponse, + }, + // List Regions for given Cloud Provider +listCloudRegions: { + path: '/clarifai.api.V2/ListCloudRegions', + requestStream: false, + responseStream: false, + requestType: proto_clarifai_api_service_pb.ListCloudRegionsRequest, + responseType: proto_clarifai_api_service_pb.MultiCloudRegionResponse, + requestSerialize: serialize_clarifai_api_ListCloudRegionsRequest, + requestDeserialize: deserialize_clarifai_api_ListCloudRegionsRequest, + responseSerialize: serialize_clarifai_api_MultiCloudRegionResponse, + responseDeserialize: deserialize_clarifai_api_MultiCloudRegionResponse, + }, // Get InstanceTypes given Cloud Provider and Region listInstanceTypes: { path: '/clarifai.api.V2/ListInstanceTypes', @@ -6751,6 +6841,17 @@ deleteDeployments: { responseSerialize: serialize_clarifai_api_MultiWorkflowEvaluationTemplateResponse, responseDeserialize: deserialize_clarifai_api_MultiWorkflowEvaluationTemplateResponse, }, + listLogEntries: { + path: '/clarifai.api.V2/ListLogEntries', + requestStream: false, + responseStream: false, + requestType: proto_clarifai_api_service_pb.ListLogEntriesRequest, + responseType: proto_clarifai_api_service_pb.MultiLogEntryResponse, + requestSerialize: serialize_clarifai_api_ListLogEntriesRequest, + requestDeserialize: deserialize_clarifai_api_ListLogEntriesRequest, + responseSerialize: serialize_clarifai_api_MultiLogEntryResponse, + responseDeserialize: deserialize_clarifai_api_MultiLogEntryResponse, + }, }; exports.V2Client = grpc.makeGenericClientConstructor(V2Service); diff --git a/proto/clarifai/api/service_pb.d.ts b/proto/clarifai/api/service_pb.d.ts index 4be196a..c160d1e 100644 --- a/proto/clarifai/api/service_pb.d.ts +++ b/proto/clarifai/api/service_pb.d.ts @@ -3234,6 +3234,56 @@ export namespace ListModelInputsRequest { } } +export class ListLogEntriesRequest extends jspb.Message { + getPage(): number; + setPage(value: number): ListLogEntriesRequest; + getPerPage(): number; + setPerPage(value: number): ListLogEntriesRequest; + getLogType(): string; + setLogType(value: string): ListLogEntriesRequest; + + hasUserAppId(): boolean; + clearUserAppId(): void; + getUserAppId(): proto_clarifai_api_resources_pb.UserAppIDSet | undefined; + setUserAppId(value?: proto_clarifai_api_resources_pb.UserAppIDSet): ListLogEntriesRequest; + getModelId(): string; + setModelId(value: string): ListLogEntriesRequest; + getModelVersionId(): string; + setModelVersionId(value: string): ListLogEntriesRequest; + getWorkflowId(): string; + setWorkflowId(value: string): ListLogEntriesRequest; + getComputeClusterId(): string; + setComputeClusterId(value: string): ListLogEntriesRequest; + getNodepoolId(): string; + setNodepoolId(value: string): ListLogEntriesRequest; + getRunnerId(): string; + setRunnerId(value: string): ListLogEntriesRequest; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): ListLogEntriesRequest.AsObject; + static toObject(includeInstance: boolean, msg: ListLogEntriesRequest): ListLogEntriesRequest.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: ListLogEntriesRequest, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): ListLogEntriesRequest; + static deserializeBinaryFromReader(message: ListLogEntriesRequest, reader: jspb.BinaryReader): ListLogEntriesRequest; +} + +export namespace ListLogEntriesRequest { + export type AsObject = { + page: number, + perPage: number, + logType: string, + userAppId?: proto_clarifai_api_resources_pb.UserAppIDSet.AsObject, + modelId: string, + modelVersionId: string, + workflowId: string, + computeClusterId: string, + nodepoolId: string, + runnerId: string, + } +} + export class GetKeyRequest extends jspb.Message { hasUserAppId(): boolean; @@ -5714,6 +5764,34 @@ export namespace MultiOutputResponse { } } +export class MultiLogEntryResponse extends jspb.Message { + + hasStatus(): boolean; + clearStatus(): void; + getStatus(): proto_clarifai_api_status_status_pb.Status | undefined; + setStatus(value?: proto_clarifai_api_status_status_pb.Status): MultiLogEntryResponse; + clearLogEntriesList(): void; + getLogEntriesList(): Array; + setLogEntriesList(value: Array): MultiLogEntryResponse; + addLogEntries(value?: proto_clarifai_api_resources_pb.LogEntry, index?: number): proto_clarifai_api_resources_pb.LogEntry; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): MultiLogEntryResponse.AsObject; + static toObject(includeInstance: boolean, msg: MultiLogEntryResponse): MultiLogEntryResponse.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: MultiLogEntryResponse, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): MultiLogEntryResponse; + static deserializeBinaryFromReader(message: MultiLogEntryResponse, reader: jspb.BinaryReader): MultiLogEntryResponse; +} + +export namespace MultiLogEntryResponse { + export type AsObject = { + status?: proto_clarifai_api_status_status_pb.Status.AsObject, + logEntriesList: Array, + } +} + export class ListScopesRequest extends jspb.Message { getKeyType(): string; setKeyType(value: string): ListScopesRequest; @@ -7649,6 +7727,12 @@ export class ListTasksRequest extends jspb.Message { getIdsList(): Array; setIdsList(value: Array): ListTasksRequest; addIds(value: string, index?: number): string; + getInputSourceType(): proto_clarifai_api_resources_pb.TaskInputSource.TaskInputSourceType; + setInputSourceType(value: proto_clarifai_api_resources_pb.TaskInputSource.TaskInputSourceType): ListTasksRequest; + clearInputSourceIdsList(): void; + getInputSourceIdsList(): Array; + setInputSourceIdsList(value: Array): ListTasksRequest; + addInputSourceIds(value: string, index?: number): string; serializeBinary(): Uint8Array; toObject(includeInstance?: boolean): ListTasksRequest.AsObject; @@ -7671,6 +7755,8 @@ export namespace ListTasksRequest { includingLabelOrderTasks: boolean, additionalFieldsList: Array, idsList: Array, + inputSourceType: proto_clarifai_api_resources_pb.TaskInputSource.TaskInputSourceType, + inputSourceIdsList: Array, } } @@ -10559,6 +10645,102 @@ export namespace MultiTrainingTimeEstimateResponse { } } +export class ListCloudProvidersRequest extends jspb.Message { + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): ListCloudProvidersRequest.AsObject; + static toObject(includeInstance: boolean, msg: ListCloudProvidersRequest): ListCloudProvidersRequest.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: ListCloudProvidersRequest, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): ListCloudProvidersRequest; + static deserializeBinaryFromReader(message: ListCloudProvidersRequest, reader: jspb.BinaryReader): ListCloudProvidersRequest; +} + +export namespace ListCloudProvidersRequest { + export type AsObject = { + } +} + +export class MultiCloudProviderResponse extends jspb.Message { + + hasStatus(): boolean; + clearStatus(): void; + getStatus(): proto_clarifai_api_status_status_pb.Status | undefined; + setStatus(value?: proto_clarifai_api_status_status_pb.Status): MultiCloudProviderResponse; + clearCloudProvidersList(): void; + getCloudProvidersList(): Array; + setCloudProvidersList(value: Array): MultiCloudProviderResponse; + addCloudProviders(value?: proto_clarifai_api_resources_pb.CloudProvider, index?: number): proto_clarifai_api_resources_pb.CloudProvider; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): MultiCloudProviderResponse.AsObject; + static toObject(includeInstance: boolean, msg: MultiCloudProviderResponse): MultiCloudProviderResponse.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: MultiCloudProviderResponse, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): MultiCloudProviderResponse; + static deserializeBinaryFromReader(message: MultiCloudProviderResponse, reader: jspb.BinaryReader): MultiCloudProviderResponse; +} + +export namespace MultiCloudProviderResponse { + export type AsObject = { + status?: proto_clarifai_api_status_status_pb.Status.AsObject, + cloudProvidersList: Array, + } +} + +export class ListCloudRegionsRequest extends jspb.Message { + + hasCloudProvider(): boolean; + clearCloudProvider(): void; + getCloudProvider(): proto_clarifai_api_resources_pb.CloudProvider | undefined; + setCloudProvider(value?: proto_clarifai_api_resources_pb.CloudProvider): ListCloudRegionsRequest; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): ListCloudRegionsRequest.AsObject; + static toObject(includeInstance: boolean, msg: ListCloudRegionsRequest): ListCloudRegionsRequest.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: ListCloudRegionsRequest, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): ListCloudRegionsRequest; + static deserializeBinaryFromReader(message: ListCloudRegionsRequest, reader: jspb.BinaryReader): ListCloudRegionsRequest; +} + +export namespace ListCloudRegionsRequest { + export type AsObject = { + cloudProvider?: proto_clarifai_api_resources_pb.CloudProvider.AsObject, + } +} + +export class MultiCloudRegionResponse extends jspb.Message { + + hasStatus(): boolean; + clearStatus(): void; + getStatus(): proto_clarifai_api_status_status_pb.Status | undefined; + setStatus(value?: proto_clarifai_api_status_status_pb.Status): MultiCloudRegionResponse; + clearRegionsList(): void; + getRegionsList(): Array; + setRegionsList(value: Array): MultiCloudRegionResponse; + addRegions(value: string, index?: number): string; + + serializeBinary(): Uint8Array; + toObject(includeInstance?: boolean): MultiCloudRegionResponse.AsObject; + static toObject(includeInstance: boolean, msg: MultiCloudRegionResponse): MultiCloudRegionResponse.AsObject; + static extensions: {[key: number]: jspb.ExtensionFieldInfo}; + static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo}; + static serializeBinaryToWriter(message: MultiCloudRegionResponse, writer: jspb.BinaryWriter): void; + static deserializeBinary(bytes: Uint8Array): MultiCloudRegionResponse; + static deserializeBinaryFromReader(message: MultiCloudRegionResponse, reader: jspb.BinaryReader): MultiCloudRegionResponse; +} + +export namespace MultiCloudRegionResponse { + export type AsObject = { + status?: proto_clarifai_api_status_status_pb.Status.AsObject, + regionsList: Array, + } +} + export class ListInstanceTypesRequest extends jspb.Message { hasCloudProvider(): boolean; diff --git a/proto/clarifai/api/service_pb.js b/proto/clarifai/api/service_pb.js index 88c6e1b..c57af7e 100644 --- a/proto/clarifai/api/service_pb.js +++ b/proto/clarifai/api/service_pb.js @@ -136,6 +136,8 @@ goog.exportSymbol('proto.clarifai.api.ListAppKeysRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListAppsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListAppsRequest.SortByCase', null, global); goog.exportSymbol('proto.clarifai.api.ListBulkOperationsRequest', null, global); +goog.exportSymbol('proto.clarifai.api.ListCloudProvidersRequest', null, global); +goog.exportSymbol('proto.clarifai.api.ListCloudRegionsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListCollaborationsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListCollaboratorsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListCollectorsRequest', null, global); @@ -159,6 +161,7 @@ goog.exportSymbol('proto.clarifai.api.ListInstanceTypesRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListKeysRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListKnowledgeGraphsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListLabelOrdersRequest', null, global); +goog.exportSymbol('proto.clarifai.api.ListLogEntriesRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListModelConceptsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListModelInputsRequest', null, global); goog.exportSymbol('proto.clarifai.api.ListModelReferencesRequest', null, global); @@ -196,6 +199,8 @@ goog.exportSymbol('proto.clarifai.api.MultiAppDuplicationsResponse', null, globa goog.exportSymbol('proto.clarifai.api.MultiAppResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiAuditLogEntryResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiBulkOperationsResponse', null, global); +goog.exportSymbol('proto.clarifai.api.MultiCloudProviderResponse', null, global); +goog.exportSymbol('proto.clarifai.api.MultiCloudRegionResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiCollaborationsResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiCollaboratorsResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiCollectorResponse', null, global); @@ -220,6 +225,7 @@ goog.exportSymbol('proto.clarifai.api.MultiInstanceTypeResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiKeyResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiKnowledgeGraphResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiLabelOrderResponse', null, global); +goog.exportSymbol('proto.clarifai.api.MultiLogEntryResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiModelCheckConsentResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiModelLanguageResponse', null, global); goog.exportSymbol('proto.clarifai.api.MultiModelReferenceResponse', null, global); @@ -2509,6 +2515,27 @@ if (goog.DEBUG && !COMPILED) { */ proto.clarifai.api.ListModelInputsRequest.displayName = 'proto.clarifai.api.ListModelInputsRequest'; } +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.ListLogEntriesRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.clarifai.api.ListLogEntriesRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.ListLogEntriesRequest.displayName = 'proto.clarifai.api.ListLogEntriesRequest'; +} /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a @@ -4042,6 +4069,27 @@ if (goog.DEBUG && !COMPILED) { */ proto.clarifai.api.MultiOutputResponse.displayName = 'proto.clarifai.api.MultiOutputResponse'; } +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.MultiLogEntryResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.clarifai.api.MultiLogEntryResponse.repeatedFields_, null); +}; +goog.inherits(proto.clarifai.api.MultiLogEntryResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.MultiLogEntryResponse.displayName = 'proto.clarifai.api.MultiLogEntryResponse'; +} /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a @@ -7318,6 +7366,90 @@ if (goog.DEBUG && !COMPILED) { */ proto.clarifai.api.MultiTrainingTimeEstimateResponse.displayName = 'proto.clarifai.api.MultiTrainingTimeEstimateResponse'; } +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.ListCloudProvidersRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.clarifai.api.ListCloudProvidersRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.ListCloudProvidersRequest.displayName = 'proto.clarifai.api.ListCloudProvidersRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.MultiCloudProviderResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.clarifai.api.MultiCloudProviderResponse.repeatedFields_, null); +}; +goog.inherits(proto.clarifai.api.MultiCloudProviderResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.MultiCloudProviderResponse.displayName = 'proto.clarifai.api.MultiCloudProviderResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.ListCloudRegionsRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.clarifai.api.ListCloudRegionsRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.ListCloudRegionsRequest.displayName = 'proto.clarifai.api.ListCloudRegionsRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.clarifai.api.MultiCloudRegionResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.clarifai.api.MultiCloudRegionResponse.repeatedFields_, null); +}; +goog.inherits(proto.clarifai.api.MultiCloudRegionResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.clarifai.api.MultiCloudRegionResponse.displayName = 'proto.clarifai.api.MultiCloudRegionResponse'; +} /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a @@ -32216,6 +32348,427 @@ proto.clarifai.api.ListModelInputsRequest.prototype.setPerPage = function(value) +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.ListLogEntriesRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.ListLogEntriesRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListLogEntriesRequest.toObject = function(includeInstance, msg) { + var f, obj = { + page: jspb.Message.getFieldWithDefault(msg, 1, 0), + perPage: jspb.Message.getFieldWithDefault(msg, 2, 0), + logType: jspb.Message.getFieldWithDefault(msg, 3, ""), + userAppId: (f = msg.getUserAppId()) && proto_clarifai_api_resources_pb.UserAppIDSet.toObject(includeInstance, f), + modelId: jspb.Message.getFieldWithDefault(msg, 5, ""), + modelVersionId: jspb.Message.getFieldWithDefault(msg, 6, ""), + workflowId: jspb.Message.getFieldWithDefault(msg, 7, ""), + computeClusterId: jspb.Message.getFieldWithDefault(msg, 9, ""), + nodepoolId: jspb.Message.getFieldWithDefault(msg, 10, ""), + runnerId: jspb.Message.getFieldWithDefault(msg, 11, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.ListLogEntriesRequest} + */ +proto.clarifai.api.ListLogEntriesRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.ListLogEntriesRequest; + return proto.clarifai.api.ListLogEntriesRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.ListLogEntriesRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.ListLogEntriesRequest} + */ +proto.clarifai.api.ListLogEntriesRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint32()); + msg.setPage(value); + break; + case 2: + var value = /** @type {number} */ (reader.readUint32()); + msg.setPerPage(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setLogType(value); + break; + case 4: + var value = new proto_clarifai_api_resources_pb.UserAppIDSet; + reader.readMessage(value,proto_clarifai_api_resources_pb.UserAppIDSet.deserializeBinaryFromReader); + msg.setUserAppId(value); + break; + case 5: + var value = /** @type {string} */ (reader.readString()); + msg.setModelId(value); + break; + case 6: + var value = /** @type {string} */ (reader.readString()); + msg.setModelVersionId(value); + break; + case 7: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowId(value); + break; + case 9: + var value = /** @type {string} */ (reader.readString()); + msg.setComputeClusterId(value); + break; + case 10: + var value = /** @type {string} */ (reader.readString()); + msg.setNodepoolId(value); + break; + case 11: + var value = /** @type {string} */ (reader.readString()); + msg.setRunnerId(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.ListLogEntriesRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.ListLogEntriesRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListLogEntriesRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getPage(); + if (f !== 0) { + writer.writeUint32( + 1, + f + ); + } + f = message.getPerPage(); + if (f !== 0) { + writer.writeUint32( + 2, + f + ); + } + f = message.getLogType(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } + f = message.getUserAppId(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto_clarifai_api_resources_pb.UserAppIDSet.serializeBinaryToWriter + ); + } + f = message.getModelId(); + if (f.length > 0) { + writer.writeString( + 5, + f + ); + } + f = message.getModelVersionId(); + if (f.length > 0) { + writer.writeString( + 6, + f + ); + } + f = message.getWorkflowId(); + if (f.length > 0) { + writer.writeString( + 7, + f + ); + } + f = message.getComputeClusterId(); + if (f.length > 0) { + writer.writeString( + 9, + f + ); + } + f = message.getNodepoolId(); + if (f.length > 0) { + writer.writeString( + 10, + f + ); + } + f = message.getRunnerId(); + if (f.length > 0) { + writer.writeString( + 11, + f + ); + } +}; + + +/** + * optional uint32 page = 1; + * @return {number} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getPage = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setPage = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + +/** + * optional uint32 per_page = 2; + * @return {number} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getPerPage = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setPerPage = function(value) { + return jspb.Message.setProto3IntField(this, 2, value); +}; + + +/** + * optional string log_type = 3; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getLogType = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setLogType = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + +/** + * optional UserAppIDSet user_app_id = 4; + * @return {?proto.clarifai.api.UserAppIDSet} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getUserAppId = function() { + return /** @type{?proto.clarifai.api.UserAppIDSet} */ ( + jspb.Message.getWrapperField(this, proto_clarifai_api_resources_pb.UserAppIDSet, 4)); +}; + + +/** + * @param {?proto.clarifai.api.UserAppIDSet|undefined} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this +*/ +proto.clarifai.api.ListLogEntriesRequest.prototype.setUserAppId = function(value) { + return jspb.Message.setWrapperField(this, 4, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.clearUserAppId = function() { + return this.setUserAppId(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.hasUserAppId = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional string model_id = 5; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getModelId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setModelId = function(value) { + return jspb.Message.setProto3StringField(this, 5, value); +}; + + +/** + * optional string model_version_id = 6; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getModelVersionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setModelVersionId = function(value) { + return jspb.Message.setProto3StringField(this, 6, value); +}; + + +/** + * optional string workflow_id = 7; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getWorkflowId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setWorkflowId = function(value) { + return jspb.Message.setProto3StringField(this, 7, value); +}; + + +/** + * optional string compute_cluster_id = 9; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getComputeClusterId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setComputeClusterId = function(value) { + return jspb.Message.setProto3StringField(this, 9, value); +}; + + +/** + * optional string nodepool_id = 10; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getNodepoolId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setNodepoolId = function(value) { + return jspb.Message.setProto3StringField(this, 10, value); +}; + + +/** + * optional string runner_id = 11; + * @return {string} + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.getRunnerId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, "")); +}; + + +/** + * @param {string} value + * @return {!proto.clarifai.api.ListLogEntriesRequest} returns this + */ +proto.clarifai.api.ListLogEntriesRequest.prototype.setRunnerId = function(value) { + return jspb.Message.setProto3StringField(this, 11, value); +}; + + + + + if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. @@ -50824,6 +51377,217 @@ proto.clarifai.api.MultiOutputResponse.prototype.clearOutputsList = function() { +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.clarifai.api.MultiLogEntryResponse.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.MultiLogEntryResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.MultiLogEntryResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiLogEntryResponse.toObject = function(includeInstance, msg) { + var f, obj = { + status: (f = msg.getStatus()) && proto_clarifai_api_status_status_pb.Status.toObject(includeInstance, f), + logEntriesList: jspb.Message.toObjectList(msg.getLogEntriesList(), + proto_clarifai_api_resources_pb.LogEntry.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.MultiLogEntryResponse} + */ +proto.clarifai.api.MultiLogEntryResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.MultiLogEntryResponse; + return proto.clarifai.api.MultiLogEntryResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.MultiLogEntryResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.MultiLogEntryResponse} + */ +proto.clarifai.api.MultiLogEntryResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto_clarifai_api_status_status_pb.Status; + reader.readMessage(value,proto_clarifai_api_status_status_pb.Status.deserializeBinaryFromReader); + msg.setStatus(value); + break; + case 2: + var value = new proto_clarifai_api_resources_pb.LogEntry; + reader.readMessage(value,proto_clarifai_api_resources_pb.LogEntry.deserializeBinaryFromReader); + msg.addLogEntries(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.MultiLogEntryResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.MultiLogEntryResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiLogEntryResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getStatus(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto_clarifai_api_status_status_pb.Status.serializeBinaryToWriter + ); + } + f = message.getLogEntriesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto_clarifai_api_resources_pb.LogEntry.serializeBinaryToWriter + ); + } +}; + + +/** + * optional status.Status status = 1; + * @return {?proto.clarifai.api.status.Status} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.getStatus = function() { + return /** @type{?proto.clarifai.api.status.Status} */ ( + jspb.Message.getWrapperField(this, proto_clarifai_api_status_status_pb.Status, 1)); +}; + + +/** + * @param {?proto.clarifai.api.status.Status|undefined} value + * @return {!proto.clarifai.api.MultiLogEntryResponse} returns this +*/ +proto.clarifai.api.MultiLogEntryResponse.prototype.setStatus = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.MultiLogEntryResponse} returns this + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.clearStatus = function() { + return this.setStatus(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.hasStatus = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * repeated LogEntry log_entries = 2; + * @return {!Array} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.getLogEntriesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto_clarifai_api_resources_pb.LogEntry, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.clarifai.api.MultiLogEntryResponse} returns this +*/ +proto.clarifai.api.MultiLogEntryResponse.prototype.setLogEntriesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.clarifai.api.LogEntry=} opt_value + * @param {number=} opt_index + * @return {!proto.clarifai.api.LogEntry} + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.addLogEntries = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.clarifai.api.LogEntry, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.clarifai.api.MultiLogEntryResponse} returns this + */ +proto.clarifai.api.MultiLogEntryResponse.prototype.clearLogEntriesList = function() { + return this.setLogEntriesList([]); +}; + + + if (jspb.Message.GENERATE_TO_OBJECT) { @@ -65081,7 +65845,7 @@ proto.clarifai.api.GetTaskRequest.prototype.clearAdditionalFieldsList = function * @private {!Array} * @const */ -proto.clarifai.api.ListTasksRequest.repeatedFields_ = [4,5,8,7,9]; +proto.clarifai.api.ListTasksRequest.repeatedFields_ = [4,5,8,7,9,11]; @@ -65122,7 +65886,9 @@ proto.clarifai.api.ListTasksRequest.toObject = function(includeInstance, msg) { labelOrderIdsList: (f = jspb.Message.getRepeatedField(msg, 8)) == null ? undefined : f, includingLabelOrderTasks: jspb.Message.getBooleanFieldWithDefault(msg, 6, false), additionalFieldsList: (f = jspb.Message.getRepeatedField(msg, 7)) == null ? undefined : f, - idsList: (f = jspb.Message.getRepeatedField(msg, 9)) == null ? undefined : f + idsList: (f = jspb.Message.getRepeatedField(msg, 9)) == null ? undefined : f, + inputSourceType: jspb.Message.getFieldWithDefault(msg, 10, 0), + inputSourceIdsList: (f = jspb.Message.getRepeatedField(msg, 11)) == null ? undefined : f }; if (includeInstance) { @@ -65196,6 +65962,14 @@ proto.clarifai.api.ListTasksRequest.deserializeBinaryFromReader = function(msg, var value = /** @type {string} */ (reader.readString()); msg.addIds(value); break; + case 10: + var value = /** @type {!proto.clarifai.api.TaskInputSource.TaskInputSourceType} */ (reader.readEnum()); + msg.setInputSourceType(value); + break; + case 11: + var value = /** @type {string} */ (reader.readString()); + msg.addInputSourceIds(value); + break; default: reader.skipField(); break; @@ -65289,6 +66063,20 @@ proto.clarifai.api.ListTasksRequest.serializeBinaryToWriter = function(message, f ); } + f = message.getInputSourceType(); + if (f !== 0.0) { + writer.writeEnum( + 10, + f + ); + } + f = message.getInputSourceIdsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 11, + f + ); + } }; @@ -65568,6 +66356,61 @@ proto.clarifai.api.ListTasksRequest.prototype.clearIdsList = function() { }; +/** + * optional TaskInputSource.TaskInputSourceType input_source_type = 10; + * @return {!proto.clarifai.api.TaskInputSource.TaskInputSourceType} + */ +proto.clarifai.api.ListTasksRequest.prototype.getInputSourceType = function() { + return /** @type {!proto.clarifai.api.TaskInputSource.TaskInputSourceType} */ (jspb.Message.getFieldWithDefault(this, 10, 0)); +}; + + +/** + * @param {!proto.clarifai.api.TaskInputSource.TaskInputSourceType} value + * @return {!proto.clarifai.api.ListTasksRequest} returns this + */ +proto.clarifai.api.ListTasksRequest.prototype.setInputSourceType = function(value) { + return jspb.Message.setProto3EnumField(this, 10, value); +}; + + +/** + * repeated string input_source_ids = 11; + * @return {!Array} + */ +proto.clarifai.api.ListTasksRequest.prototype.getInputSourceIdsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 11)); +}; + + +/** + * @param {!Array} value + * @return {!proto.clarifai.api.ListTasksRequest} returns this + */ +proto.clarifai.api.ListTasksRequest.prototype.setInputSourceIdsList = function(value) { + return jspb.Message.setField(this, 11, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.clarifai.api.ListTasksRequest} returns this + */ +proto.clarifai.api.ListTasksRequest.prototype.addInputSourceIds = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 11, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.clarifai.api.ListTasksRequest} returns this + */ +proto.clarifai.api.ListTasksRequest.prototype.clearInputSourceIdsList = function() { + return this.setInputSourceIdsList([]); +}; + + /** * List of repeated fields within this message type. @@ -86989,6 +87832,676 @@ proto.clarifai.api.MultiTrainingTimeEstimateResponse.prototype.clearTrainingTime +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.ListCloudProvidersRequest.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.ListCloudProvidersRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.ListCloudProvidersRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListCloudProvidersRequest.toObject = function(includeInstance, msg) { + var f, obj = { + + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.ListCloudProvidersRequest} + */ +proto.clarifai.api.ListCloudProvidersRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.ListCloudProvidersRequest; + return proto.clarifai.api.ListCloudProvidersRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.ListCloudProvidersRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.ListCloudProvidersRequest} + */ +proto.clarifai.api.ListCloudProvidersRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.ListCloudProvidersRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.ListCloudProvidersRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.ListCloudProvidersRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListCloudProvidersRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.clarifai.api.MultiCloudProviderResponse.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.MultiCloudProviderResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.MultiCloudProviderResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiCloudProviderResponse.toObject = function(includeInstance, msg) { + var f, obj = { + status: (f = msg.getStatus()) && proto_clarifai_api_status_status_pb.Status.toObject(includeInstance, f), + cloudProvidersList: jspb.Message.toObjectList(msg.getCloudProvidersList(), + proto_clarifai_api_resources_pb.CloudProvider.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.MultiCloudProviderResponse} + */ +proto.clarifai.api.MultiCloudProviderResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.MultiCloudProviderResponse; + return proto.clarifai.api.MultiCloudProviderResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.MultiCloudProviderResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.MultiCloudProviderResponse} + */ +proto.clarifai.api.MultiCloudProviderResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto_clarifai_api_status_status_pb.Status; + reader.readMessage(value,proto_clarifai_api_status_status_pb.Status.deserializeBinaryFromReader); + msg.setStatus(value); + break; + case 2: + var value = new proto_clarifai_api_resources_pb.CloudProvider; + reader.readMessage(value,proto_clarifai_api_resources_pb.CloudProvider.deserializeBinaryFromReader); + msg.addCloudProviders(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.MultiCloudProviderResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.MultiCloudProviderResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiCloudProviderResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getStatus(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto_clarifai_api_status_status_pb.Status.serializeBinaryToWriter + ); + } + f = message.getCloudProvidersList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto_clarifai_api_resources_pb.CloudProvider.serializeBinaryToWriter + ); + } +}; + + +/** + * optional status.Status status = 1; + * @return {?proto.clarifai.api.status.Status} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.getStatus = function() { + return /** @type{?proto.clarifai.api.status.Status} */ ( + jspb.Message.getWrapperField(this, proto_clarifai_api_status_status_pb.Status, 1)); +}; + + +/** + * @param {?proto.clarifai.api.status.Status|undefined} value + * @return {!proto.clarifai.api.MultiCloudProviderResponse} returns this +*/ +proto.clarifai.api.MultiCloudProviderResponse.prototype.setStatus = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.MultiCloudProviderResponse} returns this + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.clearStatus = function() { + return this.setStatus(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.hasStatus = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * repeated CloudProvider cloud_providers = 2; + * @return {!Array} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.getCloudProvidersList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto_clarifai_api_resources_pb.CloudProvider, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.clarifai.api.MultiCloudProviderResponse} returns this +*/ +proto.clarifai.api.MultiCloudProviderResponse.prototype.setCloudProvidersList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.clarifai.api.CloudProvider=} opt_value + * @param {number=} opt_index + * @return {!proto.clarifai.api.CloudProvider} + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.addCloudProviders = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.clarifai.api.CloudProvider, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.clarifai.api.MultiCloudProviderResponse} returns this + */ +proto.clarifai.api.MultiCloudProviderResponse.prototype.clearCloudProvidersList = function() { + return this.setCloudProvidersList([]); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.ListCloudRegionsRequest.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.ListCloudRegionsRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.ListCloudRegionsRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListCloudRegionsRequest.toObject = function(includeInstance, msg) { + var f, obj = { + cloudProvider: (f = msg.getCloudProvider()) && proto_clarifai_api_resources_pb.CloudProvider.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.ListCloudRegionsRequest} + */ +proto.clarifai.api.ListCloudRegionsRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.ListCloudRegionsRequest; + return proto.clarifai.api.ListCloudRegionsRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.ListCloudRegionsRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.ListCloudRegionsRequest} + */ +proto.clarifai.api.ListCloudRegionsRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto_clarifai_api_resources_pb.CloudProvider; + reader.readMessage(value,proto_clarifai_api_resources_pb.CloudProvider.deserializeBinaryFromReader); + msg.setCloudProvider(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.ListCloudRegionsRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.ListCloudRegionsRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.ListCloudRegionsRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.ListCloudRegionsRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCloudProvider(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto_clarifai_api_resources_pb.CloudProvider.serializeBinaryToWriter + ); + } +}; + + +/** + * optional CloudProvider cloud_provider = 1; + * @return {?proto.clarifai.api.CloudProvider} + */ +proto.clarifai.api.ListCloudRegionsRequest.prototype.getCloudProvider = function() { + return /** @type{?proto.clarifai.api.CloudProvider} */ ( + jspb.Message.getWrapperField(this, proto_clarifai_api_resources_pb.CloudProvider, 1)); +}; + + +/** + * @param {?proto.clarifai.api.CloudProvider|undefined} value + * @return {!proto.clarifai.api.ListCloudRegionsRequest} returns this +*/ +proto.clarifai.api.ListCloudRegionsRequest.prototype.setCloudProvider = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.ListCloudRegionsRequest} returns this + */ +proto.clarifai.api.ListCloudRegionsRequest.prototype.clearCloudProvider = function() { + return this.setCloudProvider(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.ListCloudRegionsRequest.prototype.hasCloudProvider = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.clarifai.api.MultiCloudRegionResponse.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.toObject = function(opt_includeInstance) { + return proto.clarifai.api.MultiCloudRegionResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.clarifai.api.MultiCloudRegionResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiCloudRegionResponse.toObject = function(includeInstance, msg) { + var f, obj = { + status: (f = msg.getStatus()) && proto_clarifai_api_status_status_pb.Status.toObject(includeInstance, f), + regionsList: (f = jspb.Message.getRepeatedField(msg, 2)) == null ? undefined : f + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.clarifai.api.MultiCloudRegionResponse} + */ +proto.clarifai.api.MultiCloudRegionResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.clarifai.api.MultiCloudRegionResponse; + return proto.clarifai.api.MultiCloudRegionResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.clarifai.api.MultiCloudRegionResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.clarifai.api.MultiCloudRegionResponse} + */ +proto.clarifai.api.MultiCloudRegionResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto_clarifai_api_status_status_pb.Status; + reader.readMessage(value,proto_clarifai_api_status_status_pb.Status.deserializeBinaryFromReader); + msg.setStatus(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.addRegions(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.clarifai.api.MultiCloudRegionResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.clarifai.api.MultiCloudRegionResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.clarifai.api.MultiCloudRegionResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getStatus(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto_clarifai_api_status_status_pb.Status.serializeBinaryToWriter + ); + } + f = message.getRegionsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 2, + f + ); + } +}; + + +/** + * optional status.Status status = 1; + * @return {?proto.clarifai.api.status.Status} + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.getStatus = function() { + return /** @type{?proto.clarifai.api.status.Status} */ ( + jspb.Message.getWrapperField(this, proto_clarifai_api_status_status_pb.Status, 1)); +}; + + +/** + * @param {?proto.clarifai.api.status.Status|undefined} value + * @return {!proto.clarifai.api.MultiCloudRegionResponse} returns this +*/ +proto.clarifai.api.MultiCloudRegionResponse.prototype.setStatus = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.clarifai.api.MultiCloudRegionResponse} returns this + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.clearStatus = function() { + return this.setStatus(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.hasStatus = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * repeated string regions = 2; + * @return {!Array} + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.getRegionsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.clarifai.api.MultiCloudRegionResponse} returns this + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.setRegionsList = function(value) { + return jspb.Message.setField(this, 2, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.clarifai.api.MultiCloudRegionResponse} returns this + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.addRegions = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 2, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.clarifai.api.MultiCloudRegionResponse} returns this + */ +proto.clarifai.api.MultiCloudRegionResponse.prototype.clearRegionsList = function() { + return this.setRegionsList([]); +}; + + + + + if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. diff --git a/proto/clarifai/api/service_processed.proto b/proto/clarifai/api/service_processed.proto index 6f4cc79..c071fbf 100644 --- a/proto/clarifai/api/service_processed.proto +++ b/proto/clarifai/api/service_processed.proto @@ -3749,6 +3749,22 @@ service V2 { } + // List Available Cloud Providers + rpc ListCloudProviders (ListCloudProvidersRequest) returns (MultiCloudProviderResponse) { + option (google.api.http) = { + get: "/v2/cloud_providers" + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + } + + // List Regions for given Cloud Provider + rpc ListCloudRegions (ListCloudRegionsRequest) returns (MultiCloudRegionResponse) { + option (google.api.http) = { + get: "/v2/cloud_providers/{cloud_provider.id}/regions" + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + } + // Get InstanceTypes given Cloud Provider and Region rpc ListInstanceTypes (ListInstanceTypesRequest) returns (MultiInstanceTypeResponse) { option (google.api.http) = { @@ -3974,6 +3990,28 @@ service V2 { } + rpc ListLogEntries (ListLogEntriesRequest) returns (MultiLogEntryResponse) { + option (google.api.http) = { + // Endpoint to list runner logs. + get: "/v2/users/{user_app_id.user_id}/compute_clusters/{compute_cluster_id}/nodepools/{nodepool_id}/runners/{runner_id}/{log_type}/logs" + // TODO: add convenience endpoint for /users/{user_id}/runners/{runner_id}. + // TODO: add endpoint for runner replicas. + // Endpoint to list compute cluster's agent logs. + additional_bindings178 { + get: "/v2/users/{user_app_id.user_id}/compute_clusters/{compute_cluster_id}/{log_type}/logs" + } + // Endpoint to list builder logs. + additional_bindings179 { + get: "/v2/users/{user_app_id.user_id}/apps/{user_app_id.app_id}/models/{model_id}/versions/{model_version_id}/{log_type}/logs" + } + // TODO: add endpoint for workflow. + }; + option (clarifai.auth.util.cl_auth_type) = PATAuth; + + option (clarifai.auth.util.cl_depending_scopes) = LogEntries_Get; + } + + } @@ -5228,6 +5266,34 @@ message ListModelInputsRequest { +message ListLogEntriesRequest { + reserved 8; + // (optional URL parameter) The page number. Pagination is used to split the results into chunks. + // Defaults to 1. + uint32 page = 1; + // (optional URL parameter) The number of results that will be contained in each page. Defaults + // to 128. + uint32 per_page = 2; + + // The type of log entry. Examples: model, agent, build, training. + string log_type = 3; + + // Who the logs are for. + // The user app id, if a user produced the logs. + clarifai.api.UserAppIDSet user_app_id = 4; + // The Model ID, if a model produced the logs. + string model_id = 5; + // The Version ID, if a model version produced the logs. + string model_version_id = 6; + // Workflow Id, if a workflow produced the logs. + string workflow_id = 7; + + // Where the logs came from. + string compute_cluster_id = 9; + string nodepool_id = 10; + string runner_id = 11; +} + // GetKeyRequest message GetKeyRequest { clarifai.api.UserAppIDSet user_app_id = 1; @@ -5316,7 +5382,7 @@ message GetModelRequest { // ListModelsRequest message ListModelsRequest { - reserved 4; + reserved 4, 32; clarifai.api.UserAppIDSet user_app_id = 1; // (optional URL parameter) The page number. Pagination is used to split the results into chunks. // Defaults to 1. @@ -5325,7 +5391,7 @@ message ListModelsRequest { // to 128. uint32 per_page = 3; - // (optional URL parameter) List of additional fields to be included in the response. Currently supported: all, stars, outputs, presets + // (optional URL parameter) List of additional fields to be included in the response. Currently supported: all, stars, outputs, presets, counts repeated string additional_fields = 19; // Sorting options: @@ -6004,6 +6070,11 @@ message MultiOutputResponse { clarifai.api.status.Status status = 1; // For each input processed during model prediction we create one output. repeated Output outputs = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +}// MultiLogEntryResponse +message MultiLogEntryResponse { + clarifai.api.status.Status status = 1; + // Log entries. + repeated LogEntry log_entries = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; } // ListScopesRequest @@ -6846,6 +6917,12 @@ message ListTasksRequest { // (optional) task IDs to filter on repeated string ids = 9; + + // (optional) input source type to filter + TaskInputSource.TaskInputSourceType input_source_type = 10; + + // (optional) ids of input source to be filtered + repeated string input_source_ids = 11; } // Request to patch a list of tasks. @@ -7815,6 +7892,25 @@ message MultiTrainingTimeEstimateResponse { repeated google.protobuf.Duration training_time_estimates = 2; } +// List Cloud Providers +message ListCloudProvidersRequest {} + +message MultiCloudProviderResponse { + clarifai.api.status.Status status = 1; + repeated CloudProvider cloud_providers = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +} + +// List CloudProvider Regions +message ListCloudRegionsRequest { + // The cloud provider to list compute clusters for. + CloudProvider cloud_provider = 1; +} + +message MultiCloudRegionResponse { + clarifai.api.status.Status status = 1; + repeated string regions = 2 [(clarifai.api.utils.cl_show_if_empty) = true]; +} + // List InstanceTypes message ListInstanceTypesRequest { // The cloud provider to list compute clusters for. @@ -8014,3 +8110,5 @@ message MultiWorkflowEvaluationTemplateResponse { + +