route: remove two host advantages instead of disclosing them - #661
Merged
Conversation
… of disclosing them The previous commit published three rules that favoured our own catalog on the theory that a checkable small claim beats an unverifiable large one. That was the right instinct applied one step too late: two of the three did not need to exist. REMOVED - the per-seller diversity cap now applies to our catalog on the same terms as every external seller's. The exemption was justified on the reasoning that capping the host pushes buyers toward less-vetted externals. Measured over 30 representative queries at top=12, our catalog took 8.3% of slots and the exemption actually bound on ONE query. It was buying almost nothing and costing the thing the endpoint exists for. Skipped only for include=local, where there is one seller by definition and a per-seller cap would truncate the answer to a third; verified include=local still returns 12 of 12. REMOVED - the listing-injection filter now runs against our rows too. It was external-only because the filter defends against seller-controlled text and we trust our own, but "we are exempt from our own safety check" is a rule that favours the host, and a catalog entry of ours that tripped it would be a bug worth seeing rather than an exception worth granting. Verified live: all 526 tools still findable by their own slug, none filtered. KEPT AND STILL DISCLOSED - our own health is asserted as 1 rather than measured, because the crawler never probes itself and there is no honest way to synthesise a crawl history for ourselves on the router's hot path. Every result carries why.healthSource so an asserted 1 is never mistaken for a measured one. So the disclosure went from three entries to one, by fixing rather than explaining. Fixing an asymmetry beats publishing it. 80 assertions. The tests now guard the removals as well as the disclosure: restoring the cap exemption, making the filter external-only again, and disarming the filter entirely each kill assertions. The filter guard pins both directions - no ordinary tool description of ours trips it, and a real injection attempt still does, so making it symmetric cannot have quietly disarmed it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
Follow-up to #660, which published three rules favouring our own catalog on the theory that a checkable small claim beats an unverifiable large one. Right instinct, applied one step too late: two of the three did not need to exist.
Removed
The per-seller diversity cap now applies to our catalog on the same terms as every external seller's. The exemption was justified on the reasoning that capping the host pushes buyers toward less-vetted externals. Measured over 30 representative queries at
top=12, our catalog took 8.3% of slots and the exemption bound on exactly one query. It was buying almost nothing and costing the thing the endpoint exists for.Skipped only for
include=local, where there is one seller by definition and a per-seller cap would truncate the answer to a third. Verified:include=local&top=12still returns 12.The listing-injection filter now runs against our rows too. It was external-only because the filter defends against seller-controlled text and we trust our own, but "we are exempt from our own safety check" is a rule that favours the host, and a catalog entry of ours that tripped it would be a bug worth seeing rather than an exception worth granting. Verified live: all 526 tools still findable by their own slug, none filtered.
Kept, and still disclosed
Our own health is asserted as
1rather than measured, because the crawler never probes itself and there is no honest way to synthesise a crawl history for ourselves on the router's hot path. Every result carrieswhy.healthSourceso an asserted 1 is never mistaken for a measured one.The
neutralityblock went from three entries to one, by fixing rather than explaining.Verification
scripts/test-discovery-note.js, in CI