Bring the Python side to the ADR: the judge scores 0 to 10 with the cap at 4 and migration 33 clears every judgement, summarise reads the top 30 of the want and the match order, a hidden company's roles are never in the feed, and the company switch is called All locations.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6cad9713ac
commit
6d82287402
27 files changed
+390
-247
No files matched your search
+9
-9
@@ -10,7 +10,7 @@ on. Computed once per pull (`plan`) and handed to each board's batch as the
|
||||
empty, or holds any other member (a function, a remote value other than
|
||||
`remote`, a place the gazetteer does not know), can take a role from
|
||||
anywhere, so the base reach is then everywhere.
|
||||
- **Wide reach, for the companies set to All countries**
|
||||
- **Wide reach, for the companies set to All locations**
|
||||
(`companies.all_countries`, global): the union over the enabled agents of
|
||||
their `require` reach, the intersection of each one's `require` gates on
|
||||
country and place, Europe today, expanded to its countries through the
|
||||
@@ -272,7 +272,7 @@ class Plan:
|
||||
def why(self, sub: Subscription) -> tuple[Reach, str]:
|
||||
"""The reach `sub` is read with, and why: `override`, `small`,
|
||||
`unknown` (a board never read whole), `countries` (its company is
|
||||
set to All countries) or `agents`."""
|
||||
set to All locations) or `agents`."""
|
||||
if OVERRIDE_KEYS & set(sub.params or {}):
|
||||
return EVERYWHERE, "override"
|
||||
size = self.sizes.get(sub.target)
|
||||
@@ -296,7 +296,7 @@ class Plan:
|
||||
def for_subscription(self, sub: Subscription) -> dict[str, Any] | None:
|
||||
"""The `reach` a board's batch hands `ask_for`; None for none. With
|
||||
fetch terms, and unless its company is set to All roles, a big board
|
||||
carries them, and `wide` when its company is set to All countries, for
|
||||
carries them, and `wide` when its company is set to All locations, for
|
||||
`ask_for` to decide which side gives way over `MAX_SERIES` (see the
|
||||
module docstring). A board with no size carries
|
||||
`unsized` and `small`, and the reach of a big board unless its params
|
||||
@@ -360,7 +360,7 @@ def plan(store: Store, subs: Iterable[Subscription] | None = None) -> Plan:
|
||||
base = wide = EVERYWHERE
|
||||
subs = list(store.subscriptions(source="ats") if subs is None else subs)
|
||||
rows = store.companies()
|
||||
# All countries never reads less than the board would without it: the
|
||||
# All locations never reads less than the board would without it: the
|
||||
# base's remote, which a `require` of Europe does not name, is kept.
|
||||
return Plan(base, wide | base, sizes(store, subs),
|
||||
all_countries=frozenset(c.key for c in rows if c.all_countries),
|
||||
@@ -380,7 +380,7 @@ def reaches(store: Store, subs: Iterable[Subscription]) -> Mapping[str, dict[str
|
||||
|
||||
#: Why a board is read whole, as the Companies list says it.
|
||||
_WHOLE = {"small": f"under {SMALL} roles", "unknown": "size not known yet",
|
||||
"override": "set here", "countries": "all countries (everywhere)",
|
||||
"override": "set here", "countries": "all locations (everywhere)",
|
||||
"agents": "an agent takes any place"}
|
||||
|
||||
|
||||
@@ -452,8 +452,8 @@ def line(found: Plan, sub: Subscription) -> str:
|
||||
"follows agents: DK, SE, remote · follows agents' terms: engineer,
|
||||
product", "follows agents: DK, SE, remote · all roles" (a company set to
|
||||
All roles, or a reader without a query, or terms over `MAX_SERIES`),
|
||||
"all countries (Europe) · follows agents' terms: engineer, product,
|
||||
data", "all countries (Europe) · all roles", "set here: DE · all roles",
|
||||
"all locations (Europe) · follows agents' terms: engineer, product,
|
||||
data", "all locations (Europe) · all roles", "set here: DE · all roles",
|
||||
"all places, too many countries to ask · follows agents' terms:
|
||||
engineer", or, for a board read whole, why: "under 300 roles: read
|
||||
whole", "Greenhouse cannot filter: read whole". A board with no size yet
|
||||
@@ -485,13 +485,13 @@ def line(found: Plan, sub: Subscription) -> str:
|
||||
else "")
|
||||
if why == "countries":
|
||||
named = found.wide_names or f"{len(found.wide.countries)} countries"
|
||||
return f"all countries ({named}){unasked} · {roles}"
|
||||
return f"all locations ({named}){unasked} · {roles}"
|
||||
if why == "override":
|
||||
return f"set here: {_places(ask)}{unasked} · {roles}"
|
||||
return f"follows agents: {_places(ask)}{unasked} · {roles}"
|
||||
if ask.terms:
|
||||
if given.everywhere:
|
||||
what = "all countries (everywhere)" if why == "countries" else _WHOLE[why]
|
||||
what = "all locations (everywhere)" if why == "countries" else _WHOLE[why]
|
||||
return f"{what} · {roles}"
|
||||
return f"all places, too many countries to ask · {roles}"
|
||||
if why in ("agents", "countries") and given.everywhere:
|
||||
|
||||
Reference in new issue
Block a user