Skip to content

Codex Formatter

PromptScript compiles your .prs sources to native Codex configuration. The main output is AGENTS.md. It is not enabled by default, add it to targets to use it.

Enable the Target

targets:
- codex

Pick an output version when you need more than the default:

targets:
- codex:
version: full

At a Glance

PropertyValue
TierTier 1
Main outputAGENTS.md
Dot directory.codex/
SkillsYes (.agents/skills/<name>/SKILL.md)
AgentsYes (.codex/agents/<name>.toml)
CommandsNo
Local filesNo

Output Files

FilePathPurpose
Main instructionsAGENTS.mdPrimary rule file
Lifecycle hooks.codex/hooks.jsonProject hooks in multifile and full modes
Skills.agents/skills/<name>/SKILL.mdReusable skill definitions
Agents.codex/agents/<name>.tomlAgent configurations

Output Versions

VersionOutput
simpleSingle AGENTS.md file
multifileAGENTS.md + .codex/agents/.toml
full (default)AGENTS.md + .codex/agents/.toml + .agents/skills//SKILL.md

MCP and Hooks

BlockSupport
@mcpServers.codex/mcp.json (json)
@hooks.codex/hooks.json in multifile, full
Hook eventspre-terminal-command, pre-tool-use, post-tool-use, session-start, setup, subagent-start, stop

Native hook reference: https://developers.openai.com/codex/hooks

Supported Features

FeatureSupported
Markdown OutputYes
MDC FormatNo
Code BlocksYes
Mermaid DiagramsNo
Single File OutputYes
Multiple Rule FilesNo
Workflow FilesNo
Nested Directory StructurePartial
YAML FrontmatterNo
Description in FrontmatterNo
Globs in FrontmatterNo
Activation TypeNo
Glob Pattern TargetingNo
Always Apply RulesYes
Manual ActivationNo
Auto/Model ActivationNo
Structured ExamplesYes
Character Limit ValidationNo
Content Section SplittingYes
Guard DependenciesYes
Context File InclusionNo
@-MentionsNo
Tool IntegrationNo
Path-Specific RulesPartial
Prompt FilesNo
Slash CommandsNo
SkillsYes
Agent InstructionsYes
Local MemoryNo
Nested MemoryYes

See Also