Skip to content

Commit

Permalink
GRPC clients version 10.11.0
Browse files Browse the repository at this point in the history
  • Loading branch information
clarifai-prod committed Dec 10, 2024
1 parent b7804c1 commit 0a6d2ee
Show file tree
Hide file tree
Showing 12 changed files with 3,097 additions and 15 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10.10.2
10.11.0
36 changes: 35 additions & 1 deletion google/api/client_pb.js
Original file line number Diff line number Diff line change
Expand Up @@ -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) {
Expand Down Expand Up @@ -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;
Expand Down Expand Up @@ -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);
}
};


Expand Down Expand Up @@ -3407,6 +3418,29 @@ proto.google.api.GoSettings.prototype.hasCommon = function() {
};


/**
* map<string, string> renamed_services = 2;
* @param {boolean=} opt_noLazyCreate Do not create the map if
* empty, instead returning `undefined`
* @return {!jspb.Map<string,string>}
*/
proto.google.api.GoSettings.prototype.getRenamedServicesMap = function(opt_noLazyCreate) {
return /** @type {!jspb.Map<string,string>} */ (
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.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -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",
Expand Down
61 changes: 61 additions & 0 deletions proto/clarifai/api/resources.proto
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down Expand Up @@ -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.
Expand Down Expand Up @@ -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
Expand Down Expand Up @@ -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"];
}


Expand All @@ -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;
}
}

Expand Down Expand Up @@ -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;
}





106 changes: 106 additions & 0 deletions proto/clarifai/api/resources_pb.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down Expand Up @@ -2706,6 +2708,7 @@ export namespace Model {
licenseType: LicenseType,
source: Model.Source,
creator: string,
versionCount: number,
}

export enum Source {
Expand Down Expand Up @@ -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;
Expand All @@ -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,
}
}

Expand Down Expand Up @@ -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;
Expand All @@ -8667,13 +8688,19 @@ export namespace AuditLogTarget {
user?: User.AsObject,
role?: Role.AsObject,
team?: Team.AsObject,
app?: App.AsObject,
module?: Module.AsObject,
moduleVersion?: ModuleVersion.AsObject,
}

export enum TargetCase {
TARGET_NOT_SET = 0,
USER = 1,
ROLE = 2,
TEAM = 3,
APP = 4,
MODULE = 5,
MODULE_VERSION = 6,
}

}
Expand Down Expand Up @@ -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<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
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<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
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,
Expand Down Expand Up @@ -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,
}
Loading

0 comments on commit 0a6d2ee

Please sign in to comment.