# Duplicate Requisition & Legacy Artifact Recovery

Use before tailoring any job URL or pasted JD, especially when the role feels familiar.

## Duplicate guard — run before generating

1. Extract durable identifiers from the source: company, exact title, requisition/job ID, opportunity UUID, canonical URL, recruiter/client, and distinctive JD phrase.
2. Search all three evidence surfaces:
   - Current project/vault/outbox/staging filenames and memo contents.
   - Session history using requisition ID first, then company + title, then a quoted distinctive phrase.
   - Application tracker for company, staffing firm, requisition, or URL.
3. Compare identifiers, not title alone. The same title can be a new job; the same requisition/UUID is an exact duplicate. Near-verbatim anonymous JDs may be the same client requisition distributed by multiple agencies—flag probable duplicate and ask for client + requisition before authorizing another representation.
4. Separate statuses explicitly:
   - `not-run`
   - `tailored`
   - `ready-to-submit`
   - `submitted-unverified`
   - `submitted-verified`
   - `duplicate/representation-risk`
   Artifacts on disk prove tailoring, not submission. A tracker row or user statement is secondary evidence; an ATS confirmation/email is strongest when accessible.
5. If exact duplicate and artifacts are valid, do not rerun or create a new resume. Verify DOCX readback, truth-sensitive phrases, file hashes, and current accessibility; then report the existing result and next action.

## Legacy artifact recovery

Older runs may live only in `/root/.hermes/outbox/`, which is not synced to Connie. When an exact duplicate is found there:

1. Read back each DOCX and identify its purpose (resume, cover letter, requested tool brief).
2. Check for stale or risky context before recommending submission: old availability dates, temporary business names, compensation anchors, unverified tools, or claims no longer supported by the master resume.
3. Copy still-valid files to `/root/.hermes/vault/01_Job_Seeker/` and verify source/destination SHA-256 equality.
4. Write a vault memo with requisition ID, prior verdict/ATS score, current status, duplicate finding, warnings, and Windows project-copy commands.
5. Do not delete the legacy source until Rob confirms vault sync.

## Strategy interaction

A prior override is attached to that exact opportunity and rationale; it does not automatically authorize a different role. Conversely, an exact duplicate of the same requisition should retain the recorded override rationale rather than forcing Rob to repeat it.

## Common failure modes

- Re-running an exact URL because the current session lacks context.
- Treating a generated resume as proof the application was submitted.
- Searching only filenames and missing a recruiter/staffing-firm alias.
- Treating a title match as definitive when requisition IDs differ.
- Copying legacy files into the vault without reviewing stale cover-letter claims.
- Generating a second resume before checking whether the first one is already in the tracker or vault.
