Repository navigation
Add opt-in link prediction to Speculative Loading - #1509
Draft
adamsilverstein wants to merge 7 commits into
Draft
adamsilverstein wants to merge 7 commits into
adamsilverstein wants to merge 7 commits into
Conversation
Contributor
|
this is what google's up to? crazy |
Contributor
|
🥲 |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## trunk #1509 +/- ##
==========================================
+ Coverage 70.84% 71.09% +0.24%
==========================================
Files 91 92 +1
Lines 7967 8077 +110
==========================================
+ Hits 5644 5742 +98
- Misses 2323 2335 +12
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Link prediction loads pages before any interaction, which raises server load, so it needs to be an explicit opt-in next to the other settings. Claude-Session: https://claude.ai/code/session_018vwYjS6a4aSvRzXnBSD5N7
The language model prototype needed a multi-gigabyte model download, was limited to a few desktop browsers, took seconds to answer and returned free text that had to be parsed. Scoring each link with a logistic model over layout signals gives a probability per link in a few milliseconds in any browser that supports speculation rules. Predicted links are marked with an attribute that a document rule selects, so the exclusions for speculative loading keep applying. Claude-Session: https://claude.ai/code/session_018vwYjS6a4aSvRzXnBSD5N7
This branch has not been deployed
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.
This started as an experiment with Chrome's built-in AI. I reworked it to use a small decision engine that calculates the probability of each link being visited instead, still entirely on device.
Claude rebuilt the prototype along those lines and wrote up what changed:
AI Use
Code and description both written with 🤖 Claude Code after I asked it to swap the language model for a decision engine. I will review and test.