Input Pipeline Overview
The input side of ResumeCustomizer prepares job-specific Markdown resumes by stitching together the base resume, a job-description Markdown file, and the shared instruction prompt, then invoking the Codex CLI inside a containerized watcher.
Workflow Recap
- Ensure
input/resume/contains exactly one Markdown resume. - Drop a single job-description Markdown into
input/ForCustomizing/inbox/. - Start the watcher stack (
input/Docker/run-input-processor.sh up -d). - The watcher combines the resume, job description, and the resolved instruction prompt (defaulting to
templates/ResumeCustomizerPrompt.md.example) into a prompt, runs the Codex CLI, and writes the generated resume toForCustomizing/outbox/YYYY/MM/DD/HHMM/. - Successful runs archive the job description under
ForCustomizing/processed/and copy the prompt used into the same outbox folder. Failures move the job description intoForCustomizing/failed/for review.
The human operator reviews the Codex output Markdown, makes any edits, and then manually hands it off to the output pipeline for document rendering.
Container Stack
The watcher lives in input/Docker/:
Dockerfile– builds a Node/Python base image, installs gosu, and prepares a non-rootcodexuser.watch_and_customize.py– polls the inbox, validates preconditions, resolves the prompt template (ResumeCustomizerPrompt.mdor its.examplefallback), constructs prompts, runs Codex, and routes files.entrypoint.sh– maps the container user to the caller’s UID/GID and ensures shared directories exist.run-input-processor.sh– wrapper arounddocker composethat mounts your~/.codexdirectory and forwards CLI arguments.docker-compose.yml– defines the container, volumes, environment variables, and restart policy (noso fatal errors halt the stack).
Templates
templates/ResumeCustomizerPrompt.md.exampleships with default Codex instructions.- To customize, copy the
.examplefile totemplates/ResumeCustomizerPrompt.md(the.gitignorekeeps your local overrides out of version control).
Key Environment Variables
CODEX_COMMAND_TEMPLATE– format string for invoking Codex (placeholders:{prompt},{output}).POLL_INTERVAL_SECONDS– watch loop delay (defaults to 5).CODEX_TIMEOUT_SECONDS– wall-clock timeout for each Codex call (defaults to 600).CODEX_CONFIG_DIR– host path to mount as/home/codex/.codex(defaults to${HOME}/.codexvia the wrapper).
Prerequisites
- Docker Engine with the Compose plugin (
docker compose) or the standalonedocker-composebinary. - A working Codex CLI and credentials in
~/.codex. The Docker build attemptsnpm install --location=global codex-cli; override or update as needed if packages change.
Failure Modes
- Multiple resumes or job descriptions – watcher exits immediately with a fatal configuration error. Fix the files and restart.
- Codex CLI missing or failing – job description moves to
ForCustomizing/failed/; inspect container logs, resolve, and requeue. - Timeouts – treat as failures; adjust
CODEX_TIMEOUT_SECONDSif Codex regularly needs more time.
For day-to-day operating guidelines, see input/AGENTS.md.