ADR: The campaign sends, the model writes rows
Status: accepted in part, 2026-10-24: the rules at 1.0.4.58 (Decision 1), the database at 1.0.4.59 (Decision 2), the renderer and the shadow send at 1.0.4.60 (Decision 3), the inbox side at 1.0.4.61 (Decision 4), the lead run at 1.0.4.62 (Decision 5), the card and the alert at 1.0.4.63 (Decision 6). Filled as each rung of the campaign ships: the database, the renderer and the shadow send, the inbox side, the lead run, the card, the shadow week and the switch to on. Nothing sends while this record says shadow.
In plain words
Steve asked for an email campaign to hiring managers that runs on its own. A model is good at reading a posting and finding the one plain thing a company does, and bad at being the same twice. So the work is split down the middle. A model writes rows: who the company is, who runs its engineering team, where the address was published, one clause saying what the company makes. Code does everything that touches the send: it checks every rule, fills the approved template word for word, picks the order, holds the count, and sends. No model is in the send path, and a template changes only when Steve says yes.
This first version is the rules, written as code with no database and no mail. Each one is a test that fails the build.
Context
- Steve, 2026-10-24 12:22 CDT: "the emails should run from Azure functions and AI is only used to generate the leads", and "It sends automatically at 8:00 am". 12:30: seven days a week. 12:58, after the review: "Okay do all of that, but I'm not sure about the 3rd party for email", so there is no address finder: public sources with their URL only, no account, no key.
- The review of the plan (J:\mentor\REVIEW-EMAIL-CAMPAIGN-2026-10-24.md, findings F1 to F19 and its section 8) found what the plan missed. The do-not-apply list carries none of his five former employers (F1). A "per domain" 30-day rule misses a company under its parent and a company known only by name (F10). Template A said "I applied today" on a send the next morning (F8). Re-ranking every lead with a model every run reorders the list every run (F9). A {WhatTheyDo} written by a model can carry its voice into his email (F15). The live-thread rule had no shape in code (F16).
- The Function's Gmail token already holds gmail.modify, which can send (F4). The only things between a defect and his own inbox are the switch and the cap in code, so both are constants a test reads.
Decision
The rules are code in functions/JobHunt.Domain/Features/Campaign/, with no I/O, each held by a test that names the review's case.
FormerEmployers: Storee Construction, Conway Investment Research (also Conway Investment Solutions), Cass Information Systems, Hunter Engineering and the State of Missouri, with their variants and domains (storee.com, conwayis.com, cassinfo.com, hunter.com, mo.gov). Matched by name the way Rule 50 matches names, or by domain key. No date: a former employer stays out for good.
CompanyKey: the registrable domain, public-suffix aware for the suffixes this search meets (mail.acme.co.uk is acme.co.uk, dor.mo.gov is mo.gov). An unknown suffix over-joins, which over-holds.
ThirtyDayRule and CompanyGate: one email a company in a rolling 30 days, follow-ups counted, matched by key, by parent key, or by name. A send on day 0 holds through day 30; day 31 is the first allowed. The gate reads a former employer first and names it, then the do-not-apply list, then the 30 days.
LiveThreadRule: a tracker row for the company in the last 30 days that is a person's thread (a LinkedIn message, an email, a call, a rejection) holds the lead with its Count. An application row, the ATS sweep's receipt and an unanswered connection request do not hold: the first two are the application itself, and the third is the LinkedIn order's input.
Tells and WhatTheyDoRule: S1_WORDS and S1_PHRASES of ai_tells_five_signs.py in one constant, matched against a checked-in copy of the Python file by count and content. The clause opens with a verb from a list of fifteen, runs 20 to 110 characters, ends without punctuation, has no comma clause longer than the phrase before it, no dash, quote marks, braces or address, never names the company, and carries no tell. A failing clause blocks its lead with the rule named.
CampaignRules: DailyCap 10, Ramp 3, 5, 10 on the first three days of on, five seconds between sends.
RecipientDomainRule: business domains only (no gmail.com, yahoo.com, outlook.com, hotmail.com, icloud.com and the rest of the list), and MX records checked and found.
Strength: a formula over stored facts (remote stance, .NET evidence rows, a posted role, the band's top against $155,000 and $170,000, the ghost score, days since first seen, a .NET posting in the last 30 days), the model's step held to plus or minus one, and a 16-digit hash of the inputs so the model is asked again only when a fact moves. A ghost score of 3 or more takes 25 points, more than the rest of the formula spans.
AppliedWhen: "today", "yesterday", "on Friday", "last Saturday" from AppliedAt and the send time in Central; Track A never past seven days.
ProofKey: reliability, platform, leadership and ai, each a clause built from a line of the 2026-10-24 resume. No template has a {Proof} line yet; adding one is a template change that waits for Steve.
LinkedInOrder and SendOrder: an accepted invite first, then an invite out more than three days, then the rest; then Strength, then the oldest lead.
TemplateFill: every {Variable} from the row, a required blank fills nothing and names the blank, and an optional line goes whole with the gap under it when any of its values is blank.
The database is one Basic database, sqldb-jobhunt-ss, on the server the site already runs on, and the Function signs into it as itself.
infra/jobhunt-sql.bicep makes it and nothing else: Basic, 5 DTU, 2 GB, local backup, on sql-theyard-ss-westus3, Incremental. Its own template so a deploy touches this one database. About $4.90 a month, fixed. The free serverless offer was turned down (the review, F2): its allowance is 55 awake hours a month, a campaign that wakes it three times a day spends that by the nineteenth, and then it either pauses with nothing failing loudly or bills by the hour.
functions/JobHunt.Database is the schema, the same pattern as the site's (ADR: Data first, and the database in source control): the campaign schema, Companies (the key, the parent key, the names, the remote stance, the newest .NET posting, the public board to scan, do-not-email), CompanyEvidence (one row per posting that asks for .NET), Leads (every template variable a column, the address with the URL it was published at, MX checked, AppliedAt, the LinkedIn dates, the proof key, the follow-up post, the ghost score, Strength with its model step, reason and inputs hash, Blocked, the tagged code and its five links), and EmailsSent (both bodies, the template and its version, the Gmail ids and the Message-Id a bounce quotes back, touch, shadow, bounced, replied). Three views for the Sheet mirror later: LeadsMirror, SendsMirror, DailyCounts. CI and the gate compile it to a DACPAC.
- The Function's identity,
id-jobhunt-ss, has a contained database user made from its SID, with db_datareader and db_datawriter on this database only, never on the site's. Made by script on 2026-10-24 (CREATE USER [id-jobhunt-ss] WITH SID = 0xDD6CF11F4D186148BF294DCB9E7D89C0, TYPE = E, the SID being the bytes of the identity's client id, the same rule that gives id-theyard-ss ADR-039's 0xCAA688281CBEA546A1DEC666B1D193E5) and read back from sys.database_principals at 18:38 CDT: name=id-jobhunt-ss type_desc=EXTERNAL_USER sid_hex=0xDD6CF11F4D186148BF294DCB9E7D89C0, roles db_datareader and db_datawriter. The schema was made from these files by the same script and read back: Companies 15 columns, CompanyEvidence 6, Leads 40, EmailsSent 22, three views.
- The ports are in
JobHunt.Application/Features/Campaign/: ICompanyBook, ILeadStore, IEmailLog and IAddressFinder. SqlCampaignStore in Infrastructure answers the first three over Microsoft.Data.SqlClient with Authentication=Active Directory Managed Identity;User Id=<client id> and no secret anywhere. NoFinder is the only finder (Steve, 12:58): it asks no one and answers nothing, so an address comes only from a public page the lead run names.
- The cost card reads the database by resource from the day the bill carries it, because the cost reader groups the subscription's costs by resource id.
Code renders the approved templates and the Function sends at 8 AM Central, in shadow first.
- The templates are Steve's v1 files, byte for byte, compiled into
JobHunt.Application (Features/Campaign/Templates/A-v1.md, B-v1.md); CampaignTemplate.Current is the one constant a yes to v2 changes, with the v2 files.
TemplateRender fills every variable from the lead's row through TemplateFill and adds nothing: a plain body with the Markdown marks dropped and the links bare, and an HTML body in Gmail's own shape, a div a line, Links in bold and the five links a list of anchors named for what they open, each carrying its ?r= code. A required blank renders nothing and names it. The renders of both templates, and of an optional line with and without its values, are held byte for byte against checked-in files.
CampaignSend runs every open lead through the rules in the review's order: former employer, do-not-email, an address with its public source, not bounced, a business domain with MX found, the do-not-apply list and the 30 days, a live thread, Track A within seven days, no blank, WhatTheyDo, no tell in the rendered email. Then it takes the cap (10, or 3 and 5 on the first two days of on), the LinkedIn order, Strength and the oldest lead. A lead whose own words fail (a blank, WhatTheyDo, a tell) is marked Blocked for the next lead run; the rest are counted by reason. Version 1 of Template A says "so I applied today" in words, so a Track A email goes out only when the application was today; a yes to v2 lifts that.
CampaignSendTimer (CampaignSend in the Function) fires every hour on the hour in UTC and acts in the 8 o'clock hour Central, which is 13:00 UTC now and 14:00 from November 1, seven days a week. It is idempotent by the day's count in EmailsSent. EMAIL_CAMPAIGN is shadow in the template: every would-send is written with Shadow = 1 and both bodies, and the mail port is never built; a test holds that. on builds GmailSender, which sends a multipart message five seconds apart, refuses a header with a line break or a second address, and records the Gmail ids and the Message-Id. One line a pass goes to campaign/pass.log on the share, and the run line carries counts only.
CAMPAIGN_SQL is the connection string with the identity's client id and no secret, set in the template and, for this deploy, with az functionapp config appsettings set, which adds and replaces nothing else.
The inbox pass reads what comes back: bounces, replies and requests to stop.
- A delivery failure arrives from
mailer-daemon@googlemail.com in the thread of the email that failed, its plain body naming the address (Final-Recipient), the status and a heading such as "Address not found" (read from a real one of 2026-07-28; the test's copy has the address made up). DeliveryFailure reads it; the join to EmailsSent is the thread and the address together, so a failure for another message in the same thread is not this email's. The email is marked bounced once and the lead's address unverified with the reason.
- Two failures in one Central day write a row to
campaign/switch.log on the share: the Function cannot change its own settings, so the trip is a row the send reads before anything else, and while the newest row says shadow an on campaign writes and does not send. Only a person clears it, with a row of on and why. The pass's line says BLOCKED and the run comes to blocked, so the card goes red the hour it happens.
- Once an hour (the pass at 20 past), each real send of the last 14 days with no reply is read for a sender who is neither Steve nor the mail system. The first such sender marks the email answered; the person waiting is then the reply run's, as any person waiting is. A reply whose own lines, above the quoted original, carry a stop phrase ("not interested", "do not contact", "unsubscribe", "remove me", "no thanks" and four more) marks the company do-not-email with the date, which the send reads before anything but a former employer, and lists the thread in
campaign/stop-threads.log, which the reply run reads before it drafts (a CONVENTIONS fragment says so).
- The cost: in shadow nothing was sent, so the part reads nothing. On, at ten a day, at most 140 threads are read once an hour, a metadata read each, about 5 % of the Function's free grant a month at the worst.
The model writes rows to a file; the Function is the one writer of the database.
- The lead run is the leads list's run on GitHub Actions (Sonnet, low effort,
LEADS-LANE.md in the job-hunt folder, rewritten), started by the inbox pass when it harvests a lead nobody has scored; LEADS_LIST is on from this version. It keeps scoring the leads list and adds the campaign's rows for the best of them: the company's key, names, remote stance, its .NET evidence rows (a posting's required stack, or its other engineering postings; .NET as one language of many does not count) and its public board; the engineering leader over the team; the address with the page it was read from; the WhatTheyDo clause; the track and the application's time from the tracker; the LinkedIn dates; the proof key from the posting's words; the follow-up post; the ghost score and the band; one tagged code from make_ref.py with its five links; and, for a new or changed lead only, its one step and its why. It reads the web for public pages only, with no finder, no sign-in and no guessed address, and it posts its usage under "Azure Functions, leads lane".
- The run has no identity the database knows, so it writes one file to
campaign/leads-inbox/ on the share, and LeadImport reads it in the inbox pass: every company and lead held to LeadSpool's rules (a registrable key, a named manager, Track A only with its application, an address only with its https page and never a personal one, a known proof key, links that carry the lead's code), a refused row named in import.log and written nowhere, a WhatTheyDo that fails kept with Blocked so the next run sees why, each new address asked for its MX records of a public resolver (DohMxCheck, dns.google, keyless), and Strength and its inputs hash computed by code. The file moves to merged/ or, unreadable, to rejected/.
- The daily board scan (
BoardScan) runs first in the 8 o'clock hour: one keyless request a company with a Greenhouse, Lever or Ashby board, the newest posting whose title names .NET or C# written back as the company's LastDotNetPostingAt and title, which Track B ranks by. At two hundred companies that is about 2 % of the Function's free grant a month.
The campaign has a card, a rail row and an alert, and nothing on them can name a company.
- The card
campaign under Cloud infrastructure, the rail's fifteenth row, in ADR-102's frame (its addendum of 1.0.4.63 says what it draws). It reads the database's card schema: card.Days (sent, written in shadow, bounced and answered by Central day, sixty days), card.Leads (open, with an address, waiting on one, blocked, no MX, unverified, companies, stopped, boards, the newest scan, the first email written and sent, the newest bounce) and card.Weeks (the Sunday table). The site's identity id-theyard-ss has a contained user on the campaign database made from its SID with SELECT on the card schema and nothing more, read back from sys.database_permissions. CampaignSqlTests holds the card views free of the columns that hold a name, a company, a subject or a code.
- The alert
alert-jobhunt-campaign-silent in infra/jobhunt-alerts.bicep (the review, F13): checked hourly, it fires only in the 15:00 UTC hour, after 8 AM Central under either clock, when no CampaignSend ran in the three hours before; it emails Steve through the action group the dead-Function alert already uses. The card goes red the same morning for two bounces, or for no send by 9 AM with leads ready.
- CONVENTIONS gains three fragments: seven days a week (superseding the 12:22 fragment's weekdays), no third-party finder with public pages only, and the card shows no company; a fourth, from Decision 4, tells the reply run not to draft in a thread listed in
campaign/stop-threads.log.
A week of shadow is read from a report the Function writes, one a Central day.
- The 8 o'clock pass in shadow writes
campaign/shadow/<day>.md on the share (CampaignReport): the pass's counts, the addresses of the written emails by the kind of page each was read from (the company's own site, GitHub, the posting, a public profile, another public page; the review's section 8 asks for this daily), every hold by its reason, and each would-send whole, with its address and the page it came from, subject and plain body. A later hourly firing that writes nothing leaves the day's report as it is.
- In
on, each real send is appended to campaign/sent.log in the block systemRules.md Rule 46 sets for every send (Steve, 2 October): a line of --, then SENT - TO: the name and address - SUBJECT: the subject, then --.
- The report is the Function's and not a scheduled chat's, because nothing in this campaign hangs on a reminder: the seventh report is on the share whether or not anyone opened a session that week. The switch to
on reads seven of them.
A real send writes its tagged code's send-time row (the review, F17).
- The lead run mints each lead's code with make_ref.py when it writes the lead (Steve's rule; make_ref.py stays the only minter), so the mint-time row says "sent" days before the email goes, or for an email that never goes. When Gmail takes a campaign email, the Function writes one more file to
inbox/link-tokens/ on the share with the same code, the person, the company, the Gmail thread and the true send time, lane campaign. opens_report.py (on the share, its one writer of link-tokens.csv) now keeps the latest row a code field by field, so opens are labelled by the day the email went. Shadow writes no row: an email Gmail did not take has no thread.
What holds it
CampaignCardTests (the dials, the four questions read and unread, red at two bounces and at no send by nine with leads ready, the Sunday table, every line sourced, the wire with no address or code, the source's minute and hour, the connection built from the site's own), TemplateTests (the silent-timer alert and the switch in the template), LeadImportTests (a made-up run file held to the rules row by row, the refusals named in the log, the blocked clause kept, the file moved, MX asked once an address, Strength computed by code, the scan's title rule and write-back, the three boards' and the resolver's answers read), CampaignInboxTests (the failure read off Gmail's own body, the stop phrases above the quoted original only, the newest switch row deciding, two failures today bouncing their emails once and tripping the switch once, one today and one yesterday not, a reply marking the email and a stop marking the company and listing the thread, nothing sent reading nothing), CampaignSendTests (both templates rendered byte for byte, the optional line, every variable given by the row, a blank named, the switch's words, the 8 o'clock hour across the clock change, shadow never reaching the mail port, ten of eleven sent and a second firing sending none, the three, five, ten start, every hold named, one email a company, the message's shape, the shadow report's counts, sources and whole emails, a real send's Rule 46 block, its send-time token row and none in shadow), CampaignSqlTests (every column a statement names is a column the SQL project declares, every template variable has its column, the template makes one Basic database and nothing else, the finder finds nothing), RingTests (the database client in Infrastructure alone), CampaignRulesTests (former employers by name and domain, the company key, the 30-day cases F10 names, the gate's order, the live thread over the tracker's real row shapes with every name removed) and CampaignTextTests (the tells against the Python file, the WhatTheyDo cases F15 names, the cap and ramp, the recipient domains, the Strength formula and hash, the applied word across the November 1 clock change, the proof clauses, the send order, the optional line and the named blank).
Not done in this version, and why
The switch to on with the three, five, ten start is its own version, after seven shadow reports have been read.
Where it sits
A new slice, Campaign, in the job hunt's Function rings, beside Leads, whose Rule 50 name match it reuses rather than copies. Separation of concerns is the principle: the model's judgement stays in rows a person can read and a rule can refuse, and the send is code a test can run. It cost one folder of rules and a copied Python file in the tests. What would change it: Steve approving a finder, a template with a {Proof} line, or a different cap, each a change to one constant or one adapter with its test.
Files
functions/JobHunt.Domain/Features/Campaign/ - the rules
functions/JobHunt.Database/ - the campaign's schema
functions/JobHunt.Database/JobHunt.Database.sqlproj - the schemas, which live in the site's database since 1.0.4.72 (infra/jobhunt-sql.bicep, the database of their own, is retired)
functions/JobHunt.Application/Features/Campaign/CampaignPorts.cs - the ports
functions/JobHunt.Infrastructure/Features/Campaign/ - the database adapter and the finder that finds nothing
functions/jobhunt.Tests/CampaignRulesTests.cs - the company rules, held
functions/JobHunt.Application/Features/Campaign/ - the templates, the renderer and the send
functions/jobhunt/CampaignSendTimer.cs - the 8 o'clock timer
api/TheYard.Api/Features/Admin/Cloud/CampaignCard.cs - the card
api/TheYard.Tests/CampaignCardTests.cs - the card, held
functions/jobhunt.Tests/LeadImportTests.cs - the lead run's file and the board scan, held
functions/jobhunt.Tests/CampaignInboxTests.cs - bounces, replies and stops, held
functions/jobhunt.Tests/CampaignSendTests.cs - the renders and the send, held
functions/jobhunt.Tests/CampaignSqlTests.cs - the schema, the template and the finder, held
functions/jobhunt.Tests/CampaignTextTests.cs - the text and order rules, held
functions/jobhunt.Tests/Fixtures/ai_tells_five_signs.py - the copy the tells are held to
Addendum, 2026-10-25 (1.0.4.72): one database, the campaign and the tracker as schemas
Decision 2 gave the campaign a Basic database of its own, sqldb-jobhunt-ss, about $4.90 a month, so that a deploy of it touched nothing else. On 25 October Steve asked for one database with the campaign and the tracker as schemas. A second fixed-price database for a few hundred rows is the cost the decision bought its separation with, and the separation is kept by permissions instead.
From this version the campaign and card schemas, and a new jobhunt schema for the tracker's tables (PROMPT-JOBHUNT-TRACKER-SQL), live in the site's own database, sqldb-theyard-ss-basic, beside the site's tables. functions/JobHunt.Database is still their authority and still compiles to its own DACPAC; the site's api/TheYard.Database names none of them.
- The Function's identity has a contained user in the site's database made from the same SID (
0xDD6CF11F4D186148BF294DCB9E7D89C0), with SELECT, INSERT, UPDATE and DELETE granted on the three schemas only, and no database role. It cannot read a site table.
- The site's identity is denied the
campaign and jobhunt schemas and granted SELECT on card, so the campaign card still cannot show a name, a company or an address.
- The rows moved before the switch. Every row of the four tables was copied with its Id, then both sides' counts and checksums were read back equal. Only then were
CAMPAIGN_SQL and the site's Azure:Resources:CampaignDatabase pointed at the site's database, and the rows written in between were copied a second time. The next lead import was read in the new home.
sqldb-jobhunt-ss goes once the next lead import reads back in the new home (ADR-106: unused resources are deleted). infra/jobhunt-sql.bicep is retired in this version, so nothing can make the database again, and infra/jobhunt.bicep names the site's database. The cost card stops carrying the second database from the day the bill does.
CampaignSqlTests.The_schemas_live_in_the_site_s_database_and_no_template_makes_a_second_one holds the template side. The grants were read back from sys.database_permissions and are written in J:\mentor\DOTNET10-DONE-2026-10-25.md.
Addendum, 2026-10-25 (1.0.4.86): sqldb-jobhunt-ss is deleted
The condition the addendum of 1.0.4.72 set was met and the database is gone. Read at 23:00 CDT on 25 October through the queue (J:\staging\sunday1025\onedb\onedb-dropold.txt): the old database held Companies 141, CompanyEvidence 244, Leads 3 and EmailsSent 0; the site's database held Companies 141, CompanyEvidence 244, Leads 5 and EmailsSent 0, and had taken a write since the switch at 15:09 CDT (a lead updated at 21:20 CDT) while the old one had taken none. Only then was az sql db delete run, at 23:00:22, and az sql db show read ResourceNotFound at 23:00:41. Nothing in infra/ names the database (CampaignSqlTests holds it), so no template can make it again. The campaign and the tracker live in sqldb-theyard-ss-basic under their own schemas, and the subscription carries one Basic database fewer, about $4.90 a month.
Addendum, 2026-10-26 (1.0.4.89): a date goes to SQL as a date
The first morning with EMAIL_CAMPAIGN on would have failed before it sent anything. To count the day of on for the ramp, the send asked the email log for every row since DateOnly.MinValue, the year 1. The store turned that day into a DateTime and handed it to AddWithValue, and Microsoft.Data.SqlClient sends a DateTime it was not told the type of as SQL's old datetime, whose range starts in 1753. The client refused it before the query left the Function ("SqlDateTime overflow"). Shadow never reached the line, because shadow has no day of on, so every shadow morning passed and no test saw it: the test's memory log accepted any day.
From this version:
- The day count has its own question. The email log answers the Central days that carry a real send (
OnDaysAsync: the distinct CentralDay of every row with Shadow = 0), and the send counts the ones before today. No query asks for "everything since the beginning of time".
- A date to SQL is
SqlDbType.Date. The store passes a DateOnly and its one command builder adds it as a date parameter, so a date never travels as datetime and never meets the 1753 floor. The columns it is written to (CentralDay, FirstSeen, LastDotNetPostingAt) are date already.
- The test's log holds SQL's range. The memory log the send tests use refuses a day before 1753 the way the client does, so a path that asks for one fails in the test and not on the first real morning. A test drives the
on path with one real send on an earlier day and reads the second day's cap of five.
CampaignSqlTests.A_date_goes_to_SQL_as_a_date and CampaignSendTests.The_on_path_counts_its_days_with_dates_SQL_accepts hold it.
Addendum, 2026-10-26 (1.0.4.90): one slow board does not stop the morning
The board scan runs first in the 8 o'clock hour, one board after another, and the send waits for it. A board that did not answer was meant to be skipped, but only a network error was treated that way. A board that held the request past HttpClient's 100 seconds surfaces as a cancellation, and a board that answered with a page of HTML instead of its JSON surfaces as a parse error; either one escaped the scan and failed the whole pass before the send, so that morning would have sent nothing and written no line.
From this version:
- Each public request has fifteen seconds. The board reader and the MX check each wait at most fifteen seconds a request, and treat a timeout, a body that is not JSON and JSON of the wrong shape the same way as a network error: the service did not answer, the port says null, and the scan moves to the next board. A cancellation the host asks for, when the Function is stopping, still goes on up.
- The scan cannot stop the send. The timer runs the scan inside its own guard. A scan that throws anyway is logged as an error and its part of
campaign/pass.log reads scan: FAILED: <the exception's type>, and the send runs on the postings already in the book.
- The pass line says how long the scan took, in whole seconds, so a scan creeping toward the host's ten-minute limit shows before it reaches it.
LeadImportTests.A_board_that_does_not_answer_in_time_or_answers_with_a_page_is_not_answered, LeadImportTests.A_resolver_that_does_not_answer_in_time_or_answers_with_a_page_is_not_known and LeadImportTests.A_scan_that_throws_is_written_as_failed_and_the_send_still_runs hold it.
Addendum, 2026-10-26 (1.0.4.99): no send by nine counts only a morning the switch was on
Read live on 26 October at 14:39 CDT, the campaign card was red on both names: "0 sent today", "none sent by 9 AM with 92 ready". The switch had been in shadow at that morning's 8 o'clock pass, which wrote its emails in shadow as it should, and it went on at 10:40 CDT (J:\campaign\switch.log, J:\staging\addr1026\on.txt). The first real sends belong to the next morning. Until this version the rule above, red for no send by 9 AM with leads ready, asked only whether the switch read on now, so any day the switch went on after eight read as a morning that failed to send.
From this version the rule asks what the switch read at the pass: the newest hour the card kept on the same Central day before 8 AM. When that hour read anything but on, the row stays good and says so ("the switch was shadow at the 8 AM pass; the first sends come at the next one"). When it read on, or no hour before eight was kept that day, the rule is what it was. Two bounces in a day stay red whatever the switch read. No threshold moves and nothing that emails Steve changes: alert-jobhunt-campaign-silent reads CampaignSend's runs, not this card.
CampaignCardTests.A_switch_turned_on_after_the_8_o_clock_pass_is_not_a_morning_with_no_send holds it.
Addendum, 2026-10-26 (1.0.4.103): a company mailbox, a test send, a daily lead run and a finder kept off
Lane addr1026 built these on 26 October at Steve's word (07:28, "any email will do, even if it's the companies about me email"; 09:33, "do the testing"), and they shipped as one version. Each changes the Function only; the site's rules do not move.
- A company mailbox is a lead. A lead with no first name opens on the greeting alone, with no name and no comma, so Template A and B can go to a company's published general address.
LeadSpool takes a lead with an address and no manager named, and still refuses one that names neither.
- A test send on demand.
POST /api/campaign/test-send, with the function key, renders one open lead through the real Gmail sender to the one address in the app setting CAMPAIGN_TEST_TO and never to the lead: the subject is marked [TEST], the links carry the code tst001, nothing is written to EmailsSent, and neither the cap nor the 30-day rule is spent. With the setting absent it answers 409 and sends nothing.
- The book is worked every day. Besides the run a newly harvested lead triggers, the leads run fires once a day in the pass after half past ten at night Central, marked on the share so a second pass in the slot does not fire it again.
- A finder, kept off. The "no finder" ruling of 24 October still stands in practice:
HunterFinder sits behind the finder port and is built only when the app setting HUNTER_KEY holds a key, which it does not. With a key it would ask only for a lead whose public pages gave none, keep an answer scored 70 or more that cites a public page, and stop at the free plan's 50 calls a month. Turning it on is Steve's call, after the first shadow week's numbers.
CampaignSendTests, LeadImportTests, AddressSearchTests and AtsSweepTests hold it. Shipping puts the code on main; the Function runs it once it is deployed from that commit.
Addendum, 2026-10-27 (1.0.4.106): the company mailbox is declared, never inferred from a missing name
The addendum of 1.0.4.103 meant one shape: a lead whose public pages name no engineering leader, written to the company's own published address. The code took a wider one. LeadSpool took any lead with a blank first name as long as it had an address, and the render made the first name optional for every lead. So a lead that named a manager (Pat Lee, VP Engineering) at a personal work address, where the model left the first name out, was written to the book and would have gone to that person as "Good morning!" with no name. The review of 27 October found it (D1) while the switch was on.
From this version:
- A company mailbox says so. A lead is a company mailbox only when its contact title is "Company mailbox", the shape the lead run writes for one. Nothing else makes it one: not a blank first name, not the address, not the contact's name.
- Every other blank first name is refused.
LeadSpool refuses a lead with a blank first name that is not a company mailbox, with "no manager named". A company mailbox still needs its address.
- The render holds the same line.
TemplateRender.OptionalFor lets the first name be blank only for a company mailbox. For any other lead a blank first name is a blank, and the email is incomplete and never sent, so a row already in the book from 1.0.4.103 is held at the 8 o'clock pass rather than sent.
LeadImportTests.A_company_mailbox_with_no_first_name_is_written_and_a_named_contact_with_none_is_refused, CampaignSendTests.A_named_contact_with_no_first_name_is_an_incomplete_email and the template test's blank first name hold it. Shipping puts the code on main; the Function runs it once it is deployed from that commit.
Addendum, 2026-10-27 (1.0.4.108): the book run's mark, the finder's month, the test address and the 8 AM card
The review of 27 October found five smaller places where the campaign's parts said more than they knew. From this version:
- The day's book run is marked only when GitHub took it. The dispatch answers its line rather than throwing, so a refused token or a missing one used to write the day's mark anyway and that day's leads run was lost. The mark is written only on a 204 (
Dispatch.Delivered), so a refused dispatch is tried again at the next pass in the slot, and the slot is read from the pass's own start rather than the time its sweep ended.
- The finder asks about a lead once a month. A lead the finder had no answer for was asked again every thirty minutes, spending the month's calls on the same names. Each lead asked is written to
campaign/finder/<finder>-<month>-asked.txt and skipped for the rest of the month, and the count and that list are written even when a call throws, so a failed pass never lets the next one spend past the cap.
- "off" turns the finder off.
HUNTER_KEY set to off builds no finder, as every other switch reads it.
- The test send goes to one address.
CAMPAIGN_TEST_TO must be one plain address (MailAddress.TryCreate, and nothing beside it); a list or a display name answers 409 and sends nothing, where it threw a 500.
- A silent shadow morning is a morning with no send. The 8 AM card's switch at the pass is read from the newest hour kept before eight, about a minute past seven, not at the pass itself. So a switch read as shadow at seven is taken as the pass's mode only when the day's shadow count shows the pass wrote something; a shadow morning that wrote nothing is red like any other morning with no send. The better fix, the Function writing the mode its 08:00 pass ran in, is not in this version.
AtsSweepTests, AddressSearchTests, CampaignSendTests and CampaignCardTests hold it, the card's newest-of-several-early-hours and the day the clock goes back included.
Addendum, 2026-11-05 (1.0.4.142): the board scan moves to 1 AM and keeps every posting
The scan ran first in the 8 o'clock hour, after Steve was awake, and kept one date and one title a company. A list of the night's roles has to be ready before he is, and a Staff role that comes back as Senior, or a band that drops, can only be caught by something that remembers yesterday's posting. From this version:
- The scan has its own timer,
BoardScan, in the 1 o'clock hour Central (CentralClock.IsScanHour, asked as a local hour for the reason the send's hour is). It writes its line to campaign/pass.log as the send's line wrote it, scan: and the counts with the seconds, behind the same guard. The send no longer scans; its line says scan: scanned 01:00 and it ranks Track B by what the night wrote. The boards are read least recently scanned first, and the scan stops starting boards at eight minutes, inside the host's ten, with the boards left named on its line.
- Every posting is a row in
jobhunt.Postings, keyed by its board and the board's own id, so a second scan makes no second row. Seen again, LastSeenAt moves; a changed title, level, band end or remote stance writes one jobhunt.PostingChanges row each; a posting gone from its board is closed; a new posting at the same board whose title, its level words out, matches one closed in the last 30 days within one level is linked to it with a repost_of row. A description is written to jobhunt.PostingDescriptions on first sight and on a changed hash only. jobhunt.PostingNotes is for what is learned later and nothing in the scan writes it. The three feeds are asked for their pay: Greenhouse with pay_transparency=true, Lever's salaryRange and Ashby's Salary component with includeCompensation=true; a board that published no band gives null, never a figure read out of the text. The level is read from the title by PostingLevel, one rule the night's picker reads too.
- The tables come before the rows. The scan asks whether the tables exist before its first write; until the schema is published from the Laptop (the box holds no Azure sign-in) the line ends
postings blocked: no_postings and the companies are marked as before. On the first pass with the tables present and empty, the first harvest's postings.jsonl (593 postings) is written as rows with the file's own time as their LastSeenAt, so nothing reads them as seen that night.
- The watchlist grows from the share. A lane that cannot write SQL lists the boards it found in
campaign/boards-inbox/<yyyyMMdd-HHmm>-boards.tsv; the Function, still the one writer of campaign.Companies, adds each board once, deduped on its kind and token, skips and counts Workday, iCIMS and other kinds, stops at four hundred companies with a board (about 4 % of the free grant a month), and moves the file to merged/ with one log line.
PostingsTests and PostingsSqlTests hold it.
Addendum, 2026-11-05 (1.0.4.145): Track A sends first; the finder behind the port
Track A, the email after an application, had sent nothing: 91 campaign emails by 5 November, every one Track B, and no named human reply. Nothing turned an application into a Track A lead unless the lead run happened to find one, and Template A v1 was a long cold note with five links. From this version:
- Template A v2 is the one A the send selects. Approved 28 October, the text in J:\mentor\email-templates\TEMPLATE-A-posted-v2.md with its 5 November layout: the greeting on its own line, one point a line, one link,
{SiteLink}, an anchor in the HTML body and the bare tagged address in the plain one. CampaignTemplate.CurrentFor gives A v2 and B v1; A v1 stays in the code so what it sent can be read back, and nothing selects it. WhatTheyDo is checked only when the template says it, which A v2 does not.
- The week's applications become Track A leads.
TrackAFeed runs in the 8 o'clock hour before the send: every application in the tracker from the last seven days, at a company with no Track A lead in that window, becomes one Track A lead when the night's jobs lane named a person for it on a public page and wrote them to nightly/track-a-contacts-<date>.tsv with the code make_ref.py minted. AppliedAt and AppliedCount come from the tracker row. A second pass writes nothing more.
- A named person's address, or none. An address is written only when a public page showed it on the company's own domain; a shared mailbox (info@, careers@ and the rest) is never a Track A address, and the send holds a Track A lead with none as
Track A: no named address. The row waits for the finder behind IAddressFinder: HunterFinder when HUNTER_KEY holds a key, under its monthly cap, and no finder otherwise. No code path guesses an address.
- Track A sends first. The day's order is Track A, the oldest application first, then Track B by the LinkedIn order and Strength. The cap, the ramp, the 30-day rule (A and B counted together), the live-thread rule, the former employers and do-not-email are unchanged. Shadow writes its rows and calls no mail service.
TrackATests and CampaignSendTests hold it.
Addendum, 2026-11-07 (1.0.4.148): the network schema joins the Function's grants
From this version the network schema joins the three the Function's user may read and write (ADR: The network log drafts, Steve sends, the addendum of this date). It was published on 5 November without its grant, and the laptop file Grant-NetworkSchema.vbs grants SELECT, INSERT, UPDATE and DELETE on it and reads them back as that user.
Addendum, 2026-11-10 (1.0.5.11): the boards are read every 15 minutes for new postings
Until this version a posting was first seen in the 1 o'clock hour Central, so one that went up at 2 AM waited 23 hours, and 12 on average, before anything could act on it. The measure the job hunt now runs on is the minutes from a posting going live to the first message reaching its hiring manager, under 60 at any hour, and that clock cannot start once a day. From this version:
- A fresh pass every quarter hour.
FreshScan, a timer at 0, 15, 30 and 45 past every hour, reads every board on the watchlist and adds each posting the table does not hold, the way the daily scan adds a new one: the row, its description and its repost_of row, through the one method both scans call (BoardScan.AddNewAsync). It writes nothing else. It marks no company, and it moves no LastSeenAt and closes nothing. What the table holds comes from one read of every row's board and id, open or closed (IPostingBook.KnownAsync), so a posting closed long ago is never added a second time. A board that does not answer is counted and the pass goes on. A row the other scan wrote first comes back from the unique key as already held and is counted as known, not as a failure. The pass stops starting boards at five minutes. In the 1 o'clock hour it does nothing, since the daily scan reads every board then. FRESH off stops it, and unset runs it, so a redeploy that drops the setting cannot stop it. Each pass writes one line to campaign/fresh.log and one run line, process:FreshScan.
- The daily scan keeps the rest. Seeing a posting again, a changed field, a closed posting and the company's newest .NET posting stay with the 1 AM scan. That scan touches every stored row once (
SeenAsync), and doing that 96 times a day on the Basic tier is the cost this split avoids: the fresh pass reads the table once and writes only new rows.
- The instant, not the day.
jobhunt.Postings.PublishedAt (datetimeoffset, null when the board gives none) holds the instant the board says the posting went up: Greenhouse's first_published (never updated_at), Lever's createdAt in epoch milliseconds, Ashby's publishedAt. PostedAt keeps the day as before. Both scans write the instant on every new row, and the rows already there are not backfilled. DATEDIFF(minute, PublishedAt, FirstSeenAt) is the time to first sight.
- Greenhouse's light list. One full pass over the 145 boards measured 192 MB in 49 seconds uncompressed, the way the Function's client reads it, and 157 MB of that was Greenhouse's descriptions and pay. The list without
content=true is 7.8 MB for the same 112 boards and still carries first_published. So the fresh pass asks Greenhouse for its list and reads the whole board only when the list shows an id the table does not hold. Lever and Ashby have no lighter list and are read whole.
- The column was published alone. The DACPAC's script against the live database also dropped and re-added fifteen CHECK constraints and altered
card.Network, drift older than this version. Only the ALTER TABLE ... ADD [PublishedAt] it generated was applied, and it was read back as the Function's user.
FreshScanTests and PostingsTests hold it.
Addendum, 2026-11-11 (1.0.5.26): "management" is a rung only after "engineering", and an Ashby posting keeps every place
What stopped being true: PostingLevel read the word "management" anywhere in a title as the Manager level, and an Ashby posting's location was the board's first location name and nothing else.
Read from jobhunt.PounceRoles and the boards on 11 November, while finding why the pounce passed 3 of 83 postings overnight and that morning:
- The level. "Identity & Access Management (IAM) Engineer" (Backblaze) and "Senior IT Engineer, Identity and Access Management" (1Password) were read as Manager on 10 November and failed the night's gate as "level Manager, not an engineering title". "Management" there names the seat's subject, as in Product Management or Asset Management, not its rung. From this version only "engineering management" is a Manager word beside "manager" and "engineering manager"; the two titles read Mid and Senior. The stored level is compared on every scan, so the first 1 AM scan after this version writes one
Level change row for each open posting it moves: 98 were open with Manager read from "management" alone when this was written.
- The place. Inovalon names the first location of four Ashby postings "BU: Pharmacy", a business unit, and lists Hyderabad only under
secondaryLocations, which the reader never read; the pounce's reason read "hybrid outside St. Louis: BU: Pharmacy". The verdict was right, all four are in Hyderabad, but the reason hid the place, and a hybrid seat whose St. Louis office was a secondary location would have failed the same way. From this version the reader joins the first name and every secondary name with "; ", the shape Greenhouse already writes for a posting listed in several places (619 of 11,041 Greenhouse rows). The location is not a compared field, so rows already stored keep what they hold; new rows get every place. No fit rule changed: the remote read, the hybrid rule and the seat lists read the same words as before.
PostingsTests holds both.
Addendum, 2026-11-11 (1.0.5.27): a leader's email asks to be sent down
What stopped being true: Template A v2 was the one A the send selected for every Track A lead.
RULE 73 (11/8) aims the first message at the leader one level above the seat and asks to be sent down, never around: "Who on your team should I talk to about the role?". The leaders lane (rung L of the autohunt plan) writes such a leader into nightly/track-a-contacts-<date>.tsv for the week's applications, and until this version the email that followed closed on v2's "Would it be a bad idea to set up a time to talk?", an ask for the leader's own time. Steve approved the v3 text at 16:47 CST on 11 November ("Send approve", on J:\mentor\AUTOHUNT-L-DONE-2026-11-09.md, LEFT FOR STEVE A). From this version:
- Template A v3 sits beside v2.
Templates/A-v3.md is that text byte for byte: v2's subject, greeting and link, the first line "I just applied for the Remote {RoleTitle} opening on your team.", and the close "Who on your team should I talk to about the {RoleTitle} role?". A v2 and A v1 stay in the code and v2 stays CampaignTemplate.CurrentFor('A').
- Only the leaders lane's rows get it. The lane writes its name in one more tab cell,
Lane, after the seventeen (TrackAContacts.LaneColumn); the jobs lane's rows carry none and read as before. TrackAFeed writes such a lead under the run track-a/<lane> (TrackAFeed.RunFor, a lane named leaders or leaders- and its day only), kept in the lead's existing CreatedBy column, so no column is added. CampaignTemplate.For(lead) gives A v3 when the lead is Track A and TrackAFeed.IsLeadersRun reads its CreatedBy, and the current template for its track otherwise; the send renders and logs that one, so EmailsSent.TemplateVersion reads v3 for these emails.
- What does not move. Every rule before the template (the former employers, the address and its source, the 30 days, the live thread, the seven days, the cap and the ramp) runs as before. A lead the book already held under another run keeps that run and v2, the safe default. The one-email-after-an-unanswered-invite rule offered beside v3 (item B) was not approved and is not built.
LeaderTemplateTests holds it.
Addendum, 2026-11-11 (1.0.5.32): a caught role's leader is looked up, and the email waits in shadow
What stopped being true: "With a key it would ask only for a lead whose public pages gave none" (the addendum of 1.0.4.103). The finder is now asked for one more kind of person, the leader the pounce's slot run named for a role caught within the hour.
From this version, in the same quarter-hour firing as the pounce's follow-ups (PounceFollowUpTimer), PounceEmails reads every hand-off of the last day under nightly/pounce/ and the leader its feed named, the first block's heading of QUEUE-pounce-<day>-<key>.md (live in linkedin-proof/, or the dry feed's copy in its run folder):
- The domain. The hand-off now carries
company_key, the campaign's key for the posting's company, when the scan knows it. A role with none is settled as "no company domain known".
- One email a company a month stays. A company that had a real send (
Shadow = 0) in the last 30 days gets no lookup.
- One lookup a role, the campaign's count. The finder is asked once for the leader on that domain, and the call is counted in the same
campaign/finder/<finder>-<month>.txt the campaign's finder pass keeps, so the free plan's 50 a month hold across both legs. A spent month leaves the role waiting and asks nothing. With no HUNTER_KEY nothing is asked.
- The person's own address. HunterFinder keeps only an answer scored 70 or more, verified, with a public https page. The pounce keeps it only when it is also on the company's domain and carries the leader's own name (
PounceRules.IsNamedAddress: a part of the name of three letters or more, never info@, careers@ or another shared box under a leader's name). 98 of the campaign's 99 emails went to a shared mailbox; this leg cannot.
- Shadow, whatever POUNCE_RUN says. A kept address is written to
nightly/pounce/emails/<key>.md with the words SHADOW and "Nothing was sent", and one line goes to nightly/pounce/emails.log. The pass is handed no mail port. "off" reads and writes nothing.
What it does not do yet: no pounce email is written or sent. The model writing the row's fields and the Function rendering and sending them is the rest of this leg, and it waits on Steve's email ruling in J:\dispatch\DECISION.md and on a pounce template he has seen once. PounceEmailTests holds it.
Correction, 1.0.5.38: the second paragraph says the pass reads every hand-off of the last day. Writing a settled role's line from its marker, when a pass stopped before the line reached nightly/pounce/emails.log, was tied to that day too, so a role settled near the end of its day whose line failed never got one. From this version every pass first reads each marker under nightly/pounce/emails/ whose key has no line on the log, whatever its hand-off's age, and writes the line it carries; the day picks new lookups only (CodeRabbit on #46).
Addendum, 2026-11-12 (1.0.5.52): a refusal is a wall, is not counted, and an empty month stops the finder
What stopped being true: "the count and that list are written even when a call throws" (line 185 above) holds for a call that timed out or failed in transit, which Hunter may have charged, and no longer for a call Hunter refused. HunterFinder answered null on any status that was not a success, the same value as "no address for this person", so on 11/12 21 calls met HTTP 429 restricted_account, read as 21 people with no public address, spent 21 of the month's 50 and locked those leads out of the month. Hunter does not charge a refused call (50 of 50 searches left after those 21, read by chat1112).
From this version:
- The finder answers three ways. An address (found), null (Hunter answered 200 and nothing was kept, or a failure that is not a refusal), or
FinderRefusedException for 401, 403 and 429 restricted_account. A plain 429 too_many_requests is a rate limit and stays null.
- A refusal is a wall. Both Hunter callers (the finder part and the pounce's email leg) ask through
WalledFinder. A refusal writes one bullet on dispatch/WALLS.md (what, the control "sign in at hunter.io and read the account notice", since when) and every lookup stops for 24 hours after the last refusal, with no call. After that one call tries again; the first address found takes the bullet away.
- A refused call is not counted and its lead is not written to the asked list, so it is asked again once the wall is gone. A lookup the wall stopped before any call is not counted either. The pounce leaves a walled role waiting rather than settling it as "no address".
- The floor. Ten leads asked in the month with none of them carrying an address in
campaign.Leads stops the asking, writes one bullet (the control "read one lookup by hand at hunter.io") and asks nothing for 24 hours; after that one lead a pass, and the first address found removes the bullet. The tally adds no writes: asked is the month's asked list, found is read from the table.
- The finder is its own part of the inbox pass, after the campaign's, so a later failure in the campaign's reads cannot erase what it spent (ADR-109's addendum of this version).
FinderWallTests and AddressSearchTests.A_refused_call_is_not_counted_and_its_lead_is_asked_again and Ten_asked_and_none_found_stops_the_asking_with_one_wall_and_a_found_address_clears_it hold it; A_call_that_throws_is_still_counted_against_the_cap stands for the failures Hunter may have charged.
Addendum, 2026-11-16 (1.0.5.60): no shared box under a leader's name, no first email twice, and the night's new postings
What stopped being true: "a shared box is never a Track A address" was the only refusal of one. Of the first 105 sends (10/27 to 11/13), 99 went to a shared box, info@ 54 of them, press@, media@ and careers@ 7 each, with a leader's first name as the greeting, because the lead run wrote the leadership page's name beside the contact page's inbox. Whoever reads those boxes is not the person the email names, and the opens they made were read as the leaders'. Also no longer true: an emailed lead stayed open with Touch 1, so the 30-day hold was the only thing between it and the same first email again, from 11/27 for the 10/27 sends.
From this version:
- A shared box under a person's greeting is held on every track (
CampaignSend.SharedBoxNamed). A box greeted as the company mailbox is unchanged. TrackAContacts.GeneralBoxes is the one list, and gains the local parts the sends showed it missed.
- The finder asks for the person behind the box.
WaitingLeads takes a lead with a shared box and a named person as waiting, the never-emailed ones first, under the same month's cap; SetAddress may replace a shared box but never a person's address; WithAddress does not count a shared box as found, so the floor of item 4 above reads true.
- No first email twice. Each open lead carries
Touches, its real sends. SecondTouch holds an emailed lead: never a third email, never a follow-up to a shared box, and a second, different email only after a second-touch template is approved, which none is yet.
- The 1 AM line counts the day's new postings. Since the quarter-hour pass (1.0.5.11) writes new postings all day,
postings_new counts only the minutes since its last run; the line now leads with postings_first_seen_24h, the listed postings any scan first wrote in the last 24 hours, read from FirstSeenAt.
CampaignSharedBoxTests (press@roblox.com greeted "Nick" is refused) and PostingsTests.The_nightly_line_counts_the_day_s_new_postings_another_pass_wrote_first hold it.
Addendum, 2026-11-12 (1.0.5.62): an A email over sixty words is held
What stopped being true: the sixty-word limit ADR-075's rows hold Template A v2 and v3 to was held only on the fixture's own title. v3 names {RoleTitle} twice beside 39 fixed words, so a title of eleven words rendered it at 61, and the send counted no words.
From this version CampaignSend.Check, after the render and the three holds that mark the lead (blank, what they do, a tell), counts a Track A email's words as LeaderTemplateTests counts them (every line but the bare link, split on spaces) and holds one over sixty as "over sixty words: " with Block false, because the words over are the posting's title and the lead itself is fine. It reads every A template: v3 reaches it at an eleven-word title, v2 at twenty-three. Track B is not counted. LeaderTemplateTests.A_v3_whose_title_runs_it_past_sixty_words_is_held_and_the_lead_is_not_blocked holds it: a ten-word title passes at 59, an eleven-word title is held at 61 (CodeRabbit on #38).
Addendum, 2026-11-16 (1.0.5.65): the finder asks only for leads that have had no email
What stopped being true: item 2 of the addendum of 1.0.5.60 let the finder ask for the person behind a shared box on any lead, the never-emailed first. All 99 such leads had already been emailed, and its first pass after the deploy asked for 22 of them, found 10 personal addresses and spent the month's last Hunter calls. Those 10 can have nothing more until a second-touch template is approved, and the lead run's new leads were left with no calls.
From this version WaitingLeads takes only a lead with no real send in campaign.EmailsSent, so every call goes toward a first email. When a second-touch template is approved, the version that makes it live lifts this condition with it. CampaignSqlTests.The_finder_asks_only_for_leads_that_have_had_no_real_email holds it.
Addendum, 2026-11-19 (1.0.5.105): the paid finder, and a send to a shared box is not a send to the person
What stopped being true: Hunter is on the Starter plan (2,000 credits, read from its account endpoint 11/19, resetting 12/19), so the free plan's 50 calls a month is no longer the limit, and the count file alone cannot know what the plan has left. Steve decided on 11/18 that the 10 leaders Hunter found on 11/16 never saw their first email, because it went to info@, press@ or media@, and on 11/19 that such a send starts no company's 30 days. And Track A's "16 applications in 7 days" on 11/18 were 4 submissions: 12 were invites, InMails and interview reminders whose notes said "applied" somewhere.
From this version:
- The cap is a setting.
HUNTER_MONTHLY_CAP on the Function (1,500 on Starter, leaving room for verifications at half a credit) is the month's cap for the campaign's finder and the pounce's email leg, read by HunterFinder.MonthCapFrom; with no setting it is the free plan's 50. The leaders lane's hunter_find.py reads the same setting and the same count file.
- The pass reads the plan first.
AddressSearch asks IFinderPlan for the searches left before the first call and asks no more than the lower of that and the cap. A plan that does not answer leaves the cap in charge, and the line says "plan not read".
- A valid answer with no page counts (Steve 11/12):
HunterFinder.Read keeps it with https://hunter.io/email-verifier as its source, as hunter_find.py has since 11/12.
- A touch is a send the person could read.
Touches counts a real send unless it went to a shared box and the lead now carries another address, so a lead whose only send went to info@ gets its first email at the person's own address (B v1 for a Track B lead; A v3 says "I just applied" and none of the 10 has an application). A box is still never sent the same note twice.
- The 30 days start at a person. For an email to a person's own address,
CampaignSend leaves a shared-box send out of the 30-day rule; an email to a shared box still waits 30 days after any send.
- The finder asks the never-emailed first, Track A first among them, then a lead whose only send went to a shared box; a lead a person already heard from is never asked. This lifts the condition of the 1.0.5.65 addendum, as it said the version that changes the second-touch rule would.
- Track A follows a submission (
TrackAFeed.Submitted): a row the tracker counts as an application whose opening says SUBMITTED, APPLIED or EASY APPLY, or starts with "Applied" or "Submitted", and is not an invite, InMail, message, reminder or inbound note.
AddressSearchTests, CampaignSendTests.A_shared_box_send_starts_no_thirty_days_and_the_person_gets_the_first_email, CampaignSqlTests.A_touch_is_a_send_the_person_could_read, CampaignSqlTests.The_finder_asks_never_emailed_leads_first_then_those_only_a_shared_box_heard_from and TrackATests.Track_A_follows_a_submitted_application_and_not_a_message_that_mentions_one hold it. Hunter, Gmail and the campaign database are fakes in every one of them (RULE 79).
Addendum, 2026-11-20 (1.0.5.137): a send to a shared box is not a live thread
What stopped being true: the addendum of 1.0.5.105 took a send to a shared box out of the 30 days and out of Touches, so a lead whose only email went to info@ would get its first email at the person's own address. The live-thread rule still read the campaign's own tracker row for that send, "CAMPAIGN EMAIL SENT" with Communication "Email", as a thread with a person. On the 8 AM pass of 20 November it held 67 leads as live threads and sent 0 of 10, 7 of the 10 leaders among them (Ellevation Education, DFIN, The Battery Network, Origami Risk, Pathward, Ylopo, Seeq), each on its own 29 or 30 October send to a shared box and, for Ellevation, that send's bounce. Steve's ruling of 19 November stands behind it: a send to a shared box does not reach the person.
From this version LiveThreadRule.Holds leaves out a row whose Notes open with CAMPAIGN EMAIL SENT or BOUNCE and whose Phone/Email cell is a shared box by TrackAContacts.IsGeneralMailbox, the one list of TrackAContacts.GeneralBoxes. A CAMPAIGN REPLY or AUTO-REPLY row, from any address, a LinkedIn row, and a send or bounce at a person's own address still hold. A lead with no person's address is unchanged: CampaignSend.SharedBoxNamed and the shared box's own 30 days still stop it, so only a lead the finder gave a person's address moves.
CampaignRulesTests holds it, on the tracker's own row shapes (Counts 3249, 3265 and 3268 with the names removed): a lead whose only row is its own send to a shared box passes, the same lead with a CAMPAIGN REPLY is held on the reply, a send to a person's own address still holds, and a bounce of a shared-box send passes. Every row is in memory (RULE 79).
Addendum, 2026-11-20 (1.0.5.139): the fresh pass's run time
What stopped being true: that the fresh pass reads the boards one after another. It did, about 145 public hosts a quarter hour, nearly all of the time waiting on the network: on 20 November it ran 96 times a day at 38.5 s on average (86.9 s at the 95th), about 1,850 GB-s of the Function's day, the largest single share of its free grant.
From this version the pass reads six boards at a time (FreshScan.AtOnce). Boards of one provider share its host (every Lever board is api.lever.co), so one host may see up to six reads at once, never more. The rows it adds are still written one board after another once the reads are in, so the database has the same one writer it always had, and the writes stop at eight minutes (FreshScan.WriteBudget), two inside the host's ten-minute limit: a board whose rows are not written by then is left, and its postings, still unknown to the table, are the next pass's. The quarter-hour cadence is the autohunt's promise and stays. Conditional reads (ETag or If-Modified-Since, nothing done for a board that answered 304) are the next lever and are not built: a Flex instance keeps no memory between runs, so each board's validator would have to be kept on the share or in SQL first. FreshScanTests holds the six at a time and the counts.
Addendum, 2026-11-26 (1.0.5.171): a touch is keyed by its address
What stopped being true: the addendum of 1.0.5.105 made a send to a shared box no touch to the person, so a lead whose only email went to info@ takes its first email at the person's own address. The table did not follow: IX_EmailsSent_Lead_Touch_Sent kept one real Touch 1 a lead, and the shared box's row of 29 October already held it. From 21 to 25 November each 8 AM pass sent one of the leaders Hunter found on 16 November B v1 at their own address (Ellevation Education, Origami Risk, Pathward, DFIN, The Battery Network), then failed writing it ("Cannot insert duplicate key row ... The duplicate key value is (43, 1)"), so the send left no row and the pass stopped after its first email. The tracker's own Sent reconciliation (RULE 58) logged each one; campaign.EmailsSent did not.
From this version the index is ([LeadId], [Touch], [To]) WHERE [Shadow] = 0: a person's first email sits beside the shared box's, and no address is ever written the same touch twice. The send path is unchanged. The five sends were written into campaign.EmailsSent from the tracker's rows (their Gmail message and thread ids, subject, time and code; the body as "not recorded") so Touches, the 30 days and the reply join see them, and the index was published to the live database alone and read back (J:\dispatch\done\heal-w12-campaignsend-20261126-DONE.md).
CampaignSendTests.The_person_s_first_email_after_a_shared_box_send_is_written_beside_it_and_the_pass_goes_on holds it, and CampaignSendTests.MemoryCampaign now refuses a write the table's unique index refuses, reading the index's columns from EmailsSent.sql, so a fake can no longer pass a write the database turns down (the gap that let 1.0.5.105's own test pass). The database is a fake in both (RULE 79).
Addendum, 2026-11-27 (1.0.5.182): a no-email day is a hold
What stopped being true: the card read a gated morning as a silent one. Since selfheal1120 version 2 (ADR-139) NoEmailDayGate holds every send on a Central day J:\dispatch\NO-EMAIL-DAYS.txt lists, and the 8 AM pass writes no_email_day on its held list. The campaign card did not know the gate: on 26 and 27 November (both listed by yearend1120) the switch was on, nothing was sent and six leads were ready, so "Is it sending?" read none sent by 9 AM, 6 ready in red from 09:00. "Next send" named the next 8 o'clock hour even when it was listed, and the morning card's dark-lane alarm counted each held pass as an empty run, so the nine listed days from 24 December would have led the 07:30 card with "Campaign emails (8 AM): 0 sent in N days".
One source: the gate's own file, read by the gate's own reader. The Function's anonymous health route (MergerWatch) now answers two fields beside the switches, no_email_today (true or false) and next_email_day (yyyy-MM-dd: today while its 8 o'clock send is still ahead, else the first later day the file does not list), both from NoEmailDayGate.ReadAsync on dispatch/NO-EMAIL-DAYS.txt. The site reads them in the same health read that carries the switch (NightlyProcesses.HealthAsync, FunctionHealth) and keeps them as the hour's facts; it holds no copy of the dates and parses none. On a listed day with the switch on, nothing sent and bounces under the trip, the row reads Held: no-email day in info and names the next send; "Next send" names the 8 o'clock hour on next_email_day when that is later than the next 8 o'clock hour; a readout line, "No-email day", says today, listed or not today. In the Function, DarkLanes.Campaign reads a pass with no_email_day held and nothing sent as a held run, which the count skips: it neither breaks a dark streak nor lengthens one. The other five lanes the alarm counts read state.md rows that never carry no_email_day, and the network card goes red only on a failed pass, so neither changes.
Why unread still means alarm: a host that never fired, a share that refused the read and a day nobody listed all look like a silent morning, and only a positive "listed today" can tell them apart. So the card holds only on the route's true, kept the same Central day; a missing or unreadable file answers null for both fields, a route that does not answer leaves both facts null, a fact kept on another day is not read, and in each of those cases the row reads exactly as before. Bounces at or over the trip are red on a listed day too.
MergerWatchMailDaysTests (the real file's dates; null for a missing and a refused file), CampaignCardNoEmailDayTests (11/27 at 20:27 replayed; false, null and stale still red; two bounces red; 12/23 at 10:00 names Sat 2 Jan) and DarkLaneNoEmailDayTests (nine listed days from 12/24 write no dark line; three unlisted empty days still write one) hold it, each red on the code before this version. Fakes only (RULE 79).
Addendum, 2026-11-28 (1.0.5.183): a campaign email is recorded before it is sent
What stopped being true: that the pass sends and then writes campaign.EmailsSent. From 21 to 25 November the write threw after the send (a unique-index clash, fixed in 1.0.5.171): five emails went out with no row, and the 30-day rule, which reads the rows, would have mailed the same five people again; the in-memory fake the tests used accepted any write, so the change that caused it passed its tests.
From this version the row is written first with its Gmail ids empty, then the email is sent, then the row is stamped with the ids. A write the unique index refuses throws before anything is sent. A send the no-email-day gate refuses after the row exists marks the row not sent at once. A row still unstamped at the next pass is settled from Gmail Sent (UnstampedSends, ISentSearch): a message to the same address with the same subject that day stamps it; nothing after 30 minutes marks it not sent (Shadow = 1, the reason in BounceReason) and frees the lead; any other answer, a failed search or a row under 30 minutes old leaves it counted as sent, so nobody is mailed twice. Every real-send count, the 30-day rule and the unique index read only Shadow = 0, so no schema changes and no row is deleted. Same people, same text, same caps: only the order of the write and the send changed. The tests' fake now enforces the table's unique index. CampaignSendTests holds the order, both settles and the refused write.
Addendum, 2026-11-28 (1.0.5.188): a company hiring now scores 2 more in the send pass
The points in Decision 3 gain one. A lead whose company is on that morning's nightly/hiring-signal.tsv, the jobs pass's list of the companies that opened three or more engineering seats in seven days, scores 2 more, because a company hiring that hard is the likeliest to answer. On 28 November the file named nine companies, NICE 10 seats down to Affirm and Encora 3, and nothing in the send order used it.
The point is not a stored fact: the file is rewritten nightly. So it is passed beside the inputs, Strength.Score(inputs, today, modelStep, hiringNow), and StrengthInputs keeps only stored facts; only CampaignSend adds it, reading the file once a pass through its share port, so the stored Strength column never holds it and the lead import and the Track A feed score as before. Strength.Version becomes "3" so a stored RankInputsHash names the formula that ranked the lead; RankInputsHash is written and compared nowhere, so the change costs no model call. A lead and the file are matched by a fold of the company's name (HiringNow.Fold: lowercase, punctuation dropped, then the trailing words inc, llc, corp, corporation, co, technologies, industries, group and holdings), because the file is grouped by the raw name and the registrable-domain key does not serve: "Anduril" and "Anduril Industries" are one company, "Nice Healthcare" and "NICE" two, and "Stone - Linkedin" is not "Stone". A missing or empty file changes no score.
What it is worth: the send order is Track A first, then the LinkedIn rank, then Strength, so the point only reorders Track B leads that share a LinkedIn rank. Track A, the follow-up and 30-day holds, the no-email days, the templates and the caps are unchanged. HiringNowTests holds it.
Addendum, 2026-11-29 (1.0.5.196): the links block carries the blog
What stopped being true: Decision 3's "the five links". On 29 November the 8 AM send went to MetroStar with Resume, Site, GitHub, LinkedIn and About only, the day after Steve ruled "Okay we're adding the blog link now" (28 November, 16:42 CST). His words on seeing it, 08:16 CST: "All emails like this should include my blog link". From this version Template A v1 and Template B v1 carry seven links, in the order of his 19 and 28 November rulings: Resume, Site, GitHub, LinkedIn, About, Blog, Recommendations. Blog is /?view=blog&r=<code>; Recommendations is /api/go/linkedin-recs?r=<code>, the counted pass-through RECONNECT-v1 already sends (ADR-108's addendum on that key). In the HTML body each label is now the bold link text and the address sits only in the href, the shape of his 26 October rule.
The two new links are not columns. LeadRecord.BlogLink and LeadRecord.RecommendationsLink are made from the lead's RefCode, so every lead already in the book renders them at its next send with the code it was given, and no code is minted again. SpoolLinks takes the two as optional fields, held to the lead's code when a lead file carries them, and TrackAContacts makes them from the row's code, because the night's jobs lane and leaders.py write seventeen cells and a new column would make every row they write unread. A lead with no code renders nothing and names BlogLink and RecommendationsLink as its blanks.
Templates A v2 and A v3, the short Track A emails with one link (approved 26 and 28 October), are unchanged. The text already sent is unchanged too: each email row keeps both bodies whole. CampaignSendTests holds both templates byte for byte (A v1 now among them), the seven labels in order with the send's code in each, and a lead banked before the blog; TrackATests and LeadImportTests hold the two links from a contact row and a lead file.
Addendum, 2026-11-29 (1.0.5.200): the LinkedIn bullet says LinkedIn verified him
From this version the LinkedIn line in Template A v1 and Template B v1 reads - LinkedIn ✓ identity verified: {LinkedInLink}, Steve's wording. In the HTML body only the word "LinkedIn" is the bold link, and " ✓ identity verified" follows it as plain text. In the plain body the line is "LinkedIn ✓ identity verified:
". The mark is the character U+2713, never an image. A v2 and A v3 carry one link and are unchanged. No send, ceiling, schema or gate changed. CampaignSendTests fails when a rendered A v1 or B v1 lacks the words.
Files
Addendum, 2026-12-02 (1.0.5.259): the poster of this morning's application gets a Track A row from the 6 AM program
What stopped being true: that a Track A contact row is written only by the night's jobs lane and the leaders lane. On 2 December three applications went in at 06:52 and none had a named person in the week's contact files, while the two rows the jobs lane had written that night were for roles that never sent; the leaders lane ran at 08:06, after the 08:00 pass. RULE 87 asks a tier 1 or 2 application's poster for an email the same day.
From this version the 6 AM program, right after the apply lane's records and before the invites lane, writes one row for each verified application whose MATCH tier is 1 or 2, whose READY row reads remote (Templates A v2 and A v3 both say "Remote"), and whose poster the feed read live on LinkedIn that morning with the company's domain: dispatch/leaders/hunter_find.py gives the address (KEEP only, its month count and log as they are), then leaders.py add --paired writes the row with Lane paired-<yyyyMMdd>, which TemplateRender reads as Template A v2. --paired lets a poster below RULE 68's leader titles through and does not count the person's own paired queue block as a touch; a tracker row naming them, a second row for a company in the week's files and a shared mailbox are still refused. Every application gets one "EMAIL LEG:" line in the apply lane's DONE note, and a row written after 07:55 Central says it is late, for the next day's pass. No template changes. EmailLegTests hold the plan and the lines on mocks.
Addendum, 2026-12-03 (1.0.5.267): Template A v2 and v3 lead with "check my work"
What stopped being true: that A v2 and A v3 open on "Good morning!" and put the one link on the third line behind "I build .NET on Azure with AI in the loop, and TheYard shows how:". On 3 December Steve approved the change that the review link lead every first touch (his words 09:22 CST: "Make all of these changes"), and J:\mentor\email-templates\TEMPLATE-A-posted-v2.md and -v3.md were rewritten that morning.
From this version Templates/A-v2.md and Templates/A-v3.md are those files byte for byte, subject to "Steve" (the notes under them stay out, as before): the role sentence with no "Good morning!", then "I build with AI and gate it so quality never slides. You can check my work in two minutes:", then {SiteLink} alone on its line, which the leads' rows carry as the review route with the send's code. The closes, the subject, the one link and TemplateRender are unchanged; a company mailbox's email now opens on the role sentence. A v3 holds 42 fixed words beside the title it names twice, so a title of ten words or more takes it past sixty and the lead is held as before. LeaderTemplateTests holds both texts word for word and the lead in the first three lines after the greeting.
Enforced by
13 rules in the rulebook cite this record, each held by a test on every release.