/** * Codex platform adapter. * * Generates: * - Canonical skill bodies copied to `.aidlc/skills/` * - One Codex skill per lifecycle skill at `.agents/skills//SKILL.md`, with * its implicit-invocation policy beside it in `agents/openai.yaml` * (native-skill-metadata) * - A single `merge-block` into `AGENTS.md` at project root containing * overview, state protocol, per-phase pointers to `.aidlc/skills/`, and * context-doc references. * - One custom agent per agent definition at `.codex/agents/.toml`, with a * read-only sandbox (native-reviewer-agent). * * Requirements: 1.1, 1.6 * * @module */ import type { AgentDefinition, PlatformAdapter, Skill } from '../../core/types.js'; /** * Directory name for a Codex skill: `aidlc-`. * * Prefixed, through the same helper claude-code uses, so one skill name * cannot produce two directory spellings across platforms — and matching the path * `doctor/migrations/stale-idea-skill.ts` already assumes for an orphaned Codex * skill (agent-portability/AC-5). */ export declare function skillDirName(skill: Skill): string; /** * A Codex skill file. * * Codex requires `name` and `description` in frontmatter and matches a request * against the `description`, so the trigger words have to be in it. `name` equals * the directory name, because a mismatch is what claude-code's own validator * rejects and Codex's loader may too (AC-1). * * The body is the canonical skill body, not a pointer to it: a pointer is exactly * what made Codex second-class. * * `directives` go above the body, one paragraph each. Before native-reviewer-agent a Codex skill file carried none, * so the task-agents rule's condition — the skill's entry says sub-agents are * available — could never hold on Codex (AC-15). */ export declare function formatCodexSkill(skill: Skill, directives?: string[]): string; /** * A Codex skill's `agents/openai.yaml` (native-skill-metadata/AC-17). * * Written for every skill, `auto` ones included, so each directory states its own * policy and a later change of Codex's default cannot flip a skill silently (DD-3). * It holds no executable content: the only thing it does is turn implicit loading * off, which narrows the auto-loading surface agent-portability/AC-46 was about. */ export declare function formatCodexPolicy(skill: Skill): string; /** * The line that hands a skill to its agent (native-reviewer-agent/AC-16). * * Codex has no `context: fork`, so the hand-off is an instruction to the session * that loaded the skill. The fallback is spelled out because `.codex/` loads only * in a trusted project, and a review that quietly ran in the author's session * would claim an independence it does not have. */ export declare function agentDirective(agent: AgentDefinition): string; /** * A Codex custom agent file (native-reviewer-agent/AC-12, AC-13). * * `developer_instructions` is a TOML multi-line *literal* string, which * processes no escapes, so markdown passes through byte for byte. The one thing * it cannot hold is its own delimiter, and TOML forbids most control characters * in it; for those the file is not written at all, because a half-valid TOML file * is one Codex refuses to load with the agent's name on it. `description` is a * basic string, and `JSON.stringify` of a one-line string is a valid one. * * `sandbox_mode = "read-only"` is the enforcement. Whether a child spawned from a * workspace-write parent keeps it is what the live test checks * (native-reviewer-agent/AC-24). */ export declare function formatCodexAgent(agent: AgentDefinition): string | null; /** * Codex platform adapter implementation. */ export declare const codexAdapter: PlatformAdapter; //# sourceMappingURL=codex.d.ts.map