oh-my-customcodex 0.3.5 → 0.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -6
- package/dist/cli/index.js +37 -37
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/templates/AGENTS.md.en +2 -1
- package/templates/AGENTS.md.ko +2 -1
- package/templates/guides/agents-md-quality/README.md +1 -1
- package/templates/manifest.json +2 -2
package/README.md
CHANGED
|
@@ -29,7 +29,8 @@ oh-my-customcodex is built on two ideas:
|
|
|
29
29
|
|
|
30
30
|
| Compile Concept | oh-my-customcodex |
|
|
31
31
|
|----------------|-----------------|
|
|
32
|
-
| Source
|
|
32
|
+
| Source repository authoring | `.codex/skills/` — skill definitions maintained by this package itself |
|
|
33
|
+
| Installed runtime skills | `.agents/skills/` — reusable knowledge and workflows deployed into managed projects |
|
|
33
34
|
| Build artifacts | `.codex/agents/` — executable specialists assembled from skills |
|
|
34
35
|
| Compiler | `mgr-sauron` (R017) — structural verification and integrity |
|
|
35
36
|
| Spec | `.codex/rules/` — constraints and build rules |
|
|
@@ -270,25 +271,33 @@ omcustomcodex serve-stop # Stop Web UI
|
|
|
270
271
|
|
|
271
272
|
## Project Structure
|
|
272
273
|
|
|
274
|
+
### Managed project runtime
|
|
275
|
+
|
|
273
276
|
```
|
|
274
277
|
your-project/
|
|
275
278
|
├── AGENTS.md # Entry point
|
|
276
279
|
├── .codex/
|
|
277
280
|
│ ├── agents/ # 48 agent definitions
|
|
278
|
-
│ ├── skills/ # 108 skill modules
|
|
279
281
|
│ ├── rules/ # 22 governance rules (R000-R021)
|
|
280
282
|
│ ├── hooks/ # 15 lifecycle hook scripts
|
|
281
283
|
│ ├── schemas/ # Tool input validation schemas
|
|
282
284
|
│ ├── specs/ # Extracted canonical specs
|
|
283
285
|
│ ├── contexts/ # 4 shared context files
|
|
284
286
|
│ └── ontology/ # Knowledge graph for RAG
|
|
285
|
-
|
|
286
|
-
└──
|
|
287
|
-
=======
|
|
287
|
+
├── .agents/
|
|
288
|
+
│ └── skills/ # 112 installed skill modules
|
|
288
289
|
└── guides/ # 40 reference documents
|
|
289
|
-
>>>>>>> origin/develop
|
|
290
290
|
```
|
|
291
291
|
|
|
292
|
+
### Source Repository And Compatibility Surfaces
|
|
293
|
+
|
|
294
|
+
- This repository keeps package-authoring skills in `.codex/skills/`; that is a source-repo surface, not the installed project skill path.
|
|
295
|
+
- Installed projects use `.agents/skills/` for managed skills and `.codex/agents/*.md` for managed agents.
|
|
296
|
+
- `templates/.claude/` and `templates/CLAUDE.md*` remain upstream-compatible template inputs; they are not the active Codex runtime surface after install.
|
|
297
|
+
- `.codex/hooks/` is the OMX-managed hook script layer used by this package. Native Codex `hooks.json` discovery is a separate contract and is not generated by `omcustomcodex` today.
|
|
298
|
+
- Native Codex custom subagents in `.codex/agents/*.toml` may coexist, but `omcustomcodex` currently manages `.codex/agents/*.md` as its own agent contract.
|
|
299
|
+
- Project-scoped MCP configuration lives in `.codex/config.toml`, and the managed project registry lives in `~/.oh-my-customcodex/projects.json`.
|
|
300
|
+
|
|
292
301
|
---
|
|
293
302
|
|
|
294
303
|
## External Tool Integrations
|
package/dist/cli/index.js
CHANGED
|
@@ -3091,7 +3091,7 @@ var init_package = __esm(() => {
|
|
|
3091
3091
|
workspaces: [
|
|
3092
3092
|
"packages/*"
|
|
3093
3093
|
],
|
|
3094
|
-
version: "0.3.
|
|
3094
|
+
version: "0.3.8",
|
|
3095
3095
|
description: "Batteries-included agent harness on top of GPT Codex + OMX",
|
|
3096
3096
|
type: "module",
|
|
3097
3097
|
bin: {
|
|
@@ -28614,11 +28614,28 @@ init_fs();
|
|
|
28614
28614
|
init_logger();
|
|
28615
28615
|
init_layout();
|
|
28616
28616
|
import { execSync as execSync6 } from "node:child_process";
|
|
28617
|
-
import { writeFile as writeFile2 } from "node:fs/promises";
|
|
28617
|
+
import { readFile as readFile3, writeFile as writeFile2 } from "node:fs/promises";
|
|
28618
28618
|
import { join as join8 } from "node:path";
|
|
28619
|
+
var PROJECT_CONFIG_DIR = ".codex";
|
|
28620
|
+
var PROJECT_CONFIG_FILE = "config.toml";
|
|
28621
|
+
var ONTOLOGY_SERVER_TABLE = "[mcp_servers.ontology-rag]";
|
|
28622
|
+
function getProjectMCPConfigPath(targetDir) {
|
|
28623
|
+
return join8(targetDir, PROJECT_CONFIG_DIR, PROJECT_CONFIG_FILE);
|
|
28624
|
+
}
|
|
28625
|
+
function renderOntologyMCPBlock(ontologyDir) {
|
|
28626
|
+
return `${ONTOLOGY_SERVER_TABLE}
|
|
28627
|
+
command = ".venv/bin/python"
|
|
28628
|
+
args = ["-m", "ontology_rag.mcp_server"]
|
|
28629
|
+
|
|
28630
|
+
[mcp_servers.ontology-rag.env]
|
|
28631
|
+
ONTOLOGY_DIR = "${ontologyDir}"
|
|
28632
|
+
`;
|
|
28633
|
+
}
|
|
28634
|
+
function hasOntologyMCPConfig(content) {
|
|
28635
|
+
return content.includes(ONTOLOGY_SERVER_TABLE);
|
|
28636
|
+
}
|
|
28619
28637
|
async function generateMCPConfig(targetDir) {
|
|
28620
28638
|
const layout = getProviderLayout();
|
|
28621
|
-
const mcpConfigPath = join8(targetDir, ".mcp.json");
|
|
28622
28639
|
const ontologyDir = join8(layout.rootDir, "ontology");
|
|
28623
28640
|
const ontologyExists = await fileExists(join8(targetDir, ontologyDir));
|
|
28624
28641
|
if (!ontologyExists) {
|
|
@@ -28628,7 +28645,7 @@ async function generateMCPConfig(targetDir) {
|
|
|
28628
28645
|
execSync6("uv --version", { stdio: "pipe" });
|
|
28629
28646
|
} catch {
|
|
28630
28647
|
warn("uv (Python package manager) not found. Install it with: curl -LsSf https://astral.sh/uv/install.sh | sh");
|
|
28631
|
-
warn("Skipping ontology-rag MCP configuration. You can set it up manually later.");
|
|
28648
|
+
warn("Skipping ontology-rag MCP configuration in .codex/config.toml. You can set it up manually later.");
|
|
28632
28649
|
return;
|
|
28633
28650
|
}
|
|
28634
28651
|
try {
|
|
@@ -28637,41 +28654,24 @@ async function generateMCPConfig(targetDir) {
|
|
|
28637
28654
|
} catch (error2) {
|
|
28638
28655
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
28639
28656
|
warn(`Failed to setup ontology-rag: ${msg}`);
|
|
28640
|
-
warn("You can configure the MCP server manually. See: https://github.com/baekenough/oh-my-customcodex/tree/develop/packages/ontology-rag");
|
|
28657
|
+
warn("You can configure the MCP server manually in .codex/config.toml. See: https://github.com/baekenough/oh-my-customcodex/tree/develop/packages/ontology-rag");
|
|
28641
28658
|
return;
|
|
28642
28659
|
}
|
|
28643
|
-
const
|
|
28644
|
-
|
|
28645
|
-
|
|
28646
|
-
|
|
28647
|
-
|
|
28648
|
-
|
|
28649
|
-
|
|
28650
|
-
|
|
28651
|
-
}
|
|
28652
|
-
}
|
|
28653
|
-
}
|
|
28654
|
-
};
|
|
28655
|
-
const existingConfigPath = mcpConfigPath;
|
|
28656
|
-
if (await fileExists(existingConfigPath)) {
|
|
28657
|
-
try {
|
|
28658
|
-
const { readFile: readFile3 } = await import("node:fs/promises");
|
|
28659
|
-
const existingContent = await readFile3(existingConfigPath, "utf-8");
|
|
28660
|
-
const existing = JSON.parse(existingContent);
|
|
28661
|
-
if (!existing.mcpServers?.["ontology-rag"]) {
|
|
28662
|
-
existing.mcpServers = existing.mcpServers || {};
|
|
28663
|
-
existing.mcpServers["ontology-rag"] = config.mcpServers["ontology-rag"];
|
|
28664
|
-
await writeFile2(mcpConfigPath, `${JSON.stringify(existing, null, 2)}
|
|
28665
|
-
`);
|
|
28666
|
-
}
|
|
28667
|
-
} catch {
|
|
28668
|
-
await writeFile2(mcpConfigPath, `${JSON.stringify(config, null, 2)}
|
|
28669
|
-
`);
|
|
28660
|
+
const configPath = getProjectMCPConfigPath(targetDir);
|
|
28661
|
+
await ensureDirectory(join8(targetDir, PROJECT_CONFIG_DIR));
|
|
28662
|
+
let existingContent = "";
|
|
28663
|
+
if (await fileExists(configPath)) {
|
|
28664
|
+
existingContent = await readFile3(configPath, "utf-8");
|
|
28665
|
+
if (hasOntologyMCPConfig(existingContent)) {
|
|
28666
|
+
info("ontology-rag MCP server already configured");
|
|
28667
|
+
return;
|
|
28670
28668
|
}
|
|
28671
|
-
} else {
|
|
28672
|
-
await writeFile2(mcpConfigPath, `${JSON.stringify(config, null, 2)}
|
|
28673
|
-
`);
|
|
28674
28669
|
}
|
|
28670
|
+
const block = renderOntologyMCPBlock(ontologyDir);
|
|
28671
|
+
const nextContent = existingContent.trim() ? `${existingContent.trimEnd()}
|
|
28672
|
+
|
|
28673
|
+
${block}` : block;
|
|
28674
|
+
await writeFile2(configPath, nextContent, "utf-8");
|
|
28675
28675
|
info("ontology-rag MCP server configured successfully");
|
|
28676
28676
|
}
|
|
28677
28677
|
async function checkUvAvailable() {
|
|
@@ -30689,7 +30689,7 @@ import { join as join14 } from "node:path";
|
|
|
30689
30689
|
// src/cli/serve.ts
|
|
30690
30690
|
import { spawn } from "node:child_process";
|
|
30691
30691
|
import { existsSync as existsSync3 } from "node:fs";
|
|
30692
|
-
import { readFile as
|
|
30692
|
+
import { readFile as readFile4, unlink, writeFile as writeFile3 } from "node:fs/promises";
|
|
30693
30693
|
import { join as join13 } from "node:path";
|
|
30694
30694
|
var DEFAULT_PORT = 4321;
|
|
30695
30695
|
var PID_FILE = join13(process.env.HOME ?? "~", ".omcodex-serve.pid");
|
|
@@ -30709,7 +30709,7 @@ function buildServeEnv(port, projectRoot) {
|
|
|
30709
30709
|
async function readPidFromKnownFiles() {
|
|
30710
30710
|
for (const pidFile of [PID_FILE, LEGACY_PID_FILE]) {
|
|
30711
30711
|
try {
|
|
30712
|
-
const raw = await
|
|
30712
|
+
const raw = await readFile4(pidFile, "utf-8");
|
|
30713
30713
|
const pid = Number(raw.trim());
|
|
30714
30714
|
if (Number.isFinite(pid) && pid > 0) {
|
|
30715
30715
|
return { pid, path: pidFile };
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
package/templates/AGENTS.md.en
CHANGED
|
@@ -129,10 +129,11 @@ project/
|
|
|
129
129
|
+-- AGENTS.md # Entry point
|
|
130
130
|
+-- .codex/
|
|
131
131
|
| +-- agents/ # Subagent definitions (44 files)
|
|
132
|
-
| +-- skills/ # Skills (74 directories)
|
|
133
132
|
| +-- rules/ # Global rules (R000-R020)
|
|
134
133
|
| +-- hooks/ # Hook scripts (security, validation, HUD)
|
|
135
134
|
| +-- contexts/ # Context files (ecomode)
|
|
135
|
+
+-- .agents/
|
|
136
|
+
| +-- skills/ # Installed skills (74 directories)
|
|
136
137
|
+-- guides/ # Reference docs (26 topics)
|
|
137
138
|
```
|
|
138
139
|
|
package/templates/AGENTS.md.ko
CHANGED
|
@@ -129,10 +129,11 @@ project/
|
|
|
129
129
|
+-- AGENTS.md # 진입점
|
|
130
130
|
+-- .codex/
|
|
131
131
|
| +-- agents/ # 서브에이전트 정의 (44 파일)
|
|
132
|
-
| +-- skills/ # 스킬 (74 디렉토리)
|
|
133
132
|
| +-- rules/ # 전역 규칙 (R000-R020)
|
|
134
133
|
| +-- hooks/ # 훅 스크립트 (보안, 검증, HUD)
|
|
135
134
|
| +-- contexts/ # 컨텍스트 파일 (ecomode)
|
|
135
|
+
+-- .agents/
|
|
136
|
+
| +-- skills/ # 설치된 스킬 (74 디렉토리)
|
|
136
137
|
+-- guides/ # 레퍼런스 문서 (26 토픽)
|
|
137
138
|
```
|
|
138
139
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
5
|
-
Quality criteria for `.
|
|
5
|
+
Quality criteria for managed agent markdown files (the `omcustomcodex` runtime contract uses `.codex/agents/*.md`). Adapted from ETH Zurich research on LLM-generated agent configurations, modified to fit oh-my-customcodex's "create, connect, use" philosophy.
|
|
6
6
|
|
|
7
7
|
## Core Principle: LLM Generation + Human Verification
|
|
8
8
|
|
package/templates/manifest.json
CHANGED