ThatAIguyA world of ideas

THE CONSCIOUSNESS ATLAS
Read. Experiment. Follow the evidence.

ConsciousnessLearn · Explore · Joseph Anady

Janady13/missionmatch / internal/modules/ai/bid_baserate.go

Source identity, revision, and recovered contents.

GitHub sourceSource text recovered

Source identity

FieldRecorded value
Source typeGitHub source
Original recordJanady13/missionmatch / internal/modules/ai/bid_baserate.go
DateNot specified in source
RepositoryJanady13/missionmatch
Revision720d47fae476b0d38477ae4401697d372b1ea2bc
Branchfeature/opportunity-to-outcome
Path or archive memberinternal/modules/ai/bid_baserate.go
Original SHA-256d3dc5d91800777b16267637985052612d0460065ae3f724edab209e0a3af4e8b
Git blob SHAd02a615cc9090d1f7debe6db2c1298b1b36c2688
Reading-copy SHA-256d3dc5d91800777b16267637985052612d0460065ae3f724edab209e0a3af4e8b

Original source ↗

Every recorded occurrence

These 12 records contain identical original source bytes. Their paths and revisions remain part of the archive.

Original recordBranch or archiveRevision / identifierOriginal location
Janady13/missionmatch / internal/modules/ai/bid_baserate.gofeature/opportunity-to-outcome720d47fae476b0d38477ae4401697d372b1ea2bcOpen original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gocollision-deconfliction4ee5a09972608ed89f8377c6665542d5f450f0a6Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gom5-price-to-win41000ad30fff4129fdaf5ec84e15ba14c27d4890Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gomaster1e9249840a4302ec82e123b9c9cb6f75badea3e4Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gomag-substrateb82c7100a492dec67dfd1eda6b3f53def859be35Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gotime-to-fill-survivalb66e1e505863d4f17741a4b9ede73509e45bd6c6Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gographrag-foundationb0ddeb9f633fd138d09309d1a17b7d13bc3a67f7Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gopresentation-readinesseb574acaa29d71ce4d0f852572e87c275c79fdb7Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.govendor-intelligencefe9796a19c261951d3f2565206c0c1b5ac294465Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gophase2-connectorse038d4c687aec16f8bd9bc4d907eea14d91f8704Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gofeature/aioe-upgrade2178e7298d0e5d9af83afa12402fd587f0ba6ed8Open original
Janady13/missionmatch / internal/modules/ai/bid_baserate.gocapture-readinessbae6af7cb2997e819174a9e9cfff5e16067a1975Open original

Recovered source transcript

package ai // M7 bid outcomes advisory base rate (a TAG aggregate intent, NOT a graph intent and NOT a bench intent). // bid_win_rate_by_segment reports an advisory MARKET base rate over the caller's own bid_outcomes ledger: // per customer agency segment (read from the linked requirement), the win count, the total decided (win // plus loss, the denominator that excludes pending and no_bid), and the win rate as a numeric ratio. It is // advisory context for a capture team, explicitly NOT a candidate score and NOT an employment decision // number; the frozen matching engine stays the only scorer and no learned model consumes this read yet. // // Honesty and safety are enforced by construction. The denominator counts only decided bids (win plus // loss), so a pending or no_bid bid never inflates or deflates the rate. The ratio is computed in SQL as a // numeric divided by a numeric guarded with NULLIF so a segment with no decided bid yields a NULL rate, not // a divide by zero; the Go side scans that ratio into a shopspring/decimal pointer (a NULL rate is a nil // pointer), never a float64. It reads only bid_outcomes and requirements, both allowlisted tenant tables, // never a person table, never a score, never the eeo schema. It takes no SQL parameter: it reports every // segment of the caller's ledger, RLS scoped so one tenant's win rate can never surface in another's. // // The SQL is a reviewed static constant. ValidateRegistry asserts it through GuardReadOnlyQuery at boot and // a unit test, and ExecuteIntent re guards it on every execution, so it can only ever run as a single read // only SELECT over the allowlisted tables. // IntentBidWinRateBySegment is the registered name of the advisory bid win rate base rate read. const IntentBidWinRateBySegment = "bid_win_rate_by_segment" // bidWinRateBySegmentSQL aggregates the caller's bid_outcomes by the customer agency of the linked // requirement. The LEFT JOIN keeps outcomes whose requirement link is null (or whose requirement has no // customer agency) under an "(unspecified)" segment label rather than dropping them. The denominator // total_decided counts only win plus loss; the win rate is win_count over total_decided guarded with NULLIF // so a segment with zero decided bids returns a NULL ratio, never a divide by zero. The numeric cast keeps // the ratio exact for the shopspring/decimal scan in Go. Ordered by total decided descending with a segment // tiebreaker for a stable, byte deterministic result. const bidWinRateBySegmentSQL = `SELECT COALESCE(NULLIF(r.customer_agency, ''), '(unspecified)') AS customer_agency, count(*) FILTER (WHERE b.result = 'win') AS win_count, count(*) FILTER (WHERE b.result IN ('win', 'loss')) AS total_decided, (count(*) FILTER (WHERE b.result = 'win'))::numeric / NULLIF(count(*) FILTER (WHERE b.result IN ('win', 'loss')), 0) AS win_rate FROM bid_outcomes b LEFT JOIN requirements r ON r.id = b.requirement_id GROUP BY COALESCE(NULLIF(r.customer_agency, ''), '(unspecified)') ORDER BY total_decided DESC, customer_agency`

Search equations, builds, manuscript text, and recovered sources.