Omarchy-4-AI-Agent-MCP: Instructions file for Codex

AGENTS.md

Omarchy-4-AI-Agent-MCP AGENTS.md is an instructions file for Codex, OpenCode from hlsitechio/Omarchy-4-AI-Agent-MCP. It costs 1,700 tokens per session, scanned B, original, MIT.

Project handover notes for an AI agent working on an Omarchy desktop-control server. They describe the server’s status, conventions, known environment quirks, and planned work.

In plain words
What is it for?
Resuming development, understanding the TypeScript and Node server, following its roadmap, and using its existing desktop-window safeguards and verification practices.
Why use it?
They prevent an agent from repeating investigations or breaking important safety rules when resuming the project.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md; mentions Codex.

This is hlsitechio/Omarchy-4-AI-Agent-MCP's own configuration. It tells Codex and OpenCode how to work on Omarchy-4-AI-Agent-MCP itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything Omarchy-4-AI-Agent-MCP configures →

Reuse

Borrowing it

Nothing to install: this file belongs to hlsitechio/Omarchy-4-AI-Agent-MCP. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/hlsitechio/Omarchy-4-AI-Agent-MCP/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/hlsitechio/Omarchy-4-AI-Agent-MCP

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for Omarchy-4-AI-Agent-MCP AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md/github.svg)](https://agentmods.dev/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for Omarchy-4-AI-Agent-MCP AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/hlsitechio/omarchy-4-ai-agent-mcp/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,700 This file is loaded in full into every session.
When invoked 1,700 The same file — it is already loaded in full.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.01700 $0.01700
Opus 5 $0.00850 $0.00850
Sonnet 5 $0.00340 $0.00340
Haiku 4.5 $0.00170 $0.00170

Measured 10d ago against content hash c4e5a860ca68, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade B, and why

Omarchy-4-AI-Agent-MCP AGENTS.md scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

2. **sudo needs pkexec** when run from an agent shell (no TTY). Use
AGENTS.md · 113 lines

How it starts

The opening of the file, as written. The whole thing — 113 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AGENTS.md — omarchy-mcp

Context for any LLM/agent resuming work on this project. Read this first.

Project status

Working MCP server (TypeScript + Node, stdio) exposing Omarchy desktop commands to any LLM. Built and smoke-tested (node smoke.mjs → SMOKE_OK).

  • 108 tools implemented across src/tools/{theme,appearance,capture,desktop,windows,agents,network,local-system,defaults,device-controls,local-launchers,shell-ui,plugin-local,dangerous,health}.ts
    • src/hypr.ts (introspection & verdict engine)
  • Verification layer: mutating window tools return measured before/after state with STATUS/HINT verdicts (split_confirmed / opened_but_not_split / not_detected)
  • Self-guard: PID-ancestry lock prevents closing/tile-killing the host terminal (window_close refuses; self_window_info / self_window_snap target by address)
  • Native Lua grid layout installed: ~/.config/hypr/layouts.lua -> lua:omarchy-grid with modes grid|master, runtime cmds set/cols/rows/auto/tomaster/swap/debug/show, and MCP wrappers: layout_mode, layout_grid, layout_order, layout_tomaster, layout_swap_windows
  • One-call coding-agent orchestration: agent_grid launches homogeneous grids or mixed sparse placements (for example Claude top-right + Codex bottom-right), using per-agent app IDs and verified final geometry. The grid layout adds slot/slotlast/unslot/clearslots runtime messages for sparse cells.
  • Destructive tools gated by enableDangerous (see src/config.ts)
  • Full coverage table with per-command status lives in COMMANDS.md (markers: [x] tested, ... in progress, [!] failed, [ ] not started)

Critical environment quirks (do not rediscover these)

  1. Hyprland 0.56 Lua config: raw IPC sockets are GONE ($XDG_RUNTIME_DIR/hypr/$SIG/.socket* does not exist). All dispatches must go through: hyprctl dispatch 'hl.dsp.<expr>' where the arg is a valid Lua expression, e.g.:
    • hl.dsp.window.swap({ direction = "l" })
    • hl.dsp.layout("preselect r") — next opened window lands in that split
    • hl.dsp.window.resize({ x = 100, y = 0, relative = true })
    • hl.dsp.window.float({ action = "toggle" })
    • hl.dsp.exec_cmd("some-command") API surface discovered from /usr/share/omarchy/default/hypr/bindings/*.lua.
  2. sudo needs pkexec when run from an agent shell (no TTY). Use pkexec pacman -S --noconfirm <pkg> for installs.
  3. dsp.window.resize is RELATIVE by default. Exact sizing needs relative = false. Without it, values act as deltas (caused a real bug: window collapsed to 116px). Window-address targeting works everywhere: window = "address:0x..." (discovered from omarchy-hyprland-window-pop).
  4. float({ action = "off" }) TILES a floating window — never do this to the host terminal. action = "on" floats it.
  5. Custom Lua layouts are native (no plugins): ~/.config/hypr/layouts.lua registers lua:omarchy-grid (deterministic grid, aspect-aware auto mode). Runtime commands go to the ACTIVE layout's handler: hyprctl dispatch 'hl.dsp.layout("set 3 2")' / "auto" / "show". Existing workspaces KEEP their old layout on reload; switch them with hyprctl eval 'hl.workspace_rule({ workspace = "1", layout = "lua:omarchy-grid" })'.
  6. Visual verification works: capture_screenshot returns a PNG path; agent can Read image files directly (no external vision API needed).
  7. Closing a sibling of the host terminal: siblings can share the host's PID (one ghostty process, many windows), so pid-based guards block them too. Safe close-by-address recipe (all MCP): hypr_dispatch("hl.dsp.window.cycle_next({ next = false })") to move focus off our window -> verify focused pid via desktop_status -> hypr_dispatch('hl.dsp.window.close({ window = "address:0x..." })') — address targeting works; the charset allow-list accepts it. Layout commands go through the ACTIVE layout: hl.dsp.layout("<msg>").
  8. Requires: Hyprland 0.56+ with the Lua config bridge, omarchy CLI, wl-clipboard, and Node >= 20.
  9. Mouse-focus hazard (input:follow_mouse=1): focus follows the user's cursor, so "focused window" ops can silently re-target mid-command. Mitigations now built in:
    • dispatchTracked() (src/tools/windows.ts) records which window was focused at dispatch + warns if focus moved (window_focus, window_swap, and all no-target fallbacks).
    • Destructive tools accept explicit address/match targets (resolveTarget() in src/hypr.ts): window_resize, window_float_toggle, window_fullscreen, window_close, window_to_workspace. PREFER explicit targeting in agent flows; isSelfClient() guards close on any target.
    • Address-targeted swap works too: hl.dsp.window.swap({ window = "address:0x...", direction = "u" }) (verified live; error "No window to swap with in that direction" when the slot is empty). NOTE: float-toggle off can re-tile a window into a DIFFERENT slot — verify geometry after and restore if needed.

Read the full file on GitHub · 113 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 113 lines · 1,700 tokens per session scan B c4e5a860ca68

Subscribe to this mod's changes

Omarchy-4-AI-Agent-MCP AGENTS.md is an instructions file published in the GitHub repository hlsitechio/Omarchy-4-AI-Agent-MCP (1 stars, last pushed 7d ago), licensed MIT. It adds 1,700 tokens to every session, about $0.0085 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other instructions, from other repositories

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,296 tokens

codex AGENTS.md

AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.

openai/codex · 5,153 tokens

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 6,785 tokens

spec-kit AGENTS.md

AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.

github/spec-kit · 7,104 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).

microsoft/vscode · 5,001 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,469 tokens