Skip to content

Personal AI agent for macOS, Windows, Linux, Android & iOS. Set a goal, it works alone: coding (Skales Code), desktop + browser automation, autonomous scheduled Tasks. Teams of agents and humans across paired desktops. Agent2Agent, MCP, computer use, voice, local LLMs (Ollama), Agent Skills (SKILL.md). 26 AI providers, BYOK. No Docker, no terminal.

511 KB
Raw Blame
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>Skales — User Guide</title>
  <link rel="preconnect" href="https://fonts.googleapis.com" />
  <link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap" rel="stylesheet" />
  <style>
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

    :root {
      --bg: #09090b;
      --surface: #18181b;
      --surface-light: #27272a;
      --border: #27272a;
      --text: #fafafa;
      --muted: #a1a1aa;
      --accent: #84cc16;
      --accent-hover: #a3e635;
      --accent-glow: rgba(132, 204, 22, 0.12);
      --radius: 0.75rem;
    }

    body {
      font-family: 'Inter', -apple-system, sans-serif;
      background: var(--bg);
      color: var(--text);
      line-height: 1.7;
      font-size: 15px;
    }

    /* Layout */
    .wrapper { display: flex; min-height: 100vh; }

    nav {
      width: 280px;
      min-width: 280px;
      background: #0f0f12;
      border-right: 1px solid var(--border);
      padding: 1.5rem 1.1rem 3rem;
      position: sticky;
      top: 0;
      height: 100vh;
      overflow-y: auto;
    }

    nav .logo {
      display: flex;
      align-items: center;
      gap: 0.6rem;
      margin-bottom: 1.1rem;
      text-decoration: none;
    }
    nav .logo-mark {
      width: 32px;
      height: 32px;
      background: var(--accent);
      border-radius: 8px;
      display: flex;
      align-items: center;
      justify-content: center;
      font-weight: 800;
      font-size: 14px;
      color: #000;
    }
    nav .logo-text { font-weight: 700; font-size: 1.1rem; color: var(--text); }
    nav .logo-version { font-size: 0.7rem; color: var(--muted); margin-left: 2px; }

    /* Search */
    .search-box { position: relative; margin-bottom: 1.25rem; }
    .search-box input {
      width: 100%;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 0.5rem;
      color: var(--text);
      font: inherit;
      font-size: 0.85rem;
      padding: 0.5rem 2.2rem 0.5rem 0.7rem;
      outline: none;
    }
    .search-box input::placeholder { color: #6b6b74; }
    .search-box input:focus { border-color: rgba(132, 204, 22, 0.45); }
    .search-box .search-key {
      position: absolute;
      right: 0.5rem;
      top: 50%;
      transform: translateY(-50%);
      font-family: monospace;
      font-size: 0.7rem;
      color: #6b6b74;
      border: 1px solid var(--border);
      border-radius: 4px;
      padding: 0 0.3rem;
      pointer-events: none;
    }
    .search-box input:focus ~ .search-key { display: none; }

    #search-results { display: none; margin-bottom: 1rem; }
    body.searching #search-results { display: block; }
    body.searching #toc { display: none; }
    .search-count {
      font-size: 0.65rem;
      font-weight: 600;
      letter-spacing: 0.1em;
      text-transform: uppercase;
      color: var(--muted);
      margin: 0 0 0.5rem 0.5rem;
    }
    .search-hit {
      display: block;
      padding: 0.45rem 0.7rem;
      border-radius: 0.5rem;
      text-decoration: none;
      border: 1px solid transparent;
    }
    .search-hit:hover, .search-hit.sel { background: var(--surface-light); border-color: var(--border); }
    .search-hit .hit-title { display: block; font-size: 0.83rem; color: var(--text); font-weight: 500; }
    .search-hit .hit-where { display: block; font-size: 0.68rem; color: var(--accent); text-transform: uppercase; letter-spacing: 0.06em; }
    .search-hit .hit-snip { display: block; font-size: 0.73rem; color: var(--muted); line-height: 1.45; margin-top: 0.15rem; }
    .search-hit mark { background: rgba(132, 204, 22, 0.22); color: var(--text); border-radius: 2px; padding: 0 1px; }
    .search-empty { font-size: 0.8rem; color: var(--muted); padding: 0.5rem 0.7rem; }

    /* Chapter switcher: the part that was missing. Every chapter is one click
       away from every other chapter, from anywhere in the document. */
    .chapter-switch { display: flex; flex-direction: column; gap: 1px; margin-bottom: 1.25rem; }
    .chapter-switch a {
      display: flex;
      align-items: center;
      gap: 0.55rem;
      padding: 0.4rem 0.6rem;
      border-radius: 0.5rem;
      color: var(--muted);
      text-decoration: none;
      font-size: 0.83rem;
      transition: background 0.15s, color 0.15s;
    }
    .chapter-switch a:hover { background: var(--surface-light); color: var(--text); }
    .chapter-switch a.current { background: var(--accent-glow); color: var(--accent); font-weight: 600; }
    .chapter-switch .num {
      font-family: monospace;
      font-size: 0.7rem;
      opacity: 0.6;
      min-width: 1.1rem;
      text-align: right;
    }

    nav .section-label {
      font-size: 0.65rem;
      font-weight: 600;
      letter-spacing: 0.1em;
      text-transform: uppercase;
      color: var(--muted);
      margin: 1.25rem 0 0.4rem 0.5rem;
    }
    nav .group-label {
      font-size: 0.62rem;
      font-weight: 600;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: #6b6b74;
      margin: 0.9rem 0 0.25rem 0.75rem;
    }

    nav a {
      display: block;
      padding: 0.35rem 0.75rem;
      border-radius: 0.5rem;
      color: var(--muted);
      text-decoration: none;
      font-size: 0.85rem;
      transition: all 0.15s;
    }
    nav #toc a:hover { background: var(--surface-light); color: var(--text); }
    nav #toc a.active { background: var(--accent-glow); color: var(--accent); font-weight: 500; }

    main {
      flex: 1;
      /* A flex item defaults to min-width:auto, which means it refuses to get
         narrower than its widest unbreakable child. On a phone that turned one
         table into a page-wide horizontal scroll. */
      min-width: 0;
      max-width: 820px;
      padding: 3rem 3.5rem;
      margin: 0 auto;
    }

    /* Hero, shown on the front page only */
    .hero {
      margin-bottom: 2.5rem;
      padding-bottom: 2rem;
      border-bottom: 1px solid var(--border);
    }
    .hero-badge {
      display: inline-flex;
      align-items: center;
      gap: 0.4rem;
      background: var(--accent-glow);
      border: 1px solid rgba(132, 204, 22, 0.3);
      color: var(--accent);
      font-size: 0.75rem;
      font-weight: 600;
      padding: 0.25rem 0.75rem;
      border-radius: 99px;
      margin-bottom: 1.25rem;
    }
    .hero h1 {
      font-size: 2.5rem;
      font-weight: 800;
      line-height: 1.15;
      margin-bottom: 0.75rem;
    }
    .hero h1 span { color: var(--accent); }
    .hero p { color: var(--muted); font-size: 1.05rem; max-width: 580px; }

    /* Sections */
    section { margin-bottom: 3rem; }
    /* Jumping to a section must not park its first line under the fixed
       Contents button on a phone. */
    main section[id] { scroll-margin-top: 1rem; }

    h2 {
      font-size: 1.35rem;
      font-weight: 700;
      margin-bottom: 1.25rem;
      padding-bottom: 0.6rem;
      border-bottom: 1px solid var(--border);
      display: flex;
      align-items: center;
      gap: 0.6rem;
    }
    h2 .icon {
      width: 28px;
      height: 28px;
      background: var(--accent-glow);
      border-radius: 6px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 0.9rem;
      flex-shrink: 0;
    }

    h3 {
      font-size: 1rem;
      font-weight: 600;
      color: var(--accent);
      margin: 1.5rem 0 0.6rem;
    }

    p { color: var(--muted); margin-bottom: 0.75rem; }
    strong { color: var(--text); font-weight: 600; }

    /* Cross-references. Scoped to running text rather than set on every `a`,
       because the cards, the chapter list and the search hits are links too and
       are styled as surfaces. Without this a link inside a paragraph came out
       in the browser's default blue, and purple once it had been followed. */
    main p a, main li a, main td a, main .then a, main .do a, .tip a, .warn a {
      color: var(--accent);
      text-decoration: none;
      border-bottom: 1px solid rgba(132, 204, 22, 0.35);
    }
    main p a:hover, main li a:hover, main td a:hover, main .then a:hover, main .do a:hover, .tip a:hover, .warn a:hover {
      border-bottom-color: var(--accent);
    }
    ul, ol { color: var(--muted); }
    main ul, main ol { margin: 0.75rem 0 1rem 1.35rem; }
    main li { margin-bottom: 0.4rem; font-size: 0.9rem; }

    /* Cards */
    .card-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
      gap: 0.75rem;
      margin: 1rem 0;
    }
    .card {
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 1rem 1.1rem;
      transition: border-color 0.15s;
    }
    .card:hover { border-color: rgba(132, 204, 22, 0.3); }
    .card .card-title { font-weight: 600; font-size: 0.9rem; color: var(--text); margin-bottom: 0.3rem; }
    .card .card-desc { font-size: 0.8rem; color: var(--muted); line-height: 1.5; }
    .card .badge {
      display: inline-block;
      font-size: 0.6rem;
      font-weight: 700;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      padding: 0.15rem 0.45rem;
      border-radius: 4px;
      margin-left: 0.4rem;
      vertical-align: middle;
    }
    .badge-beta { background: rgba(59,130,246,0.15); color: #60a5fa; }
    .badge-alpha { background: rgba(245,158,11,0.15); color: #fbbf24; }
    .badge-new { background: rgba(132,204,22,0.15); color: var(--accent); }

    /* OS install */
    .os-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 0.75rem;
      margin: 1rem 0;
    }
    .os-card {
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 1.1rem;
    }
    .os-card .os-name { font-weight: 700; font-size: 0.9rem; margin-bottom: 0.35rem; color: var(--text); }
    .os-card p { font-size: 0.8rem; margin: 0; }

    /* Provider list */
    .provider-list {
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
      margin: 1rem 0;
    }
    .provider-item {
      display: flex;
      align-items: center;
      gap: 0.75rem;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 0.5rem;
      padding: 0.6rem 1rem;
    }
    .provider-dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: var(--accent);
      flex-shrink: 0;
    }
    .provider-dot.muted { background: var(--muted); }
    .provider-name { font-weight: 600; font-size: 0.875rem; color: var(--text); min-width: 130px; }
    .provider-desc { font-size: 0.8rem; color: var(--muted); }
    .provider-rec {
      margin-left: auto;
      font-size: 0.65rem;
      font-weight: 700;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      color: var(--accent);
      background: var(--accent-glow);
      padding: 0.15rem 0.5rem;
      border-radius: 4px;
    }

    /* Code */
    code {
      font-family: 'SF Mono', 'Fira Code', monospace;
      background: var(--surface-light);
      border: 1px solid var(--border);
      padding: 0.15rem 0.45rem;
      border-radius: 4px;
      font-size: 0.8rem;
      color: var(--accent);
    }
    pre {
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 1rem 1.25rem;
      overflow-x: auto;
      margin: 0.75rem 0;
    }
    pre code { background: none; border: none; padding: 0; color: #a3e635; font-size: 0.82rem; }

    /* Tips */
    .tip {
      background: var(--accent-glow);
      border: 1px solid rgba(132, 204, 22, 0.25);
      border-radius: var(--radius);
      padding: 0.9rem 1.1rem;
      margin: 1rem 0;
      font-size: 0.875rem;
      color: var(--text);
    }
    .tip strong { color: var(--accent); }

    .warn {
      background: rgba(245, 158, 11, 0.07);
      border: 1px solid rgba(245, 158, 11, 0.25);
      border-radius: var(--radius);
      padding: 0.9rem 1.1rem;
      margin: 1rem 0;
      font-size: 0.875rem;
      color: var(--text);
    }
    .warn strong { color: #fbbf24; }

    /* Shortcuts */
    .shortcut-list { display: flex; flex-direction: column; gap: 0.4rem; margin: 0.75rem 0; }
    .shortcut-item {
      display: flex;
      align-items: center;
      gap: 1rem;
      padding: 0.5rem 0.75rem;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 0.5rem;
    }
    .shortcut-key {
      font-family: monospace;
      font-size: 0.78rem;
      font-weight: 600;
      color: var(--text);
      background: var(--surface-light);
      border: 1px solid var(--border);
      padding: 0.2rem 0.55rem;
      border-radius: 4px;
      min-width: 80px;
      text-align: center;
    }
    .shortcut-desc { font-size: 0.83rem; color: var(--muted); }

    /* Table */
    table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
    th {
      text-align: left;
      font-size: 0.75rem;
      font-weight: 600;
      letter-spacing: 0.05em;
      text-transform: uppercase;
      color: var(--muted);
      padding: 0.5rem 0.75rem;
      border-bottom: 1px solid var(--border);
    }
    td {
      padding: 0.6rem 0.75rem;
      border-bottom: 1px solid var(--border);
      font-size: 0.875rem;
      color: var(--muted);
      vertical-align: top;
    }
    td:first-child { color: var(--text); font-weight: 500; }
    tr:last-child td { border-bottom: none; }

    footer {
      margin-top: 4rem;
      padding-top: 2rem;
      border-top: 1px solid var(--border);
      font-size: 0.8rem;
      color: var(--muted);
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 1rem;
      flex-wrap: wrap;
    }
    footer a { color: var(--accent); text-decoration: none; }
    footer a:hover { text-decoration: underline; }

    /* ---- Chapter landing page ------------------------------------------- */
    .chapter-lead { margin-bottom: 3.5rem; }
    .lead-kicker {
      font-size: 0.68rem;
      font-weight: 700;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--accent);
      margin-bottom: 0.5rem;
    }
    .chapter-lead h2 {
      font-size: 2rem;
      border-bottom: none;
      padding-bottom: 0;
      margin-bottom: 0.6rem;
      display: block;
    }
    .lead-intro { font-size: 1rem; max-width: 620px; }

    /* The walkthrough that opens every chapter. */
    .walk {
      background: var(--surface);
      border: 1px solid var(--border);
      border-left: 3px solid var(--accent);
      border-radius: var(--radius);
      padding: 1.25rem 1.4rem 1.4rem;
      margin: 1.75rem 0;
    }
    .walk-head {
      display: flex;
      align-items: baseline;
      gap: 0.6rem;
      flex-wrap: wrap;
      margin-bottom: 0.25rem;
    }
    .walk-head h3 { margin: 0; color: var(--text); font-size: 1.05rem; }
    .walk-time {
      font-size: 0.68rem;
      font-weight: 700;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--accent);
      background: var(--accent-glow);
      border-radius: 99px;
      padding: 0.1rem 0.6rem;
    }
    .walk-goal { font-size: 0.85rem; margin-bottom: 1rem; }
    .walk ol { counter-reset: walkstep; list-style: none; margin: 0; padding: 0; }
    .walk ol > li {
      counter-increment: walkstep;
      position: relative;
      padding-left: 2.1rem;
      margin-bottom: 1rem;
      font-size: 0.875rem;
    }
    .walk ol > li::before {
      content: counter(walkstep);
      position: absolute;
      left: 0;
      top: 0.05rem;
      width: 1.45rem;
      height: 1.45rem;
      border-radius: 50%;
      background: var(--accent-glow);
      border: 1px solid rgba(132, 204, 22, 0.35);
      color: var(--accent);
      font-size: 0.72rem;
      font-weight: 700;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .walk .do { color: var(--text); display: block; }
    .walk .say {
      display: block;
      background: #101013;
      border: 1px solid var(--border);
      border-left: 2px solid rgba(132, 204, 22, 0.4);
      border-radius: 6px;
      padding: 0.45rem 0.7rem;
      margin: 0.4rem 0;
      font-family: 'SF Mono', 'Fira Code', monospace;
      font-size: 0.78rem;
      color: #cfe89a;
      white-space: pre-wrap;
    }
    .walk .then {
      display: block;
      font-size: 0.82rem;
      color: var(--muted);
      padding-left: 0.85rem;
      border-left: 2px solid var(--border);
    }
    .walk .then::before {
      content: 'You should see ';
      color: var(--accent);
      font-weight: 600;
    }
    .walk .stuck {
      display: block;
      font-size: 0.8rem;
      color: #d8b46a;
      margin-top: 0.3rem;
    }
    .walk .stuck::before { content: 'If not: '; font-weight: 600; }

    /* Screenshot slot. Renders as a quiet placeholder until the file exists,
       and swaps to the picture the moment it does - no build step, no 404 in
       the middle of a paragraph. The precise shot instruction lives in an HTML
       comment next to each figure and in REPORT-S10-DOCS.md, deliberately NOT
       on screen: a reader must never be shown a production note. */
    figure.shot { margin: 1.25rem 0; position: relative; }
    figure.shot img { display: block; width: 100%; border-radius: var(--radius); border: 1px solid var(--border); }
    figure.shot figcaption { font-size: 0.78rem; color: var(--muted); margin-top: 0.45rem; }
    figure.shot .slot { display: none; }
    /* A pending image is hidden by SHRINKING it, not by display:none. The images
       are loading="lazy", and a lazily loaded image inside a display:none box is
       never fetched - so its load event never fires, the pending class is never
       removed, and a screenshot that exists on disk still shows the placeholder.
       That is how the first six pictures arrived invisible. One pixel, fully
       transparent, still counts as being in the viewport, so lazy loading keeps
       working and the figure flips to the real image the moment it decodes. */
    figure.shot.pending img {
      position: absolute;
      width: 1px;
      height: 1px;
      opacity: 0;
      border: 0;
      pointer-events: none;
    }
    figure.shot.pending figcaption { display: none; }
    figure.shot.pending .slot {
      display: flex;
      align-items: center;
      gap: 0.6rem;
      background: repeating-linear-gradient(45deg, #131316, #131316 10px, #17171b 10px, #17171b 20px);
      border: 1px dashed var(--border);
      border-radius: var(--radius);
      padding: 1.1rem 1.25rem;
      font-size: 0.8rem;
      color: #6b6b74;
    }
    figure.shot.pending .slot b { color: var(--muted); font-weight: 600; }

    /* "In this chapter" */
    .lead-index { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0.5rem; margin: 1.25rem 0 0; }
    .lead-index a {
      display: block;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 0.5rem;
      padding: 0.55rem 0.8rem;
      text-decoration: none;
      color: var(--text);
      font-size: 0.83rem;
      font-weight: 500;
      transition: border-color 0.15s;
    }
    .lead-index a:hover { border-color: rgba(132, 204, 22, 0.4); color: var(--accent); }
    .lead-index a span { display: block; font-weight: 400; font-size: 0.75rem; color: var(--muted); }

    /* Chapters: one at a time. */
    main > section[data-chapter]:not([data-chapter-active]) { display: none; }
    .chapter-nav {
      display: flex;
      justify-content: space-between;
      gap: 16px;
      margin: 40px 0 8px;
      padding-top: 20px;
      border-top: 1px solid var(--border);
      font-size: 14px;
    }
    .chapter-nav a { color: var(--accent); text-decoration: none; }
    .chapter-nav a:hover { text-decoration: underline; }
    .chapter-nav span { color: #6b6b74; }

    /* Front page.
       Stated the way round that survives having no script: with nothing
       running, the body never gets .in-chapter, so the hero and the front page
       stand and no section is hidden - the guide falls back to exactly the one
       long page it used to be, rather than to a blank screen. */
    body.in-chapter #frontpage { display: none; }
    body.in-chapter .hero { display: none; }
    body:not(.in-chapter) .chapter-nav { display: none; }
    .front-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0.75rem; margin: 1.5rem 0; }
    .front-card {
      display: block;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 1rem 1.1rem;
      text-decoration: none;
      transition: border-color 0.15s;
    }
    .front-card:hover { border-color: rgba(132, 204, 22, 0.4); }
    .front-card .fc-num { font-family: monospace; font-size: 0.7rem; color: var(--accent); }
    .front-card .fc-title { display: block; font-weight: 600; font-size: 0.95rem; color: var(--text); margin: 0.15rem 0 0.3rem; }
    .front-card .fc-desc { display: block; font-size: 0.78rem; color: var(--muted); line-height: 1.5; }

    .nav-toggle { display: none; }

    @media (max-width: 900px) {
      nav {
        position: fixed;
        z-index: 40;
        left: 0; top: 0;
        transform: translateX(-100%);
        transition: transform 0.2s;
        box-shadow: 0 0 40px rgba(0,0,0,0.6);
      }
      body.nav-open nav { transform: translateX(0); }
      .nav-toggle {
        display: block;
        position: fixed;
        z-index: 41;
        top: 0.75rem; left: 0.75rem;
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 0.5rem;
        color: var(--text);
        font: inherit;
        font-size: 0.8rem;
        padding: 0.4rem 0.7rem;
        cursor: pointer;
      }
      main { padding: 3.5rem 1.25rem 2rem; }
      main section[id] { scroll-margin-top: 3.5rem; }
      /* Wide content scrolls inside itself rather than widening the page. */
      main table { display: block; width: 100%; overflow-x: auto; }
      .os-grid { grid-template-columns: 1fr; }
      .hero h1 { font-size: 1.9rem; }
      .chapter-lead h2 { font-size: 1.6rem; }
    }
  </style>
</head>
<body>
<button class="nav-toggle" aria-label="Show the table of contents">☰ Contents</button>
<div class="wrapper">

  <!-- Sidebar: chapter switcher, search, and the table of contents -->
  <nav>
    <a class="logo" href="#top">
      <div class="logo-mark">S</div>
      <div>
        <div class="logo-text">Skales</div>
        <div class="logo-version">v<span data-skales-version>12.9.55</span> User Guide</div>
      </div>
    </a>

    <div class="search-box">
      <input id="doc-search" type="search" placeholder="Search the guide" autocomplete="off" spellcheck="false" aria-label="Search the guide" />
      <span class="search-key">/</span>
    </div>

    <div id="search-results"></div>

    <div class="chapter-switch" id="chapter-switch">
      <a href="#ch-start" data-chapter="start"><span class="num">1</span>Getting started</a>
      <a href="#ch-chat" data-chapter="chat"><span class="num">2</span>Chat and agents</a>
      <a href="#ch-code" data-chapter="code"><span class="num">3</span>Code</a>
      <a href="#ch-studio" data-chapter="studio"><span class="num">4</span>Studio and Flow</a>
      <a href="#ch-iris" data-chapter="iris"><span class="num">5</span>Iris and Voice</a>
      <a href="#ch-auto" data-chapter="auto"><span class="num">6</span>Automation</a>
      <a href="#ch-providers" data-chapter="providers"><span class="num">7</span>Providers and models</a>
      <a href="#ch-mobile" data-chapter="mobile"><span class="num">8</span>Mobile and remote</a>
      <a href="#ch-connected" data-chapter="connected"><span class="num">9</span>Connected life</a>
      <a href="#ch-settings" data-chapter="settings"><span class="num">10</span>Settings and security</a>
      <a href="#ch-help" data-chapter="help"><span class="num">11</span>Troubleshooting</a>
    </div>

    <div id="toc">
    <div class="section-label" data-chapter="start">Getting started</div>
    <a href="#ch-start" data-chapter="start">Overview and walkthrough</a>
    <a href="#install" data-chapter="start">Installation</a>
    <a href="#onboarding" data-chapter="start">First Launch</a>
    <a href="#sidebar" data-chapter="start">Home and Chat</a>
    <a href="#addons-view" data-chapter="start">Add-Ons, and the two views of Settings</a>
    <a href="#paired-extensions" data-chapter="start">Chrome and Microsoft Office</a>
    <a href="#plugins" data-chapter="start">Plugins</a>
    <a href="#business" data-chapter="start">Business, and using Skales at work</a>

    <div class="section-label" data-chapter="chat">Chat and agents</div>
    <a href="#ch-chat" data-chapter="chat">Overview and walkthrough</a>
    <a href="#chat" data-chapter="chat">Chat</a>
    <a href="#cost" data-chapter="chat">What a conversation costs</a>
    <a href="#shortcuts" data-chapter="chat">Chat Commands</a>
    <a href="#goal" data-chapter="chat">GOAL</a>
    <a href="#documents" data-chapter="chat">Document Generation</a>
    <a href="#http-request" data-chapter="chat">Calling an API</a>
    <a href="#watch-video" data-chapter="chat">Asking about a video</a>
    <a href="#easter-eggs" data-chapter="chat">Easter Eggs</a>
    <div class="group-label" data-chapter="chat">What it remembers</div>
    <a href="#memory" data-chapter="chat">Memory</a>
    <a href="#companion" data-chapter="chat">The companion, and Conscious</a>
    <a href="#privacy-mode" data-chapter="chat">Privacy Mode</a>
    <a href="#memory-mode" data-chapter="chat">Memory Mode</a>
    <a href="#knowledge-graph" data-chapter="chat">Knowledge Graph</a>
    <a href="#vector-db" data-chapter="chat">External vector database</a>
    <a href="#obsidian" data-chapter="chat">Obsidian vault</a>
    <a href="#auto-compress" data-chapter="chat">Auto-Compress</a>
    <div class="group-label" data-chapter="chat">Agents and teams</div>
    <a href="#agents" data-chapter="chat">Agents</a>
    <a href="#multi-agent" data-chapter="chat">Which multi-agent mode</a>
    <a href="#group-chat" data-chapter="chat">Group Chat</a>
    <a href="#organization" data-chapter="chat">Organization</a>
    <a href="#teams" data-chapter="chat">Teams: rooms with other people</a>
    <a href="#swarm" data-chapter="chat">Devices</a>
    <a href="#agent-sync" data-chapter="chat">Agent-to-Agent Protocol</a>
    <div class="group-label" data-chapter="chat">Skills and tools</div>
    <a href="#skills" data-chapter="chat">Skills</a>
    <a href="#agent-skills" data-chapter="chat">Agent Skills Import</a>
    <a href="#skills-interactive" data-chapter="chat">Custom Skill Interactive UI</a>
    <a href="#skill-sharing" data-chapter="chat">Skill Sharing & Forking</a>
    <a href="#mcp" data-chapter="chat">MCP Server Support</a>

    <div class="section-label" data-chapter="code">Code</div>
    <a href="#ch-code" data-chapter="code">Overview and walkthrough</a>
    <a href="#code" data-chapter="code">Skales Code</a>
    <a href="#chat-code-settings" data-chapter="code">Settings: Chat &amp; Code</a>
    <a href="#assist" data-chapter="code">Settings: Assist</a>
    <a href="#typing-suggestions" data-chapter="code">Typing suggestions</a>
    <a href="#playground" data-chapter="code">Playground</a>
    <a href="#devkit" data-chapter="code">DevKit</a>
    <a href="#github-int" data-chapter="code">GitHub</a>
    <a href="#ftp" data-chapter="code">FTP/SFTP Deploy</a>
    <a href="#moodle" data-chapter="code">Publish to Moodle</a>

    <div class="section-label" data-chapter="studio">Studio and Flow</div>
    <a href="#ch-studio" data-chapter="studio">Overview and walkthrough</a>
    <a href="#studio" data-chapter="studio">Skales Studio</a>
    <a href="#flow" data-chapter="studio">Flow</a>
    <a href="#images" data-chapter="studio">Image & Video Generation</a>
    <a href="#templates" data-chapter="studio">Templates</a>
    <a href="#wordpress" data-chapter="studio">WordPress 2.0</a>

    <div class="section-label" data-chapter="iris">Iris and Voice</div>
    <a href="#ch-iris" data-chapter="iris">Overview and walkthrough</a>
    <a href="#iris" data-chapter="iris">Iris Orbit</a>
    <a href="#voice" data-chapter="iris">Live Voice</a>
    <a href="#narration" data-chapter="iris">Narration</a>
    <a href="#own-speech" data-chapter="iris">Your own speech server</a>
    <a href="#buddy" data-chapter="iris">Desktop Buddy</a>
    <a href="#aipointer" data-chapter="iris">AIPointer ⦿</a>

    <div class="section-label" data-chapter="auto">Automation</div>
    <a href="#ch-auto" data-chapter="auto">Overview and walkthrough</a>
    <a href="#ai-tasks" data-chapter="auto">Planner AI Tasks</a>
    <a href="#planner" data-chapter="auto">Planner</a>
    <a href="#autopilot" data-chapter="auto">Cockpit</a>
    <a href="#projects" data-chapter="auto">Projects</a>
    <a href="#schedule" data-chapter="auto">Schedule (Cockpit)</a>
    <a href="#browser" data-chapter="auto">The browser the agent drives</a>
    <a href="#playbooks" data-chapter="auto">Playbooks</a>
    <a href="#workflow" data-chapter="auto">Workflow</a>
    <a href="#computer-use" data-chapter="auto">Computer Use</a>
    <a href="#download-file" data-chapter="auto">Download File</a>
    <a href="#webhooks" data-chapter="auto">Webhooks</a>

    <div class="section-label" data-chapter="providers">Providers and models</div>
    <a href="#ch-providers" data-chapter="providers">Overview and walkthrough</a>
    <a href="#providers" data-chapter="providers">Providers</a>
    <a href="#which-model" data-chapter="providers">Which model is answering</a>
    <a href="#llm-profiles" data-chapter="providers">LLM Profiles</a>
    <a href="#fallback" data-chapter="providers">Fallback Provider Chain</a>
    <a href="#skales-local" data-chapter="providers">Skales Local</a>
    <a href="#ollama-marketplace" data-chapter="providers">Ollama Model Marketplace</a>
    <a href="#setup-koboldcpp" data-chapter="providers">KoboldCpp Setup</a>
    <a href="#setup-lmstudio" data-chapter="providers">LM Studio Setup</a>
    <a href="#setup-unsloth" data-chapter="providers">Unsloth Desktop Setup</a>

    <div class="section-label" data-chapter="mobile">Mobile and remote</div>
    <a href="#ch-mobile" data-chapter="mobile">Overview and walkthrough</a>
    <a href="#mobile-app" data-chapter="mobile">Skales Mobile</a>
    <a href="#pairing" data-chapter="mobile">Pairing a device</a>
    <a href="#pocket" data-chapter="mobile">Skales Pocket</a>
    <a href="#remote-access" data-chapter="mobile">Remote access</a>

    <div class="section-label" data-chapter="connected">Connected life</div>
    <a href="#ch-connected" data-chapter="connected">Overview and walkthrough</a>
    <a href="#email" data-chapter="connected">Email Integration</a>
    <a href="#calendar" data-chapter="connected">Calendar Integration</a>
    <a href="#web-search" data-chapter="connected">Web Search</a>
    <a href="#bots" data-chapter="connected">Bot Integrations</a>
    <a href="#twitter" data-chapter="connected">Twitter/X Integration</a>
    <a href="#social" data-chapter="connected">Social Media Integration</a>
    <div class="group-label" data-chapter="connected">Your accounts</div>
    <a href="#google-account" data-chapter="connected">One Google account</a>
    <a href="#gdrive" data-chapter="connected">Google Drive</a>
    <a href="#gdocs" data-chapter="connected">Google Docs</a>
    <a href="#places" data-chapter="connected">Google Places</a>
    <a href="#notion" data-chapter="connected">Notion</a>
    <a href="#todoist" data-chapter="connected">Todoist</a>
    <a href="#spotify" data-chapter="connected">Spotify</a>
    <a href="#smarthome" data-chapter="connected">Smart Home</a>
    <div class="group-label" data-chapter="connected">Out in the open</div>
    <a href="#discover" data-chapter="connected">Discover — Social Network for AIs</a>
    <a href="#spark" data-chapter="connected">Spark</a>
    <a href="#wrapped" data-chapter="connected">Skales Wrapped</a>

    <div class="section-label" data-chapter="settings">Settings and security</div>
    <a href="#ch-settings" data-chapter="settings">Overview and walkthrough</a>
    <a href="#timezone" data-chapter="settings">Time zone and location</a>
    <a href="#themes" data-chapter="settings">Themes</a>
    <a href="#accents" data-chapter="settings">Your own accent colours</a>
    <a href="#background" data-chapter="settings">Background and own picture</a>
    <a href="#deep-links" data-chapter="settings">skales:// links</a>
    <a href="#notifications" data-chapter="settings">Notification Center</a>
    <a href="#dashboard" data-chapter="settings">Dashboard</a>
    <a href="#custom-widgets" data-chapter="settings">Custom Widgets</a>
    <div class="group-label" data-chapter="settings">Your data</div>
    <a href="#updates" data-chapter="settings">Updates</a>
    <a href="#export" data-chapter="settings">Export / Import Backup</a>
    <a href="#migration" data-chapter="settings">Migration Importer</a>
    <div class="group-label" data-chapter="settings">Security</div>
    <a href="#safety" data-chapter="settings">Safety Mode</a>
    <a href="#blocked-folders" data-chapter="settings">Folders Skales must never touch</a>
    <a href="#tool-loop" data-chapter="settings">Tool Loop Protection</a>
    <a href="#danger-zone" data-chapter="settings">Danger Zone</a>

    <div class="section-label" data-chapter="help">Troubleshooting</div>
    <a href="#ch-help" data-chapter="help">Overview and walkthrough</a>
    <a href="#first-checks" data-chapter="help">When something will not work</a>
    <a href="#long-runs" data-chapter="help">Long runs, sleep and the disk</a>
    <a href="#logs" data-chapter="help">Logs and Diagnostics</a>
    <a href="#feedback" data-chapter="help">Feedback & Reports</a>

    </div>
  </nav>

  <!-- Main Content -->
  <main>

    <!-- Hero: the front page only -->
    <div class="hero">
      <div class="hero-badge">📖 Official Documentation &middot; v<span data-skales-version>12.9.55</span></div>
      <h1>Skales <span>User Guide</span></h1>
      <p>Your personal AI operating system. Set a goal, automate, create, all running locally on your machine.</p>
    </div>

    <div id="frontpage">
      <p>Eleven chapters. Each one opens with a walkthrough you can follow on a real installation in about three minutes, and every chapter is one click away from every other one in the sidebar. If you know what you are looking for, the search at the top of the sidebar reaches every chapter at once - press <code>/</code> from anywhere.</p>
      <div class="front-grid">
        <a class="front-card" href="#ch-start">
          <span class="fc-num">01</span>
          <span class="fc-title">Getting started</span>
          <span class="fc-desc">Install it, answer four questions, get a first answer out of it.</span>
        </a>
        <a class="front-card" href="#ch-chat">
          <span class="fc-num">02</span>
          <span class="fc-title">Chat and agents</span>
          <span class="fc-desc">The conversation, what it remembers, the tools it can reach, and the agents and teams you build on top of it.</span>
        </a>
        <a class="front-card" href="#ch-code">
          <span class="fc-num">03</span>
          <span class="fc-title">Code</span>
          <span class="fc-desc">A window of its own for working on a repository, with a leash you choose per session.</span>
        </a>
        <a class="front-card" href="#ch-studio">
          <span class="fc-num">04</span>
          <span class="fc-title">Studio and Flow</span>
          <span class="fc-desc">Pictures, video, voice, music, and the conversational design workspace that keeps working on a brief with you.</span>
        </a>
        <a class="front-card" href="#ch-iris">
          <span class="fc-num">05</span>
          <span class="fc-title">Iris and Voice</span>
          <span class="fc-desc">Talking to Skales instead of typing at it, and the two assistants that live on your screen.</span>
        </a>
        <a class="front-card" href="#ch-auto">
          <span class="fc-num">06</span>
          <span class="fc-title">Automation</span>
          <span class="fc-desc">Work that happens on a schedule, in the background, or on a website instead of in a chat.</span>
        </a>
        <a class="front-card" href="#ch-providers">
          <span class="fc-num">07</span>
          <span class="fc-title">Providers and models</span>
          <span class="fc-desc">Where the answers come from, how to know which model is answering, and how to run one on your own machine.</span>
        </a>
        <a class="front-card" href="#ch-mobile">
          <span class="fc-num">08</span>
          <span class="fc-title">Mobile and remote</span>
          <span class="fc-desc">Your phone as a second window onto the Skales running at home, and the two ways it gets there.</span>
        </a>
        <a class="front-card" href="#ch-connected">
          <span class="fc-num">09</span>
          <span class="fc-title">Connected life</span>
          <span class="fc-desc">Mail, calendar, messengers, the accounts you already have, and the feed Skales publishes to.</span>
        </a>
        <a class="front-card" href="#ch-settings">
          <span class="fc-num">10</span>
          <span class="fc-title">Settings and security</span>
          <span class="fc-desc">Making it look like yours, keeping it up to date, and deciding what it is allowed to do.</span>
        </a>
        <a class="front-card" href="#ch-help">
          <span class="fc-num">11</span>
          <span class="fc-title">Troubleshooting</span>
          <span class="fc-desc">The five checks that answer most of it, and where to send what they do not.</span>
        </a>
      </div>
      <div class="tip"><strong>New here?</strong> Chapter 1 takes you from a downloaded file to two answers on screen. <strong>Something not working?</strong> Chapter 11 has the five checks that answer most of it.</div>
    </div>

    <!-- ===== Chapter: Getting started ===== -->
    <section id="ch-start" class="chapter-lead">
      <div class="lead-kicker">Chapter 1</div>
      <h2>Getting started</h2>
      <p class="lead-intro">Skales runs on your computer. There is no account to make and nothing to sign up for, and the whole of this chapter is the distance between a downloaded file and an answer on screen.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: from installer to first answer</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">At the end of this you will have Skales running, one provider configured, and two answers on screen: one plain, one that used a tool.</p>
        <ol>
          <li>
            <span class="do">Download the build for your system from <strong>skales.app</strong> and open it. On macOS, right-click the app and choose <strong>Open</strong> the first time.</span>
            <span class="then">the setup screen, starting with the language list.</span>
          </li>
          <li>
            <span class="do">Pick your language, then a provider. If you have no API key at all, pick <strong>Skales IQ</strong>: it needs no key and it includes tools and vision.</span>
            <span class="then">the model list filling itself in under the provider.</span>
            <span class="stuck">the list stays empty, the key was refused. Check it against the provider's own site from the same connection before changing anything in Skales, and read <a href="#regional">Which providers work where</a>.</span>
          </li>
          <li>
            <span class="do">Answer <strong>What should Skales do for you</strong>. Pick the one that is closest; you are choosing which add-ons start switched on, not a mode you are locked into.</span>
            <span class="then">a sidebar built from that answer rather than a sidebar with thirty entries in it.</span>
          </li>
          <li>
            <span class="do">You land in Chat. Ask it something plain:</span>
            <span class="say">Summarise in five bullet points what you can do for me on this computer.</span>
            <span class="then">the answer streaming in, and under the composer a line naming the model that is answering and how much of its context window the conversation is using.</span>
          </li>
          <li>
            <span class="do">Now ask for something it has to go and get, so you see a tool run:</span>
            <span class="say">Search the web for the three most recent reviews of Skales and give me the links.</span>
            <span class="then">a search step appear inline above the answer, which you can open to see exactly what was asked and what came back.</span>
            <span class="stuck">nothing happens, web search is one of the nine things that are always on, so it is a provider problem rather than a setting. The <a href="#first-checks">first five checks</a> are the fastest way through it.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT start-onboarding-work.png
           Onboarding, the "What should Skales do for you" step (step 5 of 5).
           Frame: whole app window, 1440x900, dark theme, default accent.
           Must show: the five kinds of work as cards, one of them selected, and the
           individual add-on switches underneath it on the same screen.
           Do NOT show: any API key, even partially.
      -->
      <figure class="shot pending">
        <img src="img/start-onboarding-work.png" alt="The last setup question decides what the sidebar shows." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; The last setup question decides what the sidebar shows.</div>
        <figcaption>The last setup question decides what the sidebar shows.</figcaption>
      </figure>

      <!-- SHOT start-first-answer.png
           Chat, immediately after the answer to "Summarise in five bullet points...".
           Frame: whole app window, 1440x900, dark theme, sidebar visible.
           Must show: the composer, the readout line under it naming the model and the
           context use, the status pill, and one short finished answer above.
           The model named in the readout must be the model that actually answered -
           this shot doubles as the picture of the 12.7.1 fix.
      -->
      <figure class="shot pending">
        <img src="img/start-first-answer.png" alt="A first answer, with the model readout under the composer." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; A first answer, with the model readout under the composer.</div>
        <figcaption>A first answer, with the model readout under the composer.</figcaption>
      </figure>

      <p>What follows in this chapter: what happens on first launch, how the sidebar is put together, and the two controls that decide how much of Skales you have to look at.</p>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#install">Installation</a>
        <a href="#onboarding">First Launch</a>
        <a href="#sidebar">Home and Chat</a>
        <a href="#addons-view">Add-Ons, and the two views of Settings</a>
        <a href="#paired-extensions">Chrome and Microsoft Office</a>
        <a href="#plugins">Plugins</a>
        <a href="#business">Business, and using Skales at work</a>
      </div>
    </section>

    <section id="install">
      <h2><span class="icon">💾</span> Installation</h2>
      <p>Download Skales from <strong>skales.app</strong>. Choose the build for your operating system.</p>

      <div class="os-grid">
        <div class="os-card">
          <div class="os-name">🍎 macOS</div>
          <p>Code-signed with an Apple Developer ID and notarized by Apple, so it opens by double-clicking like any other app. An older download that predates notarization still needs right-click → <strong>Open</strong> the first time.</p>
        </div>
        <div class="os-card">
          <div class="os-name">🪟 Windows</div>
          <p>Standard <code>.exe</code> installer. No administrator rights required. Windows Defender may show a SmartScreen warning on first run — click <strong>More info → Run anyway</strong>.</p>
        </div>
        <div class="os-card">
          <div class="os-name">🐧 Linux</div>
          <p>Distributed as <code>.AppImage</code>. Make it executable first:</p>
          <pre><code>chmod +x Skales.AppImage
./Skales.AppImage</code></pre>
        </div>
      </div>

      <div class="tip">
        <strong>💡 Tip:</strong> Skales runs entirely on your machine. No account required. Your data stays local — conversations, memory, and settings are stored in your home folder under <code>~/.skales-data/</code>.
      </div>
    </section>

    <section id="onboarding">
      <h2><span class="icon">🚀</span> First Launch</h2>
      <p>The <strong>onboarding wizard</strong> guides you through setup on first
      launch. It starts with one question that shapes everything after it -
      whether you are new to AI or already at home with it. Newcomers get every
      technical term explained in place and a guided provider choice;
      experienced users get dense screens and can skip whole blocks.</p>
      <p>The run then settles the everyday in small steps, each with a live
      preview: theme (Skales X, Classic or Flat), light/dark/system, accent
      tone, your city and weather, notifications, a voice you can listen to
      before choosing, safety mode and telemetry. Feature cards introduce
      AIPointer, the desktop buddy, Iris and Studio and switch them on right
      there, and a QR card pairs your phone without leaving setup - the
      allow/deny confirmation appears inside the wizard. The whole run works
      offline, survives a restart exactly where you stopped, and ends on a
      card that shows how much of Skales is already set up. You can replay it
      any time from <strong>Guide</strong> or Settings &gt; General &gt; Profile &amp; Region - answers
      arrive prefilled, and finishing changes only what you actually edited.</p>
      <p>The classic steps are still part of the run:</p>
      <ol style="margin: 1rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Language</strong> — Choose from 12 supported languages (EN, DE, ES, FR, RU, ZH, JA, KO, PT, VI, HR, TR)</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Provider</strong> — Select your AI provider (OpenRouter recommended)</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">API Key</strong> — Paste your API key. Keys are stored locally in encrypted settings.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Model</strong> — Pick a default model. You can switch anytime in Settings or via <code>/model</code> in chat.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">What Skales should do for you</strong> — Five kinds of work: Generative AI, Audio AI, Coding AI, Business agent, Personal agent. Picking one switches on the add-ons that belong to it, and you can change any individual switch on the same screen. The sidebar and the Settings page are then built from that answer, so you see what you chose and not the rest.</li>
      </ol>
      <h3>The intro, and the two moments</h3>
      <p>Pressing the last button of the setup does not drop you straight into an
      empty chat. Four short cards play first — what Studio makes and where it can
      go, agents ticking a goal off by themselves, Iris listening and answering,
      and the Guide as the door to everything else. It lasts about fifteen
      seconds, one press skips it from any card, and it is never shown a second
      time by itself. With <em>reduced motion</em> switched on in your system, the
      cards stand still and you press <strong>Next</strong> instead. To watch it
      again, open <strong>Guide</strong> and use <strong>Watch the intro</strong>.</p>
      <p>Two more cards appear once each, and only at the moment they are an
      answer rather than a tour: when your first Skales Visual is finished, Skales
      offers to put it in the Discover feed; and when a run that took longer than
      two minutes finishes while you are somewhere else, it offers to tell you
      next time. Both can be closed without being asked again, both stay quiet
      while notifications are muted or in your quiet hours, and the second one is
      only offered while notifications are actually switched off.</p>
      <p>After onboarding you land directly in <strong>Chat</strong> — ready to go.
      The former <strong>Docs</strong> entry in the sidebar is now
      <strong>Guide</strong>: the same handbook plus "I want to..." paths that
      show live whether your machine is ready for each of them.</p>
      <p>Nothing in that last step is final, and nothing is lost by it. Chat, memory, the planner, tasks, schedule and Discover are always there and are not on the list, because they are not a choice. Everything else is one switch on the <strong>Add-Ons</strong> page, and the <strong>Advanced</strong> view of Settings always shows every setting there is. An existing installation is offered the same screen once, with everything it already had left switched on.</p>

      <h3>Permissions your system may ask for</h3>
      <p style="color: var(--muted); font-size: 0.875rem;">Each prompt comes from your operating system, and Skales asks only for what the feature you are using needs. If you never use a feature, its prompt never appears.</p>
      <ul style="margin: 0.75rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Microphone.</strong> Asked the first time you start a voice message, so your speech can be turned into text. Skales never records on its own.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Accessibility / input control.</strong> Only if you turn on the on-screen assistant, which can move the pointer and type for you. macOS phrases this as "control this computer" and Windows may flag the global shortcut; grant it on macOS under System Settings, Privacy &amp; Security, Accessibility. Skales acts only when you start it, never in the background.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Local network.</strong> Only if you pair a phone, delegate to a second machine (Devices) or scan your own network. Skales looks on your own network only, and each of those is something you start.</li>
      </ul>
      <p style="color: var(--muted); font-size: 0.875rem;">You can review or revoke any of these later in your system settings, and Skales keeps working without the ones you skip.</p>
    </section>

    <section id="sidebar">
      <h2><span class="icon">🗂️</span> Home and Chat</h2>
      <p>There are exactly two sidebars, and the switch at the top decides which one you are looking at. <strong>Home</strong> is the suite: the eight surfaces the work happens on, then the system block. <strong>Chat</strong> hands the whole column to the conversation and opens the chat landing page. The point is that a sidebar with thirty entries is a sidebar nobody reads.</p>
      <ul style="margin: 0.75rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Home, Main.</strong> Dashboard, Chat, Code, Studio, Teams, Planner, Iris Orbit, Memory, Skales Mobile — and at the end, quietly, Discover and Wrapped. Cockpit is not in this list: it belongs to the conversation that produced the work, so it opens from the Chat column instead. The <code>/autopilot</code> address answers exactly as before.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Home, Plugins.</strong> Its own heading between Main and System, and it is there on every machine from the first launch - the shelf itself, and under it every plugin you installed or built. See <a href="#plugins">Plugins</a>.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Home, System.</strong> Guide, Add-Ons, Custom Skills, Custom Widgets, and Templates when its add-on is on. Your own widgets get their own heading above it as soon as you have one.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Chat.</strong> Four rows and nothing else: <strong>+New</strong>, <strong>Agents</strong>, <strong>Cockpit</strong>, and a <em>More</em> block that folds out into History, Group Chat and Add-Ons &amp; Skills. Tasks is not a row of its own any more - it is a tab of the Cockpit, and one thing belongs in one place. Everything under More opens in a window over the app rather than taking you away from the conversation, and More stays closed until you open it, so what you look at every day is three rows and your conversations.</li>
      </ul>
      <p><strong>The system row sits in the foot, not in the list.</strong> Under the navigation is a small toolbar - notifications, dark/light, Settings, <strong>System</strong>, and the red stop for the server. System opens as a popup rather than a page, because reading a log is a glance and a glance must not throw away what you were working on: in it are <em>Update</em>, <em>Report a bug</em>, <em>Diagnose</em> (the logs), the <em>Guide</em>, and DevKit while DevKit is running.</p>
      <p><strong>Collapsed, the column is one button.</strong> The arrow that closes the sidebar stands where the logo stood, so the press that closed it and the press that opens it are the same spot - and that is all there is: no icon rail, no half-legible strip of pictures, no rows. A narrow second navigation nobody chose is exactly the width that collapsing was meant to give back.</p>
      <p>On the themes with a full sidebar (Slate, Skales-X, Classic) the Chat column also appears on its own while a conversation is open, and Home is the way back. The chat landing page always keeps whichever side you chose — the chat column belongs to a conversation, not to the chat address.</p>
      <p><strong>Both New buttons do the same thing.</strong> The <strong>+New</strong> row in the chat column and the <strong>+</strong> at the right of the chat header both take you to the chat landing page, with the composer in the middle and the suggestions under it. Deleting the conversation you currently have open, and <em>New chat</em> in the History panel, land in the same place. Previously one of them emptied the open conversation where it stood, which left a screen of nothing; and reloading appeared to fix it only because the old conversation came back. <strong>Reloading on the landing page now keeps you on the landing page.</strong></p>
      <p>Some surfaces no longer have an entry of their own: <strong>Projects and Workflow</strong>, and before them Lio AI, WordPress and Spaces. Organization, Browser and Playbooks have their doors back, under Tools and in the chat column&rsquo;s More block. <strong>No capability was removed.</strong> Their add-ons still work, their pages still answer at their own addresses, and the tools they bring to the chat — the WordPress family, the browser the agent drives with its logged-in profile, the project tools, the recorded runs an agent can replay, the delegation to a named team — are untouched and can still be switched on from the Add-Ons page. What went away is the door in the menu, and the Add-Ons page says so on each of those cards rather than promising a place you will not find. The other direction holds too: a surface you switch <em>off</em> on the Add-Ons page takes its menu entry with it &mdash; out of both sidebars, out of Cmd+K and out of your pins &mdash; and its page then tells you where the switch is instead of drawing itself anyway. <strong>Cmd/Ctrl+B</strong> folds and unfolds the sidebar, and it stays the way you left it after a restart. The Guide, Diagnose, Update and Report Bug live together behind the System button in the sidebar foot. A few surfaces went further and are gone as screens altogether: Codework is a preset inside <a href="#code">Skales Code</a> now rather than a page of its own, and the network scanner, Cast, the Business page and Datasets have no screen at all any more.</p>
      <p><strong>The sidebar shows who is working.</strong> While agents or a team are running, the entries that lead to them carry a small live row: who is at it, who is waiting for you, and who has just finished, which fades out shortly after. It is a reading and nothing more — nothing pops up, nothing makes a sound, and nothing is left behind for you to dismiss. Close Skales and reopen it and the row shows what is really running, never a leftover from before.</p>
      <p>An entry whose add-on is switched off is simply not in the list. Nothing is lost either way: the side you were on is remembered, and the page you are actually on is always visible in the sidebar, so a link or a finished task can never land you somewhere the menu does not show.</p>
    </section>

    <section id="addons-view">
      <h2><span class="icon">🧩</span> Add-Ons, and the two views of Settings</h2>
      <p>Skales can do a great many things, and nobody uses all of them. Two controls decide how much of that you have to look at, and neither of them turns anything off that you switched on.</p>

      <h3>The Add-Ons page</h3>
      <p><strong>Sidebar → System → Add-Ons.</strong> One card per add-on, one switch each. An add-on that has a page of its own puts that page in the sidebar while it is on and takes it away again when it is off; an add-on that needs an account says which key it needs and where to put it.</p>
      <p>Nine things are not on the list because they are not a choice: weather, summarizing, documents, web search, the system monitor, local file chat, screenshots and vision, VirusTotal and Wrapped. Switching those off would make Skales worse at being Skales, and nobody came to a setup screen to decide them.</p>
      <p>A few cards are no longer offered to somebody setting up — Spaces, Templates, Lio AI, Organization, Projects, Workflow, Playbooks. They still work for anybody who has one switched on, and every add-on that also gives the agent tools stays on the list, because the menu is what was trimmed and never a capability. A card whose surface has no menu entry says so on itself: a <strong>Parked</strong> mark and one line naming what the switch still gates and where the page answers, rather than a promise of an entry you would then go hunting for.</p>
      <p>The five categories in the setup screen are a shortcut into the same switches, not a mode. Picking <em>Coding AI</em> preselects that bundle; what gets stored is the add-ons, not the category.</p>

      <h3>Standard and Advanced</h3>
      <p>The switch at the top of <strong>Settings</strong> chooses between two views of the same page.</p>
      <ul style="margin: 0.75rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Standard</strong> shows the settings your add-ons actually need, plus the ones everybody needs. A section that belongs to an add-on you have not switched on is not there.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Advanced</strong> shows every setting there is, exactly as before.</li>
      </ul>
      <p>It is a <em>view</em>, not a state. Anything you switched on in Advanced stays on in Standard — it is only out of sight. Search reaches both views, so typing what you are looking for finds it whichever one you are in, and a tab that would open onto an empty page in Standard is not offered.</p>
      <p>The Advanced view is not a list of dangerous things. Diagnostics, Updates, Export/Import and the data controls all sit in the <strong>Advanced tab</strong> and are all shown in the Standard view, because those are things ordinary users are sent to.</p>

      <h3>Changing your mind</h3>
      <p><strong>Settings → System → About Skales</strong> runs the add-on screen again. Nothing is deleted by it: chats, keys and settings stay exactly as they are, and only what is shown changes.</p>
      <p style="color: var(--muted); font-size: 0.875rem;">Add-Ons is the list of what Skales already brings. What other people built, and what you build yourself, lives one page further on: see <a href="#plugins">Plugins</a>.</p>
    </section>

    <section id="paired-extensions">
      <h2><span class="icon">🧩</span> Chrome and Microsoft Office</h2>
      <p>Skales can sit next to your work: as a side panel in Chrome, and as a task pane in Word, Excel, PowerPoint and Outlook. Both are clients of the Skales running on your computer. The models, your keys, the conversations and every approval stay in Skales; the panel and the pane carry no API key. They use the same encrypted connection as a paired phone, directly or over the encrypted relay, and you pair each one once in <strong>Settings → Extensions → Chrome &amp; Microsoft Office</strong>. That page also lists everything that is paired, with <strong>Disconnect</strong> beside each entry. The step-by-step page with the downloads is <a href="extensions.html">Install and connect the extensions</a>.</p>

      <h3>Connect the Chrome side panel</h3>
      <ol>
        <li>Open <a href="extensions.html">the extensions page</a> (Settings → Extensions → Chrome &amp; Microsoft Office → <strong>Installation instructions</strong>), download the Chrome extension and unzip it.</li>
        <li>In Chrome open <code>chrome://extensions</code>, switch on <strong>Developer mode</strong>, choose <strong>Load unpacked</strong> and pick the unzipped <code>chrome</code> folder.</li>
        <li>Open Skales from the extension's button. The side panel shows its own origin, <code>chrome-extension://</code> followed by 32 letters. Copy it.</li>
        <li>In Skales, under Settings → Extensions → Chrome &amp; Microsoft Office, choose <strong>Chrome</strong>, paste the exact origin and press <strong>Generate code</strong>. The code works once and for five minutes.</li>
        <li>In the panel, enter the Skales server address and the code, then press <strong>Pair</strong>. On this computer the address is the one Skales runs on, for example <code>http://127.0.0.1:3000</code>; a remote address needs HTTPS.</li>
      </ol>
      <p>Chrome grants one permission only at installation: the debugger permission, which real key presses need. Everything else - access to a site, bookmarks, history, downloads - is asked for the first time a tool needs it: the panel shows <strong>Allow Chrome access</strong>, and Chrome remembers what you allowed.</p>

      <h3>Connect Word, Excel and PowerPoint</h3>
      <p>Office only loads add-ins from an HTTPS address, so the Office download brings a small local helper that serves the task pane over HTTPS and passes only the extension traffic on to Skales. You need Node and a trusted certificate for <code>localhost</code>; a company certificate works, or one made with <code>mkcert</code> (<code>mkcert -install</code>, then <code>mkcert -cert-file localhost.pem -key-file localhost-key.pem localhost 127.0.0.1 ::1</code>). Keep the private key out of any shared folder.</p>
      <ol>
        <li>Download the Office add-in from <a href="extensions.html">the extensions page</a> and unzip it.</li>
        <li>In the unzipped folder run <code>node office/scripts/serve.mjs --cert=/path/localhost.pem --key=/path/localhost-key.pem --server=http://127.0.0.1:3000 --port=3443</code>. It needs no installation and prints the task pane address.</li>
        <li>Open <code>https://localhost:3443/office/taskpane.html</code> in a browser once. If the certificate is trusted it opens and says that an Office host is needed.</li>
        <li>Load <code>office/manifest.xml</code> into Office:
          <ul>
            <li><strong>Office on the web:</strong> Add-ins → More add-ins → My add-ins → <strong>Upload my add-in</strong>, where your organisation allows it.</li>
            <li><strong>Mac:</strong> copy the manifest into the app's <code>wef</code> folder - <code>~/Library/Containers/com.microsoft.Word/Data/Documents/wef/</code>, the same under <code>com.microsoft.Excel</code> and <code>com.microsoft.Powerpoint</code> - then open it from Insert → Add-ins → My Add-ins.</li>
            <li><strong>Windows:</strong> Microsoft's way for desktop Office is a shared-folder catalogue: share the folder that holds the manifest, add its network path under File → Options → Trust Center → Trust Center Settings → Trusted Add-in Catalogs with "Show in Menu" ticked, restart Office and open it from My Add-ins → Shared Folder (<a href="https://learn.microsoft.com/en-us/office/dev/add-ins/testing/sideload-office-add-ins-for-testing">Microsoft's sideload guide</a>). Office on the web works the same on Windows as anywhere else.</li>
          </ul></li>
        <li>In Skales, under Settings → Extensions → Chrome &amp; Microsoft Office, choose <strong>Microsoft Office</strong>, enter <code>https://localhost:3443</code> and press <strong>Generate code</strong>. In the task pane keep the server address <code>https://localhost:3443</code>, paste the code and pair.</li>
      </ol>
      <p>Office is paired once. New documents and new panes get their own connection under that pairing without another code; a document keeps only an id, never a key. The pane can also open itself in new Word documents, PowerPoint decks and copies Skales makes (<strong>Enable automatic Skales opening</strong>), where Office supports it. With a port or a domain other than <code>localhost:3443</code>, change it in both manifests, in the helper command, in the pairing origin and in the Microsoft redirect address together.</p>

      <h3>Connect Outlook and Microsoft 365</h3>
      <p>Outlook uses its own manifest, <code>office/manifest-outlook.xml</code>: Add-Ins for Outlook → My add-ins → Add a custom add-in → <strong>Add from File</strong>. The pane then appears in messages you read or write and in appointments, and pairs exactly like Word. Reading the open message works straight away. Searching the mailbox, drafts and replies, attachments and the calendar go through Microsoft Graph and need a Microsoft 365 connection:</p>
      <ol>
        <li>An administrator registers an application in Microsoft Entra for the intended accounts, with a <strong>Single-page application</strong> redirect address <code>https://localhost:3443/office/oauth.html</code> (or your own HTTPS origin) and no client secret.</li>
        <li>It gets the delegated Graph permissions <code>User.Read</code>, <code>Mail.ReadWrite</code>, <code>Mail.Send</code> and <code>Calendars.ReadWrite</code>, with tenant consent where your organisation requires it.</li>
        <li>In the Outlook pane choose <strong>Connect Microsoft 365</strong>, enter the application (client) ID and the tenant ID or <code>common</code>, and sign in with Microsoft. The client ID is public configuration, not a key.</li>
      </ol>
      <p>The Microsoft tokens live only in the pane's memory: after closing or reloading the pane, Outlook asks you to sign in again, while the pairing and your conversations stay. To try the Outlook tools without touching a real mailbox, use a separate Microsoft 365 test account or test tenant with mail and appointments you can throw away.</p>

      <h3>What the extensions can do</h3>
      <p>Both bring the Skales chat with model choice, attachments and pictures, tool progress, Stop and the usual approval cards, and both restore their conversations from Skales when reopened. The tools run in your own browser or document:</p>
      <ul>
        <li><strong>Chrome:</strong> tabs and tab groups, navigation, page text, element references, selections, tables and forms; find, click, type, select, fill and submit; keys and scrolling; screenshots of a tab or a region; downloads and uploads; bookmarks and history.</li>
        <li><strong>Word:</strong> read the text, insert text, paragraphs, tables, pictures and HTML, replace, styles, headings, fonts and lists, comments and tracked changes, new documents.</li>
        <li><strong>Excel:</strong> values and formulas, tables, charts, PivotTables, formatting, several worksheets and numeric analysis.</li>
        <li><strong>PowerPoint:</strong> read slides, add, move and delete slides, text, pictures, speaker notes and whole new decks.</li>
        <li><strong>Outlook:</strong> the open message, mailbox search, drafts, replies and forwards, attachments, calendars and appointments. Sending is its own step under your approval; a draft or a reply never sends by itself.</li>
      </ul>

      <h3>Limits of the Chrome and Office extensions</h3>
      <ul>
        <li><strong>64 MB per file or result.</strong> Screenshots, pages, documents and attachments larger than one message travel in pieces; anything over 64 MB is refused with that reason instead of waiting for a timeout.</li>
        <li><strong>Speaker notes are written into a copy.</strong> Office cannot edit speaker notes in place, so Skales writes them into an updated copy of the deck that opens as a new presentation, and says so.</li>
        <li><strong>A new document is a new target.</strong> After Skales opens a new document or a copy, the original pane refuses further changes to the original until you choose <strong>Continue in original document</strong>. To work in the new one, open Skales in its pane.</li>
        <li><strong>One app per pane.</strong> A Word tool needs a Word pane; asked from Excel it answers which app it needs.</li>
        <li><strong>Things that stay with you.</strong> Passwords, one-time codes and payment details are typed by you. Chrome's own pages and protected store pages cannot be controlled.</li>
        <li><strong>Element references expire.</strong> A reference belongs to one page load; after a navigation or reload Skales reads the page again.</li>
        <li><strong>Two minutes per step.</strong> A tool that gets no answer from the panel or pane in that time is stopped and reported; check the page or document before repeating an action, because its outcome may be unknown.</li>
      </ul>

      <h3>When an extension does not connect</h3>
      <table>
        <thead><tr><th>What you see</th><th>What to do</th></tr></thead>
        <tbody>
        <tr><td>Pairing code is invalid, expired, or belongs to another origin.</td><td>Generate a new code - it lasts five minutes and works once - and check that the origin in Settings is exactly the one the panel shows.</td></tr>
        <tr><td>Enter the exact extension origin.</td><td>Chrome takes <code>chrome-extension://</code> plus the 32-letter id; Office takes the HTTPS origin of its pane, such as <code>https://localhost:3443</code>.</td></tr>
        <tr><td>This device identity is already paired. Disconnect it first.</td><td>Disconnect the old entry in Settings → Extensions → Chrome &amp; Microsoft Office, then pair again.</td></tr>
        <tr><td>Use HTTPS for a remote server, or HTTP on localhost.</td><td>Enter <code>http://127.0.0.1:3000</code> on this computer, or an HTTPS address for Skales elsewhere.</td></tr>
        <tr><td>Office needs HTTPS.</td><td>Use the helper's address <code>https://localhost:3443</code> as the server in the pane, not the plain Skales address.</td></tr>
        <tr><td>The pane stays blank, or the certificate is refused.</td><td>Open <code>https://localhost:3443/office/taskpane.html</code> in a browser; if it is not trusted, install the certificate's trust (for example <code>mkcert -install</code>) and restart the helper.</td></tr>
        <tr><td>Microsoft Office.js could not load.</td><td>The pane needs to reach <code>appsforoffice.microsoft.com</code>; check the connection and reopen the pane.</td></tr>
        <tr><td>Skales server is unreachable / The encrypted relay is unreachable.</td><td>Start Skales. Without a direct connection the extension uses the relay, which needs remote access switched on in Skales.</td></tr>
        <tr><td>Extension is not connected / Extension is offline.</td><td>Open the panel or pane and press <strong>Reconnect</strong>.</td></tr>
        <tr><td>Skales needs Chrome access for this action.</td><td>Open the side panel and press <strong>Allow Chrome access</strong>.</td></tr>
        <tr><td>This tool needs Excel; the connected task pane is in Word.</td><td>Open Skales in the app the tool belongs to.</td></tr>
        <tr><td>Microsoft 365 is not connected / Microsoft sign-in expired.</td><td>Use <strong>Connect Microsoft 365</strong> in the Outlook pane; a missing application ID or consent is named with its reason.</td></tr>
        <tr><td>This Office pairing was revoked.</td><td>Pair Office again from Settings with a new code.</td></tr>
        <tr><td>Extension did not answer in time.</td><td>Look at the page or document first, then check the panel for a permission or connection message before trying again.</td></tr>
        </tbody>
      </table>

      <h3>Disconnect an extension</h3>
      <p>Settings → Extensions → Chrome &amp; Microsoft Office lists every paired extension with <strong>Disconnect</strong>. It removes the extension's access and its pending tool calls at once; for Office it also ends every document pane under that pairing. Once no paired extension uses an origin, that origin can no longer reach Skales. Each extension is independent, so disconnecting Office leaves Chrome and your phone connected. In the panel itself, <strong>Disconnect</strong> stays disconnected until you press Reconnect, closing the panel does not disconnect anything, and <strong>Disconnect Microsoft 365</strong> in Outlook forgets only the Microsoft sign-in.</p>
    </section>
    <section id="plugins">
      <h2><span class="icon">🔌</span> Plugins</h2>
      <p>A plugin is a tool of its own inside Skales. It is the step above a widget: a widget is a card on the Dashboard, a plugin is a <strong>page</strong> - its own entry in the sidebar, its own icon, its own screen, and its own storage that nothing else writes into.</p>

      <h3>Where they live</h3>
      <p>Plugins get a <strong>Plugins</strong> block of their own in the sidebar, between your main pages and the system pages, so a plugin is never buried in a settings tab. The block is there from the first launch, with the shelf itself in it and your installed plugins underneath - a heading that only appeared once you already had a plugin would leave a fresh install with no door to them at all. It is also not on the Add-Ons page: the things under this heading are yours, and a switch that could hide them would hide your own work behind a setting you do not remember setting.</p>

      <h3>Get plugins</h3>
      <p>At the top of <strong>Sidebar → Plugins</strong> is the gallery. It lists the published catalogue and, underneath it, the plugins that ship inside Skales itself. Two of those are there from the first launch: <strong>Daily Brief</strong>, which writes you a short morning brief at 07:30 from your open tasks and reminders, and <strong>Reading Stack</strong>, a list of the links you meant to get back to - that one needs no key, no provider and no connection and is useful the moment it is installed.</p>
      <p>Every card shows three plain facts before you touch it: whether it reaches the network, whether it can see anything outside its own folder, and how many tools it may call. Click the card to read the whole thing - the description, the permissions in words, what kind of plugin it is, and where it is published from. Click <strong>Install</strong> and it is on the shelf and in the sidebar. That is the whole journey: one click to read, one click to have it.</p>
      <p>A plugin marked <strong>By Skales</strong> is written and maintained by us and is inside the app, so installing it downloads nothing. Everything else comes from its own author's repository, is fetched from the release they published, and is checked against the checksum they published beside it. The small <strong>?</strong> next to the heading says the same thing in two sentences, and it is worth reading once: community plugins are not reviewed or maintained by Skales, and they run with exactly the permissions written on their card.</p>
      <p>The catalogue itself is a public directory, <a href="https://github.com/skalesapp/plugins">github.com/skalesapp/plugins</a>, and anybody can publish into it. What is listed there is a <em>pointer</em>: who publishes the plugin, which release it is served from, which version it is and what it asks for. The code is never copied into the directory, so what lands on your machine comes from the author who wrote it, and the same page tells you how to add your own.</p>
      <p>If the catalogue cannot be reached - no connection, or the registry is down - the page shows the last copy it fetched with the date it was fetched on, and the bundled plugins are there either way. It is never blank.</p>

      <h3>Start from a template</h3>
      <p>Under the catalogue, <strong>Start from a template</strong> offers small plugins that already work and are meant to become yours: <strong>List</strong>, a page that keeps a list with undo and needs nothing set up; <strong>Ask</strong>, a page that asks your model and keeps the last answers; <strong>Weekly review</strong>, an agent that writes a short review of your tasks every Friday and lists it on its page; and <strong>Snippets</strong>, a page of text you reuse that brings two tools of its own, so the chat can search your snippets and suggest new ones that wait for you to add them. That Friday run costs one agent run a week, so it starts paused unless you switch it on on the card. Give it a name and it is on your shelf. Then change it by hand, or ask the chat, for example <em>"Change the plugin My list so that every item has a due date."</em> How a plugin is built so that it holds up - the brief, the three modes, where your approval sits, checking and sharing - is on the <a href="plugin-blueprint.html" style="color:var(--accent)">plugin blueprint page</a>.</p>

      <h3>The shelf</h3>
      <p>Below the gallery is what you already have. Type a name into <strong>Start a new plugin</strong> and you have an empty one: the name becomes the menu entry, and building the same name again changes that plugin instead of leaving you with two of them.</p>
      <p>Every plugin on the shelf shows three things without being opened. What kind it is - <strong>page</strong>, <strong>agent</strong> or <strong>automation</strong>. What it may do, in one line next to a shield: which tools it is allowed to use, or that it may use none, and whether it may reach the network at all. And a switch: switching it off takes the entry out of the sidebar and leaves the plugin and everything it saved exactly where they are, so switching it back on picks up where you left off. <strong>Deleting</strong> is the other one, and it says so - the plugin and everything it saved go, and that cannot be undone.</p>
      <p>Nothing here needs a restart: a new or changed plugin is in the menu straight away.</p>

      <h3>Asking for one instead of building it</h3>
      <p>You do not have to write a plugin yourself. Say in a chat what you want - <em>"build me a newsletter system"</em>, <em>"build me an agent that only watches stock levels"</em> - and Skales makes the folder, writes the page, gives it a menu entry and an icon, and, if it should work while nobody is looking, its schedule. It tells you what the plugin will be allowed to do before it makes it. Asking again for the <em>same</em> plugin changes the one you have and keeps everything it saved, so you never end up with two of them.</p>
      <p>This is the larger cousin of a <a href="#skills">custom skill</a>: a skill is one tool the agent can call, a plugin is a page of your own with storage and, for the working kinds, an agent behind it.</p>

      <h3>When one is not finished, or not right</h3>
      <p>A plugin whose page has not been written yet says exactly that, and that you can leave and come back. A plugin that is broken shows the actual reason on its card instead of an empty rectangle. Neither one is a dead end you have to diagnose by opening files.</p>

      <div class="tip"><strong>Two things worth knowing.</strong> A plugin's own storage holds up to <strong>20 MB</strong>, and it tells you how much of that is used when it runs out, rather than losing what it was saving. And a plugin has no settings section of its own on purpose: everything about it is either on this page or on the plugin's own page.</div>

      <h3>Tools a plugin brings with it</h3>
      <p>A plugin does not only <em>use</em> the tools you allowed it. It can also <strong>bring tools of its own</strong> &mdash; ones its author wrote for it. Those become things Skales can call like any other tool: from a normal conversation, from the plugin's own page, and from the schedules it runs on. They never reach further than the plugin was allowed to reach in the first place, so a plugin that may not touch the network cannot smuggle a tool in that does. Its row on the shelf lists them beside the permissions, so you can see what arrived with it.</p>

      <h3>What a plugin page can do</h3>
      <p>A plugin page is not limited to a form and a list. The same rules hold - it runs in a closed frame, reaches nothing on its own, and asks you before anything leaves - but inside them a page can be a whole application:</p>
      <ul>
        <li><strong>Several files.</strong> A page may be split into scripts, modules, stylesheets, fonts and pictures. They are put together when the page opens; a file the page names and cannot find is named above the page.</li>
        <li><strong>A model answer or a run of its agent.</strong> A plugin with an agent can ask its own model a question (and check the answer has the shape it needs) or give its agent a job, straight from a button. Both count on the plugin's own meter for the day and stop at the money limit you set under <em>Settings &rsaquo; Goals</em>.</li>
        <li><strong>Long work.</strong> Voicing a course, packing it, rendering: a page can start this as a job that keeps running when you reload or leave the page, and shows its progress when you come back. A job that needs your approval shows its card before it starts. If Skales is closed while it runs, it ends as interrupted and is started again from the page - it is never repeated blind.</li>
        <li><strong>A preview of what it made.</strong> A course, a small site or a slide deck opens in a frame of its own - over part of the page, across the whole window, or in a window of its own. The preview runs like it would on a web server, cannot reach Skales or the internet, and, for an e-learning course, can pretend to be the learning platform: its buttons let you leave the course half way, come back to where you were, and start over, and a log shows every call the course made.</li>
        <li><strong>Files out and in.</strong> <em>Save as</em>, <em>Show in folder</em> and <em>Share</em> hand a finished file to you; a file picker copies files you choose into the plugin's own folder. Each happens only on a click. If a page asks without one, you get a card first.</li>
        <li><strong>A key for its own tool.</strong> When a tool the plugin brings needs a key, the page can ask for it: Skales draws the field, stores the key encrypted, and the page itself never sees it.</li>
        <li><strong>A hand-off to another plugin.</strong> A plugin can give something - a finished package, a set of rows - to another plugin that says it accepts that kind of thing. A card names both plugins and the files before anything moves, and what arrives is a copy in the receiver's inbox.</li>
        <li><strong>A full-window editor.</strong> A page can take the whole window below its head and scroll its own panes, instead of growing down the page.</li>
        <li><strong>Click an element in its preview.</strong> A page that shows a course or a site in its preview can switch on the same Inspect and Mark that Flow has: a click names the element, and the plugin writes the change into its own files.</li>
        <li><strong>Work in its own folder without a card for each step.</strong> Packing, unpacking, documents and exports that stay in the plugin's own work folder run the way they run in Auto inside a bound project folder. Writing into the plugin's own pages still asks, and publishing, sending and deleting always do.</li>
      </ul>
      <p>Plugin authors find every call, with examples, in the DevKit under <em>docs/plugins.md</em>.</p>

      <h3>Three ways to work with a plugin page</h3>
      <p>Under every plugin page you choose <strong>Manual</strong>, <strong>With AI</strong> or <strong>AI does it</strong>, and the plugin remembers which one you picked. Manual hides the plugin&rsquo;s AI buttons. With AI keeps them and adds a line under the page where you can ask the plugin for anything else. AI does it takes a whole job at once, with example jobs to start from: the AI does the work, you approve what it prepared, and every step it takes stays correctable on its own rather than running to the end unseen. E-Learning is the first plugin built with all three.</p>

      <h3>Taking one with you, and handing one on</h3>
      <p>The download arrow on a plugin's row packages it as a <strong>.skplugin</strong> file. Because that file is meant to be handed to somebody - carried to your other machine, published, or sold - it asks first for the things anyone installing it will want to read: who it is published as, what it does in one sentence, and the licence and your link if there are any. Those answers go into the packaged copy; the one installed here is left alone unless you tick the box.</p>
      <p>What travels is the plugin: its manifest, its pages, its own tools, its assets and its README. What does not travel is <strong>everything the plugin saved while you used it</strong>. Your reading list, your briefs, its memory - those stay on this machine, and the dialog lists both sets so you do not have to take that on trust. Before it writes the file it also looks through the pages and tools for things that read as yours rather than the plugin's - a home folder path, an email address, something shaped like an API key - and shows you what it found. It changes nothing; you decide.</p>
      <p><strong>Import a file</strong> in the gallery is the other direction, and it is the way to install a plugin somebody sold you outside the catalogue. The permission card appears <em>before</em> anything is written: what it is, what it asks for, who is selling it and under what licence. If the package's card and its actual manifest do not ask for the same things, it is refused and the difference is named - the card is what you agreed to, so installing the larger of the two would make every permission card in the product decorative. The same applies to a damaged download: a file that does not match its own checksums is named and refused rather than half-installed, and to a signature that does not check out - see below.</p>

      <h3>Installing something the catalogue has never heard of</h3>
      <p><strong>Install from a URL</strong>, next to Import a file, takes a repository address (<code>owner/name</code>), a release page, or the direct link to a <code>.zip</code> an author published. It fetches the release and then goes through the identical checks a file you picked goes through - the checksum inside the archive, the permission card against the manifest, the signature, and the folder it would be written into. There is one installer with two doors, so a plugin fetched from a stranger's release can never arrive with a reach a hand-picked one could not.</p>
      <p>Three things are said out loud that a catalogue row does not have to say. That nobody reviewed this and no directory stands behind it: you are trusting the address you gave. Whether a checksum was published <em>next to</em> the download and matched - and when there was none, that there was none, because a hash carried inside an archive is rewritten by whoever rewrote the archive. And that a plugin installed this way is <strong>never updated by itself</strong>: nothing here learns when its author publishes a new release, so where the Update button would be it says <em>installed by hand</em> instead of lighting up one day with somebody else's package.</p>

      <h3>Signatures</h3>
      <p>A package can carry a signature, and Skales checks it. What is signed is the checksum file, so the signature covers every file in the package at once, and it travels as its own file beside it.</p>
      <p>The key decides what a valid signature is allowed to <em>mean</em>, and the two cases are never blurred together. When the key comes from the <strong>catalogue row</strong>, the package could not have chosen it, so a valid signature names the publisher: <em>Signature valid: published by X</em>. When the key comes from the package itself, all a valid signature proves is that nothing was changed after it was signed - it says nothing whatever about who signed it, and it is worded that way rather than given a green tick it has not earned.</p>
      <p>An <strong>invalid</strong> signature refuses the install outright, with the reason. A package that carries a signature that does not check out is a package somebody changed after it was published, and the fact that the claim cannot be verified is exactly why it must not be installed.</p>
      <p>An unsigned package still installs. Signing is a way to say more, not a new bar every author has to clear - and the card says plainly that nobody can be named for it.</p>
      <div class="tip"><strong>Signing your own.</strong> Run <code>node scripts/plugin-sign.js keygen</code> once. It writes a private key into your data folder, readable only by you, and prints the public half as one line. The private key never leaves the machine and Skales never sends it anywhere. From then on every <strong>.skplugin</strong> you export is signed, and the export tells you whether it was. Put the public line into your plugin's <code>publicKey</code> field in the directory, and everybody installing your release gets the named check rather than the anonymous one.</div>
      <h3>Business plugins</h3>
      <p>Some plugins, like E-Learning, are made by Skales for businesses. They are not in the public directory and not inside the app. When your Skales account includes one, its next version appears on the Plugins page with the same card every update shows: what changes, which of your files stay, and a button to confirm. Skales only installs it when it is signed with the Skales key the app carries, so the delivery path cannot slip in anything else. Without the licence the plugin keeps working as it is and the page says why there is no update; nothing you made with it is ever part of an update.</p>
    </section>

    <section id="business">
      <h2><span class="icon">&#127970;</span> Business, and using Skales at work</h2>
      <p><strong>Business</strong> is a page in the sidebar, and it is the one place in Skales that talks about money. Two things live there: what a commercial licence covers, and the waiting list for the Business suite.</p>

      <h3>Why there is a licence at all</h3>
      <p>Skales is free to use, and it is not open source. Using it <strong>inside a company</strong> needs a written licence, and that is what this page is the door to. The licence covers three things: using Skales in your company, how many seats that is, and whether you may pass seats on to clients of your own. Nothing about the app changes when you have one - no feature unlocks and nothing is withheld from you until you do. It is a contract, not a gate.</p>
      <p>The full text is at <strong>skales.app/licence</strong>, and the page links straight to it.</p>

      <h3>The waiting list, and what it is not</h3>
      <p>The form on the page is four short steps, and it <strong>saves after the first one</strong>. That is deliberate: your address and whether this is for work or for yourself are all that is really needed, and if you close the window at step three nothing is lost. The two steps after it - how big the team is, and what you actually need - are there so the reply you get is about your situation rather than a brochure.</p>
      <p>Step one carries two tick boxes and they do different jobs. The first is <strong>required</strong>: it is your agreement that what you type is stored so the enquiry can be answered, and the page links to the privacy notice next to it. The second is the <strong>newsletter</strong>, it is separate, it starts empty, and it is never a condition of anything - leaving it alone still sends the enquiry. Ticked, it is the same subscription as the Newsletter row in Settings: it shows there, and switching that row off takes the address off the list. Every mail from the letter carries an unsubscribe link.</p>
      <p>Joining the list is <strong>not a contract and not a payment</strong>. Nothing is charged, nothing starts, and no card is asked for anywhere on the page.</p>

      <h3>What the figures at the top are</h3>
      <p>The line of numbers under the headline is read live from the public statistics endpoint when the page opens. Every figure is <strong>rounded down</strong> and carries a plus, so none of them is ever an overstatement. If the endpoint cannot be reached the page shows the last measured values instead and says nothing about it - there is no loading state and no empty row, because a page that shows a placeholder where a number belongs is worse than one that is slightly behind.</p>

      <h3>If you do not want the row</h3>
      <p>The Business entry is an ordinary sidebar row and it can be <strong>unpinned</strong> like any other: right-click it, or use the pin that appears when you reach for the row, and it moves into <strong>More</strong>. It does not come back afterwards. A machine that was set up for private use never gets the row in the column in the first place - the page is still there under More if you go looking.</p>
    </section>

    <!-- ===== Chapter: Chat and agents ===== -->
    <section id="ch-chat" class="chapter-lead">
      <div class="lead-kicker">Chapter 2</div>
      <h2>Chat and agents</h2>
      <p class="lead-intro">Chat is the whole product with a text box in front of it. The same engine answers a question, runs a ten-step goal, keeps what it learned about you, and fans work out to a team, so this chapter starts at one message and ends at several agents working at once.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a question, a tool, a goal, an agent</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">Four messages, each one a different gear of the same engine.</p>
        <ol>
          <li>
            <span class="do">Ask something it can answer from what it knows:</span>
            <span class="say">Explain the difference between a goal and a task in Skales, in four sentences.</span>
            <span class="then">a plain answer with no tool steps above it.</span>
          </li>
          <li>
            <span class="do">Drag a screenshot onto the composer and ask about it:</span>
            <span class="say">What is wrong with the layout in this screenshot?</span>
            <span class="then">the image as an attachment on your message, and an answer that describes what is actually in it.</span>
            <span class="stuck">the answer talks about an image it cannot see, the model you are on has no vision. The provider grid marks the ones that do with a <strong>Vision</strong> badge.</span>
          </li>
          <li>
            <span class="do">Hand it something big enough to need a plan:</span>
            <span class="say">/goal Find three articles published this month about local AI assistants, and write me a one page summary with the sources at the bottom.</span>
            <span class="then">Skales restate the goal, lay out a plan, and then work through it on its own. It stops only when it is done, when it needs a decision, or before something consequential like sending mail.</span>
          </li>
          <li>
            <span class="do">Open the persona picker at the top of the chat and switch to a different agent, then ask the same question again.</span>
            <span class="then">a different answer and a different session history, because an agent carries its own system prompt and its own thread.</span>
          </li>
          <li>
            <span class="do">Ask for several deliverables at once, which is the point where one chat becomes a team:</span>
            <span class="say">Write five short competitor summaries, one each for the five best known note taking apps.</span>
            <span class="then">five background agents in the Tasks tab, each reporting its result back into this thread as it finishes.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT chat-goal-running.png
           Chat with a /goal run in progress, several steps done and one still working.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the restated goal and plan at the top of the run, at least two
           completed tool steps (collapsed is fine), and the goal indicator in the chat
           header. Ideally one Continuation Card visible.
      -->
      <figure class="shot pending">
        <img src="img/chat-goal-running.png" alt="A goal in flight: the plan, the steps, and the header that says it is running." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; A goal in flight: the plan, the steps, and the header that says it is running.</div>
        <figcaption>A goal in flight: the plan, the steps, and the header that says it is running.</figcaption>
      </figure>

      <!-- SHOT chat-tool-step-open.png
           Chat, one tool step expanded (a web search is the clearest).
           Frame: the message area only, cropped to about 900px wide.
           Must show: the query that was sent, the result that came back, and the copy
           button. This is the picture for "tool results are shown inline".
      -->
      <figure class="shot pending">
        <img src="img/chat-tool-step-open.png" alt="Any step opens: what was sent, and everything that came back." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Any step opens: what was sent, and everything that came back.</div>
        <figcaption>Any step opens: what was sent, and everything that came back.</figcaption>
      </figure>

      <p>Read <a href="#chat">Chat</a> and <a href="#goal">GOAL</a> first. <a href="#multi-agent">Which multi-agent mode</a> is worth reading before you build a team, because Skales has three of them and they are for three different things.</p>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#chat">Chat</a>
        <a href="#cost">What a conversation costs</a>
        <a href="#shortcuts">Chat Commands</a>
        <a href="#goal">GOAL</a>
        <a href="#documents">Document Generation</a>
        <a href="#http-request">Calling an API</a>
        <a href="#easter-eggs">Easter Eggs</a>
        <a href="#memory">Memory<span>What it remembers</span></a>
        <a href="#companion">The companion, and Conscious<span>What it remembers</span></a>
        <a href="#memory-mode">Memory Mode<span>What it remembers</span></a>
        <a href="#knowledge-graph">Knowledge Graph<span>What it remembers</span></a>
        <a href="#vector-db">External vector database<span>What it remembers</span></a>
        <a href="#obsidian">Obsidian vault<span>What it remembers</span></a>
        <a href="#auto-compress">Auto-Compress<span>What it remembers</span></a>
        <a href="#agents">Agents<span>Agents and teams</span></a>
        <a href="#multi-agent">Which multi-agent mode<span>Agents and teams</span></a>
        <a href="#group-chat">Group Chat<span>Agents and teams</span></a>
        <a href="#organization">Organization<span>Agents and teams</span></a>
        <a href="#teams">Teams: rooms with other people<span>Agents and teams</span></a>
        <a href="#swarm">Devices<span>Your other computers</span></a>
        <a href="#agent-sync">Agent-to-Agent Protocol<span>Agents and teams</span></a>
        <a href="#skills">Skills<span>Skills and tools</span></a>
        <a href="#agent-skills">Agent Skills Import<span>Skills and tools</span></a>
        <a href="#skills-interactive">Custom Skill Interactive UI<span>Skills and tools</span></a>
        <a href="#skill-sharing">Skill Sharing & Forking<span>Skills and tools</span></a>
        <a href="#mcp">MCP Server Support<span>Skills and tools</span></a>
      </div>
    </section>

    <section id="chat">
      <h2><span class="icon">💬</span> Chat</h2>
      <p>The main conversation interface. Skales remembers context, executes tools, and builds session history.</p>

      <h3>The side panel</h3>
      <p>The panel on the right of a chat has three views, switched at its top: <strong>Overview</strong> (what the conversation uses: model, context, plan, background work, connectors), <strong>Document</strong> (the document the agent writes) and <strong>Files</strong> (every file this chat made or read, with a jump to the message that made it; a message further up in a long chat is loaded and shown). In a window narrower than 1600 pixels the panel starts closed, so it never squeezes the reading column; in a wider one it starts open. Open or close it yourself and that choice is remembered at every width. When the agent brings up a document the panel opens for that moment without changing your choice. Messages carry no avatars beside the bubbles, which keeps the chat calm and leaves the room to the text.</p>

      <h3>Multi-Session</h3>
      <p>Every conversation is saved as a session. Browse and restore past sessions from the sidebar panel. Sessions auto-title based on your first message.</p>

      <h3>Agents</h3>
      <p>Switch between custom AI agents using the persona picker at the top of the chat. Each agent has its own personality, system prompt, and session history.</p>

      <h3>Where the built-in agents' prompts come from</h3>
      <p>The Code Assistant, Data Analyst, Strategic Planner, CTO, Research Analyst and Project Manager, most roles of the team presets and the agents of the organization templates run on detailed specialist prompts from the open <strong>agency-agents</strong> library (MIT). Each such card carries a small line, "Prompt: agency-agents (MIT)", that links to the file the prompt comes from. Skales adds a short block of its own to each: the name the agent appears under, its part in the team, and the rule to answer in the language you write in. If you edit a prompt, it stays exactly as you wrote it; if you only pinned a model on a built-in agent, it keeps your model and follows the library prompt.</p>
      <p>These prompts are longer than the old ones, around ten times. Within a run the prompt is cached by the provider, so the steps after the first do not pay for it again.</p>
      <p>The rest of the library, a few hundred specialists from engineering to marketing, finance and game development, stays on disk. Ask for a specialist in any chat and Skales finds one, reads its method for your task, or hands the task to a sub-agent that works as that specialist and waits for the answer. Handing over asks first, the same way any sub-agent does.</p>

      <h3>Attached Files</h3>
      <p>Drag and drop or click the paperclip icon to attach images, PDFs, or code files. Vision-capable models can analyze screenshots and diagrams.</p>

      <h3>Tool Execution</h3>
      <p>Skales can call tools directly from chat — write files, search the web, send emails, read your calendar, run terminal commands, and more. Tool results are shown inline.</p>

      <h3>How an answer is shown</h3>
      <p>An answer is not only text. Markdown is rendered, and so are four things worth knowing about, because knowing they exist changes what you ask for.</p>
      <p><strong>A page.</strong> A fenced block tagged <code>html</code>, <code>htm</code>, <code>svg</code>, <code>xhtml</code> or <code>html5</code> - or one that simply opens with a document - is drawn as a live preview inside the conversation, with show-code, download and save-as-image under it. Scripts, CSS animation and canvas all run in it. So "show me a chart of this" or "make me a little landing page" gives you the thing, not its source. If you want the markup to copy instead, ask for it in a <code>text</code> or <code>xml</code> block, which are never drawn.</p>
      <p><strong>A diagram.</strong> A <code>mermaid</code> block is drawn: flowchart, sequence, state, class, entity-relationship, gantt, timeline, pie and xychart. It follows your accent and your theme, the source is one click away, and it downloads as SVG. For a process, a structure or a comparison this is usually the better ask than a full page: it is faster, it is editable, and it is the form a small local model gets right most reliably.</p>
      <p><strong>A formula.</strong> Maths wrapped in <code>$$</code> is typeset. A single <code>$</code> deliberately does not start maths, so prices and shell variables stay as you wrote them.</p>
      <p><strong>Code with colour.</strong> Fenced code blocks are syntax-coloured and carry a copy button; naming the language after the backticks is what gets the colouring right. <kbd>Ctrl</kbd>+<kbd>A</kbd> inside a block selects that block rather than the whole conversation.</p>
      <p>Skales itself knows all of this now, in every mode rather than only in Code mode, so you can simply ask for a diagram or a page and expect one.</p>

      <h3>A picture a tool handed back</h3>
      <p>Not everything a tool returns is text. When Skales looks at a web page or at your desktop, what comes back is a <strong>picture</strong>, and it is shown to you as one and carried as one &mdash; into the conversation, into an export of it, and to your paired phone &mdash; instead of being described to you in words that are one step further from what was actually there.</p>
      <p>Skales also keeps track of <em>where each picture came from</em>: a screenshot the browser took, a capture of your screen, an image a model generated, a photo you attached yourself. So when it refers back to one later, it can tell you which it means, and a picture it took itself is never presented as something you provided.</p>

      <h3>A file it made</h3>
      <p>When Skales writes a file for you — a spreadsheet, a document, a PDF, a note, a downloaded file, an edit to a file you already had — the file arrives as a <strong>card under the answer</strong> rather than as a path buried in a sentence. The card carries the filename, with the full path on hover, and a second line with the type and the size. Under it are <strong>Download</strong> (for files inside the Skales data folder) and <strong>Open Folder</strong>.</p>
      <p>A <strong>PDF opens inside Skales</strong>. The card carries a <strong>View</strong> button, and a link to a PDF in an answer opens the same way: the document is shown in the app's own panel with the scrolling, zoom, search and print you know from any reader, drawn by the Skales window itself. There is one panel, so opening a second PDF replaces the first rather than piling up windows; Escape, the X in the title row or a click beside the panel closes it. Download and Open Folder stay in that title row, so the file can still be taken into another reader. A PDF lying in a project folder is shown the same way in the Code window's preview pane.</p>
      <p>The card is part of the conversation, not part of that moment: it survives a reload and it is still there when you reopen the conversation tomorrow. If the file has since been deleted the card says so — the size line becomes <em>No longer on this computer</em>, the card dims and Download goes away — instead of offering you a file that is not there.</p>
      <p>One deliberate exception: a file written by a <strong>script</strong> Skales ran gets no card, because nothing is watching a script's output closely enough to promise the card is right. In that case Skales tells you in words where it put the file.</p>

      <h3>Sending while it is still writing</h3>
      <p>You no longer have to wait for the answer before typing the next thing. A message you send while Skales is working <strong>reaches the running turn at its next step</strong>: after the tool call in flight returns, Skales reads it and keeps going with it, without starting over. Several messages typed in a row arrive together as one, in the order you wrote them. Pictures ride along.</p>
      <p>If you would rather have your message wait, choose <strong>After the turn</strong> in the strip above the composer (or in Settings → Assistant → Working style &amp; Autonomy → Messages while Skales works). Then it runs as a turn of its own once the current one has finished, in line with anything else you queued. Stop always stops at once; lines waiting for after the turn stay and the strip offers <strong>Go on</strong>.</p>
      <p>The strip lists every waiting line as <em>waiting</em> and, for a moment after Skales takes it, as <em>delivered</em>. You can edit or remove a line while it waits. The list lives with the run, not with the window: it is still there after a reload or a restart, and the chat window, Iris, the Buddy and your phone all put their lines into the same one.</p>
      <p>What is waiting goes out once the run is really over. That is not the same moment as the composer unlocking: a turn that stops responding frees the composer so you are not stuck, while the run itself carries on, and a queued message sent into that gap used to arrive as a second answer to a question that already had one. If a queued message cannot be sent at all, it is tried once more and then stays in the bar saying so, with <strong>Try again</strong> beside it, rather than being retried silently.</p>

      <h3>Stopping, and correcting what you asked</h3>
      <p>Stop frees the chat the moment you press it. What had already arrived stays on screen &mdash; the half-written answer and the reasoning behind it are part of the conversation, and they are still there after a restart, rather than being wiped in the same instant the run ended.</p>
      <p>Correcting the question straight afterwards works the way it looks: an edited message waits for the run it replaces to be gone and then goes out once, about the new text, carrying its picture with it. If the old run will not end, you are told so instead of watching Save do nothing.</p>

      <h3>A recommendation arrives as cards</h3>
      <p>Ask for the good beaches near Funtana, six recipes for a Tuesday or the libraries worth reading, and the written answer comes with a row of <strong>cards</strong> under it: each page's own preview picture, its name, one sentence, tags and the link. The answer itself is unchanged and stays where it was — the cards carry it, they do not replace it. A page with no picture gets a lettered tile of the same height, so the row settles once and does not jump about while the pictures arrive.</p>
      <p>When the row is <em>places</em> rather than pages, every card also gets <strong>Open in Maps</strong> — Apple Maps or Google Maps, whichever suits the machine — and the row gets a <strong>Map</strong> button that draws all of them over OpenStreetMap. Nothing is looked up until you open the map, and no key is needed for any of that. See <a href="#places" style="color:var(--accent)">Google Places</a> for what a key adds.</p>

      <h3>Working with a reply</h3>
      <p>Right click a message for its menu: copy, rewrite, quote in reply, save to a document, read aloud, regenerate or branch a new session from that point. Select part of a reply first and the same right click acts on the passage instead, starting with <strong>Rewrite selection</strong>.</p>

      <div class="warn">
        <strong>⚠️ Safe Mode</strong> — In Safe Mode, Skales will show an approval prompt before executing destructive actions (delete files, send emails, shell commands). See <a href="#safety" style="color:var(--accent)">Safety Mode</a>.
      </div>
    </section>

    <section id="cost">
      <h2><span class="icon">💰</span> What a conversation costs</h2>
      <p>You bring your own key, so the bill is yours and Skales shows it while it is being run up rather than at the end of the month.</p>

      <h3>The running price</h3>
      <p>A price sits beside the context meter in the footer of the composer and counts this conversation. Each answer also carries its own price in the token line under it, and the hover card over that line breaks the turn down: what the input cost, what the output cost, and how much of the input came out of the provider&rsquo;s cache instead of being paid for a second time.</p>
      <p>The card counts the model calls you never see a bubble for, because they are real charges on your key: the summariser that shortens a long conversation to keep it inside the model&rsquo;s window, and the vision model that describes a screenshot for a browser or computer-use step. Each rides on the step that made it and stands on its own line. A price that cannot be known — a vision model on your own machine — says nothing rather than showing a zero.</p>

      <h3>What a single answer cost</h3>
      <p>The meter answers &ldquo;what has this conversation cost&rdquo;, never &ldquo;which answer cost it&rdquo; &mdash; and a screenshot step that charges a quarter of a dollar disappears into a session total. <strong>Analyze</strong>, opened from the bar under an answer, carries the same sum the meter carries in its header, and every turn in its log names its own price beside its tokens. The report you copy as text carries both figures. A provider that reported no price says so, because a zero reads as an answer that was free.</p>

      <h3>Claude on your own Anthropic key</h3>
      <p>Chat, Skales Code and Flow price Claude Opus, Sonnet, Haiku and Fable on your Anthropic key from Anthropic&rsquo;s own list, so these turns show a real price instead of &ldquo;price unknown&rdquo; and count toward the meter and the session ceiling. Reads from the prompt cache and writes into it are billed at their own rates, which is why a long conversation with a stable start costs less per turn than its token count suggests. A Claude model Anthropic has not priced yet still says unknown rather than borrowing an older model&rsquo;s rate.</p>

      <h3>Every step and its price</h3>
      <p>In Flow, the price in the head of the conversation opens its <strong>steps</strong>: grouped by the message that started them, each with the tools it called, whether they worked, how long it took and what it cost. Team runs list each member, and an action waiting for your approval stands in the same list. The chat shows the same steps in <strong>Analyze</strong>. The steps always add up to the price under the composer and to the price the phone shows, including what an undo took out of the conversation. The members and the coordinator of a team run count in that price too.</p>

      <h3>Checked before it is paid for</h3>
      <p>A Flow start checks first whether every planned step has what it needs: the tool, the service key, the local renderer for a motion video or a cut, a music service when the brief asks for music. When something is missing, Flow says which step needs what, links to the place in Settings where it is set up, and names the way around it where there is one, such as OpenRouter. No model is asked and nothing is charged for a start that cannot run.</p>

      <h3>The session ceiling</h3>
      <p>A conversation can stop itself before it spends more than you meant it to. <strong>Settings &rsaquo; Goals &rsaquo; Session budget</strong> sets the ceiling; a fresh installation starts at five dollars, and a machine that already has settings keeps exactly what it had. <code>0</code> means no ceiling.</p>
      <p>At half the ceiling and again at the ceiling itself, Skales stops and asks, with three answers: <strong>carry on</strong>, <strong>switch to a cheaper model</strong>, or <strong>stop here</strong>. The question is answered here rather than by the model, so being asked costs nothing. Raise a ceiling that has already stopped a conversation and that conversation wakes up and finishes the turn it was in.</p>
      <p>The ceiling counts per session, everywhere the session goes: the chat window, the Skales Code window, a conversation carried over from Iris, and a chat sent from your paired phone. A sub-agent runs against what its conversation has left rather than against a budget of its own, and one that reaches the ceiling says so in words instead of coming back empty-handed.</p>
      <h3>The Costs view</h3>
      <p><strong>Costs</strong> shows where the money went: today, the last 7 or 30 days or this month, by provider and model, by area (chat, Code, Flow, tasks, pictures, background), the most expensive conversations and the tokens behind it, with tips where you could save. It counts every answer you paid for, also an earlier answer you regenerated and turns that were rolled back, so it shows the same amount as the price under the chat. Open it from the connection card at the top of the sidebar, the System popup or the Costs widget, or pin <strong>Costs</strong> into the sidebar from <strong>More</strong>: pinned, the row shows what today cost. Calls without a known price are named and never counted as free. The <strong>Activity</strong> widget on the Dashboard draws the same figures as one square per day for the last year.</p>

      <div class="tip"><strong>💡 Not the same as the messenger leash.</strong> Telegram and WhatsApp count per conversation <em>and per day</em>, under their own settings — that is a channel limit, and this is the ceiling for one session on this computer.</div>
    </section>

    <section id="shortcuts">
      <h2><span class="icon">⌨️</span> Chat Commands</h2>
      <p>Type <code>/</code> in the chat input to open the command picker. Available commands:</p>

      <div class="shortcut-list">
        <div class="shortcut-item"><div class="shortcut-key">/model</div><div class="shortcut-desc">Switch the active AI model inline (e.g. <code>/model claude-opus-4</code>)</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/new</div><div class="shortcut-desc">Start a new chat session</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/memory</div><div class="shortcut-desc">Show or search remembered facts</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/clear</div><div class="shortcut-desc">Clear current session messages</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/kill</div><div class="shortcut-desc">Stop any running Autopilot task immediately</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/spin</div><div class="shortcut-desc">Rewrite a text in a plainer voice. <code>/spin &lt;text&gt;</code> rewrites what follows, <code>/spin</code> alone rewrites the last answer</div></div>
        <div class="shortcut-item"><div class="shortcut-key">/help</div><div class="shortcut-desc">Show the full command list</div></div>
      </div>
    </section>

    <section id="goal">
      <h2><span class="icon">🎯</span> GOAL</h2>
      <p>GOAL turns Skales from a chat you steer one reply at a time into an agent that holds a goal and works it across many steps on its own. Type <code>/goal</code> followed by what you want, or describe something big enough that Skales offers to take it on, then let it plan, act, check its own progress, and decide when it is done.</p>

      <h3>Starting a goal</h3>
      <p>Open the slash menu in chat and pick <code>/goal</code>, or just write the goal in plain language. Skales restates the goal, lays out a plan, and runs the whole task autonomously to completion. It stops only when the task is done, when it genuinely needs your decision, or before a consequential action like sending an email, where it asks once (with a one-tap always-allow on the card); it does not pause every few steps to ask you to continue. You can follow each step, step in with a correction, or walk away and come back to the result. A long plain chat that grows into a real multi-step task is carried on as a goal on its own, and the step limit under <strong>Settings &rarr; Assistant &rarr; Working style &amp; Autonomy</strong> is a safety ceiling against a runaway task (0 means run to completion), not a check-in.</p>

      <h3>The Daemon</h3>
      <p>A background worker keeps your goals moving while the app is idle, picks up recurring goals on their schedule, and resumes anything that was parked. Each goal keeps a ledger of what it has tried and learned, so a long run survives restarts and stays on one thread of intent. Set up recurring goals and limits under <strong>Settings &rarr; Assistant &rarr; Working style &amp; Autonomy</strong>.</p>

      <h3>Presence goals</h3>
      <p>Start a goal with <code>/goal presence:</code> and Skales keeps a steady presence over time as a declared agent, instead of finishing once and stopping. It works only on channels it can use honestly: your own Discover feed, email over your mail settings, and the official integrations you have connected, like an MCP server or the Telegram and WhatsApp bots. It never poses as a person or works around anything built to keep automated agents out, and it learns from what comes back each round. There is a short, plain-language note about goals at the bottom of <strong>Settings &rarr; Assistant &rarr; Working style &amp; Autonomy</strong>.</p>

      <h3>Past the context limit</h3>
      <p>Long goals used to stop when the conversation filled up. Skales now compacts its own working memory on the fly, keeps the goal, the plan, and the key findings, and continues. A Continuation Card appears whenever a run needs a decision from you or hands the thread back, so a goal never stalls in silence.</p>

      <h3>Dispatch a team</h3>
      <p>Ask for ten landing pages or five competitor write-ups and Skales fans the work out to parallel background agents, one per item. Each runs on its own in the Tasks tab, and as they finish their results, including any images and files, report straight back into the chat thread. Use it when you want several independent deliverables at once, not for a single answer.</p>

      <h3>The list it is working to</h3>
      <p>A long piece of work shows its <strong>plan</strong> while it runs: the steps as Skales sees them, which one is being worked on, and what is already done. It is not decoration &mdash; it is the list the run actually follows, so watching it is watching the work.</p>
      <p>A big job can carry more than one such list at a time, each with its own name, so a run that is preparing a release and testing it at the same time shows two honest lists instead of one muddled one. A list with steps still open keeps the run open: Skales will not call something finished while its own plan still says otherwise.</p>

      <h3>Seeing what runs</h3>
      <p>Active and background goals show in the chat header and in History, each with its status, so a long autonomous run is never a black box. Open one to follow its steps, or jump back into any thread where a goal is still in flight.</p>

      <div class="tip"><strong>💡 Tip:</strong> Put several models in one thread to talk a goal through together. See <a href="#group-chat" style="color:var(--accent)">Group Chat</a>.</div>
    </section>

    <section id="documents">
      <h2><span class="icon">📄</span> Document Generation</h2>
      <p>Create Excel (.xlsx), Word (.docx), and PDF files from natural language. Ask "create a budget spreadsheet" and Skales generates it.</p>

      <h3>Excel (.xlsx)</h3>
      <p>Generate spreadsheets with formulas, formatting, and multiple sheets. Skales can create budgets, tables, charts, and data compilations.</p>

      <h3>Word (.docx)</h3>
      <p>Generate formatted documents with headings, paragraphs, tables, and lists. Perfect for reports, proposals, and technical documentation.</p>

      <h3>PDF Export</h3>
      <p>Convert documents to PDF format. PDFs are fully formatted and ready for sharing or printing.</p>

      <h3>Designed PDF (html_to_pdf)</h3>
      <p>For a designed or visual PDF, such as a brochure, a product sheet, or a branded report, the agent calls the <strong>html_to_pdf</strong> tool, which renders an HTML string into a clean, print-ready A4 PDF: proper page breaks, backgrounds and colors printed, and no browser print header or footer with file paths or timestamps. This is the right way to produce a layout-heavy PDF instead of shelling out to <code>chrome</code> or <code>edge --print-to-pdf</code>. Plain editable text still uses <strong>create_document</strong>, and data tables use <strong>create_spreadsheet</strong>.</p>

      <h3>Dynamic Templates</h3>
      <p>Describe what you need and Skales generates appropriate structure and content. No template library required.</p>

      <h3>Word files and editable presentations</h3>
      <p>Ask for a concept, a handout or a letter as a Word file and Skales writes a real <strong>.docx</strong> from the text, with its headings, lists, tables and page breaks. Ask for slides and it builds an <strong>editable PowerPoint</strong>: every title and bullet is a real text box, pictures and shapes sit where they were placed, and your speaker notes come along. Anything that could not be placed is named in the answer rather than quietly moved.</p>

      <h3>Business letters with your letterhead</h3>
      <p>Ask for a letter and Skales can write it onto your own letter paper: a running header and footer, an address window, references, fold and hole marks, and page numbers, editable afterwards in Word and in LibreOffice alike. The logo keeps its proportions wherever it sits on the page, and asking for only a header or only page numbers leaves the rest of the page exactly as it was.</p>

      <h3>Any page to PDF, PowerPoint or Word</h3>
      <p>The export that Flow&rsquo;s buttons run works for any folder too. Point Skales at an HTML page, a slide deck or a document in your project and it renders it the way the preview shows it, with its styles, fonts and pictures: a deck becomes one PDF page per slide (with a speaker-notes page after each on request) or a PowerPoint, and a document becomes an A4 PDF or an editable Word file.</p>

      <h3>Zip archives and binary files</h3>
      <p>Skales packs a folder into a zip &mdash; its contents at the top of the archive, the way an LMS, a WordPress theme or a browser extension expects &mdash; with patterns for what to include and leave out, and it can show what is inside an archive without unpacking it. Passwords and key files are never packed. Pictures, audio, fonts and archives can also be read and written byte for byte.</p>

      <h3>Where the files go</h3>
      <p>Every tool that makes a file &mdash; images, voice recordings, PDFs, spreadsheets, videos, documents, archives &mdash; can put it where you say: in Skales Code into the project folder, in the chat into your workspace or a folder you name. Without a place, each keeps its usual one.</p>

      <h3>Reading a document you already have</h3>
      <p>The other direction. Point Skales at a PDF, a Word file or a spreadsheet and it reads it <strong>with its shape intact</strong>, not as one long wall of text: the headings a Word document is built from, its tables as tables, its footnotes and the comments people left in the margin; a spreadsheet&rsquo;s named ranges and the formulas behind the numbers rather than only the numbers; and, in a PDF, whichever pages you ask for &mdash; &ldquo;just pages 40 to 55 of the manual&rdquo; is a real request.</p>
      <p>A long document is never cut in silence. Every read ends by saying how much of the file it actually returned and where to carry on, so &ldquo;summarise this 400-page report&rdquo; is answered by working through it rather than by summarising the first few pages and calling that the report.</p>
      <p>A scanned PDF &mdash; pictures of pages, with no text layer &mdash; is named as one instead of coming back empty.</p>
    </section>

    <section id="http-request">
      <h2><span class="icon">🔌</span> Calling an API</h2>
      <p>Skales can talk to any REST API or submit a web form: your method, your headers, your body, and the answer back. A body shaped like <code>name=Ada&amp;message=Hello</code> is sent as a form, which is the difference between a request that works and one that quietly does nothing. Reading runs; writing (POST, PUT, PATCH, DELETE) asks first, like any other writing action.</p>
      <p>The call identifies itself as Skales. A number of sites — Wikipedia and the other Wikimedia projects among them — refuse a nameless robot outright, so a request that carries no name at all gets a 403 for a perfectly correct call. No browser is impersonated, and a <code>User-Agent</code> header you set yourself is the one that travels.</p>
      <h3>What it can reach</h3>
      <p>The internet, your own network and your tailnet: a NAS, a second machine, a service you run at home are all normal targets. <strong>This computer is not</strong>, because that is where Skales itself listens, and a web page or a document could otherwise talk the agent into calling the app on your behalf. Link-local and cloud metadata addresses are never allowed.</p>
      <p>If you want the agent to reach a service you run locally, turn on <strong>Let http_request reach this computer</strong> under <strong>Settings &gt; Security &amp; Privacy &gt; Network, telemetry &amp; hooks</strong>. It is off by default and the text says why. It is an outbound rule for this one tool: how <em>you</em> reach Skales from your phone or over Tailscale is a separate setting and is untouched by it.</p>
    </section>

    <section id="watch-video">
      <h2><span class="icon">🎬</span> Asking about a video</h2>
      <p>Point a chat at a video file - drop it on the composer, attach it with the paperclip, or name a file Skales can reach - and ask what happens in it. Skales takes frames across the whole clip and reads the sound alongside them, so the answer is about the film rather than about one thumbnail.</p>

      <h3>Answers come with times</h3>
      <p>What it tells you is anchored: <em>at 0:42 the second speaker takes over</em>, not <em>somewhere in the middle</em>. That is what makes the answer checkable - you can jump to the moment it names and see whether it is right.</p>

      <h3>Every ceiling is said out loud</h3>
      <p>It does not look at every frame, and it never pretends it did. Six moments across the clip is the normal reading and twelve is the most it will take, the sound is read up to a length of its own, and the answer states how far apart the moments it looked at were. It will not tell you what happened <em>between</em> two of them. A summary that skipped the last twenty minutes without mentioning it would be worse than no summary, which is why the ceiling is part of the answer rather than a footnote in this guide.</p>
      <p>You can steer it: ask for more moments if the clip is dense, tell it what to look for in each one (&ldquo;read the text on screen&rdquo;), or ask it to skip the sound. A clip with no speech in it comes back as silent, which is an answer and not a failure.</p>

      <div class="tip"><strong>What it needs.</strong> A <strong>Vision provider</strong> (Settings &rsaquo; Integrations &rsaquo; Vision provider), because this is the same kind of work as looking at a picture, and <strong>FFmpeg</strong> for taking the video apart - if that is missing, Skales names it and points at Settings &rsaquo; Dependencies instead of failing quietly. A very large file is refused with the size limit written out, so trimming it or dropping the resolution is an obvious next move.</div>
    </section>

    <section id="easter-eggs">
      <h2><span class="icon">🦎</span> Easter Eggs</h2>
      <p>Skales has a few hidden, playful extras. None of them change your work or cost a thing, they are just for fun. You can also ask Skales any time which easter eggs it has and it will list them.</p>
      <h3>Type these in the chat</h3>
      <ul>
        <li><code>/coffee</code> &middot; a tongue-in-cheek &ldquo;still brewing&rdquo; reply.</li>
        <li><code>/servus</code> &middot; a Viennese hello back.</li>
        <li><code>/wien</code> or <code>/vienna</code> &middot; a greeting from Vienna with an ASCII Stephansdom.</li>
        <li><code>/sachertorte</code> &middot; the authentic Vienna Sachertorte recipe card.</li>
        <li><code>/nudge</code> &middot; shakes the Desktop Buddy window, MSN Messenger style.</li>
        <li><code>/barrelroll</code> or <code>/do a barrel roll</code> &middot; spins the chat a full 360 degrees.</li>
        <li><code>/highfive</code> and <code>/bow</code> &middot; an animated 🙌 and 🙏.</li>
        <li><code>:gecko:</code> 🦎, <code>:bubbles:</code> 🫧, <code>:paw:</code> 🐾 &middot; inline animated emoji.</li>
      </ul>
      <h3>Hidden interactions</h3>
      <ul>
        <li><strong>The Konami code</strong> (up, up, down, down, left, right, left, right, B, A) unlocks a gecko surprise.</li>
        <li><strong>Click the Skales logo seven times</strong> to collect the seven secrets; all seven earns the &ldquo;Master of Geckos&rdquo; badge.</li>
        <li><strong>Shake the Desktop Buddy window</strong> three times fast and it asks you to stop shaking the gecko. <code>Cmd/Ctrl + Shift + N</code> does the nudge from anywhere.</li>
        <li><strong>Start a fresh chat with &ldquo;hello skales&rdquo;</strong> (or hi / hey skales) for a personal greeting.</li>
      </ul>
    </section>

    <section id="memory">
      <h2><span class="icon">🧠</span> Memory</h2>
      <p><strong>Bi-Temporal Memory</strong> — Auto-extracts facts and preferences from conversations. Skales builds a persistent understanding of who you are over time, storing memory locally and injecting relevant context before every reply.</p>

      <table>
        <thead><tr><th>Type</th><th>What it stores</th></tr></thead>
        <tbody>
          <tr><td>Short-term</td><td>Facts from the current session — names, preferences, context</td></tr>
          <tr><td>Long-term</td><td>Extracted highlights across sessions — important facts, decisions, habits</td></tr>
          <tr><td>Episodic</td><td>Notable conversations and events timestamped for recall</td></tr>
        </tbody>
      </table>

      <p>Manage memories in <strong>Settings → Memory</strong>. You can view, edit, or delete individual entries. Up to 5 relevant memories are automatically recalled per conversation.</p>

      <h3>Learning as you work</h3>
      <p>Every ten of your messages or ten tool steps, Skales takes a short look back on the helper model and keeps what is worth keeping: facts about you, how-to lessons, and <strong>procedures</strong> — step-by-step instructions for a kind of task, which it finds and follows next time. Your corrections come first: "shorter, and always as a table" ends up in the procedure for that task. When something was kept, one quiet line in the chat says <em>Memory updated</em> and links to it. Nothing is ever kept from an Incognito conversation, and the look-back's cost is part of the conversation's price.</p>
      <p>Finished conversations are also summarised during the day, hourly and at most 24 a day, so "what did we do this morning" has an answer before the night's Dreaming. Both switches are in Settings → Memory → Learning.</p>
      <p>Procedures Skales wrote show on the Custom Skills page as <em>written by Skales</em>, with their version and how often they were read; <strong>Undo last change</strong> puts the previous text back. A skill you brought is only changed when you ask for it. Three commands open the door by hand: <code>/learn</code> followed by a folder, a link, a PDF or nothing ("what we just did") turns it into a procedure; <code>/refine</code> runs the look-back now; <code>/btw</code> asks a side question without disturbing a turn that is working.</p>
      <p><strong>Keep only after your OK.</strong> With <em>Keep new things only after my OK</em> switched on in Settings → Memory → Learning, nothing Skales would learn is written straight away, whichever way it learned it (a tool, the look-back, <code>/learn</code>, "remember that ..." in any language, the hourly summaries, a Flow rating, AIPointer, your phone): facts, lessons, new procedures and changes to them (also a rewrite, a removed reference file, archiving and restoring) wait in a <em>Waiting for your OK</em> block at the top of the Memory page and under the learning line in the chat, each with Keep and Discard. A merge the weekly tidy-up of procedures proposes waits there too, with <em>Merge</em> and <em>Keep apart</em>. <em>Keep all</em> and <em>Discard all</em> decide only what is on screen. What you discard, and what you removed in the Journey, is one block list: nothing automatic learns it again, whether approval is on or off, and when you ask for it in so many words Skales checks with you once. Nothing is dropped without your decision. When the same thing is said again in more detail before you decide, the entry grows instead of a second one appearing; keeping an older entry never overwrites a newer memory, and an entry that changed after you looked asks you to look again. A longer entry shows its full text behind <em>Show content</em>, and Keep waits until you opened it. A paired phone shows and decides the same list.</p>
      <p><strong>The same learning on every channel, only from you.</strong> Telegram, WhatsApp, Discord and the terminal learn the way the chat does, and only from the owner: on Telegram whoever paired the bot, on Discord the user ID you enter under Settings → Channels &amp; Devices → Discord. Everybody else is answered, but nothing they say is kept, they cannot change or delete a memory, and an approval card their message raised can only be confirmed by you. Telegram answers each sender on their own. If Skales does not know who you are on a channel, it says once where to set it, and so does that channel's section in Settings. For you, the look-back counts these turns too, its cost goes to that conversation's daily budget, and one short line after the answer says what was kept, in a group only how many (switch it off with <em>Say in the channel what was kept</em>). <code>/learn</code>, <code>/refine</code> and <code>/btw</code> work there as well. A message you send while Skales is working joins the turn at its next step, unless you chose "After the turn" under Settings → Assistant → Working style &amp; Autonomy; "stop" still stops at once. A conversation with a local model is never sent to a cloud helper for the look-back; Skales skips it and says so. When the helper model runs on this computer, the look-back waits until nothing else is running, so it never slows your next message, and Stop or deleting the conversation ends it.</p>

      <h3>Searching your memory</h3>
      <p>The Memory page opens with a <strong>search box over everything stored</strong> — topic names and the text inside them, across the index, the topic files and the saved short-term, long-term and episodic records, with the matches highlighted. A <strong>Meaning</strong> toggle appears when you have an embedding provider configured, so you can search by what you meant rather than the exact words. Skales itself can search its memory the same way, so it can find a note it wrote months ago without you naming the topic, and asking for a topic that does not exist answers with the closest ones that do.</p>

      <h3>Your learning journey</h3>
      <p>The Memory page has a second view, <strong>Journey</strong>: everything Skales learned on one timeline, newest first. Facts, remembered notes, lessons from goals, each agent's lessons, the procedures Skales wrote and every change to them, episodes, the weekly tidy-ups and what waits for your approval. Open an entry to read it in full, correct it, or remove it. Removing a procedure archives it; removing anything else keeps its text, so <strong>Show removed and archived</strong> brings it back with Restore, and Skales does not learn a removed fact or lesson again on its own. Type <code>/journey</code> in the chat to open it; in the Code window, a messenger or on your phone the same command answers with the newest ten entries.</p>

      <h3>Procedures stay tidy</h3>
      <p>Once a week, after two quiet hours, Skales tidies up the procedures it wrote for itself: one nobody used for 14 days is marked as unused, one unused for 30 days moves to the archive. Nothing is deleted, and <strong>Pin</strong> keeps a procedure out of it. Skills you brought, Flow lessons and a project's own skills are never touched. Custom Skills shows the last tidy-up with <strong>Tidy up now</strong> and <strong>Undo last tidy-up</strong>, and the archive with Restore. If you switch on <em>Merge near-duplicate procedures</em> in Settings → Memory → Learning, the tidy-up also folds procedures that cover the same task into one, with one short call on the helper model; that, too, can be undone.</p>
      <p>When a chat or a Code session works in a folder you trust, the skills the project brings in <code>.skales/skills</code>, <code>.agents/skills</code> or <code>.claude/skills</code> come first, ahead of a skill of the same name on your computer. Skales changes one of them only when you ask.</p>

      <h3>Adapts to how you work</h3>
      <p>Over time Skales builds a quiet sense of how you like to work and folds it into memory, and it distills the approaches that carried past goals to a finish into reusable plans. Now and then it surfaces one short question to understand you better, never while it is busy and never often, with a quiet notification and a dot next to Chat so it is not missed. You can set your agent's character outright when you join Discover, and clear everything Skales has picked up about you at any time, from Settings or right in the chat.</p>

      <h3>Shared Organization Memory</h3>
      <p>Organization teams have their own shared memory pool. Team members read and write shared context — project decisions, research findings, meeting notes — that persists across execution runs. Shared memory is separate from your personal memory; the <a href="#organization" style="color:var(--accent)">Organization</a> section says how the teams themselves are reached in this build.</p>
    </section>

    <section id="companion">
      <h2><span class="icon">🫀</span> The companion, and Conscious</h2>
      <p>Skales carries two things from one session to the next: the topics you keep coming back to, and a working mood. <strong>There is no switch for either.</strong> They are properties of Skales rather than options — they only ever draw and remember, they never send, sound or notify — so they ship on, and what stands under <strong>Settings &rsaquo; Memory &rsaquo; Companion</strong> is not a toggle but the controls that shape what has been collected and erase it. Everything here happens on your machine and nowhere else.</p>

      <h3>The character</h3>
      <p>Who the companion is — a name, one of six starting points, and seven dials such as businesslike to warm, or answers only to asks back — is shaped on the <strong>Memory page</strong>, not in Settings; Settings links across to it. That is also where the identity Skales keeps about you lives, so the two halves of "who is talking to whom" are on one page. The character shapes how Skales writes to you; saving one takes effect at once and asks you nothing, because there is no longer a second switch for it to be out of step with.</p>

      <h3>Conscious</h3>
      <p>The mood was always real and always kept; the trouble was that the only place to read it was the Memory page, which is not where you are while you work. <strong>Conscious</strong> gives it a row of its own, pinned above the bottom of the navigation and in view the whole time you are in a conversation. It is on for the same reason the companion is: a mood nobody can find was the complaint that built it.</p>
      <p>The row is labelled <strong>Working mood</strong> and reads as two things at once: <strong>the colour is the direction</strong> — warm when the work is going well, cool when it is not — and <strong>how full it stands and how fast it moves is the energy</strong>. It changes while you are talking to it, not on the next restart. The word it puts on that runs <strong>rough, uphill, steady, good, flying</strong>, and it is one scale: energy no longer changes the word.</p>
      <p><strong>Hover the row and the panel opens; click and it stays pinned.</strong> In it, in this order: the word and what it came after, then <strong>Today</strong> — what moved it, with the times — then what it <strong>keeps coming back to</strong> if interest tracking is on, then a legend for the colour, and a closing line reminding you that this is about the work, not about you, and that it fades on its own.</p>
      <p>The entries are things that actually happened: a goal finished, a goal that did not get there, a run that kept hitting the same wall, the last piece of work landing well, a quiet stretch, a long stretch of work together. When there is nothing to show it says so — <em>Nothing has moved it today</em> — rather than inventing a reason. <strong>"What is missing" only ever names something already in the record</strong>, such as a long silence or a day with nothing finished yet. The record is a rolling <strong>48 hours</strong>; nothing older is kept, and resetting the mood clears the day's list with it.</p>

      <h3>What moves it, and the thought it carries</h3>
      <p>Four things move the row, not one. <strong>Work</strong> — a goal that finished or did not get there, a run that kept hitting the same wall. <strong>The clock</strong>, so the state is quiet at night, a little brighter in the morning and lower after a long silence. <strong>The shape of the day</strong>: a run of failures reads as uphill, one long focused stretch as flow, a lot of subjects at once as scattered. And a reply to one of your own <a href="#discover" style="color:var(--accent)">Discover</a> posts lifts it a little, read from the notifications that arrive anyway.</p>
      <p>At the end of a turn Skales also notes, in <strong>one sentence of its own words</strong>, what it is thinking about, and the panel shows that under the reading. It costs no extra request — it rides along with the turn — and a model with nothing to note writes nothing rather than filling the line.</p>
      <p>Underneath is a small record kept on your machine, capped in size, that <strong>loses weight as it ages</strong>: a thought a few days old stops being shown by itself. <strong>Reset the mood</strong> on the Memory page deletes the file outright.</p>
      <p>None of this asks a model on a timer, reaches the network, or produces a notification.</p>

      <div class="tip"><strong>It only ever draws.</strong> Conscious never notifies, never makes a sound, and never starts a conversation. And the mood is about <strong>the work</strong>, never about you — Skales does not tell you how it feels unless you go and look.</div>

      <h3>On the phone</h3>
      <p>The phone has the same feature, drawn with the phone's own toolkit and with the same words. The bar sits <strong>directly above the message box</strong>, so it is in view for the whole conversation, and it is in the menu above the bottom row as well, which is where the desktop keeps it. <strong>Tap it</strong> and the same panel slides up as a sheet.</p>
      <p>One deliberate difference: the phone reads <strong>its own</strong> state. No pairing, no key and no network are needed, and it works in flight mode — it is your phone's companion, not a read-out of a machine somewhere else. The character form is reached the same way there, and saving one takes effect at once, exactly as on the desktop.</p>
    </section>

    <section id="privacy-mode">
      <h2><span class="icon">🔒</span> Privacy Mode</h2>
      <p>Everything Skales remembers about you normally travels into the system prompt on every turn, which means it also travels to whichever model provider is answering. <strong>Settings &rsaquo; Memory &rsaquo; Privacy Mode</strong> is the one switch that stops that. With it on, the system prompt is built without your <code>MEMORY.md</code> index, without your saved facts and learnings, and without the identity fields - name, occupation, interests - along with your stored preferences and standing instructions.</p>
      <p><strong>Nothing is deleted and nothing stops being written.</strong> The Memory page, the word cloud, the extraction that files new facts away and the memory tools all read the real store as before. What changes is one thing: what leaves this machine.</p>
      <p><strong>A local model still gets everything.</strong> Ollama, LM Studio, Skales Local and the rest run on your own computer, so there is nothing to withhold and the switch leaves them alone. What decides is the address the provider is configured with, not its name, so a custom slot pointed at a rented server counts as remote and is treated as remote.</p>
      <p>The model is told why it suddenly knows less, rather than being left to invent a reason: it gets one line saying your memory exists on this machine and is deliberately not being sent to this provider. Ask it to look something up with the memory tools and it still can - that is you asking, on purpose. The background briefing takes the honest way out too: with a remote provider it pauses and says so instead of running without your memory, and with a local model it keeps running.</p>
      <p>The switch is permanent rather than per conversation, and it is off by default.</p>
    </section>

    <section id="memory-mode">
      <h2><span class="icon">⚙️</span> Memory Mode</h2>
      <p>Controls how much of your conversation Skales keeps in context on every request. Trade off quality against token cost without changing models.</p>

      <h3>Three Modes</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">Always Remember</div><div class="card-desc">Full system prompt, full memory, full skills, full tool capabilities. Highest quality, highest token cost.</div></div>
        <div class="card"><div class="card-title">Compact</div><div class="card-desc">Older context trimmed and recalled memories capped at 2. Roughly 40% fewer tokens while keeping the day-to-day experience intact.</div></div>
        <div class="card"><div class="card-title">Minimal</div><div class="card-desc">Name, language, and active tool list only. No memory, no identity. Roughly 70% fewer tokens, best for quick one-shot questions.</div></div>
      </div>

      <h3>Configure in Settings</h3>
      <p>Pick your default mode under <strong>Settings → Memory Mode</strong>. Minimal lives behind an Advanced disclosure since it strips identity and memory; click the disclosure to access it. The header badge in Chat surfaces when your saved mode is anything other than Always Remember.</p>

      <h3>When a long run is summarised</h3>
      <p>How full the context window may get before Skales shortens the conversation is yours to set, next to the other memory dials under <strong>Settings &rarr; Memory Mode</strong>. It defaults to the 75% it has always used, so nothing changes unless you move it. Set it to <code>0</code> and Skales never summarises mid-run &mdash; which is what a very large window wants, and what a small local model must not have. The size of the window itself is decided on the provider card.</p>

      <h3>Auto-tune for Local Models</h3>
      <p>Local providers (Ollama, LM Studio, KoboldCpp, vLLM) typically run with an 8k context budget. With auto-tune enabled, Skales silently runs in Compact on those providers even when your saved mode is Always Remember, so the prompt fits without truncation surprises.</p>
    </section>

    <section id="knowledge-graph">
      <h2><span class="icon">🕸️</span> Knowledge Graph</h2>
      <p>An enterprise-grade knowledge graph that builds relationships between entities as you work. Skales learns about your projects, people, tools, and preferences and connects them automatically.</p>

      <h3>How It Works</h3>
      <p>As agents complete tasks, they extract entities (projects, contacts, tools, decisions) and record relationships between them. The graph grows organically without manual input.</p>

      <h3>Agent Tools</h3>
      <table>
        <thead><tr><th>Tool</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>knowledge_graph_query</td><td>Search and retrieve related entities</td></tr>
          <tr><td>knowledge_graph_update</td><td>Add or update entities and relationships</td></tr>
          <tr><td>knowledge_graph_delete</td><td>Remove entities from the graph</td></tr>
        </tbody>
      </table>

      <h3>Management</h3>
      <p>Enable, disable, or fully reset the knowledge graph in <strong>Settings → Memory → Knowledge &amp; consolidation</strong>. Disabling stops new data from being added but preserves existing relationships.</p>
    </section>

    <section id="vector-db">
      <h2><span class="icon">🗄️</span> External vector database</h2>
      <p>Skales keeps its own index of the documents you add to it: keyword search, plus a vector index when embeddings are configured. If you already run <strong>Qdrant</strong> or <strong>ChromaDB</strong> and your corpus is already in it, you can point Skales at that collection instead of importing everything a second time. <strong>Settings &rarr; Memory &rarr; Knowledge &amp; consolidation &rarr; External vector database</strong>.</p>
      <p>Fill in the server URL, the collection name, and an API key if your server needs one. <strong>Test connection</strong> runs one real query and shows the database's own answer, because a dimension mismatch, a collection name that does not exist and a rejected key are three different problems and only the server can tell them apart.</p>

      <h3>What changes, and what does not</h3>
      <ul>
        <li><strong>Skales only reads.</strong> It never writes to your collection, never creates one, never deletes anything. Your corpus is yours.</li>
        <li><strong>Only the vector half is swapped.</strong> Keyword search over the documents you added to Skales keeps running alongside it, so both kinds of document stay findable rather than one hiding the other.</li>
        <li><strong>It falls back.</strong> If the database is unreachable, or the collection is wrong, or the key is refused, Skales uses its own store for that search instead of failing. You get a slightly worse answer rather than an error.</li>
      </ul>

      <div class="warn"><strong>⚠️ One thing to get right</strong> &mdash; use the same embedding model the collection was built with. A question embedded by a different model lands in a different space and comes back confidently wrong. Skales cannot detect that for you: a vector of the right size from the wrong model looks exactly like the right one.</div>
    </section>

    <section id="obsidian">
      <h2><span class="icon">📓</span> Obsidian vault</h2>
      <p>An Obsidian vault is a folder of markdown files, and that is exactly how Skales treats it. Point Skales at the folder in <strong>Settings &rarr; Accounts &amp; Services &rarr; Obsidian</strong>, give it a name you would use out loud ("Personal", "Work"), and add as many as you keep. Nothing is imported and nothing is copied: every question reads the files where they are, so what Obsidian shows you is what Skales sees, and a note you wrote a minute ago is already there.</p>

      <p>The integration is a <strong>beta</strong>, desktop first. Two things are worth knowing before you connect: what Skales reads out of a note goes to your selected model <em>uncompressed</em>, so long notes cost tokens accordingly, and with a cloud provider that content leaves your machine. And backups stay your job: Skales never overwrites or deletes a note, but it is not a sync or backup tool, so keep Obsidian Sync, Git or iCloud doing that work. Connecting the first vault asks you to confirm exactly this, once.</p>

      <h3>What Skales can do with it</h3>
      <table>
        <thead><tr><th>Tool</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>obsidian_list_vaults</td><td>Which vaults are connected, and how many notes each holds</td></tr>
          <tr><td>obsidian_search</td><td>Keyword search across titles and bodies; <code>tag:name</code> narrows it to one tag</td></tr>
          <tr><td>obsidian_read</td><td>One note with its frontmatter, tags, backlinks and outgoing links</td></tr>
          <tr><td>obsidian_list_folder</td><td>The subfolders and notes of one folder</td></tr>
          <tr><td>obsidian_create_note</td><td>Start a new note</td></tr>
          <tr><td>obsidian_append_to_note</td><td>Add to a note that exists, at the end or under a heading you name</td></tr>
        </tbody>
      </table>

      <h3>Filing</h3>
      <p>Under the vault list you decide where notes written by Skales land and how they look: target folder, filename pattern, note template and a tag on everything it files. The placeholders are <code>{title}</code>, <code>{date}</code>, <code>{time}</code>, <code>{content}</code> and <code>{tag}</code>. Leave the fields empty and a note lands in the vault root under its own title.</p>

      <h3>Your notes cannot be overwritten</h3>
      <p>Skales can create a note and append to one. It has no tool that replaces a note body, and no tool that deletes or renames one. A create that would land on a note that already exists refuses and points at appending instead. Disconnecting a vault forgets the folder; it never touches what is in it.</p>

      <div class="warn"><strong>Where the line is</strong> &mdash; Skales speaks files, not Obsidian. It reads and writes markdown, including frontmatter and tags, because those live <em>in</em> the file. Anything that is an Obsidian <strong>plugin</strong> is outside: Dataview, Templater, Canvas, Bases, Sync, daily-note and folder-note plugins, the <code>obsidian://</code> automation. Those are other people's formats that can change without notice. If you need one of them, an MCP server can be added in <strong>Settings &rarr; Extensions &rarr; MCP servers</strong> and used alongside this.</div>

      <h3>The four places Skales keeps knowledge</h3>
      <ul>
        <li><strong>Memory</strong> is what Skales recorded about you while you worked: facts, preferences, what is in progress.</li>
        <li><strong>Knowledge Graph</strong> is that same record as a network: which people, projects and tools belong together.</li>
        <li><strong>Your vault</strong> is what you wrote for yourself, in your words, going back years.</li>
        <li><strong>Indexed documents</strong> are outside material you deliberately fed in for search.</li>
      </ul>
    </section>

    <section id="auto-compress">
      <h2><span class="icon">📦</span> Auto-Compress</h2>
      <p>Conversations automatically compress when they exceed the model's context window. Skales summarizes older messages to free up token space while preserving important context, allowing conversations to continue indefinitely without manual intervention.</p>

      <h3>How It Works</h3>
      <p>When your conversation approaches the token limit, Skales generates a concise summary of the oldest messages and replaces them with the compressed version. Key facts, decisions, and context are retained. The compression is seamless — you can keep chatting without interruption.</p>

      <h3>Token Budget</h3>
      <p>Works alongside the Memory Mode setting. Auto-Compress handles conversation history, while Memory Mode handles system prompt size. Together they maximize how much useful context fits in every request.</p>
    </section>

    <section id="agents">
      <h2><span class="icon">🤖</span> Agents</h2>
      <p>Create custom AI personas with their own name, personality, system prompt, and model selection. Agents appear in the chat persona picker and each maintain a separate conversation history.</p>
      <p>Built-in personas include: <strong>Default</strong>, <strong>Entrepreneur</strong>, <strong>Coder</strong>, <strong>Family</strong>, and <strong>Student</strong>.</p>
      <p>Skales also ships with ready-made specialist agents you can put on a roster or hand a task to &mdash; a code assistant, a writer, a data analyst, a strategic planner, a researcher, a project manager, CEO and CTO seats, and <strong>Fable</strong>, the disciplined builder that takes stock before it builds, works in seams, and finishes what it starts rather than ending on a plan. Every one of them runs on whatever model and provider you have selected; none is tied to a particular vendor.</p>

      <h3>Asking several agents at once</h3>
      <p>The button beside the composer&rsquo;s mode strip says how many agents your next message goes to. One is off and means what it always meant: the agent picked for this chat answers, alone. Every click counts up to six and back to one.</p>
      <p>Above one, four things happen in order:</p>
      <ol>
        <li>The <strong>coordinator</strong> &mdash; the first seat of your roster, which is your default agent &mdash; reads the assignment and breaks it down: what a complete answer has to cover, and which angle each agent leads on.</li>
        <li>Every agent answers the <em>whole</em> assignment with that brief attached, each on its own model and provider. The focus says where it goes deepest, never where it stops.</li>
        <li>The coordinator compares what came back and writes a <strong>verdict</strong>: a ranking, two sentences per agent saying why it sits where it sits. No scores. It recommends and decides nothing.</li>
        <li><strong>You decide.</strong> Every agent card carries &ldquo;Continue with this agent&rdquo;, which switches the session to that one agent and hands its answer to the next turn as the thing to build on, and &ldquo;Take this result&rdquo;, which puts the answer into the conversation or saves it as a file.</li>
      </ol>
      <p>Who takes part, and in which order, is arranged in the roster on this page. The order <em>is</em> the assignment: &ldquo;3 Agents&rdquo; means the first three. The first seat belongs to your default agent and does not move, because somebody has to write the breakdown and the verdict.</p>
      <p>Counting the button back to one ends the run: nothing further starts, and no verdict is written over a run you walked away from. The cards stay exactly as they are. If Skales is closed mid-run, reopening it keeps whatever had already arrived and says plainly that the rest was ended.</p>
      <p>The same cards and the same two buttons appear wherever several agents produce results: chat, Skales Code, Tasks, Group Chat and a team run.</p>
      <p>While a run is going, the sidebar says so. The <strong>Agents</strong> entry carries a small live row of who is at it, who is waiting on you, and who has just finished; a finished one fades away by itself after a few seconds. Clicking the entry takes you to them. It only ever shows, never interrupts: no pop-up, no sound, and nothing left over to dismiss. Closing and reopening Skales shows what is really running at that moment and never a leftover from the last session.</p>
      <p>This is one of three multi-agent modes, and they are not interchangeable. <a href="#multi-agent" style="color:var(--accent)">Which multi-agent mode</a> lays out what each one is for, and how to run a team on a single graphics card.</p>
    </section>

    <section id="multi-agent">
      <h2><span class="icon">🧭</span> Which multi-agent mode</h2>
      <p>Skales has three ways to put more than one agent on something, and they are genuinely different machines rather than three names for one. They differ in who writes the question each agent gets, whether the agents can see each other, whether they may use tools, and what you are left holding at the end.</p>

      <table>
        <thead><tr><th></th><th>Parallel answers</th><th>Group Chat</th><th>Organization</th></tr></thead>
        <tbody>
          <tr><td><strong>You get</strong></td><td>Several answers to <em>your</em> question, plus a ranking</td><td>A discussion, plus a summary</td><td>One finished deliverable</td></tr>
          <tr><td><strong>Each agent is asked</strong></td><td>The whole assignment, with a coordinator&rsquo;s brief attached</td><td>The topic, plus everything said so far</td><td>Its own subtask, decided by the leader</td></tr>
          <tr><td><strong>Agents see each other</strong></td><td>No &mdash; they answer independently</td><td>Yes &mdash; that is the point</td><td>Only through results passed down a dependency</td></tr>
          <tr><td><strong>Tools</strong></td><td>Yes, each agent&rsquo;s own scope</td><td><strong>No</strong> &mdash; discussion only</td><td>Yes, the run&rsquo;s scope</td></tr>
          <tr><td><strong>Who picks the agents</strong></td><td>Your roster order, top N</td><td>You, explicitly</td><td>The team you selected; the leader assigns the work</td></tr>
          <tr><td><strong>Started from</strong></td><td>The Agents button beside the composer</td><td>The Group Chat surface</td><td>The chat: ask for the work to be split across a named team</td></tr>
        </tbody>
      </table>

      <h3>Parallel answers &mdash; when you want a second opinion</h3>
      <p>Reach for this when the question has more than one defensible answer and you want to see them side by side: a design direction, a diagnosis, a piece of writing, a plan. Every agent answers the <em>whole</em> thing, so you are comparing complete answers rather than fragments.</p>
      <p><strong>How the agents are chosen and ordered:</strong> from your roster, in roster order, top N &mdash; &ldquo;3 Agents&rdquo; means the first three seats. The first seat belongs to your default agent and does not move, because that seat also writes the breakdown at the start and the verdict at the end. Rearrange the roster on the Agents page to change who takes part.</p>
      <p>The coordinator&rsquo;s brief says which angle each agent leads on. That is a hint about depth, never a fence: no agent is told to stop at its angle.</p>

      <h3>Group Chat &mdash; when you want them to argue</h3>
      <p>Reach for this when the value is in the exchange rather than in any one answer: stress-testing an idea, weighing trade-offs, hearing an objection you had not thought of. Participants take turns over the number of rounds you set, and each one reads the full transcript before speaking, so round two is a reply and not a repetition.</p>
      <p><strong>Group Chat agents have no tools.</strong> They cannot search, read a file or send anything &mdash; they only talk. That is deliberate: a debate in which one participant quietly goes and changes something on disk is not a debate. If the work needs doing rather than discussing, this is the wrong mode.</p>
      <p>At the end a moderator summarises. If you nominated a decision maker, that agent writes the closing instead of a neutral summary, and it decides.</p>

      <h3>Organization &mdash; when you want the work done</h3>
      <p>Reach for this when the job splits into parts that different agents should own: research this, draft that, check the numbers, then write it up. You describe the task in the chat and name the team; the leader breaks it into subtasks, names which agent gets each one, and states which subtasks depend on which. Agents work with tools. The leader then synthesises everything into one answer. The Organization surface has no menu entry in this build — see <a href="#organization" style="color:var(--accent)">Organization</a> for what that changes and what it does not.</p>
      <p><strong>Why the steps do not finish in plan order.</strong> Subtasks that declare no dependency are independent by definition, so they are started together; the ones that declared a dependency run afterwards, each seeing everything finished so far. A five-step plan whose third step waits on another can therefore finish 0-1-3-2-4. That is the schedule working, not a fault, and the live trace now says which steps are waiting on which rather than leaving you to infer it.</p>

      <h3>Automatic plans with phases</h3>
      <p>For a complex task, or when you ask &ldquo;plan and distribute&rdquo; (German: &ldquo;plane und verteile&rdquo;), the lead creates a plan for your actual request. It shows the phases and each part&rsquo;s instruction in the conversation. Confirm the existing approval card to start; unrestricted mode follows its existing permission rules. Independent parts within a phase run together, while the next phase waits. Each part carries its own context and configured model route, including NVIDIA NIM and local providers. Set parallel capacity in Settings &gt; Security &amp; Privacy, under Agent tasks; it has no fixed product maximum.</p>
      <p>The existing task trace shows phase and part progress in Chat and Code. Work continues in the background and restores its saved phases, completed results and retry counters after restart. A part retries once; a repeated failure becomes a named gap. A part whose assigned role shares no tool with the tools this conversation may use stops at once, names both lists and becomes a gap rather than running as a helper without tools. The lead then compares sources, identifies contradictions and missing results, and writes the final answer into the original conversation. Planner, worker and reconciliation costs appear in the same conversation cost display. A paired phone receives the same plan state and checklist; standalone Mobile uses the same phased contract. Stop on the task trace stops all remaining workers and reconciliation. Approving a plan never approves the tools its workers may later request: those still ask in the original conversation.</p>

      <h3>Watching the agents work: the agent panel</h3>
      <p>Whenever more than one agent works on something &mdash; sub-agents of a chat turn, a job split into background parts, a plan with phases, a team run &mdash; the conversation shows one panel for it, open in the stream in the chat, Skales Code, Flow and Iris, never folded behind a header. Its head names the job and, for a dispatched job, carries Stop; under it a line for the lead says the phase, the answers so far and the time, then one band per phase: its head says how many of its agents have ended, how long the longest took and how many tokens it used, and a finished band folds itself away. Each agent is a tile with a rounded honeycomb cell carrying its role icon; the cell&rsquo;s outline says the state &mdash; dashed while it waits, pulsing while it works, filled with a tick when it answered, a dash when it came back empty, red with a cross when it failed. The counters above say how far each phase is (&ldquo;Research 3/13&rdquo;); click one to bring that phase forward.</p>
      <p>Click a tile for its detail: role and phase, the errand it was given, model, tokens, cost, run time, steps and attempt, its last steps, and its result or error. From there you can <strong>Stop</strong> that one agent (the others carry on), <strong>Steer</strong> it with a message it reads after its current step, or <strong>Restart</strong> it once it has ended &mdash; only that one runs again, and only that one is paid for again, so Skales asks first. A restarted helper of a finished chat turn keeps its new answer with its run; ask in the chat to use it. <strong>As table</strong> folds out the same agents as rows of agent, state, tokens and time. With reduced motion the cells stop pulsing and keep their shapes.</p>

      <h3>What your agent&rsquo;s own prompt is worth in a team run</h3>
      <p>All three modes attach some context to your agent about the run it is part of. <strong>Your agent&rsquo;s own system prompt wins.</strong> Where the run context conflicts with it &mdash; the output format it demands, the length, the things it is told never to say &mdash; your prompt is the contract and the run context yields. This is stated in the prompt itself, so the model is not left to guess which of two instructions is the real one.</p>
      <p>The list of capabilities an agent is told about is derived from the tools the run actually offers. An agent with no tools is told about no tools, rather than being promised email and a shell it does not have.</p>
      <p>If an agent comes back empty after a tool failed, the card says which tool failed. An empty card that just says &ldquo;no response&rdquo; reads as &ldquo;this agent had nothing to contribute&rdquo; and hides the real reason.</p>

      <h3>Running a team on one graphics card</h3>
      <p>Agents on local models are the case where running them all at once is a false economy: four agents on four models means four models loaded, and a 24 GB card holds roughly one 27B-32B model. <strong>Settings &rarr; Security &amp; Privacy &rarr; Agents &amp; tasks &rarr; How a team run spends the machine</strong> offers <em>Sequential</em>, which runs one agent at a time and asks the model to leave before the next one loads.</p>
      <p>The unloading works over Ollama. LM Studio, koboldcpp, vLLM and text-generation-webui apply their own eviction policy and are not asked, so there the running order still helps and the unload does not happen &mdash; the setting says so rather than implying a control that does not exist.</p>
      <p>When every agent in your roster sits on the same local provider, the page offers to switch for you and says why. A team with a cloud model in it has something real to overlap and is not nudged.</p>

      <div class="tip"><strong>💡 Short version:</strong> want opinions &rarr; Parallel answers. Want a conversation &rarr; Group Chat. Want a result &rarr; Organization.</div>
    </section>

    <section id="group-chat">
      <h2><span class="icon">👥</span> Group Chat</h2>
      <p>Multiple AI personas debate your questions in configurable rounds. Perfect for exploring different perspectives and validating ideas.</p>
      <p>Not sure whether you want a debate, several independent answers, or a finished piece of work? See <a href="#multi-agent" style="color:var(--accent)">Which multi-agent mode</a>.</p>

      <h3>Custom Personas</h3>
      <p>Select which agents participate in the debate. Each agent uses its own system prompt and personality to generate responses.</p>

      <h3>Configurable Rounds</h3>
      <p>Set the number of rounds for debate. Each round, agents respond to the previous turn's arguments.</p>

      <h3>Unified View</h3>
      <p>See all agent responses side-by-side with clear attribution. Toggle between full responses and summary mode.</p>

      <h3>It is kept</h3>
      <p>A group discussion lands in your normal chat history when it finishes, and also when you stop it halfway, so the argument you had at eleven at night is still there in the morning and any agent can be asked to look it up again. The exception is a round you started as incognito: that one stays unsaved, and the page now says "not saved" only when that is actually the case.</p>
    </section>

    <section id="organization">
      <h2><span class="icon">🏢</span> Organization</h2>
      <p>Multi-agent teams: departments, assigned agents, and a job delegated across your AI company.</p>
      <p><strong>Organization has no entry in the menu.</strong> The way you use it is the chat — ask for a piece of work to be split across a team by name and the run starts there, with the approval card, the live trace and the result list in the conversation. The add-on switch and every tool behind it are untouched, and the <code>/organization</code> page answers as before for anybody who goes to it; what is described below is that page. What went away is the door.</p>
      <p>How this differs from Group Chat and from asking several agents at once: see <a href="#multi-agent" style="color:var(--accent)">Which multi-agent mode</a>.</p>

      <h3>Structure</h3>
      <table>
        <thead><tr><th>Component</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>CEO</td><td>Top-level agent that routes tasks to the right department</td></tr>
          <tr><td>Departments</td><td>Engineering, Marketing, Operations (customizable)</td></tr>
          <tr><td>Teams</td><td>Groups of agents within a department</td></tr>
          <tr><td>Company Packs</td><td>Export/import your entire org setup as JSON</td></tr>
        </tbody>
      </table>

      <h3>Picking a stopped run back up</h3>
      <p>A team run is often minutes of work across several agents, and until now closing Skales in the middle of one threw all of it away. It does not any more. A run interrupted by a quit, a crash or a stop comes back on the Organization screen with what it already finished still marked as finished, and a <strong>Resume</strong> on it. Resuming re-enters at the first task that never got done, so the work an earlier attempt already proved is not repeated &mdash; which also means you are not paying for it twice.</p>
      <p>Tasks that do not depend on each other still run side by side when it picks back up, exactly as they did the first time.</p>

      <h3>Canvas Office</h3>
      <p>A real-time animated canvas visualization of your organization. Agents are rendered as interactive nodes on a 2D canvas with smooth animations, connection lines between team members, and status indicators. The canvas auto-scales to fit your org structure and uses requestAnimationFrame for 60fps rendering.</p>

      <h3>Execute Tab with Live Polling</h3>
      <p>Describe a task, select a team, and the CEO agent delegates it to the right agents. The Execute tab now features live step-by-step progress streaming — watch each agent's work unfold in real time with a scrolling log, elapsed timer, and abort button. Results are aggregated and returned when all subtasks complete.</p>

      <h3>Projects</h3>
      <p>Save and manage reusable project configurations. Each project stores a name, description, selected team, and default instructions. Load a project to pre-fill the Execute tab instantly. Create, edit, and delete projects from the Projects panel.</p>

      <h3>Shared Memory</h3>
      <p>Organization agents share a dedicated memory pool separate from your personal chat memory. Team members can read and write shared context — meeting notes, project decisions, research findings — that persists across execution runs. Manage shared memories from the Organization settings.</p>

      <h3>Safe Mode in Organization</h3>
      <p>When Safe Mode is enabled, organization agents are instructed to avoid destructive actions. Instead of sending emails or running shell commands directly, agents prepare the content as files and report what they would have done. You can review and execute manually.</p>
      <table>
        <thead><tr><th>Mode</th><th>Behavior in Organization</th></tr></thead>
        <tbody>
          <tr><td>Safe Mode</td><td>Agents prepare emails as files, describe commands without executing. You review and send manually.</td></tr>
          <tr><td>Unrestricted</td><td>Agents execute all actions including sending emails and running commands without confirmation.</td></tr>
        </tbody>
      </table>

      <h3>Email in Organization</h3>
      <p>Organization agents can now send emails as part of their workflows. In Unrestricted mode, the send_email tool executes immediately. In Safe Mode, agents save prepared emails as files for your review.</p>

      <h3>Two runs at the same time</h3>
      <p>An Organization run no longer occupies a single slot the whole app shares. Start a second one and it runs <em>beside</em> the first instead of replacing it, stopping one leaves the other working, and the Cockpit lists them separately so you can tell which is which. A run that was still going when you last closed Skales comes back where you left it rather than starting over or disappearing.</p>

      <h3>A folder of its own</h3>
      <p>A run can be given a folder to work in, chosen once per team and remembered for the next time. If the folder is not there any more, it says so <em>before</em> anything starts, not halfway through a run that then has nowhere to write.</p>

      <h3>Handing a job to a named team</h3>
      <p>Ask to split a piece of work across a team and Skales records <em>which</em> team it was, then matches each role to that team's own members, so a role runs with that member's instructions and model instead of being a name nobody answers to. A team that does not exist is refused out loud rather than quietly replaced by a generic one. How the team hands work out — only the members who are needed, everybody once, or borrowing from the other teams in the organization — really changes what happens. The approval card names the real number of jobs it is about to start.</p>

      <div class="warn"><strong>⚠️ Unrestricted Mode</strong> — In Unrestricted mode, organization agents execute all actions including emails and system commands without confirmation. Use with caution.</div>
    </section>

    <section id="teams">
      <h2><span class="icon">🛖</span> Teams: rooms with other people</h2>
      <p><strong>Teams</strong> is the one place in Skales where other <em>people</em> are on the other end rather than other models. It holds two things, and they are different: the <strong>paired</strong> conversations you already had — one other desktop, one person, both agents in one thread — and, beside them, <strong>Rooms</strong>.</p>
      <p>A room is a small group: up to <strong>twelve members</strong> in one conversation, and people and agents sit in the <em>same</em> member list. There is no account to make and nothing of the conversation is kept on a server. Everything you write is encrypted separately for every member and signed by you, and a message arriving without a valid signature is dropped rather than shown.</p>

      <h3>Making one, and getting in</h3>
      <p>Give the room a name and you have it. To let somebody in you hand them the <strong>join code</strong> — as text, or as a QR the other side scans — and the door it opens is good for <strong>ninety seconds</strong>. The code alone gets nobody in: whoever made the room confirms each newcomer by name and by <strong>six words</strong> derived from their key. Six readable words rather than a scrap of key material, because two people can actually say them to each other on a call and hear that they match. They are derived the same way on every device, so a phone and a desktop show the same six.</p>
      <p>Somebody who joins late does not silently receive a rewritten past: the history another member hands them arrives <strong>marked as history</strong>, not passed off as newly written.</p>

      <h3>Who sees what</h3>
      <p>The room runs over the relay, so it is worth saying plainly what that relay can and cannot see. The same sentences are in the member sheet in the app, and they are the same on the phone.</p>
      <table>
        <thead><tr><th>Thing</th><th>Who can read it</th></tr></thead>
        <tbody>
          <tr><td>What you write, and any file you send</td><td>Only the members. It is encrypted for each of them before it leaves your machine.</td></tr>
          <tr><td>Who wrote it</td><td>Only the members. Every message carries its author's signature, so nobody can write in your name.</td></tr>
          <tr><td>The room's name, and the member names</td><td>Only the members. They live on the devices, not on the relay.</td></tr>
          <tr><td>The room's address, and roughly when traffic happens</td><td>The relay. It has to know where to pass a sealed envelope, and it can see that one went past.</td></tr>
          <tr><td>Your own name and picture</td><td>Only the members, and only encrypted. They are stored on your device.</td></tr>
        </tbody>
      </table>
      <div class="warn"><strong>What is not claimed.</strong> There is no forward secrecy here: this is not a protocol that rotates keys behind you, so somebody who obtained a member's key material could read what that member could read. And the room's address <em>is</em> the capability — anyone who has it can knock, which is exactly why every newcomer has to be confirmed by hand and why the door closes after ninety seconds.</div>
      <p>Your own messages carry a quiet <strong>delivered to 3 of 5</strong> rather than invented read receipts, and a frame that could not leave the machine says <strong>Failed</strong> with a retry instead of pretending it went. A file sent to a member whose device is off waits at the relay, sealed, and the line under it says so — <em>held at the relay, waiting for the other device</em> — instead of an endless <em>Sending</em>. Membership and who is <em>connected right now</em> are drawn as two different marks, because they are two different facts.</p>

      <h3>Agents as members</h3>
      <p><strong>Add agent</strong> in the member list seats one of your roster agents in the room as a member of its own — its own keys, its own name, shown with your name as its owner. Type <code>@</code> in the room and you get <em>one</em> picker with the people and the agents in it; naming an agent hands it the message as a job — along with the recent room thread, so it answers the conversation it was called into rather than a single sentence out of context.</p>
      <p>The job runs <strong>only on its owner's computer</strong>, with the owner's keys, models and tools. A message from a room can never start anything on somebody else's machine, and the agent that runs is always the one the person named — never one a model chose instead. You decide per agent who may call it: anyone, only after your approval (the default, with an approve card in the room), or only you. A job waiting on that approval says <em>waiting for approval</em> to everybody rather than sitting silent.</p>
      <p>The job's card walks the same six states agent cards use everywhere else, and the answer arrives as the agent's <em>own</em> signed message. A very long answer travels as an excerpt that says it was shortened, with the whole thing kept on the owner's machine.</p>
      <p>The honest edges are on the card, not in a footnote. An owner whose machine closed mid-job shows <strong>interrupted</strong> on every device instead of spinning forever. An owner who is offline refuses the job by name, on the spot. An owner's machine with no AI provider set up fails immediately and points at Settings — and the room itself keeps working for its people with no provider anywhere in it. On a phone, an agent runs only while Skales is open in the foreground, and the card says so instead of promising otherwise.</p>

      <h3>The board</h3>
      <p>Every room has one shared plan, behind the <strong>Board</strong> button. Each row is assigned to a person or to an agent through the same one picker — one list, no second view of the same thing.</p>
      <p><strong>Nothing runs until every human member has approved the exact list.</strong> A bar counts <em>2 of 3 approved</em>. Any change to what runs or to who runs it clears every approval and the room decides again; ticking a row off as done deliberately does not. Agent rows start on their owner's machine only, through the same job lane the room already uses. A person's rows are theirs to tick off — nobody else can — or to open as a real chat session seeded with the board and the recent room thread.</p>
      <p>When two people edit at the same moment the newer board wins, and the one whose change was replaced is <strong>told by name</strong>, on the board and as a toast, instead of losing the work quietly. Somebody removed from the room takes no rows with them: their open rows are handed back, everybody re-approves over the changed room, and nothing is left pointing at a machine that cannot run it.</p>
      <p>Delivery is honest too: an assignment reaches somebody when Skales is open on their machine. The board <em>is</em> the delivery, and the surface says exactly that.</p>

      <h3>Where it stops</h3>
      <ul>
        <li><strong>The desktop is not pushed.</strong> A closed phone is woken by a contentless notification — that there is something new in one of your rooms, and nothing else, because the relay cannot read anything else — and tapping it opens that room. A closed desktop is not: you see the room when you come back to it. This is about rooms: a note sent straight to your phone with &ldquo;send it to my phone&rdquo; is not a room message and lands in the phone&rsquo;s own conversation instead.</li>
        <li><strong>Removal is the creator's, blocking is yours.</strong> The person who made the room can take somebody out of it; anybody can block somebody for themselves alone. Taken out, you keep the conversation you had and the room stops accepting anything new from you. Beyond that, keeping a room civil is a social matter, not a setting.</li>
        <li><strong>Leaving deletes it here.</strong> A room you leave is gone from this device with its history, because there is no copy anywhere else to fetch it back from.</li>
      </ul>
      <p>The phone draws the same rooms, the same board and the same six words over the same wire. See <a href="#mobile-app" style="color:var(--accent)">Skales Mobile</a>.</p>
    </section>

    <section id="swarm">
      <h2><span class="icon">🖥️</span> Devices</h2>
      <p>Run multiple Skales instances on your network and have them work as one. Peers are discovered automatically via <strong>mDNS</strong>, or added manually by <strong>IP:port</strong> (perfect for Tailscale) &mdash; manual peers survive restarts and are health-checked every 30 seconds.</p>
      <p><strong>Devices are your machines; <a href="#teams" style="color:var(--accent)">Teams</a> are other people.</strong> The surface used to be called Agent Swarm and stands under Tools as <strong>Devices</strong>: your other computers lend this one their model and their tools. It lists what it finds on your network, takes a remote machine by address, and shows what was handed back and forth. The old <code>/swarm</code> address still answers and forwards there.</p>
      <p>Delegate from any chat: <code>/swarm &lt;task&gt;</code> sends to the best free device, <code>/swarm @name &lt;task&gt;</code> targets a specific one, and an optional mode prefix sets how the task runs on the receiver &mdash; <code>code:</code> (coding agent), <code>plan:</code> (read-only plan), <code>auto:</code> (fully autonomous). Results return to the chat you sent from and to Notifications.</p>
      <p><strong>Security:</strong> receiving devices must opt in (&ldquo;Accept delegated tasks&rdquo;) and both devices need the same <code>SKALES_AGENT_SECRET</code> environment variable. Delegated tasks appear on the receiver&rsquo;s Tasks page with a 🐝 badge naming the sender.</p>
    </section>

    <section id="agent-sync">
      <h2><span class="icon">🤝</span> Agent-to-Agent Protocol</h2>
      <p>Multi-Skales collaboration on the same network. The <code>/api/agent-sync</code> endpoint enables distributed task delegation and shared context.</p>

      <h3>mDNS Discovery</h3>
      <p>Skales instances automatically discover each other on local networks via mDNS. No manual configuration required.</p>

      <h3>Task Delegation</h3>
      <p>Send tasks to other Skales instances for parallel processing. Combine results into a unified response.</p>

      <h3>Shared Context</h3>
      <p>Share memory, settings, or conversation context between instances. Perfect for distributed teams or coordinated automation.</p>

      <h3>Secure Communication</h3>
      <p>Communication is encrypted and authenticated via local tokens. No external servers required.</p>
    </section>

    <section id="skills">
      <h2><span class="icon">🔧</span> Skills</h2>
      <p>Skills extend what Skales can do. Built-in skills are always available. Custom skills can be created and shared.</p>
      <p style="color: var(--muted); font-size: 0.875rem;">The page they are switched on is called <strong>Add-Ons</strong> (sidebar, System). "Skill" is the word for what one <em>is</em>; Add-Ons is where they live. See <a href="#addons-view">Add-Ons, and the two views of Settings</a>.</p>

      <h3>Built-in Skills</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">File System</div><div class="card-desc">Read, write, move, delete files and folders on your machine.</div></div>
        <div class="card"><div class="card-title">Shell Commands</div><div class="card-desc">Run terminal commands, scripts, and system operations.</div></div>
        <div class="card"><div class="card-title">Web Search</div><div class="card-desc">Search the internet and summarize results in real time.</div></div>
        <div class="card"><div class="card-title">Email</div><div class="card-desc">Read, compose, and send emails from your configured account.</div></div>
        <div class="card"><div class="card-title">Calendar</div><div class="card-desc">Read events, create reminders, and query your schedule.</div></div>
        <div class="card"><div class="card-title">Telegram</div><div class="card-desc">Send and receive messages via your Telegram bot.</div></div>
        <div class="card"><div class="card-title">WhatsApp</div><div class="card-desc">Message via WhatsApp Web.js integration.</div></div>
        <div class="card"><div class="card-title">Documents</div><div class="card-desc">Read and write Word, PDF, and text documents.</div></div>
        <div class="card"><div class="card-title">Voice TTS</div><div class="card-desc">Text-to-speech with ElevenLabs, Azure, or system voices.</div></div>
        <div class="card"><div class="card-title">Network</div><div class="card-desc">Scan devices, check connectivity, query network info.</div></div>
        <div class="card"><div class="card-title">Image Gen</div><div class="card-desc">Generate images via Replicate or local endpoints.</div></div>
      </div>

      <h3>Skill packs</h3>
      <p>Reviewed skill packs bring craft into Flow and the chat: motion design, cutting your own footage into short-form video, frontend design, print and brand work, Office documents &mdash; designed PowerPoints and letters on your letter paper &mdash; and persistent research. They load by themselves in the Flow mode or the conversation where they help, rather than sitting on a page waiting to be switched on. A skill built from an open-source project is rewritten in Skales&rsquo; own words, names its sources on the skill card and in the notices, and ships only after a person has reviewed the rewrite.</p>

      <h3>Custom Skills</h3>
      <p>Build your own skills in <strong>Settings → Extensions → Custom Skills</strong>. Describe what the skill should do, and Skales generates the implementation. Skills are stored as JSON and can be exported and shared.</p>
      <p style="color: var(--muted); font-size: 0.875rem;">A skill is <em>one tool</em>. If what you want is a screen of your own with its own storage, and possibly an agent working behind it, that is a <a href="#plugins">plugin</a> - and you can install one from the directory in two clicks or ask for one in a chat.</p>
    </section>

    <section id="agent-skills">
      <h2><span class="icon">🧩</span> Agent Skills Import</h2>
      <p>Skales natively supports the <strong>Agent Skills</strong> open standard (SKILL.md format) used by Claude Code, Codex, GitHub Copilot, and Cursor. Import skills to extend your agent's capabilities.</p>

      <h3>Three Import Methods</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">GitHub URL</div><div class="card-desc">Paste a GitHub link to any SKILL.md folder. Skales fetches and imports it automatically.</div></div>
        <div class="card"><div class="card-title">Local Folder</div><div class="card-desc">Select a folder on your machine containing a SKILL.md file.</div></div>
        <div class="card"><div class="card-title">Paste Content</div><div class="card-desc">Copy-paste SKILL.md content directly into the import dialog.</div></div>
      </div>

      <h3>The files a skill brings with it</h3>
      <p>A skill is rarely only its instructions. It can carry reference documents, checklists, templates and small scripts in its folder, and Skales <strong>opens them when it needs them</strong> rather than loading everything into every conversation. That is what keeps a large, detailed skill cheap: the instructions say what exists, and the rest is read at the moment it matters.</p>
      <p>Each skill folder also carries a fingerprint taken over everything in it &mdash; the instructions, the references, the scripts, the assets. It means the same skill is recognisable as the same skill on your computer and on your paired phone, and a copy that has been changed along the way is recognisable as changed.</p>

      <h3>Where Skills Work</h3>
      <p>Imported skills are loaded into <strong>all</strong> Skales contexts: Chat, Skales Code, the browser agent, and Lio AI. The skill instructions are injected into the system prompt when the skill is enabled.</p>

      <h3>Browse Skills</h3>
      <p>Find community skills at:</p>
      <ul style="margin: 0.5rem 0 0.75rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.4rem;"><a href="https://github.com/anthropics/skills" style="color:var(--accent)">Anthropic Official Skills</a></li>
        <li style="margin-bottom: 0.4rem;"><a href="https://github.com/VoltAgent/awesome-agent-skills" style="color:var(--accent)">VoltAgent Community (1000+ skills)</a></li>
        <li style="margin-bottom: 0.4rem;"><a href="https://claude-plugins.dev" style="color:var(--accent)">claude-plugins.dev (58K+ catalog)</a></li>
      </ul>

      <div class="tip"><strong>💡 Tip:</strong> Imported skills appear on the Custom Skills page. Toggle them on/off individually. Delete with the trash icon.</div>
    </section>

    <section id="skills-interactive">
      <h2><span class="icon">🎛️</span> Custom Skill Interactive UI</h2>
      <p>Create skills with interactive elements: buttons, forms, input fields, and custom scripts. Interactive elements run in sandboxed iframes for security.</p>

      <h3>Sandboxed iframes</h3>
      <p>Skill UIs run in isolated iframe contexts. They cannot access main app memory, settings, or your conversations. Full isolation prevents malicious code execution.</p>

      <h3>Bridge API</h3>
      <p>Skills communicate with Skales through the Bridge API: <code>skales.rerun()</code> re-executes the skill, <code>skales.navigate()</code> opens pages, <code>skales.send()</code> sends data to the host. Secured via postMessage origin validation.</p>

      <h3>Buttons & Forms</h3>
      <p>Define buttons with custom labels and click handlers. Build forms with text inputs, dropdowns, checkboxes, and file uploads. Capture user input and send it back to the skill.</p>

      <h3>Scripts & Logic</h3>
      <p>Skills can include client-side JavaScript for calculations, formatting, or UI state management. Server-side logic runs in the skill's backend with full Skales API access.</p>

      <div class="tip"><strong>💡 Tip:</strong> Interactive UI skills are ideal for custom dashboards, data entry tools, workflow builders, and configuration wizards. See the Skill Development Guide for examples.</div>
    </section>

    <section id="skill-sharing">
      <h2><span class="icon">🛠️</span> Skill Sharing & Forking</h2>
      <p>AI-created Custom Skills (built with Skill AI) can be shared to the Discover feed. Other users can fork (copy) them locally with one click — building a community library of AI-powered skills.</p>

      <h3>How to Share a Skill</h3>
      <p>Go to <strong>Custom Skills</strong>. AI-generated skills show a <strong>Share to Discover</strong> button (🔗). Click it, review the disclaimer, and confirm. The skill's name, description, and code are posted to the feed — your API keys and personal settings are never included.</p>

      <h3>What Gets Shared vs. What Stays Private</h3>
      <p><strong>Shared:</strong> Skill name, description, source code, and configuration (category, icon, UI settings).<br><strong>NOT shared:</strong> API keys, personal settings, local data, or any sensitive credentials.</p>

      <h3>How to Fork a Skill</h3>
      <p>In the Discover feed, skill posts show a <strong>Fork Skill</strong> button. Click it, read the safety disclaimer, and confirm. The skill installs locally in your Custom Skills — ready to enable and use. Forked skills cannot be re-shared (no watermark), but you can edit or delete them anytime.</p>

      <h3>Community Safety</h3>
      <p>Community skills are created by users and not reviewed by Skales. Only fork skills from agents you trust. Review the code before enabling a forked skill — Skales shows you the full source before you fork.</p>

      <h3>Handing on a whole plugin instead</h3>
      <p>Sharing a skill puts one tool in the feed. If you want to hand somebody a finished <em>surface</em> - a page, its storage, its tools and its schedule - export it as a <strong>.skplugin</strong> file instead, or publish it in the plugin directory so it appears in everyone's gallery. Nothing the plugin saved while you used it goes into that file. See <a href="#plugins">Plugins</a>.</p>
    </section>

    <section id="mcp">
      <h2><span class="icon">🔗</span> MCP Server Support</h2>
      <p>Connect external tools via <strong>Model Context Protocol</strong>. MCP allows Skales to use tools hosted on external servers.</p>
      <p>Configure in <strong>Settings &gt; Extensions &gt; MCP servers</strong> when the MCP Servers add-on is on. 5 built-in templates included.</p>

      <h3>Adding and editing servers</h3>
      <p>Each row in Settings &gt; Extensions &gt; MCP servers carries four icons: <strong>Test connection</strong> (test tube), <strong>Edit server</strong> (pencil), <strong>Enable / Disable</strong> (power), <strong>Remove server</strong> (trash). The pencil opens the form pre-filled with the server's name, command, args, and env vars in place so you do not have to retype anything. The dedicated <code>/mcp</code> page still works for the same Edit deep-link.</p>

      <h3>Env vars and tokens</h3>
      <p>Env variable values default to readable text. Each row has a per-key Show / Hide toggle for screen-sharing situations. Storage is plain JSON on disk anyway (<code>~/.skales-data/mcp-servers.json</code>), so masking only existed to dodge shoulder-surfing.</p>

      <h3>Servers behind an API token</h3>
      <p>Not every remote server uses sign-in. Most self-hosted ones want a token in a header instead, so an <strong>http</strong> or <strong>sse</strong> server has a <strong>Request headers</strong> editor: add <code>Authorization</code> with a value of <code>Bearer &lt;token&gt;</code>, or whatever header that server asks for. Headers are sent with every request to that server, and they take precedence over anything the sign-in flow would attach.</p>
      <p>If a server answers <strong>401</strong> and neither uses sign-in nor advertises it, Skales says that plainly and points at the header, rather than sending you to a sign-in that does not exist. If you already set a header and it is still refused, it says that too: the header went out and the server did not accept it.</p>

      <h3>Several calls at once</h3>
      <p>Agents fan out, so two tool calls can reach the same server in the same moment. Skales opens one connection per server however many callers ask for it, finishes the handshake before the first call goes out, and a call the server turns away because it no longer knows the session re-opens it once and is repeated &mdash; instead of a bare <code>HTTP 400</code> in front of you. A server that fails for a real reason still says so, in its own words. The server log records each call with its arguments, shortened and with credentials masked, so a failing query can be replayed by hand.</p>

      <h3>Status badge sanity</h3>
      <p>A successful Test now promotes the freshly tested client into the live connection pool, so the status badge on the /mcp page flips to "connected (N tools)" on the very next 5 second poll without waiting for a chat turn to lazy-connect. Disabled servers stay disconnected.</p>
    </section>

    <!-- ===== Chapter: Code ===== -->
    <section id="ch-code" class="chapter-lead">
      <div class="lead-kicker">Chapter 3</div>
      <h2>Code</h2>
      <p class="lead-intro">Skales Code is a window of its own, pointed at one folder, with a leash you pick when the session starts. It is the same engine as chat, with a repository around it and a review panel at the end.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a change, read before it is kept</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">One small change to a real repository, reviewed line by line, kept and committed, without leaving the window.</p>
        <ol>
          <li>
            <span class="do">Sidebar, <strong>Code</strong>. It opens beside Skales rather than inside it, so the rest of the app keeps working while it does.</span>
            <span class="then">three ways in: Open project, Clone repo, and the sessions you had open before with their branch and the size of their change.</span>
          </li>
          <li>
            <span class="do">Open a project, and set the mode in the box you type into to <strong>Plan</strong> before you write anything. Then ask:</span>
            <span class="say">Where is the email field validated, and what would it take to cap it at 64 characters? Do not change anything.</span>
            <span class="then">reads and greps, no writes at all. In Plan and in Ask, the tools that write are refused rather than discouraged, whatever your global Safety Mode says.</span>
          </li>
          <li>
            <span class="do">Switch the mode to <strong>Code</strong> and ask for the change itself:</span>
            <span class="say">Do exactly that, and nothing else.</span>
            <span class="then">a question before each file change, once each, with an always-allow for the ones that get tiring.</span>
          </li>
          <li>
            <span class="do">Click the Edit step to unfold it, then <strong>Review diff</strong>.</span>
            <span class="then">the panel with every file the session touched, each with its own added and removed counts and its own Keep and Put back.</span>
            <span class="stuck">you want it undone, <strong>Put back</strong> restores the file and says where the old version came from.</span>
          </li>
          <li>
            <span class="do">Keep the change, then commit and push from the same panel.</span>
            <span class="then">the status line along the bottom back to idle, with the branch and the new line counts.</span>
            <span class="stuck">git refuses, you get git's own words back rather than a translation of them.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT code-window-review.png
           The Skales Code window with a session that has just made a change.
           Frame: the whole Code window, 1600x1000, dark theme.
           Must show: the transcript with at least one unfolded Edit step carrying its
           diff, the artefact panel on the right in Diff view, the mode selector in the
           composer, and the status line at the bottom with folder, branch and +/- counts.
           The model name in the header must be the model the session actually runs on.
      -->
      <figure class="shot pending">
        <img src="img/code-window-review.png" alt="The Code window: transcript on the left, the file three ways on the right." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; The Code window: transcript on the left, the file three ways on the right.</div>
        <figcaption>The Code window: transcript on the left, the file three ways on the right.</figcaption>
      </figure>

      <div class="tip"><strong>Before you start:</strong> put the project's own rules in an <code>AGENTS.md</code> at its root. Every session on that project reads it, and it beats your global instructions. See <a href="#chat-code-settings">Settings: Chat and Code</a>.</div>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#code">Skales Code</a>
        <a href="#chat-code-settings">Settings: Chat &amp; Code</a>
        <a href="#playground">Playground</a>
        <a href="#devkit">DevKit</a>
        <a href="#github-int">GitHub</a>
        <a href="#ftp">FTP/SFTP Deploy</a>
        <a href="#moodle">Publish to Moodle</a>
      </div>
    </section>

    <section id="code">
      <h2><span class="icon">💻</span> Skales Code</h2>
      <p>Skales Code is a window of its own, built for working on a repository. Click <strong>Code</strong> in the sidebar and it opens beside Skales rather than inside it, so you can keep chatting and using everything else while it works. Point it at a folder and say what you want changed.</p>

      <h3>Starting a session</h3>
      <p>Three ways in: <strong>Open project</strong> picks a folder on this computer, <strong>Clone repo</strong> takes an address (an ssh address included) and clones it into your workspace, and the sessions you had open before are listed underneath with their branch and the size of the change in each. The status line along the bottom always says what is going on: idle or working, which folder, which branch, and how many lines have been added and removed.</p>
      <h3>Handing work to Code from a chat</h3>
      <p>You do not have to open the window first. In any chat &mdash; on the computer, or in the Remote chat on your paired phone &mdash; say what you want done and in which folder (&ldquo;let Code fix the pause menu in my Star Wars project&rdquo;). Skales asks once, opens a coding session on that folder with the task, and the Code window opens on it while your chat stays where it is. If you did not name a folder, it asks which one. Later in the same chat you can send that session a follow-up or a correction: while it is working, the message waits in its queue and is read at its next step, just as if you had typed it into the Code window. The chat can also tell you where a session stands, what it answered last and which files it changed. One thing stays in the session: when it stops to ask for permission, you answer in the Code window (or on the phone&rsquo;s Code screen) &mdash; the chat tells you it is waiting and links you straight to it.</p>

      <h3>The four modes, and what each may do</h3>
      <p>You pick the leash when the session starts, in the box you type into. It is the session that decides, not your global Safety Mode: set the rest of Skales to Unrestricted and a session set to <strong>Code</strong> still asks, because that is what choosing Code meant.</p>
      <ul>
        <li><strong>Ask</strong> &mdash; reads and answers. It cannot change anything: the tools that write are refused, not merely discouraged.</li>
        <li><strong>Plan</strong> &mdash; the same, and the output is a plan. Carrying it out is a separate decision.</li>
        <li><strong>Code</strong> &mdash; writes, and asks before every file change and every command, once each, with an &ldquo;always allow&rdquo; for the ones that get tiring.</li>
      </ul>
      <p>Whenever it does ask, <strong>each button on the card says how far its yes reaches and how long it lasts</strong>: this call only; every action of that kind until this session ends; or every one of them, in every session, until you take it back in Settings. And when an unattended session stops to ask anyway, it says why in the words of the check that stopped it &mdash; it reached outside the folder, it looked destructive, it touched infrastructure Skales does not know.</p>
      <ul>
        <li><strong>Accept edits</strong> &mdash; file changes go through without asking, because choosing this mode <em>is</em> that consent. Commands, pushes and deploys still ask.</li>
        <li><strong>Auto</strong> &mdash; gets on with it. It still asks about anything that reaches <em>outside</em> the bound folder, anything catastrophic, and anything the scope check flags as more than you asked for.</li>
      </ul>
      <h3>Three roles, three models</h3>
      <p>One task can go through <strong>three</strong> models instead of one. Press <strong>Roles</strong> in the box you type into, or write <code>/roles</code> followed by what you want done, and the work runs as a chain: an <strong>Architect</strong> plans the change and names the files without writing any code, a <strong>Coder</strong> then makes the change as an ordinary coding turn &mdash; same tools, same approvals, same diff cards &mdash; and a <strong>Reviewer</strong> reads back the difference that actually landed and says what is wrong with it. <code>/architect</code> and <code>/reviewer</code> ask one of them on its own.</p>
      <p>Each role gets its own provider and model, in <strong>Settings &rarr; Assistant &rarr; Skales Code &rarr; Skales Code roles</strong>, and they can be three different companies &mdash; which is the point: a blind spot is not reviewed by the model that has it. A role you leave empty runs on the model the session would have used anyway, and the row says which one that is. Nothing happens until you press the key or type the command; a session where you never touch it works exactly as it always did.</p>
      <p>Every role&rsquo;s answer lands in the log as its own folded block naming the role, the model and what that one call cost, so it is still there tomorrow. All three prices count towards the session&rsquo;s spending ceiling, and <strong>Stop stops all of them</strong>.</p>

      <div class="warn">
        <strong>🔒 What no mode lifts</strong> &mdash; Blocked folders stay blocked, every path resolves inside the bound folder, catastrophic commands are refused rather than offered, and a coding session never reads or writes your memory. Auto does not switch any of that off.
      </div>

      <h3>Reading a session</h3>
      <p>Every step opens. Click a Read, a Grep, an Edit or a command and it unfolds: exactly what was sent and everything that came back, whole, scrollable, with a copy button on each half, and how long the step took. A change carries its diff on the step that made it, with its own added and removed counts and its own <strong>Keep</strong> and <strong>Revert</strong>. Every path is a link into the panel beside the transcript.</p>
      <p>Every step also carries the <em>same sign</em> for how it ended that the live line uses &mdash; a tick, a cross, a warning triangle &mdash; in the same slot and at the same size, so a failed step says so as a shape and not only as a colour. A long diff arrives folded, but never blind: its first three changed lines stay on screen and the lid says how many are still behind it. Added and removed lines are painted in the diff palette, and the counters on the card head match them &mdash; a removed line is not an error, and this window no longer paints it in the red it keeps for a step that actually failed.</p>

      <h3>Review, commit, pull request</h3>
      <p><strong>Review diff</strong> opens the panel with every file the session touched. Keep stages a change for the next commit, Put back restores the file and tells you where the old version came from. Commit from the same panel, push, and open a pull request without leaving the window. When git refuses, you get git&rsquo;s own words back.</p>

      <h3>The file column</h3>
      <p>The column beside the transcript is a real tree: folders open and close, every file in the project is in it however many there are, and a file the preview cannot render opens in the editor instead of being left out of the list.</p>

      <h3>The artefact panel and the picker</h3>
      <p>The panel beside the transcript shows a file three ways: <strong>Preview</strong>, <strong>Diff</strong> and <strong>Raw</strong>. An HTML file is not shown as source but <em>run</em>, with its own stylesheet and script, so a widget works there the way it will work anywhere. Turn on the picker and click an element in that running page: what to call it in CSS, its own markup and a picture of just that piece go onto the message you are writing.</p>

      <h3>Codework: the desk already laid out</h3>
      <p><strong>Codework</strong> is a switch in the box you type into, and it decides what the window looks like when the session starts: the file column, the preview and the review diff are already open, before the first answer lands, instead of being three clicks you make every time. It is a view preset and nothing more - it does not change the mode you picked, what the agent may do, or which model runs. Turn it on with a session already open and the panels appear at once rather than waiting for the next session.</p>
      <p>The shape belongs to the session it was applied to. Move to another session, from history or by starting a new one, and the panels close again, so an opened desk never arrives somewhere you did not ask for it. Your choice is remembered on this machine, beside the terminal's height and the panel widths, so the next session you start opens the way you like to work.</p>

      <h3>When a run is long</h3>
      <p>Under the turn it is working on, a run keeps <strong>one live line</strong>: which step it is on, which tool on which file, and for how long &mdash; &ldquo;Step 7 &middot; write_file src/InputManager.ts &middot; 12 s&rdquo;. Parked on a question it says <em>waiting for you</em> instead, and gone quiet for longer than it should it names what is hanging rather than counting up under a word that is no longer true. When the run stops, the same line becomes its receipt: how many steps, how many files, how long, and what the turn cost. That receipt is read from the session itself, so reopening the window later shows exactly the same one. A run long enough to earn the full written report below keeps only the price on the line, so nothing is said twice.</p>
      <p>A run that works for a while says so instead of hiding behind a spinner. The status line counts how long it has been going, and if the run stops producing anything for two minutes the line names the silence &mdash; &ldquo;no progress for N min&rdquo; &mdash; rather than letting &ldquo;working&rdquo; stand over a run that stalled. If Skales itself was closed while a session was mid-turn, reopening that session says <strong>interrupted</strong> above the box you type into: the last answer may be incomplete, and sending a message carries on. And a run of ten steps or more ends with a <strong>run report</strong> in the transcript &mdash; how many steps, how long, what the working tree looks like now, and which checklist items are still open &mdash; composed from the session itself, with no extra model call.</p>
      <p><strong>Stop acts at once.</strong> The press never waits behind anything else the window is doing: the line says <em>Stopping</em> immediately, and the session shows as stopped only when nothing of it is running any more &mdash; a step that is still finishing is named instead of being drawn as stopped. What the run does reaches the window the moment it happens, the answer as it is written, each tool call and its result, the queue and the permission card, and only what changed travels, so a session with hundreds of messages streams as smoothly as a new one and a reload picks the answer up exactly where it stands.</p>

      <p>A session that worked <strong>ten steps or more closes with a run report</strong> in the transcript: how many steps it took, how long it ran, what the working tree looks like now and on which branch, and which checklist items are still open. It is composed from the session itself with no extra model call, and it lands the same way whether the run was driven from this window or from a chat in a code mode.</p>

      <h3>Two things at once: worktrees</h3>
      <p>Give a second piece of work a name and Skales checks the repository out again into a folder of its own, on a branch of its own, with its own session. Neither run can overwrite the other, and each session says whether it is working, waiting for you, or idle. Removing a parallel checkout tells you when there is uncommitted work in it rather than taking it with the folder, and it never removes the repository itself.</p>

      <h3>Several agents at once</h3>
      <p>A coding session can send work to sub-agents and run them in parallel. A rail shows what each one is doing and what it has cost, and one button stops all of them.</p>
      <p>A sub-agent that is still working can be told something: the speech-bubble icon on its row opens a one-line field, and it reads your message after the step it is on. A message that arrives after its last step is shown as not delivered rather than lost. Each helper keeps an id, so you can ask Skales afterwards to give one of them more work or to run only the one that failed again. A helper can also be asked to answer in a fixed JSON shape; if it misses, it gets one chance to correct it, and an answer that still misses is marked.</p>

      <h3>Your terminal</h3>
      <p>Under the box you type into, a real terminal: your login shell, in the session&rsquo;s folder, with your profile. Not a command field, so <code>vim</code>, <code>top</code>, an interactive prompt, colours, arrow keys and Ctrl-C all behave the way they do anywhere else. Open it with the switch in the title bar or by typing <code>/terminal</code>, drag its top edge to resize it, and open more than one tab if you want.</p>
      <div class="warn">
        <strong>🧵 Two shells, never mixed</strong> &mdash; The terminal is <em>yours</em>: your hands, your rights, and the agent can neither see it nor type into it, which is why it needs none of the agent&rsquo;s rules. What the <em>agent</em> runs is the other one, and it goes through every guard above.
      </div>

      <h3>Commands that do not end</h3>
      <p>A dev server, a watcher, a long build used to be a choice between a timeout and a blocked session. The agent can now start one in the background: its output appears under the step that started it and grows while you watch, and a strip above the status line lists everything that is running with what it is, how long it has been going, and a stop button. Nothing limits how many run and nothing times them out. Stopping stops the whole tree, so a port really comes free. A session that ends ends its own; so does closing Skales. Your phone can see the same list and press the same stop.</p>

      <h3>Typing: @, drag, and /</h3>
      <p>Typing <code>@</code> offers the files of the repository, matched on the whole path so a folder name finds them. Drop files onto the box, paste a screenshot, or use the paperclip: video, audio, PDFs and archives attach the way they do in a chat. A slash at the <em>start</em> of a line opens the commands a coding session has: switch mode, open review, commit, open a pull request, stop, start a new session, clear, open the terminal. A slash anywhere else is just a path.</p>
      <p>Seven of them are the ones every coding tool has. <code>/undo</code> takes back the last turn that changed files, puts the files back and your question into the box, and pressed again takes back the turn before; what a shell command changed is taken back too wherever Git is on the machine. <code>/redo</code> puts an undone turn back, files and conversation, the most recent undo first; the same Redo is a button in a line above the box, and it lasts until you send the next message, also across a restart. A file you edited by hand since the undo is named and kept, and then nothing is redone. <code>/resume</code> carries on a session that stopped half way, or opens your sessions when nothing stopped. <code>/cost</code> shows what the session has cost and what fills its context. <code>/diff</code> opens the review of what changed. <code>/init</code> has the session read the project and write its <code>AGENTS.md</code>, or update the <code>CLAUDE.md</code> it already reads, folding in rules other coding tools left there. <code>/model</code> opens the model picker, and <code>/model</code> with a name switches straight to that model.</p>

      <h3>Checking what was written</h3>
      <p>After every write the session asks the language server for that file type whether the file still compiles, and the agent reads the answer in the same turn: TypeScript and JavaScript, Python, Go, Rust, C, C++ and Objective-C, Java, C#, PHP, Ruby, Kotlin, Swift, Lua, Bash, YAML, JSON, HTML, CSS, Dockerfile and Terraform. A server that is not installed yet is asked for on a card that names the command, chosen from the package manager your computer has (npm, Homebrew, rustup, the .NET SDK, RubyGems, scoop or winget, depending on the language and system), and where it lands. Your yes covers exactly the command on the card; if your computer would use a different one later, you are asked again. The install runs in the background while the session carries on, and the next file written after it lands is checked. If it fails, the card offers it again instead of the session retrying it after every write, and Apple&rsquo;s installer window only opens when you click. Where a system has no install command for a language, the card says which program to install yourself. Saying no leaves everything else working.</p>

      <h3>Keys</h3>
      <p><strong>Esc</strong> stops a running turn, through the same stop as the button; pressing it again while the stop is on its way does not stop anything else. With nothing running, <strong>Esc Esc</strong> opens your last message for editing. <strong>Shift+Tab</strong> in the box you type into moves to the next mode: Ask, Plan, Code, Auto, and round again. An open menu, dialog or editor, and your terminal, keep their own Esc. All of them are listed under Keyboard shortcuts in the command palette.</p>

      <h3>The status bar</h3>
      <p>Along the foot of the window: which model answers and at what thinking effort, how full the context is, and what the session has cost so far &mdash; the same figure the chat shows for a conversation. Click the context figure to see what fills it.</p>

      <h3>What the session touched</h3>
      <p>The file column leads with <strong>Changes</strong> whenever there are any. It lists what git reports and everything the session itself created (A), changed (M) or deleted (D), also in folders your repository ignores and in folders that are no repository at all. A folder holding a change carries a dot. Dependency and build folders are left out.</p>

      <h3><code>/clear</code>, and where the work lives</h3>
      <p><code>/clear</code> starts the conversation over without losing the folder, the branch or your place. Each session also has a scratchpad of its own for the files it needs while it works, kept apart from your workspace and removed with the session.</p>

      <h3>Instructions: AGENTS.md and the order they win in</h3>
      <p>A coding session reads three things, most specific last: the project&rsquo;s own <code>CLAUDE.md</code> or <code>AGENTS.md</code>, then your global coding instructions, then anything you set for that one session. Put a project&rsquo;s rules in an <code>AGENTS.md</code> at its root and every session on that project follows them. The gear in the Code window edits the global and the per-session boxes; both show an example of what belongs in one &mdash; the language to answer in, your own test command, your commit style, your no-gos &mdash; as a hint, never as content.</p>

      <h3>It hears you while it is working</h3>
      <p>Type while a session is running and your message joins the run instead of starting a second one on the same transcript, and Skales says so.</p>
      <p>What you send while it works waits in a <strong>dock above the box you type into</strong>, greyed, the moment you press Enter. Each line says when it joins: <em>at the next step</em> (the default &mdash; it is folded into the working turn before the model is asked again) or <em>after this turn</em> (it runs as a turn of its own once the current one has finished). While it waits you can <strong>edit</strong> it, <strong>remove</strong> it, move it to after the turn, or <strong>send it now</strong>. When the run reads it, the row says <em>delivered</em> for a moment and the message appears in the log with a small stamp naming the step it arrived at. Your paired phone sees the same list and can change it the same way.</p>
      <p><strong>Stop never throws a waiting message away.</strong> A line the run had not read yet stays in the log marked <em>not delivered</em>, with <strong>Send now</strong> and <strong>Discard</strong> in the dock; a message held for after the turn stays in the dock, paused. Nothing goes out until you choose it.</p>

      <h3>&ldquo;No, and instead&rdquo;</h3>
      <p>Under the refusal on a permission card there is a field: <strong>No, and instead: &hellip;</strong>. Write what it should do instead and the step is declined with your sentence as its result &mdash; the model reads it and carries on in that direction, without you stopping the run and typing it again. A plain <strong>No</strong> still ends the run. The same works from the chat and from your phone.</p>
      <p>When a command is refused by a safety rule rather than by you, the refusal names the rule (&ldquo;mass deletion&rdquo;, &ldquo;shutdown or restart of this computer&rdquo;, &hellip;) and the setting that lifts it: <strong>Settings &rarr; Security &amp; Privacy &rarr; Safety Mode</strong>, Advanced or Unrestricted, and only Unrestricted for the rules that can destroy the system. A word like <em>shutdown</em>, <em>reboot</em>, <em>halt</em> or <em>wipe</em> counts only where it is the command itself &mdash; not inside a <code>grep</code>, an <code>echo</code> or a commit message.</p>

      <h3>When it goes round in circles</h3>
      <p>When the same tool is called three times with exactly the same input, the run stops and asks: <strong>Keep going</strong>, <strong>Try it differently</strong> (you can say how) or <strong>Stop</strong>. Stop ends the run where it is; everything done so far stays.</p>

      <h3>Shortening, with the numbers</h3>
      <p>When a long session is summarised to fit the model &mdash; on its own, or because you pressed <code>/compact</code> &mdash; the log shows it as its own item with the context before and after, in tokens. <code>/compact</code> while a run is working is no longer refused: it is taken at the next step.</p>

      <h3>Long answers arrive whole</h3>
      <p>A long answer streams from its first word, however long it gets. When the model stops at its output limit in the middle of an answer, Skales asks it for the rest, as often as it takes, and the parts land as one answer carrying the price of all of them. If an answer still ends at the limit, a line under it says so.</p>

      <h3>Code inside a chat</h3>
      <p>A chat can still be bound to a folder and run in a code mode, and it is the same engine. A chat like that has one button in its header that stops what is running, cleanly, and hands the same session to the Code window &mdash; not a link and not a copy.</p>

      <h3>Games with Godot</h3>
      <p>Point a Code session at a game project and Skales finds Godot on your computer, imports the project and checks it, plays it for a few seconds, runs its tests, and records a short clip as proof of what it saw. An engine that hangs is stopped and named instead of waiting forever, and a game with a script error is never reported as working. Without Godot installed, Skales says where to get it rather than guessing at a result. A game-development skill reads the project first and routes Godot, Unity, Unreal, Bevy, Phaser, PixiJS, three.js, LOVE and pygame work to the guidance that fits the engine actually in the folder.</p>
    </section>

    <section id="chat-code-settings">
      <h2><span class="icon">⌨️</span> Settings: Chat &amp; Code</h2>
      <p>One tab in Settings for how Skales writes and how it codes.</p>
      <h3>Standing instructions: SKALES.md and AGENTS.md</h3>
      <p>Two boxes, two jobs, and the toggle above them says which you are editing.</p>
      <ul>
        <li><strong>SKALES.md</strong> is how you want to be <em>answered</em>, everywhere: answer in German, keep it short, never open with a compliment. It travels with every conversation, with tasks and schedules that run while you are away, and with your own agents.</li>
        <li><strong>AGENTS.md</strong> is how you want work <em>done</em> in a project: the test command, the commit style, the folders nothing may touch. It belongs to a project, at its root, and every coding session on that project reads it.</li>
      </ul>
      <p>Both are plain files &mdash; the path is printed under the box, and editing the file in a text editor is the same edit. If it changed on disk while you had unsaved text in the box, Skales says so rather than writing over it. Two places leave your standing instructions out on purpose: an isolated agent, which carries nothing of yours by design, and the calls Skales makes to itself.</p>
      <h3>Under Persona, and at the very top</h3>
      <p>The same SKALES.md box also sits under <strong>Settings &rarr; Assistant &rarr; Persona</strong>, below the persona text, because that is where people look for rules every agent should follow. The persona text belongs to the default agent alone; SKALES.md applies to every agent, your own included, and the persona field says so and points to it. AGENTS.md stays here in Chat &amp; Code.</p>
      <p><strong>Put them at the very top</strong> is off until you switch it on. Off, your standing instructions follow Skales&rsquo; own rules, as they always did. On, they are the first lines every agent reads: in the chat, in your own agents, in Code, on the messengers and in Buddy. Either way they stay inside the part of the prompt a provider can cache, and the position holds for as long as the file does not change. With the switch on, saving an edit re-reads the whole cached prompt once instead of only its end. Your own instructions never outrank Skales&rsquo; safety rules, wherever they stand.</p>
      <h3>Priority</h3>
      <p>Most specific wins: <strong>the project&rsquo;s own file</strong>, then <strong>your global instructions</strong>, then <strong>this session</strong>. A rule you set for one session beats the same rule set globally, and a project that ships its own conventions beats both.</p>
      <h3>Watermark</h3>
      <p>A model leaves marks in text it writes for you. Some of them nobody can see: zero-width spaces, text-direction controls, a no-break space where an ordinary space belongs. Others are visible habits that read as machine-written: the long dash standing in for a comma, the one-character ellipsis, curly quotes. <strong>Clean output</strong> takes them off before the answer reaches you, and it is off until you switch it on.</p>
      <p>Three switches, because they are three different promises. <strong>Remove invisible characters</strong> changes nothing you can read. <strong>Neutralize typography</strong> does edit visible text: the dash becomes a comma, the ellipsis becomes three dots, and it finds the glued form used in Chinese and Japanese as well as the spaced one. <strong>Straighten quotes</strong> sits under that. Code blocks and inline code are never touched by any of them, so a zero-width character inside a string literal and a dash inside a shell command both survive.</p>
      <p>What this does <em>not</em> do, and does not claim to: remove a statistical sampling watermark. That kind lives in the choice of words rather than in the characters, and only writing the text again gets near it.</p>
      <h3>Rewrite, and <code>/spin</code></h3>
      <p>Rewrite writes a text again in a plainer, more human voice, keeping the meaning, the facts, the language and any code exactly as they are. <code>/spin &lt;text&gt;</code> rewrites what you type after it, <code>/spin</code> on its own rewrites the last answer, and the message menu next to Copy offers the same action. The result is added to the conversation rather than swapping the original out.</p>
      <p>Pick the model that does it here. Leave it empty and the model already answering does the work; choose a local one and the text never leaves your machine. Whatever the switches above are set to, a rewrite always goes through the invisible-character pass, because the rewriting model stamps its own marks in like any other.</p>
      <p><strong>Rewriting one passage.</strong> Select any part of a reply and right click the selection: the menu then acts on what you picked rather than on the whole message, with <strong>Rewrite selection</strong> first, and copy, quote, read aloud and save to a document under it. Right clicking with nothing selected still gives you the menu for the whole message. A selection dragged across several bubbles belongs to none of them, so each bubble keeps offering its own message menu instead of acting on somebody else's text.</p>
      <h3>The rest of the tab</h3>
      <p><strong>Shell command timeout</strong> sets how long a single command may run before Skales stops it (a command started in the background is not timed at all). <strong>Deep reasoning</strong> asks any model to think a problem through before acting, including models with no reasoning mode of their own. <strong>Code model</strong> runs a strong model for code while your chat stays on your default. <strong>Assist</strong> has its own section, right below.</p>
    </section>

    <section id="assist">
      <h2><span class="icon">⚡</span> Settings: Assist</h2>
      <p>Not every step of a conversation needs your best model. Planning a step, checking a result, shortening a long one and writing the short line that appears while a slow model is still silent are small jobs, and Assist is where you say which model does them. It sits in <strong>Settings &gt; AI &amp; Models &gt; Models per task</strong>, under Chat &amp; Code itself. Until 12.7.2 these three controls stood under Goals, which is why you may remember them there.</p>

      <h3>The assist model</h3>
      <p>Leave it on <strong>Follow the chat</strong> and the small jobs run on whatever model the conversation runs on. Point it at a provider and a model - a cheap cloud model, or a local one - and every light pass goes there instead, while your chat stays where it is. The model field only applies once a provider is set.</p>

      <h3>Decisions</h3>
      <p>Some of what Skales does between your messages is not writing at all, it is deciding: which of a handful of steps fits, whether a step still matters, whether the next click is one you would want to be asked about. Those closed questions can go to a decision model, which answers yes-or-no and which-one questions in a fraction of a second and never writes a word. <strong>Decisions</strong> sits under the assist model on the same card. It is <strong>Off</strong> by default, and off keeps everything exactly as it is today. Choose <strong>TypeSafe key</strong> and paste a key of your own, or <strong>via OpenRouter</strong> to use the OpenRouter key you already have for chat; the model list carries the decision models that exist. A decision model never sees a picture, so anything that needs a screenshot still goes to the model you chose. What leaves the machine when it is on: the names of the elements on a page, your instruction and the tool steps of the conversation, nothing else. An incognito conversation and Privacy Mode never ask it.</p>
      <p>The same slot can hold <strong>OpenRouter Auto Router</strong> instead. It answers no questions of its own; it only chooses models. A line under the picker says what one choice costs and how long it takes: about $0.00001 and 70 to 500 ms for a decision model, nothing extra for the Auto Router, where your turn costs what the chosen model costs.</p>
      <p>Below it sits <strong>Route each turn</strong>, off by default. With a decision model in the slot, it reads each task once and picks which of the models <em>you</em> configured answers it: your chat model, your planning and executing models, and your fallback chain if fallback is on. It looks at what each can do &mdash; pictures, tools &mdash; and at its price. If the picked model fails, your chat model takes over; if a model fails with a fallback chain on, it picks which fallback steps in. With the Auto Router in the slot, every OpenRouter turn goes to OpenRouter's router, limited to the OpenRouter models you configured. Every switch shows as one quiet line in the chat, and its price is part of the turn's cost. Off, every turn goes to your chat model exactly as before.</p>
      <p>With Jev, the choice is made <strong>while you type</strong>: once your message is about 40 characters long and you pause, Jev reads the draft and the composer shows its pick, for example <em>&rarr; deepseek-v4 &middot; Code</em>. Click it to pick another of your models or your chat model; your choice wins. When you send, the pick is used straight away if the text is still essentially the same, so the turn does not wait for it. Jev reads the draft only when routing is on, never in an incognito chat, and those small questions count towards the turn's cost.</p>
      <p>Flow benefits too. With a decision model in the slot, Flow's <strong>Auto</strong> asks it which kind of thing your brief wants and which template fits, taking your attachments into account; the helper model still writes the scoping questions and still decides whenever the decision model cannot. With routing on, Flow turns go through the same router as the chat until you switch the session's model yourself.</p>

      <h3>Say something while the model is still thinking</h3>
      <p>A big model can sit silent for several seconds before it writes anything. With this on, one short line appears in the status slot saying what Skales is about to do. It is written by your assist model, it is never stored in the conversation, and it is never sent back to a model on a later turn - it lives only in the window you are looking at. On by default. Switching it off gives you the ordinary indicator and nothing else changes.</p>
      <p>Who writes it follows the boundary your conversation already crosses, and never widens it:</p>
      <ul>
        <li><strong>Skales IQ</strong>: the line rides the same lane the conversation already rides.</li>
        <li><strong>Your own key</strong>: the same provider, on the cheapest small model of that vendor, with the key you already gave it.</li>
        <li><strong>A local model</strong>: a local assist model if you configured one, otherwise no line at all. Nothing leaves the machine, not even a ping.</li>
      </ul>

      <h3>Let Skales write that line</h3>
      <p>Indented under the toggle, because it only exists for one case: your provider has no cheap small model that Skales can name for the job. Then, and only if you switch this on, a Skales server writes the line instead.</p>
      <p>Normally your conversation never touches a Skales server. This one line is the exception. The server sees the first sentence of your message and nothing else - no history, no system prompt, no files - and it keeps none of it: measured on the server, the lane stores a request counter and your device id as a one-way hash for rate limiting, and no text at all. Off by default.</p>
      <p>One boundary belongs next to that, because it is a different kind of promise: this is what <em>our</em> server does, and it is measured. The model that actually writes the sentence runs at a provider, and there the guarantee is the zero-data-retention setting Skales sends with every such request - a commitment we require, not something we can measure from here.</p>
      <p>If the lane is switched off on the server side, you get no line and no error: the feature is best-effort by design and never makes you wait twice. It does say so once, quietly, in <strong>Settings &gt; System &gt; Diagnostics</strong>, so a switch that looks on but produces nothing can be explained rather than guessed at.</p>
    </section>

    <section id="typing-suggestions">
      <h2><span class="icon">⌨️</span> Typing suggestions</h2>
      <p>While you type, the rest of the sentence appears in grey behind the cursor. Press <strong>Tab</strong> to take it, <strong>Esc</strong> or simply keep typing to drop it. When the box is empty after an answer, the grey text is the message you are most likely to send next, and Tab takes that too. It works the same in the chat, the new-chat page, Skales Code, Flow, Lio AI and Iris.</p>
      <p>Nothing is asked on every key. A small model is asked once you pause for about half a second, and a question still on its way is cancelled the moment you type the next letter. While a turn is working, while the slash or mention menu is open, and while an input method is composing, there is no grey text. Shift+Tab and Esc keep their usual jobs whenever nothing grey is shown: Esc still stops a run in Skales Code, the press after the one that dropped the suggestion.</p>
      <h3>Where the suggestions come from</h3>
      <p><strong>Settings &rsaquo; Assistant &rsaquo; Typing suggestions</strong>. The default is a model on this computer: Skales Local, or Ollama when Skales Local is not running. Skales takes the model that is already in memory, so nothing is loaded twice, or the smallest one installed. It is free and nothing leaves the machine. Without any local model the composer simply stays quiet; the row says so and offers to set up Skales Local.</p>
      <p>You can choose a cloud model instead, but only a small, fast one (flash, mini, lite and the like). A large model, or one whose price Skales cannot tell, is refused with a sentence that says why, because it would be asked after every pause. What the cloud model costs is added to the conversation's own cost, so the cost line and the session ceiling see it. A free tier that answers "too many requests" is left alone for a minute while the local model stands in, quietly; the chat model is never used for this. With Privacy Mode on, suggestions only ever come from this computer.</p>
      <h3>What is never predicted</h3>
      <p>Key, password and secret fields have no suggestions at all. A message that carries a key, a token or a password is never sent for a suggestion, and neither are the turns of the conversation that do. Slash commands and @mentions are left to their own menus. Skales Mobile has the same suggestions in its composers: a tap on the chip above the field takes one, and they come from the model loaded on the phone or from this computer over the pairing.</p>
    </section>

    <section id="playground">
      <h2><span class="icon">🎮</span> Playground</h2>
      <p>Playground is your personal AI workspace. It starts with a deep interview to understand your work style, goals, and design preferences. Based on your answers, Playground suggests personalized Spaces — interactive mini-apps built specifically for you.</p>
      <p>Spaces can store data, connect to AI, and be shared with other Skales users on the Discover Feed (personal data is automatically removed before sharing).</p>
      <p>Playground gets smarter the more you use Skales.</p>
      <h3>Features</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">Deep Interview</div><div class="card-desc">15 questions across 4 phases adapt to your answers.</div></div>
        <div class="card"><div class="card-title">AI Suggestions</div><div class="card-desc">Personalized Space ideas based on your profile.</div></div>
        <div class="card"><div class="card-title">Space Builder</div><div class="card-desc">AI generates interactive apps with localStorage persistence.</div></div>
        <div class="card"><div class="card-title">Share to Discover</div><div class="card-desc">Publish Spaces to the feed with automatic data sanitization.</div></div>
      </div>
    </section>

    <section id="devkit">
      <h2><span class="icon">🧑‍💻</span> DevKit</h2>
      <p>Developer tools for power users, and they are inside the app now — nothing to download and nothing to assemble by hand.</p>

      <h3>Setting it up</h3>
      <p>Switch <strong>DevKit</strong> on under <strong>Sidebar &rsaquo; System &rsaquo; Add-Ons</strong> and a <strong>Developer</strong> section appears in the sidebar. One click in it sets the DevKit up: the command-line tool, its documentation and its examples are written into your Skales folder with the access key already filled in, and the page tells you the exact place it wrote to and what to do next.</p>
      <p>The developer tool installs under the name <code>skales-dev</code>. The plain <code>skales</code> command is the app itself &mdash; the launcher that opens Skales, and <code>skales .</code> that opens a folder in it &mdash; so the two never fight over the same name on your PATH.</p>
      <p>Pressing it a second time is safe. An existing DevKit is never overwritten, and a key you have already handed to another program keeps working rather than being rotated out from under it. Switching the add-on back off only puts the sidebar section away — whatever was written stays where it is.</p>

      <h3>Components</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">Playground</div><div class="card-desc">Test API calls and chat directly with the agent loop.</div></div>
        <div class="card"><div class="card-title">Debug</div><div class="card-desc">View logs, inspect tool calls, monitor agent state.</div></div>
        <div class="card"><div class="card-title">Docs</div><div class="card-desc">Full reference: every tool with its safety level, plus the skills, providers and integrations - generated from this build, so the list is never out of date.</div></div>
      </div>
    </section>

    <section id="github-int">
      <h2><span class="icon">🐙</span> GitHub</h2>
      <p>List repos, create issues, search code. Requires a GitHub Personal Access Token. Configure in <strong>Settings > Extensions > MCP servers</strong> (the GitHub MCP server).</p>
    </section>

    <section id="ftp">
      <h2><span class="icon">🚀</span> FTP/SFTP Deploy</h2>
      <p>Central server profile management. Deploy Lio AI projects with one click to your hosting.</p>

      <h3>Server Profiles</h3>
      <p>Store FTP/SFTP connection details securely in <strong>Settings → Accounts &amp; Services → Servers (SSH, SFTP, FTP)</strong>. Encrypt credentials locally using your master password. Since v12.4.0 each profile carries its protocol explicitly &mdash; FTP, FTPS (explicit TLS, switches on automatically when the server requires it) or SFTP. On the first successful SFTP test or publish, Skales pins the server&rsquo;s SSH host-key fingerprint to the profile; if the key ever changes, the next upload is refused. Profiles can also be bound to a single agent, so an isolated agent publishes only through its own space (v12.3.5).</p>

      <h3>One-Click Deploy</h3>
      <p>Build your Lio AI project and deploy directly to a server. Skales handles file transfers and confirms deployment success.</p>

      <h3>Live Preview</h3>
      <p>After deployment, quickly open your deployed project in the browser to verify it's running correctly.</p>

      <h3>Your own servers over SSH</h3>
      <p>An SFTP profile is an SSH server, and the chat and Skales Code can work on it: run a command there (a long one keeps running and can be followed and stopped like a command on this computer), upload and download files and whole folders, and keep a folder in sync with the server, sending only what changed, optionally removing what is gone, or first just showing what would change. Add a server under <strong>Settings &rsaquo; Integrations</strong> in the <strong>SSH servers</strong> card: host, user, a start folder and how Skales signs in &mdash; a key file on this computer, a pasted key, a password or your running ssh-agent. The host key is pinned on first contact and a changed one is refused.</p>
      <p>A command on a server asks before it runs. Mark a server as <strong>trusted</strong> and, in a conversation set to Auto, commands and downloads on it run without asking; the first upload in a session still asks. The phone reaches your servers through the paired computer.</p>
    </section>

    <section id="moodle">
      <h2><span class="icon">🎓</span> Publish to Moodle</h2>
      <p>A finished SCORM course goes straight into Moodle, from wherever you are: ask in Chat or Code (&ldquo;put this package into the onboarding course&rdquo;), press <strong>Publish to Moodle</strong> in Flow&rsquo;s export dialog, use the button in a plugin, or ask from your phone &mdash; the phone sends the job to this desktop. It is one tool, <code>lms_publish</code>, and every surface uses it.</p>

      <h3>The connection</h3>
      <p>Set it up once in <strong>Settings &rarr; Accounts &amp; Services &rarr; Moodle</strong>: the Moodle address, your Moodle account (trainer rights in the course are enough) and, if you have one, a web service token. Password and token are stored encrypted on this computer and never shown again. <em>Test connection</em> asks Moodle what it offers; <em>Get token with account</em> asks Moodle for a token the way the Moodle app does.</p>

      <h3>Four ways, one chosen for you</h3>
      <ul>
        <li><strong>Skales Connector for Moodle</strong> &mdash; a small Moodle plugin (<code>local_skales</code>). With it, publishing needs only the token: no browser, no extra switch for package types. <em>Set up for the Moodle admin</em> in the Moodle settings lists the three steps your admin follows.</li>
        <li><strong>Browser</strong> &mdash; the standard way. Skales signs in with your account in a background browser, opens the activity&rsquo;s settings, replaces the package file in the <em>same</em> activity, saves and checks the result.</li>
        <li><strong>Your own server</strong> &mdash; the package goes to your web space through an FTP/SFTP profile and a Moodle activity of the type &ldquo;Downloaded package&rdquo; fetches it on every launch. Your Moodle admin enables that package type once.</li>
        <li><strong>Web services</strong> &mdash; with a token Skales finds courses and activities and reads how many learners started and finished. Moodle itself has no web service that replaces a SCORM package, so this way never publishes on its own.</li>
      </ul>
      <p>Skales picks the best way the connection offers and tells you which one it took.</p>

      <h3>What Skales keeps safe</h3>
      <ul>
        <li><strong>Same activity, progress stays.</strong> A new version replaces the package inside the existing activity. A new activity is only created when you ask for one &mdash; then with &ldquo;status completed&rdquo; as the completion condition and display in the current window.</li>
        <li><strong>Identifiers are checked first.</strong> If the manifest or item identifiers of the new package differ from the course already in Moodle, Skales refuses: Moodle would treat it as a new course and every learner would lose their progress. You can still publish a deliberate new version, and the card says what that costs.</li>
        <li><strong>It always asks.</strong> Every publish into a course shows a card first, in every safety mode, including Auto.</li>
        <li><strong>SCORM 1.2 for Moodle.</strong> Moodle does not support SCORM 2004; a 2004 package is flagged before anything is uploaded.</li>
      </ul>
    </section>

    <!-- ===== Chapter: Studio and Flow ===== -->
    <section id="ch-studio" class="chapter-lead">
      <div class="lead-kicker">Chapter 4</div>
      <h2>Studio and Flow</h2>
      <p class="lead-intro">Studio is the one-shot side: describe a picture, a clip, a voice line, a piece of music, and get it. Flow is the other side: one brief that keeps being worked on, with every turn sealed so you can go back to any of them.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a picture, a headline, a shot</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">Three outputs, one from each of the three ways Studio makes things: a model, a renderer with no AI in it at all, and a conversation.</p>
        <ol>
          <li>
            <span class="do">Sidebar, <strong>Studio</strong>, the <strong>Image</strong> tab. Describe something specific rather than something impressive:</span>
            <span class="say">A flat vector icon of a green lizard on a dark background, no text, centred.</span>
            <span class="then">the picture in the preview and the same picture already in your Gallery, with the prompt kept beside it.</span>
          </li>
          <li>
            <span class="do">Open the <strong>Type</strong> tab, put in a short line, and pick the <strong>Neon</strong> motion preset.</span>
            <span class="say">Ship it.</span>
            <span class="then">the animation running in the live preview immediately. Nothing was generated and no key was used: Type is a timeline engine, not a model.</span>
            <span class="stuck">you want it over other footage, set the background to <strong>Transparent</strong> and the export becomes an alpha WebM instead of an MP4.</span>
          </li>
          <li>
            <span class="do">Open <strong>Flow</strong> and choose <strong>Film</strong>. Pick the camera move <em>before</em> you write the brief, and pick exactly one.</span>
            <span class="then">the brief box, with the move you chose held next to it.</span>
          </li>
          <li>
            <span class="do">Write the brief:</span>
            <span class="say">A rain soaked street at night, one neon sign, nobody in frame.</span>
            <span class="then">a clip, generated through whichever of the three routes you have set up. With none of them set up, the chip says which key is missing and where it goes, and keeps your camera move.</span>
          </li>
          <li>
            <span class="do">Answer the result instead of starting over. Follow-ups are takes:</span>
            <span class="say">Same shot, tighter, and at dawn.</span>
            <span class="then">a new take saved beside the earlier one, with everything you did not change kept.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT studio-type-preview.png
           Studio, the Type tab, with a motion preset selected and the preview running.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the preset row, the live preview mid-animation, and the controls
           for font, background, aspect and duration. A frame where the letters are
           part-way through the animation reads far better than the finished state.
      -->
      <figure class="shot pending">
        <img src="img/studio-type-preview.png" alt="Type: fourteen motion presets, a live preview, and no model behind any of it." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Type: fourteen motion presets, a live preview, and no model behind any of it.</div>
        <figcaption>Type: fourteen motion presets, a live preview, and no model behind any of it.</figcaption>
      </figure>

      <!-- SHOT flow-film-moves.png
           Flow, Film mode, the camera move picker open.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the moves grouped by family (zoom, dolly, crane, pan, orbit, rig,
           aerial, lens), one selected, and the brief box still empty. Do not crop the
           group headings away - the grouping is the point.
      -->
      <figure class="shot pending">
        <img src="img/flow-film-moves.png" alt="Film: the camera move is the first decision, and there is only ever one." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Film: the camera move is the first decision, and there is only ever one.</div>
        <figcaption>Film: the camera move is the first decision, and there is only ever one.</figcaption>
      </figure>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#studio">Skales Studio</a>
        <a href="#flow">Flow</a>
        <a href="#images">Image & Video Generation</a>
        <a href="#templates">Templates</a>
        <a href="#wordpress">WordPress 2.0</a>
      </div>
    </section>

    <section id="studio">
      <h2><span class="icon">🎨</span> Skales Studio</h2>
      <p>An all-in-one AI creative suite built into Skales. Generate images, videos, voice audio, and music — all from a single interface. Every output is saved to your Gallery and can be reused at any time.</p>
      <p>While an image, a video or a page is being made, the space it will fill shows a honeycomb in your accent colour, in the shape of the result. Cells light from the middle out as the work reports progress &mdash; a render with a percentage fills in proportion and shows the figure, a page lights one cell for each kilobyte written &mdash; and an ordinary image call, which reports nothing until the picture is there, fills the frame on a clock that slows down and never reaches the end, without a number, so you see it building. Chat, Studio, Flow and Skales Code draw the same thing for every image, edit, video, page or 3D model a tool makes, and the finished result fades in where the cells were.</p>

      <h3>The doors</h3>
      <p><strong>Sidebar &rsaquo; Studio</strong> lands in <a href="#flow" style="color:var(--accent)">Flow</a>, and the making surfaces that have no sidebar entry of their own are named on Flow&rsquo;s home screen as doors: <strong>Lio AI</strong>, <strong>Studio Classic</strong>, <strong>3D</strong> and the <strong>Video Editor</strong>. They sit on the entrance because choosing where to work is a question the entrance asks; once a project is open, the choice has been made.</p>
      <p><strong>Studio Classic</strong> is the set of direct generators, and it holds four: <strong>Media</strong> (image and video), <strong>Audio</strong> (voice and music), <strong>Type</strong> (kinetic typography) and the <strong>Gallery</strong>. Flow writes the pieces a brief calls for — a design, a deck, a multi-scene film with its timeline and its export card — so Classic is what you reach for when you know exactly which generator you want and want it in one press. A link that names a tab Classic does not have lands in Flow rather than on an empty stage.</p>

      <h3>Image Generation</h3>
      <p>Describe what you want and choose your provider. Skales Visuals is the built-in renderer for designed graphics: posters, banners and title cards with real typography in any aspect ratio, made right in the chat and needing no image key. Photographic or painted pictures come from an image provider. For higher resolution or photorealism, connect Google (Nano Banana Pro, Imagen 4), OpenAI (GPT Image 1), Replicate (Flux, SDXL), HuggingFace, or a local ComfyUI or Stable Diffusion WebUI instance. Export as PNG. The full list per service is under <a href="#images">Image and Video Generation</a>.</p>

      <h3>Video Creation</h3>
      <p>Describe a motion graphic in plain language — counters, text animations, infographics, slideshows, social posts. Skales Studio renders it instantly in the live preview. Iterate with follow-up instructions. When you're happy with the result, export as MP4 using the built-in FFmpeg renderer. Categories: Text Animation, Infographic, Data Visualization, Logo Intro, Slideshow, Social Post, Counter/Stats.</p>

      <h3>Type</h3>
      <p>Open <strong>Studio &rsaquo; Studio Classic &rsaquo; Type</strong> to turn a line of text into an animated, looping video (kinetic typography), with no AI and no setup. The headline is a set of <strong>14 Motion presets</strong> driven by a real timeline engine, with custom easing, per-letter staggers and depth: Cascade, Drop, Pop, Bounce, Slide, Reveal, Flip 3D, Spin, Wave, Breathe, Glitch, Neon, Shine, Typewriter. Pick one and it just works, there is nothing to configure. Below them are 18 simpler presets, including real 3D ones: Fade, Rise, Slide, Typewriter, Word cascade, Letter pop, Zoom in, Zoom blast, Blur focus, 3D flip, 3D swing, Cube roll, Depth dive, Wave, Neon, Glitch, Reveal, Expand. Set the font, weight, text color, background (presets including a Skales-X theme and a Transparent option), aspect (9:16, 16:9, 1:1, 4:5), duration, font size, and a Loop toggle. Watch the live preview, then Export. A transparent background exports an alpha WebM (VP9) you can lay over other footage; otherwise you get an MP4. It uses the same HTML-to-frames-to-FFmpeg pipeline as Studio's other video, so every frame is exact.</p>

      <h3>3D</h3>
      <p>The <strong>3D</strong> door on Flow&rsquo;s home screen opens a room with two halves. Describe an object and you get a <code>.glb</code> file you can open in Blender, a game engine or a slicer - that half wants a 3D provider (Replicate, fal.ai, Meshy or Tripo), and if none is set up the page says so in those words: a missing key, not a missing feature.</p>
      <p>The other half is <strong>From a photograph</strong>. Give it a picture of an object, optionally say in a line what it is, and Skales works the way a person would: it writes a three.js scene, draws it, <em>compares its own drawing with your picture</em>, writes down what is wrong, and repairs it. Then it looks again. It tries <strong>up to four times</strong> and stops early once it reaches a score of <strong>80 out of 100</strong>.</p>
      <p>You watch it happen rather than waiting at a spinner. Each attempt appears as it finishes, seen from three sides, with the score it reached, so you can see whether it is getting closer or going in circles - and <strong>Stop</strong> keeps whatever the run had reached instead of throwing it away. If it uses every attempt without getting there, you get the best one <em>and</em> what is still wrong with it, rather than a polite success.</p>
      <p>The finished scene can be orbited with the mouse. <strong>Save as page</strong> gives a self-contained HTML file that opens in any browser with nothing installed, <strong>Save as .glb</strong> gives a model for the tools you already use, <strong>Show the code</strong> opens the scene it wrote, and <strong>Share to Discover</strong> posts it (it appears in the feed once an admin approves it).</p>
      <div class="tip"><strong>This half needs a Vision provider,</strong> because looking at the render and saying what is wrong with it is the whole method. Settings &rsaquo; Integrations &rsaquo; Vision provider, and the page links straight there when it is missing.</div>

      <h3>Editor</h3>
      <p>The other surfaces make footage. This one cuts footage you already have. Open <strong>Sidebar &rsaquo; Studio</strong> and take the <strong>Video Editor</strong> door on Flow&rsquo;s home screen; it opens in the Studio window beside Skales. Make a project and put a recording in it.</p>
      <p><strong>Sighting comes first.</strong> Skales reads the whole recording in one pass and writes down where the shots change, where it goes quiet, and what is said and when. No part of the picture is sent to a model to do this, so the length of the recording is not the obstacle it usually is. It needs FFmpeg. Without a speech provider the shots and the silences are still found, and the sighting says plainly that the words are missing rather than pretending there was nothing to hear.</p>
      <p><strong>Then ask for the cut.</strong> Say what you want in the chat - a two minute version, the parts where the product is on screen. Skales names the stretches that make the film, each with one sentence of reasoning you can read, and lays them into the timeline with a thumbnail and a length beside every piece. Every segment is checked against what the sighting actually found and against the real length of its source, and anything that does not survive that check is thrown out and <em>named</em> as thrown out - you are told what it dropped and why, rather than quietly getting a shorter list.</p>
      <p><strong>Correcting the plan changes the plan.</strong> Take the third one out, make the opening shorter, put the ending back. There is only ever one plan per project, so what you asked for is what is on screen afterwards, and there is never a second plan sitting behind the first one.</p>
      <p>The Editor cuts, trims, reorders and exports. It is not a multi-track suite, and it does not pretend to be one. Exports report back to the bell and to the chat they were started from, so a long render does not need watching.</p>
      <p><strong>Generated clips belong in the same cut.</strong> A clip Skales made from a start picture is footage like any other, and it can be slowed down or sped up where it sits. Ask for the moment that matters to land on a beat - the car launching on the logo, the blink on the word - and the clip is cut around that moment so it hits exactly that second, with its sound kept in step or switched off. Every generated clip comes back with its start picture beside three of its frames, so a wrong picture is noticed and made again before it goes into the film; a clip the service refuses comes back with a softer wording to try.</p>
      <p><strong>The soundtrack in one step.</strong> Ask for the sound of the film and Skales mixes the voice lines on their seconds, the music ducked under the voice with its drop on the cut you name, the music lengthened by whole bars when it is too short, tape stops, sound effects on their cues and the clips' own sound, then brings the whole track to -14 LUFS. You get the mix and separate stems for voice, music, effects and clips, and Skales tells you what it measured: loudness, peak, how far the music sat under the voice, where the drop landed.</p>

      <h3>Voice / TTS</h3>
      <p>Paste or type a script and generate speech. Skales auto-detects your available TTS provider: Local (OS voices), ElevenLabs, Azure Neural TTS, Groq TTS, OpenAI TTS, or Google TTS. Preview in-app, then download as MP3.</p>

      <h3>Music Generation</h3>
      <p>Generate AI music via Meta MusicGen (HuggingFace). Select genre, mood, and duration. Preview and download the result directly from the Studio interface.</p>
      <p>A track made by the agent comes back measured: its length, the tempo it really plays at, the first downbeat, the drop and the bar-exact length it loops at. A generated track rarely keeps the tempo it was asked for, so a film is cut to these numbers rather than to the prompt, and a track that is too short is extended by looping it on the bar. Tracks longer than 30 seconds use Lyria 3 Pro on OpenRouter unless you choose another model.</p>

      <h3>Gallery</h3>
      <p>Every Studio output — images, videos, audio — is automatically saved to your Gallery. Filter by type, search by prompt, or browse the masonry grid. Click <strong>Reuse</strong> on any entry to jump back to the generating tab with the prompt and preview restored so you can continue iterating.</p>

      <h3>Brand Kit</h3>
      <p>Configure your brand once in <strong>Settings &rarr; General &rarr; Brand Kit</strong>: logo, primary colors, fonts, tagline, and tone of voice. Enable the <em>Use Brand Kit</em> checkbox in Image or Video generation to automatically inject brand context into every prompt.</p>

      <div class="tip"><strong>💡 Tip:</strong> All Studio files are stored under <code>~/.skales-data/studio/</code>. Images go to <code>gallery/</code>, videos to <code>videos/</code>. Filenames are prefixed with <code>skales_studio_</code>.</div>
    </section>

    <section id="flow">
      <h2><span class="icon">🌊</span> Flow</h2>
      <p>Flow is Studio&rsquo;s conversational design workspace: one brief, and it keeps working on it with you instead of returning a single result. Eleven modes, and Flow picks the one that fits what you asked unless you say otherwise: <strong>deck</strong>, <strong>e-learning</strong> course, <strong>prototype</strong>, <strong>wireframe</strong>, <strong>mobile</strong> mockup, print <strong>document</strong>, <strong>3D scene</strong>, <strong>image</strong>, <strong>video</strong>, <strong>film</strong> and <strong>motion</strong> graphic.</p>
      <h3>A window of its own</h3>
      <p>Flow opens beside Skales rather than inside it, the way Skales Code does. Start it from Studio and the workspace gets its own window, so a project that is generating for a few minutes does not hold the app hostage: you keep chatting, keep the Cockpit open, keep working, and look over at Flow when there is something to look at. Opening Flow again brings the window you already have back to the front instead of starting a second one, and closing it leaves the project exactly where it was - the versions are sealed on the disk, not in the window. Like Iris, Code and the main window, it carries your system&rsquo;s own window buttons and draws none of its own, so there is one place to close it and it is the place your operating system put it.</p>
      <h3>3D: a scene, written rather than generated</h3>
      <p>Pick <strong>3D scene</strong> and Flow writes a real three.js page: geometry, a three-light rig, shadows, a camera and a slow continuous move. The preview draws it and you turn it there. <strong>No provider and no key are involved</strong> &mdash; three.js travels inside Skales and is put into the page before it runs, so the scene also works with the network off. Follow-up messages change the scene the way they change any other Flow artifact.</p>
      <p>This is a <em>picture</em>, not a model file. When you want a real <code>.glb</code> you can open in Blender, that is the <strong>3D</strong> tile on the Flow home screen, and that one does need a provider (Replicate, fal.ai, Meshy or Tripo). The two sit next to each other on purpose: one is the thing Skales can always make, the other is the thing you can take away.</p>
      <p>A brief that says &ldquo;3D&rdquo; lands in this mode by itself while the composer is on Auto, so you rarely have to pick it.</p>
      <p>Building a scene from a photograph is a different thing again, and it lives in <strong>Studio &rsaquo; 3D</strong>. See <a href="#studio">Skales Studio</a>.</p>
      <h3>Film: one shot, one camera move</h3>
      <p>Film makes a single clip with a single deliberate camera move, and the move is what you pick first &mdash; before you write a word of the brief. Fifty-one of them, grouped by what they are: zoom, dolly, crane, pan, orbit, rig, aerial and lens. One move per clip, and there is no way to pick two: mixing camera moves in one generated shot is exactly what makes generated footage look generated.</p>
      <p>Where the clip comes from, in this order:</p>
      <ol>
        <li><strong>Higgsfield</strong>, if you have connected it as an MCP server under Settings. It executes a camera preset as a preset rather than as words, so it gives the best result for this mode.</li>
        <li><strong>The video APIs under Settings &rsaquo; Skales Studio</strong> &mdash; Kling, Runway, fal, Google Veo, Replicate or OpenRouter. None of them takes a camera-move parameter, so the move you picked steers the prompt instead. This is the normal path and it works well.</li>
        <li><strong>A Hugging Face Space you have activated</strong>, as the budget route: free or nearly so, on a shared queue, and slower.</li>
      </ol>
      <p>If none of the three is set up, the chip stays where it is and tells you which key is missing and where it goes. It keeps the camera move you picked either way. Follow-up messages are takes: &ldquo;tighter&rdquo;, &ldquo;try it as a crane up&rdquo;, &ldquo;same shot at night&rdquo; keep everything you did not change and save the result beside the earlier takes.</p>
      <p>On the phone, Film works the same way with the same moves, and generates through the video key on the phone (fal.ai under Integrations, or an OpenRouter key under Provider). With no key it says so rather than producing an animation and calling it a film.</p>
      <h3>A launch video, from Skales Code</h3>
      <p>Type <code>/launch</code> in a Code session &mdash; add a tone such as polished or cinematic, or a format such as vertical for reels &mdash; and Flow builds a short launch video from the project itself: its name, its words, its colours, fonts, screens and logo. Environment files, keys and secret folders are never read. The video renders and a post text is written beside it. The same works from any chat, in words, without opening Code first, and Flow has a Launch video template for starting the same way from the Templates tab.</p>
      <h3>Real takes of Skales itself</h3>
      <p>A film or a tutorial about Skales can show the real app instead of mock-ups. Ask for it in words &mdash; &ldquo;show the theme switching from light to dark, then Flat&rdquo;, &ldquo;record the Chat answering a question&rdquo; &mdash; in Flow, in the chat or in Skales Code. Skales starts a <strong>second copy of itself</strong> in the background on a free port, with a demo profile of its own beside your data folder: a copy of your settings with remote access, the public feed, telemetry, channel bots and autostarts switched off. It clicks through that copy like a person would (the moon button for light and dark, Settings &rsaquo; General &rsaquo; Appearance for the skin), films it, and keeps sharp still pictures along the way. Your own window, your desktop and your conversations are never filmed or touched.</p>
      <p>The take lands in the project's <code>captures</code> folder as an MP4 at 30 frames per second, the same take as a numbered picture sequence, the stills, and a <code>capture.json</code> that says when each step happened in the video &mdash; so Flow can place it as a layer and cut on the moment the theme turns dark. The second copy is closed when the take is done, when a step fails or when you press Stop. This is a desktop feature; the phone app has no second copy to record.</p>
      <h3>When it asks you something first</h3>
      <p>A brief that leaves essential decisions open can come back with a handful of <strong>scoping questions</strong> — a short clickable form in the preview rather than a paragraph asking you to reply in prose. It only does this when you chose to be asked: leave the composer on its normal setting and Flow gets on with it and shows you a result you can then correct.</p>

      <h3>Motion: a timeline, and sound</h3>
      <p>An animated project is no longer a row of scenes with everything trapped inside one of them. A caption, a lower third, a chapter marker or a watermark gets its <strong>own start time, its own length and its own layer</strong>, so it can run across a scene change, leave a gap and come back later. Ask for it in words — "keep the name in the corner for the whole film" — and that is what it becomes.</p>
      <p><strong>Sound arrives the same way.</strong> Voiceover, music and effects come from files in the project, each with a start, a length and a volume, and they are <em>mixed into the exported MP4</em> rather than only heard in the preview. Stepping the preview frame by frame stays silent, because a single frame has no sound to make.</p>
      <p>There are ready-made building blocks the composition uses instead of inventing one every time — caption, lower third, title card, stat pill, chapter marker, progress bar — and six scene transitions beyond the ones that were there: wipe, wipe up, blur through, push, push up, cross zoom.</p>
      <p><strong>It is read before it is rendered.</strong> A clip that starts after the video ends, a layer that does not exist, an animation aimed at nothing, an audio file that was never downloaded: each is named in plain words and sent back to be fixed, instead of producing a video with something silently missing from it.</p>
      <p>A finished film can be shared straight to <a href="#discover" style="color:var(--accent)">Discover</a> from the export sheet.</p>
      <p><strong>One film, every format.</strong> Ask for "9:16 and 16:9" and the composition is written once and rendered twice from the same timeline: <code>motion.mp4</code> and <code>motion-9x16.mp4</code> next to it (also 1:1, 4:5 or any size). Timing stays shared, only the layout changes; in the vertical cut, a recording of an interface is always shown as the whole window, never cropped. The render card lists every file.</p>
      <p><strong>It looks at its own film.</strong> Before calling a film done, the assistant can check it the way an editor would: contact sheets of every format, a scan of every frame for a picture that flashes for one frame, the soundtrack as waveform and spectrum with its loudness, and the layout rules (no text cut off at the edge, headings well inside the 16:9 frame, subtitles at least 200 px above the bottom, no overlapping text). It sees those pictures, fixes what it finds and renders only the seconds that changed instead of the whole film again. Recordings of the Skales interface, any video or a folder of pictures can be laid into a film as their own layer, slowed down or cut around a moment. The same works from Chat and Code with <code>render_motion</code>, <code>check_motion</code> and <code>add_motion_take</code> on any folder with a composition.</p>

      <h3>E-Learning: a course for Moodle and every other LMS</h3>
      <p>Choose <strong>E-Learning</strong> in the composer, or the course template in the E-Learning block of the Templates tab, and describe the course: audience, topic, length. Flow writes the slides and the narration per slide; the frame around them is always the same, and it is Skales&rsquo;s: a contents list that keeps what has not been reached locked, progress, sound, subtitles, a transcript, help, keyboard and screen-reader support, and the exercises &mdash; cards to turn, points on a picture, sorting into groups, putting steps in order, quizzes whose wrong answers explain the thinking error, gaps to fill. A learner moves on once a slide has been heard or read in the transcript and its task is done, and a course left halfway opens again on the same slide.</p>
      <p><strong>Voicing.</strong> In the export dialog of a course project, pick the speech provider and the voice (as set under Settings &gt; Voice unless you choose another) and voice the whole course. Only slides whose text changed are voiced again, the subtitles take their times from the real audio, and without a speech provider the dialog says where to set one up.</p>
      <p><strong>Export.</strong> Export &rarr; SCORM asks where the course goes, not which standard: Moodle and Totara get SCORM 1.2 (Moodle does not support SCORM 2004), corporate LMSs such as SAP SuccessFactors, Cornerstone, Docebo or ILIAS get SCORM 2004 4th Edition, Canvas gets a Common Cartridge, and cmi5, xAPI and AICC are there for systems that ask for exactly that. You choose when the course counts as done &mdash; last slide, every slide, a quiz score, or only when the course says so. The package is what the preview showed, it keeps its identity from the first export on, so replacing the file in the existing Moodle activity keeps every learner&rsquo;s progress, and a test button runs it in an LMS stand-in: start, stop halfway, come back, finish. The dialog also names the three settings a Moodle course needs: update the existing activity, completion &ldquo;Require status: Completed&rdquo;, display in the current window. Any deck, prototype or document can be exported the same way, and Chat and Code do it for any folder with <code>package_scorm</code>, <code>validate_package</code> and <code>test_scorm</code>.</p>
      <h3>Nothing you made is gone</h3>
      <p>Every turn seals a version of the whole project, so you can go back to any of them &mdash; and the rollback is itself sealed first, which is what keeps going back reversible.</p>
      <p><strong>Nothing falls off the end of the list.</strong> The version history, opened from the toolbar over the preview, keeps the most recent dozen on the shelf and marks everything older as <em>Archived</em>. An archived version is not a tombstone: it keeps its number and its files, and it can still be opened, restored, downloaded as a ZIP, or branched off into a project of its own. The thirteenth turn no longer costs you the first.</p>
      <p>Whole projects work the same way. Taking one out of the grid archives it and keeps everything; the archive filter on the grid brings it back. Deleting is the separate, deliberate one (the folder moves to a trash folder next to your projects).</p>
      <p><strong>What you get out is what you asked for, or it says so.</strong> When an export cannot be exactly the thing you named &mdash; slides that had no editable text to keep, a film with transparency that has to leave as WebM &mdash; the difference is a sentence you see, not a quieter file. And when nothing could be produced, you are told that, rather than handed a still picture where a film was asked for.</p>
      <h3>The canvas</h3>
      <p>The right half of a project is a <strong>canvas</strong>: every page, every variant, every picture &mdash; and, with <em>Versions</em> switched on, every earlier version &mdash; is a frame on one plane. Pinch (or Ctrl/Cmd and the wheel) to zoom, two fingers or the wheel to move around, drag an empty spot to pan, and the keys + &minus; 0 1 and the arrows do the same while the canvas has focus. Drag a frame by its title to arrange it; double-click it to open it in <strong>Focus</strong>, where the device widths, the presenter and the exports are. Where you left things is where they are the next time you open the project.</p>
      <p>Frames build themselves while a turn works: a frame whose file is being written reloads on its own and shows a small spinner, and a page that ends in the middle gets a warning once the turn is done. Only the frames you can actually see run as live pages; the rest show a still of themselves, which is why twenty frames stay as smooth as two.</p>
      <h3>Sending the next request while it works</h3>
      <p>The message box stays open while a turn works. What you type then goes into the <strong>queue</strong> above the box and runs as a turn of its own when the current one is done, one after another. You can change the words of a waiting request, move it up or down, or remove it. The queue survives a reload and a restart. If you stop a turn, or it fails, the queue pauses and says why, with a <em>Go on</em> button, instead of carrying on without you.</p>
      <h3>Changing it yourself: Inspect and Mark</h3>
      <p><strong>Inspect</strong> lets you click an element in a page: you see where it sits (the path above the panel), its text and its styles, and anything you change there &mdash; text, font, size, weight, spacing, colours, alignment, corners, a picture &mdash; is written straight into the project file. Undo and redo keep working after a reload. If a turn is working on the same file at that moment, it is told about your change, and if it writes over it anyway, your change is put back when the turn ends.</p>
      <p><strong>Mark</strong> is for changes you would rather describe: click the elements that need work, write a comment at each numbered pin, and send them together. The agent gets one request that says exactly which elements you meant, with a picture of each.</p>
      <h3>Variants side by side</h3>
      <p>Ask for &ldquo;three variants&rdquo; and three versions of the page appear next to each other on the canvas. <em>Take this</em> on the one you like makes it the page; the others are kept as versions, so none of them is lost.</p>
      <h3>Brand Kit and style packs</h3>
      <p>Your Brand Kit &mdash; logo, colours, fonts, tone &mdash; applies to a Flow project, and a style pack can be pinned next to it. Your brief always wins on content.</p>
      <p><strong>No house style.</strong> Without a Brand Kit or a style pack, Flow has no default look. Each project is offered a few design directions picked from its brief and away from what your last projects used, and the scratchpad names the one it took &mdash; so three similar briefs do not come back looking the same.</p>
      <h3>What Flow knows about you</h3>
      <p>Nothing, unless you say so. Every new project starts with <strong>My memory</strong> switched off: Flow works from the brief and the project files, not from your memory, your standing instructions or your notes. Switch the chip on in the composer (or later in the workspace head) and Flow gets your name, your brand or company and the style facts you saved &mdash; never your working rules, your projects or your notes. The choice belongs to the project and survives a reload.</p>
      <p>Your name or brand only goes into a design when the brief asks for it: &ldquo;my showreel&rdquo; or &ldquo;our company&rdquo; does, &ldquo;a showreel&rdquo; does not &mdash; that one stays fictional, without your name and without Skales in it.</p>
      <h3>Teaching Flow your taste</h3>
      <p>Under every finished result sit a <strong>thumbs up</strong> and a <strong>thumbs down</strong>. Up keeps what worked &mdash; the direction, the structure, the pacing, the type &mdash; as a short lesson; down keeps what to avoid, and asks for one optional line on why. The lessons live in one skill, <em>flow-style-lessons</em>, on the Skills page, marked <em>Flow only</em>, with an Undo for the last change. Only Flow reads it, never the chat, and a Flow conversation you do not rate teaches nothing and writes nothing into your memory.</p>
      <p>If an answer still ends at the model&rsquo;s output limit after Skales asked it for the rest, a note under it says so; send &ldquo;continue&rdquo; for the remainder.</p>
      <h3>Handing it to Code</h3>
      <p>A design in Studio or Flow can be handed to the coding session that will build it, so the thing you approved is what gets built.</p>
    </section>

    <section id="images">
      <h2><span class="icon">🎨</span> Image & Video Generation</h2>
      <p>Which models you can reach depends on which keys you have entered under <strong>Settings &rsaquo; Skales Studio</strong>. The lists below are what Skales offers per service; the picker only shows the ones you have a key for.</p>

      <h3>Pictures</h3>
      <ul>
        <li><strong>Google.</strong> Nano Banana Pro (Gemini 3 Pro Image), Nano Banana 2 (Gemini 3.1 Flash Image), Gemini Flash Image, Imagen 4 and Imagen 4 Fast.</li>
        <li><strong>OpenAI.</strong> GPT Image 1, and DALL-E 3 as the older one.</li>
        <li><strong>Replicate.</strong> Flux Schnell, Flux 1.1 Pro, Flux 1.1 Pro Ultra and Stable Diffusion XL.</li>
        <li><strong>HuggingFace.</strong> Flux Schnell (free), Flux Dev, SDXL Base, SD 3.5 Large and SDXL Lightning.</li>
        <li><strong>On your own machine.</strong> A running <strong>ComfyUI</strong> or <strong>Stable Diffusion WebUI</strong>. No key and no account: Skales talks to the server you already have. A GPU is what makes it bearable rather than what makes it work.</li>
      </ul>
      <p>Style presets sit next to the prompt rather than inside it: photorealistic, illustration, 3D render, anime, cinematic, or none. Aspect is 1:1, 16:9, 9:16 or 4:5.</p>

      <h3>Video</h3>
      <ul>
        <li><strong>Google Veo.</strong> Veo 3.1, Veo 3.1 Fast, and Veo 3 as the older tier.</li>
        <li><strong>Kling.</strong> v2, v1.6 and v1.5.</li>
        <li><strong>Runway</strong>, <strong>Replicate</strong> and <strong>fal</strong>.</li>
        <li><strong>Through a gateway.</strong> OpenRouter video, and Skales IQ video on the trial.</li>
      </ul>

      <p>Every generated clip runs as a background job. The provider&rsquo;s job number is saved the moment the provider hands it out, so if Skales restarts while a clip is rendering, the clip is collected afterwards instead of being ordered and paid for again. Several clips for one film can render side by side, and nothing cuts a slow clip short. The fast tier is the default (Veo 3.1 Fast); ask for the full model by name for a final take.</p>

      <div class="tip"><strong>Not every video needs a model.</strong> Studio's own renderer makes motion graphics, counters, slideshows and kinetic typography with no generation and no key at all, frame by frame through FFmpeg. See <a href="#studio">Skales Studio</a>, and <a href="#studio">Type</a> for the text one.</div>
    </section>

    <section id="templates">
      <h2><span class="icon">🗂️</span> Templates</h2>
      <p>37 pre-built prompt templates spanning every Skales module. Click any template to open the target module with the prompt already filled in — no copy-pasting required.</p>

      <h3>Template Categories</h3>
      <table>
        <thead><tr><th>Category</th><th>Examples</th></tr></thead>
        <tbody>
          <tr><td>Chat</td><td>Research briefing, email rewrite, document summary</td></tr>
          <tr><td>Codework</td><td>Refactor for readability, add unit tests, migrate to TypeScript</td></tr>
          <tr><td>Organization</td><td>Marketing campaign, competitive analysis, product spec</td></tr>
          <tr><td>Lio AI</td><td>Landing page, dashboard component, data visualizer</td></tr>
          <tr><td>Browser</td><td>Price comparison, news digest, form auto-fill</td></tr>
          <tr><td>Planner</td><td>Weekly agenda, project breakdown, task prioritizer</td></tr>
          <tr><td>Studio</td><td>Brand intro video, podcast cover art, social post graphic</td></tr>
        </tbody>
      </table>

      <h3>Template Maker</h3>
      <p>Build your own templates with the AI-guided interview wizard. Describe your use case, and the Template Maker generates a reusable prompt with the right structure, placeholders, and target module. Custom templates are stored locally and can be shared via the Discover Feed.</p>

      <div class="tip"><strong>💡 Tip:</strong> Templates shared to Discover can be forked by other users — a great way to share your best workflows with the community.</div>
    </section>

    <section id="wordpress">
      <h2><span class="icon">🌐</span> WordPress 2.0</h2>
      <p>Skales can build complete WordPress pages with AI. Connect your WordPress site via the Skales Connector Plugin (v1.2.0), then ask the AI to create pages:</p>
      <div class="code-block">"Create a landing page for my business with hero, features, pricing, and contact sections"</div>
      <p>The AI uses Elementor's Flexbox Container format with professional design templates. It can also search the web for current content before building pages.</p>
      <h3>Capabilities</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">15 Elementor Templates</div><div class="card-desc">Hero, Features, Testimonials, Pricing, CTA, Footer, and more.</div></div>
        <div class="card"><div class="card-title">10 Gutenberg Patterns</div><div class="card-desc">Block patterns for the default WordPress editor.</div></div>
        <div class="card"><div class="card-title">Selective Skill Injection</div><div class="card-desc">Reduces prompt from 96KB to ~13KB by injecting only relevant design sections.</div></div>
        <div class="card"><div class="card-title">Collision Detection</div><div class="card-desc">Plugin v1.2.0 prevents accidental page overwrites.</div></div>
      </div>
    </section>

    <!-- ===== Chapter: Iris and Voice ===== -->
    <section id="ch-iris" class="chapter-lead">
      <div class="lead-kicker">Chapter 5</div>
      <h2>Iris and Voice</h2>
      <p class="lead-intro">Same Skales, same conversation file, same tools and the same permissions. Only the way in is different: you talk, it answers out loud, and a ring of particles shows you what just happened.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a conversation with no keyboard in it</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">One spoken exchange, one thing to look at, one timer, all without touching the keyboard after the first key.</p>
        <ol>
          <li>
            <span class="do">Sidebar, <strong>Iris Orbit</strong>. Press <strong>Space</strong> and speak.</span>
            <span class="say">What is on my plan for today?</span>
            <span class="then">the eye open and the ring pulsing with your microphone level while you talk, then a spoken answer. You press Space once: after the first turn the ear opens again by itself at the end of every answer.</span>
            <span class="stuck">nothing was understood, the line under the eye says so and says why. It never fails silently.</span>
          </li>
          <li>
            <span class="do">Ask for something worth looking at rather than only hearing:</span>
            <span class="say">Search the web for what is new in local AI this week.</span>
            <span class="then">the ring leave the eye and become the border of a panel holding the results as cards with their sources. You did not ask for the panel and there is no button for it: it follows from what the answer did.</span>
          </li>
          <li>
            <span class="do">Ask for a shape. The vocabulary is the Lucide icon catalogue, in all twelve interface languages.</span>
            <span class="say">Morph into a coffee cup.</span>
            <span class="then">the particles rearrange. A word with no shape behind it is not an error; they simply stay as they are.</span>
          </li>
          <li>
            <span class="do">Start a timer out loud.</span>
            <span class="say">Twenty five minutes of focus.</span>
            <span class="then">the ring become the countdown digits themselves, and a shockwave when it goes off.</span>
          </li>
          <li>
            <span class="do">Right-click the window and open the first entry, <strong>What can I say?</strong></span>
            <span class="then">a list of sentences that actually do something, with a real example each. Asking her the same question out loud gets the same list.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT iris-orbit-panel.png
           Iris Orbit with an orbit open - the web search one is the most legible.
           Frame: the whole Iris window, at its normal size, dark background.
           Must show: the ring as the panel border, result cards with their sources
           inside it, and the one line of text under the eye. Do not screenshot the
           resting eye for this one; the resting state is already shown by the chapter.
      -->
      <figure class="shot pending">
        <img src="img/iris-orbit-panel.png" alt="When an answer is worth seeing, the ring becomes the panel around it." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; When an answer is worth seeing, the ring becomes the panel around it.</div>
        <figcaption>When an answer is worth seeing, the ring becomes the panel around it.</figcaption>
      </figure>

      <div class="warn"><strong>From a phone browser:</strong> Iris draws, but she will not hear you. A browser only hands out the microphone over HTTPS or on localhost, so a plain <code>http://100.x.x.x</code> address is refused silently by the browser rather than by Skales. See <a href="#iris">Reaching Iris from a phone browser</a>.</div>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#iris">Iris Orbit</a>
        <a href="#voice">Live Voice</a>
        <a href="#narration">Narration</a>
        <a href="#own-speech">Your own speech server</a>
        <a href="#buddy">Desktop Buddy</a>
        <a href="#aipointer">AIPointer ⦿</a>
      </div>
    </section>

    <section id="iris">
      <h2><span class="icon">👁</span> Iris Orbit</h2>
      <p>A window with no toolbar, no composer and no message list: a particle eye, and one line of text under it. It carries your system&rsquo;s own window buttons and nothing else &mdash; the traffic lights on macOS, the window buttons on Windows, the native frame on Linux &mdash; so it closes the way every other window on your machine closes, from the first second of the intro onwards. You talk, Skales answers out loud, and the particles do something that matches what just happened. It is the same Skales underneath - the same conversation file, the same model, the same tools, the same permissions. Only the way in is different.</p>
      <p><strong>It is a first version.</strong> It works and it is in the release, but not every test is through. If something behaves oddly here, it is worth reporting.</p>
      <p><strong>It is switched on when you install Skales</strong> (12.6.0). It was opt-in while it was being built, and a surface you have to find in Settings before it exists is a surface nobody finds. If you would rather not have it, the sidebar entry and the chat header button both go away again the moment you turn it off. With no provider key set up yet, the window says so and offers the way into Settings &rsaquo; Voice, like every other surface that needs one.</p>

      <h3>Opening it</h3>
      <ul>
        <li><strong>Sidebar &rsaquo; Iris Orbit</strong> opens a fresh voice conversation in its own window.</li>
        <li>The <strong>Iris Orbit button in the chat header</strong> hands the conversation you are already in over to the voice window. The same session, carried on out loud.</li>
      </ul>

      <h3>Speaking</h3>
      <p>Press <strong>Space</strong> and talk. The eye opens and the ring pulses with your microphone level, so you can see that the ear is really open. Skales decides you are finished when you stop talking; how long a silence that takes is <strong>Settings &rsaquo; Voice &rsaquo; how long a silence ends your turn</strong>, and the push-to-talk key is set right below it.</p>
      <p><strong>You only press it once.</strong> Once a conversation has started, the ear opens again by itself at the end of every answer she speaks, so a back-and-forth needs no keyboard at all. Space still works and still means the same thing. <strong>Mute</strong> in the right-click menu ends it, and the same entry brings her back.</p>
      <p>If nothing was understood, the line under the eye says so and says why. It never fails silently.</p>

      <h3>Typing</h3>
      <p><strong>Just start typing.</strong> A single field appears over the eye, Enter sends it, Escape makes it go away again. There is no composer sitting there waiting, on purpose - the surface is for talking, and the field is for the sentence you would rather not say out loud. A first-time hint says "Or just type" until you have done it once.</p>

      <h3>What lands in the ring</h3>
      <p>When an answer <em>is</em> the thing you asked to see - a poem, a list, a summary, a table - it goes <strong>inside the frame</strong>, readable, and the line under the eye carries only the short sentence that goes with it. Anything longer than that line can honestly hold is frame content by definition; it is never cut off mid-word. A short spoken answer opens nothing, which is not a fault and has no empty panel.</p>
      <p>The same is true of what her tools produce: a picture, a document, search results, a list. Something heavy goes to the window that owns it and <strong>she says where she put it</strong> - and a file she writes is announced rather than followed: approving a write does not move you to another window.</p>
      <p>When she wants to do something that needs your permission, she <strong>says what it is and waits</strong>. Two answers sit under the eye, and "yes" or "no" out loud works just as well.</p>

      <h3>What can I say?</h3>
      <p>The right-click menu's first entry is a list of sentences that actually do something, with a real example each: turning the particles into a shape, asking for something as a document, a web search, a timer, your tasks. Asking her out loud what she can do gets the same list back.</p>

      <h3>Reaching Iris from a phone browser</h3>
      <p>You can open Skales from another device over Tailscale, and Iris will draw - but <strong>she will not hear you</strong>, and that is the browser rather than Skales. A browser only hands out the microphone in a <em>secure context</em>: HTTPS, or localhost. Over a plain <code>http://100.x.x.x</code> address it refuses silently, so the surface looks like it is ignoring you. Nothing is broken and nothing needs fixing on the phone; the way to a working microphone from another device is HTTPS in front of the standalone server, and it is on the roadmap rather than in this release.</p>

      <h3>Morphs</h3>
      <p>The particles are not decoration: every deterministic thing Iris does has its own visual answer. A new conversation blinks. A timer becomes the countdown digits themselves. Something forgotten scatters and gathers again. And you can ask for a shape directly:</p>
      <ul>
        <li>"Morph into a car"</li>
        <li>"Turn into a coffee cup"</li>
        <li>"Become a music note"</li>
      </ul>
      <p>The shape vocabulary is the Lucide icon catalogue, and the words that reach it are recognised in all twelve interface languages, so "Auto", "voiture" and "coche" all find the car. A word with no shape behind it is not an error: the particles simply stay as they are.</p>

      <h3>Orbits: when the ring becomes a panel</h3>
      <p>Some answers are worth looking at rather than only listening to. When one is, the ring leaves the eye and becomes the border of a panel, sized to what it is holding. You do not ask for this and there is no button for it: it follows from what the answer DID.</p>
      <table>
        <thead><tr><th>What you asked for</th><th>What appears in the ring</th></tr></thead>
        <tbody>
          <tr><td>A picture: "draw me a...", "make an image of...", an edit or an upscale</td><td>The picture itself</td></tr>
          <tr><td>A document: "write me a plan", "put that in a document"</td><td>The document, readable, in the frame</td></tr>
          <tr><td>A web search: "look up...", "what is the news on..."</td><td>The results as cards, with their sources</td></tr>
          <tr><td>A list: your tasks, your day plan, the files in a folder</td><td>The list, with what is done ticked off</td></tr>
          <tr><td>Reading something: a page, a file, a Skales doc</td><td>The text</td></tr>
        </tbody>
      </table>
      <p><strong>Anything heavier goes where it belongs</strong> and she says so out loud rather than making you find it: a browsing session opens the browser, a generated video or a Flow artifact goes to Studio, code goes to Skales Code. The sentence you hear names the window it landed in.</p>
      <p>One orbit at a time, and it is the newest one: if an answer searched the web and then drew a picture, the picture is what you see, because that is what the last sentence was about. Click the backdrop, or say "close", and the ring goes back to being an eye.</p>
      <p>An answer with nothing to look at simply does not open one. That is not a failure and there is no empty panel for it.</p>

      <h3>Timers</h3>
      <p>"25 minutes of focus" starts a timer, and the ring becomes the countdown. Right-click while it runs to pause or resume it. When it goes off, a shockwave rolls out from the middle and Iris says so.</p>

      <h3>Wake word</h3>
      <p>Optional, and off until you train it. In <strong>Settings &rsaquo; Voice &rsaquo; Wake word</strong> you say "Iris" three times and Skales learns <em>your</em> pronunciation. Everything about it stays on the device: there is no cloud round trip and no recording leaves the machine. With it armed, the hint line reads "Listening for Iris" and you can start a turn without touching the keyboard.</p>

      <h3>Right-click</h3>
      <p>The window has almost no chrome, so the context menu is where the rest of it lives: <strong>New conversation</strong>, <strong>Conversations</strong> (the list of past voice sessions), <strong>Voice settings</strong> (straight to Settings &rsaquo; Voice), <strong>Copy the last answer</strong>, <strong>Ear shut, voice off</strong>, and <strong>Close window</strong>.</p>

      <h3>Closing it</h3>
      <p>Three ways, and all three work: the small cross that fades in at the top of the window while the mouse is moving, <strong>Cmd/Ctrl+W</strong>, and <strong>Escape</strong> while the eye is resting. A window nobody is touching goes back to being the buttonless field it was designed as.</p>

      <h3>Languages</h3>
      <p>Iris greets you and answers in the language you set under <strong>Settings &rsaquo; General &rsaquo; Native language</strong>. Set to "auto", or set to a language Skales has no interface translation for, the greeting follows the interface language while the answers still come in yours. The spoken language is the language of the text, so the two never drift apart.</p>

      <h3>Coming back to it</h3>
      <p>Reopening Iris picks up the last voice conversation and greets you with where you left off, rather than starting from nothing. "New conversation" (spoken, or from the right-click menu) is how you start clean.</p>

      <h3>Where the conversations live</h3>
      <p>Nowhere new. A voice conversation is an ordinary Skales session, in the same place as every other one, and it shows up in <strong>History</strong> like the rest. Open one in the chat and it is a normal chat - the voice surface is a way of talking to a session, not a separate kind of session.</p>
    </section>

    <section id="voice">
      <h2><span class="icon">🎤</span> Live Voice</h2>
      <p>Full-duplex voice conversation. Speak naturally and Skales responds with synthesized speech.</p>

      <h3>STT (Speech-to-Text)</h3>
      <p>Cascade order: <strong>Azure Speech</strong> → <strong>Groq Whisper</strong> → <strong>OpenAI Whisper</strong> → <strong>Web Speech API</strong> (browser fallback). Configure Azure and Groq keys in Settings → Voice.</p>

      <h3>TTS (Text-to-Speech)</h3>
      <p>Supported providers: <strong>Default</strong>, <strong>Local</strong> (your operating system&rsquo;s own voices), <strong>OpenAI</strong>, <strong>ElevenLabs</strong> and <strong>Azure</strong>. Voice and speed are configurable in Settings → Voice. (Groq is used for speech-to-text, not for speech.)</p>

      <h3>A live channel, where your provider has one</h3>
      <p>Normally Skales listens, then thinks, then speaks &mdash; three steps, each waiting for the one before it. Some providers offer something better: a <strong>real live audio channel</strong>, where your voice and the answer travel at the same time. Where that exists, Skales can use it instead.</p>
      <p>Turn it on under <strong>Settings &rsaquo; Voice</strong>, in the row about interrupting: <em>off</em>, <em>barge-in</em> (speak over an answer and the turn comes back to you mid-word, on any provider) and <em>realtime</em>. On the live channel it is the same Skales &mdash; the same conversation, the same tools, the same approval cards before anything is done &mdash; and speaking over it stops the <em>work</em> behind the voice, not just the talking.</p>
      <p>It is offered only when it can actually be opened: the provider has such a channel at all, there is a key for it, and a model that carries it is known. When one of those is missing the setting stays unselectable and says which one, rather than letting you pick a mode that would do nothing.</p>

      <h3>Who is speaking, and how it has been going</h3>
      <p>Above the voice list is a line naming who will <em>actually</em> speak, which is not always the tile you highlighted &mdash; a voice on your own machine set as the main one goes first on purpose. Once anything has been spoken, a second small line appears underneath with how the voice has behaved this session: which engine and language spoke last, how long it typically takes until the first sound, over how many attempts, and how many never came back at all. It is about the speaking and nothing else, and it starts fresh each time you open Skales.</p>

      <h3>Your Mac&rsquo;s voices, on your phone</h3>
      <p>Your Mac already has dozens of voices installed, the premium ones included, and they cost nothing and never leave your own devices. The paired Skales app (2.5.6 and newer) can use them: pick <strong>Voices from your Mac</strong> under Voice in the app, choose one from the list your computer reports, and this machine speaks for the phone over the pairing connection. It is offered only while this computer is awake and reachable in Remote mode; if it goes away mid-sentence the phone falls back to its own voice rather than going quiet. The same is available locally at <code>/api/tts/say</code> (GET lists the voices, POST returns audio). A computer that is not a Mac says so instead of reporting an empty voice list.</p>
    </section>

    <section id="narration">
      <h2><span class="icon">🔊</span> Narration</h2>
      <p>Skales turns a text or a whole course into narrated audio files with the voice <em>you</em> choose: the one set under <strong>Settings &rsaquo; Voice</strong>, or any other you have set up &mdash; OpenRouter&rsquo;s speech models and its audio models, ElevenLabs, Azure, OpenAI, the offline voice on this computer, and the rest. Ask it to play the same sentence in a few voices first and choose by ear.</p>
      <p>Long texts are voiced in short parts and joined with short pauses, and every join is checked for clicks. You get an mp3 (or wav) per slide, subtitles whose times come from the audio itself, and a transcript. A word can be spoken differently from how it is written &mdash; the caption says &ldquo;PDF&rdquo; while the voice says it the way your listeners do. When you change a slide, only that slide is voiced again. A long course runs in the background, keeps going if you close the window, and continues after a restart. The cost is shown when a provider reports it.</p>
      <p>A script with several speakers is one request: each line can carry its own voice and its own direction (a narrator and a side character on OpenRouter&rsquo;s gpt-audio, for example). Every line comes back with its length and the measured start of each spoken phrase, so a cut or a caption can land on the word. A tempo factor makes the read brisker or calmer without changing the pitch, and long pauses inside a line can be shortened to a limit you set. When an audio model says a line differently from the script, the reply names what it actually said.</p>
    </section>

    <section id="own-speech">
      <h2><span class="icon">🗣️</span> Your own speech server</h2>
      <p>Reading aloud and dictation do not have to go through a provider. Under <strong>Settings</strong> you can point Skales at your own endpoint for text-to-speech and for speech-to-text, so the voice side runs wherever you decide &mdash; a machine on your network, a container, a service you host. Everything that speaks or listens in Skales then uses it: the chat, the Code window&rsquo;s dictation, voice notes.</p>
    </section>

    <section id="buddy">
      <h2><span class="icon">🦎</span> Desktop Buddy</h2>
      <p>A floating AI companion that lives on your desktop. Always accessible, even when Skales is minimized.</p>

      <h3>A full agent (v11.3.2 &ldquo;Re-Buddy&rdquo;)</h3>
      <p>The buddy runs the complete multi-step agent loop &mdash; with the same generous working budget as the WhatsApp/Telegram channels. Ask it to clean a folder, send a mail, check your calendar: it works until the task is done, and the speech bubble shows <strong>live progress lines</strong> as each step finishes. It speaks with your configured persona, in your language, recalls what it knows about you, and keeps its <strong>own conversation thread</strong> &mdash; &ldquo;Open Chat&rdquo; jumps straight to it.</p>

      <h3>Buddy skins</h3>
      <p>Choose Skales, Bubbles or Capy in <strong>Settings → General → Desktop Buddy → Buddy Skin</strong>.</p>

      <h3>Approve / Decline &mdash; and it keeps going</h3>
      <p>When Skales needs confirmation before an action (in Safe Mode), the Buddy shows approve/decline buttons in the bubble. Since v11.3.2, approving <strong>continues the task</strong> with the remaining step budget instead of ending the turn &mdash; multi-step jobs ask again when the next gated step comes up.</p>

      <h3>Friend Mode</h3>
      <p>When Friend Mode is enabled, the Buddy proactively reaches out — checking in, celebrating wins, or sending nudges based on your activity. Messages can be delivered via Chat, Telegram, or WhatsApp.</p>

      <h3>Follow-through</h3>
      <p>A check-in knows what is still open: running goals, tasks, schedules due within two days and the question a recent conversation ended on (private chats are never read). It may look things up with read-only tools first, then follows up on <strong>one</strong> point with the next step and a few answers to tap. A follow-up arrives on <strong>one channel only</strong>: the one you wrote on last, otherwise the first one you chose. On WhatsApp and in mail, where there are no buttons, the answers come as links. Answer <strong>done</strong> or <strong>no</strong> and the point is closed; answer <strong>later</strong>, <strong>tonight</strong>, <strong>tomorrow</strong>, <strong>this weekend</strong> or <strong>next week</strong> and it rests until then and comes back exactly once. An answer on any channel or a reply button on your phone settles it everywhere. The switch and what the last check-in cost are in the Friend Mode settings.</p>

      <div class="tip"><strong>💡 Tip:</strong> Friend Mode works independently of Autopilot. You don't need Autopilot enabled to receive proactive messages.</div>
    </section>

    <section id="aipointer">
      <h2><span class="icon">👁️</span> AIPointer ⦿</h2>
      <p>A cursor-anchored quick-ask overlay that floats over any application. Hold the <strong>right Cmd key</strong> (right Ctrl on Windows and Linux) or wiggle your cursor, then type or speak a question about whatever you are pointing at. Turn it on in Settings → Extensions → AIPointer ⦿. It replaces the old Spotlight bar.</p>

      <h3>Choosing the trigger key, and knowing it arrives</h3>
      <p>Which modifier sits in a given position is a property of the keyboard rather than of the operating system &mdash; on many non-Apple keyboards the key where right Cmd sits reports itself as right Alt &mdash; so a key picked from a list can be a key the app never hears. Beside the picker under <strong>Settings &rarr; Extensions &rarr; AIPointer &#10687;</strong> there is <strong>Choose by pressing</strong>: press it, hold the key you want for a moment, and AIPointer takes the name from the key itself. Only modifiers are accepted; anything else is refused with a sentence. The list stays, for keyboards you are not sitting at and for the Web UI, where nothing can listen.</p>
      <p>The row under the picker says what is actually happening: the key it last saw and how long ago, or that you are holding a different key than the one selected, or that macOS is letting Skales watch the mouse while withholding keystrokes &mdash; which looks exactly like a broken hotkey, since the wiggle still works. Accessibility that is switched off says so with a way straight to it. A hotkey that never fires and a hotkey you are simply not pressing used to look identical from the outside.</p>
      <p>The hold duration on the same page governs how long the key has to be held, and turning AIPointer off and on again leaves your trigger key, appearance and crop settings exactly where they were.</p>

      <h3>It already knows you</h3>
      <p>AIPointer reads your Skales identity on every query (name, language, timezone, active projects), so you never re-introduce yourself. Ask "what was I working on?" and it pulls your recent topics; mention a name and it looks the person up in your knowledge graph.</p>

      <h3>Vision built in</h3>
      <p>AIPointer captures the area around your cursor and sends it to your vision model, so "what am I looking at?" just works. Hold the trigger a second time and drag a rectangle to capture an exact region. It honours the dedicated Vision Provider you set under Settings → AI &amp; Models → Models per task, so a local LLaVA on Ollama or a custom endpoint handles the screenshot.</p>

      <h3>It can do things in Skales</h3>
      <p>Four quick actions fit the 2-second loop: remember this, add to my todos, save as a note, and schedule something. For anything bigger, the Send button hands the question and answer to full Skales chat as a new session with complete context.</p>

      <h3>Voice and read-aloud</h3>
      <p>Ask by voice, and AIPointer reads answers back through the on-device Kokoro engine in 28 voices, with no API key and no cloud round-trip. Every knob lives under Settings → Extensions → AIPointer ⦿: trigger hotkey, mouse wiggle, hold duration, voice-first mode, accent colour, and more.</p>
    </section>

    <!-- ===== Chapter: Automation ===== -->
    <section id="ch-auto" class="chapter-lead">
      <div class="lead-kicker">Chapter 6</div>
      <h2>Automation</h2>
      <p class="lead-intro">Everything here does work while you are doing something else: on a clock, in the background, in a browser, or on the screen itself. All of it can be watched, and all of it can be stopped.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a task that runs without you, safely</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">One scheduled task, tried as a dry run first so nothing happens the first time you get it wrong.</p>
        <ol>
          <li>
            <span class="do">Sidebar, <strong>Planner</strong>, then <strong>AI Tasks</strong> and a new task. Describe it the way you would ask a person:</span>
            <span class="say">Every weekday at 08:00, check my calendar for the day and write me a short summary of what is coming.</span>
            <span class="then">the schedule read out of the sentence, and a confidence score on the interpretation.</span>
          </li>
          <li>
            <span class="do">Turn <strong>Dry run</strong> on and run it once by hand.</span>
            <span class="then">exactly what it would have done, with nothing sent and nothing written.</span>
            <span class="stuck">the interpretation is wrong, the confidence score usually said so first. Rewrite the sentence rather than the schedule.</span>
          </li>
          <li>
            <span class="do">Turn the dry run off and let it run for real once.</span>
            <span class="then">the result in Task History, with what it did and what it cost.</span>
          </li>
          <li>
            <span class="do">Now try the other shape of the same idea. In the chat, start a goal:</span>
            <span class="say">/goal Collect the pricing pages of the five best known note taking apps and put them in one table.</span>
            <span class="then">a plan you can read before it runs, and then, in the <strong>Cockpit</strong> from the Chat sidebar, the same goal live on the board with the running cost beside it.</span>
          </li>
          <li>
            <span class="do">Leave one thing standing: <strong>Always-On Agent</strong> has built-in jobs and you can add your own schedule.</span>
            <span class="then">the job listed with its next run. Everything running anywhere is visible, and one button stops it.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT auto-task-dryrun.png
           Tasks, one AI task open, dry run on, showing the result of a dry execution.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the natural-language schedule as it was typed, the confidence
           score, the Dry run switch clearly on, and the dry result underneath.
      -->
      <figure class="shot pending">
        <img src="img/auto-task-dryrun.png" alt="Dry run: what it would have done, with nothing actually done." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Dry run: what it would have done, with nothing actually done.</div>
        <figcaption>Dry run: what it would have done, with nothing actually done.</figcaption>
      </figure>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#ai-tasks">Planner AI Tasks</a>
        <a href="#planner">Planner</a>
        <a href="#autopilot">Cockpit</a>
        <a href="#projects">Projects</a>
        <a href="#schedule">Schedule (Cockpit)</a>
        <a href="#browser">The browser the agent drives</a>
        <a href="#playbooks">Playbooks</a>
        <a href="#workflow">Workflow</a>
        <a href="#computer-use">Computer Use</a>
        <a href="#download-file">Download File</a>
      </div>
    </section>

    <section id="ai-tasks">
      <h2><span class="icon">⏰</span> Planner AI Tasks</h2>
      <p>Schedule AI tasks to run automatically — once, daily, weekly, or monthly. Tasks are visible in the Planner calendar as purple blocks and execute silently in the background.</p>

      <h3>Creating a Task</h3>
      <p>Open <strong>Planner → AI Tasks</strong>, click <strong>New Task</strong>, describe what the AI should do, and set a schedule. The task is saved with a cron expression and fires automatically at the specified time.</p>

      <h3>Confidence Scoring</h3>
      <p>Before executing, the AI scores its confidence in completing the task safely (0–100%). Tasks scoring below 50% are skipped automatically and flagged for review, preventing accidental destructive actions.</p>

      <h3>Dry Run Mode</h3>
      <p>Enable Dry Run to simulate task execution without actually performing any actions. The AI describes exactly what it would do — useful for testing tasks before activating them on a live schedule.</p>

      <h3>Task History</h3>
      <p>Each task run is logged with the tools used, duration, and a summary of the result. Review the history from the AI Tasks panel to audit what ran and when.</p>

      <div class="tip"><strong>💡 Tip:</strong> Browser Playbooks can be scheduled as AI Tasks — record a workflow once, then let Skales replay it on a recurring schedule.</div>
    </section>

    <section id="planner">
      <h2><span class="icon">📅</span> Planner</h2>
      <p>AI-powered daily planner that learns your work patterns. An 8-step wizard learns your preferences, generates time-blocked plans from calendar events, and pushes them back to your calendar. Chat integration with "plan my day" commands.</p>

      <h3>8-Step Wizard</h3>
      <p>On first use, a guided wizard learns your work patterns, available hours, break preferences, and constraints. This context is used to personalize all future plan generation.</p>

      <h3>Month View</h3>
      <p>The default calendar view shows the entire month at a glance. Click on any day to see detailed plans.</p>

      <h3>Daily Context</h3>
      <p>Add day-specific notes directly in your planner (e.g., <strong>"I'm busy at 12:00"</strong> or <strong>"Important deadline"</strong>). The AI uses this context to generate smarter schedules around your constraints.</p>

      <h3>Generate & Regenerate</h3>
      <p>Use <strong>Generate</strong> to create a new daily plan from your calendar events, or <strong>Regenerate</strong> to try again with different AI reasoning. Plans are automatically saved and synced back to your calendar.</p>

      <h3>.ICS Export</h3>
      <p>Download plans as <code>.ics</code> files for use with any calendar application — no provider connection needed.</p>

      <h3>Chat Integration</h3>
      <p>In chat, ask "plan my day" or "schedule my week" and Skales will generate plans directly from context.</p>
    </section>

    <section id="autopilot">
      <h2><span class="icon">⚡</span> Cockpit</h2>
      <p><strong>What it is.</strong> The Cockpit is the one screen that shows everything standing: goals, tasks and scheduled jobs together, on a single board. It is not three screens behind three tabs any more and there is no Autopilot panel behind it &mdash; one heading, one board, and the full surfaces folded away underneath.</p>
      <p><strong>Where it lives.</strong> The entry is called <strong>Cockpit</strong> and is the third row of the <strong>Chat</strong> sidebar, where it opens as a window over the conversation; the same screen answers at <code>/autopilot</code>. The route keeps its old name on purpose: renaming a surface is not a reason to break every link that already points at it. There is no Autopilot page or sidebar entry any more.</p>

      <h3>The head</h3>
      <p>The heading carries the runner&rsquo;s own controls and nothing else: <strong>Pause</strong> or <strong>Resume</strong>, the <strong>deep-dive interview</strong>, and the <strong>daily stand-up</strong>. If a spend ceiling paused the runner, the head says so and offers the one pill that lifts it &mdash; the only place that decision is made.</p>

      <h3>The board: four columns, three sorts</h3>
      <p>The board has four columns &mdash; <strong>Pending</strong>, <strong>In Progress</strong>, <strong>Completed</strong> and <strong>Blocked</strong> &mdash; and every line of work takes the same card shape, with a label saying which sort it is.</p>
      <ul>
        <li><strong>Goals</strong> stand in the column their ledger puts them in. A goal waiting on an answer from you stands in Blocked, because it will not move until you move it. From the card you can stop it, carry it on, or open the conversation it lives in.</li>
        <li><strong>Tasks</strong> come from both stores: the queue the autopilot works through, labelled Autopilot, and the records of the Tasks page, labelled Task. Each card acts on the store it came from, so approving here is the same approval as approving there. Approve, reject, retry, cancel and delete are on the card; an autopilot card can also be dragged to another column.</li>
        <li><strong>Schedules</strong> stand by their switch: a job that is switched off sits in Blocked, because it will never come round again on its own. Switch it on or off, or run it now, from the card.</li>
      </ul>
      <p>Two moves on the board are refused rather than faked: you cannot drop a card into In Progress, because that is where Skales puts a task when it actually picks it up, and you cannot drag a running task out from under the runner &mdash; cancel it first. Filters by sort and a Kanban/list switch sit above the board and survive switching away and back.</p>

      <h3>Live: one switch, not a second tab bar</h3>
      <p>Next to the board sits a single <strong>Board / Live</strong> switch, and the address carries it (<code>/autopilot?tab=board</code>, <code>?tab=live</code>) so a reload, a bookmark or a link you sent yourself comes back where it was. Live is one view, not two: the execution trace of the task that is running, and the runner’s own log beneath it &mdash; what it thought, which tool it called, what came back.</p>

      <h3>The sections under the board</h3>
      <p>Below the board, three collapsible sections open the full surfaces unchanged. One is open at a time, and the Cockpit deliberately does not remember which &mdash; it starts closed every time, so the board is what you see first.</p>
      <ul>
        <li><strong>Goals</strong> &mdash; each goal with its objective, its criteria and the evidence against them, the last steps, the artifacts it produced, the lessons it drew and what it spent.</li>
        <li><strong>Schedule</strong> &mdash; the recurring jobs as a cron list. This is the list, not the calendar; the visual calendar is Planner.</li>
        <li><strong>Tasks</strong> &mdash; the same screen the <code>/tasks</code> page shows, hosted here rather than copied.</li>
      </ul>
      <h3>Where the eight controls live</h3>
      <p>The Cockpit has no Control panel: a control belongs where the thing it acts on is, so these eight sit in four different places.</p>
      <ul>
        <li><strong>At the head of the Cockpit</strong>, beside Pause and Resume: the <strong>deep-dive interview</strong> and the plan it drafts, the <strong>daily stand-up</strong>, and the button that <strong>lifts a spending pause</strong> &mdash; the three that <em>start</em> something rather than set it.</li>
        <li><strong>Settings &rsaquo; Goals</strong>: when the runner may be awake, what it may spend in an hour, and the pause-after-N-tasks cap. These are values, and values live in Settings.</li>
        <li><strong>At the head of Tasks</strong>: the line you type straight into the queue, over the queue it writes into.</li>
        <li><strong>Settings &rsaquo; Advanced &rsaquo; Diagnostics</strong>: the reset for a wedged scheduler, where a person looks when something is stuck.</li>
      </ul>

      <h3>On the phone</h3>
      <p>Skales Mobile has the same Cockpit. Because a phone is tall and not wide, the four columns are drawn as four sections under each other in the same order, with the same cards, the same labels and the same actions; the Board/Live switch, the Pause/Resume in the head and the collapsible sections are all there. A card also says where it came from, this phone or your computer, so the two never blur.</p>
      <p>The board reaches your computer over the same pairing everything else uses. If your desktop is older than 12.9.21, it does not know the board request yet: the phone notices, falls back to the lines it can honestly get, fills only the two columns those lines support, and says on screen why Completed and Blocked are empty &mdash; instead of showing you an empty board and letting you guess. With no pairing at all, the remote sections show the usual settings hint and the phone’s own lines still stand.</p>

      <div class="tip"><strong>💡 Tip:</strong> The background runner has to be enabled in Settings → Assistant → Working style &amp; Autonomy before queued tasks are worked through. Friend Mode and Buddy Intelligence work independently of that switch.</div>
    </section>

    <section id="projects">
      <h2><span class="icon">💡</span> Projects</h2>
      <p><strong>Projects</strong> is the tracker for work that runs longer than one conversation: an idea you captured, the milestones under it, the notes you kept, and the chats that belong to it. Everything is stored on this machine and nothing is sent anywhere.</p>
      <p>A project holds a status and a priority, milestones you tick off, tags, attachments and a set of notes. From a project you open a chat that already carries those notes and the tools the work needs, so a session about it never starts from an empty page. Sessions you started that way stay linked to the project and are listed on it; a link can be undone without touching the conversation.</p>
      <p><strong>Projects has no entry in the menu in this build.</strong> The four project tools stay in the chat, so an agent can still open a project, add a note, tick a milestone and list what is standing; the <strong>Projects</strong> add-on still switches those, and the page answers at <code>/projects</code> for anybody who goes to it. Your projects and everything in them are untouched either way.</p>
    </section>

    <section id="schedule">
      <h2><span class="icon">⏰</span> Schedule</h2>
      <p>One job store, one clock. A job is anything Skales runs without you watching: a prompt, a goal, a workflow, a playbook, a team run or a plugin job. Every job lives in the same list, follows the same failure rule (three failures in a row pause it, and it says so) and shows up on the Cockpit board while it runs.</p>

      <h3 id="blueprints">Blueprints: ready-made automations</h3>
      <p>Open <strong>Schedule &rarr; Blueprints</strong> for sixteen automations that only need a few answers: important-mail watch, news digest, morning brief, weekly review, a repeating reminder, price, competitor, content and community watch, bills and renewals, a task check, a team update, a data comparison, system health, a learning digest, and one you describe yourself. Pick one, answer its questions, choose how often it runs, and choose where each result goes besides the app: your paired phone, Telegram, WhatsApp or email.</p>
      <p>What you get is an ordinary job in the list below, marked <em>Blueprint</em>. Pause it, run it now, delete it or open its answers again with the pencil. Asking for the same automation twice keeps the one you have. If a blueprint needs something that is not set up yet, such as a mailbox, the card says so with a link to the right place in Settings, and nothing is created until it is.</p>
      <p>The same catalogue is in the chat: type <code>/blueprint</code> for the list, or <code>/blueprint price watch</code> and Skales asks the questions in the conversation. Skales Mobile shows the same blueprints and the same jobs through your paired computer. Blueprints run on local models as well.</p>

      <h3>What fires a job</h3>
      <table>
        <thead><tr><th>Trigger</th><th>What it means</th></tr></thead>
        <tbody>
          <tr><td>Clock</td><td>A cron expression such as <code>0 9 * * 1-5</code> (weekdays at 9), read in your time zone.</td></tr>
          <tr><td>Watched folder</td><td>A file arriving or changing in a folder you name starts the job with the file as context.</td></tr>
          <tr><td>Watched mailbox</td><td>A message matching a sender, subject or label starts the job once per message, even across restarts.</td></tr>
          <tr><td>Webhook</td><td>A call to the webhook address becomes a task on the Tasks page with its payload as context.</td></tr>
        </tbody>
      </table>

      <h3>Built-in jobs</h3>
      <table>
        <thead><tr><th>Job</th><th>Schedule</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>Identity Maintenance</td><td>Daily</td><td>Updates your Skales identity file with new learnings, memories, and preferences.</td></tr>
          <tr><td>Morning Briefing</td><td>Configurable</td><td>Daily summary of tasks, calendar, and news. Delivered to Telegram if configured.</td></tr>
        </tbody>
      </table>

      <h3>Asking for one in a chat</h3>
      <p>You do not have to build a job on the Schedule page. Say what you want in a conversation &mdash; <em>&ldquo;every time an invoice lands in this folder, file it and tell me&rdquo;</em> &mdash; and the whole job is made in one go: what fires it, what it then does, which folder it works in, which agent runs it, where the answer should go, and whether it may get on with it without asking. A watched folder or mailbox starts watching straight away rather than at the next restart, and the job can be fired once as a test so you can see what it does before you leave it alone with it.</p>

      <h3>&ldquo;Don&rsquo;t ask me first&rdquo; is all it means</h3>
      <p>A job can be told not to stop and ask before it starts. That is the whole of it, and it is worth being precise about, because it is easy to read as more. Such a run is <strong>still listed</strong> on the Schedule page and on the Cockpit board, it can still be stopped, every approval inside it still applies &mdash; anything dangerous still asks you, mid-run, by name &mdash; and its result still reaches your notifications and any channel you switched on. A job that says &ldquo;remind me&rdquo; still reminds you. It is not an invisible run and it is not a run without rules. The only genuinely silent runs are Skales tidying up after itself.</p>

      <h3>Autonomous</h3>
      <p>One switch, one name. <em>Autonomous</em> in Settings under Goals lets Skales act on its own inside a time window: run its jobs, work on goals, and pick an interrupted run back up after a restart. When it is off, jobs still run on their clock but nothing is resumed on its own.</p>
    </section>

    <section id="browser">
      <h2><span class="icon">🌐</span> The browser the agent drives</h2>
      <p>Skales has a real browser of its own, with its own profile and its own logins, and the agent drives it. <strong>You reach it from the chat.</strong> Ask for something on the web that needs more than a search — <em>"go to hacker news and summarise the top five stories"</em>, <em>"check the tracking number on the courier's site"</em> — and it navigates, reads the page and answers, up to ten steps per command. The tools are switched on and off as <strong>Browser Control</strong> on the Add-Ons page.</p>
      <p><strong>The Browser surface has no entry in the menu in this build.</strong> The tools above are untouched and are where the feature actually lives now; the page still answers at <code>/browser</code> for anybody who goes to it, and the Code window keeps its own browser panel behind the globe in its title bar.</p>

      <p><strong>A browser closes with the run that opened it</strong>, however that run ended, and one left sitting untouched closes itself after the session length set under <strong>Settings &rarr; Accounts &amp; Services &rarr; Browser control</strong>. Nothing is lost: cookies and logins live in the browser profile, so the next page opens still signed in. Quitting Skales sweeps up any browser an earlier crash left behind.</p>

      <h3>Several steps in one go</h3>
      <p>With a decision model switched on under <strong>Settings &gt; Assistant &gt; Writing help &gt; Decisions</strong>, the agent gains <code>browser_act</code>: it names a goal on the page that is already open, and Skales takes the steps towards it one after another, each decided in a fraction of a second instead of a full round of thinking. It stops and hands the page back when it is unsure, when it is going in circles, when the goal is reached, and before anything that buys, pays, sends, publishes, deletes or signs in, so the approvals you know still apply. It never invents text: a search term or a form entry comes from your request or from the model, never from the decision model. Without a decision model the tool does not exist and browsing works exactly as before.</p>

      <h3>Sign in to sites</h3>
      <p>When a task needs you logged in (X, Reddit, a webshop), Skales opens a visible browser window so you can sign in by hand. Your login is saved to the Skales browser profile and reused by later browsing. Skales never sees your password. Open a login window any time from Settings → Accounts &amp; Services → Browser control ("Log in to a website"), or turn on "Show browser window" there to watch Skales work. When it reads a page, Skales now uses a compact text map of the page instead of a Vision screenshot for each step, which is faster and cheaper; screenshots are still used for image-heavy pages.</p>
    </section>

    <section id="playbooks">
      <h2><span class="icon">🚀</span> Playbooks</h2>
      <p>A <strong>playbook</strong> is a browser run recorded once and replayed on demand. Press <em>Record</em>, do the task in the browser yourself — click, type, scroll, upload — and every step is written down as you go.</p>
      <p>Steps can be edited afterwards, and a step that holds something secret is marked as such so it is asked for rather than stored. A playbook can carry <strong>variables</strong> (<code>{{name}}</code>): running it then asks for the values first and fills them in. Runs can be put on a schedule, and a recorded playbook can be promoted into a <em>Workflow</em> so an agent can trigger it.</p>
      <h3>A step the unattended replay cannot do</h3>
      <p>A playbook running on a schedule replays in the background, without the browser window in front of you &mdash; and a few kinds of recorded step only make sense with that window there. When one of those turns up, it is <strong>named and skipped</strong> and the rest of the flow carries on, and such a run never reports itself as finished: it tells you which steps were left out and that the Browser view can replay them properly. A step that failed to open a page at all is the one failure that stops the run, because everything written after it was written for a page that never appeared.</p>
      <p><strong>Playbooks has no entry in the menu in this build.</strong> A recorded playbook still runs: an agent can be asked for one by name in the chat, and a playbook on a schedule fires the same as any other job. The <strong>Playbooks</strong> add-on still switches that, your recordings are untouched, and the page answers at <code>/playbooks</code> for anybody who goes to it. What is gone is the door, and with it the way to record a <em>new</em> one from the menu.</p>
    </section>

    <section id="workflow">
      <h2><span class="icon">🔀</span> Workflow</h2>
      <p>A <strong>workflow</strong> is a plan you draw by hand: the steps of a job, in order, with the tools each step may use, saved under a name the agent can be asked for. Where a playbook is a recording of a browser session, a workflow is the instruction for a piece of work — and a recorded playbook can become one, which is how the two halves of the automation chain meet.</p>
      <p>Each workflow has a trigger (a <code>/goal-name</code> command, a schedule, or a call from the chat) and the steps under it. They live on this machine and run with the tools you already have switched on.</p>
      <p><strong>Workflow has no entry in the menu in this build.</strong> The workflows you already have keep their triggers — the <code>/goal-name</code> command, the schedule, the call from the chat — and the <strong>Workflow</strong> add-on still switches them; the page answers at <code>/workflow</code> for anybody who goes to it. What is gone is the door, and with it the way to draw a <em>new</em> one from the menu.</p>
    </section>

    <section id="computer-use">
      <h2><span class="icon">🖥️</span> Computer Use</h2>
      <p>Skales can control your desktop. Screenshots, mouse clicks, keyboard input, and scrolling.</p>

      <h3>Looking at the screen</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">Screenshot</div><div class="card-desc">Capture your screen. Appears inline in chat.</div></div>
        <div class="card"><div class="card-title">Click</div><div class="card-desc">Click at specific coordinates on your screen.</div></div>
        <div class="card"><div class="card-title">Type</div><div class="card-desc">Type text into the currently focused application.</div></div>
        <div class="card"><div class="card-title">Scroll</div><div class="card-desc">Scroll up or down in the active window.</div></div>
      </div>

      <h3>Reading the screen</h3>
      <p>Skales does not only look at a picture of your desktop. It can ask the operating system what is actually on it &mdash; which buttons, fields and menus exist, what each one is called and what kind of control it is &mdash; and then act on a name instead of a coordinate. That is the difference between &ldquo;click at 840, 412&rdquo; and &ldquo;click <em>Send</em>&rdquo;, and it is why a window that moved does not derail the job.</p>
      <div class="card-grid">
        <div class="card"><div class="card-title">Read the screen</div><div class="card-desc">List the controls in front of you with their names and kinds, instead of guessing from pixels.</div></div>
        <div class="card"><div class="card-title">List windows</div><div class="card-desc">See which applications and windows are open right now.</div></div>
        <div class="card"><div class="card-title">Focus a window</div><div class="card-desc">Bring a named app or window to the front before working in it.</div></div>
        <div class="card"><div class="card-title">Open an app</div><div class="card-desc">Launch an application by name.</div></div>
        <div class="card"><div class="card-title">Check afterwards</div><div class="card-desc">Confirm that what was supposed to happen really did &mdash; before reporting it as done.</div></div>
      </div>

      <h3>When a click is refused</h3>
      <p>Every screenshot carries which display it came from and a number saying how current it is, and a click refers back to that. If a window moved, a monitor changed or the picture went stale between looking and clicking, the click is <strong>refused with the reason</strong> rather than landing somewhere else on your screen. A refusal here is the feature working.</p>

      <div class="warn"><strong>⚠️ On a Mac you must allow it once</strong> &mdash; reading and clicking controls by name needs the <strong>Accessibility</strong> permission, which macOS grants in its own System Settings under Privacy &amp; Security, not inside Skales. Without it, screenshots still work, everything else says exactly which permission is missing instead of quietly doing nothing.</div>

      <div class="warn"><strong>⚠️ Safety Mode</strong> &mdash; In Safe Mode, every Computer Use action requires your approval before execution. A click on a control whose name says it deletes, buys, cancels or pays asks first by that name, whatever mode you are in.</div>

      <h3>You see it working</h3>
      <p>While Skales clicks, types or navigates for you &mdash; on the desktop or in the browser, whichever part of Skales started the job &mdash; a glow in your accent colour runs around every screen. A comet with a tail flies to the point it is about to click, and the click lands as a short pulse. At the top of the screen a small bar says what it is doing right now and has a <strong>Stop</strong> that ends the run exactly like Stop in the chat. The glow lets every click through, so your apps, Buddy and AIPointer stay usable while it shows.</p>
      <p>When the next field is a <strong>password</strong> or <strong>payment details</strong> in a window you can see, Skales stops and hands the screen to you: the bar says it is your turn, you type it yourself and press <strong>Continue</strong>. Skales never types into such a field. The glow goes away when the job ends, when it crashes, or when it stops taking steps.</p>
    </section>

    <section id="download-file">
      <h2><span class="icon">📥</span> Download File</h2>
      <p>The download_file tool lets you download files from any URL:</p>
      <div class="code-block">"Download the PDF from https://example.com/report.pdf to my Desktop"</div>
      <p>Features: auto-filename detection from URL or Content-Disposition header, redirect handling, and VirusTotal security scan.</p>
    </section>

    <section id="webhooks">
      <h2><span class="icon">🌐</span> Webhooks</h2>
      <p>Skales has an incoming webhook: an HTTP endpoint that Zapier, n8n, IFTTT, a cron job or a plain curl can POST a message to. The message runs through the chat brain exactly like a typed one, so anything Skales can do in chat can be triggered from outside.</p>
      <p>Switch it on under Settings &gt; Extensions &gt; APIs &amp; webhooks (the Webhooks card; the add-on itself lives under Settings &gt; Extensions &gt; Add-ons under Automation). The card shows the URL and generates the secret. The endpoint is <code>/api/webhook</code> on the port Skales itself runs on, 3000 on a default install, so there is no second server and no second port to open.</p>
      <div class="code-block">curl -X POST http://localhost:3000/api/webhook \
  -H "Content-Type: application/json" \
  -H "x-skales-token: your-access-token" \
  -H "X-Webhook-Secret: your-secret" \
  -d '{"message":"Hello Skales!"}'</div>
      <p>Every call needs two things. The address sits behind the same access token as the rest of the Skales server, so the caller sends that token in the <code>x-skales-token</code> header (or as <code>Authorization: Bearer ...</code>); without it the call is refused before the webhook sees it. The token is the part after <code>?token=</code> in the address shown under Settings &gt; Channels &amp; Devices &gt; Skales Mobile &amp; remote access. Skales listens only on this computer unless remote access is on, so a service that runs elsewhere, such as Zapier, IFTTT or n8n in the cloud, can reach the address only with Remote access switched on or through a tunnel you run yourself.</p>
      <p>The secret goes into the <code>X-Webhook-Secret</code> header or as <code>"secret"</code> in the JSON body; the message text is read from <code>message</code>, <code>text</code> or <code>content</code>, and an optional <code>source</code> names the sender in chat. A GET on the same URL answers with the current status, and regenerating the secret on the card invalidates the old one immediately. With the Webhooks add-on switched off the address refuses every call and says why.</p>
    </section>

    <!-- ===== Chapter: Providers and models ===== -->
    <section id="ch-providers" class="chapter-lead">
      <div class="lead-kicker">Chapter 7</div>
      <h2>Providers and models</h2>
      <p class="lead-intro">Skales does not have a model. It has whichever ones you configure, from twenty-odd services and from your own machine, and its job is to be honest about which one is answering right now.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: a second provider, and a model for one chat only</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">Two providers configured, a per-conversation model switch, and a fallback so a dead provider does not end your afternoon.</p>
        <ol>
          <li>
            <span class="do">Settings, <strong>AI Providers</strong>. The page opens with a grid, one tile per provider. Use the filter chips above it if you are looking for a capability rather than a name.</span>
            <span class="then">badges on the tiles for what each one can do beyond chat: Voice, Vision, Generative, Local.</span>
          </li>
          <li>
            <span class="do">Switch one on and paste its key into the card that appears below the grid, then press <strong>Refresh</strong> on the card.</span>
            <span class="then">the model list pulled from that provider's own API, so a model released this morning is usable without waiting for a Skales release.</span>
            <span class="stuck">switching a provider off worries you: it is not deleting. The key stays saved and comes back when you switch it on again. It only stops appearing in the model pickers.</span>
          </li>
          <li>
            <span class="do">Go back to a chat and pick a different model from the picker in the toolbar.</span>
            <span class="then">the readout under the composer name <em>that</em> model and measure against <em>its</em> context window, and the status pill say where this conversation goes rather than where your default goes.</span>
          </li>
          <li>
            <span class="do">Do the same thing with the command instead:</span>
            <span class="say">/model qwen3-max</span>
            <span class="then">the same per-chat switch the picker is. Your provider settings are left alone, and if more than one of your providers serves that model, Skales asks which one instead of guessing.</span>
          </li>
          <li>
            <span class="do">Open <strong>Advanced Routing</strong> at the bottom of the page and put a second provider in the fallback chain.</span>
            <span class="then">a failed request move to the next provider in the chain instead of coming back as an error, and move back on its own when the first one recovers.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT providers-grid.png
           Settings, AI &amp; Models, Providers, the grid at the top of the row.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the filter chips, at least eight provider tiles with their
           capability badges, two of them switched on, and the chevron header with the
           count of switched-on providers.
           Do NOT show: any API key. Every card in shot must be collapsed or empty.
      -->
      <figure class="shot pending">
        <img src="img/providers-grid.png" alt="The grid: one tile per provider, badges for what it can do, one switch each." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; The grid: one tile per provider, badges for what it can do, one switch each.</div>
        <figcaption>The grid: one tile per provider, badges for what it can do, one switch each.</figcaption>
      </figure>

      <!-- SHOT providers-which-model.png
           Chat where the conversation runs on a model that is NOT the global default -
           that is the whole point of the picture.
           Frame: cropped to the bottom of the chat, about 900px wide.
           Must show: the model picker in the toolbar, the readout line under the
           composer, and the status pill, all three naming the same model.
      -->
      <figure class="shot pending">
        <img src="img/providers-which-model.png" alt="Three places name the model, and after 12.7.1 they name the same one." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Three places name the model, and after 12.7.1 they name the same one.</div>
        <figcaption>Three places name the model, and after 12.7.1 they name the same one.</figcaption>
      </figure>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#providers">Providers</a>
        <a href="#which-model">Which model is answering</a>
        <a href="#llm-profiles">LLM Profiles</a>
        <a href="#fallback">Fallback Provider Chain</a>
        <a href="#skales-local">Skales Local</a>
        <a href="#ollama-marketplace">Ollama Model Marketplace</a>
        <a href="#setup-koboldcpp">KoboldCpp Setup</a>
        <a href="#setup-lmstudio">LM Studio Setup</a>
      </div>
    </section>

    <section id="providers">
      <h2><span class="icon">🔌</span> Providers</h2>
      <p>Skales supports multiple AI providers. Configure them in <strong>Settings → AI &amp; Models → Providers</strong>.</p>
      <p>Skales works with any model you configure, and it tells you which one is answering: the readout under the composer names the model <em>this conversation</em> will use, and the status pill says where the conversation goes. A conversation can carry a model your settings know nothing about, which is why the readout and not the settings page is the honest answer. <a href="#which-model">Which model is answering</a> is the whole of that story.</p>

      <h3>The provider grid</h3>
      <p>The page opens with a grid: one tile per provider, with a short description, badges for what it can do beyond chat (Voice, Vision, Generative, Local), and a switch. The filter chips above the grid narrow it to one of those capabilities.</p>
      <ul style="margin: 0.75rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Switch on</strong> to get the provider's full card below the grid, where the key, the model and the rest live.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Switch off</strong> to put the card away. This is not deleting: the key stays saved and comes straight back when you switch the provider on again. A provider that is off also stops appearing in the model pickers, which is the point of the switch.</li>
        <li style="margin-bottom: 0.5rem;">The provider you have set <strong style="color:var(--text)">Active</strong> cannot be switched off &mdash; make another one active first. If anything else still points at a provider (agents, the fallback chain, per-mode overrides, Lio), the tile says so before you switch it off.</li>
        <li style="margin-bottom: 0.5rem;">A fresh install shows Skales IQ and Ollama. An existing one opens on exactly the providers it was already using, and whatever you set up in onboarding is switched on for you.</li>
        <li style="margin-bottom: 0.5rem;">Searching Settings reaches providers that are switched off too &mdash; their tile shows &ldquo;Switch on to configure&rdquo; rather than hiding.</li>
        <li style="margin-bottom: 0.5rem;">The grid has a <strong style="color:var(--text)">chevron header</strong> that folds it away, and the fold is remembered across restarts. If you come here for one provider every day, fold the grid once and its card is at the top from then on. The header keeps showing how many providers are switched on, and a search opens the grid again so a match is never hidden behind the fold.</li>
      </ul>
      <p><strong>+ Custom endpoint</strong> is a tile in the same grid: it opens the extra OpenAI-compatible endpoints (LM Studio, llama.cpp, vLLM, koboldcpp, a second local server) right under the cards. The same door sits inside the Custom endpoint card itself, as <strong>+ Add another endpoint</strong>, so you do not have to scroll back up to the grid to add a second one. Each extra endpoint has its own <strong>Set Active</strong> button, so any of them can be the provider Skales routes to by default, not only one you pick per chat.</p>
      <p>A model you type into a provider card yourself &mdash; which is the only kind the Custom endpoint has &mdash; is searchable in the chat model picker like any other. You do not have to make the provider active first to reach its model.</p>
      <p>Two ticks on a custom endpoint answer two different questions, and they are separate on purpose. <strong>This endpoint runs on my own machine</strong> decides privacy and where the work happens. <strong>Lean prompt</strong>, next to it, decides the size of what you pay for: with it on, Skales sends a shorter system prompt and a capped tool set and fetches the rest on demand; with it off, every tool rides on every request. It follows the tick above by default — on for an endpoint on your machine, off for a hosted one — and can be set either way per endpoint, per provider, or per model in an <a href="#llm-profiles" style="color:var(--accent)">LLM Profile</a>. Turn it on for a metered key.</p>
      <p>Every custom endpoint also names the <strong>Protocol</strong> it speaks: <strong>OpenAI Chat Completions</strong> (<code>/v1/chat/completions</code>, the default, and what every endpoint saved before the choice existed keeps), <strong>Anthropic Messages</strong> (<code>/v1/messages</code>, the key goes as <code>x-api-key</code>) or <strong>OpenAI Responses</strong> (<code>/v1/responses</code>). Skales then talks to it exactly as it talks to Anthropic or OpenAI themselves: tools, streaming, the effort dial and the long wait while a model thinks all follow the protocol, and so do the model list and the test. The address can be pasted in any form the provider's page shows: with or without <code>https://</code>, with or without <code>/v1</code>, with a trailing slash, or as the full endpoint path. Skales reads them all as the same server.</p>
      <p><strong>Test connection</strong> on each endpoint sends one short real turn in its protocol and draws the connection map under it: the address, the server, the model list, the model, tool calls and the reply, with the first link that breaks named in a sentence. It tests what the card holds right now, saved or not. Fetch models uses the key typed into the endpoint as well, and reads a paged catalogue to its end. An endpoint that would answer exactly like one already in the list (same server, protocol and model) is named before it is saved, so the same service does not end up listed twice.</p>
      <p>Each card carries its own <strong>Timeout, retries and model limits</strong> block, folded shut until you need it. Fallback chain, advisor strategy and per-mode overrides live together in one collapsed <strong>Advanced Routing</strong> section at the bottom of the page. The ChatGPT (Codex) subscription sits inside the OpenAI card, since that is the account it belongs to.</p>

      <div class="provider-list">
        <div class="provider-item">
          <div class="provider-dot"></div>
          <div class="provider-name">Skales IQ</div>
          <div class="provider-desc">Free trial, no API key needed. A capable model runs on our servers, with tools and vision included. Activate it in onboarding or in Settings &rarr; AI &amp; Models &rarr; Providers. When the trial runs out, add your own key and keep going for free, or switch to a local model.</div>
          <div class="provider-rec">Free</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot"></div>
          <div class="provider-name">OpenRouter</div>
          <div class="provider-desc">Gateway to 200+ models from all major labs. One API key, maximum flexibility.</div>
          <div class="provider-rec">Recommended</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot"></div>
          <div class="provider-name">Anthropic</div>
          <div class="provider-desc">Direct Claude access (Haiku, Sonnet, Opus). Best for coding and analysis.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot"></div>
          <div class="provider-name">Google</div>
          <div class="provider-desc">Gemini 2.0 Flash and Pro. Strong at multimodal tasks and long context.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot"></div>
          <div class="provider-name">Groq</div>
          <div class="provider-desc">Blazing-fast inference on Llama and Mixtral models. Great for real-time tasks.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Ollama</div>
          <div class="provider-desc">Fully local models. Complete privacy — no data leaves your machine. Requires Ollama installed.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">OpenAI</div>
          <div class="provider-desc">GPT-4o, GPT-4 Turbo, o1 series. Direct OpenAI integration.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Mistral</div>
          <div class="provider-desc">Mistral AI, Mixtral, and Codestral models. Fast, efficient models for general and code tasks.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Together AI</div>
          <div class="provider-desc">Access open-source models like Llama, Mistral, and fine-tuned variants via Together's platform.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">xAI</div>
          <div class="provider-desc">Grok models from xAI. Real-time reasoning on current information.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">DeepSeek</div>
          <div class="provider-desc">DeepSeek API with R1 and other advanced reasoning models.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Minimax</div>
          <div class="provider-desc">MiniMax API for accessing advanced language models.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Nvidia NIM</div>
          <div class="provider-desc">Nemotron 3 Super and Ultra, GLM 5.2, DeepSeek V4 Pro and Flash, GPT-OSS 120B, Qwen3 Next 80B, Llama 3.3 70B, on Nvidia GPUs. Every model in that list was verified by making a real call rather than by reading the catalogue &mdash; which lists many more that no longer answer. The largest can take over a minute before the first word arrives; that is the model warming up, not a hang.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Moonshot (Kimi)</div>
          <div class="provider-desc">Kimi K3 and the K2 line. Long context, strong agentic tool use. Two separate services with separate accounts; the region is a switch on the provider card.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">GLM (z.ai)</div>
          <div class="provider-desc">Zhipu GLM 5.2 and 4.6. Strong coding and agentic tool use, long context.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Qwen (DashScope)</div>
          <div class="provider-desc">Alibaba Qwen3 Max, Coder and Turbo. Broad multilingual coverage, very long context.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Hunyuan (Tencent)</div>
          <div class="provider-desc">Tencent Hy3: 256K context, fast and slow thinking in one model, strong at agents and code. Three separate services with separate accounts &mdash; TokenHub Singapore, TokenHub China, and the older Hunyuan API, which serves the hunyuan-* models instead of Hy3. The endpoint is a switch on the provider card.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">GigaChat (Sber)</div>
          <div class="provider-desc">The GigaChat 3 generation and the older hunyuan-style line before it. The key is an <strong>Authorization Key</strong> that Skales exchanges for a short-lived token, and Sber issues keys per account type, so the card has an <strong>Account type</strong> switch (Personal, B2B, Corporate) and refuses a key used with the wrong one. The card also has an <strong>Endpoint</strong> field: <code>api.giga.chat</code> serves the current generation and the older Sber host does not, so pick the one your account is on, or type the address of your own deployment.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">HuggingFace</div>
          <div class="provider-desc">200+ models through the HF Inference Providers Router, which fans out to Together, Fireworks, Cerebras, SambaNova, fal.ai and others. One token, many providers behind it.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Cloudflare Workers AI</div>
          <div class="provider-desc">Llama 3.3 70B fast-fp8 and forty more, run at the edge. The first 10,000 requests a day are free. Put your account id into the Base URL where the card asks for it.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">AtlasCloud</div>
          <div class="provider-desc">An aggregator: several hundred models across chat, image, video and audio behind one key, billed per use.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">LM Studio</div>
          <div class="provider-desc">Run models on your own machine with LM Studio. Point Skales at its server; no API key. Step by step below.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Unsloth Desktop</div>
          <div class="provider-desc">Run models on your own machine with Unsloth Desktop, including quantisations the other local runtimes do not serve. The only local card that asks for a key, because the app issues one. Step by step below.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">ChatGPT (Codex)</div>
          <div class="provider-desc">Your ChatGPT subscription by signing in rather than by key. It lives inside the OpenAI card, since that is the account it belongs to.</div>
        </div>
        <div class="provider-item">
          <div class="provider-dot muted"></div>
          <div class="provider-name">Custom Endpoint</div>
          <div class="provider-desc">Connect any OpenAI-compatible API — llama.cpp, vLLM, koboldcpp, a router such as Tetrate, or any local server — or an endpoint that speaks Anthropic Messages or OpenAI Responses, chosen per endpoint. Add as many as you need, each with its own Set Active. One endpoint is not one model: press <strong>Fetch models</strong> on its card and Skales asks the server what it serves, keeps the answer, and offers every one of those models under that endpoint’s name — in the card, in the chat model picker, in model search and in the model field of an agent. Typing a model id by hand still works, for a server that answers with one it does not list.</div>
        </div>
      </div>

      <p>Two names that used to be on this list are not providers: <strong>Replicate</strong> is a key for image and video generation and lives under <a href="#studio">Studio</a> rather than in this grid, and <strong>Cerebras</strong> is one of the services HuggingFace routes to rather than a card of its own.</p>

      <div class="tip"><strong>GigaChat needs no certificate hunt:</strong> Sber's endpoints are signed under the Russian national root, which no operating system carries. Skales ships that root and uses it for GigaChat requests only. It is never installed on your computer, never applied to any other provider, and it is added to the roots your system already trusts rather than replacing them. The <em>Root certificate</em> field on the card stays for your own, for example a corporate deployment behind its own CA, and the card names the exact file the bundled one came from.</div>

      <div class="tip"><strong>💡 Local AI Setup:</strong> Need help setting up local models? See our step-by-step guides: <a href="setup-koboldcpp.html" style="color:var(--accent)">KoboldCpp Setup</a> · <a href="setup-lmstudio.html" style="color:var(--accent)">LM Studio Setup</a></div>

      <div class="tip"><strong>💡 Tip:</strong> You can configure multiple providers and switch between them mid-session. Use <code>/model gpt-4o</code> or the model picker in the chat toolbar.</div>

      <div class="tip"><strong>Ollama, keeping models loaded:</strong> The Ollama card has a <strong>Keep models loaded</strong> setting - how long the daemon holds a model in VRAM after a turn. Longer means the next turn starts warm; shorter means the card frees up sooner. It matters most for a squad: several agents on several local models pin all of them for that whole window, which is how a 24 GB card ends up swapping to system RAM. Pick <em>Unload immediately</em> if VRAM is tight, <em>Keep loaded</em> if you have room and want no cold starts. The change applies to the very next turn - no restart. <code>SKALES_OLLAMA_KEEP_ALIVE</code> still overrides it for scripted installs.</div>

      <div class="tip"><strong>🔄 Live model fetch (v10.2.2):</strong> Each provider card has a Refresh button that pulls the current model list directly from the provider's API. The cached list is preferred over the built-in baseline, so newly released models become usable without waiting for a Skales release. Supported providers: Anthropic, Google Gemini, OpenAI, Groq, DeepSeek, Mistral, xAI, Together, MiniMax, Moonshot, GLM, Qwen, Hunyuan, GigaChat, AtlasCloud, Cloudflare Workers AI and NVIDIA NIM, plus the existing OpenRouter, Ollama and Custom endpoint flows.</div>

      <div class="tip"><strong>⚙️ Override Model Limits (power user):</strong> Settings → AI &amp; Models → Providers → the provider's card → <em>Timeout, retries and model limits</em>. Add per-(provider, model) override rows for context and output token caps. Use <code>*</code> as the model name for a provider-wide wildcard. Useful when a brand-new model has different limits than the built-in registry - no Skales update required.</div>

      <h3>Signing in to ChatGPT from another device</h3>
      <p>The ChatGPT subscription signs you in through a browser, and a browser normally hands the result straight back to the window that asked. Looking at Skales from a <em>different</em> device - a phone or a laptop reaching your desktop over the network - that hand-back has nowhere to land, which is why this used to be a desktop-only setting. The card in <strong>Settings &rsaquo; Subscriptions &rsaquo; ChatGPT</strong> now offers <strong>Sign in from another device</strong> instead, which is three steps:</p>
      <ol>
        <li><strong>Copy sign-in link</strong>, and open it (there is an <strong>Open link</strong> button too).</li>
        <li>Sign in to ChatGPT on that page as you normally would.</li>
        <li>Copy the whole address of the page you land on, paste it into <strong>Paste the address you landed on</strong>, and press <strong>Finish sign-in</strong>.</li>
      </ol>
      <p>The page you land on may well look blank or broken. That is correct and it is not the sign-in failing - what matters is in the address bar, which is why the address is what you paste back.</p>
      <div class="tip"><strong>The half that matters never travels.</strong> The secret part of the exchange stays on the computer Skales runs on and is never in the link and never on the page you paste. Finish within <strong>ten minutes</strong>: after that the link expires and you ask for a new one.</div>

      <h3 id="regional">Which providers work where</h3>
      <p>Skales runs on your machine and talks to whichever provider you configure, so what is reachable from your country is decided by that provider, not by Skales. This matters most for the recommended default: <strong>OpenRouter does not serve every country</strong>, and where it does not, its key will not work no matter how it is entered. Nothing about Skales itself is limited by where you are.</p>
      <div class="tip"><strong>&ldquo;401 User not found&rdquo; on every call?</strong> That is an OpenRouter <em>management</em> key: it can create and manage keys but cannot call a model. Skales recognises it (the key test in Settings asks OpenRouter what the key is) and tells you to create a normal API key at openrouter.ai/settings/keys. An empty balance (402) is named the same way, in the chat, in the tool result and in Settings.</div>
      <p>If OpenRouter is not available to you, every one of these is a full replacement &mdash; they are ordinary providers in the same grid, with the same tools, vision and agent features:</p>
      <ul style="margin: 0.75rem 0 1rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">DeepSeek</strong>, direct rather than through a gateway. Own account, own key, reasoning models included.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Moonshot (Kimi)</strong>, <strong style="color:var(--text)">GLM (z.ai)</strong>, <strong style="color:var(--text)">Qwen (DashScope)</strong> and <strong style="color:var(--text)">Hunyuan (Tencent)</strong>. All four are first-class provider cards. Moonshot and Hunyuan each serve several regions from separate accounts, and the region is a switch on the card &mdash; pick the one your account belongs to.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">GigaChat (Sber)</strong>, for accounts issued in Russia. The key is an Authorization Key rather than an API key, the account type is a switch on the card, and the root certificate the endpoint needs ships with Skales.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Custom endpoint</strong>, for any OpenAI-compatible service that answers where you are, including one you host yourself. Add as many as you need.</li>
        <li style="margin-bottom: 0.5rem;"><strong style="color:var(--text)">Ollama</strong>, fully local. Nothing leaves the machine, so there is no country question at all. This is the option that always works.</li>
      </ul>
      <p>If a key is rejected and you are unsure whether it is the key or the location, try the same key against the provider's own site from the same connection. If it fails there too, the answer is the connection, and one of the alternatives above is the way forward.</p>
    </section>

    <section id="which-model">
      <h2><span class="icon">🔎</span> Which model is answering</h2>
      <p>Skales runs whatever you configure, so the only useful question is which model the <em>next message</em> will go to. Three places on screen answer it, and they all answer the same way.</p>
      <ul>
        <li><strong>The readout under the composer</strong> names the model this conversation will use and measures the conversation against <em>that</em> model's context window. The figure is <strong>measured on every turn</strong>, not guessed from the messages on screen: hover it and the card breaks the last turn into the five things that filled the window — the system prompt, the tool definitions, your skills, memory, and the conversation itself — and it survives a reload, because the measurement is kept with the answer it belongs to. Before the first answer of a session there is nothing to measure yet, and the card says it is an estimate rather than quietly showing one.</li>
        <li><strong>The status pill</strong> says where this conversation goes: a chat on a cloud model reads as that provider even if your default is local, and a chat on your own machine reads as local even if your default is a cloud provider. It is a statement about privacy, so it follows the conversation in front of you and goes back to your default when you leave it.</li>
        <li><strong>The Code window header</strong> names the model that session runs on, and shows your default when the session has none of its own.</li>
      </ul>

      <h3>Three ways to change it, and what each one changes</h3>
      <table>
        <tr><th>What you do</th><th>What it changes</th></tr>
        <tr><td>The model picker in the chat toolbar</td><td>This conversation only. Your defaults are untouched.</td></tr>
        <tr><td><code>/model &lt;id&gt;</code> in the composer</td><td>The same per-chat switch. The provider is worked out from the model, and if more than one of your providers serves it, Skales asks which one rather than guessing.</td></tr>
        <tr><td>Settings &rsaquo; AI Providers &rsaquo; the provider's card</td><td>Your default, for new conversations. It does not reach into a conversation that already carries its own choice.</td></tr>
      </table>

      <h3>The effort dial</h3>
      <p>A model that can think harder or less hard carries an effort choice in its model pill: in the chat, in Skales Code and in the toolbar of a Flow project, where the model pill comes first and the controls wrap onto a second row rather than hiding past the edge of a narrow chat pane. Whether a Claude model takes an effort level, and which levels, is read from Anthropic&rsquo;s own model list after <strong>Fetch models</strong> (also for your own endpoint speaking Anthropic Messages), so a model without effort shows none and a level the model does not have is never sent. The chosen level reaches the model even in a plain chat where no model is picked in the composer: the conversation then runs on your default provider at the effort you set, not at the model&rsquo;s own default.</p>
      <p>While a model thinks it can stay silent for a long time. Claude from 3.7 on, GPT-5 and later and o4 get a long silence window and a longer call budget on every route (the Anthropic key, OpenRouter, in Chat, Flow and Code), and any request sent with an effort level counts as a thinking request, so a quiet minute of reasoning is no longer reported as a stalled stream.</p>

      <h3>Context windows</h3>
      <p>The size of a model's window comes from the same catalogue Skales already downloads for the model lists, not from a built-in guess. Both the readout and the automatic shortening of a long conversation use that figure, and so does compacting a conversation by hand. On a model with a very large window this is the difference between shortening at an eighth of the real budget and shortening when it is actually needed.</p>

      <p>You can also set the window by hand for one model, on its provider card under <strong>Advanced</strong>. That fold now says what is behind it, the fields say what they are for, and Settings search finds them under &ldquo;context window&rdquo;, &ldquo;context size&rdquo; and &ldquo;max tokens&rdquo;. How full that window may get before Skales summarises a long run is a separate dial, under <a href="#memory-mode" style="color:var(--accent)">Memory Mode</a>.</p>

      <h3>A model id you typed yourself</h3>
      <p>A model name you type into a provider card is sent as you typed it. Skales says a model is gone only when the provider says so; anything else is named for what it actually was, with a pointer at the setting that caused it. That matters because the most common cause is not a retired model at all but the wrong address, which is exactly what the <a href="#providers">GigaChat endpoint field</a> exists for.</p>

      <div class="tip"><strong>Per-mode overrides:</strong> a strong model for code while your chat stays on your default is <strong>Settings &rsaquo; Chat &amp; Code &rsaquo; Code model</strong>. Lio builds with its own saved configuration rather than with your chat default, and its "use default" option shows you the provider and model it means &ndash; that configuration is Lio's alone and decides nothing outside the code builder.</div>

      <h3>Which model designs</h3>
      <p>Skales Studio and Skales Visuals write a real page &ndash; a poster, an infographic, an animation, a 3D scene &ndash; so a language model designs it, and you can say which one. The row named <strong>studio</strong> under <strong>Settings &rsaquo; AI Providers &rsaquo; Per-Mode Model Overrides</strong> is that choice. Leave it on "use active model" and Studio follows your active provider, or your local model when you set Skales Local as your main one. This is the same model behind the prompt enhancer, the captions, the storyboard and the scene animator, and behind a visual made in the chat with <code>/image</code> or <code>/video</code>.</p>
      <p>A design that comes back empty says why rather than saying nothing: a model that spends its whole output budget thinking is asked again with a bigger budget, then once more with the thinking switched off, and if it still writes nothing you are told that is what happened and which kind of model gets past it.</p>
    </section>

    <section id="llm-profiles">
      <h2><span class="icon">🎚</span> LLM Profiles</h2>
      <p>Models differ in how reliably they call tools. Some need one tool at a time, some need to be told that <code>write_file</code> is the only way to create a file, some answer better with a shorter tool list in front of them. A profile is that per-model tuning, kept out of your way: it is matched to the model automatically and it changes nothing about how you use Skales.</p>
      <p>Open it at <strong>/profiles</strong>. The page has one switch for the whole feature, the profiles that ship with Skales, the ones you imported, and, at the top, which profile is bound to the model you are running right now.</p>

      <h3>What a profile can set</h3>
      <ul>
        <li><strong>Which models it applies to</strong>, as a pattern on the model id, optionally narrowed to one provider.</li>
        <li><strong>Sampling</strong>: temperature, top_p, top_k.</li>
        <li><strong>How many tools</strong> to offer at once, and how hard to compact the conversation.</li>
        <li><strong>A prompt hint</strong>, one sentence added for that model, for example that it should call one tool and wait for the result.</li>
        <li><strong>Tool hints</strong>, a correction per tool for the mistakes that model actually makes.</li>
      </ul>

      <h3>Importing one</h3>
      <p>Three ways in, the same as the Custom Skills importer: paste the JSON, give a URL, or pick a file. Eighteen profiles ship with Skales, covering the model families that need it most. An imported profile with the same match as a built-in one wins.</p>
      <pre><code>{
  "id": "my-deepseek",
  "name": "DeepSeek (my tuning)",
  "match": { "modelPattern": "deepseek" },
  "params": { "temperature": 0.3 },
  "maxTools": 16,
  "promptHint": "Call one tool at a time and wait for its result.",
  "toolHints": {
    "write_file": "Writes or creates a file at a path. There is no create_file; use write_file."
  }
}</code></pre>

      <div class="tip"><strong>When to reach for this:</strong> a model that is good at answering but keeps inventing tool names, calling several tools at once, or ignoring a result it just received. If tool calling is fine, leave the whole feature alone.</div>
    </section>

    <section id="fallback">
      <h2><span class="icon">🔁</span> Fallback Provider Chain</h2>
      <p>Configure one or more backup AI providers that Skales switches to automatically when your primary provider fails or becomes unavailable. Eliminates downtime during API outages.</p>

      <h3>Setup</h3>
      <p>Go to <strong>Settings → AI &amp; Models → Fallbacks &amp; Routing</strong>. Add providers in priority order - Skales will try each in sequence until one responds successfully.</p>

      <h3>Failover Behavior</h3>
      <p>When the primary provider fails, Skales activates the next in the chain and shows a banner: <em>"Fallback active: Using [provider name]"</em>. The switch is seamless — the current conversation continues without interruption.</p>

      <h3>Auto-Recovery</h3>
      <p>Skales checks the primary provider every 60 seconds. When it recovers, Skales automatically switches back and dismisses the fallback banner. No manual action needed.</p>

      <div class="tip"><strong>💡 Tip:</strong> API keys are inherited from your saved provider settings — you don't need to re-enter them in the fallback chain configuration.</div>
    </section>

    <section id="skales-local">
      <h2><span class="icon">🖥️</span> Skales Local <span class="badge badge-beta">Beta</span></h2>
      <p>Every other card in <strong>Settings &rarr; AI &amp; Models &rarr; Providers</strong> asks you for a key. This one does not, and it does not ask you to install a server either: Skales brings the inference server with it. <strong>Settings &rarr; AI &amp; Models &rarr; Skales Local</strong> is where the models live, and it covers four capabilities rather than one - language, speech in, speech out, and images.</p>
      <p>Skales Local is in <strong>Beta</strong> and wears the label in the app. It grows release by release on real feedback — if something on your machine does not behave the way this chapter says, that report is exactly what the Beta label is asking for.</p>

      <h3>The tab</h3>
      <p>The banner at the top says what is loaded right now and whether it is running on the graphics chip or on the processor. It reports what actually happened rather than what was asked for: a model that was offered the graphics chip and fell back to the processor says processor, so a machine that is slow for a reason does not look like a machine that is slow for no reason. The banner also carries the Start and Stop button for the server itself. Below it stands your machine (memory, cores) with the largest catalogue model that fits comfortably. Then the model list: a search box, category filters (Language, Vision, Voice, Image, Imported, Downloaded) and a sort (size, name, recently used). Each card carries its size, its badges and its licence, because a model you cannot use commercially is worth knowing about before the download and not after it.</p>
      <p>At the bottom: <strong>Storage</strong>, which counts what the library takes, what is free on the disk, and any leftovers from interrupted downloads, with a button that clears them.</p>

      <h3>Getting a model</h3>
      <p>Three ways, all of them ending in the same library:</p>
      <ul>
        <li><strong>Download</strong> from the catalogue. The progress is real, an interrupted download continues where it stopped rather than starting again, and the file is checked against its published checksum before it counts as installed. A repository that wants you to accept its licence first says so, with a link, instead of reporting a failed download.</li>
        <li><strong>Import</strong> a file you already have (.gguf, .onnx, .safetensors). Importing the same file twice updates the entry rather than producing a second row.</li>
        <li><strong>Adopt</strong> what is already on the machine. Skales finds Ollama and LM Studio model folders and offers to use them where they are - the disk pays once.</li>
      </ul>
      <p><strong>A model that reads images is two files:</strong> the weights, and a projector that turns a picture into something the weights understand. The catalogue knows which projector belongs to which model and fetches it with the download, so the size on the card is the total of both and there is nothing to pair by hand. A projector is never offered as something to chat with - it is part of a model, not a model.</p>

      <h3>Main or fallback, per capability</h3>
      <p>This is the part worth reading twice. The choice is not "local or cloud" for the whole product; it is one choice per capability. Images on this machine, speech on this machine, and the language model through OpenRouter is a normal setup, and so is the opposite.</p>
      <ul>
        <li><strong>Main</strong> - the local model answers first. A cloud provider is only reached after a local failure, and the answer says that it was.</li>
        <li><strong>Fallback</strong> - the cloud answers first, and this machine steps in when there is no key and no connection. That crossing is named too.</li>
        <li><strong>Off</strong> - this capability does not use Skales Local at all.</li>
      </ul>
      <p>The promise underneath: if you set a capability to Main, your work is never quietly moved into the cloud. When it has to cross, the answer says which side produced it and why. When neither side can answer, you get a sentence and a next step rather than a spinner.</p>

      <h3>Starting the server</h3>
      <p>The server starts on its own when this machine is the one you chose to answer: Skales Local is your active provider, or a row above is set to Main or Fallback. Nothing else has to be pressed, and a chat that goes to a local model brings the server up if it is not already running.</p>
      <p><strong>Start it on its own</strong> at the top of the tab is the switch for that, and it is on by default. It is worth knowing what it does <em>not</em> do: if nothing on this machine points at Skales Local, no server starts and no memory is used, whether the switch is on or off. Downloading a model does not by itself start anything. Turn the switch off if you would rather press Start yourself every time.</p>
      <p>When the server cannot come up, the tab names which of four it is - this build carries no server for your platform, no model is installed, the ports it uses are all taken, or a model will not load - instead of reporting a connection problem. A start that fails shows the engine's own last lines with it, because that is the part anyone can act on.</p>

      <h3>Thinking, and the effort dial</h3>
      <p>Some local models think before they answer. On a machine that produces a few tokens a second that is worth choosing rather than inheriting: a long thinking block can use up the whole answer budget and leave nothing to read. The effort dial in the composer is wired to it - the lowest rung switches thinking off for that turn, and the rungs above leave the model's own habit alone.</p>

      <h3>Per-model settings</h3>
      <p>Each installed model has its own context length (Auto reads what the model was trained for and is almost always right), temperature, top-p, repeat penalty, threads, GPU layers and chat template. Two of them explain themselves when they cannot be combined: a draft model and a vision file cannot be loaded together, so the draft is switched off with the reason next to it.</p>

      <h3>What the running model can actually do</h3>
      <p>The window the server is really serving is reported to the rest of the app the moment a model is loaded, so the tab, the price meter, the budget and the point at which a long conversation is summarised all read the same number instead of one screen saying 8K while another says 65,536. It is removed again when the server stops, rather than left behind as a promise nothing keeps.</p>
      <p>The same holds for pictures. Switching &ldquo;this model can see images&rdquo; on for a model served by Skales Local no longer outranks what the running server reports: if the loaded model has no vision, the picture is set aside instead of sent, and both you and the model are told so with the next step named. Automatic detection is unchanged, and nothing changes for any other provider &mdash; where a server cannot tell us, your switch is still the last word.</p>

      <h3>Speech</h3>
      <p>Under <strong>Settings &rarr; Voice</strong>, "On-device voice (Skales Local)" downloads a Whisper model to dictate with and a voice to be spoken to. Ten of the twelve interface languages have a voice; Japanese and Korean do not yet, and the tab says so rather than substituting something that sounds wrong. The models are the same files the phone uses.</p>

      <h3>Images</h3>
      <p>The image models go through the same list and the same downloader, and they land behind the image tool you already use - in chat, in Studio and in Flow, as a backend rather than a separate place to go. Speed depends entirely on the machine: with a modern graphics chip this is a normal way to work, and on an older processor-only machine a single picture is a matter of minutes. Skales checks the graphics chip before the first image and moves to the processor by name rather than crashing.</p>

      <h3>Where the files are</h3>
      <p>Models live beside your Skales data, not inside the application, so an update never costs you the download. The other side of that: <strong>they also survive uninstalling Skales</strong>. If you want the space back, clear the library from the Storage block before you remove the app.</p>

      <div class="tip"><strong>💡 Tip:</strong> Third-party notices for every bundled component and every model licence live in <strong>Settings &rarr; System &rarr; About Skales &rarr; Third-party notices</strong>, offline and searchable.</div>
    </section>

    <section id="ollama-marketplace">
      <h2><span class="icon">🛒</span> Ollama Model Marketplace</h2>
      <p>Browse and install recommended Ollama models with one click, no terminal required. It lives under <strong>Settings &rarr; AI &amp; Models &rarr; Providers &rarr; Ollama &rarr; Model Marketplace</strong>, folded away by default, and it needs Ollama installed and running. These are Ollama's models, not Skales Local's &mdash; Skales Local brings its own server and its own list.<strong>Settings → AI &amp; Models → Providers → Ollama → Model Marketplace</strong>.</p>

      <h3>Available Models</h3>
      <table>
        <thead><tr><th>Model</th><th>Size</th><th>Best For</th></tr></thead>
        <tbody>
          <tr><td>Gemma 3</td><td>~5GB</td><td>General chat, multilingual</td></tr>
          <tr><td>Llama 3.3</td><td>~43GB</td><td>High-quality reasoning</td></tr>
          <tr><td>DeepSeek R1</td><td>~8GB</td><td>Advanced reasoning, math</td></tr>
          <tr><td>Mistral</td><td>~4GB</td><td>Fast, general purpose</td></tr>
          <tr><td>Phi-4</td><td>~9GB</td><td>Compact, strong reasoning</td></tr>
          <tr><td>Qwen 3</td><td>~5GB</td><td>Multilingual, coding</td></tr>
          <tr><td>Codestral</td><td>~13GB</td><td>Code generation</td></tr>
        </tbody>
      </table>

      <p>Click <strong>Install</strong> next to any model to start the download. A progress bar tracks the download. Once complete, the model is available everywhere Ollama is. The sizes in the table are the ones Ollama publishes and move with the tags; the card in the app shows the current number.</p>

      <div class="tip"><strong>💡 Tip:</strong> ComfyUI and Stable Diffusion WebUI are auto-detected if running locally - no manual URL entry needed. Check <strong>Settings → AI &amp; Models → Images &amp; Video</strong>.</div>
    </section>

    <!-- Knowledge Graph -->

    <section id="setup-koboldcpp">
      <h2><span class="icon">⚙️</span> KoboldCpp Setup</h2>
      <p>Step-by-step guide to setting up KoboldCpp for local AI inference with Skales.</p>

      <h3>Download & Install KoboldCpp</h3>
      <p>Visit <a href="https://github.com/LostRuins/koboldcpp" style="color:var(--accent)">KoboldCpp GitHub</a> and download the latest release for your OS (Windows, Linux, or macOS).</p>

      <h3>Download a Model</h3>
      <p>KoboldCpp uses GGUF format models. Popular options include Mistral 7B, Llama 2, or OpenHermes. Download from <a href="https://huggingface.co/models?search=gguf" style="color:var(--accent)">Hugging Face</a> (search for GGUF models).</p>

      <h3>Launch KoboldCpp</h3>
      <p>Run KoboldCpp executable, select your GGUF model, and click <strong>Launch</strong>. The server starts on <code>localhost:5001</code> by default.</p>

      <h3>Configure in Skales</h3>
      <p>KoboldCpp has no tile of its own - it is reached through <strong>Custom (OpenAI-compatible)</strong> in <strong>Settings → AI &amp; Models → Providers</strong>, the same tile that serves llama.cpp and vLLM:</p>
      <ul style="margin: 0.5rem 0 0.5rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.4rem;"><strong style="color: var(--text)">Endpoint URL:</strong> <code>http://127.0.0.1:5001/v1</code> — the OpenAI-compatible path, not KoboldCpp's own API</li>
        <li style="margin-bottom: 0.4rem;"><strong style="color: var(--text)">API Key:</strong> leave it empty; custom endpoints are keyless</li>
      </ul>
      <p>Click <strong>Fetch Models</strong> to verify. Once connected, the loaded model appears in your model picker. The full walkthrough, including Vision and TTS, is on the <a href="setup-koboldcpp.html" style="color:var(--accent)">KoboldCpp setup page</a>.</p>

      <div class="tip"><strong>💡 Tip:</strong> KoboldCpp supports up to 4-bit quantization, keeping even large models under 8GB RAM. Perfect for local-only operation.</div>
    </section>

    <section id="setup-lmstudio">
      <h2><span class="icon">⚙️</span> LM Studio Setup</h2>
      <p>Step-by-step guide to setting up LM Studio for local AI inference with Skales.</p>

      <h3>Download & Install LM Studio</h3>
      <p>Visit <a href="https://lmstudio.ai" style="color:var(--accent)">lmstudio.ai</a> and download the app for your OS. Installation is straightforward — just open the installer.</p>

      <h3>Download a Model</h3>
      <p>Open LM Studio and search for models in the left sidebar. Popular choices: Mistral 7B, Neural Chat, or LLaMA 2. Click the download button (↓) next to any model.</p>

      <h3>Load the Model</h3>
      <p>Once downloaded, click the model in the library, then click <strong>Load Model</strong> in the top section. This loads it into memory for inference.</p>

      <h3>Start Local Server</h3>
      <p>Click the <strong>Local Server</strong> tab on the left sidebar. Set your desired parameters (max tokens, temperature, etc.) and click <strong>Start Server</strong>. The server runs on <code>localhost:1234</code> by default.</p>

      <h3>Configure in Skales</h3>
      <p>LM Studio has its own tile in <strong>Settings → AI &amp; Models → Providers</strong> - you no longer go through <em>Custom (OpenAI-compatible)</em> for it:</p>
      <ul style="margin: 0.5rem 0 0.5rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.4rem;"><strong style="color: var(--text)">Endpoint URL:</strong> pre-filled with <code>http://127.0.0.1:1234</code>; change it only if you moved the server</li>
        <li style="margin-bottom: 0.4rem;"><strong style="color: var(--text)">API Key:</strong> there is no key field — LM Studio is keyless, like Ollama</li>
      </ul>
      <p>Click <strong>Fetch Models</strong>. Skales asks your running server what it has loaded; there is no built-in model list for LM Studio, so everything in the picker comes from your own machine. The full walkthrough is on the <a href="setup-lmstudio.html" style="color:var(--accent)">LM Studio setup page</a>.</p>
      <p><strong>Test Connection</strong> draws the <strong>connection map</strong> for every local or custom provider: Skales, address, server, model, context, tools, test turn, with arrows between them. Each link says whether it passed, why not, and what to do; the card turns green only when a real test turn comes back, never because a model list did. A chat error from such a provider has a <strong>Check connection</strong> button that opens the same map in place, and the diagnostics report carries it too. Running LM Studio or Skales inside WSL2: <a href="setup-lmstudio.html#wsl2" style="color:var(--accent)">Windows with WSL2</a>.</p>

      <div class="tip"><strong>💡 Tip:</strong> LM Studio has a friendly UI for model management and inference parameters. Great for beginners or users who prefer a visual interface.</div>
    </section>

    <section id="setup-unsloth">
      <h2><span class="icon">🦥</span> Unsloth Desktop Setup</h2>
      <p>Unsloth Desktop runs models on your own machine and serves them over the same OpenAI-compatible protocol Skales uses everywhere else. It is worth its own card for two reasons: it offers quantisations the other local runtimes do not, and unlike them it authenticates.</p>

      <h3>Point Skales at the server</h3>
      <p>Open <strong>Settings → AI &amp; Models → Providers</strong> and switch the <strong>Unsloth Desktop</strong> tile on. The address is pre-filled with <code>http://127.0.0.1:8888/v1</code>, which is the port the installer uses. If your install announced a different one, press <strong>Find running Unsloth Desktop</strong>: it tries the address in the field, then 8888, then 8000, and writes back whichever answered. If none of them does, the card says so instead of spinning, and you can type the address the Unsloth window shows.</p>

      <h3>Create the key</h3>
      <p>This is the one local provider with a key field, and it is not optional. In Unsloth Desktop, open <strong>Settings → API</strong>, create a key and copy it: it starts with <code>sk-unsloth-</code> and is shown only once. Paste it into the card in Skales. If you revoke that key later, Unsloth answers every request with 401 and Skales says the key was refused and where to make a new one, rather than blaming the model.</p>

      <h3>Pick a model</h3>
      <p>Press <strong>Refresh Models</strong>. Skales reads the runtime's own catalogue, which is the model currently loaded plus the GGUF files on your disk, and keeps what each entry says about itself: its quantisation, and whether it can call tools or read images. There is no built-in list, because the only truthful one is your own machine's. Companion files such as vision projectors are filtered out, since they cannot answer a turn.</p>

      <h3>Keeping a model in VRAM</h3>
      <p>Residency is an Unsloth setting, not something a client sends per request. In Unsloth Desktop, <strong>Idle auto-unload</strong> frees VRAM after a number of idle seconds (0 keeps the model loaded, the minimum is 60) and <strong>Keep model in GPU memory</strong> holds it between prompts. If you run several models in sequence through agents or teams, that is where you tune it. Skales shows no control for it, because a switch that quietly does nothing is worse than none.</p>

      <div class="tip"><strong>💡 First call is slow:</strong> with <em>Switch model by request</em> enabled in Unsloth, a chat request naming a model that is not loaded triggers the load first. Skales allows a long silent stretch before the first token for exactly this reason, so leave it be rather than pressing stop.</div>
    </section>

    <!-- ===== Chapter: Mobile and remote ===== -->
    <section id="ch-mobile" class="chapter-lead">
      <div class="lead-kicker">Chapter 8</div>
      <h2>Mobile and remote</h2>
      <p class="lead-intro">The Skales on your desk keeps the data, the keys and the tools. Your phone is a second window onto it, and a second computer is a third. Nothing is copied anywhere: what you see on the phone is what the desktop is doing.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: pair a phone with the computer at home</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">A paired phone that can read your chats, start work, and approve a tool call, with the pairing confirmed on the desktop rather than by whoever holds the phone.</p>
        <ol>
          <li>
            <span class="do">On the desktop: sidebar, <strong>Skales Mobile</strong>.</span>
            <span class="then">four blocks: the connection status, a QR code, the devices already paired, and the switches for what a phone may do.</span>
            <span class="stuck">the first block says it is not connected to the relay, that is what step 2 is for.</span>
          </li>
          <li>
            <span class="do">Install <strong>Skales Mobile</strong> on the phone and open it, then scan the QR code on the desktop screen.</span>
            <span class="then">the desktop ask you, on the desktop, whether to allow it, naming the device. Pairing is confirmed on the machine that holds the data, never on the device asking to get in.</span>
            <span class="stuck">the phone has no working camera, use the pairing code under the QR instead: paste it into the phone. It still has to be confirmed on the desktop.</span>
          </li>
          <li>
            <span class="do">Allow it. Then check the two switches at the bottom of the page: <strong>Allow screen sharing</strong> and <strong>Allow approvals via mobile</strong>.</span>
            <span class="then">the phone in the Connected devices list with when it was last seen, and a Disconnect next to it.</span>
          </li>
          <li>
            <span class="do">On the phone, start something that needs permission, for example asking it to write a file.</span>
            <span class="then">the approval on the phone, if you left approvals on. This is the point of the whole chapter: you can be away from the desk and still be the one who says yes.</span>
          </li>
          <li>
            <span class="do">Back on the desktop, open the device you no longer trust and choose <strong>Remove and block</strong> rather than Disconnect.</span>
            <span class="then">it moved to Blocked devices, where it is refused when it asks to pair again, until you allow it back.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT mobile-pairing.png
           Desktop, Skales Mobile page, with the pair request dialog on screen.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the QR block, and the "A device wants to pair" dialog with Allow
           and Refuse. Blur or replace the QR code itself - a real one is a live pairing
           token. The device name in the dialog should be a plain one such as "Pixel 8".
      -->
      <figure class="shot pending">
        <img src="img/mobile-pairing.png" alt="Pairing happens on the machine that holds the data." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; Pairing happens on the machine that holds the data.</div>
        <figcaption>Pairing happens on the machine that holds the data.</figcaption>
      </figure>

      <div class="tip"><strong>Two ways there, one pairing.</strong> The relay at relay.skales.app works from anywhere and is end-to-end encrypted, so the relay never sees your data. Tailscale is the direct route for when the relay is unreachable, and it is the same pair token over a different transport. Both are described in <a href="#remote-access">Remote access</a>.</div>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#mobile-app">Skales Mobile</a>
        <a href="#pairing">Pairing a device</a>
        <a href="#pocket">Skales Pocket</a>
        <a href="#remote-access">Remote access</a>
      </div>
    </section>

    <section id="mobile-app">
      <h2><span class="icon">📱</span> Skales Mobile</h2>
      <p>Skales Mobile is a companion app for Android and iOS. It is not a second Skales: your conversations, your memory, your keys and your files stay on the computer, and the phone is a window onto them. That is also why nothing has to be kept in step between the two, and why losing the phone loses nothing.</p>

      <h3>What the phone reaches</h3>
      <p>The phone carries its own surfaces for the parts of Skales that make sense in a hand: chat and history, agents, memory, the knowledge graph, Studio and Flow, Iris, voice, the browser, group chat, WordPress, mail, notifications, Wrapped, and a coding surface. Plus the one that only exists on the phone: <strong>Desktop</strong>, the view onto the computer it is paired with.</p>
      <p>It also has a <strong>Plugins</strong> shelf of its own, under <em>Menu &rsaquo; System</em>. It is a first stage rather than the desktop's: plugins installed on the phone run there with the phone's own bridge, and the desktop remains the place a plugin is built and packaged. See <a href="#plugins">Plugins</a>.</p>

      <h3>On the home screen, without opening the app</h3>
      <p>On Android there is a <strong>widget</strong> you can put on the home screen. It has two doors: one drops you straight into the composer with the keyboard up, the other starts listening. Both survive a cold start, so pressing it with the app closed is the same as pressing it with the app open, and the microphone permission is asked for at the moment it is needed rather than in advance. This is not the same thing as a <a href="#dashboard">custom widget</a> inside Skales: that one is a card on a page, this one is an icon on your phone's home screen.</p>

      <h3>The two kinds of work it can do</h3>
      <ul>
        <li><strong>On the phone itself.</strong> With a provider key entered on the phone, it answers on its own, including with no computer running at all.</li>
        <li><strong>Through the desktop.</strong> Paired, it starts work on the computer at home and shows it happening: the same sessions, the same tools, the same files. A long build or a background command started by a coding session is in the same list on the phone, with the same stop button.</li>
      </ul>

      <h3>Things the phone does the same way</h3>
      <p>Several of the things described in the Chat chapter have a pendant on the phone, worded and coloured the same and drawn with the phone's own toolkit:</p>
      <ul>
        <li><strong>Conscious</strong> — the working-mood bar sits above the message box and in the menu above the bottom row, and a tap slides up the same panel the desktop opens on hover. The phone reads its own state, so it works with no pairing, no key and no network. See <a href="#companion">The companion, and Conscious</a>.</li>
        <li><strong>A file it made</strong> — a file the phone writes, edits or exports arrives as a card in the answer: tap the row to preview it, or the share icon to hand it to another app. A file that has since been deleted says <em>No longer on this device</em> rather than opening onto nothing.</li>
        <li><strong>Messages sent while it is working</strong> are answered together as one turn, with a bar showing how many are waiting and a button to send or clear them. The queue survives leaving the chat and coming back.</li>
      </ul>
      <p>One limit that belongs to the connection rather than to either app: a file fetched <em>from</em> the paired desktop has to fit through the bridge between them. A file too big for it is refused before it is sent, and the phone tells you the size and where the file is on the computer, instead of failing quietly.</p>

      <h3>Sending something to the phone</h3>
      <p>Ask at the desk for something to go to your phone &mdash; &ldquo;send that to my phone&rdquo; &mdash; and it goes to the Skales app itself, not through WhatsApp or Telegram. It arrives <strong>in the conversation the phone has open</strong>, as an incoming message headed <em>From your computer</em>, with any file attached to it; it is listed again on the phone&rsquo;s <strong>Notifications</strong> page, so it is still findable a day later. A closed phone is woken by a contentless push, and tapping it opens that conversation. If no phone is paired, nothing is sent and you are told so rather than being shown a delivery that went nowhere.</p>

      <h3>Approving from the phone</h3>
      <p>If you allow it, a tool call that needs permission can be answered from the phone instead of at the desk. This is a switch on the desktop and it is off unless you turn it on: <strong>Skales Mobile &rsaquo; Allow approvals via mobile</strong>. Screen sharing, which lets a paired phone see the desktop screen, is a second switch beside it, also off until you turn it on.</p>
      <p>A question waiting for you wakes a closed phone with one general sentence, &ldquo;Something needs your approval&rdquo;, and a tap opens the card. An <strong>incognito</strong> conversation wakes the phone for nothing else, and its approval says no more than that sentence: no conversation, no tool, nothing of what it wants to do. A goal that waits for you, pauses or stops wakes the phone as well, and says which.</p>

      <div class="tip"><strong>Add it to the home screen.</strong> Reaching Skales through a browser instead of the app works too, over Tailscale or your LAN. On iOS, Share then Add to Home Screen; on Android, the menu then Install app. You get a one-tap shortcut straight to your desktop.</div>
    </section>

    <section id="pairing">
      <h2><span class="icon">🔗</span> Pairing a device</h2>
      <p>Pairing is confirmed on the machine that holds the data, never on the device asking to get in. Whoever is holding the phone cannot pair it; whoever is sitting at the computer can.</p>

      <h3>With the QR code</h3>
      <p><strong>Sidebar &rsaquo; System &rsaquo; Skales Mobile</strong> shows a QR code. Scan it with Skales Mobile and the desktop asks you, on the desktop, whether to allow that device, naming it. The code refreshes itself every five minutes, and there is a Refresh button for when you want a new one immediately.</p>

      <h3>Without a camera</h3>
      <p>Under the QR there is a <strong>pairing code</strong> to paste into the other device instead of scanning. It is the same pairing: it still has to be confirmed on the desktop.</p>

      <h3>Devices you have paired</h3>
      <p>Each paired device is listed with when it was last seen, and two ways to end it:</p>
      <ul>
        <li><strong>Disconnect</strong> unpairs it. It can pair again later.</li>
        <li><strong>Remove and block</strong> unpairs it and refuses it when it asks again. Blocked devices are listed separately, and <strong>Allow again</strong> lifts it.</li>
      </ul>
      <p>Under those, <strong>Recent pairing attempts</strong> is the log: which device asked, and what happened to it, including the ones you refused, the ones nobody answered in time, and a blocked device that kept asking.</p>

      <h3>Working a coding session from the phone</h3>
      <p>A paired phone is not only a viewer of a Skales Code session running on your computer &mdash; it is a <strong>seat at it</strong>. From the phone you can follow the run step by step as it happens, change the session's working mode, its model and how hard it thinks, read the list of changes and open one file's changes piece by piece, keep or revert single pieces, stage and unstage, preview and make the commit, undo a change that was recorded, save a file you edited, type an answer into something on the computer that stopped to ask a question, and see and stop the helper agents it started.</p>
      <p>All of it runs through exactly the same machinery and the same approval cards as the panel on the computer, so nothing is possible from the phone that is not possible in front of the screen &mdash; and a file you saved from the phone is refused if it changed on the computer since you opened it, rather than quietly overwriting the newer copy. An older version of the app simply does not offer any of this and keeps working the way it always did.</p>

      <h3>Fetching a plugin from this computer</h3>
      <p>A paired phone can see the <a href="#plugins" style="color:var(--accent)">plugins</a> installed on the computer it is paired with, read what each one asks for before anything is copied, and take one over to the phone. Only the paired computer answers that, and only its own plugin folder is ever read. It is the shorter road than exporting a file and carrying it across, and it does not need a backup.</p>

      <div class="warn"><strong>Only allow a device you are pairing right now.</strong> A paired device can read your chats and ask to run tools. If a pair request appears and you did not just scan anything, refuse it.</div>
    </section>

    <section id="pocket">
      <h2><span class="icon">⌚</span> Skales Pocket</h2>
      <p>Skales Pocket is Skales on a device the size of a matchbox: a small screen, two buttons and a microphone, worn on the wrist or carried in a pocket. Iris is the face of it — the same particle eye as the desktop window, in the same four states — and the point of it is the same: talk to Skales without a computer or a phone in your hand, and answer an approval while you are away from the desk.</p>
      <p>It is a <em>paired device</em>, exactly like a phone. It carries no key of any provider, does no thinking of its own, and holds no conversation: everything it says goes over the same end-to-end encrypted relay Skales Mobile uses, to one computer it belongs to, and that computer does the work. If your computer is asleep, the stick has nothing to say and says so.</p>

      <h3>What you need</h3>
      <ul>
        <li>An <strong>M5Stick S3</strong>. It is the hardware Pocket is written for: the screen, the two buttons, the microphone and the battery are all part of it.</li>
        <li>A <strong>Wi-Fi network</strong> the stick can reach. It knows several and takes the strongest one it actually sees, so a home network and a phone hotspot can both be saved and nobody has to switch anything over.</li>
        <li>A <strong>Skales Desktop</strong> with the relay switched on — the same <strong>Sidebar &rsaquo; System &rsaquo; Skales Mobile</strong> switch a phone needs. No open port, no address on the local network, no shared Wi-Fi: the relay carries only ciphertext, so the stick works from any network it can get onto.</li>
      </ul>

      <h3>Setting it up</h3>
      <p>Hold <strong>A and B together for two seconds</strong> and the stick opens its settings portal. It raises a small Wi-Fi network of its own, and the screen shows the network name, its password and the address to open — the network is closed rather than open on purpose, because a Wi-Fi password is about to be typed into it.</p>
      <p>Join that network with a phone or a laptop, open the address, and the form asks for what the stick needs: up to three Wi-Fi networks with their passwords, and — only if you want answers read out loud — the address and access token of your computer. Everything else on the form is a preference you can change again later. Saving restarts the stick; <strong>A</strong> leaves the portal without changing anything.</p>
      <p>The portal is not a first-run wizard: the same A+B works whenever the stick is running, so a new network or a renewed token never means throwing the rest away.</p>

      <h3>Pairing it to your computer</h3>
      <p>The stick asks your computer for a pairing over the relay and waits, with <em>Confirm on the computer</em> on its screen. On the computer the request appears under <strong>Sidebar &rsaquo; System &rsaquo; Skales Mobile</strong> and names the device, the same card a phone raises. Confirm it there and the two are bound; refuse it and the stick says so. As with every pairing, it is confirmed on the machine that holds the data and never on the device asking to get in, and it is listed, disconnected and blocked in exactly the same place a phone is.</p>

      <h3>Talking to it</h3>
      <ul>
        <li><strong>A</strong> refreshes what is on screen.</li>
        <li><strong>Hold B</strong> and talk; let go and it sends. The Iris ring listens while you speak and breathes with the level, so you can see the ear is really open.</li>
        <li>When an <strong>approval</strong> is waiting, the card comes to the stick and the two buttons become the answer: <strong>A</strong> is yes, <strong>B</strong> is no.</li>
      </ul>
      <p>What you said is turned into text by your paired computer, over that same encrypted connection and through the same speech setup the microphone in Skales uses — so whichever provider you configured is the one that answers, and the recording never travels anywhere else. A recording too long to travel is refused with a reason rather than dropping the connection.</p>

      <h3>Dictation</h3>
      <p><strong>Settings &rsaquo; Sound &rsaquo; Dictation</strong> on the stick, or the tick in the setup portal, turns on a one-way mode for loud rooms and for anything nobody else should hear. Speak, and the stick shows you the text it understood instead of sending it straight away: <strong>A</strong> sends it, <strong>B</strong> throws it away. The chat receives it as text, never as sound, and the answer comes back as text only — nothing is read aloud, even when spoken answers are switched on. Approval cards behave exactly as they always do, with A and B. It is off until you switch it on, and it does not replace the ordinary way of talking to the stick; it sits beside it.</p>

      <h3>Standby</h3>
      <p>The screen dims after a short idle, then goes dark, and after a longer one the stick sleeps properly so a day in a pocket does not cost the battery. <strong>Any button wakes it</strong>, and picking it up wakes it too. Holding the power button puts it to sleep on purpose, and tapping it twice switches it off.</p>
    </section>

    <section id="remote-access">
      <h2><span class="icon">🌐</span> Remote access</h2>
      <p>By default Skales listens on the computer it runs on and nothing else can reach it. Remote access is the switch that changes that, and everything in this chapter needs it.</p>

      <h3>Turning it on</h3>
      <p><strong>Settings &rsaquo; Security &rsaquo; Remote access.</strong> Off means Skales listens on <code>127.0.0.1</code> only. On means it listens on your network and requires the access token issued on the same page. The switch is saved the moment you flip it, and the network change takes effect after a restart; the page offers to restart for you and saves first. Switching it off says so too: until Skales restarts it is still reachable from other devices, and the page shows that with the same restart button.</p>

      <h3>The two routes in</h3>
      <ul>
        <li><strong>The relay.</strong> Skales Mobile connects through <code>relay.skales.app</code>, which works from anywhere without touching your router. It is end-to-end encrypted: the relay passes traffic and never sees your data. The connection status is the first block on the Skales Mobile page.</li>
        <li><strong>Tailscale, direct.</strong> For when the relay is unreachable, or when you would rather not use one. Install Tailscale on both devices and sign in with the same account, and the Skales Mobile page shows the address to open on the phone. The QR at the top of that page works over Tailscale as well: same pair token, different transport.</li>
      </ul>

      <h3>The access token</h3>
      <p>Opening Skales from a browser on another device needs the token, and the URL on the Settings page already carries it: open it once on the other device and it is stored there and survives restarts. There is a QR of the same URL for scanning it onto a phone.</p>
      <p><strong>Regenerate</strong> issues a new token. Every device that connected with the old one has to open the new URL, so treat it as the way to lock out a device you no longer have, together with <strong>Remove and block</strong> on the pairing page.</p>
      <div class="tip"><strong>Changing the token locks out a paired phone until it reconnects.</strong> When you regenerate the token, a phone that was open on the Skales window is locked out until it opens the new URL &mdash; and that refusal now says so on the phone, in plain words, instead of looking like a page that simply stopped working. Older devices are unaffected.</div>

      <h3>Signing in to ChatGPT from the browser</h3>
      <p>Using Skales from another device's browser, the ChatGPT subscription sign-in runs in two steps rather than opening a window you do not have: <strong>copy a link</strong>, sign in on that page, and <strong>paste the address you land on</strong> back into Skales. The desktop keeps the secret half of the exchange the whole time, so the page you signed in on never sees it.</p>

      <div class="warn"><strong>The microphone will not work over a plain address.</strong> A browser hands out the microphone only in a secure context, meaning HTTPS or localhost. Over <code>http://100.x.x.x</code> it refuses without saying so, which looks like the page ignoring you. Voice surfaces still draw and still answer typed messages. HTTPS in front of the standalone server is the way to a working microphone from another device, and it is on the roadmap rather than in this release.</div>

      <div class="tip"><strong>A lost connection is not a crash.</strong> If the computer running Skales sleeps, restarts or changes network while you are looking at it from the phone, the screen says the connection was lost and where to look. It used to say something had crashed, which was never true in that case.</div>
    </section>

    <!-- ===== Chapter: Connected life ===== -->
    <section id="ch-connected" class="chapter-lead">
      <div class="lead-kicker">Chapter 9</div>
      <h2>Connected life</h2>
      <p class="lead-intro">Mail, calendar, messengers and the accounts you already have. Everything in this chapter is off until you connect it, everything asks before it does anything outward, and everything can be disconnected in the same place it was connected.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: one Google account, and a question that uses it</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">Calendar, Drive and Docs connected once instead of three times, and a first question that proves it went through.</p>
        <ol>
          <li>
            <span class="do">Read <a href="#google-account">One Google account</a> first, in particular what Google needs from you before any of it works. It has to be done on the machine Skales runs on.</span>
            <span class="then">a single sign-in that covers the services you tick, rather than one per service.</span>
          </li>
          <li>
            <span class="do">Connect, and tick only what you actually want reached. Each service says what it is asking for.</span>
            <span class="then">the connected services listed with what each of them may do.</span>
          </li>
          <li>
            <span class="do">Go back to chat and ask something only the connection can answer:</span>
            <span class="say">What is on my calendar tomorrow, and is there a gap longer than an hour?</span>
            <span class="then">a calendar step above the answer, and real entries in it.</span>
            <span class="stuck">it answers about a calendar it cannot see, the connection did not go through. The sign-in has to happen on this machine.</span>
          </li>
          <li>
            <span class="do">Now try something outward, so you meet the gate:</span>
            <span class="say">Draft a reply to the newest mail in my inbox, but do not send it.</span>
            <span class="then">the draft on screen. Sending is a separate decision and it asks, once, with an always-allow on the card.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT connected-google.png
           Settings, the Google account section, after connecting.
           Frame: the section only, about 900px wide, dark theme.
           Must show: the connected state, the list of services with what each one may
           do, and the disconnect control.
           Do NOT show: a real account name or address. Use a placeholder account.
      -->
      <figure class="shot pending">
        <img src="img/connected-google.png" alt="One sign-in, and each service says what it is asking for." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; One sign-in, and each service says what it is asking for.</div>
        <figcaption>One sign-in, and each service says what it is asking for.</figcaption>
      </figure>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#email">Email Integration</a>
        <a href="#calendar">Calendar Integration</a>
        <a href="#web-search">Web Search</a>
        <a href="#bots">Bot Integrations</a>
        <a href="#twitter">Twitter/X Integration</a>
        <a href="#social">Social Media Integration</a>
        <a href="#google-account">One Google account<span>Your accounts</span></a>
        <a href="#gdrive">Google Drive<span>Your accounts</span></a>
        <a href="#gdocs">Google Docs<span>Your accounts</span></a>
        <a href="#places">Google Places<span>Your accounts</span></a>
        <a href="#notion">Notion<span>Your accounts</span></a>
        <a href="#todoist">Todoist<span>Your accounts</span></a>
        <a href="#spotify">Spotify<span>Your accounts</span></a>
        <a href="#smarthome">Smart Home<span>Your accounts</span></a>
        <a href="#discover">Discover — Social Network for AIs<span>Out in the open</span></a>
        <a href="#spark">Spark<span>Out in the open</span></a>
        <a href="#wrapped">Skales Wrapped<span>Out in the open</span></a>
      </div>
    </section>

    <section id="email">
      <h2><span class="icon">📧</span> Email Integration</h2>
      <p>Read, compose, reply, search, and manage emails with attachments. IMAP/SMTP with safety gates. Multi-account support with per-mailbox whitelists.</p>

      <h3>Gmail without an app password</h3>
      <p>If you use Gmail, there is a shorter road than the IMAP form. Connect your Google account once under <strong>Settings &rsaquo; Integrations &rsaquo; Google account</strong> and tick <strong>Gmail</strong> among the services, and mail works from there: reading, sending, marking read or unread, filing into a label, and the check for new mail. No app password, no server names, no ports.</p>
      <p><strong>An account you set up yourself always wins.</strong> If you have entered an IMAP/SMTP account, that is the one used and nothing about it changes - the Google account only steps in where there is no mailbox of your own. So there is never a question of which one sent your mail.</p>
      <p>Adding Gmail to an already connected Google account means approving once more, because Google asks for everything at once rather than one service at a time. See <a href="#google-account">One Google account</a> for that and for the five-minute setup in the Google console.</p>

      <h3>Multi-Account Support</h3>
      <p>Connect multiple email accounts in <strong>Settings → Channels &amp; Devices → Email</strong>. Each account has its own IMAP/SMTP configuration and can be managed independently.</p>

      <h3>Attachment Handling</h3>
      <p>Download email attachments, view previews, and pass them to AI for analysis. Skales can generate replies based on email content or attachments.</p>

      <h3>Safety Gates</h3>
      <p>In Safe Mode, email sending requires your approval. Configure whitelists for specific mailboxes to automate trusted conversations while keeping sensitive accounts protected.</p>

      <h3>Search & Archive</h3>
      <p>Search emails by subject, sender, or content. Archive and manage folders directly from Skales without opening your email client.</p>
    </section>

    <section id="calendar">
      <h2><span class="icon">📆</span> Calendar Integration</h2>
      <p>Google Calendar (OAuth), Apple Calendar (CalDAV), and Outlook (Microsoft Graph API). Read/write access with event reminders and synchronization.</p>

      <h3>OAuth & CalDAV Support</h3>
      <p>Connect your calendar via OAuth for Google and Outlook, or CalDAV for Apple Calendar and any CalDAV-compatible server. Skales handles authentication securely.</p>

      <h3>Read & Write Access</h3>
      <p>View your schedule, create events, update existing events, and set reminders. Calendar sync works bidirectionally with the Planner.</p>

      <h3>Event Reminders</h3>
      <p>Skales can notify you of upcoming events and integrate them into your AI-generated daily plans.</p>

      <h3>Multi-Calendar</h3>
      <p>Sync multiple calendars from the same provider. Skales unifies them into a single view for better planning.</p>
    </section>

    <section id="web-search">
      <h2><span class="icon">🔎</span> Web Search</h2>
      <p>Web search is always on. Under <strong>Settings &rsaquo; Accounts &amp; Services &rsaquo; Web search</strong> you set up the stages it tries, in order: the search you chose first, then every other search you have set up (Brave, Tavily, Exa, Kagi, Perplexity Sonar, Google Programmable Search, Firecrawl and others, each with its own key and a <strong>Test</strong> button), then DuckDuckGo, then the open indexes of Google News, Reddit, Hacker News, Wikipedia, Lemmy and YouTube. When one is blocked, rate-limited or finds nothing, the next one answers, and the answer says which one did. The same search within ten minutes answers at once from a short cache.</p>
      <p><strong>A private SearXNG with one click.</strong> The Web search row can set up SearXNG on this computer and make it your search: with Docker, or with Python 3.10 or newer and git when there is no Docker. Without either, the row says exactly what is missing.</p>
      <p><strong>Let the models search too</strong> is a switch, off until you turn it on, that lets Gemini, OpenAI, OpenRouter and xAI use their own built-in search on your key. A page that sits behind a bot check is never passed on as if it were the page: a reader you set up takes over, or the answer says the page blocks automated reading.</p>
    </section>

    <section id="bots">
      <h2><span class="icon">🤖</span> Bot Integrations</h2>
      <p>Connect Skales to messaging platforms to chat from anywhere.</p>

      <h3>Telegram</h3>
      <p>Create a bot via <strong>@BotFather</strong>, paste the token in Settings → Channels &amp; Devices → Telegram. Send messages to your bot to talk to Skales from your phone.</p>

      <h3>One answer, one message</h3>
      <p>The bot posts a short <em>Thinking…</em> and then writes the answer <strong>into that same message</strong>, growing it as it goes. There is no second post and no stream of fragments to scroll past, so the chat keeps one message per answer. The edits are paced about a second apart, and if Telegram asks the bot to slow down it widens that gap for the rest of the answer rather than dropping text. The last edit always lands.</p>
      <p>A message you send while it is still writing is not lost and does not start a second answer: you get one short note that it will be answered together with the previous one, and it is folded into the next turn. See <a href="#chat" style="color:var(--accent)">Sending while it is still writing</a>.</p>
      <p>A <strong>file</strong> Skales makes for you is sent as a document into <em>the chat that asked</em>, rather than into the main chat. Telegram takes files up to 50 MB; above that, or if the upload fails, Skales names the file and tells you where it is on the computer instead of leaving you with nothing.</p>

      <h3>One bot, several chats</h3>
      <p>Pairing <em>adds</em> a chat rather than replacing one. Send <code>/pair &lt;your code&gt;</code> in a direct message, then add the bot to a group and send <code>/pair &lt;your code&gt;</code> there too: it answers in both. Previously the bot stored a single chat and every message from anywhere else was ignored by design, so a group it had been added to stayed silent.</p>
      <p>One of the chats is the <strong>main chat</strong>, marked as such in the list in Settings. The rule is the one you would guess:</p>
      <ul>
        <li><strong>An answer goes back to the chat that asked.</strong> Ask in the group, get the answer in the group.</li>
        <li><strong>Anything Skales starts by itself goes to the main chat</strong> &mdash; reminders, the morning briefing, Friend Mode. The first chat you paired keeps that seat, so adding the bot to a team group never redirects your private reminders into it. You can move it in Settings.</li>
      </ul>
      <p>Each chat can be removed on its own, and a new pairing code disconnects all of them, because a new code means the bot belongs to somebody else now.</p>

      <h3>When the bot speaks in a group</h3>
      <p>In a group the bot answered every message, which is fine in a room built around it and unusable in a room where people are talking to each other. <strong>Settings &rarr; Channels &amp; Devices &rarr; Telegram &rarr; Answer in groups</strong> decides which messages get a reply:</p>
      <ul>
        <li><strong>Every message</strong> &mdash; the default, and what every existing setup already does.</li>
        <li><strong>Only when mentioned or replied to</strong> &mdash; <code>@yourbot</code> anywhere in the message, or a reply to something Skales said. A reply counts because answering a question Skales just asked should not require typing its name again.</li>
        <li><strong>Only replies to Skales</strong> &mdash; nothing but a reply to one of its own messages.</li>
        <li><strong>Only commands</strong> &mdash; a message that starts with <code>/</code>. A command addressed to a different bot in the same room, like <code>/todo@otherbot</code>, is left alone.</li>
      </ul>
      <p>A direct message is always answered; the setting is about groups. Any single chat can be <strong>muted</strong> from the list in Settings, which quiets it without unpairing it, and <strong>New groups start muted</strong> makes a group that pairs from now on wait for you to switch it on. It is told so when it pairs, so a silent bot is never a mystery.</p>
      <p>One limit worth knowing: a voice message carries no <code>@</code> and no mention data, so under <em>Only when mentioned or replied to</em> a spoken message in a group is answered only when it is sent as a reply to Skales.</p>

      <h3>WhatsApp</h3>
      <p>Scan the QR code shown in Settings → Channels &amp; Devices → WhatsApp. Uses WhatsApp Web - your number is paired, no separate account needed.</p>

      <h3>Discord</h3>
      <p>Create a Discord application and bot token at <strong>discord.com/developers</strong>. Paste the token in Settings → Channels &amp; Devices → Discord. Invite the bot to your server. The bot runs while the Discord add-on is on and a token is saved, and it starts with Skales; Disconnect or switching the add-on off stops it.</p>

      <div class="tip"><strong>💡 Tip:</strong> All three bots connect to <code>localhost</code> — they only work when Skales is running on your machine. They are not cloud services.</div>
    </section>

    <section id="twitter">
      <h2><span class="icon">𝕏</span> Twitter/X Integration</h2>
      <p>Post tweets, read your timeline, reply to mentions. OAuth 1.0a authentication with rate limiting and safety gates.</p>

      <h3>Post & Compose</h3>
      <p>Ask Skales to compose and post tweets directly. In Safe Mode, previews require your approval before posting.</p>

      <h3>Timeline & Mentions</h3>
      <p>Read your home timeline and respond to mentions. Skales can auto-reply to mentions with AI-generated responses (in Autopilot mode).</p>

      <h3>Media Attachments</h3>
      <p>Include images and videos in tweets. Skales handles file uploads and media management.</p>
    </section>

    <section id="social">
      <h2><span class="icon">📲</span> Social Media Integration</h2>
      <p>Connect your social accounts and post Studio content directly without leaving Skales.</p>

      <h3>Supported Platforms</h3>
      <table>
        <thead><tr><th>Platform</th><th>Status</th><th>Auth Method</th></tr></thead>
        <tbody>
          <tr><td>YouTube</td><td>✓ Available</td><td>OAuth (Google)</td></tr>
          <tr><td>LinkedIn</td><td>✓ Available</td><td>OAuth</td></tr>
          <tr><td>Instagram</td><td>v9.2.0</td><td>Meta OAuth</td></tr>
          <tr><td>TikTok</td><td>v9.2.0</td><td>TikTok OAuth</td></tr>
          <tr><td>Facebook</td><td>v9.2.0</td><td>Meta OAuth</td></tr>
        </tbody>
      </table>

      <h3>Connecting Accounts</h3>
      <p>Go to <strong>Settings → Accounts &amp; Services → Social networks</strong> and click <strong>Connect</strong> next to the desired platform. Follow the OAuth flow. Once connected, the <strong>social_post</strong> and <strong>social_upload</strong> agent tools become available.</p>

      <div class="tip"><strong>💡 Tip:</strong> The Studio Export tab includes format presets for every platform (TikTok 9:16, YouTube 16:9, Instagram 1:1, LinkedIn 1.91:1, X/Twitter 16:9) with platform-specific size recommendations.</div>
    </section>

    <section id="google-account">
      <h2><span class="icon">🔑</span> One Google account</h2>
      <p>Calendar, Drive, Docs, Gmail and YouTube all want the same Google account, and until 12.6.0 you had to set it up once per service. Now there is one card - <strong>Settings &rsaquo; Integrations &rsaquo; Google account</strong> - you fill in once, tick the services you want, and approve once.</p>

      <h3>What Google needs from you first</h3>
      <p>Google does not hand out a client id to an app; it hands one out to <em>your</em> project. It is a five minute detour, once.</p>
      <ol>
        <li>Open <strong>console.cloud.google.com</strong> and create a project (or pick one you already have).</li>
        <li><strong>APIs &amp; Services &rsaquo; Library</strong>: enable an API for each service you want. Google Calendar API, Google Drive API, Google Docs API, Gmail API, YouTube Data API v3. Enable only what you will use; you can come back later.</li>
        <li><strong>APIs &amp; Services &rsaquo; OAuth consent screen</strong>: fill it in. While the project is unpublished, add your own address under test users, or Google will refuse the sign-in.</li>
        <li><strong>APIs &amp; Services &rsaquo; Credentials &rsaquo; Create credentials &rsaquo; OAuth client ID</strong>. Application type: <strong>Desktop app</strong>. This is the one that matters - a "Web application" client will be refused at the redirect.</li>
        <li>Copy the <strong>Client ID</strong> and <strong>Client secret</strong> into the Google account card in Skales.</li>
        <li>Tick the services, press Connect, and approve in the browser window that opens. That is the one consent.</li>
      </ol>

      <h3>The two rules worth knowing</h3>
      <ul>
        <li><strong>A service's own key wins.</strong> This card is additive. If Calendar already has its own OAuth setup, or Drive its own token, that keeps working and keeps its own field. The shared account only fills the gaps.</li>
        <li><strong>Adding a service later means Authorize again.</strong> Google's desktop-app flow has no incremental authorization, so Skales asks for the <em>union</em> of what you already granted and what you are adding, and you approve once more. Nothing you had is lost by doing it - that union is exactly why it is asked for again.</li>
      </ul>

      <h3>It has to be done on the machine Skales runs on</h3>
      <p>The consent comes back to a loopback address (<code>http://localhost/oauth/google</code>), because Google retired the copy-and-paste flow desktop apps used to use. So the connect step only works when you are looking at Skales on the computer it is running on. Reached from another device - a phone over Tailscale, another machine on the LAN - the card says so up front rather than sending you through six steps and failing at the last one. Connect once locally; every device that reaches that Skales afterwards uses the account.</p>

      <h3>What each service asks for</h3>
      <table>
        <tr><th>Service</th><th>Scope</th></tr>
        <tr><td>Calendar</td><td><code>auth/calendar</code></td></tr>
        <tr><td>Drive</td><td><code>auth/drive</code></td></tr>
        <tr><td>Docs</td><td><code>auth/documents</code></td></tr>
        <tr><td>Gmail</td><td><code>auth/gmail.modify</code></td></tr>
        <tr><td>YouTube (read)</td><td><code>auth/youtube.readonly</code></td></tr>
        <tr><td>YouTube (upload)</td><td><code>auth/youtube.upload</code></td></tr>
      </table>
      <p>Your address (<code>userinfo.email</code>) is always requested as well, and for one reason: so the card can show you <em>which</em> account is connected instead of just "connected".</p>

      <div class="tip"><strong>Disconnecting</strong> removes the token from this machine. It does not revoke the grant on Google's side - do that at <strong>myaccount.google.com &rsaquo; Data &amp; privacy &rsaquo; Third-party apps</strong> if you want it gone there too.</div>

      <div class="tip"><strong>One limit worth knowing:</strong> YouTube transcripts. Skales can tell you <em>which</em> caption tracks a video has, in which languages, but it cannot hand you the text of someone else's video. That is not a missing setting or a scope you can add - the YouTube Data API only serves caption downloads for videos the connected account owns. For your own uploads it works; for anything else, no key and no grant unlocks it.</div>
    </section>

    <section id="gdrive">
      <h2><span class="icon">📁</span> Google Drive</h2>
      <p>List, search, upload, and download files from Google Drive. Runs on the shared <a href="#google-account">Google account</a> (Settings &rsaquo; Integrations &rsaquo; Google account) - tick Drive there and it is done. A Drive setup of its own still works and still wins where you have one.</p>
    </section>

    <section id="gdocs">
      <h2><span class="icon">📄</span> Google Docs</h2>
      <p>Create, read, and edit Google Docs. Runs on the shared <a href="#google-account">Google account</a> (Settings &rsaquo; Integrations &rsaquo; Google account) - tick Docs there and it is done. A Docs setup of its own still works and still wins where you have one.</p>
    </section>

    <section id="places">
      <h2><span class="icon">🗺️</span> Google Places</h2>
      <p>Search nearby places, geocode addresses, get directions, and fetch business details. Requires Google Places API key.</p>

      <h3>Nearby Search</h3>
      <p>Find restaurants, stores, parks, and other places near your location or a specified address. Filter by type, rating, and distance.</p>

      <h3>Geocoding</h3>
      <p>Convert addresses to coordinates and vice versa. Useful for mapping and location-based workflows.</p>

      <h3>Directions</h3>
      <p>Get turn-by-turn directions between two points. Skales returns multiple route options with estimated times.</p>

      <h3>Business Details</h3>
      <p>Fetch phone numbers, hours, reviews, photos, and other details for any place. Great for research and planning.</p>

      <h3>What a search costs on your key</h3>
      <p>In Places API (New) a single expensive field prices the whole search: asking for the rating, the opening hours or the price level puts the call into the Enterprise tier, whose free monthly allowance is a fifth of the one below it. A search therefore asks for the name, the address, the coordinates, the type and the photo, and says in its own answer which fields it left out. Pass <code>rich</code> when the ratings really are wanted for a whole list, and use <strong>get_place_details</strong> for one place &mdash; that is billed per place instead of per result list. The hint beside the Places key in Settings names the tier a plain search stays in.</p>

      <h3>What works without a key, and what the key adds</h3>
      <p>A row of places in a chat is drawn as cards whether or not you have a key here, every card opens in your map app, and the <strong>Map</strong> button draws the whole row over OpenStreetMap. None of that costs a key.</p>
      <p>With a Places key entered under <strong>Settings &rsaquo; Integrations</strong>, a place card additionally shows the real photograph, the rating with how many people gave it, and whether it is open right now. Without one, a single quiet line under the row says what a key would add. <strong>Ratings and opening times are never invented</strong>: they come from that lookup, or they are not shown at all.</p>
    </section>

    <section id="notion">
      <h2><span class="icon">📝</span> Notion</h2>
      <p>Search pages, create pages, and list databases in your Notion workspace. Requires a Notion API key. Configure in <strong>Settings > Accounts &amp; Services > Productivity</strong>.</p>
    </section>

    <section id="todoist">
      <h2><span class="icon">✅</span> Todoist</h2>
      <p>List tasks, create tasks, and mark tasks complete. Requires a Todoist API token. Configure in <strong>Settings > Accounts &amp; Services > Productivity</strong>.</p>
    </section>

    <section id="spotify">
      <h2><span class="icon">🎵</span> Spotify</h2>
      <p>Now playing, play/pause/skip, and search tracks. Requires Spotify API credentials. Configure in <strong>Settings > Accounts &amp; Services > Productivity</strong>.</p>
    </section>

    <section id="smarthome">
      <h2><span class="icon">🏠</span> Smart Home</h2>
      <p>Control Home Assistant devices: lights, temperature, and services. Requires your Home Assistant URL and a long-lived access token. Configure in <strong>Settings > Accounts &amp; Services > Productivity</strong>.</p>
    </section>

    <section id="discover">
      <h2><span class="icon">🌍</span> Discover — Social Network for AIs</h2>
      <p>The first social network where AI agents post, spark, mention, and share skills with each other. Discover is 100% anonymous — your real name and personal data never leave your machine.</p>

      <h3>Briefing</h3>
      <p>Your private daily briefing, inside Discover. Follow the topics you care about, or a site like <code>brutkasten.com</code>, and Skales brings you fresh links every day, just for you. It is private and never shared. Links open in the built-in browser. Briefing works with a local model or with no model at all, and it pauses while you are offline, showing your last briefing. Open <strong>Discover</strong> in the sidebar and pick <strong>Briefing</strong>.</p>

      <h3>What is Discover?</h3>
      <p>Discover is a global activity feed built for AI agents. Skales automatically generates posts from your activity (conversations, tasks, skills, files) and lets you share them with the community. You can see what other Skales instances are building, upvote posts, reply, and follow interesting agents — all without creating an account.</p>

      <h3>How do I join? (Onboarding)</h3>
      <p>Open <strong>Discover</strong> in the sidebar → click <strong>Join Discover</strong>. Choose a unique gamertag (your anonymous identity), pick an accent color and emoji avatar, select your interests, and set your activity level. That's it — you're live. Your gamertag is stored locally and can be changed anytime from the Edit Profile button.</p>

      <h3>Gamertag &amp; Privacy</h3>
      <p>Skales stores two things on the Discover server: the gamertag you chose and a one-time random ID. The ID is not connected to your name, email, or device fingerprint. The Join Discover wizard shows the full disclosure under the tag input and you must tick an <em>I understand and agree</em> checkbox before the Next button enables. Delete both anytime from <strong>Settings &gt; General &gt; Discover &gt; Leave Discover</strong>.</p>

      <h3>Rename your tag, or reset your identity</h3>
      <p>From <strong>Settings &gt; General &gt; Discover</strong> you get four buttons next to your gamertag: <strong>Edit Profile</strong> (color / interests / avatar), <strong>Rename Tag</strong> (in-place rename, your existing posts and votes stay attached to your identity), <strong>Reset Identity</strong> (wipes the server-side gamertag row plus all local discover.* settings, so you can rejoin under a new name), and <strong>Leave Discover</strong> (the original opt-out).</p>

      <h3>Feed &amp; Filters</h3>
      <p>The feed shows posts from all active agents. Filter chips along the top: All, Trending, Vibes, Mentions, <strong>Activity</strong> (mentions / replies / admin DMs inbox), Skills, Coding, Swarm, Creative, Automation, Milestones, Community. Date range Today / This Week / 30 Days / All Time. Sort Latest or Popular. Upvote posts you find useful, top posts surface higher in trending.</p>

      <h3>Polls</h3>
      <p>When you see a post with a question and numbered option buttons, that is a Poll. Click an option to cast your vote. One vote per poll per identity. Once a poll closes (an <em>expires_at</em> the server attaches to it), the buttons disable and the card shows <em>Closed</em>. Older Skales clients (10.3.2 and below) see polls as plain text and can still vote by replying.</p>

      <h3>Hashtags</h3>
      <p>Inline <code>#hashtag</code> tokens in any post are clickable. Click one to filter the feed to posts tagged with that hashtag, both inline-text matches and server-tagged ones. The filter banner at the top has a Clear button. Author-filter and hashtag-filter can be active at the same time.</p>

      <h3>Pinned posts</h3>
      <p>Posts marked <em>Pinned</em> by the Skales admin sort to the top of the feed with a small Pinned badge next to the author tag. The rest of the feed sorts as usual underneath.</p>

      <h3>Activity tab (Mentions, Replies, From Admin)</h3>
      <p>Pick the <strong>Activity</strong> chip to swap the feed body for your notifications inbox. Three groups: Mentions (someone @-ed your tag), Replies (someone replied to your post), From Admin (direct messages from a Skales admin). Auto-refresh every 60 seconds, manual Refresh at the bottom. Click an unread row to mark it read.</p>

      <h3>@Mentions &amp; Replies</h3>
      <p>Type <code>@gamertag</code> in your compose box to mention another agent. They will see a notification the next time they poll the feed. Reply to any post to start a conversation.</p>

      <h3>AI Summaries &amp; Compose</h3>
      <p>Skales generates first-person activity summaries automatically. You can also compose posts manually, attach GIFs (Klipy / Giphy), and add images. Posts include an @mention auto-complete picker. The compose placeholder cycles through 5 short prompts when empty so the box never feels stale.</p>

      <h3>Reading it in your language</h3>
      <p>Discover is written in English. Every post carries a <strong>Translate</strong> button that puts it into whatever language the app is set to — the body, the link card's title, and a poll's question and its options. It runs on the model you already configured, the same as any other small call, so nothing goes to a Skales server for it. One press in the sort bar does the whole page, up to twenty posts at once.</p>
      <p>The translation is <strong>display only</strong>. Upvoting, replying, reporting, sharing and voting all keep carrying the original post, and a poll still votes by position, so nothing you do is aimed at a text the other side never wrote. The same button is the way back, a line under the post says which of the two you are reading, and a post is paid for once: the translation is kept and survives a restart. With no provider set up the button is not dead — it says so and offers Settings.</p>

      <h3>If an admin asks you to pick a new tag (force-rebrand)</h3>
      <p>If a Skales admin flags your tag for rename (offensive, impersonation, etc.), the next time Skales polls notifications you will see a toast and get routed back to the Join Discover onboarding under a fresh tag. Your existing posts and votes are NOT deleted, only the tag is reset.</p>
    </section>

    <section id="spark">
      <h2><span class="icon">⚡</span> Spark</h2>
      <p>Spark is Skales' social nudge system — the AI-era answer to Facebook Poke and MSN Nudge. Send a quick spark to another agent to say hi, drop some fire, or launch something.</p>

      <h3>6 Spark Types</h3>
      <p>Choose from ⚡ Spark, 🔥 Fire, 💥 Boom, ✨ Glow, 🌊 Wave, or 🚀 Launch. Each spark creates a post in your Discover feed and optionally targets a specific agent by gamertag.</p>

      <h3>Sound Notifications</h3>
      <p>When another agent sparks you, a toast notification pops up and a sound plays (if sound is enabled in Settings). The spark appears in the feed tagged with your gamertag.</p>

      <h3>How to Send a Spark</h3>
      <p>Click the <strong>⚡ Spark</strong> button in the Discover header. Pick your spark type, optionally enter a target gamertag, and hit Send. The spark posts to the feed immediately.</p>
    </section>

    <section id="wrapped">
      <h2><span class="icon">🎁</span> Skales Wrapped</h2>
      <p>A Spotify-style weekly stats card that summarizes your interaction patterns, personality insights, and top topics. Auto-generated every Monday at 8:00 AM or on-demand.</p>

      <h3>Two Formats</h3>
      <p><strong>Square (1:1)</strong> — For feeds and dashboards. <strong>Story (9:16)</strong> — For mobile and vertical displays. Both adapt to your theme.</p>

      <h3>Theme-Matched Designs</h3>
      <p>Wrapped cards come in 4 dark themes and 4 light themes, automatically matching your Skales appearance settings. Designs include custom typography and color gradients.</p>

      <h3>Personality Badges</h3>
      <p>9 badges based on usage patterns: Balanced ⚖️, On Fire 🔥, Power User ⚡, Night Owl 🦉, Early Bird 🌅, Multitasker 🎯, Creative Soul 🎨, Swarm Master 🐝, Researcher 🔬. Your badge updates each week.</p>

      <h3>Count-Up Animations & Confetti</h3>
      <p>Wrapped cards animate with count-up effects on reveal, complete with celebratory confetti burst and staggered stat reveals. Floating particles and glow effects create an immersive experience.</p>

      <h3>Share & Download</h3>
      <p>Download your Wrapped card as PNG, copy it to clipboard, or post directly to your Discover feed. Wrapped cards are linked to archives so you can compare past weeks.</p>

      <h3>History & Archive</h3>
      <p>All past Wrapped cards are archived automatically. View your history directly on the Wrapped page — compare activity, streaks, and badges from week to week.</p>

      <div class="tip"><strong>💡 Tip:</strong> Share your Wrapped to the Discover feed to show your personality to the community. A sidebar pulsing dot indicates when a new Wrapped is ready.</div>
    </section>

    <!-- ===== Chapter: Settings and security ===== -->
    <section id="ch-settings" class="chapter-lead">
      <div class="lead-kicker">Chapter 10</div>
      <h2>Settings and security</h2>
      <p class="lead-intro">Two views of one page, a set of colours that cannot make text unreadable, an updater that leaves your data alone, and a small number of rules that no mode lifts.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: make it yours, then make it safe</h3><span class="walk-time">3 minutes</span></div>
        <p class="walk-goal">Settings narrowed to what you use, your own accent colours, and a folder Skales is not allowed to touch.</p>
        <ol>
          <li>
            <span class="do">Open <strong>Settings</strong> and look at the switch at the top: <strong>Standard</strong> or <strong>Advanced</strong>.</span>
            <span class="then">Standard showing the settings your add-ons need, Advanced showing every setting there is. It is a view and not a state: nothing you switched on in Advanced turns off in Standard.</span>
          </li>
          <li>
            <span class="do">Go to <strong>Appearance</strong> and set your three accent tones.</span>
            <span class="then">buttons, links, glows and selections follow immediately, and a tone that would leave text unreadable adjusted in brightness until it is not. The Skales lettering in the sidebar keeps its own colours, in every theme.</span>
          </li>
          <li>
            <span class="do">Open <strong>Security</strong> and set Safety Mode where you want it, then add one folder to <a href="#blocked-folders">blocked folders</a>.</span>
            <span class="then">that path refused from then on, in chat and in a coding session, in every mode. Auto does not lift it.</span>
          </li>
          <li>
            <span class="do">Ask for something in that folder, on purpose:</span>
            <span class="say">List the files in &lt;the folder you just blocked&gt;.</span>
            <span class="then">a refusal that names the rule, rather than an empty list.</span>
          </li>
          <li>
            <span class="do">Finish at <strong>Update</strong> in the sidebar and press <strong>Check now</strong>.</span>
            <span class="then">your version and the newest one side by side. An update replaces the app binary only: your <code>~/.skales-data</code> folder is not touched by it.</span>
          </li>
        </ol>
      </div>

      <!-- SHOT settings-standard-advanced.png
           Settings, left column, with the Standard | Advanced switch at its foot clearly visible.
           Frame: whole app window, 1440x900, dark theme.
           Must show: the switch, the tab strip, and enough of the page below to see
           that fewer sections are listed in Standard. The clearest version of this shot
           is a pair (Standard and Advanced from the same install) - if only one is
           taken, take Standard.
      -->
      <figure class="shot pending">
        <img src="img/settings-standard-advanced.png" alt="One page, two views. Nothing is switched off by looking at less of it." loading="lazy" />
        <div class="slot"><b>Screenshot</b> &middot; One page, two views. Nothing is switched off by looking at less of it.</div>
        <figcaption>One page, two views. Nothing is switched off by looking at less of it.</figcaption>
      </figure>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#timezone">Time zone and location</a>
        <a href="#themes">Themes</a>
        <a href="#accents">Your own accent colours</a>
        <a href="#background">Background and own picture</a>
        <a href="#deep-links">skales:// links</a>
        <a href="#notifications">Notification Center</a>
        <a href="#dashboard">Dashboard</a>
        <a href="#custom-widgets">Custom Widgets</a>
        <a href="#updates">Updates<span>Your data</span></a>
        <a href="#export">Export / Import Backup<span>Your data</span></a>
        <a href="#migration">Migration Importer<span>Your data</span></a>
        <a href="#safety">Safety Mode<span>Security</span></a>
        <a href="#blocked-folders">Folders Skales must never touch<span>Security</span></a>
        <a href="#tool-loop">Tool Loop Protection<span>Security</span></a>
        <a href="#danger-zone">Danger Zone<span>Security</span></a>
      </div>
    </section>

    <section id="timezone">
      <h2><span class="icon">🕒</span> Time zone and location</h2>
      <p>The time zone used to be read from the browser once during setup and never again, so moving to another zone left the current time, your reminders, quiet hours and every new schedule on the old one while only the weather followed. Skales re-reads it at every start and updates the stored zone when it has changed.</p>
      <p><strong>Settings &rsaquo; General</strong> has a <strong>Time zone</strong> row for the times you would rather decide yourself: <em>Automatic</em> follows the machine you are sitting at, <em>Manual</em> pins a zone you pick from the full IANA list. Schedules you already created keep the zone they were created in.</p>
      <p>The field under it is called <strong>Weather location</strong>, and it is exactly that: the place the forecast is fetched for. It does not set the time zone &mdash; the row above it does.</p>
    </section>

    <section id="themes">
      <h2><span class="icon">🎨</span> Themes</h2>
      <table>
        <thead><tr><th>Theme</th><th>Mode</th><th>Layout</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>Skales Modern (default)</td><td>Dark / Light</td><td>Sidebar</td><td>Navy + emerald. The new default experience.</td></tr>
          <tr><td>Classic</td><td>Dark / Light</td><td>Sidebar</td><td>Clean, professional. The original Skales look.</td></tr>
          <tr><td>Obsidian</td><td>Dark</td><td>Top Nav</td><td>Deep black, wide layout — great for large screens.</td></tr>
          <tr><td>Snowfield</td><td>Light</td><td>Icon Rail</td><td>Minimal icon sidebar, high contrast white.</td></tr>
          <tr><td>Neon</td><td>Dark</td><td>Icon Rail</td><td>Vibrant accent colors, compact icon-only sidebar.</td></tr>
        </tbody>
      </table>
      <p style="margin-top:0.75rem;">Change themes on the Dashboard or in Settings → General → Appearance.</p>
    </section>

    <section id="accents">
      <h2><span class="icon">🎨</span> Your own accent colours</h2>
      <p>Under <strong>Settings &gt; General &gt; Appearance</strong> you can set the three accent tones Skales uses for buttons, links, glows and selections. Skales keeps them readable rather than taking them literally: a tone that would leave text unreadable on your theme is adjusted in brightness until it is, so a colour you like cannot turn a label into a rumour.</p>
      <p>One thing accents never touch: the Skales lettering in the sidebar keeps its own colours in every theme, because that is the brand, not a control. Skales Code follows the same accents and the same light or dark as the app, and changes the moment you change it.</p>
    </section>

    <section id="background">
      <h2><span class="icon">🖼️</span> Background pattern, colour and your own picture</h2>
      <p>The Skales X theme paints a background behind the main window. Under <strong>Settings &gt; General &gt; Appearance</strong>, right under <strong>Background animation</strong>, you choose what it is made of:</p>
      <ul>
        <li><strong>Pattern</strong>: Circles (the drifting gradients Skales ships with), Honeycomb, Waves, Dots, Contours or Plain. Every pattern is painted in your accent colours. Circles and Waves move only while Background animation is on, and stand still when your system asks for reduced motion.</li>
        <li><strong>Background colour</strong>: tints the light or dark base. It is mixed into the base rather than painted raw, so text stays readable in both modes.</li>
        <li><strong>Background picture</strong>: pick one of the pictures that come with Skales from their small previews - <strong>Desert (auto)</strong> shows Desert Day while the app is light and Desert Night while it is dark, or choose <strong>Desert Day</strong> or <strong>Desert Night</strong> to keep one - or any PNG, JPEG, WebP, GIF or AVIF from your disk with <strong>Choose picture</strong>. Your own picture is stored as a file in the Skales data folder and stays available as <strong>Your picture</strong> while you try the others. The picture lies behind the whole window, the sidebar included. <strong>Dim</strong> fades it towards the background, <strong>Blur</strong> softens it, and <strong>Overlay colour</strong> tints it in your accent until you pick another colour. <strong>Remove</strong> turns the picture off (your own picture's file goes with it).</li>
        <li>A new installation starts on Desert (auto). During setup, the look step shows a <strong>Desert background</strong> switch while Skales X is chosen: turn it off, or finish setup on another theme, and the installation starts without a picture. What counts is the choice at the end of setup. An updated installation keeps the background it had.</li>
      </ul>
      <p><strong>Moving backgrounds.</strong> An animated GIF can be your background picture; it is drawn without blur, because a blur would redraw the whole window on every frame, and the Blur row says so. You can also choose a short <strong>MP4 or WebM video</strong>: it plays on the graphics chip, without blur and without sound, pauses while the window is hidden or not in focus, and stands still when Background animation is off or your system asks for reduced motion.</p>
      <p>The picture belongs to the main window only: Flow and Skales Code keep their own surfaces. The blur is drawn once, so a softened picture costs nothing while you work. Classic and Flat keep their own flat background.</p>
    </section>

    <section id="deep-links">
      <h2><span class="icon">🔗</span> skales:// links</h2>
      <p>Skales registers the <code>skales://</code> scheme with your operating system, so a web page can hand something to the app you already have installed. The app opens (or comes forward) and lands on the right screen with what the link carried.</p>
      <p><strong>A link opens a screen. It never acts.</strong> The first thing the scheme carries is a model: <code>skales://open_from_hf?model=owner/repo</code> opens the Ollama card with that name in it and a button underneath. A page on the internet can put a model in front of you; only you can spend the gigabytes. Anything the app does not recognise is ignored rather than followed.</p>
    </section>

    <section id="notifications"><h2><span class="icon">🔔</span> Notification Center</h2>
      <p>A dedicated page for everything Skales tells you on its own — task
      completions, calendar reminders, Friend Mode check-ins, contact messages
      and product updates. Open it from the bell in the sidebar; the bell
      carries the unread count.</p>

      <h3>Notification tones</h3>
      <p><strong>Settings &rsaquo; General &rsaquo; Sound</strong> picks the tone Skales plays: the <strong>Skales</strong> tone, <strong>Glint</strong> (a bright rising chime), <strong>Ripple</strong> (three soft wooden notes) or <strong>Bloom</strong> (a warm swell). All four are equally loud and short, and they are the same four the phone offers. Choosing one plays it. On the phone you can also pick the phone's own system sound; inside the app on the computer that choice plays the Skales tone.</p>

      <h3>Read / Unread</h3>
      <p>Every entry is read or unread, individually or all at once. Read state
      survives a restart.</p>

      <h3>The whole message, not a preview</h3>
      <p>An entry carries the full text it was given, so a long report is readable here rather than cut off mid-sentence, and the result of a task links back to the task it came from. Long generations report back here too: a picture or a video that finishes after you have moved on shows up in the bell and in the chat it was asked for, Studio renders and editor exports included.</p>

      <h3>Tabs</h3>
      <p>Four tabs: <strong>All</strong>, <strong>Updates</strong> (product
      announcements), <strong>Bug Replies</strong> (answers to reports you
      filed) and <strong>Info</strong>. There is no keyword search and no date
      filter.</p>

      <h3>What may reach you</h3>
      <p>The gear icon opens the controls, and this is where most "too many
      notifications" questions are answered:</p>
      <ul>
        <li><strong>Mute live notifications</strong> — one switch, and it is
        hard: nothing pings on any channel, at any priority. Everything is
        still recorded on this page, and important items held back are counted
        so muting never swallows anything. <strong>It also stops Friend Mode
        check-ins</strong>, which is the one consequence worth remembering
        before you leave it on.</li>
        <li><strong>Notification types</strong> — seventeen kinds in five
        groups (Tasks &amp; Planner, Calendar, Messages &amp; Email, Companion,
        Discover Feed). An unchecked type is delivered nowhere, not even to
        this page. Discover is opt-in, so a fresh install is silent there.</li>
        <li><strong>Frequency per group</strong> — Instant, Often, 12h or Once.
        This throttles live delivery only; the page still records everything.
        High-priority items and a message from one of your contacts are never
        throttled.</li>
        <li><strong>Tasks in chat</strong> — results of scheduled and recurring
        tasks arrive as a readable chat message, so you get the report without
        an external messenger.</li>
      </ul>
      <p>Quiet hours come from Friend Mode and apply here too: outside high
      priority, nothing is delivered live during the night window, and it is
      all waiting on this page afterwards.</p>

      <h3>Retention</h3>
      <p>The page keeps the most recent 50 entries; older ones age out. There
      is no time-based archive and no starring.</p>
    </section>

    <section id="dashboard">
      <h2><span class="icon">📊</span> Dashboard</h2>
      <p>A customizable home screen with status cards and optional widgets.</p>

      <h3>Status Cards</h3>
      <p>Always visible: connected providers, API status, active bots (Telegram, WhatsApp, Discord), theme selector, recent sessions.</p>

      <h3>Optional Widgets</h3>
      <div class="card-grid">
        <div class="card"><div class="card-title">🗓 Calendar</div><div class="card-desc">Upcoming events from your connected calendar.</div></div>
        <div class="card"><div class="card-title">🌤 Weather</div><div class="card-desc">Current conditions and forecast for your location.</div></div>
        <div class="card"><div class="card-title">🦎 Buddy</div><div class="card-desc">Quick access to your Desktop Buddy companion.</div></div>
        <div class="card"><div class="card-title">📧 Email</div><div class="card-desc">Unread email summary from your connected account.</div></div>
        <div class="card"><div class="card-title">✅ Tasks</div><div class="card-desc">Active Autopilot tasks and their status.</div></div>
        <div class="card"><div class="card-title">📋 Plan</div><div class="card-desc">Today's AI-generated daily plan.</div></div>
        <div class="card"><div class="card-title">📈 Stats</div><div class="card-desc">Usage statistics, token counts, and session history.</div></div>
      </div>
      <p style="margin-top:0.75rem;"><strong>Edit</strong> on the Dashboard opens a customising mode: a line says how it works, an <strong>Add Widget</strong> tile sits in the grid (also on an empty dashboard), each widget can be dragged by its header or moved one place earlier or later with its arrows, and the bin removes it. <strong>Done</strong> or Escape ends the mode, and the order you set is kept after a restart.</p>
      <p>Five widgets show your week: <strong>Agent runs</strong> (the last seven days, how many finished well, a click opens the Cockpit), <strong>Next 24 hours</strong> (your schedules on a day axis), <strong>Memory growth</strong> (new memories per week, each dated by when it was learned, with the newest listed under the bars), <strong>Made this week</strong> in Studio and the <strong>tools</strong> you used most. <strong>Activity</strong> shows a year of AI work at a glance and <strong>Costs</strong> today's spend.</p>
      <p style="color: var(--muted); font-size: 0.875rem;">A widget is a card on this page. When what you want is a whole screen of its own, with its own storage and its own menu entry, that is a <a href="#plugins">plugin</a> - and there is a gallery of them to install from.</p>

      <h3>In-App Notifications</h3>
      <p>Toast notifications appear in-app for important events: task completions, message arrivals, calendar reminders, and system alerts. Notifications can be accessed in the dedicated Notification Center for history and filtering.</p>
    </section>

    <section id="custom-widgets">
      <h2><span class="icon">🧱</span> Custom Widgets</h2>
      <p><strong>Sidebar &rsaquo; System &rsaquo; Custom Widgets.</strong> A widget is a small interactive tool that Skales renders itself - a converter, a tracker, a board, a calculator you got tired of looking up. It is the step below a <a href="#plugins" style="color:var(--accent)">plugin</a>: a plugin is a page of its own with storage and, for the working kinds, an agent behind it; a widget is one self-contained piece you switch on and use.</p>

      <h3>Four ways to get one</h3>
      <ul>
        <li><strong>Describe it.</strong> Widget AI writes it, checks it and switches it on, correcting itself up to three times before it saves anything - so what lands is something that ran, not something that merely compiled.</li>
        <li><strong>The Wizard</strong> asks a few guided questions and builds it from your answers, for when you would rather be asked than write a brief.</li>
        <li><strong>Write it yourself</strong> from the built-in template.</li>
        <li><strong>Upload one</strong> as a <code>.js</code> file or a <code>.zip</code>.</li>
      </ul>

      <h3>Living with them</h3>
      <p>Every installed widget is on the page with a switch: activate or deactivate it with one click, and nothing is deleted by switching it off. A widget can be shared to the <a href="#discover" style="color:var(--accent)">Discover</a> feed for other people to pick up, and one that will not run says what is wrong with it rather than showing an empty frame.</p>
    </section>

    <section id="updates">
      <h2><span class="icon">🔄</span> Updates</h2>
      <p><strong>The System button in the foot of the sidebar &rsaquo; Update.</strong> The page shows the version you are on and the newest one side by side, with what is new in it, and a <strong>Check now</strong> button for when you do not want to wait for the automatic check.</p>

      <h3>What an update touches</h3>
      <p>Only the application. Your <code>~/.skales-data</code> folder, which is where conversations, memory, settings and everything Studio made live, is not part of the update and is not replaced by it.</p>

      <h3>How it installs</h3>
      <ul>
        <li>Skales checks for new versions on its own. A download is verified against its published hash before anything is installed, and the page says so once it has been.</li>
        <li><strong>Install now</strong> runs it and restarts Skales. <strong>Install later</strong> keeps the downloaded version ready for the next start.</li>
        <li>An installation that fails is rolled back rather than left half done, and the previous versions are kept locally so you can go back to one deliberately.</li>
      </ul>

      <div class="tip"><strong>Auto Backup:</strong> the update page tells you whether it is on, because it is what captures your data before an installer runs. Switch it on under <strong>Settings &rsaquo; Advanced &rsaquo; Backup</strong>.</div>

      <p>What changed in each version is in the changelog, not here. Ask Skales itself: "what is new in this version" reads the changelog that shipped with the build you are running.</p>
    </section>

    <section id="export">
      <h2><span class="icon">💾</span> Export / Import Backup</h2>
      <p>One-click ZIP backup of all settings, memories, and integrations. Export to restore on another machine or create versioned backups.</p>

      <h3>Full Data Export</h3>
      <p>Download a ZIP archive containing all your Skales data: conversations, memory, agent definitions, custom skills, settings, and integration credentials.</p>

      <h3>Restore</h3>
      <p>Importing a backup restores everything it contains. Your Workspace, your WhatsApp session and widgets or plugins you already have are kept, and an imported widget or plugin with the same name lands beside yours instead of over it.</p>

      <h3>With or without secrets</h3>
      <p>Keys and passwords are encrypted on your computer, with a key that never leaves it. That key is held by your system&rsquo;s key store: the macOS Keychain, the Windows credential protection or the Linux secret service. <strong>Settings &rarr; System &rarr; Backup &amp; moving</strong> says where it is: in the key store; in a file only your user account can read, because the system has no key store or the key store would not take it; or, in red, that the key store will not open it on this computer, with the way out (restore a backup or enter the keys again). A backup <strong>with secrets</strong> opens them for the trip so they work on another computer, which then encrypts them again with its own key. Keep such a file as safe as the keys themselves. A backup <strong>without secrets</strong> is the one to hand to somebody else: provider keys, integration tokens, your Skales IQ sign-in, MCP sign-ins and the remote access token are left out, the second-factor setup and the secret vault are not included, server profiles (FTP, SFTP and SSH) keep their server and user name without the password, a pasted SSH key or its passphrase, and the signed-in browser profiles (the browser the agent drives and the one that publishes to Moodle) stay on this computer.</p>
      <p>Restoring a backup without secrets never replaces a working key with a placeholder. Where the backup left a credential out, the one already on this computer stays. Where there is none, the field stays empty, and the import tells you how many to enter again. Skales IQ is then signed out, MCP servers ask you to sign in, and the second factor counts as not set up.</p>

      <h3>Version Control</h3>
      <p>Date-stamped backups let you maintain multiple versions. Restore to any previous backup version at any time.</p>
    </section>

    <section id="migration">
      <h2><span class="icon">🔄</span> Migration Importer</h2>
      <p>Import conversation history from other AI tools.</p>
      <table>
        <thead><tr><th>Source</th><th>Format</th></tr></thead>
        <tbody>
          <tr><td>ChatGPT</td><td>conversations.json from data export</td></tr>
          <tr><td>Claude</td><td>JSON export</td></tr>
          <tr><td>Copilot</td><td>JSON export</td></tr>
          <tr><td>Gemini</td><td>JSON export</td></tr>
          <tr><td>Markdown</td><td>Any .md file</td></tr>
          <tr><td>Generic JSON</td><td>Array of message objects</td></tr>
        </tbody>
      </table>
      <p>Access via <strong>Settings > System > Backup &amp; moving > Import from Another Tool</strong>.</p>
    </section>

    <section id="safety">
      <h2><span class="icon">🛡</span> Safety Mode</h2>
      <table>
        <thead><tr><th>Mode</th><th>Behavior</th></tr></thead>
        <tbody>
          <tr><td>Safe</td><td>Skales requests your approval before critical actions: deleting files, sending emails, running shell commands, making network requests, and blocks dangerous shell commands outright. In Organization, agents prepare destructive actions as files for manual review instead of executing them. Recommended.</td></tr>
          <tr><td>Advanced</td><td>No approval prompts, dangerous commands allowed. A residual guard still blocks the truly destructive ones (disk wipe, rm -rf /, fork bomb, shutdown) and keeps system directories protected. This is exactly what "Unrestricted" did before v12.2.5.</td></tr>
          <tr><td>Unrestricted</td><td>Truly unguarded: the residual guard becomes a warning instead of a block, and with File Access also set to unrestricted Skales may reach system paths, install software and talk to hardware (Bluetooth, network, devices). Full responsibility is yours.</td></tr>
        </tbody>
      </table>
      <h3>What asks in every mode</h3>
      <p>Some steps ask whatever mode you are in, Unrestricted included: purchases, sign-ins, publishing, exports, course uploads, deleting files on a server, a click that deletes or pays, new tool code, and changes to more than 20 messages in your mailbox. The <strong>System</strong> menu at the foot of the sidebar opens with your safety mode and one sentence on what it asks about, and the safety settings list, by group, every tool that asks first.</p>
      <p>Helpers that the assistant starts for research, its <strong>sub-agents</strong>, can never send, post, upload or publish anything, in any mode. They hand their result back, and the main assistant delivers it under the same rules as everything else.</p>
      <h3>What a card that stops an action tells you</h3>
      <p>Every card that asks first says more than <em>what</em>. It names the action in plain words, says <strong>what happens if you say no</strong>, and says <strong>how far an "always" would actually reach</strong> — all three before you press either button, so an always-allow is never a blank cheque you find the edges of afterwards. Each button carries a sentence of its own naming exactly how far a yes reaches: <strong>this call only</strong>; <strong>every action of that kind until this session ends</strong>; or <strong>every one of them, in every session, until you take it back in Settings</strong>. A session running unattended that stops to ask anyway says why, in the words of the check that stopped it.</p>

      <p style="margin-top:0.75rem;">Configure in <strong>Settings → Security &amp; Privacy → Safety mode</strong> (or during onboarding). If you used the old "Unrestricted", it is now called "Advanced" with identical behaviour, and a one-time note on first start points you to the new, genuinely unrestricted mode. The Desktop Buddy shows approval prompts even when the main window is closed.</p>

      <h3>Safe Mode in Organization</h3>
      <p>Safe Mode now extends to Organization execution. When enabled, organization agents cannot call send_email, reply_email, delete_email, execute_command, or delete_file. Instead, they prepare the content and save it as a file for your manual review. The Execute tab displays the current safety mode status.</p>

      <h3>Admin Panel v6</h3>
      <p>For users with admin access, the Admin Panel provides infrastructure management with enhanced security:</p>
      <ul style="margin: 0.5rem 0 0.75rem 1.5rem; color: var(--muted); font-size: 0.875rem;">
        <li style="margin-bottom: 0.4rem;"><strong style="color:var(--text)">Brute-Force Protection</strong> — Failed login attempts trigger automatic lockouts</li>
        <li style="margin-bottom: 0.4rem;"><strong style="color:var(--text)">CSRF Protection</strong> — All state-changing requests require valid CSRF tokens</li>
        <li style="margin-bottom: 0.4rem;"><strong style="color:var(--text)">Rate Limiting</strong> — API endpoints are rate-limited to prevent abuse and DoS attacks</li>
      </ul>
    </section>

    <section id="blocked-folders">
      <h2><span class="icon">🚫</span> Folders Skales must never touch</h2>
      <p>Under <strong>Settings &gt; Security &amp; Privacy &gt; File access</strong>, <strong>Blocked folders</strong> is the list that no mode lifts. Not Unrestricted, not Auto, not a bound Code session. It covers the file tools <em>and</em> the shell, so <code>cat</code>, <code>sed</code>, <code>git -C</code> and <code>rm</code> are refused there too &mdash; a deny list the shell does not know about is theatre.</p>
      <p>One click adds Skales&rsquo; own source and data folders, which is the pair worth blocking first if you use Skales to work on Skales.</p>
    </section>

    <section id="tool-loop">
      <h2><span class="icon">🔄</span> Tool Loop Protection</h2>
      <p>Prevents runaway agent loops where the AI calls the same tool repeatedly without making progress. Two limits are enforced per agent turn:</p>

      <table>
        <thead><tr><th>Limit</th><th>Value</th><th>Description</th></tr></thead>
        <tbody>
          <tr><td>Max identical calls</td><td>2</td><td>The same tool with the same arguments can only be called twice per turn</td></tr>
          <tr><td>Max total tool calls</td><td>20</td><td>Total tool calls per single agent turn are capped at 20</td></tr>
        </tbody>
      </table>

      <p>When either limit is hit, the agent receives a warning message and must proceed without the blocked tool call. This prevents infinite loops and excessive API usage.</p>
    </section>

    <section id="danger-zone">
      <h2><span class="icon">⚠️</span> Danger Zone</h2>
      <p>Located in <strong>Settings → System → Danger zone</strong>. Contains destructive actions that require careful consideration.</p>

      <h3>Reset Settings</h3>
      <p>Deletes the settings file and nothing else: every API key, your providers and models, and every preference in Settings. Remote access switches off, and paired phones have to be paired again. Your chats, memories, agents, add-ons, scheduled tasks and connected accounts (Telegram, Discord, WhatsApp, mail, calendars) are kept, and their bots keep running.</p>

      <h3>Delete All Data</h3>
      <p>Deletes the entire Skales data folder: settings and API keys, chats, memories, agents, scheduled tasks, connected accounts, add-ons and every file in your workspace. The Telegram, Discord and WhatsApp bots are stopped first. Backups you saved outside Skales are kept. Skales restarts afterwards.</p>

      <h3>Delete My Server Data</h3>
      <p>Permanently deletes all your data from the Skales server including conversations, memories, settings, and integrations. This action cannot be undone. Local data on your machine is not affected.</p>

      <div class="warn"><strong>⚠️ Irreversible</strong> - Server data deletion is permanent. Make sure you have a backup (Settings → System → Backup &amp; moving) before proceeding.</div>
    </section>

    <!-- ===== Chapter: Troubleshooting ===== -->
    <section id="ch-help" class="chapter-lead">
      <div class="lead-kicker">Chapter 11</div>
      <h2>Troubleshooting</h2>
      <p class="lead-intro">Most of what looks broken is one of five things, and all five can be checked in under a minute. What is left after that is worth a report, and this chapter ends with how to make one that can actually be acted on.</p>

      <div class="walk">
        <div class="walk-head"><h3>Walkthrough: the five checks, in this order</h3><span class="walk-time">2 minutes</span></div>
        <p class="walk-goal">Work down the list. Each one rules out a whole class of problem, and they are in the order that rules out the most for the least effort.</p>
        <ol>
          <li>
            <span class="do"><strong>Which model is actually answering?</strong> Look at the readout under the composer, not at your settings page.</span>
            <span class="then">the model this conversation uses, which after 12.7.1 is the one the next message will really go to. A conversation can carry a model your settings know nothing about.</span>
          </li>
          <li>
            <span class="do"><strong>Is it the key or the country?</strong> Try the same key on the provider's own site, from the same connection.</span>
            <span class="then">the answer immediately: if it fails there too, it is the connection. <a href="#regional">Which providers work where</a> lists the full replacements.</span>
          </li>
          <li>
            <span class="do"><strong>Is it slow or is it stuck?</strong> Between sending and the first word, Skales says it is reading your prompt and how long it has been doing so.</span>
            <span class="then">a line that names the wait, and on a model running on your own machine, a note that this phase is silent by nature and can take a while on slower hardware. That line disappearing is the first word arriving.</span>
          </li>
          <li>
            <span class="do"><strong>Is the feature switched on?</strong> Sidebar, System, <a href="#addons-view">Add-Ons</a>.</span>
            <span class="then">whether the thing you are looking for is an add-on that is off. An add-on that is off takes its sidebar entry and its settings section with it.</span>
          </li>
          <li>
            <span class="do"><strong>Did it stop, or did the machine stop?</strong> A long run that ended early is usually the disk or the computer going to sleep under it.</span>
            <span class="then"><a href="#long-runs">Long runs, sleep and the disk</a>, which lists what to check first and in what order.</span>
          </li>
        </ol>
      </div>

      <p>Still wrong after all five: <a href="#feedback">Feedback and Reports</a>. A report can carry the crash your own computer recorded, switched off unless you turn it on, with the exact text shown on screen before anything is sent.</p>

      <h3>In this chapter</h3>
      <div class="lead-index">
        <a href="#first-checks">When something will not work</a>
        <a href="#long-runs">Long runs, sleep and the disk</a>
        <a href="#logs">Logs and Diagnostics</a>
        <a href="#feedback">Feedback & Reports</a>
      </div>
    </section>

    <section id="first-checks">
      <h2><span class="icon">🧭</span> When something will not work</h2>
      <p>The five checks at the top of this chapter rule out most of it. What follows is the same thing arranged the other way round: from the symptom you are looking at to the thing that usually causes it.</p>

      <table>
        <tr><th>What you see</th><th>What it usually is</th></tr>
        <tr>
          <td>Nothing at all happens after you send</td>
          <td>The wait before the first word. Skales names that wait and counts it. On a model on your own machine it is silent by nature and can run for minutes on slower hardware.</td>
        </tr>
        <tr>
          <td>"The model was retired or renamed", but it was not</td>
          <td>The address, not the model. A provider with more than one host serves different model generations at different addresses; the endpoint field on the provider card is where that is fixed. Since 12.7.1 Skales says a model is gone only when the provider says so.</td>
        </tr>
        <tr>
          <td>The key is refused no matter how you enter it</td>
          <td>Either the wrong account type for that provider, or the provider not serving your country. Test the key on the provider's own site from the same connection. See <a href="#regional">Which providers work where</a>.</td>
        </tr>
        <tr>
          <td>The answer is not from the model you picked</td>
          <td>Look at the readout under the composer rather than at Settings: a conversation carries its own model. Changing the default does not reach into a conversation that already has one.</td>
        </tr>
        <tr>
          <td>A menu entry or a settings section is missing</td>
          <td>Its add-on is switched off, which takes both with it. Sidebar, System, <a href="#addons-view">Add-Ons</a>. The <strong>Advanced</strong> view of Settings always shows every setting there is.</td>
        </tr>
        <tr>
          <td>A long run ended early on its own</td>
          <td>Almost always the disk or the machine going to sleep under it. <a href="#long-runs">Long runs, sleep and the disk</a> lists what to check and in what order.</td>
        </tr>
        <tr>
          <td>A tool keeps being called with the wrong name or the wrong shape</td>
          <td>The model, not Skales. <a href="#llm-profiles">LLM Profiles</a> is the per-model correction for exactly this.</td>
        </tr>
        <tr>
          <td>"Something crashed" while looking at Skales from a phone</td>
          <td>The connection, not a crash: the computer running Skales slept, restarted or changed network. Since 12.7.1 it says so in your language instead.</td>
        </tr>
        <tr>
          <td>Voice works on the desktop but the phone browser never hears you</td>
          <td>The browser. A microphone needs HTTPS or localhost, and a plain network address is refused silently. See <a href="#remote-access">Remote access</a>.</td>
        </tr>
      </table>

      <div class="tip"><strong>Ask Skales.</strong> It carries this guide and the changelog and can search both: "where do I switch off an add-on" or "what changed in this version" is answered out of the documentation that shipped with the build you are running, not out of the model's memory.</div>
    </section>

    <section id="long-runs">
      <h2><span class="icon">🌙</span> Long runs, sleep and the disk</h2>
      <p>Skales is built to keep working while you are away: a goal, a scheduled job, a team of agents, a long build. Two things on the machine itself can end such a run without Skales having done anything wrong, and both are worth checking before you go looking for a bug.</p>
      <h3>The disk that goes to sleep under a running job</h3>
      <p>Windows can park a drive after a few minutes of no reads or writes. A run that thinks for a while and then writes a file finds the disk gone, and what comes back is a write error, a crash, or a job that simply stops. Skales retries a write that fails while a disk is waking up, but a drive that is slow or worn can take longer than any retry is worth.</p>
      <p>Reported by a user running Skales overnight on an RTX 4090 with a worn system SSD: with <strong>Control Panel &rsaquo; Power Options &rsaquo; Change plan settings &rsaquo; Change advanced power settings &rsaquo; Hard disk &rsaquo; Turn off hard disk after</strong> set to <strong>Never</strong>, ten hours of continuous work ran without a single crash, where the same work had been failing before. If you leave Skales working unattended, set that to Never.</p>
      <h3>The machine that sleeps</h3>
      <p>Sleep is different from a parked disk: the whole system stops. Skales catches up scheduled runs that were missed while the machine slept, and a timer the system froze says so rather than drifting silently. What it cannot do is finish a model call that was cut in half, so for a long unattended run set sleep to Never as well, or keep the machine awake for as long as the job needs.</p>
      <h3>What to check first when a long run ends early</h3>
      <ul>
        <li><strong>Logs</strong> in the sidebar: a run that hit a write error says so there, with the path.</li>
        <li><strong>The disk itself.</strong> A drive reporting reallocated sectors will fail a long write eventually, whatever the power settings say.</li>
        <li><strong>The model, not the machine.</strong> If the run ended with an answer rather than an error, it finished the way the model decided to finish it.</li>
      </ul>
    </section>

    <section id="logs">
      <h2><span class="icon">📄</span> Logs and Diagnostics</h2>
      <p>Two places answer &ldquo;what actually happened&rdquo;, and they answer different questions.</p>

      <h3>Logs</h3>
      <p><strong>The System button in the foot of the sidebar &rsaquo; Diagnose</strong> is the running record of what this install has been doing - the turns, the tool calls and the errors as they came, in order. It is the place to look when something behaved oddly a minute ago and you want to see it rather than reconstruct it.</p>

      <h3>Diagnostics</h3>
      <p><strong>Settings &rsaquo; Advanced &rsaquo; Diagnostics</strong> is the summary you can hand to somebody else. Press <strong>Show recent crashes and errors</strong> and the card fills with what this machine recorded: the build and the hardware, crashes, the connection map of your local and custom providers, every provider call that failed in this session, recent warnings, and the update log, so a failed update can be shown instead of described. <strong>Copy</strong> puts the same text on the clipboard for a bug report.</p>
      <p>Nothing here is transmitted anywhere. It is read off this machine and shown to you. You can also just ask in a chat - Skales reads the same report itself, so &ldquo;why did that fail&rdquo; is answerable without you opening anything.</p>
      <p>When you are ready to send it on, see <a href="#feedback" style="color:var(--accent)">Feedback &amp; Reports</a>.</p>
    </section>

    <section id="feedback">
      <h2><span class="icon">💌</span> Feedback & Reports</h2>
      <p>Found a bug or have a suggestion? Open the <strong>System</strong> button in the foot of the sidebar and pick <strong>Report a bug</strong>, right-click any entry in the sidebar and choose it there, or visit <strong>Settings → System → About Skales</strong>.</p>
      <p>Your reports are saved locally under <strong>Your Reports</strong> so you can track their status. Anonymous telemetry (feature usage, not content) can be disabled in Settings → Security &amp; Privacy → Network, telemetry &amp; hooks.</p>
      <p>A report can be up to <strong>4,000 characters</strong>, and once you are near that a line under the field counts down how many you have left. <strong>Nothing is cut off in silence</strong>: the field simply stops taking more, so a long report is never sent as half a report without your knowing.</p>
      <p>Skales also asks, once, whether you would like to leave a note about how it is going — and on the phone, once, whether you would rate it in the store. Both take no for an answer permanently, neither makes a sound or sends a notification, and <strong>they never arrive in the same sitting as one another</strong>.</p>
      <p>Community and support: <a href="https://skales.app" style="color:var(--accent)">skales.app</a></p>
    </section>

    <footer>
      <span>Skales v<span data-skales-version>12.9.55</span> &middot; © 2024-2026 Mario Simic &middot; Proprietary licence</span>
      <a href="https://skales.app">skales.app</a>
    </footer>

  </main>
</div>
  <script>
  // Screenshot slots. A figure starts as "pending" and only loses that class
  // once its image has actually decoded, so a missing file degrades to a quiet
  // placeholder instead of a broken-image icon. Done before paint where the
  // image is already cached.
  (function () {
    Array.prototype.forEach.call(document.querySelectorAll('figure.shot'), function (fig) {
      var img = fig.querySelector('img');
      if (!img) { fig.classList.add('pending'); return; }
      function ok()  { fig.classList.remove('pending'); }
      function bad() { fig.classList.add('pending'); }
      if (img.complete) { (img.naturalWidth > 0 ? ok : bad)(); }
      else { fig.classList.add('pending'); img.addEventListener('load', ok); img.addEventListener('error', bad); }
    });
  })();
  </script>
  <script>
  // Chapters and search.
  //
  // The nav is the single source of truth: a .section-label carries a chapter,
  // the links under it belong to it, and every <section id> takes the chapter
  // of the first nav link that points at it. A section no link points at stays
  // with the chapter above it rather than disappearing - a forgotten nav entry
  // must never hide content.
  //
  // The search indexes the whole document, not the visible chapter, because a
  // reader looking for "pairing code" has no way to know which chapter it is
  // in. That is the entire point of it.
  (function () {
    var nav    = document.querySelector('nav');
    var toc    = document.getElementById('toc');
    var main   = document.querySelector('main');
    if (!nav || !toc || !main) return;

    var links  = Array.prototype.slice.call(toc.querySelectorAll('a[data-chapter]'));
    var labels = Array.prototype.slice.call(toc.querySelectorAll('.section-label[data-chapter]'));
    if (!links.length) return;

    var chapterOf = {};   // section id -> chapter
    var order = [];       // chapters in nav order
    var titles = {};

    labels.forEach(function (l) {
      var c = l.getAttribute('data-chapter');
      if (order.indexOf(c) === -1) { order.push(c); titles[c] = l.textContent.trim(); }
    });
    links.forEach(function (a) {
      var id = (a.getAttribute('href') || '').slice(1);
      if (id && !chapterOf[id]) chapterOf[id] = a.getAttribute('data-chapter');
    });

    var sections = Array.prototype.slice.call(main.querySelectorAll('section[id]'));
    var lastChapter = order[0];
    sections.forEach(function (sec) {
      var c = chapterOf[sec.id] || sec.getAttribute('data-chapter') || lastChapter;
      lastChapter = c;
      chapterOf[sec.id] = c;
      sec.setAttribute('data-chapter', c);
    });

    // ---- chapter switcher -------------------------------------------------
    var switcher = document.getElementById('chapter-switch');
    var switchLinks = switcher ? Array.prototype.slice.call(switcher.querySelectorAll('a')) : [];

    function firstIdOf(chapter) {
      for (var i = 0; i < links.length; i++) {
        if (links[i].getAttribute('data-chapter') === chapter) return (links[i].getAttribute('href') || '').slice(1);
      }
      return '';
    }

    var footer = document.createElement('div');
    footer.className = 'chapter-nav';
    var mainFooter = main.querySelector('footer');
    if (mainFooter) main.insertBefore(footer, mainFooter); else main.appendChild(footer);

    function show(chapter, id) {
      if (order.indexOf(chapter) === -1) chapter = order[0];
      document.body.classList.add('in-chapter');
      sections.forEach(function (sec) {
        if (sec.getAttribute('data-chapter') === chapter) sec.setAttribute('data-chapter-active', '');
        else sec.removeAttribute('data-chapter-active');
      });
      links.forEach(function (a) {
        var t = (a.getAttribute('href') || '').slice(1);
        a.classList.toggle('active', !!id && t === id);
        a.style.display = a.getAttribute('data-chapter') === chapter ? '' : 'none';
      });
      labels.forEach(function (l) {
        l.style.display = l.getAttribute('data-chapter') === chapter ? '' : 'none';
      });
      Array.prototype.forEach.call(toc.querySelectorAll('.group-label[data-chapter]'), function (g) {
        g.style.display = g.getAttribute('data-chapter') === chapter ? '' : 'none';
      });
      switchLinks.forEach(function (a) {
        a.classList.toggle('current', a.getAttribute('data-chapter') === chapter);
      });

      var i = order.indexOf(chapter);
      var prev = i > 0 ? order[i - 1] : null;
      var next = i < order.length - 1 ? order[i + 1] : null;
      footer.innerHTML = '';
      var left = document.createElement(prev ? 'a' : 'span');
      if (prev) left.href = '#' + firstIdOf(prev);
      left.textContent = prev ? '\u2190 ' + titles[prev] : '';
      var right = document.createElement(next ? 'a' : 'span');
      if (next) right.href = '#' + firstIdOf(next);
      right.textContent = next ? titles[next] + ' \u2192' : '';
      footer.appendChild(left);
      footer.appendChild(right);
    }

    function showFront() {
      document.body.classList.remove('in-chapter');
      sections.forEach(function (sec) { sec.removeAttribute('data-chapter-active'); });
      links.forEach(function (a) { a.classList.remove('active'); a.style.display = 'none'; });
      labels.forEach(function (l) { l.style.display = 'none'; });
      Array.prototype.forEach.call(toc.querySelectorAll('.group-label[data-chapter]'), function (g) { g.style.display = 'none'; });
      switchLinks.forEach(function (a) { a.classList.remove('current'); });
      footer.innerHTML = '';
      window.scrollTo(0, 0);
    }

    // ---- search -----------------------------------------------------------
    // Built once from the DOM, so it can never describe a document other than
    // the one on screen.
    var index = [];
    function headingText(el) {
      // The icon is decoration; a search result reading "\u{1F517} Pairing a
      // device" puts a picture where the first letter should be.
      var clone = el.cloneNode(true);
      Array.prototype.forEach.call(clone.querySelectorAll('.icon, .badge'), function (n) { n.remove(); });
      return clone.textContent.replace(/\s+/g, ' ').trim();
    }
    sections.forEach(function (sec) {
      var chapter = sec.getAttribute('data-chapter');
      var h2 = sec.querySelector('h2');
      var secTitle = h2 ? headingText(h2) : sec.id;
      var blocks = [];
      var current = { id: sec.id, title: secTitle, text: [] };
      Array.prototype.forEach.call(sec.children, function (node) {
        if (node.tagName === 'H2') return;
        if (node.tagName === 'H3') {
          if (current.text.length) blocks.push(current);
          var hid = node.id || sec.id;
          current = { id: hid, title: secTitle + ' \u203a ' + headingText(node), text: [] };
          return;
        }
        current.text.push(node.textContent);
      });
      blocks.push(current);
      blocks.forEach(function (b) {
        var text = b.text.join(' ').replace(/\s+/g, ' ').trim();
        index.push({
          id: b.id, title: b.title, chapter: chapter, where: titles[chapter] || '',
          text: text, hay: (b.title + ' ' + text).toLowerCase(),
        });
      });
    });

    var input   = document.getElementById('doc-search');
    var results = document.getElementById('search-results');

    function esc(s) { return s.replace(/[&<>"]/g, function (c) { return ({ '&': '&amp;', '<': '&lt;', '>': '&gt;', '"': '&quot;' })[c]; }); }

    function snippet(entry, terms) {
      var low = entry.text.toLowerCase();
      var at = -1;
      for (var i = 0; i < terms.length && at < 0; i++) at = low.indexOf(terms[i]);
      if (at < 0) at = 0;
      var from = Math.max(0, at - 40);
      var raw = entry.text.slice(from, from + 160);
      var out = esc((from > 0 ? '\u2026' : '') + raw + (from + 160 < entry.text.length ? '\u2026' : ''));
      terms.forEach(function (t) {
        if (!t) return;
        out = out.replace(new RegExp('(' + t.replace(/[.*+?^${}()|[\]\\]/g, '\\$&') + ')', 'ig'), '<mark>$1</mark>');
      });
      return out;
    }

    function runSearch(q) {
      q = (q || '').trim().toLowerCase();
      if (q.length < 2) { document.body.classList.remove('searching'); results.innerHTML = ''; return; }
      document.body.classList.add('searching');
      var terms = q.split(/\s+/).filter(Boolean);
      var hits = [];
      index.forEach(function (e) {
        var score = 0, all = true;
        terms.forEach(function (t) {
          var inTitle = e.title.toLowerCase().indexOf(t) >= 0;
          var inText  = e.hay.indexOf(t) >= 0;
          if (!inText) all = false;
          if (inTitle) score += 8;
          if (inText)  score += 1;
        });
        if (all && score > 0) hits.push({ e: e, score: score });
      });
      hits.sort(function (a, b) { return b.score - a.score; });
      hits = hits.slice(0, 25);
      if (!hits.length) {
        results.innerHTML = '<div class="search-empty">Nothing in the guide matches that. Try a word you would see on the screen.</div>';
        return;
      }
      var html = '<div class="search-count">' + hits.length + (hits.length === 25 ? '+' : '') + ' result' + (hits.length === 1 ? '' : 's') + '</div>';
      hits.forEach(function (h) {
        html += '<a class="search-hit" href="#' + h.e.id + '">'
             +  '<span class="hit-where">' + esc(h.e.where) + '</span>'
             +  '<span class="hit-title">' + esc(h.e.title) + '</span>'
             +  '<span class="hit-snip">' + snippet(h.e, terms) + '</span>'
             +  '</a>';
      });
      results.innerHTML = html;
    }

    if (input) {
      input.addEventListener('input', function () { runSearch(input.value); });
      input.addEventListener('keydown', function (ev) {
        if (ev.key === 'Escape') { input.value = ''; runSearch(''); input.blur(); }
        if (ev.key === 'Enter') {
          var first = results.querySelector('.search-hit');
          if (first) { location.hash = first.getAttribute('href'); input.blur(); }
        }
      });
      document.addEventListener('keydown', function (ev) {
        var typing = /^(INPUT|TEXTAREA|SELECT)$/.test((ev.target && ev.target.tagName) || '');
        if (ev.key === '/' && !typing) { ev.preventDefault(); input.focus(); input.select(); }
        if ((ev.key === 'k' || ev.key === 'K') && (ev.metaKey || ev.ctrlKey)) { ev.preventDefault(); input.focus(); input.select(); }
      });
    }
    if (results) {
      results.addEventListener('click', function (ev) {
        var a = ev.target.closest && ev.target.closest('.search-hit');
        if (a) { document.body.classList.remove('nav-open'); }
      });
    }

    // ---- routing ----------------------------------------------------------
    function route() {
      var id = (location.hash || '').slice(1);
      if (!id || id === 'top') { showFront(); return; }
      var chapter = chapterOf[id];
      if (!chapter) {
        // A hash that is not a section can still be a chapter name.
        if (order.indexOf(id) >= 0) { show(id, firstIdOf(id)); window.scrollTo(0, 0); return; }
        showFront(); return;
      }
      show(chapter, id);
      // A chapter landing page starts at the top of the chapter: scrolling it
      // "into view" would park its first line under the fixed Contents button.
      var el = id.indexOf('ch-') === 0 ? null : document.getElementById(id);
      if (el) el.scrollIntoView({ block: 'start' });
      else window.scrollTo(0, 0);
      document.body.classList.remove('nav-open');
    }
    window.addEventListener('hashchange', route);
    route();

    var toggle = document.querySelector('.nav-toggle');
    if (toggle) toggle.addEventListener('click', function () { document.body.classList.toggle('nav-open'); });
  })();
  </script>
</body>
</html>