spec(6.3.2): an absent next_available_date must not rank as available - #17
Open
danieljaffe1 wants to merge 1 commit into
Open
spec(6.3.2): an absent next_available_date must not rank as available#17danieljaffe1 wants to merge 1 commit into
danieljaffe1 wants to merge 1 commit into
Conversation
danieljaffe1
force-pushed
the
spec/availability-hint-ranking
branch
from
August 26, 2026 12:46
589a9c4 to
cf95ace
Compare
§3.6 makes next_available_date optional but never says what its absence means to a consumer, and the natural reading of the field inverts it. A producer sampling a bounded horizon omits the date precisely when nothing in that horizon is open -- when the service is fully booked. Resolving the absent field to zero and measuring the distance from now therefore awards the largest boost to the services a buyer is least able to book. On a live registry index that was 3 of 9 services. §6.3.2 states the absence semantics as a MUST, and ties §6.3's "MUST NOT use the hint as a hard availability filter" to matching: a hint's value must not cause a service to leave the matched set, which a re-ranking phase over the already-matched set guarantees structurally. That second rule states its converse deliberately, because the natural over-reading is unsatisfiable. A registry pages a bounded window -- the reference implementation retrieves the top 500 by score and reports no further pages -- so requiring every matched service to stay reachable by paging would make every registry backed by a real search engine non-conformant. Text relevance and geo distance already decide window membership; the hint is not special, and ranking effects inside a bounded window are not exclusion. Deliberately not specified: how a registry weights or composes the signal. §6.3.1 already leaves ranking registry-defined, and no response distinguishes a registry that multiplies its freshness factor from one that adds it -- a normative rule that cannot be tested from the wire is a design opinion, not protocol. Scoring formulas, weights and horizons stay in registry implementation guidance. Verified: tools/usp_check.py all passes (schemas, refs, vectors, authority) and mkdocs build --strict exits 0 with the new anchors resolving on the registry and service-catalog pages. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
danieljaffe1
force-pushed
the
spec/availability-hint-ranking
branch
from
August 26, 2026 12:50
cf95ace to
08d757a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The gap
§3.6 makes
next_available_dateoptional and never says what its absence means to a consumer. That is the defect, and the natural reading of the field inverts it.A producer that samples a bounded horizon has no date to publish precisely when nothing in that horizon is open — that is, when the service is fully booked. So an implementation that resolves the absent field to a numeric zero and measures the distance from now awards its largest boost to the services a buyer is least able to book. Not hypothetical: on a live registry index, 3 of 9 returned services carried a valid hint with no
next_available_date.A second registry implementing ranking from this specification alone hits the same trap, because nothing here tells it not to.
What this adds
§6.3.2, two rules:
1. An absent
next_available_dateis neutral, never maximal. Its contribution MUST be identical to that of a service carrying no hint at all, and MUST NOT be read as availability today or as the nearest possible date.2. The hint is not an input to matching. §6.3's MUST NOT use the hint as a hard availability filter governs matching: a hint's value MUST NOT cause a service to fail the request's filters or otherwise leave the matched set. Registries SHOULD apply the signal in a re-ranking phase over the already-matched set, so that holds structurally rather than by convention.
Rule 2 also states its converse, and that sentence is load-bearing: ordinary ranking effects within a bounded result window are not exclusion. An earlier draft of this PR required that every matched service "remain reachable by paging the full result sequence" — which is unsatisfiable. A registry pages a bounded window (the reference implementation retrieves the top 500 by score and reports no further pages), and text relevance and geo distance already decide window membership. Requiring otherwise would make every registry backed by a real search engine non-conformant, so the spec says so explicitly rather than leaving the next implementer to discover it.
Plus the enabling
MAY, and cross-references from the §6.3 pass-through paragraph and the §3.6.1 use-case table.What this deliberately does not specify
Not how a registry weights or composes the signal. §6.3.1 already leaves ranking registry-defined, and that is the right default here: no response distinguishes a registry that multiplies its freshness factor from one that adds it. A normative rule that cannot be tested from the wire is a design opinion in spec clothing.
So there is no weight, no decay curve, no horizon, and no scoring formula in this PR — those belong in registry implementation guidance. An earlier draft carried all of it (a freshness-composition SHOULD, a refresh SHOULD, a disclosure SHOULD, and a worked scoring table: 106 lines, 15 RFC-2119 keywords). The refresh SHOULD in particular was redundant — §3.6 already says businesses SHOULD regenerate every 1–6 hours and §6.3 already says registries SHOULD re-index at most every 24 hours.
Scope
No wire change — nothing new is sent or returned, so
schemas/,openapi/andopenrpc/are untouched.specification.mdsite-docs/specification/discovery-registry.mdAGENTS.md)site-docs/specification/service-catalog.mdCHANGE_LOG.mdVerification
tools/usp_check.py all→schemas: ok,refs: ok,vectors: ok,authority: ok(run against a built site, soauthorityexercises rather than skips)mkdocs build --strictexits 0; the new#availability-hint-rankinganchor resolves on the registry page and the cross-page link from the service-catalog page resolves to itif (attribute(availability_next_date) > 0, …, 0)) and applies the term in second phase only, so it never participates in matching🤖 Generated with Claude Code