Uoink 3.12.0 / tool reference
apply_reshelving
Create a reshelving preview or apply an approved preview to current labels.
Inputs
Input variant 1
modeOptionalsee full schema (default: "preview")
run_idRequiredtext
expected_projection_revisionRequiredwhole number
activate_versionOptionaltrue or false (default: false)
Input variant 2
modeRequiredsee full schema
preview_idRequiredtext
expected_projection_revisionRequiredwhole number
delta_hashRequiredtext
operation_keyRequiredtext
Full input schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$defs": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"client": {
"type": "string",
"minLength": 1,
"maxLength": 64
},
"key": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"hash": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"token": {
"type": "string",
"pattern": "^[A-Za-z0-9_-]{43,128}$"
},
"revision": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
},
"confidence": {
"type": "number",
"minimum": 0,
"maximum": 1
},
"evidence": {
"type": "object",
"properties": {
"basis": {
"type": "string",
"enum": [
"packet",
"fetched_full"
]
},
"kind": {
"type": "string",
"enum": [
"timed_clip",
"text_only"
]
},
"excerpt_id": {
"$ref": "#/$defs/hash"
},
"card_hash": {
"$ref": "#/$defs/hash"
},
"quote": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"basis",
"kind",
"excerpt_id",
"card_hash",
"quote"
],
"additionalProperties": false
},
"membership": {
"type": "object",
"properties": {
"shelf_id": {
"$ref": "#/$defs/id"
},
"shelf_path": {
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 100
},
"minItems": 1,
"maxItems": 3
},
"confidence": {
"$ref": "#/$defs/confidence"
},
"evidence": {
"$ref": "#/$defs/evidence"
}
},
"required": [
"shelf_id",
"shelf_path",
"confidence",
"evidence"
],
"additionalProperties": false
},
"result": {
"oneOf": [
{
"type": "object",
"properties": {
"outcome": {
"const": "assigned"
},
"memberships": {
"type": "array",
"items": {
"$ref": "#/$defs/membership"
},
"minItems": 1,
"maxItems": 3
}
},
"required": [
"outcome",
"memberships"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"outcome": {
"type": "string",
"enum": [
"unmapped",
"unsupported",
"error"
]
},
"reason": {
"type": "string",
"minLength": 1,
"maxLength": 500
}
},
"required": [
"outcome",
"reason"
],
"additionalProperties": false
}
]
},
"usage": {
"oneOf": [
{
"type": "object",
"properties": {
"status": {
"const": "reported"
},
"model": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"input_tokens": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
},
"output_tokens": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
},
"cache_read_tokens": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
},
"cache_create_tokens": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
},
"wall_time_ms": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
}
},
"required": [
"status",
"model",
"input_tokens",
"output_tokens",
"wall_time_ms"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"status": {
"const": "unavailable"
},
"model": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"reason": {
"type": "string",
"minLength": 1,
"maxLength": 500
},
"wall_time_ms": {
"type": "integer",
"minimum": 0,
"maximum": 2147483647
}
},
"required": [
"status",
"reason"
],
"additionalProperties": false
}
]
}
},
"oneOf": [
{
"type": "object",
"properties": {
"mode": {
"const": "preview",
"default": "preview"
},
"run_id": {
"$ref": "#/$defs/id"
},
"expected_projection_revision": {
"$ref": "#/$defs/revision"
},
"activate_version": {
"type": "boolean",
"default": false
}
},
"required": [
"run_id",
"expected_projection_revision"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"mode": {
"const": "apply"
},
"preview_id": {
"$ref": "#/$defs/id"
},
"expected_projection_revision": {
"$ref": "#/$defs/revision"
},
"delta_hash": {
"$ref": "#/$defs/hash"
},
"operation_key": {
"$ref": "#/$defs/key"
}
},
"required": [
"mode",
"preview_id",
"expected_projection_revision",
"delta_hash",
"operation_key"
],
"additionalProperties": false
}
]
}Outputs and behavior
Create a reshelving preview or apply an approved preview to current labels. Use after submit_library_result stages assignments; use pin_shelf for a user's individual shelf decision or undo_library_apply to reverse the latest apply. Preview needs a run and current projection revision; apply needs its preview_id, delta_hash and operation_key. Apply is disabled by default and stops at 15 percent churn without trusted human approval; expired or stale previews must be rebuilt.
The registry does not publish an output schema for this tool. The description above is its documented behavior; response fields beyond it are not specified here.
Example call
Example tool name and arguments, generated from the input schema. Replace placeholder strings and sample numbers with your own values. This is a request template, not a recorded call or response.
Input variant 1
{
"name": "apply_reshelving",
"arguments": {
"run_id": "YOUR_RUN_ID",
"expected_projection_revision": 0,
"mode": "preview",
"activate_version": false
}
}Input variant 2
{
"name": "apply_reshelving",
"arguments": {
"mode": "apply",
"preview_id": "YOUR_PREVIEW_ID",
"expected_projection_revision": 0,
"delta_hash": "0000000000000000000000000000000000000000000000000000000000000000",
"operation_key": "YOUR_OPERATION_KEY"
}
}Clients
This tool is available to MCP clients using stdio or http.
The registry records transport support, not individual client test results. See the MCP setup reference for named clients, configuration, and tool-list limits.
Source
Uoink 3.12.0 tool registry. Synced .