Galaxy Shell / docs
Docs / Interface and features

Agent contract: direction

docs/agent-direction.md · Edit on GitHub ↗

On this page

Agent contract: direction

Doc status: current contract. Full text moved verbatim from AGENTS.md on 2026-11-11 (naming, philosophy and current direction). Checked 2026-11-11.

This file is part of the binding contract of AGENTS.md and binds exactly as it does. AGENTS.md keeps the short rule and points here; when the two differ, this file wins, and a change to one updates the other in the same commit. The headings below are the sections of AGENTS.md that held this text until 2026-11-11, so references such as "AGENTS.md, Host/core maintenance" resolve here.

Project name and technical compatibility

The project is named Galaxy Shell as of 2026-11-05, formerly Agent Native OS. The canonical repository is naaando/galaxy-shell. See openspec/changes/naming/design.md and docs/galaxy-shell.html. Use Galaxy Shell in project prose. Preserve existing runtime identifiers, exact protocol/window titles, agent-native-os paths and executables, AGENT_NATIVE_* variables, package names and existing profiles. This branding decision does not authorize migrating these compatibility contracts or restarting a session. The local checkout folder is not one of these contracts; see openspec/changes/naming/design.md, section Local checkout folder. On 2026-11-06 the owner set the target ("todos os lugares devem chamar galaxy shell"): macOS and Windows use Galaxy Shell from the start, and Linux gets a scoped compatibility migration in the order of openspec/changes/naming/design.md, section Name everywhere. Until each of its steps lands, the rules above stay current on Linux.

Current operating philosophy

The shell AI must have the context and the tools to inspect, operate and evolve the system itself: interface, host, core, OpenCode, Smithay and installation, with the privileges of the user. This direction supersedes the historical restrictions below that limited the product agent to the three UI files or required external development for every core change. See openspec/specs/self-maintenance/spec.md. Use system_context to find the real paths and state; use execute_command and command_status for maintenance operations that do not depend on the compositor. Generated HTML stays isolated and does not receive these tools. Visual customization of the profile must keep the read_ui/replace_ui cycle for style.css. HTML/React and host controls are trusted sources of the checkout and require maintenance and a rebuild, or the overlay of the chat host: whole files that the user approves in the review card and activates separately (openspec/specs/immutable-base/spec.md, The overlay; since 2026-11-05). Preserve profile, history, applications and recovery. Before you restart the runtime itself, prepare a tested release, a persistent plan and external supervision with rollback. Do not claim that the conversation is available during a failure of the core, the provider or the compositor.

Whatever the user can change, the user can ask for in userland (owner, 2026-11-13: "tudo que podemos alterar deveria ser possível o usuário pedir para alterar no userland"). A default always exists and lives outside the compositor code ("sempre deve ter um default nesse caso ... o código disso deveria poder ser ajustado sem mexer no compositor"): every window effect has its default in the built-in base theme pack, a shader and CSS pack like the others, which a profile copy adjusts without a rebuild. A request that draws on windows still waits for its protected approval: the host approval of window effects that the agent generates is a separate change, and the protected settings and boundaries below still bind.

Current direction

The paragraphs on the library, Motion and the window themes below are summaries; the full decisions, with their dates and owner quotes, are in the section Binding contract (from AGENTS.md) of the doc that each names, and they bind exactly as AGENTS.md does.

On 2026-10-27 the project owner approved Smithay as the only compositor, React + Electron for the UI, and loading the active project tree from a subfolder of the home directory. River was removed from the product code and installers. River references in the evidence are historical. The data directory can stay named river-shell to preserve the profile. See openspec/specs/project-loading/spec.md and docs/smithay-development.md. Recovery uses a known-good Smithay and external supervision. Do not end the session in use and do not start a nested session without an explicit request. The request of the user on 2026-11-01 ("voce conseguiria adaptar para sempre testarmos com uma sessao nested?") is a standing authorization for nested QA through scripts/nested-qa.py and nothing else; see docs/nested-qa.md.

The user clarified that they prefer to keep all visual components web-based, including bars, widgets, controls, custom window frames and the overview interface. Smithay handles compositing, transforms, GPU effects, focus and input; do not create a second native UI in it. Historical native elements that still exist do not mean the migration is complete. Preserve the separation between the protected host and generated HTML. See openspec/changes/archive/2026-10-27-ui-compositor-rendering/design.md and docs/architecture-decisions.md.

System UI library (decided 2026-11-02, library replaced 2026-11-04): the whole system UI is React with shadcn/ui on Base UI and lucide-react icons, including the chat, the composer, the bars, settings, the panels, the overview, the approval dialogs, the change review card, recovery, the wallpaper page and the lock screen. Generated HTML and isolated plugin panels are not system UI and stay in their opaque iframes. New UI work uses React and shadcn/ui, never new plain DOM components or a CSS-only imitation; a surface that is still HeroUI moves in its phase. Each phase replaces the old surface in the same commit, with no setting, no safeguard and no plain HTML fallback, and the rollback is a git revert; the lock screen moves last and its React form never keeps the password in React state. The whole system has one style with the chat and the composer as the reference; the approval dialogs, the change review card, the panel confirmations and the lock screen keep their fixed palette, and the review card and the panel confirmations are manual popovers in the top layer over a slot that keeps their place (naaando/galaxy-shell#17). System CSS uses only the semantic design tokens of host/theme.css (openspec/specs/css-structure/spec.md, section Design tokens), and web-shell/test/design-tokens.test.js refuses new literals. Full text: openspec/specs/shadcn-migration/spec.md, section Binding contract (from AGENTS.md).

Motion (adopted 2026-11-05, extended 2026-11-06): every component that we make is React. CSS stays the default for animation; Motion (motion) is only for exits, layout and reorder animation and springs, through m under LazyMotion ... strict and MotionConfig reducedMotion="user", or the animate of motion/mini where the profile CSS must own the resting look. The approval dialogs, the change review card, the lock screen, recovery, the wallpaper, the bottom bar tabs and the overview cards stay without Motion on purpose. Full text: openspec/specs/motion/spec.md, section Binding contract (from AGENTS.md).

Window themes (decided 2026-11-06, Office reference replaced 2026-11-09): the protected setting uiTheme selects the theme (office by default, galaxy, formerly glass, ninja or lumen); a theme is one token file in host/ui-themes/, one entry in core/ui-themes.js and a layout. Every panel in glass now means the galaxy theme, and one style and the design tokens stay for every theme. Office has one 48 px taskbar at the bottom and no top bar, positioned after the owner's Windows 10-style picture (positioning only, not colors); the glass keeps its two bars. Ninja is experimental: a top bar of three islands, cut glass and one fixed palette (Grafite, Fumaça, Marfim, with coral and amber) whose main accent is the profile color (mint when none was chosen), and four photo ambiances of its wallpaper chosen in Settings. Lumen (accepted by the owner on 2026-11-16, no longer experimental) has a thin 32 px top bar (the overview at the left, the clock and the bell in the center, the status at the right) and an app dock of 80 px at the bottom (chat, pinned and running applications, the app grid, the trash) that the compositor hides while a window covers it (intellihide) and shows again at the bottom edge. Full text: openspec/specs/ui-themes/spec.md, section Binding contract (from AGENTS.md).

On 2026-10-28 the user decided that dragging windows between overview cards must never be implemented, because it does not fit the philosophy of the project. Do not propose or plan this feature as a future evolution. This decision replaces item 3 of the visual effects proposal; see docs/architecture-decisions.md and openspec/specs/visual-effects-3d-shaders/spec.md.

Before you implement, read the docs of the area that you touch (index in docs/README.md). README.md, openspec/specs/interaction-decisions/spec.md, openspec/changes/archive/2026-10-26-web-shell-mvp/design.md and docs/web-shell-development.md hold the background of the chat-first shell; until 2026-11-11 this sentence required reading all four before any implementation. The user authorized the integration of real windows, currently through Smithay, and an initial interface with only a central chat. The first validation was nested; the direct Smithay session is already in use, still experimental. Do not start another session to validate a shell update, except the private nested QA run of scripts/nested-qa.py (docs/nested-qa.md). On 2026-11-01 the user asked for a workspace canvas with a camera and a floating chat; see openspec/specs/canvas-windows/spec.md and docs/architecture-decisions.md. It ships in phases behind the protected setting canvas. The earlier rule that kept the infinite canvas outside the milestone is history. Loadable GPU effects have their own contract in openspec/specs/themes/spec.md and openspec/specs/visual-effects-3d-shaders/spec.md; do not assume that every effect is validated just because a shader exists. See docs/smithay-development.md for the current implementation and openspec/changes/archive/2026-10-26-river-development/design.md only as history.

Flutter is preserved as WIP on another branch. The Rust/Iced prototype was removed on 2026-10-30 and stays in the Git history (commit f615cab). Do not expand these UIs as the definitive implementation out of inertia.