docs(swagger): regenerate for the failover endpoints

Regenerate the checked-in specification now that swag can parse
OpenAIResponse again after the master merge. The output also picks up
the SystemOne and process VRAM types that master had not regenerated
yet.

Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
Assisted-by: Claude:claude-opus-5-5 [Claude Code]
This commit is contained in:
Ettore Di Giacinto committed 2026-09-27 19:58:06 +00:00
1 parent dae9a431e8
commit 7d31d342d0
3 files changed
+1459 -3

No files matched your search

+543 -1
View File
@@ -881,6 +881,160 @@ const docTemplate = `{
}
}
},
"/api/failover": {
"get": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "List failover chains and the health of their targets",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/localai.FailoverChainsResponse"
}
}
}
}
},
"/api/failover/events": {
"get": {
"description": "The first event is \"snapshot\" with the full state, then \"chain.switched\" and \"target.state\" events.",
"produces": [
"text/event-stream"
],
"tags": [
"failover"
],
"summary": "Stream failover events (server-sent events)",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/failover/{chain}": {
"get": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Get one failover chain",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
}
},
"/api/failover/{chain}/pin": {
"post": {
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Pin a failover chain to one target",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
},
{
"description": "Target to pin",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/localai.FailoverPinRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"400": {
"description": "Bad Request",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
},
"delete": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Remove the pin from a failover chain",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
}
},
"/api/instructions": {
"get": {
"description": "Returns a compact list of instruction areas with descriptions and URLs for detailed guides",
@@ -3770,6 +3924,90 @@ const docTemplate = `{
}
}
},
"/v1/systemone": {
"post": {
"description": "Runs zero-shot NER over the supplied state and answers each question. Question types: noul (binary entity presence), choice (pick one option), score (pick one level).",
"tags": [
"systemone"
],
"summary": "Answer structured-extraction questions over state text.",
"parameters": [
{
"description": "state + questions",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOneRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOneResponse"
}
}
}
}
},
"/v1/systemone/permute": {
"post": {
"description": "Re-runs one choice question under n_perm option orders. Reports per-order probabilities, argmax stability, and spread.",
"tags": [
"systemone"
],
"summary": "Re-run a choice question under multiple option orders.",
"parameters": [
{
"description": "request + question + n_perm + seed",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOnePermuteRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOnePermuteResponse"
}
}
}
}
},
"/v1/systemone/separate": {
"post": {
"description": "Runs N independent NER passes, one per question, against the same state. Response shape matches /v1/systemone.",
"tags": [
"systemone"
],
"summary": "Answer each question in a separate NER pass.",
"parameters": [
{
"description": "state + questions",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOneRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOneResponse"
}
}
}
}
},
"/v1/text-to-speech/{voice-id}": {
"post": {
"tags": [
@@ -4093,8 +4331,16 @@ const docTemplate = `{
"config.Gallery": {
"type": "object",
"properties": {
"artifact_verification": {
"description": "ArtifactVerification overrides Verification only for the gallery OCI artifact.\nBackend images keep their separate Verification policy.",
"allOf": [
{
"$ref": "#/definitions/config.GalleryVerification"
}
]
},
"mirrors": {
"description": "Mirrors are tried in order when URL cannot be fetched. They are a\nfallback for availability, not a load-balancing pool: the primary is\nalways preferred, and a mirror is only consulted after the one before\nit fails. Any URI the gallery loader understands works here\n(https://, github:, file://).",
"description": "Mirrors are tried in order when URL cannot be fetched. They are a\nfallback for availability, not a load-balancing pool: the primary is\nalways preferred, and a mirror is only consulted after the one before\nit fails. Any URI the gallery loader understands works here\n(https://, github:, file://, oci://).",
"type": "array",
"items": {
"type": "string"
@@ -4129,6 +4375,10 @@ const docTemplate = `{
"not_before": {
"description": "NotBefore is an RFC3339 timestamp. Empty disables the time check.",
"type": "string"
},
"source_repository": {
"description": "SourceRepository is an https URL compared exactly against the\ncertificate's source-repository extension. Empty skips the check.",
"type": "string"
}
}
},
@@ -4146,6 +4396,97 @@ const docTemplate = `{
}
}
},
"failover.ChainState": {
"type": "string",
"enum": [
"primary",
"fallback",
"degraded"
],
"x-enum-varnames": [
"ChainPrimary",
"ChainFallback",
"ChainDegraded"
]
},
"failover.ChainStatus": {
"type": "object",
"properties": {
"active": {
"type": "string"
},
"active_since": {
"type": "string"
},
"name": {
"type": "string"
},
"pinned": {
"type": "string"
},
"state": {
"$ref": "#/definitions/failover.ChainState"
},
"targets": {
"type": "array",
"items": {
"$ref": "#/definitions/failover.TargetStatus"
}
}
}
},
"failover.Kind": {
"type": "string",
"enum": [
"local",
"remote"
],
"x-enum-varnames": [
"KindLocal",
"KindRemote"
]
},
"failover.TargetState": {
"type": "string",
"enum": [
"healthy",
"down",
"recovering",
"missing"
],
"x-enum-varnames": [
"StateHealthy",
"StateDown",
"StateRecovering",
"StateMissing"
]
},
"failover.TargetStatus": {
"type": "object",
"properties": {
"consecutive_ok": {
"type": "integer"
},
"kind": {
"$ref": "#/definitions/failover.Kind"
},
"last_error": {
"type": "string"
},
"last_probe": {
"type": "string"
},
"model": {
"type": "string"
},
"state": {
"$ref": "#/definitions/failover.TargetState"
},
"warm": {
"type": "boolean"
}
}
},
"functions.Function": {
"type": "object",
"properties": {
@@ -4556,6 +4897,25 @@ const docTemplate = `{
}
}
},
"localai.FailoverChainsResponse": {
"type": "object",
"properties": {
"chains": {
"type": "array",
"items": {
"$ref": "#/definitions/failover.ChainStatus"
}
}
}
},
"localai.FailoverPinRequest": {
"type": "object",
"properties": {
"target": {
"type": "string"
}
}
},
"localai.GalleryBackend": {
"type": "object",
"properties": {
@@ -7811,12 +8171,42 @@ const docTemplate = `{
"id": {
"type": "string"
},
"process": {
"description": "Process is the backend process serving the model on this host. Absent\nwhen the model has no local process (a distributed worker holds it) or\nthe process could not be read.",
"allOf": [
{
"$ref": "#/definitions/schema.SysInfoProcess"
}
]
},
"size_vram": {
"description": "SizeVRAM is DRM-accounted resident device memory in bytes. Nil means\nthe backend process tree has no complete supported reading.",
"type": "integer"
}
}
},
"schema.SysInfoProcess": {
"type": "object",
"properties": {
"cpu_percent": {
"description": "CPUPercent is the share of the whole host's CPU used since the previous\nreading, 0-100. Absent on the first reading of a process.",
"type": "number"
},
"memory_percent": {
"type": "number"
},
"pid": {
"type": "integer"
},
"rss_bytes": {
"description": "RSSBytes is resident host memory. Weights offloaded to a GPU are not\nin it.",
"type": "integer"
},
"started_at": {
"type": "string"
}
}
},
"schema.SystemInformationResponse": {
"type": "object",
"properties": {
@@ -7836,6 +8226,158 @@ const docTemplate = `{
}
}
},
"schema.SystemOneAnswer": {
"type": "object",
"properties": {
"choice": {
"type": "string"
},
"confidence": {
"type": "number"
},
"entities": {
"type": "array",
"items": {
"$ref": "#/definitions/schema.SystemOneEntity"
}
},
"legend": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"noul": {
"type": "number"
},
"probabilities": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
},
"score": {
"type": "number"
},
"type": {
"type": "string"
}
}
},
"schema.SystemOneEntity": {
"type": "object",
"properties": {
"confidence": {
"type": "number"
},
"end": {
"type": "integer"
},
"start": {
"type": "integer"
},
"text": {
"type": "string"
}
}
},
"schema.SystemOnePermuteRequest": {
"type": "object",
"properties": {
"n_perm": {
"type": "integer"
},
"question": {
"type": "string"
},
"request": {
"$ref": "#/definitions/schema.SystemOneRequest"
},
"seed": {
"type": "integer"
}
}
},
"schema.SystemOnePermuteResponse": {
"type": "object",
"properties": {
"argmax_stable": {
"type": "boolean"
},
"runs": {
"type": "array",
"items": {
"$ref": "#/definitions/schema.SystemOnePermuteRun"
}
},
"spread": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
}
}
},
"schema.SystemOnePermuteRun": {
"type": "object",
"properties": {
"choice": {
"type": "string"
},
"latency_ms": {
"type": "number"
},
"order": {
"type": "array",
"items": {
"type": "string"
}
},
"probabilities": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
}
}
},
"schema.SystemOneRequest": {
"type": "object"
},
"schema.SystemOneResponse": {
"type": "object",
"properties": {
"answers": {
"type": "object",
"additionalProperties": {
"$ref": "#/definitions/schema.SystemOneAnswer"
}
},
"latency_ms": {
"type": "number"
},
"model": {
"type": "string"
},
"usage": {
"$ref": "#/definitions/schema.SystemOneUsage"
}
}
},
"schema.SystemOneUsage": {
"type": "object",
"properties": {
"input_tokens": {
"type": "integer"
},
"output_tokens": {
"type": "integer"
}
}
},
"schema.TTSRequest": {
"description": "TTS request body",
"type": "object",
+543 -1
View File
@@ -878,6 +878,160 @@
}
}
},
"/api/failover": {
"get": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "List failover chains and the health of their targets",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/localai.FailoverChainsResponse"
}
}
}
}
},
"/api/failover/events": {
"get": {
"description": "The first event is \"snapshot\" with the full state, then \"chain.switched\" and \"target.state\" events.",
"produces": [
"text/event-stream"
],
"tags": [
"failover"
],
"summary": "Stream failover events (server-sent events)",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/failover/{chain}": {
"get": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Get one failover chain",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
}
},
"/api/failover/{chain}/pin": {
"post": {
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Pin a failover chain to one target",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
},
{
"description": "Target to pin",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/localai.FailoverPinRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"400": {
"description": "Bad Request",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
},
"delete": {
"produces": [
"application/json"
],
"tags": [
"failover"
],
"summary": "Remove the pin from a failover chain",
"parameters": [
{
"type": "string",
"description": "Chain name",
"name": "chain",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/failover.ChainStatus"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/schema.ErrorResponse"
}
}
}
}
},
"/api/instructions": {
"get": {
"description": "Returns a compact list of instruction areas with descriptions and URLs for detailed guides",
@@ -3767,6 +3921,90 @@
}
}
},
"/v1/systemone": {
"post": {
"description": "Runs zero-shot NER over the supplied state and answers each question. Question types: noul (binary entity presence), choice (pick one option), score (pick one level).",
"tags": [
"systemone"
],
"summary": "Answer structured-extraction questions over state text.",
"parameters": [
{
"description": "state + questions",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOneRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOneResponse"
}
}
}
}
},
"/v1/systemone/permute": {
"post": {
"description": "Re-runs one choice question under n_perm option orders. Reports per-order probabilities, argmax stability, and spread.",
"tags": [
"systemone"
],
"summary": "Re-run a choice question under multiple option orders.",
"parameters": [
{
"description": "request + question + n_perm + seed",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOnePermuteRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOnePermuteResponse"
}
}
}
}
},
"/v1/systemone/separate": {
"post": {
"description": "Runs N independent NER passes, one per question, against the same state. Response shape matches /v1/systemone.",
"tags": [
"systemone"
],
"summary": "Answer each question in a separate NER pass.",
"parameters": [
{
"description": "state + questions",
"name": "request",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/schema.SystemOneRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/schema.SystemOneResponse"
}
}
}
}
},
"/v1/text-to-speech/{voice-id}": {
"post": {
"tags": [
@@ -4090,8 +4328,16 @@
"config.Gallery": {
"type": "object",
"properties": {
"artifact_verification": {
"description": "ArtifactVerification overrides Verification only for the gallery OCI artifact.\nBackend images keep their separate Verification policy.",
"allOf": [
{
"$ref": "#/definitions/config.GalleryVerification"
}
]
},
"mirrors": {
"description": "Mirrors are tried in order when URL cannot be fetched. They are a\nfallback for availability, not a load-balancing pool: the primary is\nalways preferred, and a mirror is only consulted after the one before\nit fails. Any URI the gallery loader understands works here\n(https://, github:, file://).",
"description": "Mirrors are tried in order when URL cannot be fetched. They are a\nfallback for availability, not a load-balancing pool: the primary is\nalways preferred, and a mirror is only consulted after the one before\nit fails. Any URI the gallery loader understands works here\n(https://, github:, file://, oci://).",
"type": "array",
"items": {
"type": "string"
@@ -4126,6 +4372,10 @@
"not_before": {
"description": "NotBefore is an RFC3339 timestamp. Empty disables the time check.",
"type": "string"
},
"source_repository": {
"description": "SourceRepository is an https URL compared exactly against the\ncertificate's source-repository extension. Empty skips the check.",
"type": "string"
}
}
},
@@ -4143,6 +4393,97 @@
}
}
},
"failover.ChainState": {
"type": "string",
"enum": [
"primary",
"fallback",
"degraded"
],
"x-enum-varnames": [
"ChainPrimary",
"ChainFallback",
"ChainDegraded"
]
},
"failover.ChainStatus": {
"type": "object",
"properties": {
"active": {
"type": "string"
},
"active_since": {
"type": "string"
},
"name": {
"type": "string"
},
"pinned": {
"type": "string"
},
"state": {
"$ref": "#/definitions/failover.ChainState"
},
"targets": {
"type": "array",
"items": {
"$ref": "#/definitions/failover.TargetStatus"
}
}
}
},
"failover.Kind": {
"type": "string",
"enum": [
"local",
"remote"
],
"x-enum-varnames": [
"KindLocal",
"KindRemote"
]
},
"failover.TargetState": {
"type": "string",
"enum": [
"healthy",
"down",
"recovering",
"missing"
],
"x-enum-varnames": [
"StateHealthy",
"StateDown",
"StateRecovering",
"StateMissing"
]
},
"failover.TargetStatus": {
"type": "object",
"properties": {
"consecutive_ok": {
"type": "integer"
},
"kind": {
"$ref": "#/definitions/failover.Kind"
},
"last_error": {
"type": "string"
},
"last_probe": {
"type": "string"
},
"model": {
"type": "string"
},
"state": {
"$ref": "#/definitions/failover.TargetState"
},
"warm": {
"type": "boolean"
}
}
},
"functions.Function": {
"type": "object",
"properties": {
@@ -4553,6 +4894,25 @@
}
}
},
"localai.FailoverChainsResponse": {
"type": "object",
"properties": {
"chains": {
"type": "array",
"items": {
"$ref": "#/definitions/failover.ChainStatus"
}
}
}
},
"localai.FailoverPinRequest": {
"type": "object",
"properties": {
"target": {
"type": "string"
}
}
},
"localai.GalleryBackend": {
"type": "object",
"properties": {
@@ -7808,12 +8168,42 @@
"id": {
"type": "string"
},
"process": {
"description": "Process is the backend process serving the model on this host. Absent\nwhen the model has no local process (a distributed worker holds it) or\nthe process could not be read.",
"allOf": [
{
"$ref": "#/definitions/schema.SysInfoProcess"
}
]
},
"size_vram": {
"description": "SizeVRAM is DRM-accounted resident device memory in bytes. Nil means\nthe backend process tree has no complete supported reading.",
"type": "integer"
}
}
},
"schema.SysInfoProcess": {
"type": "object",
"properties": {
"cpu_percent": {
"description": "CPUPercent is the share of the whole host's CPU used since the previous\nreading, 0-100. Absent on the first reading of a process.",
"type": "number"
},
"memory_percent": {
"type": "number"
},
"pid": {
"type": "integer"
},
"rss_bytes": {
"description": "RSSBytes is resident host memory. Weights offloaded to a GPU are not\nin it.",
"type": "integer"
},
"started_at": {
"type": "string"
}
}
},
"schema.SystemInformationResponse": {
"type": "object",
"properties": {
@@ -7833,6 +8223,158 @@
}
}
},
"schema.SystemOneAnswer": {
"type": "object",
"properties": {
"choice": {
"type": "string"
},
"confidence": {
"type": "number"
},
"entities": {
"type": "array",
"items": {
"$ref": "#/definitions/schema.SystemOneEntity"
}
},
"legend": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"noul": {
"type": "number"
},
"probabilities": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
},
"score": {
"type": "number"
},
"type": {
"type": "string"
}
}
},
"schema.SystemOneEntity": {
"type": "object",
"properties": {
"confidence": {
"type": "number"
},
"end": {
"type": "integer"
},
"start": {
"type": "integer"
},
"text": {
"type": "string"
}
}
},
"schema.SystemOnePermuteRequest": {
"type": "object",
"properties": {
"n_perm": {
"type": "integer"
},
"question": {
"type": "string"
},
"request": {
"$ref": "#/definitions/schema.SystemOneRequest"
},
"seed": {
"type": "integer"
}
}
},
"schema.SystemOnePermuteResponse": {
"type": "object",
"properties": {
"argmax_stable": {
"type": "boolean"
},
"runs": {
"type": "array",
"items": {
"$ref": "#/definitions/schema.SystemOnePermuteRun"
}
},
"spread": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
}
}
},
"schema.SystemOnePermuteRun": {
"type": "object",
"properties": {
"choice": {
"type": "string"
},
"latency_ms": {
"type": "number"
},
"order": {
"type": "array",
"items": {
"type": "string"
}
},
"probabilities": {
"type": "object",
"additionalProperties": {
"type": "number",
"format": "float64"
}
}
}
},
"schema.SystemOneRequest": {
"type": "object"
},
"schema.SystemOneResponse": {
"type": "object",
"properties": {
"answers": {
"type": "object",
"additionalProperties": {
"$ref": "#/definitions/schema.SystemOneAnswer"
}
},
"latency_ms": {
"type": "number"
},
"model": {
"type": "string"
},
"usage": {
"$ref": "#/definitions/schema.SystemOneUsage"
}
}
},
"schema.SystemOneUsage": {
"type": "object",
"properties": {
"input_tokens": {
"type": "integer"
},
"output_tokens": {
"type": "integer"
}
}
},
"schema.TTSRequest": {
"description": "TTS request body",
"type": "object",
+373 -1
View File
@@ -2,13 +2,19 @@ basePath: /
definitions:
config.Gallery:
properties:
artifact_verification:
allOf:
- $ref: '#/definitions/config.GalleryVerification'
description: |-
ArtifactVerification overrides Verification only for the gallery OCI artifact.
Backend images keep their separate Verification policy.
mirrors:
description: |-
Mirrors are tried in order when URL cannot be fetched. They are a
fallback for availability, not a load-balancing pool: the primary is
always preferred, and a mirror is only consulted after the one before
it fails. Any URI the gallery loader understands works here
(https://, github:, file://).
(https://, github:, file://, oci://).
items:
type: string
type: array
@@ -32,6 +38,11 @@ definitions:
not_before:
description: NotBefore is an RFC3339 timestamp. Empty disables the time check.
type: string
source_repository:
description: |-
SourceRepository is an https URL compared exactly against the
certificate's source-repository extension. Empty skips the check.
type: string
type: object
config.TTSVoice:
properties:
@@ -42,6 +53,70 @@ definitions:
name:
type: string
type: object
failover.ChainState:
enum:
- primary
- fallback
- degraded
type: string
x-enum-varnames:
- ChainPrimary
- ChainFallback
- ChainDegraded
failover.ChainStatus:
properties:
active:
type: string
active_since:
type: string
name:
type: string
pinned:
type: string
state:
$ref: '#/definitions/failover.ChainState'
targets:
items:
$ref: '#/definitions/failover.TargetStatus'
type: array
type: object
failover.Kind:
enum:
- local
- remote
type: string
x-enum-varnames:
- KindLocal
- KindRemote
failover.TargetState:
enum:
- healthy
- down
- recovering
- missing
type: string
x-enum-varnames:
- StateHealthy
- StateDown
- StateRecovering
- StateMissing
failover.TargetStatus:
properties:
consecutive_ok:
type: integer
kind:
$ref: '#/definitions/failover.Kind'
last_error:
type: string
last_probe:
type: string
model:
type: string
state:
$ref: '#/definitions/failover.TargetState'
warm:
type: boolean
type: object
functions.Function:
properties:
description:
@@ -333,6 +408,18 @@ definitions:
logo_url:
type: string
type: object
localai.FailoverChainsResponse:
properties:
chains:
items:
$ref: '#/definitions/failover.ChainStatus'
type: array
type: object
localai.FailoverPinRequest:
properties:
target:
type: string
type: object
localai.GalleryBackend:
properties:
force:
@@ -2654,12 +2741,38 @@ definitions:
type: string
id:
type: string
process:
allOf:
- $ref: '#/definitions/schema.SysInfoProcess'
description: |-
Process is the backend process serving the model on this host. Absent
when the model has no local process (a distributed worker holds it) or
the process could not be read.
size_vram:
description: |-
SizeVRAM is DRM-accounted resident device memory in bytes. Nil means
the backend process tree has no complete supported reading.
type: integer
type: object
schema.SysInfoProcess:
properties:
cpu_percent:
description: |-
CPUPercent is the share of the whole host's CPU used since the previous
reading, 0-100. Absent on the first reading of a process.
type: number
memory_percent:
type: number
pid:
type: integer
rss_bytes:
description: |-
RSSBytes is resident host memory. Weights offloaded to a GPU are not
in it.
type: integer
started_at:
type: string
type: object
schema.SystemInformationResponse:
properties:
backends:
@@ -2673,6 +2786,106 @@ definitions:
$ref: '#/definitions/schema.SysInfoModel'
type: array
type: object
schema.SystemOneAnswer:
properties:
choice:
type: string
confidence:
type: number
entities:
items:
$ref: '#/definitions/schema.SystemOneEntity'
type: array
legend:
additionalProperties:
type: string
type: object
noul:
type: number
probabilities:
additionalProperties:
format: float64
type: number
type: object
score:
type: number
type:
type: string
type: object
schema.SystemOneEntity:
properties:
confidence:
type: number
end:
type: integer
start:
type: integer
text:
type: string
type: object
schema.SystemOnePermuteRequest:
properties:
n_perm:
type: integer
question:
type: string
request:
$ref: '#/definitions/schema.SystemOneRequest'
seed:
type: integer
type: object
schema.SystemOnePermuteResponse:
properties:
argmax_stable:
type: boolean
runs:
items:
$ref: '#/definitions/schema.SystemOnePermuteRun'
type: array
spread:
additionalProperties:
format: float64
type: number
type: object
type: object
schema.SystemOnePermuteRun:
properties:
choice:
type: string
latency_ms:
type: number
order:
items:
type: string
type: array
probabilities:
additionalProperties:
format: float64
type: number
type: object
type: object
schema.SystemOneRequest:
type: object
schema.SystemOneResponse:
properties:
answers:
additionalProperties:
$ref: '#/definitions/schema.SystemOneAnswer'
type: object
latency_ms:
type: number
model:
type: string
usage:
$ref: '#/definitions/schema.SystemOneUsage'
type: object
schema.SystemOneUsage:
properties:
input_tokens:
type: integer
output_tokens:
type: integer
type: object
schema.TTSRequest:
description: TTS request body
properties:
@@ -3729,6 +3942,107 @@ paths:
summary: Upload a branding asset
tags:
- branding
/api/failover:
get:
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/localai.FailoverChainsResponse'
summary: List failover chains and the health of their targets
tags:
- failover
/api/failover/{chain}:
get:
parameters:
- description: Chain name
in: path
name: chain
required: true
type: string
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/failover.ChainStatus'
"404":
description: Not Found
schema:
$ref: '#/definitions/schema.ErrorResponse'
summary: Get one failover chain
tags:
- failover
/api/failover/{chain}/pin:
delete:
parameters:
- description: Chain name
in: path
name: chain
required: true
type: string
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/failover.ChainStatus'
"404":
description: Not Found
schema:
$ref: '#/definitions/schema.ErrorResponse'
summary: Remove the pin from a failover chain
tags:
- failover
post:
consumes:
- application/json
parameters:
- description: Chain name
in: path
name: chain
required: true
type: string
- description: Target to pin
in: body
name: request
required: true
schema:
$ref: '#/definitions/localai.FailoverPinRequest'
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/failover.ChainStatus'
"400":
description: Bad Request
schema:
$ref: '#/definitions/schema.ErrorResponse'
"404":
description: Not Found
schema:
$ref: '#/definitions/schema.ErrorResponse'
summary: Pin a failover chain to one target
tags:
- failover
/api/failover/events:
get:
description: The first event is "snapshot" with the full state, then "chain.switched"
and "target.state" events.
produces:
- text/event-stream
responses:
"200":
description: OK
summary: Stream failover events (server-sent events)
tags:
- failover
/api/instructions:
get:
description: Returns a compact list of instruction areas with descriptions and
@@ -5672,6 +5986,64 @@ paths:
summary: Generates audio from the input text.
tags:
- audio
/v1/systemone:
post:
description: 'Runs zero-shot NER over the supplied state and answers each question.
Question types: noul (binary entity presence), choice (pick one option), score
(pick one level).'
parameters:
- description: state + questions
in: body
name: request
required: true
schema:
$ref: '#/definitions/schema.SystemOneRequest'
responses:
"200":
description: OK
schema:
$ref: '#/definitions/schema.SystemOneResponse'
summary: Answer structured-extraction questions over state text.
tags:
- systemone
/v1/systemone/permute:
post:
description: Re-runs one choice question under n_perm option orders. Reports
per-order probabilities, argmax stability, and spread.
parameters:
- description: request + question + n_perm + seed
in: body
name: request
required: true
schema:
$ref: '#/definitions/schema.SystemOnePermuteRequest'
responses:
"200":
description: OK
schema:
$ref: '#/definitions/schema.SystemOnePermuteResponse'
summary: Re-run a choice question under multiple option orders.
tags:
- systemone
/v1/systemone/separate:
post:
description: Runs N independent NER passes, one per question, against the same
state. Response shape matches /v1/systemone.
parameters:
- description: state + questions
in: body
name: request
required: true
schema:
$ref: '#/definitions/schema.SystemOneRequest'
responses:
"200":
description: OK
schema:
$ref: '#/definitions/schema.SystemOneResponse'
summary: Answer each question in a separate NER pass.
tags:
- systemone
/v1/text-to-speech/{voice-id}:
post:
parameters: