SForum: Instructions file for Codex

AGENTS.md

SForum AGENTS.md is an instructions file for Codex, OpenCode from zhuchunshu/SForum. It costs 6,736 tokens per session, scanned A, original, MIT.

A contributor guide for SForum, an open-source forum framework designed around a core system with optional extensions for different products and service providers.

In plain words
What is it for?
Understanding the forum, identity, administration, and extension systems; choosing existing libraries; and organizing new code into focused modules.
Why use it?
It explains the project’s intended architecture and working rules so new changes remain maintainable and do not mix unrelated responsibilities.

Instructions file for CodexOpenCode

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

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

Reuse

Borrowing it

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

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

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/zhuchunshu/sforum/agents-md"><img src="https://agentmods.dev/badge/instructions/zhuchunshu/sforum/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 6,736 This file is loaded in full into every session.
When invoked 6,736 The same file — it is already loaded in full.
Security scan A 0 findings. 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.06736 $0.06736
Opus 5 $0.03368 $0.03368
Sonnet 5 $0.01347 $0.01347
Haiku 4.5 $0.00674 $0.00674

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

Security

Grade A, and why

SForum 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 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.

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 · 538 lines

How it starts

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

Agent Guide

This file is the shared working agreement for SForum. Read it before starting any new session. It is intentionally self-contained: do not assume contributors have the same personal or global Codex instructions. Personal defaults may supplement this file, while more specific repository instructions take precedence within their directory scope.

Project Intent

SForum is a maintainable, plugin-first, open-source forum framework. Core is the host framework; product verticals and provider/vendor behavior live in extensions. The repository is past scaffolding and actively implementing core forum, identity, admin, and extension systems.

Working Principles

  • Prefer mature third-party libraries before building custom infrastructure. Before starting a module or feature, briefly check whether established libraries already solve the core problem well.
  • Avoid messy, tightly coupled code. Keep responsibilities clear, name things plainly, and make the easy path maintainable.
  • Split long implementations across multiple focused files. Avoid placing more than 1000 lines in one file unless there is a strong, documented reason.
  • Keep changes scoped to the current task. Do not refactor unrelated areas just because they are nearby.
  • Record decisions in the knowledge base when they will matter to future sessions.

Stack And Directory Map

Monorepo with a Go API plus a Nuxt web app, plus shared contracts, extensions, knowledge base, and tests.

  • apps/api — Go 1.26.6 API + background worker (toolchain anchored in apps/api/go.mod; do not let docs lag behind it). Module path github.com/zhuchunshu/sforum/apps/api. Laravel-style Go layout:
    • cmd/api (HTTP server), worker (River queue worker), migrate (embedded Goose migrator), sforum (developer CLI; scaffolds plugins/themes, runs seed:forum).
    • bootstrap/ — runtime assembly; NewWorker for the worker process.
    • app/Http/ — HTTP kernel, controllers, and route registration (app/Http/Controllers/*).
    • app/Models/ — domain logic and services.
    • app/Providers/ — provider wiring (mail provider slot, attachment storage adapters, search, cache, etc.).
    • app/Support/ — cross-cutting infra: Jobs (River durable queue), Search (host framework + site PG FTS; optional Meili plugin), Cache (Redis CachedStore decorator).
    • database/migrations/ (Goose SQL), migrator/ (shared embedded migrator), queries/ + sqlc/ (sqlc-generated code; config in sqlc.yaml).
    • config/ — runtime config loaders. config.Load does NOT read .env; the dev scripts source .env and export vars explicitly.
  • apps/web — Nuxt 4 / Vue 3 / Nuxt UI 4 frontend (package name @sforum/web). SSR-first (no ssr: false remains anywhere). Key deps: Bun, Tailwind, @nuxtjs/i18n, Tiptap, DOMPurify, altcha, @iconify-json/tabler + @iconify-json/lucide. App code lives under apps/web/app/{components,composables,pages,layouts,middleware,plugins,config} with the uppercase SF prefix component library, and admin pages under apps/web/app/pages/admin. i18n default locale zh-CN, secondary en-US.
  • contracts/ — modular OpenAPI contract. openapi.yaml is the entrypoint index only; paths in openapi/paths/<module>.yaml, schemas in openapi/schemas/<module>.yaml, shared components in openapi/components/.
  • extensions/ — package trees; only builtin/ is boot-scanned into the admin list (SyncBuiltins). Also dev/ (gitignored scaffolds), optional/ (ship-with-repo, operator install), fixtures/ (CI). Layout map: extensions/README.md. Container images copy built-ins to /app/extensions/builtin.
  • knowledge/ — project memory: index.md, modules/, decisions/, sessions/, glossary.md, research.md. Read before sensitive work.
  • tests/ — repo-level validation scripts (Playwright/Node) that hit the running dev servers.
  • scripts/ — dev/test orchestration shell scripts (see Commands below).
  • docs/ — bilingual handbooks (zh-CN/, en-US/) plus path-stable extension reference under docs/extensions/; historical material in docs/archive/.
  • deploy/, compose*.yaml, deploy.sh — deployment and ops.
  • Runtime deps via Compose: PostgreSQL, Redis, Mailpit (Meilisearch optional via --profile search).

Read the full file on GitHub · 538 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 · 538 lines · 6,736 tokens per session scan A af7d93724c2a

Subscribe to this mod's changes

SForum AGENTS.md is an instructions file published in the GitHub repository zhuchunshu/SForum (202 stars, last pushed 6d ago), licensed MIT. It adds 6,736 tokens to every session, about $0.0337 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.

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

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

deepseek-harness AGENTS.md

AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.

deepseek-ai/deepseek-harness · 3,735 tokens