cmind/modelmanager/v1/model_deployment_service.proto
Package: cmind.modelmanager.v1
Enums
ModelSource
| Value | Number | Description |
|---|
MODEL_SOURCE_UNSPECIFIED | 0 | |
MODEL_SOURCE_HUGGINGFACE | 1 | Weights are downloaded from HuggingFace Hub at deploy time. |
MODEL_SOURCE_LOCAL_PATH | 2 | Weights are already present on the serving nodes (pre-staged) and are served from that path with no download — the air-gapped path. model_url holds the on-node directory. See CON-2389. |
ModelDeploymentStage
| Value | Number | Description |
|---|
MODEL_DEPLOYMENT_STAGE_UNSPECIFIED | 0 | |
MODEL_DEPLOYMENT_STAGE_UNDEPLOYED | 1 | |
MODEL_DEPLOYMENT_STAGE_CACHING_MODEL | 2 | |
MODEL_DEPLOYMENT_STAGE_DEPLOYING | 3 | |
MODEL_DEPLOYMENT_STAGE_DEPLOYED | 4 | |
MODEL_DEPLOYMENT_STAGE_ERROR | 5 | |
ModelDeploymentPresetKind
| Value | Number | Description |
|---|
MODEL_DEPLOYMENT_PRESET_KIND_UNSPECIFIED | 0 | |
MODEL_DEPLOYMENT_PRESET_KIND_GENERATION | 1 | |
MODEL_DEPLOYMENT_PRESET_KIND_EMBEDDING | 2 | |
MODEL_DEPLOYMENT_PRESET_KIND_RERANKER | 3 | |
Messages
ModelDeploymentStatus
| Field | Type | Number | Description |
|---|
stage | ModelDeploymentStage | 1 | |
stageProgress | uint32 | 2 | |
stageProgressMax | uint32 | 3 | |
errorMessage | string | 4 | |
errorCode | int32 | 5 | |
ModelDeployment
| Field | Type | Number | Description |
|---|
name | string | 1 | name is the Kubernetes resource name / admin handle for the deployment. |
model | CachedModel | 2 | model is required on Create (enforced server-side). UpdateModelDeployment may omit it when no model.* paths are listed in update_mask. |
preset | string | 3 | |
deploymentInfo | ModelDeploymentInfo | 4 | |
targetInfo | DeploymentTargetInfo | 5 | |
scaling | Scaling | 6 | |
modelId | string | 7 | model_id is the backend/canonical model identity used by the serving backend. If omitted on create, manager-go preserves legacy behavior and defaults it from name. |
sharing | Sharing | 8 | sharing reflects current sharing state. Read-only on Create/Update — mutate via UpdateModelDeploymentSharing. |
publicModelId | string | 9 | public_model_id is the client-facing model identifier. This is the exact string clients send in the OpenAI model field to invoke this deployment. Required, immutable, and unique across ModelDeployment + ExternalModel + ModelAlias within the shared namespace. Validation mirrors the operator CRD: alnum start/end, 2–128 chars, internal chars [A-Za-z0-9._/-]. |
displayName | string | 10 | display_name is the human-facing label rendered in pickers and admin UIs. Mutable; not required to be unique. |
capabilities | ModelCapabilities | 11 | capabilities describes what this model can do (task type + input modalities). Mirrors the CRD spec.capabilities. The type is defaulted from the preset kind for preset deploys, else text-generation. |
disableTracing | bool | 12 | disable_tracing stops the model server exporting OpenTelemetry spans for inference. For a custom image built without the OTel packages, which treats the tracing flag as a startup error rather than ignoring it. |
CachedModel
| Field | Type | Number | Description |
|---|
modelUrl | string | 1 | model_url is required on Create (enforced server-side) and rejected if empty when listed in UpdateModelDeployment's update_mask. Its meaning depends on source: for HUGGINGFACE it's a repo id (e.g. "Qwen/Qwen2.5-7B-Instruct"); for LOCAL_PATH it's an absolute on-node directory (e.g. "/mnt/models/qwen2.5-7b"). The server applies the matching URI scheme (hf:// or local://) for the serving backend; a value that already carries a scheme is passed through unchanged. |
modelCredentials | string | 2 | |
source | ModelSource | 3 | source selects how the weights are obtained. Defaults to HUGGINGFACE when unspecified, preserving the original behavior. On read it is derived from the stored model_url scheme. |
KeyValue
| Field | Type | Number | Description |
|---|
key | string | 1 | |
value | string | 2 | |
ModelDeploymentInfo
| Field | Type | Number | Description |
|---|
inferenceServerImage | string | 1 | |
command | string | 2 | |
args | repeated string | 3 | |
envs | repeated KeyValue | 4 | |
DeploymentTargetInfo
| Field | Type | Number | Description |
|---|
nodeSelector | repeated KeyValue | 1 | |
gpuIds | repeated string | 2 | |
gpuMemoryUtilization | float | 3 | |
Scaling
| Field | Type | Number | Description |
|---|
replicas | optional int32 | 1 | |
ModelDeploymentPresetConfig
| Field | Type | Number | Description |
|---|
inferenceServerImage | string | 1 | |
command | string | 2 | |
args | repeated string | 3 | |
envs | repeated KeyValue | 4 | |
runtimePreset | string | 5 | |
gpuMemoryUtilization | float | 6 | |
ModelDeploymentPreset
| Field | Type | Number | Description |
|---|
id | string | 1 | |
displayName | string | 2 | |
kind | ModelDeploymentPresetKind | 3 | |
modelUrl | string | 4 | |
defaultDeploymentName | string | 5 | |
defaultModelId | string | 6 | |
defaultPublicModelId | string | 7 | default_public_model_id is the default value to pre-fill into the ModelDeployment's public_model_id when creating from this preset. Constraints match public_model_id. |
defaultPublicModelDisplayName | string | 8 | default_public_model_display_name pairs with default_public_model_id — the default display_name to pre-fill on the deployment. |
defaultConfig | ModelDeploymentPresetConfig | 9 | |
capabilities | ModelCapabilities | 10 | capabilities the deployment gets when created from this preset. The portal forwards these in the create request so a catalog deploy is typed without re-deriving anything client-side. Supersedes kind, which predates the capabilities system. |
CreateModelDeploymentRequest
| Field | Type | Number | Description |
|---|
deployment | ModelDeployment | 1 | |
CreateModelDeploymentResponse
| Field | Type | Number | Description |
|---|
deployment | ModelDeployment | 1 | |
status | ModelDeploymentStatus | 2 | |
GetModelDeploymentRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
GetModelDeploymentResponse
| Field | Type | Number | Description |
|---|
deployment | ModelDeployment | 1 | |
status | ModelDeploymentStatus | 2 | |
UpdateModelDeploymentRequest
| Field | Type | Number | Description |
|---|
deployment | ModelDeployment | 1 | |
updateMask | google.protobuf.FieldMask | 2 | update_mask lists which leaf paths in deployment to write. Paths are relative to ModelDeployment (no deployment. prefix). Required and non-empty — empty/unset → InvalidArgument. Supported paths (leaves only): model.model_url, model.model_credentials, preset, deployment_info.inference_server_image, deployment_info.command, deployment_info.args, deployment_info.envs, target_info.node_selector, target_info.gpu_ids, target_info.gpu_memory_utilization, scaling.replicas, display_name, capabilities, disable_tracing. Parent paths (model, deployment_info, target_info, scaling) are NOT supported — list the leaves you want to write. capabilities is the exception: it is written as a whole message (send the full desired value; unset modality axes are defaulted from the type). Read-only/immutable paths (name, model_id, public_model_id, sharing) are rejected; mutate sharing via UpdateModelDeploymentSharing. display_name is mutable. For listed paths, empty values clear the field — including args, envs, node_selector, gpu_ids (whole-list replacement, not append). Exception: empty model.model_url is rejected. model.model_credentials is write-only: omit the path to leave existing credentials unchanged; include with non-empty value to replace; include with empty value to clear. |
UpdateModelDeploymentResponse
| Field | Type | Number | Description |
|---|
deployment | ModelDeployment | 1 | |
status | ModelDeploymentStatus | 2 | |
UpdateModelDeploymentSharingRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
sharing | Sharing | 2 | |
UpdateModelDeploymentSharingResponse
| Field | Type | Number | Description |
|---|
sharing | Sharing | 1 | |
DeleteModelDeploymentRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
DeleteModelDeploymentResponse
ListModelDeploymentsRequest
ModelDeploymentSummary
ModelDeploymentSummary is the slim shape returned by ListModelDeployments. Spec detail (model.*, deployment_info, target_info, scaling) is omitted because the list endpoint is reachable by any tenant member with can_invoke; detail fields can carry secrets (env vars, model credentials, private model URLs). Callers must fetch them via GetModelDeployment, which is gated by can_admin. share_to_all is included because pickers need to distinguish public models from tenant-scoped ones. The full Sharing struct (notably shared_with) is admin-only — enumerating other tenants on a public list would be a cross-tenant leak.
| Field | Type | Number | Description |
|---|
name | string | 1 | |
displayName | string | 2 | |
publicModelId | string | 3 | |
modelId | string | 4 | |
shareToAll | bool | 5 | |
capabilities | ModelCapabilities | 6 | capabilities lets pickers filter the list to a context without a per-item GetModelDeployment round-trip. See ModelCapabilities. |
ListModelDeploymentsResponse
| Field | Type | Number | Description |
|---|
deployments | repeated ListModelDeploymentsResponse.Item | 1 | |
ListModelDeploymentsResponse.Item
| Field | Type | Number | Description |
|---|
deployment | ModelDeploymentSummary | 1 | |
status | ModelDeploymentStatus | 2 | |
ListModelDeploymentPresetsRequest
ListModelDeploymentPresetsResponse
| Field | Type | Number | Description |
|---|
presets | repeated ModelDeploymentPreset | 1 | |
WatchModelDeploymentStatusRequest
| Field | Type | Number | Description |
|---|
names | repeated string | 1 | |
WatchModelDeploymentStatusResponse
| Field | Type | Number | Description |
|---|
name | string | 1 | |
status | ModelDeploymentStatus | 2 | |
ListModelDeploymentPermissionsRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
subjectType | optional cmind.permissions.v1.SubjectType | 2 | |
role | optional cmind.permissions.v1.DeploymentRole | 3 | |
ListModelDeploymentPermissionsResponse
| Field | Type | Number | Description |
|---|
permissions | repeated cmind.permissions.v1.DeploymentPermission | 1 | |
AddModelDeploymentPermissionRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
subject | cmind.permissions.v1.Subject | 2 | |
role | cmind.permissions.v1.DeploymentRole | 3 | |
AddModelDeploymentPermissionResponse
RemoveModelDeploymentPermissionRequest
| Field | Type | Number | Description |
|---|
name | string | 1 | |
subject | cmind.permissions.v1.Subject | 2 | |
role | cmind.permissions.v1.DeploymentRole | 3 | |
RemoveModelDeploymentPermissionResponse
Services
ModelDeploymentService
CreateModelDeployment
POST /cmind.modelmanager.v1.ModelDeploymentService/CreateModelDeployment
Request: CreateModelDeploymentRequest
Response: CreateModelDeploymentResponse
GetModelDeployment
GET /cmind.modelmanager.v1.ModelDeploymentService/GetModelDeployment
Request: GetModelDeploymentRequest
Response: GetModelDeploymentResponse
UpdateModelDeployment
POST /cmind.modelmanager.v1.ModelDeploymentService/UpdateModelDeployment
Request: UpdateModelDeploymentRequest
Response: UpdateModelDeploymentResponse
UpdateModelDeploymentSharing
POST /cmind.modelmanager.v1.ModelDeploymentService/UpdateModelDeploymentSharing
UpdateModelDeploymentSharing replaces the deployment's Sharing struct atomically (PUT semantics). The full desired state must be supplied; omitted fields are cleared. Sharing is not mutated by UpdateModelDeployment — this is the only write path for it.
Request: UpdateModelDeploymentSharingRequest
Response: UpdateModelDeploymentSharingResponse
DeleteModelDeployment
POST /cmind.modelmanager.v1.ModelDeploymentService/DeleteModelDeployment
Request: DeleteModelDeploymentRequest
Response: DeleteModelDeploymentResponse
ListModelDeployments
GET /cmind.modelmanager.v1.ModelDeploymentService/ListModelDeployments
Handler filters per-item by can_invoke; gate here is just "logged in".
Request: ListModelDeploymentsRequest
Response: ListModelDeploymentsResponse
ListModelDeploymentPresets
GET /cmind.modelmanager.v1.ModelDeploymentService/ListModelDeploymentPresets
Request: ListModelDeploymentPresetsRequest
Response: ListModelDeploymentPresetsResponse
WatchModelDeploymentStatus
POST /cmind.modelmanager.v1.ModelDeploymentService/WatchModelDeploymentStatus
Caller must be admin on every model deployment it asks to watch; the {names[]} template fans the FGA check out across the batch.
Request: WatchModelDeploymentStatusRequest
Response: stream WatchModelDeploymentStatusResponse
ListModelDeploymentPermissions
GET /cmind.modelmanager.v1.ModelDeploymentService/ListModelDeploymentPermissions
Request: ListModelDeploymentPermissionsRequest
Response: ListModelDeploymentPermissionsResponse
AddModelDeploymentPermission
POST /cmind.modelmanager.v1.ModelDeploymentService/AddModelDeploymentPermission
Request: AddModelDeploymentPermissionRequest
Response: AddModelDeploymentPermissionResponse
RemoveModelDeploymentPermission
POST /cmind.modelmanager.v1.ModelDeploymentService/RemoveModelDeploymentPermission
Request: RemoveModelDeploymentPermissionRequest
Response: RemoveModelDeploymentPermissionResponse