decky-music: Instructions file for Codex

AGENTS.md

decky-music AGENTS.md is an instructions file for Codex, OpenCode from jinzhongjia/decky-music. It costs 3,735 tokens per session, scanned B, original, MIT.

Repository instructions for Decky Music, a Steam Deck music plugin with a React interface, Python bridge, and separate music-provider and audio-player processes.

In plain words
What is it for?
Use them when changing the Decky UI, bridge methods, music providers, audio playback, plugin APIs, tests, or build configuration.
Why use it?
They explain how the plugin’s parts communicate and where code belongs, reducing the risk of breaking its interfaces or packaging.

Instructions file for CodexOpenCode

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

This is jinzhongjia/decky-music's own configuration. It tells Codex and OpenCode how to work on decky-music 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 decky-music configures →

Reuse

Borrowing it

Nothing to install: this file belongs to jinzhongjia/decky-music. 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/jinzhongjia/decky-music/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/jinzhongjia/decky-music

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 decky-music AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/jinzhongjia/decky-music/agents-md/github.svg)](https://agentmods.dev/instructions/jinzhongjia/decky-music/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/jinzhongjia/decky-music/agents-md"><img src="https://agentmods.dev/badge/instructions/jinzhongjia/decky-music/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 decky-music AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/jinzhongjia/decky-music/agents-md"><img src="https://agentmods.dev/badge/instructions/jinzhongjia/decky-music/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3,735 This file is loaded in full into every session.
When invoked 3,735 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.03735 $0.03735
Opus 5 $0.01868 $0.01868
Sonnet 5 $0.00747 $0.00747
Haiku 4.5 $0.00374 $0.00374

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

Security

Grade B, and why

decky-music 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.

sudo ./cli/decky plugin build . # 官方 CLI 打包整个插件 → out/<name>.zip(需 Docker + sudo)
AGENTS.md · 209 lines

How it starts

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

AGENTS.md

Library

以下为使用的库:

架构速览

UI 只跟 bridge 说话;bridge 是唯一常驻的真相源;provider / player 是插件沙盒外的独立二进制。

UI (React)  ──Decky RPC(callable/emit)──  bridge (main.py)
                                              │  UDS + NDJSON,bridge 作 server
                            ┌─────────────────┴─────────────────┐
                      provider 进程                          player 进程
                 qq: Python+Nuitka / ncm: Rust                 Rust
                 出元数据·歌词·可播 URL                    拉流·解码·出声

目录:

  • main.py —— 只剩对外接口 facade:CALLABLES 白名单 + __getattr__ 转发给 bridge (Decky loader 按名 getattr 分发,不必逐个写同名方法;tests/test_callables.py 机械校验白名单 ↔ Bridge 方法 ↔ src/api.ts 三端一致)
  • py_modules/ —— bridge 实现(bridge.py 总线 + 进程管理 / log.py 日志);放这里才被 Decky 加进 sys.path 且被 CLI 打包
  • src/ —— React UI:index.tsx(definePlugin 入口)/ QAM.tsx(QAM 面板)/ Page.tsx(大屏页,导出 ROUTE)/ api.ts(前端↔bridge 唯一接口层)/ errors.ts+ErrorBanner.tsx+Boundary.tsx(错误纵深)/ Footer.tsx / i18n.ts
  • player/ —— Rust,reqwest + rodio
  • ncm-provider/ —— Rust,依赖 ncm-api-rs
  • qq-provider/ —— Python,依赖 qqmusic_api,Nuitka --standalone 打包

Coding rules

  • 不要写过长的代码,例如单文件超过 500 行,函数超过 50 行。
  • 插件支持 i18n,支持语言为 中文 和 英文。
  • 开发完一部分后就提示用户提交代码,避免一次性提交过多代码。

Dev environment

  • 部署目标:Steam Deck(SteamOS,gamescope 会话)。SSH/路径见 scripts/deploy.sh
  • bridge 跑在 Decky 冻结的 CPython 里,只能用 stdlib,严禁第三方依赖(编译扩展会随 Decky 升级崩)。
  • 三个二进制通过 Decky remote_binary(package.json)在安装时下载,不进插件包。
  • 改了 player / provider 代码必须先重建二进制再部署:deploy.sh 只搬运 target/release/*qq-provider/build/*.tar.gz已有的产物,不自动重建。改了 Rust/Python 后先 bash scripts/build-rust.sh -p <player|ncm-provider> / bash scripts/build-qq-provider.sh 再 deploy,否则装的是旧二进制。只改前端则 deploy 会自己 pnpm build

Read the full file on GitHub · 209 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 · 209 lines · 3,735 tokens per session scan B d52276e91020

Subscribe to this mod's changes

decky-music AGENTS.md is an instructions file published in the GitHub repository jinzhongjia/decky-music (119 stars, last pushed 7d ago), licensed MIT. It adds 3,735 tokens to every session, about $0.0187 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-30.

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