OpenSunstar AGENTS.md

OpenSunstar AGENTS.md is an instructions file for Codex, OpenCode from alisunstar/OpenSunstar. It costs 1,063 tokens per session, scanned A, original, Apache-2.0.

A project guide for OpenSunstar’s public client and its os command-line tool for checking configuration, project readiness, and workflow rules. It also defines the boundary between public code and private commercial services.

In plain words
What is it for?
Use it when diagnosing agent-tool configuration, validating project workflow gates, checking project status, preparing releases, or previewing command-line changes.
Why use it?
It helps keep private billing, team, and cloud-management code out of public releases and makes automated checks produce predictable results.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/alisunstar/opensunstar/agents-md
Clone the repo
git clone --depth 1 https://github.com/alisunstar/OpenSunstar

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 OpenSunstar AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/alisunstar/opensunstar/agents-md.svg)](https://agentmods.dev/instructions/alisunstar/opensunstar/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/alisunstar/opensunstar/agents-md"><img src="https://agentmods.dev/badge/instructions/alisunstar/opensunstar/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,063 This file is loaded in full into every session.
When invoked 1,063 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.01063 $0.01063
Opus 5 $0.00531 $0.00531
Sonnet 5 $0.00213 $0.00213
Haiku 4.5 $0.00106 $0.00106

Measured 3d ago against content hash 9bd70d3c084f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

OpenSunstar AGENTS.md scanned grade A with 0 findings 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 3d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 100 lines

How it starts

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

AGENTS.md — AI Agent Integration Guide

商业控制面隔离与发版边界

账号、订阅与计费、多租户团队服务及云端运维属于独立维护的私有商业控制面,是 OpenSunstar 核心商业化许可边界。本公开仓库仅包含 Apache-2.0 授权的公共客户端、os CLI、本地配置与工作流能力,以及展示或调用可选控制面能力的客户端侧集成。

发版、README/website 同步、tag、GitHub Release、npm 发布与远程推送时,必须保持以下隔离:

  • 私有商业控制面源码、服务端实现、计费系统、多租户服务、云端运维配置与部署脚本,必须保留在独立私有远程仓库和本地私有仓库。
  • 本仓库发版内容不得包含 opensunstar-control-planecontrol-plane 私有目录、@opensunstar/control-plane 包,或 E:\projects\opensunstar-control-plane 本地路径内容。
  • 若商业控制面有更新,必须独立安排私有仓库提交、推送、部署与发版,不与本公开仓库发版混合。
  • 公共客户端中保留的订阅账号、团队配置等 UI / API 适配仅代表客户端入口,不等同于私有商业控制面源码授权。

CLI 治理与编排工具 (os)

当检测到 AI 编程工具配置异常时,可运行以下命令诊断:

os drift check --json          # 检查配置漂移
os readiness score --json      # Agent 就绪度评分
os doctor --json               # 环境诊断
os flow validate --json        # 阶段门禁校验
os flow validate --strict --json  # 跨模块治理门禁(检查设计合约/Recipe/Specs 就位)
os project status --json       # 项目全景状态(聚合编排+资产+漂移)

退出码约定: 0=正常, 1=有发现(如漂移/门禁阻断), 2=治理门禁阻断(strict), 3=错误 所有命令支持 --json 输出机器可读格式。 写操作支持 --dry-run 预览和 --yes 跳过确认。

全局选项

选项 说明
--json 输出 JSON 格式(机器消费)
--timeout <seconds> 操作超时(秒),防止 Agent 会话无限挂起

错误输出格式

JSON 模式下错误输出包含 codemessagehint 三字段,便于 Agent 自动诊断:

{
  "error": true,
  "code": "error",
  "message": "数据库不存在: ...",
  "hint": "运行 os config bootstrap --yes 初始化,或检查 ~/.OpenSunstar 目录权限"
}

常用诊断流程

# 0. 首次使用(无 GUI 时)
os config bootstrap --yes

# 1. 环境健康检查
os doctor --json

# 2. 配置漂移扫描(强制刷新缓存)
os drift check --refresh --json

# 3. 就绪度评分
os readiness score --json

# 4. 漂移修复(预演)
os drift repair --dry-run --json

# 5. 漂移修复(执行)
os drift repair --yes --json

项目编排闭环

# 项目全景状态(聚合 DB 资产 + 文件系统编排状态)
os project status --project-path /path/to/project --json

# 阶段门禁(标准:检查 .specs/ 工件)
os flow validate --project-path . --project-type web --change-id CHG-001 --target-stage implementation --json

# 阶段门禁(严格:额外检查设计合约/Recipe/FlowConfig 就位)
os flow validate --project-path . --project-type web --change-id CHG-001 --target-stage implementation --strict --json

# 导出 CI 门禁配置
os flow config --project-path . --project-type web --json

# Recipe 安装预检
os recipe plan --project-path . --name my-recipe --json

# Recipe 安装到项目
os recipe install --project-path . --name my-recipe --yes --json

Read the full file on GitHub · 100 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. 3d ago First seen · 100 lines · 1,063 tokens per session scan A 9bd70d3c084f

Subscribe to this mod's changes

OpenSunstar AGENTS.md is an instructions file published in the GitHub repository alisunstar/OpenSunstar (40 stars, last pushed 20d ago), licensed Apache-2.0. It adds 1,063 tokens to every session, about $0.0053 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.