add_own_model
Add an own model
Add a vendor model to the account's own key. Without modes: read the model and its family off the vendor and return each endpoint's fields and a proposed binding (prompt_field, media_fields, output), saving nothing. With modes: save it with the endpoints and bindings you confirm, each { endpoint, slot, binding } built from that proposal. The account must hold a key for the vendor (Settings).
Scope
generation.write— Makes, edits, imports, shares and deletes media in the account.
Behaviour
- Writes
- Creates or changes items in the caller's own account.
- Adds or updates
- Adds or updates; nothing the caller already has is deleted or overwritten.
- Reaches outside
- Reads the vendor's catalog and the model's own schema with the account's own key.
Inputs
vendorstring · requiredone of "replicate", "fal", "siray", "runware", "higgsfield"
refstring · requiredThe vendor's model address, as list_own_models' search returns it or as its site shows it.
at least 1 character · at most 300 characters
labelstring · optionalat least 1 character · at most 120 characters
kindstring · optionalone of "image", "video", "tts", "music"
modesarray of object · optionalat least 1 item · at most 24 items
Example call
A tools/call request with the required arguments only, each a placeholder read off the schema. Replace them before sending.
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "add_own_model",
"arguments": {
"vendor": "replicate",
"ref": "<ref>"
}
}
}Input schema
As the server sends it in tools/list.
{
"type": "object",
"properties": {
"vendor": {
"type": "string",
"enum": [
"replicate",
"fal",
"siray",
"runware",
"higgsfield"
]
},
"ref": {
"type": "string",
"minLength": 1,
"maxLength": 300,
"description": "The vendor's model address, as list_own_models' search returns it or as its site shows it."
},
"label": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"kind": {
"type": "string",
"enum": [
"image",
"video",
"tts",
"music"
]
},
"modes": {
"type": "array",
"items": {
"type": "object",
"properties": {
"endpoint": {
"type": "string",
"minLength": 1,
"maxLength": 240
},
"slot": {
"type": "string",
"enum": [
"text",
"frames",
"references",
"image",
"other"
]
},
"binding": {
"type": "object",
"properties": {
"prompt_field": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 120
},
{
"type": "null"
}
]
},
"media_fields": {
"type": "array",
"items": {
"type": "object",
"properties": {
"field": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"accepts": {
"type": "string",
"enum": [
"image",
"video",
"audio"
]
},
"role": {
"type": "string",
"enum": [
"first_frame",
"last_frame",
"reference"
]
}
},
"required": [
"field",
"accepts"
],
"additionalProperties": false
},
"maxItems": 40
},
"output": {
"$ref": "#/properties/modes/items/properties/binding/properties/media_fields/items/properties/accepts"
},
"controls": {
"type": "array",
"items": {
"type": "object",
"properties": {
"field": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"role": {
"type": "string",
"enum": [
"aspect_ratio",
"duration",
"resolution",
"audio"
]
}
},
"required": [
"field",
"role"
],
"additionalProperties": false
},
"maxItems": 4
}
},
"required": [
"prompt_field",
"media_fields",
"output"
],
"additionalProperties": false
}
},
"required": [
"endpoint",
"slot",
"binding"
],
"additionalProperties": false
},
"minItems": 1,
"maxItems": 24
}
},
"required": [
"vendor",
"ref"
],
"additionalProperties": false
}Related tools
- list_own_models
The vendor models this account added to its own key (vendor, endpoint, modes, what each makes).