Skip to content

armgit / avibe

Public Imported from GitHub
0

Make your computer a home for your AI partner. Avibe is the local-first Agent OS: Vibey, its built-in AI partner, works out of the box, and Claude Code, Codex & OpenCode run unchanged beside it — reach them from your browser, phone, or any chat app.

7.3 KB
Raw Blame
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "model-hub/runtime-dependency.schema.json",
  "title": "RuntimeDependency",
  "description": "v5 managed engine dependency manifest + persisted user intent + server-owned installation and runtime status. not_installed -> installing -> not_started is the installation path; not_started is installed lazy-start idleness, and down means a demanded runtime failed or stopped. Pinned manifest values remain normative until the next explicit re-pin. The one-time default-on upgrade marker is persisted in model_hub config, not returned on this runtime response.",
  "type": "object",
  "required": ["contract_version", "manifest", "status"],
  "additionalProperties": false,
  "properties": {
    "contract_version": { "const": 23 },
    "enabled": {
      "type": "boolean",
      "description": "Persisted user intent for the managed gateway. Fresh/default configuration is true; explicit stop persists false."
    },
    "host_platform": {
      "type": "string",
      "pattern": "^[a-z0-9]+(?:-[a-z0-9_]+)+$",
      "description": "Server-authoritative platform key for the Avibe host, never the browser device. Manifest admission is derived from manifest.resolution. OPTIONAL in the reusable schema and REQUIRED on runtime API payloads."
    },
    "manifest": {
      "type": "object",
      "required": ["name", "resolution", "assets"],
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": { "resolution": { "const": "unresolved" } },
            "required": ["resolution"]
          },
          "then": {
            "properties": { "assets": { "maxItems": 0 } },
            "not": {
              "anyOf": [
                { "required": ["version"] },
                { "required": ["source_sha"] }
              ]
            }
          },
          "else": {
            "required": ["version", "source_sha"]
          }
        }
      ],
      "properties": {
        "name": { "const": "cliproxyapi" },
        "resolution": {
          "enum": ["resolved", "unresolved", "unsupported"],
          "description": "resolved means a trusted inventory contains an exact host asset; unresolved means no trusted local inventory exists yet; unsupported means a trusted inventory exists without an exact host asset."
        },
        "version": { "type": "string", "minLength": 1 },
        "source_sha": { "type": "string", "pattern": "^[0-9a-f]{40}$" },
        "assets": {
          "type": "array",
          "description": "Trusted pinned assets. Empty is required for unresolved and is not evidence of unsupported host admission.",
          "items": {
            "type": "object",
            "required": ["platform", "url", "size_bytes", "sha256"],
            "additionalProperties": false,
            "properties": {
              "platform": { "enum": ["darwin-arm64", "darwin-x64", "linux-amd64", "linux-arm64", "windows-amd64", "windows-arm64"] },
              "url": { "type": "string" },
              "size_bytes": { "type": "integer" },
              "sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" }
            }
          }
        }
      }
    },
    "status": {
      "type": "object",
      "required": ["installed_version", "verified", "health"],
      "additionalProperties": false,
      "allOf": [
        {
          "$comment": "Only not_installed may carry a persisted install-failure key. Initial absence and an unsupported host may still carry null.",
          "if": {
            "properties": {
              "health": {
                "not": { "const": "not_installed" }
              }
            },
            "required": ["health"]
          },
          "then": {
            "properties": {
              "error_key": { "type": "null" }
            }
          }
        },
        {
          "$comment": "installing is the unverified, non-listening transition entered only from not_installed. A verified binary settles at not_started before it may listen.",
          "if": {
            "properties": {
              "health": { "const": "installing" }
            },
            "required": ["health"]
          },
          "then": {
            "required": ["listening"],
            "properties": {
              "installed_version": { "type": "null" },
              "verified": { "const": false },
              "listening": { "type": "null" }
            }
          }
        }
      ],
      "properties": {
        "installed_version": { "type": ["string", "null"] },
        "verified": { "type": "boolean", "description": "SHA256 of installed binary matches manifest" },
        "listening": {
          "type": ["object", "null"],
          "required": ["host", "port"],
          "additionalProperties": false,
          "properties": {
            "host": { "const": "127.0.0.1" },
            "port": { "type": "integer" }
          }
        },
        "health": {
          "enum": ["ok", "degraded", "down", "not_installed", "installing", "not_started"],
          "description": "not_installed is the stable absence state; installing is the server-owned transition after an install request; not_started is verified installation and intentional lazy-start idleness; down is a runtime that was demanded and is no longer available."
        },
        "last_check": { "type": ["string", "null"], "format": "date-time" },
        "error_key": {
          "enum": [null, "settings.models.install.fail.detail"],
          "description": "Persisted closed i18n key for the most recent install failure. A failed install settles at not_installed with settings.models.install.fail.detail; a new install attempt clears it before entering installing, and every other health carries null. OPTIONAL in the reusable schema and REQUIRED on runtime API payloads."
        }
      }
    }
  },
  "examples": [
    {
      "contract_version": 23,
      "host_platform": "darwin-arm64",
      "manifest": {
        "name": "cliproxyapi",
        "resolution": "resolved",
        "version": "v7.2.95",
        "source_sha": "f71ec0eb6776854457892452cf28c47f0d658251",
        "assets": [
          { "platform": "darwin-arm64", "url": "https://github.com/router-for-me/CLIProxyAPI/releases/download/v7.2.95/<darwin-arm64-asset>", "size_bytes": 14384655, "sha256": "c7ccc28b7db5d1799999a9e22725ccc6bd0e36d9aa023da6b52b7c1a71aad978" },
          { "platform": "darwin-x64", "url": "https://github.com/router-for-me/CLIProxyAPI/releases/download/v7.2.95/<darwin-x64-asset>", "size_bytes": 15372282, "sha256": "fbee90c29ee1047a8b3041d736500422bea22cd2ebb306782efcd74c0a10939c" },
          { "platform": "linux-amd64", "url": "https://github.com/router-for-me/CLIProxyAPI/releases/download/v7.2.95/<linux-amd64-asset>", "size_bytes": 15401775, "sha256": "826604e2dbf11913b0f373047f7bca1829eb2bab8a45d3a1916cc2534c7a9fd5" },
          { "platform": "linux-arm64", "url": "https://github.com/router-for-me/CLIProxyAPI/releases/download/v7.2.95/<linux-arm64-asset>", "size_bytes": 14062559, "sha256": "acc1173c73db2a2ee203438bac9a956491855d4955c5175855abc62d12ae0184" }
        ]
      },
      "status": {
        "installed_version": "v7.2.95",
        "verified": true,
        "listening": { "host": "127.0.0.1", "port": 15220 },
        "health": "ok",
        "last_check": "2026-07-23T03:40:00+08:00",
        "error_key": null
      }
    }
  ]
}