From eedb3891c60b19e59aded1f10ee63678752e34e6 Mon Sep 17 00:00:00 2001 From: YoungWoo nam Date: Sun, 29 Nov 2026 22:48:11 +0900 Subject: [PATCH 1/8] docs: source files that lacked one open with their one-line description --- plugins/browser/src/main.rs | 1 + plugins/herdr/src/main.rs | 1 + src-tauri/src/agent_ingress/avatar_rpc.rs | 1 + src-tauri/src/agent_ingress/payload.rs | 1 + src-tauri/src/agent_ingress/server_tests.rs | 1 + src-tauri/src/agent_ingress/threads/mod.rs | 1 + src-tauri/src/agent_ingress/threads/requests.rs | 1 + src-tauri/src/agent_ingress/threads/routes.rs | 1 + src-tauri/src/log_rotation.rs | 1 + src-tauri/src/os_event_watcher/drop_release.rs | 1 + src-tauri/src/os_event_watcher/pure_helpers.rs | 1 + src-tauri/src/terminal/commands.rs | 1 + src-tauri/src/terminal/input.rs | 1 + src-tauri/src/terminal/pty.rs | 1 + src-tauri/src/terminal/screen.rs | 1 + src-tauri/src/terminal/store.rs | 1 + src-tauri/src/threads/commands.rs | 1 + src-tauri/src/threads/disk.rs | 1 + src-tauri/src/threads/mod.rs | 1 + src-tauri/src/threads/model.rs | 1 + src-tauri/src/threads/store.rs | 1 + src-tauri/src/tray.rs | 1 + src/ambient/come-along/entry-pick.ts | 1 + src/ambient/come-along/stage-pin.ts | 1 + src/ambient/locomotion/climb/wire-climb.ts | 1 + src/ambient/locomotion/fall/wire-fall.ts | 1 + src/ambient/locomotion/perch/wire-perch.ts | 1 + src/ambient/locomotion/travel/wire-travel-frame.ts | 1 + src/ambient/locomotion/walk/wire-walk.ts | 1 + src/app/bootstrap-configured.ts | 1 + src/app/controls/wire-devtools-request.ts | 1 + src/app/cross-window/wire-cross-window.ts | 1 + src/app/cross-window/wire-window-sync.ts | 1 + src/app/csp-violation.ts | 1 + src/app/dev/wire-dev-globals.ts | 1 + src/app/message/wire-message-surface-ops.ts | 1 + src/app/pet-windows/wire-preset-ids-sync.ts | 1 + src/app/settings-window/edit-target-url.ts | 1 + src/app/settings-window/wire-settings-page.ts | 1 + src/app/settings-window/wire-settings-window.ts | 1 + src/app/settings-window/wire-voice-mirror.ts | 1 + src/app/settings/config-defaults.ts | 1 + src/app/settings/conversation-stores.ts | 1 + src/app/settings/window-stores.ts | 1 + src/app/settings/wire-cue-locale-sync.ts | 1 + src/app/signal-chips/wire-signal-chips.ts | 1 + src/app/stage/stage-renderer.ts | 1 + src/app/stage/wire-summon.ts | 1 + src/app/stage/wire-window-sources.ts | 1 + src/app/turn/push/ask-session.ts | 1 + src/app/turn/push/delegation-chip-mount.ts | 1 + src/app/turn/push/playback.ts | 1 + src/app/turn/push/push-stores.ts | 1 + src/app/turn/push/wire-backend-commands.ts | 1 + src/app/turn/push/wire-push.ts | 1 + src/app/turn/turn-core.ts | 1 + src/app/turn/vocabulary/wire-vocabulary.ts | 1 + src/app/turn/voice/speak-turn.ts | 1 + src/app/turn/voice/unified-voice.ts | 1 + src/app/turn/voice/wire-voice-pipeline.ts | 1 + src/app/turn/voice/wire-voice.ts | 1 + src/app/turn/wire-sources.ts | 1 + src/app/unified/wire-unified-close.ts | 1 + src/app/unified/wire-unified-window.ts | 1 + src/config/tts-provider.ts | 1 + src/config/validators/avatar/available.ts | 1 + src/config/validators/avatar/climb.ts | 1 + src/config/validators/avatar/fall.ts | 1 + src/config/validators/avatar/framing.ts | 1 + src/config/validators/avatar/gaze.ts | 1 + src/config/validators/avatar/gestures.ts | 1 + src/config/validators/avatar/helpers.ts | 1 + src/config/validators/avatar/hit-test.ts | 1 + src/config/validators/avatar/index.ts | 1 + src/config/validators/avatar/jump.ts | 1 + src/config/validators/avatar/peek.ts | 1 + src/config/validators/avatar/stage.ts | 1 + src/config/validators/avatar/tap.ts | 1 + src/config/validators/avatar/walk.ts | 1 + src/config/validators/emotion-registry.ts | 1 + src/config/validators/endpoints.ts | 1 + src/config/validators/filler.ts | 1 + src/config/validators/guardrails.ts | 1 + src/config/validators/hotkeys.ts | 1 + src/config/validators/motions.ts | 1 + src/config/validators/persona/persona.ts | 1 + src/config/validators/persona/read-card.ts | 1 + src/config/validators/screen.ts | 1 + src/dispatcher/backend/context-builder.ts | 1 + src/dispatcher/backend/previous-turn.ts | 1 + src/dispatcher/core/turn-gate.ts | 1 + src/dispatcher/sources/gesture/tap-source.ts | 1 + src/dispatcher/turn/turn-output.ts | 1 + src/io/assets/card/photo-size.ts | 1 + src/io/bridge/inbox/create-inbox.ts | 1 + src/io/chat/card/assemble-card.ts | 1 + src/io/chat/card/perform-greeting.ts | 1 + src/io/chat/card/pick-greeting.ts | 1 + src/io/chat/card/resolve-card.ts | 1 + src/io/chat/conversation/context-history.ts | 1 + src/io/chat/conversation/overheard/overheard-reader.ts | 1 + src/io/chat/conversation/overheard/overheard-store.ts | 1 + src/io/chat/push/tool-results/encode.ts | 1 + src/io/chat/stream/chat-completions-stream.ts | 1 + src/io/chat/stream/stream-helpers.ts | 1 + src/io/chat/stream/tool-results/chat-completions.ts | 1 + src/io/chat/stream/tool-results/responses.ts | 1 + src/io/chat/tools/screen/screen-query.ts | 1 + src/io/chat/vocabulary/express-vocabulary.ts | 1 + src/io/locks/fake-lock-manager.ts | 1 + src/io/voice/tts/readings.ts | 1 + src/io/voice/tts/voice-gate.ts | 1 + src/io/window/capture/screen-point.ts | 1 + src/io/window/geometry/roomier-side.ts | 1 + src/io/window/openers/devtools-window.ts | 1 + src/io/window/openers/pet-window.ts | 1 + src/io/window/own-origin-fetch.ts | 1 + src/io/window/pet/peek-state.ts | 1 + src/logger.ts | 1 + src/renderer/expression/gaze/bone-pitch.ts | 1 + src/renderer/geometry/hit/tap-region.ts | 1 + src/renderer/motion/clip/mirror-clip.ts | 1 + src/renderer/motion/clip/self-crossfade.ts | 1 + src/renderer/motion/grounding/sole-offset.ts | 1 + src/renderer/motion/grounding/sole-points.ts | 1 + src/renderer/motion/playback/motion-start-generation.ts | 1 + src/renderer/motion/playback/perch-hold.ts | 1 + src/settings/agent-access/document.ts | 1 + src/settings/agent-access/rows.ts | 1 + src/settings/agent-access/validate.ts | 1 + src/settings/appearance/text-size-settings.ts | 1 + src/settings/appearance/theme-settings.ts | 1 + src/settings/backend/workflow-settings.ts | 1 + src/settings/preset/bound-preset.ts | 1 + src/settings/relations/relation-lines.ts | 1 + src/settings/relations/relation-targets.ts | 1 + src/settings/relations/relations-store.ts | 1 + src/settings/relations/relations-switch.ts | 1 + src/settings/settings-stores.ts | 1 + src/settings/unified/unified-chat-switch.ts | 1 + src/settings/unified/unified-shown.ts | 1 + src/ui/ask/ask-route.ts | 1 + src/ui/chips/fit-sheet.ts | 1 + src/ui/chips/voice-input-status.ts | 1 + src/ui/commands/command-input.ts | 1 + src/ui/commands/command-list.css | 1 + src/ui/commands/command-list.ts | 1 + src/ui/commands/command-reply.css | 1 + src/ui/commands/command-reply.ts | 1 + src/ui/commands/drag-scroll.ts | 1 + src/ui/commands/reply-resize.ts | 1 + src/ui/commands/surface-commands.ts | 1 + src/ui/controls/checkbox/index.ts | 1 + src/ui/controls/disclosure/index.ts | 1 + src/ui/controls/number-field/index.ts | 1 + src/ui/controls/segment/index.ts | 1 + src/ui/controls/select/index.ts | 1 + src/ui/controls/slider/index.ts | 1 + src/ui/controls/switch/index.ts | 1 + src/ui/controls/tabs/index.ts | 1 + src/ui/controls/tooltip/index.ts | 1 + src/ui/controls/tooltip/tip-test-helpers.ts | 1 + src/ui/devtools/devtools.css | 1 + src/ui/devtools/motion-preview/live-status.ts | 1 + src/ui/devtools/motion-preview/motion-load.ts | 1 + src/ui/devtools/motion-preview/perch-hook.ts | 1 + src/ui/devtools/motion-preview/variants.ts | 1 + src/ui/listbox/listbox.ts | 1 + src/ui/quick-controls/connection/chat/push-state-text.ts | 1 + src/ui/quick-controls/delegations/delegation-sync.ts | 1 + src/ui/quick-controls/history/history-time.ts | 1 + src/ui/quick-controls/preset/photo-dialog/photo-dialog.css | 1 + src/ui/quick-controls/preset/relations/view.ts | 1 + src/ui/quick-controls/preset/use-prepended.ts | 1 + src/ui/quick-controls/switch-row.ts | 1 + src/ui/ref-mount/index.ts | 1 + src/ui/scroll-fade/scroll-fade.ts | 1 + src/ui/surfaces/apply-speech-op.ts | 1 + src/ui/theme/apply-text-scale.ts | 1 + src/ui/theme/apply-theme.ts | 1 + src/ui/unified/backlog-lines.ts | 1 + src/ui/unified/commands/unified-commands.ts | 1 + src/ui/use-snapshot/use-notify.ts | 1 + src/ui/use-snapshot/use-snapshot.ts | 1 + src/windows/devtools-main.ts | 1 + vite.config.ts | 1 + 186 files changed, 186 insertions(+) diff --git a/plugins/browser/src/main.rs b/plugins/browser/src/main.rs index cdb7749ed..6f01f3938 100644 --- a/plugins/browser/src/main.rs +++ b/plugins/browser/src/main.rs @@ -1,3 +1,4 @@ +//! Sweeps stale screenshot folders, then serves the MCP server on stdio. mod boot; mod image_encode; mod locate; diff --git a/plugins/herdr/src/main.rs b/plugins/herdr/src/main.rs index 76bd812f3..926bf781b 100644 --- a/plugins/herdr/src/main.rs +++ b/plugins/herdr/src/main.rs @@ -1,3 +1,4 @@ +//! Serves the MCP server on stdio, removes the socket directory at exit. mod cli; mod locate; mod parse; diff --git a/src-tauri/src/agent_ingress/avatar_rpc.rs b/src-tauri/src/agent_ingress/avatar_rpc.rs index db5536255..1f3359f1c 100644 --- a/src-tauri/src/agent_ingress/avatar_rpc.rs +++ b/src-tauri/src/agent_ingress/avatar_rpc.rs @@ -1,3 +1,4 @@ +//! Avatar RPC bridge between HTTP requests and the webview. use super::payload::{AvatarRoute, AvatarRpcRequest, AVATAR_RPC_CHANNEL}; use crate::os_event_watcher::epoch_ms; use std::collections::HashMap; diff --git a/src-tauri/src/agent_ingress/payload.rs b/src-tauri/src/agent_ingress/payload.rs index 95498810d..54c8844f7 100644 --- a/src-tauri/src/agent_ingress/payload.rs +++ b/src-tauri/src/agent_ingress/payload.rs @@ -1,3 +1,4 @@ +//! Request parsing, size caps, and event payload types. use crate::os_event_watcher::epoch_ms; use serde::{Deserialize, Serialize}; use std::collections::BTreeMap; diff --git a/src-tauri/src/agent_ingress/server_tests.rs b/src-tauri/src/agent_ingress/server_tests.rs index 40f23f99e..b11230c8e 100644 --- a/src-tauri/src/agent_ingress/server_tests.rs +++ b/src-tauri/src/agent_ingress/server_tests.rs @@ -1,3 +1,4 @@ +//! The agent_ingress tests' loopback server and raw TCP client. use super::*; use crate::agent_ingress::{ response::{self, status}, diff --git a/src-tauri/src/agent_ingress/threads/mod.rs b/src-tauri/src/agent_ingress/threads/mod.rs index 2fe76a3a7..4584712f6 100644 --- a/src-tauri/src/agent_ingress/threads/mod.rs +++ b/src-tauri/src/agent_ingress/threads/mod.rs @@ -1,2 +1,3 @@ +//! The ingress Threads routes' module declarations. pub(super) mod requests; pub(super) mod routes; diff --git a/src-tauri/src/agent_ingress/threads/requests.rs b/src-tauri/src/agent_ingress/threads/requests.rs index c43699374..296c9c2c9 100644 --- a/src-tauri/src/agent_ingress/threads/requests.rs +++ b/src-tauri/src/agent_ingress/threads/requests.rs @@ -1,3 +1,4 @@ +//! A PUT /threads/ request's handler: the upsert into the ThreadStore and the updated_at answer. use super::super::response::{respond_json, HttpResponse}; use super::routes::ThreadRoute; use crate::os_event_watcher::epoch_ms; diff --git a/src-tauri/src/agent_ingress/threads/routes.rs b/src-tauri/src/agent_ingress/threads/routes.rs index 1155d436b..0143dcc77 100644 --- a/src-tauri/src/agent_ingress/threads/routes.rs +++ b/src-tauri/src/agent_ingress/threads/routes.rs @@ -1,3 +1,4 @@ +//! The /threads/ route's parse: method, id shape, and body checks into a ThreadRoute. use crate::threads::model::{parse_upsert, Upsert}; const THREAD_ID_MAX_BYTES: usize = 128; diff --git a/src-tauri/src/log_rotation.rs b/src-tauri/src/log_rotation.rs index ef65517f2..130b1877e 100644 --- a/src-tauri/src/log_rotation.rs +++ b/src-tauri/src/log_rotation.rs @@ -1,3 +1,4 @@ +//! Calendar-date log rotation with a retention window. use std::fs::{self, File, OpenOptions}; use std::io::{self, Write}; use std::path::{Path, PathBuf}; diff --git a/src-tauri/src/os_event_watcher/drop_release.rs b/src-tauri/src/os_event_watcher/drop_release.rs index c34b7d416..16735ee91 100644 --- a/src-tauri/src/os_event_watcher/drop_release.rs +++ b/src-tauri/src/os_event_watcher/drop_release.rs @@ -1,3 +1,4 @@ +//! Drop-release probe that emits window_drop_release with the dragged window's label. use super::{platform_lbutton_is_down, WINDOW_DROP_RELEASE_CHANNEL}; use std::{ sync::atomic::{AtomicBool, Ordering}, diff --git a/src-tauri/src/os_event_watcher/pure_helpers.rs b/src-tauri/src/os_event_watcher/pure_helpers.rs index 3dc07ee89..2aea2ba3f 100644 --- a/src-tauri/src/os_event_watcher/pure_helpers.rs +++ b/src-tauri/src/os_event_watcher/pure_helpers.rs @@ -1,3 +1,4 @@ +//! Idle conversion, frontmost-window pick, and the listed windows' keep rule for the Threads window. use super::WindowAtPoint; /// Converts idle seconds (f64) to milliseconds (u64), clamping negative to 0. diff --git a/src-tauri/src/terminal/commands.rs b/src-tauri/src/terminal/commands.rs index 0222b0ccf..948339676 100644 --- a/src-tauri/src/terminal/commands.rs +++ b/src-tauri/src/terminal/commands.rs @@ -1,3 +1,4 @@ +//! The terminal_* commands: snapshot, open, close, input, resize, attach, the Allow answer, take back, and the tool terminals. use super::pty::{self, Store}; use super::screen; use super::store::{AccessKind, TerminalOwner, TerminalSnapshot}; diff --git a/src-tauri/src/terminal/input.rs b/src-tauri/src/terminal/input.rs index 3ea372012..f54fdabd7 100644 --- a/src-tauri/src/terminal/input.rs +++ b/src-tauri/src/terminal/input.rs @@ -1,3 +1,4 @@ +//! A terminal's input queue, written in order by its own thread so a stalled terminal never blocks a caller. use std::io::Write; use std::sync::mpsc; diff --git a/src-tauri/src/terminal/pty.rs b/src-tauri/src/terminal/pty.rs index b2e79daf5..dee130fea 100644 --- a/src-tauri/src/terminal/pty.rs +++ b/src-tauri/src/terminal/pty.rs @@ -1,3 +1,4 @@ +//! One terminal's Pty: the spawned PTY process, its output into the vt100 parser and the attach channel, resize, and kill. use super::input::Input; use super::screen; use super::store::{lock, Terminal, TerminalOwner, TerminalStore}; diff --git a/src-tauri/src/terminal/screen.rs b/src-tauri/src/terminal/screen.rs index 3d3e14273..a82e40c4b 100644 --- a/src-tauri/src/terminal/screen.rs +++ b/src-tauri/src/terminal/screen.rs @@ -1,3 +1,4 @@ +//! A terminal screen's text read: the untrusted-content line, scrollback through the scrolled view, and the cap with its cut marker. use super::store::{Terminal, TerminalOwner}; const UNTRUSTED: &str = diff --git a/src-tauri/src/terminal/store.rs b/src-tauri/src/terminal/store.rs index d089f5757..dcddc593b 100644 --- a/src-tauri/src/terminal/store.rs +++ b/src-tauri/src/terminal/store.rs @@ -1,3 +1,4 @@ +//! The terminal store: owners, snapshots, the per-terminal state lock, and the refusal and terminal caps. use serde::Serialize; use std::sync::{Arc, Condvar, Mutex, MutexGuard, PoisonError}; use std::time::{Duration, Instant}; diff --git a/src-tauri/src/threads/commands.rs b/src-tauri/src/threads/commands.rs index fc347a158..a60e46ceb 100644 --- a/src-tauri/src/threads/commands.rs +++ b/src-tauri/src/threads/commands.rs @@ -1,3 +1,4 @@ +//! The threads_snapshot and thread_read commands over the ThreadStore. use super::store::{ThreadStore, ThreadsSnapshot}; use std::sync::Arc; use tauri::State; diff --git a/src-tauri/src/threads/disk.rs b/src-tauri/src/threads/disk.rs index 73a7092ce..b31369ac9 100644 --- a/src-tauri/src/threads/disk.rs +++ b/src-tauri/src/threads/disk.rs @@ -1,3 +1,4 @@ +//! The threads' dated jsonl file: one append per thread change and the replay that loads them. use super::model::Thread; use crate::log_rotation::{parse_dated_name, DateRotatingFile}; use std::collections::HashMap; diff --git a/src-tauri/src/threads/mod.rs b/src-tauri/src/threads/mod.rs index 65992c678..da2ad85e1 100644 --- a/src-tauri/src/threads/mod.rs +++ b/src-tauri/src/threads/mod.rs @@ -1,3 +1,4 @@ +//! The Threads module: the replayed threads at setup, the managed ThreadStore, and the snapshot event emitted to the webview. pub mod commands; mod disk; pub mod model; diff --git a/src-tauri/src/threads/model.rs b/src-tauri/src/threads/model.rs index 4d9a50d91..92b42ae7d 100644 --- a/src-tauri/src/threads/model.rs +++ b/src-tauri/src/threads/model.rs @@ -1,3 +1,4 @@ +//! The Thread model: states, roles, entries, and the Upsert body's parse with its bounds. use serde::{Deserialize, Serialize}; const TEXT_MAX_CHARS: usize = 16384; diff --git a/src-tauri/src/threads/store.rs b/src-tauri/src/threads/store.rs index d1957033a..b10578b81 100644 --- a/src-tauri/src/threads/store.rs +++ b/src-tauri/src/threads/store.rs @@ -1,3 +1,4 @@ +//! The ThreadStore: entries per thread, snapshots sorted by recency, the entry and thread caps, and the disk sink. use super::model::{Entry, Thread, ThreadState, Upsert}; use serde::Serialize; use std::collections::HashMap; diff --git a/src-tauri/src/tray.rs b/src-tauri/src/tray.rs index 207ef0d74..70729c6e2 100644 --- a/src-tauri/src/tray.rs +++ b/src-tauri/src/tray.rs @@ -1,3 +1,4 @@ +//! System tray menu and its show and hide actions. use tauri::{ menu::{CheckMenuItem, Menu, MenuItem, PredefinedMenuItem}, tray::TrayIconBuilder, diff --git a/src/ambient/come-along/entry-pick.ts b/src/ambient/come-along/entry-pick.ts index 7f154655e..b8eec4bd2 100644 --- a/src/ambient/come-along/entry-pick.ts +++ b/src/ambient/come-along/entry-pick.ts @@ -1,3 +1,4 @@ +/** Picks her entry clip from the Entry family of her last backend emotion. */ import type { StageConfig } from "../../config/validators/avatar/types"; /** diff --git a/src/ambient/come-along/stage-pin.ts b/src/ambient/come-along/stage-pin.ts index ac98bacfc..0b4ea8b44 100644 --- a/src/ambient/come-along/stage-pin.ts +++ b/src/ambient/come-along/stage-pin.ts @@ -1,3 +1,4 @@ +/** The stage peek pin: arms an edge entry past the window's right edge and lets go when the clip stops or at its play_ms. */ import type { EdgeEntry } from "../../config/validators/avatar/types"; import type { MotionKind } from "../../contract"; import type { Renderer } from "../../renderer"; diff --git a/src/ambient/locomotion/climb/wire-climb.ts b/src/ambient/locomotion/climb/wire-climb.ts index d84d3340e..f25edeba4 100644 --- a/src/ambient/locomotion/climb/wire-climb.ts +++ b/src/ambient/locomotion/climb/wire-climb.ts @@ -1,3 +1,4 @@ +/** Climber start, enable latch, and teardown. */ import type { ClimbConfig, DescendConfig, diff --git a/src/ambient/locomotion/fall/wire-fall.ts b/src/ambient/locomotion/fall/wire-fall.ts index 99296e786..bb4a12caf 100644 --- a/src/ambient/locomotion/fall/wire-fall.ts +++ b/src/ambient/locomotion/fall/wire-fall.ts @@ -1,3 +1,4 @@ +/** Faller start, the fall switch, and landing events. */ import type { FallConfig, GestureCuesConfig } from "../../../config/validators/avatar/types"; import type { MotionKind, WindowRect } from "../../../contract"; import type { EventBus } from "../../../dispatcher/core/event-bus"; diff --git a/src/ambient/locomotion/perch/wire-perch.ts b/src/ambient/locomotion/perch/wire-perch.ts index 80ce9ae25..460336904 100644 --- a/src/ambient/locomotion/perch/wire-perch.ts +++ b/src/ambient/locomotion/perch/wire-perch.ts @@ -1,3 +1,4 @@ +/** Percher and jumper start and teardown. */ import type { FallConfig, JumpConfig, diff --git a/src/ambient/locomotion/travel/wire-travel-frame.ts b/src/ambient/locomotion/travel/wire-travel-frame.ts index 423a27fb5..b2140d13e 100644 --- a/src/ambient/locomotion/travel/wire-travel-frame.ts +++ b/src/ambient/locomotion/travel/wire-travel-frame.ts @@ -1,3 +1,4 @@ +/** Real-window travel frame wiring. */ import { type PetWindow, type ScreenMonitor, diff --git a/src/ambient/locomotion/walk/wire-walk.ts b/src/ambient/locomotion/walk/wire-walk.ts index 51fdcc987..7d76f6e75 100644 --- a/src/ambient/locomotion/walk/wire-walk.ts +++ b/src/ambient/locomotion/walk/wire-walk.ts @@ -1,3 +1,4 @@ +/** Walker start and teardown, and the reflex-turn stroll cancel. */ import type { DescendConfig, WalkConfig } from "../../../config/validators/avatar/types"; import type { MotionKind } from "../../../contract"; import { isReflexTurn } from "../../../dispatcher/backend/backend-caller"; diff --git a/src/app/bootstrap-configured.ts b/src/app/bootstrap-configured.ts index 7819740cf..b2b409ca5 100644 --- a/src/app/bootstrap-configured.ts +++ b/src/app/bootstrap-configured.ts @@ -1,3 +1,4 @@ +/** Pet window's config-derived bootstrap: runs the turn core and the pet-only wirings in order and drains their teardowns. */ import type { Tier1Engine } from "../ambient/liveliness/tier1"; import type { Sitter } from "../ambient/locomotion/sitter"; import type { ThreadReactionDeps } from "../ambient/threads-reaction/thread-reaction"; diff --git a/src/app/controls/wire-devtools-request.ts b/src/app/controls/wire-devtools-request.ts index f9044dd9f..b034d7013 100644 --- a/src/app/controls/wire-devtools-request.ts +++ b/src/app/controls/wire-devtools-request.ts @@ -1,3 +1,4 @@ +/** Main's pet window opens Developer Tools when the settings window asks. */ import type { SettingsBridge } from "../../io/bridge/settings-bridge"; /** Main's pet window opens Developer Tools when the settings window asks; a bound window never listens. */ diff --git a/src/app/cross-window/wire-cross-window.ts b/src/app/cross-window/wire-cross-window.ts index 5ce7abe1f..1a6d7404a 100644 --- a/src/app/cross-window/wire-cross-window.ts +++ b/src/app/cross-window/wire-cross-window.ts @@ -1,3 +1,4 @@ +/** Per-window sync for the pet, settings, and devtools windows. */ import type { SettingsBridge } from "../../io/bridge/settings-bridge"; import type { Logger } from "../../logger"; import type { Renderer } from "../../renderer"; diff --git a/src/app/cross-window/wire-window-sync.ts b/src/app/cross-window/wire-window-sync.ts index 6d2cf1ed5..51be09b1a 100644 --- a/src/app/cross-window/wire-window-sync.ts +++ b/src/app/cross-window/wire-window-sync.ts @@ -1,3 +1,4 @@ +/** Settings broadcast, guardrail overrides, and the shared cross-window sync core. */ import type { Guardrails, GuardrailsConfig } from "../../dispatcher/core/guardrails"; import type { createVrmSelection } from "../../io/assets/vrm-selection"; import type { WindowKind } from "../../io/bridge/core/bridge-core"; diff --git a/src/app/csp-violation.ts b/src/app/csp-violation.ts index 7c140c848..d457d3219 100644 --- a/src/app/csp-violation.ts +++ b/src/app/csp-violation.ts @@ -1,3 +1,4 @@ +/** Logs every Content-Security-Policy violation the window reports. */ import { createLogger } from "../logger"; const log = createLogger("csp-violation"); diff --git a/src/app/dev/wire-dev-globals.ts b/src/app/dev/wire-dev-globals.ts index bd674a01b..163d48b1c 100644 --- a/src/app/dev/wire-dev-globals.ts +++ b/src/app/dev/wire-dev-globals.ts @@ -1,3 +1,4 @@ +/** The DEV console and global handles for inspection and firing dispatcher events. */ import type { Tier1Engine } from "../../ambient/liveliness/tier1"; import type { WindowRect } from "../../contract"; import type { EventBus } from "../../dispatcher/core/event-bus"; diff --git a/src/app/message/wire-message-surface-ops.ts b/src/app/message/wire-message-surface-ops.ts index cd8e4415a..0985241db 100644 --- a/src/app/message/wire-message-surface-ops.ts +++ b/src/app/message/wire-message-surface-ops.ts @@ -1,3 +1,4 @@ +/** Draws each surface op from the pet window onto the surfaces, which the plate follows. */ import type { MessageBridge } from "../../io/bridge/message/message-bridge"; import { receiveSurfaceOp, type SurfacePort } from "../../io/bridge/message/surface-ops"; import { focusWindow } from "../../io/window/geometry/companion-column"; diff --git a/src/app/pet-windows/wire-preset-ids-sync.ts b/src/app/pet-windows/wire-preset-ids-sync.ts index c7c6d99db..a9ecae150 100644 --- a/src/app/pet-windows/wire-preset-ids-sync.ts +++ b/src/app/pet-windows/wire-preset-ids-sync.ts @@ -1,3 +1,4 @@ +/** Main publishes the registry's preset ids to the shell, so a prefixed ingress route can tell a closed window from an unknown id. */ import { syncPresetIds } from "../../io/bridge/inbox/preset-ids"; import type { Logger } from "../../logger"; import type { PresetRegistry } from "../../settings/preset/preset-registry"; diff --git a/src/app/settings-window/edit-target-url.ts b/src/app/settings-window/edit-target-url.ts index bc01cb73b..129b9fe7d 100644 --- a/src/app/settings-window/edit-target-url.ts +++ b/src/app/settings-window/edit-target-url.ts @@ -1,3 +1,4 @@ +/** The settings URL with its `edit` param set to the picked preset, or dropped for the window's own, and its `page` and `focus` params set to the requested page and field. */ import type { PageRequest } from "../../settings/panels/settings-pages"; /** The settings window's URL editing preset `id`, landing on the requested page and focus when given; the `edit` param drops when `id` is the window's own preset. */ diff --git a/src/app/settings-window/wire-settings-page.ts b/src/app/settings-window/wire-settings-page.ts index 394916bee..3b1c08973 100644 --- a/src/app/settings-window/wire-settings-page.ts +++ b/src/app/settings-window/wire-settings-page.ts @@ -1,3 +1,4 @@ +/** Takes the URL's page and focus, and answers an opener's page request: switches to the opener's character, then selects the page and focuses the field it names. */ import type { EndpointsConfig } from "../../contract"; import { isChatConfigured } from "../../dispatcher/backend/backend-caller"; import type { SettingsBridge } from "../../io/bridge/settings-bridge"; diff --git a/src/app/settings-window/wire-settings-window.ts b/src/app/settings-window/wire-settings-window.ts index bbd3c81a1..718a1fdce 100644 --- a/src/app/settings-window/wire-settings-window.ts +++ b/src/app/settings-window/wire-settings-window.ts @@ -1,3 +1,4 @@ +/** Stores, config, cross-window sync, and the settings panel remounted on locale change, bound to the query's preset when it names one, and editing the preset `?edit=` names. */ import { CHAT_API_KEY_SECRET, STT_API_KEY_SECRET } from "../../config/secrets"; import { importVrmFromFile, removeUserVrm } from "../../io/assets/vrm-import"; import { createDelegationHistory } from "../../io/bridge/delegations/delegation-history"; diff --git a/src/app/settings-window/wire-voice-mirror.ts b/src/app/settings-window/wire-voice-mirror.ts index 75ecba59e..506d03d59 100644 --- a/src/app/settings-window/wire-voice-mirror.ts +++ b/src/app/settings-window/wire-voice-mirror.ts @@ -1,3 +1,4 @@ +/** Mirrors the voice toggle to the pet window and the pet window's voice state back; main only. */ import type { SettingsBridge } from "../../io/bridge/settings-bridge"; import type { VoiceInputState } from "../../io/voice/stt-vad"; import type { VoiceInputStatus } from "../../ui/chips/voice-input-status"; diff --git a/src/app/settings/config-defaults.ts b/src/app/settings/config-defaults.ts index 3566e3a51..23f0f3485 100644 --- a/src/app/settings/config-defaults.ts +++ b/src/app/settings/config-defaults.ts @@ -1,3 +1,4 @@ +/** The quick-controls getters over the bundled config, shared by the pet and settings windows. */ import type { ConfigStore } from "../../config/store"; import { agentTriggerableMotionIds } from "../../io/chat/vocabulary/express-vocabulary"; import { endpointDefaultsOf } from "../../settings/backend/endpoints-settings"; diff --git a/src/app/settings/conversation-stores.ts b/src/app/settings/conversation-stores.ts index c7ae1781f..7724f45ca 100644 --- a/src/app/settings/conversation-stores.ts +++ b/src/app/settings/conversation-stores.ts @@ -1,3 +1,4 @@ +/** Constructs the shared io/chat conversation stores each window owns and disposes. */ import { createChatHistoryStore, localStorageChatHistoryStorage, diff --git a/src/app/settings/window-stores.ts b/src/app/settings/window-stores.ts index f2802a6b8..4ad9d203e 100644 --- a/src/app/settings/window-stores.ts +++ b/src/app/settings/window-stores.ts @@ -1,3 +1,4 @@ +/** Creates the settings and conversation store bags and the preset registry of the pet and settings windows and registers each store's teardown. */ import { createPetWindows, type PetWindows } from "../../settings/preset/pet-windows"; import { createPresetRegistry, type PresetRegistry } from "../../settings/preset/preset-registry"; import { createSettingsStores } from "../../settings/settings-stores"; diff --git a/src/app/settings/wire-cue-locale-sync.ts b/src/app/settings/wire-cue-locale-sync.ts index a3dd1df97..c31944cf8 100644 --- a/src/app/settings/wire-cue-locale-sync.ts +++ b/src/app/settings/wire-cue-locale-sync.ts @@ -1,3 +1,4 @@ +/** Reseeds untouched built-in cues when the display language changes. */ import { getLocale, type Locale, subscribe as subscribeLocale } from "../../ui/i18n"; interface CueLocaleStore { diff --git a/src/app/signal-chips/wire-signal-chips.ts b/src/app/signal-chips/wire-signal-chips.ts index e15ff5cc1..8cac656fa 100644 --- a/src/app/signal-chips/wire-signal-chips.ts +++ b/src/app/signal-chips/wire-signal-chips.ts @@ -1,3 +1,4 @@ +/** The signal chips on every transport, sharing the delegation chip's fold store. */ import type { SignalGroup } from "../../contract"; import type { SignalRecord } from "../../io/chat/conversation/signal-history-store"; import { diff --git a/src/app/stage/stage-renderer.ts b/src/app/stage/stage-renderer.ts index b8be04469..7e2238568 100644 --- a/src/app/stage/stage-renderer.ts +++ b/src/app/stage/stage-renderer.ts @@ -1,3 +1,4 @@ +/** The renderer on the stage with its persisted camera and idle throttle, plus Tier 1 liveliness, for the pet window. */ import { createTier1Engine, type Tier1Engine } from "../../ambient/liveliness/tier1"; import { createRenderer, type Renderer } from "../../renderer"; import type { SettingsStores } from "../../settings/settings-stores"; diff --git a/src/app/stage/wire-summon.ts b/src/app/stage/wire-summon.ts index 350d42afa..ab6ef5452 100644 --- a/src/app/stage/wire-summon.ts +++ b/src/app/stage/wire-summon.ts @@ -1,3 +1,4 @@ +/** Peek state and exit triggers, tray summon, and the global summon hotkey. */ import type { EventBus } from "../../dispatcher/core/event-bus"; import { createPeekState, type PeekState } from "../../io/window/pet/peek-state"; import { createSummonHotkey, type SummonHotkey } from "../../io/window/pet/summon-hotkey"; diff --git a/src/app/stage/wire-window-sources.ts b/src/app/stage/wire-window-sources.ts index 8dc02ddbe..0960dad55 100644 --- a/src/app/stage/wire-window-sources.ts +++ b/src/app/stage/wire-window-sources.ts @@ -1,3 +1,4 @@ +/** The Tauri window drop and resize sources, the avatar RPC executor, and keep-on-screen. */ import type { GestureCuesConfig, PeekConfig } from "../../config/validators/avatar/types"; import type { Posture, WindowRect } from "../../contract"; import type { EventBus } from "../../dispatcher/core/event-bus"; diff --git a/src/app/turn/push/ask-session.ts b/src/app/turn/push/ask-session.ts index a7a7a8fea..a1a830cf7 100644 --- a/src/app/turn/push/ask-session.ts +++ b/src/app/turn/push/ask-session.ts @@ -1,3 +1,4 @@ +/** The push socket's Asks fed into the window's Ask queue and their Answers sent back. */ import type { AskAnswer } from "../../../io/chat/push/push-frames"; import type { PushSocket } from "../../../io/chat/push/push-socket"; import type { AskOwner, AskQueue } from "../ask-queue"; diff --git a/src/app/turn/push/delegation-chip-mount.ts b/src/app/turn/push/delegation-chip-mount.ts index 51811d203..3a738c6c1 100644 --- a/src/app/turn/push/delegation-chip-mount.ts +++ b/src/app/turn/push/delegation-chip-mount.ts @@ -1,3 +1,4 @@ +/** The delegation chip's lazy mount and its suppression port. */ import type { DelegationsStore } from "../../../io/bridge/delegations/delegations-store"; import type { PushSocket } from "../../../io/chat/push/push-socket"; import { diff --git a/src/app/turn/push/playback.ts b/src/app/turn/push/playback.ts index 0320f6d25..d873197b7 100644 --- a/src/app/turn/push/playback.ts +++ b/src/app/turn/push/playback.ts @@ -1,3 +1,4 @@ +/** Reports a failed turn's end to the push socket as a playback frame. */ import type { PreviousTurnSlot } from "../../../dispatcher/backend/previous-turn"; import type { PushSocket } from "../../../io/chat/push/push-socket"; diff --git a/src/app/turn/push/push-stores.ts b/src/app/turn/push/push-stores.ts index 804c543d3..86b8eba95 100644 --- a/src/app/turn/push/push-stores.ts +++ b/src/app/turn/push/push-stores.ts @@ -1,3 +1,4 @@ +/** The push socket, its chat id, and the delegations and reasoning stores its frames feed. */ import type { EndpointsConfig } from "../../../contract"; import { createDelegationHistory, diff --git a/src/app/turn/push/wire-backend-commands.ts b/src/app/turn/push/wire-backend-commands.ts index ac782f3e6..5b712cac0 100644 --- a/src/app/turn/push/wire-backend-commands.ts +++ b/src/app/turn/push/wire-backend-commands.ts @@ -1,3 +1,4 @@ +/** The push socket's backend commands into the surfaces: the list, a send's pending reply card, and the settled text. */ import type { PushSocket } from "../../../io/chat/push/push-socket"; import { createLogger } from "../../../logger"; import { t } from "../../../ui/i18n"; diff --git a/src/app/turn/push/wire-push.ts b/src/app/turn/push/wire-push.ts index 14bedeab8..20426f685 100644 --- a/src/app/turn/push/wire-push.ts +++ b/src/app/turn/push/wire-push.ts @@ -1,3 +1,4 @@ +/** Push socket frames into turns, the stop button, and the push mode chip. */ import type { EndpointsConfig, Usage } from "../../../contract"; import type { PushTurns } from "../../../dispatcher/turn/push-turn"; import { createRenderTurn } from "../../../dispatcher/turn/render-turn"; diff --git a/src/app/turn/turn-core.ts b/src/app/turn/turn-core.ts index 0363ebcb1..371fe3511 100644 --- a/src/app/turn/turn-core.ts +++ b/src/app/turn/turn-core.ts @@ -1,3 +1,4 @@ +/** The chat turn every backend-facing window runs: voice, dispatcher, STT, VRM load, vocabulary, push transport, stop, and submit. */ import type { AppConfig } from "../../config/load"; import type { ConfigStore } from "../../config/store"; import type { EndpointsConfig, Usage } from "../../contract"; diff --git a/src/app/turn/vocabulary/wire-vocabulary.ts b/src/app/turn/vocabulary/wire-vocabulary.ts index a1a421773..936354926 100644 --- a/src/app/turn/vocabulary/wire-vocabulary.ts +++ b/src/app/turn/vocabulary/wire-vocabulary.ts @@ -1,3 +1,4 @@ +/** The emotion_text table load, the derived vocabulary, and its change announcements. */ import { loadEmotionTextTable } from "../../../config/emotion-text"; import type { AppConfig, ConfigSection } from "../../../config/load"; import { ttsProviderOf } from "../../../config/tts-provider"; diff --git a/src/app/turn/voice/speak-turn.ts b/src/app/turn/voice/speak-turn.ts index e37740693..7ed7346c6 100644 --- a/src/app/turn/voice/speak-turn.ts +++ b/src/app/turn/voice/speak-turn.ts @@ -1,3 +1,4 @@ +/** The speech turn behind TurnOutput: thinking guard and motion hold, filler availability, failure asides, barge-in. */ import type { FillerPool } from "../../../config/validators/filler"; import type { TurnFailure } from "../../../dispatcher/backend/backend-caller"; import type { TurnOutput } from "../../../dispatcher/turn/turn-output"; diff --git a/src/app/turn/voice/unified-voice.ts b/src/app/turn/voice/unified-voice.ts index d8c891058..eaed2dedc 100644 --- a/src/app/turn/voice/unified-voice.ts +++ b/src/app/turn/voice/unified-voice.ts @@ -1,3 +1,4 @@ +/** Main's speech while the unified chat window shows, and the user speaking answered like a stop. */ import { createLogger } from "../../../logger"; const log = createLogger("unified-voice"); diff --git a/src/app/turn/voice/wire-voice-pipeline.ts b/src/app/turn/voice/wire-voice-pipeline.ts index 8920d9311..baad8ebca 100644 --- a/src/app/turn/voice/wire-voice-pipeline.ts +++ b/src/app/turn/voice/wire-voice-pipeline.ts @@ -1,3 +1,4 @@ +/** Wires filler, TTS, and speech playback to the turn lifecycle. */ import type { AppConfig } from "../../../config/load"; import type { EndpointsConfig, UtteranceIdentity } from "../../../contract"; import type { TurnFailure } from "../../../dispatcher/backend/backend-caller"; diff --git a/src/app/turn/voice/wire-voice.ts b/src/app/turn/voice/wire-voice.ts index 066dddcdb..bc6ed33ac 100644 --- a/src/app/turn/voice/wire-voice.ts +++ b/src/app/turn/voice/wire-voice.ts @@ -1,3 +1,4 @@ +/** The voice-input and turn-voice wiring; a bound window builds no capture. */ import type { AppConfig } from "../../../config/load"; import { STT_API_KEY_SECRET, TTS_API_KEY_SECRET } from "../../../config/secrets"; import type { AttachedThread, EndpointsConfig, UtteranceIdentity } from "../../../contract"; diff --git a/src/app/turn/wire-sources.ts b/src/app/turn/wire-sources.ts index 26deabb7d..c3e2c8135 100644 --- a/src/app/turn/wire-sources.ts +++ b/src/app/turn/wire-sources.ts @@ -1,3 +1,4 @@ +/** The dispatcher's utterance sources, built and started. */ import type { ScreenConfig } from "../../config/validators/screen"; import type { SignalGroup } from "../../contract"; import type { EventBus } from "../../dispatcher/core/event-bus"; diff --git a/src/app/unified/wire-unified-close.ts b/src/app/unified/wire-unified-close.ts index 5752e31e4..2f1101714 100644 --- a/src/app/unified/wire-unified-close.ts +++ b/src/app/unified/wire-unified-close.ts @@ -1,3 +1,4 @@ +/** The window closing itself turns the Unified chat switch off. */ import { createLogger } from "../../logger"; import type { FlagSettingsStore } from "../../settings/persisted-store"; diff --git a/src/app/unified/wire-unified-window.ts b/src/app/unified/wire-unified-window.ts index 37ae24474..68c23d059 100644 --- a/src/app/unified/wire-unified-window.ts +++ b/src/app/unified/wire-unified-window.ts @@ -1,3 +1,4 @@ +/** Main opens the window while it shows and destroys it otherwise. */ import type { UnifiedShown } from "../../settings/unified/unified-shown"; /** Main opens the unified chat window while it is shown, and closes it otherwise. */ diff --git a/src/config/tts-provider.ts b/src/config/tts-provider.ts index ec6dd8b4a..3164f3c1d 100644 --- a/src/config/tts-provider.ts +++ b/src/config/tts-provider.ts @@ -1,3 +1,4 @@ +/** The tts_provider values and the Irodori default for an unset one. */ import type { EndpointsConfig, TtsProviderName } from "../contract"; /** Every value `tts_provider` accepts. */ diff --git a/src/config/validators/avatar/available.ts b/src/config/validators/avatar/available.ts index 96d9fe251..987d1bcf4 100644 --- a/src/config/validators/avatar/available.ts +++ b/src/config/validators/avatar/available.ts @@ -1,3 +1,4 @@ +/** The available VRM manifest. */ import { isObject } from "../shared"; import type { SectionContext } from "./helpers"; import type { AvatarOption } from "./types"; diff --git a/src/config/validators/avatar/climb.ts b/src/config/validators/avatar/climb.ts index 414996804..927d5fd25 100644 --- a/src/config/validators/avatar/climb.ts +++ b/src/config/validators/avatar/climb.ts @@ -1,3 +1,4 @@ +/** Ambient window climb. */ import { isObject } from "../shared"; import { int, nonNegative, num, positive, requireOrder, type SectionContext } from "./helpers"; import type { ClimbConfig } from "./types"; diff --git a/src/config/validators/avatar/fall.ts b/src/config/validators/avatar/fall.ts index 8ae2181ad..76606c4fa 100644 --- a/src/config/validators/avatar/fall.ts +++ b/src/config/validators/avatar/fall.ts @@ -1,3 +1,4 @@ +/** Drag-release fall and monitor descent. */ import { isObject } from "../shared"; import { int, nonNegative, num, positive, type SectionContext, unit } from "./helpers"; import type { DescendConfig, FallConfig } from "./types"; diff --git a/src/config/validators/avatar/framing.ts b/src/config/validators/avatar/framing.ts index 8a801d427..4e0e952da 100644 --- a/src/config/validators/avatar/framing.ts +++ b/src/config/validators/avatar/framing.ts @@ -1,3 +1,4 @@ +/** The fit-to-bounds camera. */ import { isObject } from "../shared"; import { nonNegative, num, type SectionContext } from "./helpers"; import type { FramingConfig } from "./types"; diff --git a/src/config/validators/avatar/gaze.ts b/src/config/validators/avatar/gaze.ts index a5475e099..fa9200b8e 100644 --- a/src/config/validators/avatar/gaze.ts +++ b/src/config/validators/avatar/gaze.ts @@ -1,3 +1,4 @@ +/** Cursor tracking angles and damping. */ import { isObject } from "../shared"; import { num, type SectionContext } from "./helpers"; import type { GazeKnobs } from "./types"; diff --git a/src/config/validators/avatar/gestures.ts b/src/config/validators/avatar/gestures.ts index 2392ccd5d..41797230d 100644 --- a/src/config/validators/avatar/gestures.ts +++ b/src/config/validators/avatar/gestures.ts @@ -1,3 +1,4 @@ +/** Drag-hold duration and gesture cues. */ import { isObject } from "../shared"; import { cue, rejectUnknownKeys, type SectionContext } from "./helpers"; import type { GestureCuesConfig } from "./types"; diff --git a/src/config/validators/avatar/helpers.ts b/src/config/validators/avatar/helpers.ts index 69f30855d..3809acdb8 100644 --- a/src/config/validators/avatar/helpers.ts +++ b/src/config/validators/avatar/helpers.ts @@ -1,3 +1,4 @@ +/** Shared issue-recording field readers and unknown-key check. */ import type { GestureCueConfig } from "./types"; /** What every section validator receives besides its raw input. */ diff --git a/src/config/validators/avatar/hit-test.ts b/src/config/validators/avatar/hit-test.ts index db6fc37cf..0eae6a7aa 100644 --- a/src/config/validators/avatar/hit-test.ts +++ b/src/config/validators/avatar/hit-test.ts @@ -1,3 +1,4 @@ +/** Click-through polling and the alpha cut. */ import { isObject } from "../shared"; import { int, nonNegative, num, positive, type SectionContext } from "./helpers"; import type { HitTestKnobs } from "./types"; diff --git a/src/config/validators/avatar/index.ts b/src/config/validators/avatar/index.ts index 455ac3c16..6c8dad2ac 100644 --- a/src/config/validators/avatar/index.ts +++ b/src/config/validators/avatar/index.ts @@ -1,3 +1,4 @@ +/** Router: the early throws, section calls in order, and the result. */ import { assertValid, ConfigError, isObject } from "../shared"; import { validateAvailable } from "./available"; import { validateClimb } from "./climb"; diff --git a/src/config/validators/avatar/jump.ts b/src/config/validators/avatar/jump.ts index 3d898e3df..7262460bc 100644 --- a/src/config/validators/avatar/jump.ts +++ b/src/config/validators/avatar/jump.ts @@ -1,3 +1,4 @@ +/** Window-to-window flight. */ import { isObject } from "../shared"; import { int, num, positive, type SectionContext, unit } from "./helpers"; import type { JumpConfig } from "./types"; diff --git a/src/config/validators/avatar/peek.ts b/src/config/validators/avatar/peek.ts index 2649d3191..cc2e9ce83 100644 --- a/src/config/validators/avatar/peek.ts +++ b/src/config/validators/avatar/peek.ts @@ -1,3 +1,4 @@ +/** Side-peek geometry. */ import { isObject } from "../shared"; import { num, type SectionContext, unit } from "./helpers"; import type { PeekConfig } from "./types"; diff --git a/src/config/validators/avatar/stage.ts b/src/config/validators/avatar/stage.ts index 017d3aff2..72fbbd356 100644 --- a/src/config/validators/avatar/stage.ts +++ b/src/config/validators/avatar/stage.ts @@ -1,3 +1,4 @@ +/** The avatar config's stage section validator: her travel onto the settings stage, entry families, and edge entries. */ import { isObject } from "../shared"; import { nonNegative, num, positive, type SectionContext, unit } from "./helpers"; import type { EdgeEntry, EntryFamily, StageConfig } from "./types"; diff --git a/src/config/validators/avatar/tap.ts b/src/config/validators/avatar/tap.ts index a5f0ed248..9787f9deb 100644 --- a/src/config/validators/avatar/tap.ts +++ b/src/config/validators/avatar/tap.ts @@ -1,3 +1,4 @@ +/** Tap regions and touch cues. */ import { isObject } from "../shared"; import { cue, int, nonNegative, num, rejectUnknownKeys, type SectionContext, str } from "./helpers"; import type { TapConfig } from "./types"; diff --git a/src/config/validators/avatar/walk.ts b/src/config/validators/avatar/walk.ts index 11f91badc..0df0d58fe 100644 --- a/src/config/validators/avatar/walk.ts +++ b/src/config/validators/avatar/walk.ts @@ -1,3 +1,4 @@ +/** Floor stroll and window-top stroll. */ import { isObject } from "../shared"; import { int, diff --git a/src/config/validators/emotion-registry.ts b/src/config/validators/emotion-registry.ts index 05103d42b..a370e591c 100644 --- a/src/config/validators/emotion-registry.ts +++ b/src/config/validators/emotion-registry.ts @@ -1,3 +1,4 @@ +/** Validates the emotion registry against the emotion enum. */ import type { EmotionId, EmotionRegistry, EmotionRegistryEntry } from "../../contract"; import { assertValid, ConfigError, isObject } from "./shared"; diff --git a/src/config/validators/endpoints.ts b/src/config/validators/endpoints.ts index 543384191..ae9dba468 100644 --- a/src/config/validators/endpoints.ts +++ b/src/config/validators/endpoints.ts @@ -1,3 +1,4 @@ +/** Validates endpoint URLs and models; an empty value leaves the feature off. */ import type { EndpointsConfig, TtsProviderName } from "../../contract"; import { TTS_PROVIDERS } from "../tts-provider"; import { assertValid, ConfigError, isObject } from "./shared"; diff --git a/src/config/validators/filler.ts b/src/config/validators/filler.ts index 64c94a46c..7ef2f0600 100644 --- a/src/config/validators/filler.ts +++ b/src/config/validators/filler.ts @@ -1,3 +1,4 @@ +/** The filler.json phrase-pool and loop-timing types and their validation. */ import { assertValid, ConfigError, isObject } from "./shared"; /** TTFT filler language — closed union, never crosses the backend wire. */ diff --git a/src/config/validators/guardrails.ts b/src/config/validators/guardrails.ts index 5b0ca306e..2663e4805 100644 --- a/src/config/validators/guardrails.ts +++ b/src/config/validators/guardrails.ts @@ -1,3 +1,4 @@ +/** The guardrails.json debounce, rate-limit, and attachment-cap types and their validation. */ import { assertValid, ConfigError, isObject } from "./shared"; /** Attach-time caps on one turn's image attachments. */ diff --git a/src/config/validators/hotkeys.ts b/src/config/validators/hotkeys.ts index f8f4684de..6d7146dbf 100644 --- a/src/config/validators/hotkeys.ts +++ b/src/config/validators/hotkeys.ts @@ -1,3 +1,4 @@ +/** The hotkeys.json summon-accelerator type and its validation. */ import { assertValid, ConfigError, isObject } from "./shared"; /** configs/hotkeys.json — OS global-hotkey accelerators. */ diff --git a/src/config/validators/motions.ts b/src/config/validators/motions.ts index eca4eb230..fe5fd0dc3 100644 --- a/src/config/validators/motions.ts +++ b/src/config/validators/motions.ts @@ -1,3 +1,4 @@ +/** Validates the motion registry. */ import type { InterruptPolicy, MotionKind, diff --git a/src/config/validators/persona/persona.ts b/src/config/validators/persona/persona.ts index 0373b5a70..a26bf8279 100644 --- a/src/config/validators/persona/persona.ts +++ b/src/config/validators/persona/persona.ts @@ -1,3 +1,4 @@ +/** The persona.json card, framing sentence, and user fallback validation. */ import { assertValid, ConfigError, isObject } from "../shared"; import { readCard } from "./read-card"; import { type Card, EMPTY_CARD, type Locale, type PersonaConfig } from "./types"; diff --git a/src/config/validators/persona/read-card.ts b/src/config/validators/persona/read-card.ts index 2adcef16b..ff23be274 100644 --- a/src/config/validators/persona/read-card.ts +++ b/src/config/validators/persona/read-card.ts @@ -1,3 +1,4 @@ +/** The V1, V2, and V3 card reader with its issues. */ import { isObject } from "../shared"; import { CARD_FIELD_MAX_LEN, CARD_TEXT_FIELDS, type Card, EMPTY_CARD } from "./types"; diff --git a/src/config/validators/screen.ts b/src/config/validators/screen.ts index 5918a855d..ea84fe125 100644 --- a/src/config/validators/screen.ts +++ b/src/config/validators/screen.ts @@ -1,3 +1,4 @@ +/** The screen.json type and the validation of its frontmost-transition thresholds. */ import { assertValid, ConfigError, isObject } from "./shared"; /** diff --git a/src/dispatcher/backend/context-builder.ts b/src/dispatcher/backend/context-builder.ts index 67cedd357..b2fc9f0c8 100644 --- a/src/dispatcher/backend/context-builder.ts +++ b/src/dispatcher/backend/context-builder.ts @@ -1,3 +1,4 @@ +/** Builds the per-turn client context, with waited items and the do-not-disturb line, and image attachments. */ import type { AttachedThread, BodyState, diff --git a/src/dispatcher/backend/previous-turn.ts b/src/dispatcher/backend/previous-turn.ts index 4cfcc5ea6..e03e620e1 100644 --- a/src/dispatcher/backend/previous-turn.ts +++ b/src/dispatcher/backend/previous-turn.ts @@ -1,3 +1,4 @@ +/** Persisted record of how the last turn that tried to speak ended. */ import { BACKEND_EVENT_NAME, type PreviousTurn, diff --git a/src/dispatcher/core/turn-gate.ts b/src/dispatcher/core/turn-gate.ts index 562b54b8e..9ffabbdb0 100644 --- a/src/dispatcher/core/turn-gate.ts +++ b/src/dispatcher/core/turn-gate.ts @@ -1,3 +1,4 @@ +/** The cross-window Web Lock a turn holds from its backend call to the end of its playback. */ import { createExclusiveHold, type ExclusiveHold } from "../../io/locks/exclusive-hold"; import type { Logger } from "../../logger"; import { createLogger } from "../../logger"; diff --git a/src/dispatcher/sources/gesture/tap-source.ts b/src/dispatcher/sources/gesture/tap-source.ts index 2fac06a50..95f55f4ec 100644 --- a/src/dispatcher/sources/gesture/tap-source.ts +++ b/src/dispatcher/sources/gesture/tap-source.ts @@ -1,3 +1,4 @@ +/** Turns taps on the character into bus envelopes. */ import type { TapConfig } from "../../../config/validators/avatar/types"; import type { SignalGroup } from "../../../contract"; import { createLogger } from "../../../logger"; diff --git a/src/dispatcher/turn/turn-output.ts b/src/dispatcher/turn/turn-output.ts index 8cb493461..26f7ec0f3 100644 --- a/src/dispatcher/turn/turn-output.ts +++ b/src/dispatcher/turn/turn-output.ts @@ -1,3 +1,4 @@ +/** Speech lifecycle port between the backend caller and the voice pipeline. */ import type { ExpressArgs, ToolStatus, UtteranceIdentity } from "../../contract"; /** diff --git a/src/io/assets/card/photo-size.ts b/src/io/assets/card/photo-size.ts index 90d9db532..c34563f43 100644 --- a/src/io/assets/card/photo-size.ts +++ b/src/io/assets/card/photo-size.ts @@ -1,3 +1,4 @@ +/** The natural size of a photo, read by decoding it. */ import type { PhotoSize } from "../../../settings/preset/photo-crop"; /** The natural size of the image at `url`; rejects when it cannot be decoded. */ diff --git a/src/io/bridge/inbox/create-inbox.ts b/src/io/bridge/inbox/create-inbox.ts index 3bea592e5..4ceef0e2f 100644 --- a/src/io/bridge/inbox/create-inbox.ts +++ b/src/io/bridge/inbox/create-inbox.ts @@ -1,3 +1,4 @@ +/** Generic Tauri event-channel subscription seam. */ import type { Options } from "@tauri-apps/api/event"; import { createLogger } from "../../../logger"; import { isTauri } from "../../../tauri-env"; diff --git a/src/io/chat/card/assemble-card.ts b/src/io/chat/card/assemble-card.ts index baf9f403f..bf9b05a0e 100644 --- a/src/io/chat/card/assemble-card.ts +++ b/src/io/chat/card/assemble-card.ts @@ -1,3 +1,4 @@ +/** The first system message and the post-history text, with {{char}}, {{user}}, {{original}}. */ import type { Card } from "../../../config/validators/persona/types"; interface MacroValues { diff --git a/src/io/chat/card/perform-greeting.ts b/src/io/chat/card/perform-greeting.ts index de1afed79..ef0717a8d 100644 --- a/src/io/chat/card/perform-greeting.ts +++ b/src/io/chat/card/perform-greeting.ts @@ -1,3 +1,4 @@ +/** Speaks a card greeting into the transcript at a session reset. */ import type { Card } from "../../../config/validators/persona/types"; import type { UtteranceIdentity } from "../../../contract"; import type { createChatHistoryStore } from "../conversation/chat-history-store"; diff --git a/src/io/chat/card/pick-greeting.ts b/src/io/chat/card/pick-greeting.ts index 0c4d0530f..6662fb930 100644 --- a/src/io/chat/card/pick-greeting.ts +++ b/src/io/chat/card/pick-greeting.ts @@ -1,3 +1,4 @@ +/** One of the card's greetings at random. */ import type { Card } from "../../../config/validators/persona/types"; /** One of the card's non-empty greetings at random, as raw text; null when it has none. */ diff --git a/src/io/chat/card/resolve-card.ts b/src/io/chat/card/resolve-card.ts index 2472abf6a..2c81ccc0f 100644 --- a/src/io/chat/card/resolve-card.ts +++ b/src/io/chat/card/resolve-card.ts @@ -1,3 +1,4 @@ +/** The preset's card and its effective name; null on push or with the switch off. */ import type { Card, Locale, PersonaConfig } from "../../../config/validators/persona/types"; import type { EndpointsConfig } from "../../../contract"; import type { AgentSettings } from "../../../settings/backend/agent-settings"; diff --git a/src/io/chat/conversation/context-history.ts b/src/io/chat/conversation/context-history.ts index ac6fb6162..3b558f01d 100644 --- a/src/io/chat/conversation/context-history.ts +++ b/src/io/chat/conversation/context-history.ts @@ -1,3 +1,4 @@ +/** Capped ring of recent client-context entries. */ import type { ClientContext } from "../../../contract"; import { createPersistedStore, diff --git a/src/io/chat/conversation/overheard/overheard-reader.ts b/src/io/chat/conversation/overheard/overheard-reader.ts index eacabedcb..5a872ff01 100644 --- a/src/io/chat/conversation/overheard/overheard-reader.ts +++ b/src/io/chat/conversation/overheard/overheard-reader.ts @@ -1,3 +1,4 @@ +/** Reads the lines other open presets exchanged since this window last heard them. */ import type { ClientContext } from "../../../../contract"; import type { ChatHistoryEntry } from "../chat-history-store"; import type { OverheardCursor, OverheardStore } from "./overheard-store"; diff --git a/src/io/chat/conversation/overheard/overheard-store.ts b/src/io/chat/conversation/overheard/overheard-store.ts index 60fe046ea..f8663e417 100644 --- a/src/io/chat/conversation/overheard/overheard-store.ts +++ b/src/io/chat/conversation/overheard/overheard-store.ts @@ -1,3 +1,4 @@ +/** Per other preset, the cursor up to which this window has heard its transcript. */ import { createPersistedStore, isPlainObject, diff --git a/src/io/chat/push/tool-results/encode.ts b/src/io/chat/push/tool-results/encode.ts index 821dd863b..afab13faa 100644 --- a/src/io/chat/push/tool-results/encode.ts +++ b/src/io/chat/push/tool-results/encode.ts @@ -1,3 +1,4 @@ +/** Text and image tool results within the push frame's byte cap. */ import { fitTurnImages } from "../fit-turn-images"; import type { ToolCallFrame, ToolResultFrame } from "../push-frames"; import { byteLength, PUSH_FRAME_MAX_BYTES } from "../push-socket"; diff --git a/src/io/chat/stream/chat-completions-stream.ts b/src/io/chat/stream/chat-completions-stream.ts index b79470912..655652d43 100644 --- a/src/io/chat/stream/chat-completions-stream.ts +++ b/src/io/chat/stream/chat-completions-stream.ts @@ -1,3 +1,4 @@ +/** Chat Completions streaming loop with its tool round trips. */ import type OpenAI from "openai"; import type { ChatCompletionChunk, diff --git a/src/io/chat/stream/stream-helpers.ts b/src/io/chat/stream/stream-helpers.ts index 6c7871575..fb5dd0b4f 100644 --- a/src/io/chat/stream/stream-helpers.ts +++ b/src/io/chat/stream/stream-helpers.ts @@ -1,3 +1,4 @@ +/** Express-tool and error helpers both streaming loops use. */ import type { ControlEnvelope, EmotionId, ExpressArgs } from "../../../contract"; export function isExpressTool(name: unknown): boolean { diff --git a/src/io/chat/stream/tool-results/chat-completions.ts b/src/io/chat/stream/tool-results/chat-completions.ts index 53fe24137..1501a1506 100644 --- a/src/io/chat/stream/tool-results/chat-completions.ts +++ b/src/io/chat/stream/tool-results/chat-completions.ts @@ -1,3 +1,4 @@ +/** Chat Completions tool messages, an image following in the next user message. */ import { type ClientToolResult, toolResultText } from "../../tools/client-tools"; import type { CCMessage } from "../chat-completions"; diff --git a/src/io/chat/stream/tool-results/responses.ts b/src/io/chat/stream/tool-results/responses.ts index d246cba7b..afc8d9f38 100644 --- a/src/io/chat/stream/tool-results/responses.ts +++ b/src/io/chat/stream/tool-results/responses.ts @@ -1,3 +1,4 @@ +/** Responses function-call output, with images as input_image items. */ import type { ResponseFunctionCallOutputItemList } from "openai/resources/responses/responses"; import type { ClientToolResult } from "../../tools/client-tools"; diff --git a/src/io/chat/tools/screen/screen-query.ts b/src/io/chat/tools/screen/screen-query.ts index 78aba30bc..3e00a5dd7 100644 --- a/src/io/chat/tools/screen/screen-query.ts +++ b/src/io/chat/tools/screen/screen-query.ts @@ -1,3 +1,4 @@ +/** Answers a screen query from the live monitors and a screenshot. */ import { physicalToLogicalScreenPoint, type ScreenPoint, diff --git a/src/io/chat/vocabulary/express-vocabulary.ts b/src/io/chat/vocabulary/express-vocabulary.ts index 8f12379e6..bddb4e1c7 100644 --- a/src/io/chat/vocabulary/express-vocabulary.ts +++ b/src/io/chat/vocabulary/express-vocabulary.ts @@ -1,3 +1,4 @@ +/** Derives the express vocabulary from the loaded config and the motion selection. */ import type { AppConfig } from "../../../config/load"; import type { MotionRegistry } from "../../../contract"; import { diff --git a/src/io/locks/fake-lock-manager.ts b/src/io/locks/fake-lock-manager.ts index b4e4ed09e..29a1eccc7 100644 --- a/src/io/locks/fake-lock-manager.ts +++ b/src/io/locks/fake-lock-manager.ts @@ -1,3 +1,4 @@ +/** The in-memory exclusive lock the gate tests share. */ import { vi } from "vitest"; type Options = { ifAvailable?: boolean; signal?: AbortSignal }; diff --git a/src/io/voice/tts/readings.ts b/src/io/voice/tts/readings.ts index 0e0721fda..c2328a602 100644 --- a/src/io/voice/tts/readings.ts +++ b/src/io/voice/tts/readings.ts @@ -1,3 +1,4 @@ +/** The surface=reading dictionary parser and its readings lookup. */ export type ReadingPair = [surface: string, reading: string]; /** One `surface=reading` pair per line; later duplicates win, longest surface first, bad lines numbered in `skipped`. */ diff --git a/src/io/voice/tts/voice-gate.ts b/src/io/voice/tts/voice-gate.ts index 2ecaa5292..2eca7c7a7 100644 --- a/src/io/voice/tts/voice-gate.ts +++ b/src/io/voice/tts/voice-gate.ts @@ -1,3 +1,4 @@ +/** One voice at a time across windows: the yui.speaking Web Lock. */ import { createExclusiveHold, type ExclusiveHold } from "../../locks/exclusive-hold"; /** One voice at a time across windows: an exclusive Web Lock held from an utterance's first sound to its end. */ diff --git a/src/io/window/capture/screen-point.ts b/src/io/window/capture/screen-point.ts index 5d61e9812..9be6aad7b 100644 --- a/src/io/window/capture/screen-point.ts +++ b/src/io/window/capture/screen-point.ts @@ -1,3 +1,4 @@ +/** A physical screen point as a logical one over a display's scale. */ export interface ScreenPoint { x: number; y: number; diff --git a/src/io/window/geometry/roomier-side.ts b/src/io/window/geometry/roomier-side.ts index b7886de74..3690d6bff 100644 --- a/src/io/window/geometry/roomier-side.ts +++ b/src/io/window/geometry/roomier-side.ts @@ -1,3 +1,4 @@ +/** Which side of her has more free room in the work area. */ import type { ScreenRect } from "../../../contract"; /** The side of her with more free room in the work area; the right wins a tie. */ diff --git a/src/io/window/openers/devtools-window.ts b/src/io/window/openers/devtools-window.ts index 0c5aa5c9b..1e953c1a9 100644 --- a/src/io/window/openers/devtools-window.ts +++ b/src/io/window/openers/devtools-window.ts @@ -1,3 +1,4 @@ +/** Developer Tools window opener. */ import { createLogger } from "../../../logger"; import { isTauri } from "../../../tauri-env"; diff --git a/src/io/window/openers/pet-window.ts b/src/io/window/openers/pet-window.ts index e9d8a3b3a..deb27b390 100644 --- a/src/io/window/openers/pet-window.ts +++ b/src/io/window/openers/pet-window.ts @@ -1,3 +1,4 @@ +/** Bound pet window opener: creates pet- and lists the windows that exist. */ import type { WebviewWindow } from "@tauri-apps/api/webviewWindow"; import type { BackgroundThrottlingPolicy } from "@tauri-apps/api/window"; import { createLogger } from "../../../logger"; diff --git a/src/io/window/own-origin-fetch.ts b/src/io/window/own-origin-fetch.ts index e84de2d2b..a7bca97a0 100644 --- a/src/io/window/own-origin-fetch.ts +++ b/src/io/window/own-origin-fetch.ts @@ -1,3 +1,4 @@ +/** Keeps each webview's own origin on native fetch instead of the CORS proxy. */ type CorsFetchPlugin = { config: (config: { exclude: RegExp[] }) => void }; /** Windows serves bundled assets from http://tauri.localhost, which the cors-fetch proxy can't reach, so same-origin requests stay native. */ diff --git a/src/io/window/pet/peek-state.ts b/src/io/window/pet/peek-state.ts index 10f9801ee..658b3eb0c 100644 --- a/src/io/window/pet/peek-state.ts +++ b/src/io/window/pet/peek-state.ts @@ -1,3 +1,4 @@ +/** Holds the current peek side and its lifecycle. */ import { createLogger } from "../../../logger"; const log = createLogger("peek-state"); diff --git a/src/logger.ts b/src/logger.ts index 15d1010f5..fa6478d70 100644 --- a/src/logger.ts +++ b/src/logger.ts @@ -1,3 +1,4 @@ +/** Namespaced frontend logger with a runtime level. */ import { isTauri } from "./tauri-env"; export type LogLevel = "debug" | "info" | "warn" | "error"; diff --git a/src/renderer/expression/gaze/bone-pitch.ts b/src/renderer/expression/gaze/bone-pitch.ts index a4caa9dc5..91cb32c50 100644 --- a/src/renderer/expression/gaze/bone-pitch.ts +++ b/src/renderer/expression/gaze/bone-pitch.ts @@ -1,3 +1,4 @@ +/** Sign that turns a downward head pitch into a normalized bone's local rotation.x. */ import type { VRM } from "@pixiv/three-vrm"; /** diff --git a/src/renderer/geometry/hit/tap-region.ts b/src/renderer/geometry/hit/tap-region.ts index 42a7e0d6c..bb08cd897 100644 --- a/src/renderer/geometry/hit/tap-region.ts +++ b/src/renderer/geometry/hit/tap-region.ts @@ -1,3 +1,4 @@ +/** Classifies a tap point into a body region. */ export type TapRegion = "head" | "chest" | "hips"; export type CssPoint = { x: number; y: number }; diff --git a/src/renderer/motion/clip/mirror-clip.ts b/src/renderer/motion/clip/mirror-clip.ts index 74d6437f9..2d0147623 100644 --- a/src/renderer/motion/clip/mirror-clip.ts +++ b/src/renderer/motion/clip/mirror-clip.ts @@ -1,3 +1,4 @@ +/** Mirrors a clip across the YZ plane. */ import type { AnimationClip } from "three"; /** Mirror a clip across the YZ plane and return a new clip. */ diff --git a/src/renderer/motion/clip/self-crossfade.ts b/src/renderer/motion/clip/self-crossfade.ts index bb2687452..eb1ca6c48 100644 --- a/src/renderer/motion/clip/self-crossfade.ts +++ b/src/renderer/motion/clip/self-crossfade.ts @@ -1,3 +1,4 @@ +/** Clip-cache key composition and playback clip selection. */ import type { AnimationClip } from "three"; /** diff --git a/src/renderer/motion/grounding/sole-offset.ts b/src/renderer/motion/grounding/sole-offset.ts index 2a2c78c85..c1b1ed0f8 100644 --- a/src/renderer/motion/grounding/sole-offset.ts +++ b/src/renderer/motion/grounding/sole-offset.ts @@ -1,3 +1,4 @@ +/** The signed Y offset that puts a VRM's lowest sole point on the floor. */ import type { VRM } from "@pixiv/three-vrm"; import * as THREE from "three"; import type { SoleBone } from "./sole-points"; diff --git a/src/renderer/motion/grounding/sole-points.ts b/src/renderer/motion/grounding/sole-points.ts index b685872a9..6e5e69cca 100644 --- a/src/renderer/motion/grounding/sole-points.ts +++ b/src/renderer/motion/grounding/sole-points.ts @@ -1,3 +1,4 @@ +/** Sole points per foot and toes bone, extracted from the skinned meshes in the rest pose. */ import type { VRM, VRMHumanBoneName } from "@pixiv/three-vrm"; import * as THREE from "three"; diff --git a/src/renderer/motion/playback/motion-start-generation.ts b/src/renderer/motion/playback/motion-start-generation.ts index 5def7badd..e79b319b4 100644 --- a/src/renderer/motion/playback/motion-start-generation.ts +++ b/src/renderer/motion/playback/motion-start-generation.ts @@ -1,3 +1,4 @@ +/** Tracks which asynchronous motion start owns mixer playback. */ interface MotionStartGeneration { begin(): number; invalidate(): void; diff --git a/src/renderer/motion/playback/perch-hold.ts b/src/renderer/motion/playback/perch-hold.ts index 1036ed6b8..d84153011 100644 --- a/src/renderer/motion/playback/perch-hold.ts +++ b/src/renderer/motion/playback/perch-hold.ts @@ -1,3 +1,4 @@ +/** Held-posture suppression and baseline rules. */ import type { MotionKind, MotionSignal } from "../../../contract"; /** A held posture ignores idle returns and non-state motion requests. */ diff --git a/src/settings/agent-access/document.ts b/src/settings/agent-access/document.ts index 0f0d4a47f..da1f07fa7 100644 --- a/src/settings/agent-access/document.ts +++ b/src/settings/agent-access/document.ts @@ -1,3 +1,4 @@ +/** Reads the exposed settings as one document, and applies the direct rows of a JSON merge patch and returns the allow changes. */ import type { SettingsStores } from "../settings-stores"; import { getIn, leaves, setIn } from "./paths"; import { ROWS, type SettingAccess } from "./rows"; diff --git a/src/settings/agent-access/rows.ts b/src/settings/agent-access/rows.ts index aa94d082a..e35f4db36 100644 --- a/src/settings/agent-access/rows.ts +++ b/src/settings/agent-access/rows.ts @@ -1,3 +1,4 @@ +/** The exposed settings rows: path, label, type, range, and the direct or allow tier. */ import type { FillerLang } from "../../config/validators/filler"; import { FILLER_LANGS } from "../../config/validators/filler"; import { createActiveHoursSettings } from "../active-hours/active-hours-settings"; diff --git a/src/settings/agent-access/validate.ts b/src/settings/agent-access/validate.ts index e10080e1e..2fb3d57bc 100644 --- a/src/settings/agent-access/validate.ts +++ b/src/settings/agent-access/validate.ts @@ -1,3 +1,4 @@ +/** The store probe a row's value passes before it is written. */ import type { SettingsStores } from "../settings-stores"; import { setIn } from "./paths"; import type { SettingRow } from "./rows"; diff --git a/src/settings/appearance/text-size-settings.ts b/src/settings/appearance/text-size-settings.ts index 0e4e6c233..7f1b29c96 100644 --- a/src/settings/appearance/text-size-settings.ts +++ b/src/settings/appearance/text-size-settings.ts @@ -1,3 +1,4 @@ +/** The persisted text-size scale setting and its store. */ import { createPersistedStore, isPlainObject, diff --git a/src/settings/appearance/theme-settings.ts b/src/settings/appearance/theme-settings.ts index 51bbdec52..4fcc6f2ef 100644 --- a/src/settings/appearance/theme-settings.ts +++ b/src/settings/appearance/theme-settings.ts @@ -1,3 +1,4 @@ +/** The dawn, hearth, or system theme under yui.theme. */ import { createPersistedStore, isPlainObject, diff --git a/src/settings/backend/workflow-settings.ts b/src/settings/backend/workflow-settings.ts index fc628fb33..078864043 100644 --- a/src/settings/backend/workflow-settings.ts +++ b/src/settings/backend/workflow-settings.ts @@ -1,3 +1,4 @@ +/** Workflow entry list and URL validation. */ import { createPersistedStore, localStorageStore, type PersistedStorage } from "../persisted-store"; export interface WorkflowEntry { diff --git a/src/settings/preset/bound-preset.ts b/src/settings/preset/bound-preset.ts index 53b5e1778..889eb7c03 100644 --- a/src/settings/preset/bound-preset.ts +++ b/src/settings/preset/bound-preset.ts @@ -1,3 +1,4 @@ +/** The page queries that bind a window to one preset (`?preset=`), name the preset a settings window edits (`?edit=`), and the page it opens on (`?page=`). */ import { isSettingsPage, type SettingsPage } from "../panels/settings-pages"; /** The page query binds a pet window to a preset whose membership the registry validates. */ diff --git a/src/settings/relations/relation-lines.ts b/src/settings/relations/relation-lines.ts index f1fb3cded..115c616b4 100644 --- a/src/settings/relations/relation-lines.ts +++ b/src/settings/relations/relation-lines.ts @@ -1,3 +1,4 @@ +/** The relation entries a turn carries: user first, then the other presets in registry order; none while the switch is off. */ import type { ClientContext } from "../../contract/types"; import type { PresetEntry } from "../preset/active-preset"; import { targetLabel } from "./relation-targets"; diff --git a/src/settings/relations/relation-targets.ts b/src/settings/relations/relation-targets.ts index 473d3b695..0e657b950 100644 --- a/src/settings/relations/relation-targets.ts +++ b/src/settings/relations/relation-targets.ts @@ -1,3 +1,4 @@ +/** The label a prompt line or the rate_relation enum shows for a preset: one named `user` is disambiguated. */ import type { PresetEntry } from "../preset/active-preset"; /** The name the client-context lines and the tools show for a preset: a preset named `user` is disambiguated. */ diff --git a/src/settings/relations/relations-store.ts b/src/settings/relations/relations-store.ts index 58d504bdf..0bb048ab3 100644 --- a/src/settings/relations/relations-store.ts +++ b/src/settings/relations/relations-store.ts @@ -1,3 +1,4 @@ +/** The per-preset store under yui..relations: bands, the daily cap, the range clamp, the user's own set, and the read of another preset's store. */ import type { RelationBand } from "../../contract/types"; import { createPersistedStore, diff --git a/src/settings/relations/relations-switch.ts b/src/settings/relations/relations-switch.ts index d564fa2dc..613ae8be8 100644 --- a/src/settings/relations/relations-switch.ts +++ b/src/settings/relations/relations-switch.ts @@ -1,3 +1,4 @@ +/** The device-wide Relations switch under yui.relations-enabled, on by default. */ import { createFlagSettings, localStorageStore, type PersistedStorage } from "../persisted-store"; /** Whether relations run at all: the Relations section, the preset header's relation line, the relation: line and rate_relation. Default ON. */ diff --git a/src/settings/settings-stores.ts b/src/settings/settings-stores.ts index d647a72d5..a17700ae4 100644 --- a/src/settings/settings-stores.ts +++ b/src/settings/settings-stores.ts @@ -1,3 +1,4 @@ +/** Constructs and synchronises the persisted user-setting stores. */ import { createActiveHoursSettings, localStorageActiveHoursStorage, diff --git a/src/settings/unified/unified-chat-switch.ts b/src/settings/unified/unified-chat-switch.ts index 4af449cca..5be475fb4 100644 --- a/src/settings/unified/unified-chat-switch.ts +++ b/src/settings/unified/unified-chat-switch.ts @@ -1,3 +1,4 @@ +/** The device-wide Unified chat switch under yui.unified-chat, off by default. */ import { createFlagSettings, localStorageStore, type PersistedStorage } from "../persisted-store"; /** Whether main opens the unified chat window while two or more presets are open. Default OFF. Device-wide. */ diff --git a/src/settings/unified/unified-shown.ts b/src/settings/unified/unified-shown.ts index 8017918c9..0fac8014f 100644 --- a/src/settings/unified/unified-shown.ts +++ b/src/settings/unified/unified-shown.ts @@ -1,3 +1,4 @@ +/** Whether the unified window shows: the switch on, two or more open presets, a window can exist; every pet and settings window reads it. */ import { isTauri } from "../../tauri-env"; import type { FlagSettingsStore } from "../persisted-store"; import { readOpenPresetIds } from "../preset/pet-windows"; diff --git a/src/ui/ask/ask-route.ts b/src/ui/ask/ask-route.ts index 110582c06..a32cd47da 100644 --- a/src/ui/ask/ask-route.ts +++ b/src/ui/ask/ask-route.ts @@ -1,3 +1,4 @@ +/** Shows the Ask slot's frames on the one side the target picks, clearing the previous side, and hears answers from every side. */ import type { AskSlotFrame } from "../../io/chat/tools/run/settings-request-frame"; import type { Surfaces } from "../surfaces/surfaces"; diff --git a/src/ui/chips/fit-sheet.ts b/src/ui/chips/fit-sheet.ts index de559f10c..68a61f6cb 100644 --- a/src/ui/chips/fit-sheet.ts +++ b/src/ui/chips/fit-sheet.ts @@ -1,3 +1,4 @@ +/** Keeps the details sheet inside the window: lift, then cap and scroll. */ const MARGIN = 8; const LIFT = "--yui-sigdetails-lift"; diff --git a/src/ui/chips/voice-input-status.ts b/src/ui/chips/voice-input-status.ts index e28599baf..a99e76977 100644 --- a/src/ui/chips/voice-input-status.ts +++ b/src/ui/chips/voice-input-status.ts @@ -1,3 +1,4 @@ +/** Voice-input status model. */ import type { VoiceInputState } from "../../io/voice/stt-vad"; export interface VoiceInputStatusSnapshot { diff --git a/src/ui/commands/command-input.ts b/src/ui/commands/command-input.ts index 0a9d074ae..31e1746b9 100644 --- a/src/ui/commands/command-input.ts +++ b/src/ui/commands/command-input.ts @@ -1,3 +1,4 @@ +/** The text field's slash-command layer: interceptSubmit parses /name args and refuses non-commands. */ import type { BackendCommand } from "../../io/chat/push/push-frames"; import type { SubmitInterception } from "../input/text-input"; import { createCommandList } from "./command-list"; diff --git a/src/ui/commands/command-list.css b/src/ui/commands/command-list.css index 12c7d73d9..99dc2b9fc 100644 --- a/src/ui/commands/command-list.css +++ b/src/ui/commands/command-list.css @@ -1,3 +1,4 @@ +/* The command list's styles. */ .yui-cmd-list { position: absolute; bottom: calc(100% + 10px); diff --git a/src/ui/commands/command-list.ts b/src/ui/commands/command-list.ts index e7b6e494c..161c48a9b 100644 --- a/src/ui/commands/command-list.ts +++ b/src/ui/commands/command-list.ts @@ -1,3 +1,4 @@ +/** The command listbox above the field: the matching rows, the footer counts, and the pick and activation keys. */ import "./command-list.css"; import type { BackendCommand } from "../../io/chat/push/push-frames"; import { subscribe, t } from "../i18n"; diff --git a/src/ui/commands/command-reply.css b/src/ui/commands/command-reply.css index ff07b4ee0..0afa2d8b4 100644 --- a/src/ui/commands/command-reply.css +++ b/src/ui/commands/command-reply.css @@ -1,3 +1,4 @@ +/* The command reply card's styles. */ .yui-cmd-reply { position: relative; display: flex; diff --git a/src/ui/commands/command-reply.ts b/src/ui/commands/command-reply.ts index 492b4f7ad..2aa6208ea 100644 --- a/src/ui/commands/command-reply.ts +++ b/src/ui/commands/command-reply.ts @@ -1,3 +1,4 @@ +/** The command reply card: pending, settled, and empty states with a live region and a close button. */ import "./command-reply.css"; import type { CommandReplyState } from "../../io/bridge/message/message-bridge"; import { subscribe, t } from "../i18n"; diff --git a/src/ui/commands/drag-scroll.ts b/src/ui/commands/drag-scroll.ts index cee7a99e6..4d048804c 100644 --- a/src/ui/commands/drag-scroll.ts +++ b/src/ui/commands/drag-scroll.ts @@ -1,3 +1,4 @@ +/** Pointer drag-to-scroll over a list: vertical follow and click suppression after a drag. */ export function attachDragScroll( el: HTMLElement, onClick?: (target: EventTarget | null) => void, diff --git a/src/ui/commands/reply-resize.ts b/src/ui/commands/reply-resize.ts index 33e35b248..835516b86 100644 --- a/src/ui/commands/reply-resize.ts +++ b/src/ui/commands/reply-resize.ts @@ -1,3 +1,4 @@ +/** The reply card's resize handle: drag to set a height within the window's room. */ import { subscribe, t } from "../i18n"; export function createReplyResize({ card, onResize }: { card: HTMLElement; onResize: () => void }) { diff --git a/src/ui/commands/surface-commands.ts b/src/ui/commands/surface-commands.ts index d9005fa88..becda596f 100644 --- a/src/ui/commands/surface-commands.ts +++ b/src/ui/commands/surface-commands.ts @@ -1,3 +1,4 @@ +/** A surface's command input with its busy guard: refuses while the turn is busy. */ import { t } from "../i18n"; import type { createTextInput } from "../input/text-input"; import { createCommandInput } from "./command-input"; diff --git a/src/ui/controls/checkbox/index.ts b/src/ui/controls/checkbox/index.ts index c96631478..06c3763d2 100644 --- a/src/ui/controls/checkbox/index.ts +++ b/src/ui/controls/checkbox/index.ts @@ -1 +1,2 @@ +/** Re-exports the Checkbox and its props type. */ export { Checkbox, type CheckboxProps } from "./checkbox"; diff --git a/src/ui/controls/disclosure/index.ts b/src/ui/controls/disclosure/index.ts index 0ed287b43..0d99d1a0a 100644 --- a/src/ui/controls/disclosure/index.ts +++ b/src/ui/controls/disclosure/index.ts @@ -1 +1,2 @@ +/** Re-exports the Disclosure and its props type. */ export { Disclosure, type DisclosureProps } from "./disclosure"; diff --git a/src/ui/controls/number-field/index.ts b/src/ui/controls/number-field/index.ts index dae20f90a..39beed500 100644 --- a/src/ui/controls/number-field/index.ts +++ b/src/ui/controls/number-field/index.ts @@ -1 +1,2 @@ +/** Re-exports the NumberField and its props type. */ export { NumberField, type NumberFieldProps } from "./number-field"; diff --git a/src/ui/controls/segment/index.ts b/src/ui/controls/segment/index.ts index a45064166..a77bd1ea8 100644 --- a/src/ui/controls/segment/index.ts +++ b/src/ui/controls/segment/index.ts @@ -1 +1,2 @@ +/** Re-exports the Segment, its options and props. */ export { Segment, type SegmentOption, type SegmentProps } from "./segment"; diff --git a/src/ui/controls/select/index.ts b/src/ui/controls/select/index.ts index dfe11025d..241fd18d9 100644 --- a/src/ui/controls/select/index.ts +++ b/src/ui/controls/select/index.ts @@ -1 +1,2 @@ +/** Re-exports the Select and its props type. */ export { Select, type SelectProps } from "./select"; diff --git a/src/ui/controls/slider/index.ts b/src/ui/controls/slider/index.ts index aecbf01ae..3b746d4c3 100644 --- a/src/ui/controls/slider/index.ts +++ b/src/ui/controls/slider/index.ts @@ -1 +1,2 @@ +/** Re-exports the Slider and its props type. */ export { Slider, type SliderProps } from "./slider"; diff --git a/src/ui/controls/switch/index.ts b/src/ui/controls/switch/index.ts index ef59720d4..c3905421e 100644 --- a/src/ui/controls/switch/index.ts +++ b/src/ui/controls/switch/index.ts @@ -1 +1,2 @@ +/** Re-exports the Switch and its props type. */ export { Switch, type SwitchProps } from "./switch"; diff --git a/src/ui/controls/tabs/index.ts b/src/ui/controls/tabs/index.ts index e7746f4e4..d77e359ff 100644 --- a/src/ui/controls/tabs/index.ts +++ b/src/ui/controls/tabs/index.ts @@ -1 +1,2 @@ +/** Re-exports the Tabs state hook, root, tab, panel and handle type. */ export { Tab, TabPanel, type TabsHandle, TabsRoot, useTabs } from "./tabs"; diff --git a/src/ui/controls/tooltip/index.ts b/src/ui/controls/tooltip/index.ts index dade26f2f..8c6e17b85 100644 --- a/src/ui/controls/tooltip/index.ts +++ b/src/ui/controls/tooltip/index.ts @@ -1 +1,2 @@ +/** Re-exports the TooltipHost, the Tip and the host's handle type. */ export { Tip, TooltipHost, type TooltipHostHandle } from "./tooltip"; diff --git a/src/ui/controls/tooltip/tip-test-helpers.ts b/src/ui/controls/tooltip/tip-test-helpers.ts index c56ce437d..bfb042853 100644 --- a/src/ui/controls/tooltip/tip-test-helpers.ts +++ b/src/ui/controls/tooltip/tip-test-helpers.ts @@ -1,3 +1,4 @@ +/** The tooltip's test helpers: the shown tip's text, a hover, and a keyboard focus. */ import { fireEvent } from "@testing-library/react"; import { act } from "react"; diff --git a/src/ui/devtools/devtools.css b/src/ui/devtools/devtools.css index 598ea77ea..53c79ae6d 100644 --- a/src/ui/devtools/devtools.css +++ b/src/ui/devtools/devtools.css @@ -1,3 +1,4 @@ +/* Developer Tools shell styles. */ html, body, #app { diff --git a/src/ui/devtools/motion-preview/live-status.ts b/src/ui/devtools/motion-preview/live-status.ts index bf2fde22f..40760727f 100644 --- a/src/ui/devtools/motion-preview/live-status.ts +++ b/src/ui/devtools/motion-preview/live-status.ts @@ -1,3 +1,4 @@ +/** Per-frame status text, fps, and elapsed time; reports each clip change. */ import type { EmotionId, MotionRegistry } from "../../../contract"; import { variantName } from "./variants"; diff --git a/src/ui/devtools/motion-preview/motion-load.ts b/src/ui/devtools/motion-preview/motion-load.ts index ac5eeab8e..c3d089084 100644 --- a/src/ui/devtools/motion-preview/motion-load.ts +++ b/src/ui/devtools/motion-preview/motion-load.ts @@ -1,3 +1,4 @@ +/** The Motion panel's load attempts: pending, loaded, failed, and dispose. */ import { createLogger } from "../../../logger"; import type { MotionView } from "./motion-preview"; diff --git a/src/ui/devtools/motion-preview/perch-hook.ts b/src/ui/devtools/motion-preview/perch-hook.ts index c70b63aa4..5d30ce128 100644 --- a/src/ui/devtools/motion-preview/perch-hook.ts +++ b/src/ui/devtools/motion-preview/perch-hook.ts @@ -1,3 +1,4 @@ +/** Dev-only perch globals for the console. */ import type { Renderer } from "../../../renderer"; export function installPerchHook(renderer: Renderer): void { diff --git a/src/ui/devtools/motion-preview/variants.ts b/src/ui/devtools/motion-preview/variants.ts index 2b2fc5630..adf47bbaf 100644 --- a/src/ui/devtools/motion-preview/variants.ts +++ b/src/ui/devtools/motion-preview/variants.ts @@ -1,3 +1,4 @@ +/** Pooled-variant expansion into playable entries. */ import type { MotionRegistry } from "../../../contract"; /** "/motions/idle_03.vrma" → "idle_03" */ diff --git a/src/ui/listbox/listbox.ts b/src/ui/listbox/listbox.ts index 6b0e38e4f..454aebec6 100644 --- a/src/ui/listbox/listbox.ts +++ b/src/ui/listbox/listbox.ts @@ -1,3 +1,4 @@ +/** The shared combobox and listbox behaviour of a field: roles, one open owner, and the arrow and enter keys. */ interface Option { id: string; el: HTMLElement; diff --git a/src/ui/quick-controls/connection/chat/push-state-text.ts b/src/ui/quick-controls/connection/chat/push-state-text.ts index 41798f13f..7c16922d7 100644 --- a/src/ui/quick-controls/connection/chat/push-state-text.ts +++ b/src/ui/quick-controls/connection/chat/push-state-text.ts @@ -1,3 +1,4 @@ +/** Where the push socket stands, in words, for the status line. */ import type { PushSocketState } from "../../../../io/chat/push/push-socket"; import { t } from "../../../i18n"; diff --git a/src/ui/quick-controls/delegations/delegation-sync.ts b/src/ui/quick-controls/delegations/delegation-sync.ts index 55a590431..b816d7ef2 100644 --- a/src/ui/quick-controls/delegations/delegation-sync.ts +++ b/src/ui/quick-controls/delegations/delegation-sync.ts @@ -1,3 +1,4 @@ +/** Minute refresh timer that follows the running delegated items. */ import type { DelegationItem } from "../../../io/chat/push/push-frames"; import { DELEGATION_REFRESH_MS } from "../../chips/delegation-rows"; diff --git a/src/ui/quick-controls/history/history-time.ts b/src/ui/quick-controls/history/history-time.ts index def252e02..5eea2dc2a 100644 --- a/src/ui/quick-controls/history/history-time.ts +++ b/src/ui/quick-controls/history/history-time.ts @@ -1,3 +1,4 @@ +/** The wall-clock time of a turn and the start of a session. */ import { getLocale } from "../../i18n"; /** Locale-aware wall-clock time, 24h so the tabular-nums column stays aligned. */ diff --git a/src/ui/quick-controls/preset/photo-dialog/photo-dialog.css b/src/ui/quick-controls/preset/photo-dialog/photo-dialog.css index 244179678..dd32bce18 100644 --- a/src/ui/quick-controls/preset/photo-dialog/photo-dialog.css +++ b/src/ui/quick-controls/preset/photo-dialog/photo-dialog.css @@ -1,3 +1,4 @@ +/* The dialog's layout. */ .yui-photo-dialog { width: min(44rem, calc(100vw - 2rem)); padding: 1.5rem 1.75rem; diff --git a/src/ui/quick-controls/preset/relations/view.ts b/src/ui/quick-controls/preset/relations/view.ts index be3413a9a..a88f93d17 100644 --- a/src/ui/quick-controls/preset/relations/view.ts +++ b/src/ui/quick-controls/preset/relations/view.ts @@ -1,3 +1,4 @@ +/** What the two read: this preset's relations as stored now, a target's name, and the rated targets' order. */ import type { RelationBand } from "../../../../contract/types"; import type { PresetEntry } from "../../../../settings/preset/active-preset"; import type { Relations } from "../../../../settings/relations/relations-store"; diff --git a/src/ui/quick-controls/preset/use-prepended.ts b/src/ui/quick-controls/preset/use-prepended.ts index 7d278ac6e..39fdac0eb 100644 --- a/src/ui/quick-controls/preset/use-prepended.ts +++ b/src/ui/quick-controls/preset/use-prepended.ts @@ -1,3 +1,4 @@ +/** Keeps a vanilla element, a face or a glyph, first inside a React-rendered host. */ import { type DependencyList, type RefObject, useLayoutEffect, useRef } from "react"; /** diff --git a/src/ui/quick-controls/switch-row.ts b/src/ui/quick-controls/switch-row.ts index 18357ed16..412c34f93 100644 --- a/src/ui/quick-controls/switch-row.ts +++ b/src/ui/quick-controls/switch-row.ts @@ -1,3 +1,4 @@ +/** Switch-row element contract, the row table filling it, and each row's store follower. */ import type { createAgentNotifySettings } from "../../settings/backend/agent-notify-settings"; import type { ScreenKnobSettingsStore } from "../../settings/capture/screen-settings"; import type { MessageWindowSettingsStore } from "../../settings/panels/message-window-settings"; diff --git a/src/ui/ref-mount/index.ts b/src/ui/ref-mount/index.ts index 8546650c3..1649c3943 100644 --- a/src/ui/ref-mount/index.ts +++ b/src/ui/ref-mount/index.ts @@ -1 +1,2 @@ +/** Re-exports RefMount and its props type. */ export { RefMount, type RefMountProps } from "./ref-mount"; diff --git a/src/ui/scroll-fade/scroll-fade.ts b/src/ui/scroll-fade/scroll-fade.ts index 9673e9caf..8806e0d84 100644 --- a/src/ui/scroll-fade/scroll-fade.ts +++ b/src/ui/scroll-fade/scroll-fade.ts @@ -1,3 +1,4 @@ +/** Marks an element whose content sits below its visible part so its bottom edge fades. */ import "./scroll-fade.css"; /** Marks `el` while more of its content sits below its visible part; its bottom edge then fades. */ diff --git a/src/ui/surfaces/apply-speech-op.ts b/src/ui/surfaces/apply-speech-op.ts index a97d19a41..39c84666c 100644 --- a/src/ui/surfaces/apply-speech-op.ts +++ b/src/ui/surfaces/apply-speech-op.ts @@ -1,3 +1,4 @@ +/** Draws one bubble op on the unified box through the surface op table. */ import { type MessageSurfaceOp, receiveSurfaceOp, diff --git a/src/ui/theme/apply-text-scale.ts b/src/ui/theme/apply-text-scale.ts index 4b6e1cac0..473e4fb0a 100644 --- a/src/ui/theme/apply-text-scale.ts +++ b/src/ui/theme/apply-text-scale.ts @@ -1,3 +1,4 @@ +/** Sets --yui-text-scale on the window root and follows the text-size store. */ import type { createTextSizeSettings } from "../../settings/appearance/text-size-settings"; type TextSizeStore = Pick, "get" | "subscribe">; diff --git a/src/ui/theme/apply-theme.ts b/src/ui/theme/apply-theme.ts index 312b098bc..517feca64 100644 --- a/src/ui/theme/apply-theme.ts +++ b/src/ui/theme/apply-theme.ts @@ -1,3 +1,4 @@ +/** Resolves system through OS appearance and follows the store and the OS. */ import type { createThemeSettings } from "../../settings/appearance/theme-settings"; type ThemeStore = Pick, "get" | "subscribe">; diff --git a/src/ui/unified/backlog-lines.ts b/src/ui/unified/backlog-lines.ts index 1a2562557..29442f8f0 100644 --- a/src/ui/unified/backlog-lines.ts +++ b/src/ui/unified/backlog-lines.ts @@ -1,3 +1,4 @@ +/** The backlog's lines: the user's under "You → " without the @name it repeats, a character's under its name. */ import type { PresetEntry } from "../../settings/preset/active-preset"; import { t } from "../i18n"; import type { BacklogLine } from "../message/backlog"; diff --git a/src/ui/unified/commands/unified-commands.ts b/src/ui/unified/commands/unified-commands.ts index 8f43f704b..bf586f89d 100644 --- a/src/ui/unified/commands/unified-commands.ts +++ b/src/ui/unified/commands/unified-commands.ts @@ -1,3 +1,4 @@ +/** The unified composer's per-preset backend commands: the mention's list, a send's pending reply, and the control events. */ import type { SpeechStream, SpeechStreamControl } from "../../../io/bridge/settings-bridge"; import type { BackendCommand } from "../../../io/chat/push/push-frames"; import type { PresetEntry } from "../../../settings/preset/active-preset"; diff --git a/src/ui/use-snapshot/use-notify.ts b/src/ui/use-snapshot/use-notify.ts index 7685c3ed8..e726896fd 100644 --- a/src/ui/use-snapshot/use-notify.ts +++ b/src/ui/use-snapshot/use-notify.ts @@ -1,3 +1,4 @@ +/** Re-renders a component on each notify of a source it reads itself. */ import { useSnapshot } from "./use-snapshot"; const fresh = (): object => ({}); diff --git a/src/ui/use-snapshot/use-snapshot.ts b/src/ui/use-snapshot/use-snapshot.ts index 7210d800c..2d637074a 100644 --- a/src/ui/use-snapshot/use-snapshot.ts +++ b/src/ui/use-snapshot/use-snapshot.ts @@ -1,3 +1,4 @@ +/** Binds such a source to a component. */ import { useCallback, useState, useSyncExternalStore } from "react"; /** diff --git a/src/windows/devtools-main.ts b/src/windows/devtools-main.ts index 8bb8a5145..f81dd93ec 100644 --- a/src/windows/devtools-main.ts +++ b/src/windows/devtools-main.ts @@ -1,3 +1,4 @@ +/** Developer Tools window. */ import { getCurrentWindow } from "@tauri-apps/api/window"; import "../styles.css"; import "../ui/quick-controls/quick-controls.css"; diff --git a/vite.config.ts b/vite.config.ts index 5ac954970..6faa106b4 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,3 +1,4 @@ +/** Dev port YUI_DEV_PORT|1420, strictPort, host 127.0.0.1, backend proxy plugin. */ import { createReadStream, existsSync, statSync } from "node:fs"; import { extname, normalize, resolve } from "node:path"; import { fileURLToPath } from "node:url"; From b1da5ac29740180beddc1bbe6ff47c2173dfa065 Mon Sep 17 00:00:00 2001 From: YoungWoo nam Date: Sun, 29 Nov 2026 22:55:56 +0900 Subject: [PATCH 2/8] docs: the project structure lists folders, and a file's description is its first-line comment --- docs/agent-guide/project-structure.md | 953 ++------------------------ 1 file changed, 45 insertions(+), 908 deletions(-) diff --git a/docs/agent-guide/project-structure.md b/docs/agent-guide/project-structure.md index 0e0e3e1d8..a7d5a11c4 100644 --- a/docs/agent-guide/project-structure.md +++ b/docs/agent-guide/project-structure.md @@ -14,8 +14,10 @@ ## Directory Map +A source file's description is its first-line comment. + ``` -YUI/ +YUI/ # The repository: the app, the Rust shell, the plugins, the integrations, and the docs index.html # Vite entry settings.html # Settings-window Vite entry devtools.html # Developer Tools Vite entry @@ -23,7 +25,6 @@ YUI/ unified.html # Unified-chat-window Vite entry threads.html # Threads-window Vite entry character-menu.html # Character-menu-window Vite entry - vite.config.ts # Dev port YUI_DEV_PORT|1420, strictPort, host 127.0.0.1, backend proxy plugin biome.json # Format and lint config (curated rule set) scripts/ # Summarised: dev launchers (dev-port.mjs, tauri-dev.mjs for tauri:dev, dev-auto.mjs) and their shared package-manager.mjs helper, dev-backend-proxy.mjs, release.sh, worktree-setup.sh, rust-lines.sh (code and test line counts of a Rust file), architecture-map-base.mjs (writes the map of origin/main beside the data file for the viewer's Compare view), and ci/ (test-guard.sh, gates.sh, architecture-map.mjs, command-paths.mjs, css-selectors.mjs, logger-namespace.mjs) configs/ # Runtime-loaded config (no hardcoding) @@ -38,1027 +39,231 @@ YUI/ persona.json # Default card per UI language (en/ja/ko), the framing sentence, and the {{user}} fallback word emotion_text/ # Emoji voice-tag vocabulary, loaded only when tts_provider is irodori (emotion_text/irodori.json) public/motions/ # VRMA motion assets - src/ + src/ # The client source, in import order: contract, config, renderer, settings, io, dispatcher, ambient, ui, app, and windows app/ # Composes the pet window from the layers below - bootstrap-configured.ts # Pet window's config-derived bootstrap: runs the turn core and the pet-only wirings in order and drains their teardowns - csp-violation.ts # Logs every Content-Security-Policy violation the window reports - disposers.ts # Shared teardown bag: registers teardowns at creation sites and drains them LIFO active-hours/ # One pet window's active hours: the proactive gap and idle cue scale, and what holds her turns: Rest and quiet spans - window-active-hours.ts # Scales the gap and idle cue minutes by the base pace times the current span's pace; rest() is the running Rest, Focus or quiet span card-io/ # The card's file steps bound to a preset registry - import-preset.ts # The import a card section runs: native file step, copied voice registration, VRM list entry, preset creation, and rollback - wire-card-io.ts # The card's import, export, thumbnail, photo pick, and preset creation ports relations/ # This window's relations wiring - wire-relations.ts # rate_relation's open-preset targets and the ingress relations RPC, over the window's store turn/ # The path of a turn: sources, voice, and push - turn-core.ts # The chat turn every backend-facing window runs: voice, dispatcher, STT, VRM load, vocabulary, push transport, stop, and submit - wire-dispatcher.ts # Turn feed, backend caller, guardrails, pacer, and the dispatcher - report-turn-failure.ts # Where a failed user turn shows: the open input, or a notice on the status pill - wire-sources.ts # The dispatcher's utterance sources, built and started - wire-waiting.ts # The rows yui.waiting reads: the dispatcher's waiting list and the signal buffers, peeked without a drain - wire-card.ts # The card module bound to the window's stores, preset, UI language, and config - wire-greeting.ts # The greeting after a session reset, and the reset announcement each window's Start fresh makes - wire-first-conversation.ts # After Quick start connects, and on its Replay: the greeting on an empty session, then the input and the controls hint with the two guides - ask-queue.ts # The window's Ask queue: the push socket's Asks and the Settings requests, shown oldest first, the user's pick sent to the owner of the one shown - settings-request.ts # A yui_run write's allow paths as one Settings request in the Ask queue, answered with a decision, no answer, or busy when one is already open - wire-yui-run.ts # Builds the ports a yui_run script reaches from this window's stores, Ask queue, selections and Tauri commands - session-reset-announcer.ts # What a window's Start fresh announces: the bridge event, then this pet window's own greeting vocabulary/ # The express vocabulary every consumer declares - wire-vocabulary.ts # The emotion_text table load, the derived vocabulary, and its change announcements push/ # Push socket wiring and its stores - delegation-chip-mount.ts # The delegation chip's lazy mount and its suppression port - playback.ts # Reports a failed turn's end to the push socket as a playback frame - wire-push.ts # Push socket frames into turns, the stop button, and the push mode chip - push-stores.ts # The push socket, its chat id, and the delegations and reasoning stores its frames feed voice/ # Voice input and speech playback wiring - wire-voice.ts # The voice-input and turn-voice wiring; a bound window builds no capture - wire-voice-pipeline.ts # Wires filler, TTS, and speech playback to the turn lifecycle - speak-turn.ts # The speech turn behind TurnOutput: thinking guard and motion hold, filler availability, failure asides, barge-in - unified-voice.ts # Main's speech while the unified chat window shows, and the user speaking answered like a stop - wire-synth-failure-notice.ts # The first synth failure per pet window run: the bubble's Choose another action, opening the Voice page stage/ # What is bound to the pet window's stage and overlay - stage-renderer.ts # The renderer on the stage with its persisted camera and idle throttle, plus Tier 1 liveliness, for the pet window - wire-gestures.ts # Pointer gestures on the stage: taps, pats, the window drag, and the camera orbit - wire-window-sources.ts # The Tauri window drop and resize sources, the avatar RPC executor, and keep-on-screen - wire-window-geometry.ts # The per-window saved size and position: written after the OS drag ends and a Ctrl+wheel resize, applied once at boot - wire-locomotion.ts # Travel frame, the five locomotion loops, and the window sources composed into one handle, held still per holder - wire-come-along.ts # Her own settings window's stage slots and close into the come-along, and the stage ask at boot - wire-pet-stage.ts # Stage wheel zoom, the persisted camera and throttle flow, and the feet-follow input anchor - wire-summon.ts # Peek state and exit triggers, tray summon, and the global summon hotkey - wire-stage.ts # Click-through hit-test and cursor-gaze wiring over the stage dev/ # DEV-only console handles - wire-dev-globals.ts # The DEV console and global handles for inspection and firing dispatcher events cross-window/ # State the windows share - wire-cross-window.ts # Per-window sync for the pet, settings, and devtools windows - wire-window-sync.ts # Settings broadcast, guardrail overrides, and the shared cross-window sync core + dnd/ # Do-not-disturb wiring: the root marker that holds the urgent chip's pulse, and the tray's Do Not Disturb check controls/ # The pet window's summonable control surface - wire-pet-controls.ts # The popped-out surfaces' settings asks and the cue locale sync - wire-devtools-request.ts # Main's pet window opens Developer Tools when the settings window asks - wire-help-guide.ts # Guide requests the settings window sends over the bridge, submitted as user turns settings/ # Selections and conversation state applied to the running app - config-defaults.ts # The quick-controls getters over the bundled config, shared by the pet and settings windows - conversation-stores.ts # Constructs the shared io/chat conversation stores each window owns and disposes - dev-key-fallback.ts # The VITE_YUI_*_KEY build-time key values, read in dev builds only - window-stores.ts # Creates the settings and conversation store bags and the preset registry of the pet and settings windows and registers each store's teardown - window-vrm-selection.ts # The store-only VRM selection of a window without a renderer - wire-window-settings.ts # The settings side the settings window uses: stores, theme, config, voices, settings-window sync, the mirrored push socket and the reset announcer - wire-avatar.ts # VRM and speaker selection stores, their swap and import flows, the voice-list refresh on override commits, and the avatar config applied at boot - wire-config.ts # The config store over the bundled configs, the runtime key stores, the live endpoint/guardrail merges, and the reload/watch wiring - wire-cue-locale-sync.ts # Reseeds untouched built-in cues when the display language changes - wire-preset.ts # Sends a preset switch over the settings bridge and reloads each unbound window into it, after the pet window stops its turn; a bound window only rereads the list signal-chips/ # The signal chips beside the avatar - wire-signal-chips.ts # The signal chips on every transport, sharing the delegation chip's fold store threads-reaction/ # Main's Thread reactions: the Threads client, the Threads window, the chip's taps, presence, speech, the turn pipeline, the stage and the renderer - wire-thread-reactions.ts # Wires the thread reaction in main; a window without a Threads client wires nothing threads-attach/ # Main's attached Threads, wired by the chat turn in main's window only - attached-threads.ts # The list: each Thread once, toggled, dropped by the Threads a send carried, and a failed send's put back - wire-threads-attach.ts # The Threads window's toggles and the chips' × into the list, the list into every composer and out to the Threads window, a send's drop threads-chip/ # Main's ways into the Threads window: the chip, the tray's Terminal item and a bound Character menu's requests - wire-threads-chip.ts # The chip from the store's snapshots, on the shared fold store, opening the Threads window and reporting its taps - wire-threads-open-requests.ts # The tray's Terminal item and a bound Character menu's request, opening the Threads window on their tab pet-windows/ # Windows bound to one preset: the shared open list, their lifecycle, and the windows each one opens - pet-window-role.ts # The entry main composes: the registry and open list a window owns, the orphan check, and main's reconcile or a bound window's self-close - companion-window.ts # A companion window's boot: the orphan and owner checks, its own live key, and its teardown on a close request; the pet window's wait for its companions - wire-pet-windows-sync.ts # The open list in every window: a local edit out over yui://pet-windows-changed, a remote one reloaded from storage - wire-pet-windows-reconcile.ts # Main's reconcile: prunes the list and live keys, then opens each wanted preset that has no window - wire-preset-ids-sync.ts # Main publishes the registry's preset ids to the shell, so a prefixed ingress route can tell a closed window from an unknown id - wire-bound-window.ts # A bound pet window's live key, its companions closed first, and its store teardown and close when its preset leaves the list - close-if-orphan.ts # Closes a bound window whose preset is no longer in the registry message/ # The message window's wiring, and the character's name both windows' plates and backlogs show - wire-message-surface-ops.ts # Draws each surface op from the pet window onto the surfaces, which the plate follows - character-name.ts # In the pet window: the character's effective name, the card's while the built-in preset is unnamed, else the preset's - mirrored-name.ts # In the message window: the character's name as the pet window last sent it - wire-plate-name.ts # The plate's character name and the bound preset's face, or the active preset's when unbound unified/ # The unified chat window's wiring - wire-unified-window.ts # Main opens the window while it shows and destroys it otherwise - wire-unified-close.ts # The window closing itself turns the Unified chat switch off character-menu/ # The Character menu: its pet-window side and the Character menu window's side - wire-character-menu.ts # The pet window's right-click on her, and the menu window's picks and closes received back - pet-menu-opener.ts # Asks the menu window to open with her placement and state, holds her while it shows, marks the chip column, and lets her go on close - read-menu-placement.ts # Her window's frame, its monitor's work area, and her head, name and chest points for the menu - character-menu-ports.ts # The menu's actions over the stores and openers the pet window has: Rest, Listen, Body, Voice, Pace, Keep bubble, Unified chat, Reset chat, Threads, Turn off - wire-character-menu-window.ts # The menu window's wiring: its theme and language, and the session fed by the bridge's open, state and close requests - menu-window-session.ts # The menu window's open sessions: places and shows the menu beside each open's pet window, reports shown and closed, and hides it threads-window/ # The Threads window's wiring - wire-threads-window.ts # Snapshots into the view, read marks to the store, main's attached Threads into the pane and its Attach to chat back, the frame store into placement and resize, the list choice, the open request, theme and language - threads-placement.ts # The window's frame: beside main's pet window the first time, its stored frame after that, its head's native drag, and the frame saved once a move settles - threads-presence.ts # One open or close at a time: show and grow, or focus or raise without focus while shown; shrink and hide, then the closed report, and the presented report for an automatic request - threads-resize.ts # A handle drag into the window's box, applied at most once a frame, the frame saved after the last apply settings-window/ # The settings window's wiring - wire-settings-window.ts # Stores, config, cross-window sync, and the settings panel remounted on locale change, bound to the query's preset when it names one, and editing the preset `?edit=` names - edit-target-url.ts # The settings URL with its `edit` param set to the picked preset, or dropped for the window's own, and its `page` and `focus` params set to the requested page and field - wire-settings-page.ts # Takes the URL's page and focus, and answers an opener's page request: switches to the opener's character, then selects the page and focuses the field it names - wire-voice-mirror.ts # Mirrors the voice toggle to the pet window and the pet window's voice state back; main only - logger.ts # Namespaced frontend logger with a runtime level - tauri-env.ts # Tauri runtime detection windows/ # One entry file per window, loaded by the matching HTML file - main.ts # Pet window: config load, renderer, dispatcher, and the I/O graph - settings-main.ts # Settings window: mounts the settings window wiring, with the companion guard when the query binds a preset - devtools-main.ts # Developer Tools window - message-main.ts # Message window: the bubble, input, and plate, with the companion guard when the query binds a preset - unified-main.ts # Unified chat window: the frameless 340 px column, the speech stream into its box, and the composer that routes a message - threads-main.ts # Threads window: boots the Threads window wiring - character-menu-main.ts # Character menu window: boots its wiring with the frame, the hit-test and the bridge - styles.css # Pet-window base stylesheet - vite-env.d.ts # Vite client types and build-time env declarations contract/ # TS contract types — the wire schema source of truth - types.ts # Wire schema source of truth for the YUI to backend contract - index.ts # Contract barrel builtin-client-tools.json # Built-in client tool names; the MCP host's name conflict rule reads them and a Vitest test checks them against the tool registry config/ # Config load, validate, reactive store, hot-reload, and the runtime URL resolver - load.ts # configs/*.json loader and validation, fail-loud - asset-url.ts # Bundled asset paths and imported user files to runtime-fetchable URLs - store.ts # Reactive config snapshot with hot-reload and change subscriptions - emotion-text.ts # Per-provider emotion_text emoji table loader - tts-provider.ts # The tts_provider values and the Irodori default for an unset one - secrets.ts # The secret provider and the key-name constants - validators/ + validators/ # The bundled configs' validators: the avatar sections, the persona card, and the other config files' shapes avatar/ # Validates avatar.json, one file per section - index.ts # Router: the early throws, section calls in order, and the result - types.ts # The avatar.json config types - helpers.ts # Shared issue-recording field readers and unknown-key check - available.ts # The available VRM manifest - framing.ts # The fit-to-bounds camera - hit-test.ts # Click-through polling and the alpha cut - tap.ts # Tap regions and touch cues - peek.ts # Side-peek geometry - walk.ts # Floor stroll and window-top stroll - fall.ts # Drag-release fall and monitor descent - climb.ts # Ambient window climb - jump.ts # Window-to-window flight - gestures.ts # Drag-hold duration and gesture cues - gaze.ts # Cursor tracking angles and damping - emotion-registry.ts # Validates the emotion registry against the emotion enum - endpoints.ts # Validates endpoint URLs and models; an empty value leaves the feature off - filler.ts # The filler.json phrase-pool and loop-timing types and their validation - guardrails.ts # The guardrails.json debounce, rate-limit, and attachment-cap types and their validation - hotkeys.ts # The hotkeys.json summon-accelerator type and its validation - motions.ts # Validates the motion registry persona/ # The card type, the V1/V2/V3 card reader, the V2 export envelope, and the persona.json validation - persona.ts # The persona.json card, framing sentence, and user fallback validation - read-card.ts # The V1, V2, and V3 card reader with its issues - types.ts # A card's Tavern Card V2 shape, its limits, and the persona config type - serialize-card.ts # The card as a chara_card_v2 envelope for export - screen.ts # The screen.json type and the validation of its frontmost-transition thresholds - shared.ts # Shared ConfigError plus issue-recording helpers renderer/ # three.js + VRM rendering - index.ts # three.js and VRM output layer: scene, rAF loop, VRM load and hot-swap - types.ts # Renderer options, per-frame tick context, and the Renderer surface - apply-directive.ts # Pure routing of a control envelope into the emotion and motion sinks - frame-gate.ts # Pure idle and active frame-throttle decision - frame-loop.ts # The rAF loop with its clock, hidden-document pause, and idle-throttle gate - landing.ts # Her landing bounce on the canvas after a sit, about the live seat - pin-controller.ts # Stateful perch and peek pin apply layer - vrm-loading.ts # VRM optimisation of a loaded glTF and the display-name read - vrm-participant.ts # The per-frame lifecycle every VRM-bound sub-controller implements camera/ # Camera framing, zoom, and orbit state - camera-fit.ts # Pure fit-to-bounds framing math - pixel-ratio.ts # Pure devicePixelRatio clamp - rig.ts # Fit-to-bounds framing, wheel zoom, the eased orbit polar, and the travel view window - view-window.ts # Draws the reference-size framing at an offset inside a parked canvas geometry/ # Silhouette hit-testing and read-only model probes hit/ # Alpha-silhouette hit-testing, stage coordinates, and tap regions - alpha-hit-test.ts # CPU-side low-res silhouette grab, its sampling and its bounds - hit-test.ts # Pure helpers for the alpha silhouette predicate and its bounds - stage-coords.ts # Client CSS px to stage-local coordinate conversion - tap-region.ts # Classifies a tap point into a body region probe/ # Read-only model probes, anchor projection, and perch math - perch-geometry.ts # Pure math for the window-sit perch - project-anchor.ts # Projects the world feet point into canvas pixels - screen-probes.ts # Read-only screen probes of the loaded model: feet anchor, width, seat and tap points, hand anchors, pixels per metre motion/ # Clip scheduling, variant swaps, and clip processing clip/ # Clip cache, mirroring, and root-motion processing - clip-library.ts # Per-VRM .vrma clip cache: load, mirror, root-lock detrend, dead-clip memo, crossfade clone - dead-clips.ts # Warn-once memo of VRMA paths whose load failed for good - mirror-clip.ts # Mirrors a clip across the YZ plane - recenter-root-motion.ts # Strips baked horizontal drift from VRMA root motion - self-crossfade.ts # Clip-cache key composition and playback clip selection playback/ # Motion scheduling, variant swaps, and mixer playback - fallback.ts # Idle-fallback decision for a motion whose clip fails to load - cycle-dwell.ts # Single-timer scheduler for a cycle motion's variant swap - motion-controller.ts # Pure motion scheduling and variant-resolution state machine - motion-playback.ts # Mixer-driven motion playback: controller decisions, action crossfade, finish → next, idle baseline - motion-start-generation.ts # Tracks which asynchronous motion start owns mixer playback - perch-hold.ts # Held-posture suppression and baseline rules yaw/ # Root-yaw easing math and its per-frame apply - body-yaw.ts # Pure easing math for the root yaw a stroll turns by - root-yaw.ts # Eased root yaw the ambient stroll turns the character by, written onto the model's base rotation each frame + grounding/ # Grounding: the per-frame floor height, the sole points, and the sole offset expression/ # Emotion, mouth, and gaze apply layers over the face - ease-emotion.ts # Eases the expression back to neutral when playback ends - emotion-crossfade.ts # Stateful VRM-expression crossfade apply layer - emotion-resolver.ts # Pure expression lookup and fallback-chain traversal - mouth-lipsync.ts # Amplitude-only mouth state machine and expression describe helper gaze/ # Cursor-gaze math and its three.js apply layer - bone-pitch.ts # Sign that turns a downward head pitch into a normalized bone's local rotation.x - cursor-gaze.ts # Stateful three.js apply layer for cursor head and eye tracking - gaze-tracker.ts # Pure cursor-gaze zone curve and angle damping dispatcher/ # Event bus + classify, guardrail, route - dispatcher.ts # The router that enforces the firing-is-not-judgment boundary - core/ - classify.ts # Pure tier, target and waiting-class classification of a bus envelope, plus the paced-source table - event-bus.ts # Priority queue collecting every speech-candidate event - guardrails.ts # Debounce on arrival, then the rate limit's canSpend and spend - addressed-chain.ts # The chain cap: how many addressed turns a window takes in a row without a user turn - paced-pipeline-busy.ts # The pipeline-busy predicate composed with the proactive gap - proactive-pacer.ts # The proactive gap after a turn that every proactive source shares - turn-gate.ts # The cross-window Web Lock a turn holds from its backend call to the end of its playback - waiting-list.ts # Self-started candidates that cannot speak now, ranked by class then age, with the keep rules - waiting-release.ts # What one free slot sends: the admissible entries and drained signal groups as one envelope - admission.ts # Which holds keep a candidate from going out now: Rest, the proactive gap, presence and the spend check - tier1/ - directive.ts # Pure tier-1 control directive for sit, drop, peek and pat events - render.ts # Tier-1 rendering: local directives, posture ledger, pin targets, and the tap-emotion revert - turn/ - turn.ts # Turn identity ledger and the single definition of over - turn-output.ts # Speech lifecycle port between the backend caller and the voice pipeline - push-turn.ts # Push-turn ids the user stopped, so their late frames drop whole, and the wait for a sent turn to finish - quoted-turn.ts # The admitted turn the bubble quotes: the user's message, a signal turn's source lines, or a trigger line, at its first utterance - trigger-line.ts # The line a turn she started shows: its own trigger or a waited member's, with +N for the rest of a bundle - signal-lines.ts # A trigger's signal groups as source lines, urgent first - render-turn.ts # Plays a finished backend turn that arrived as a render frame on the push socket - turn-feed.ts # Shared tool-status and reasoning consumer for every transport - backend/ - backend-caller.ts # Sends a tier-2 event to backend judgment and streams the reply - push-call.ts # Push transport path of a turn: frame send and the wait for its turn_end - settle-reply.ts # Settles a finished reply: directive render, cue routing, speech gate - stream-attempt.ts # One stream attempt of a turn: stream events to the speech pipeline and the verdict on how it ended - turn-recording.ts # Records a sent turn into the transcript, the context history, and the turn-record log - request-input.ts # Pure encoders for a turn's Responses input: post-history and client_context blocks, user item, and the items before it - turn-outcome.ts # How a backend call settled - background-marker.ts # Placeholder user-content text for a turn with no real user utterance - idle-watchdog.ts # Idle-gap watchdog over the backend event stream and its two timeout budgets - context-builder.ts # Builds the per-turn client context, with waited items and the do-not-disturb line, and image attachments - client-context-text.ts # Renders a client context into the plain-line prompt block - previous-turn.ts # Persisted record of how the last turn that tried to speak ended - sources/ - user-input-source.ts # Normalises typed text and STT results into bus envelopes + core/ # The dispatcher's shared machinery: the event bus, classification, admission, guardrails, the proactive pacer, the turn gate, and the waiting list + tier1/ # Tier 1: the local control directives and their rendering, with no backend involved + turn/ # The turn's shared state: identity, output, the quoted trigger, push-stop, and the render of a finished turn + backend/ # The backend side of a turn: the caller, the stream attempt, the client context, and how the reply settles and records + sources/ # The firing sources: typed and spoken user input, and each surface's self-started candidates inbox/ # The inbox-push firing sources - buffered-inbox-source.ts # Shared presence-gated core for the inbox-push firing sources - signals-source.ts # Grouped signals-ingress firing source; batched groups leave through drain() at the dispatcher's release idle-tick/ # Idle-gap, clock-time, milestone, and screen firing sources - proactive-source.ts # Idle-gap proactive firing source - schedule-source.ts # Clock-time schedule firing source; a cue is marked fired only once its turn ends ok - milestone-source.ts # Once-per-day first-activity milestone firing source - screen-source.ts # Frontmost-app transition firing source with a dwell state machine gesture/ # Tap, drag-hold, and window-drop firing sources - tap-source.ts # Turns taps on the character into bus envelopes - drag-hold-source.ts # Fires one proactive.drag_held candidate per sustained drag window-drop/ # Drag-release perch settle, armed-perch poll, and placement - window-drop-source.ts # Drag-release settle composing the perch watch and placement - perch-watch.ts # Armed perch and peek state with the occlusion-aware detach poll - perch-follow.ts # Carries a seated character with her host window as it moves or resizes - placement.ts # Programmatic placement of the character on a named window addressed/ # The character-addressed firing source and the speaking half - addressed-source.ts # Turns a character-addressed bridge event for this preset into the addressed.character candidate - addressed-producer.ts # Emits the character-addressed event for this window's reply once its turn is over routed/ # The unified chat window's messages arriving as user turns - routed-user-source.ts # Submits a user-turn-routed event naming this preset as a user turn with its send id and mention - user-turn-done.ts # Reports user-turn-done for a closed or dropped turn's send id + threads/ # The Threads firing source: a snapshot diff's signal groups and the Threads that left input-required ambient/ # Backend-independent local liveliness and movement come-along/ # Her come-along onto the settings stage - come-along.ts # One settings window's session: the pickup and ease-in-out carry onto the slot at its size, the dock and entry clip, following the slot, the carry home at her desktop size, and a drag or agent move letting her go with her size back - entry-pick.ts # Picks her entry clip from the Entry family of her last backend emotion - stage-frame.ts # Her window's frame on the slot, resized about its bottom centre, and eased along a carry liveliness/ # Tier 1 idle-life engine and its cue math - tier1.ts # Tier 1 ambient engine: blink, idle sway, breath, look-around - cues.ts # Pure, side-effect-free cue math for Tier 1 locomotion/ # Movement loops: stroll, perch, climb, jump, fall, and sit transitions walk/ # Floor stroll - walker.ts # Floor stroll along the monitor's work-area bottom - wire-walk.ts # Walker start and teardown, and the reflex-turn stroll cancel perch/ # Window-top perch and jump - percher.ts # Perched dwell, stroll, and sit-back-down on a foreign window top - jumper.ts # Jump across to an adjacent window top - wire-perch.ts # Percher and jumper start and teardown climb/ # Window and screen-edge climb - climber.ts # Climb up a window or screen edge, dwell, and climb back down - climb-geometry.ts # Pure wall geometry and the climb and descent target picks - wire-climb.ts # Climber start, enable latch, and teardown fall/ # Fall to the surface below - faller.ts # Fall to the first surface below a character left in mid-air - wire-fall.ts # Faller start, the fall switch, and landing events travel/ # Travel frame shared by the stroll, fall, and climb - wire-travel-frame.ts # Real-window travel frame wiring hold/ # Who holds her still - holds.ts # The holders and what each hold declares: an abort, ending on a drag, keeping her geometry, pausing keep-on-screen - sitter.ts # Seat transitions: crossfade and eased window move - clip-leg.ts # A window leg paced by an in-place clip threads-reaction/ # Thread reactions: the count-edge and long-wait thresholds, and the reaction when she is free - reaction-thresholds.ts # The waiting count's rising edge and the per-Thread long wait that start a reaction without a chip tap - thread-reaction.ts # Runs a reaction on a chip tap, the count edge or a long wait when she is free: the filler line, the window open or raise without focus, her seat on it, and the expression settings/ # Persisted user settings, one store per setting, grouped by the part of the app they configure - persisted-store.ts # Shared bootstrap, notify, reload, and localStorage core for the settings stores - settings-stores.ts # Constructs and synchronises the persisted user-setting stores appearance/ # The window theme - theme-settings.ts # The dawn, hearth, or system theme under yui.theme backend/ # What the backend connection uses - agent-settings.ts # Reasoning effort, the preset's card (null means the UI language's default), and the send switch - agent-notify-settings.ts # Agent-notification enabled flag and listener port - api-key-settings.ts # Generic API-key override store behind the chat, STT, and TTS key settings - chat-id-settings.ts # Conversation id this installation sends in every push hello - endpoints-settings.ts # User-editable endpoint and model overrides - guardrails-settings.ts # User-editable guardrail rate-limit caps - workflow-settings.ts # Workflow entry list and URL validation cues/ # Proactive and schedule cue lists - cue-list-settings.ts # Shared on/off flag plus editable cue list behind the schedule and proactive stores - proactive-settings.ts # Idle-gap proactive cue list and its on/off flag - proactive-seeds.ts # Per-locale default proactive cues seeded on a first run - schedule-settings.ts # Clock-time schedule cue list and its on/off flag - schedule-seeds.ts # Per-locale default schedule cues seeded on a first run active-hours/ # Each character's active-hours spans and the card's spans they fall back to - spans.ts # Span and pace rules: the four paces, their gap factors, and which span holds a minute - card-active-hours.ts # The card's extensions.yui.active_hours, the spans in use, and the export transform - active-hours-settings.ts # The per-character store of edited spans under yui.active-hours - base-pace-settings.ts # The device-wide base pace under yui.base-pace, multiplied into each pet window's span pace rest/ # The Rest record under yui.dnd: a choice and its end, the choices offered at a time, and the state every surface reads - rest-settings.ts # The device-wide Rest store: the running choice, its start and end, and the stored record's parse - rest-choices.ts # The six Rest choices, the Focus predicate, and the running Rest state - rest-end.ts # When each choice ends, which choices are offered at a time, and the local clock and minutes helpers - rest-state.ts # What holds her turns at an instant: a running Rest or Focus, else an active-hours quiet span capture/ # Screen watching and screenshots - screen-settings.ts # User-editable screen-watch thresholds - screenshot-settings.ts # Screenshot enabled state and source presence/ # The user's last presence - last-together-settings.ts # The device-wide last present tick under yui.last-together, written at most once a minute; the milestone payload's last_together reads it agent-access/ # The settings a backend agent may read and change through yui_run, and the tier each row takes - rows.ts # The exposed settings rows: path, label, type, range, and the direct or allow tier - document.ts # Reads the exposed settings as one document, and applies the direct rows of a JSON merge patch and returns the allow changes - paths.ts # Dotted-path reads and writes over the settings document - validate.ts # The store probe a row's value passes before it is written avatar/ # Camera, motion, and lip-sync - camera-settings.ts # Camera zoom and orbit viewpoint - camera-gestures.ts # Maps orbit moves and pinch ratios onto the camera store - express-motion-settings.ts # Curates the motion vocabulary the agent may choose from - idle-motion-settings.ts # Selects which ambient idle variants may play - lipsync-settings.ts # Lip-sync gain voice/ # Filler speech and voice activity detection - card-filler.ts # The card's extensions.yui.filler pools, and the transforms around it - filler-settings.ts # Filler phrase pools and behaviour flags - readings-settings.ts # Device-wide reading dictionary: the raw surface=reading text as typed - vad-settings.ts # VAD silence window preset/ # Presets: which keys belong to one, the active one, the registry, and the windows bound to one - preset-keys.ts # The per-preset key list and where a key lives under a given preset - active-preset.ts # The registry's stored shape and the id a window resolves its keys under: the preset query, else the active preset - bound-preset.ts # The page queries that bind a window to one preset (`?preset=`), name the preset a settings window edits (`?edit=`), and the page it opens on (`?page=`) - preset-registry.ts # Preset list and active preset under yui.presets: create, rename (everyone, here and all are refused), remove, activate, setThumbnail (with crop) - photo-crop.ts # A photo's crop area as ratios, its validator, and the default, whole-photo and face framings - import-card-preset.ts # Creates a preset from an imported card and rolls it back on any failure - pet-windows.ts # The desired open set under yui.windows, the open presets with names, and the live key each window holds under yui.live-window.