0004: Tailoring harness: one language, checked facts, a page budget¶
- Date: 2026-11-10
- Status: accepted
Problem¶
Tailoring an English resume to a Chinese job description produced mixed text, such as
evals (评测指标) and Agent框架. It appended job keywords in brackets, as in
the rules (Agent Harness). It also kept every item, so the resume ran to two pages.
The prompt had six rules. Validation checked only for new years and changed ###
headings. A section that failed validation was still used on export.
Research¶
Open-source tailors reviewed on 2026-11-10:
- Resume-Matcher (Apache-2.0): truthfulness rules, an explicit output language, edits that quote the original, bullet relevance scores, and a list of AI-sounding phrases.
- career-ops (MIT): one output language whatever the job description's language;
keywords reworded only when they mean the same thing; rules checked in code (banned
phrases, a fact allow-list); a page budget that never ships an overflow render. It
also notes that
letter-spacingbreaks text extraction. - LLMInternSkill (MIT): polish the expression, not the facts.
- resume-lm (AGPL): a selection pass kept apart from rewriting. Ideas only.
The shared lesson is that prompt rules alone do not hold: the reliable projects check in code and retry.
Choice¶
- One output language.
[resume] languageisen,zh, or""(the base resume's language). The prompt requires every word in that language, keeps names and technical terms as written, and forbids glosses in brackets. Job keywords in another language are translated, never copied. - Prompt. Truthfulness rules adapted from Resume-Matcher and the keyword rule from career-ops, with attribution. Bullets are ordered by relevance within each entry, and that order is what the page budget trims from.
- Checks in code, all against the base section:
- no new years or numbers;
###headings unchanged;- no more brackets than the base has;
- in an English resume, no CJK characters the base lacks;
- no new capitalised terms or tokens with digits or symbols (proper nouns and tech names);
- no banned AI phrases the base does not use.
- in a section split into
###entries (not the summary), each entry's numbers and names come from the same base entry, so a bullet cannot move to another project or role; projects may still be reordered (kairos.llm.entry_scope).
A failing section is retried once with the failures stated. If it fails again, the
base text is used on export.
4. Page budget. [resume] max_pages (default 1) and min_last_page_fill (default
0.6). A designed PDF is cut until it fits max_pages. When it then spills a little
onto its last page (less than min_last_page_fill of the page is used), it is cut
further to one page fewer, so a two-page budget gives a full second page or one
page, never a page plus a line. Cuts follow kairos.render.page_cuts: lower
projects first, then older roles and the kept projects down to one bullet, then the
newest role down to half, then the remaining projects, then the newest role down to
two. Tailoring orders projects and bullets by relevance, so cuts take the least
relevant. The cut count is found by binary search over layouts. Entries may run
across a page break, and only their header lines are kept with what follows, so
pages fill.
5. Theme. Section headings lose letter-spacing, and a test extracts a rendered
PDF's text to keep headings whole.