Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions sentience-chrome/injected_api.js
Original file line number Diff line number Diff line change
Expand Up @@ -726,17 +726,23 @@
}

console.log(`[SentienceAPI] Found ${iframes.length} iframe(s), requesting snapshots...`);

// Request snapshot from each iframe
const iframePromises = iframes.map((iframe, idx) => {
// OPTIMIZATION: Skip common ad domains to save time
const src = iframe.src || '';
if (src.includes('doubleclick') || src.includes('googleadservices') || src.includes('ads system')) {
console.log(`[SentienceAPI] Skipping ad iframe: ${src.substring(0, 30)}...`);
return Promise.resolve(null);
}

return new Promise((resolve) => {
const requestId = `iframe-${idx}-${Date.now()}`;

// 1. EXTENDED TIMEOUT (Handle slow children)
const timeout = setTimeout(() => {
console.warn(`[SentienceAPI] ⚠️ Iframe ${idx} snapshot TIMEOUT (id: ${requestId})`);
resolve(null);
}, 10000); // Increased to 10s to handle slow processing
}, 5000); // Increased to 5s to handle slow processing

// 2. ROBUST LISTENER with debugging
const listener = (event) => {
Expand Down Expand Up @@ -1036,6 +1042,10 @@
return {
status: "success",
url: window.location.href,
viewport: {
width: window.innerWidth,
height: window.innerHeight
},
elements: cleanedElements,
raw_elements: cleanedRawElements,
screenshot: screenshot
Expand Down
2 changes: 1 addition & 1 deletion sentience-chrome/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"manifest_version": 3,
"name": "Sentience Semantic Visual Grounding Extractor",
"version": "2.0.2",
"version": "2.0.4",
"description": "Extract semantic visual grounding data from web pages",
"permissions": ["activeTab", "scripting"],
"host_permissions": ["<all_urls>"],
Expand Down
93 changes: 47 additions & 46 deletions sentience-chrome/release.json
Original file line number Diff line number Diff line change
@@ -1,45 +1,45 @@
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127",
"assets_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127/assets",
"upload_url": "https://uploads.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127/assets{?name,label}",
"html_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/tag/v2.0.3",
"id": 273025127,
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273046101",
"assets_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273046101/assets",
"upload_url": "https://uploads.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273046101/assets{?name,label}",
"html_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/tag/v2.0.4",
"id": 273046101,
"author": {
"login": "rcholic",
"id": 135060,
"node_id": "MDQ6VXNlcjEzNTA2MA==",
"avatar_url": "https://avatars.githubusercontent.com/u/135060?v=4",
"login": "github-actions[bot]",
"id": 41898282,
"node_id": "MDM6Qm90NDE4OTgyODI=",
"avatar_url": "https://avatars.githubusercontent.com/in/15368?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/rcholic",
"html_url": "https://github.com/rcholic",
"followers_url": "https://api.github.com/users/rcholic/followers",
"following_url": "https://api.github.com/users/rcholic/following{/other_user}",
"gists_url": "https://api.github.com/users/rcholic/gists{/gist_id}",
"starred_url": "https://api.github.com/users/rcholic/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/rcholic/subscriptions",
"organizations_url": "https://api.github.com/users/rcholic/orgs",
"repos_url": "https://api.github.com/users/rcholic/repos",
"events_url": "https://api.github.com/users/rcholic/events{/privacy}",
"received_events_url": "https://api.github.com/users/rcholic/received_events",
"type": "User",
"url": "https://api.github.com/users/github-actions%5Bbot%5D",
"html_url": "https://github.com/apps/github-actions",
"followers_url": "https://api.github.com/users/github-actions%5Bbot%5D/followers",
"following_url": "https://api.github.com/users/github-actions%5Bbot%5D/following{/other_user}",
"gists_url": "https://api.github.com/users/github-actions%5Bbot%5D/gists{/gist_id}",
"starred_url": "https://api.github.com/users/github-actions%5Bbot%5D/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/github-actions%5Bbot%5D/subscriptions",
"organizations_url": "https://api.github.com/users/github-actions%5Bbot%5D/orgs",
"repos_url": "https://api.github.com/users/github-actions%5Bbot%5D/repos",
"events_url": "https://api.github.com/users/github-actions%5Bbot%5D/events{/privacy}",
"received_events_url": "https://api.github.com/users/github-actions%5Bbot%5D/received_events",
"type": "Bot",
"user_view_type": "public",
"site_admin": false
},
"node_id": "RE_kwDOQshiJ84QRghn",
"tag_name": "v2.0.3",
"node_id": "RE_kwDOQshiJ84QRlpV",
"tag_name": "v2.0.4",
"target_commitish": "main",
"name": "Release v2.0.3",
"name": "Release v2.0.4",
"draft": false,
"immutable": false,
"prerelease": false,
"created_at": "2025-12-27T01:12:14Z",
"updated_at": "2025-12-27T22:46:31Z",
"published_at": "2025-12-27T22:46:13Z",
"created_at": "2025-12-28T05:42:53Z",
"updated_at": "2025-12-28T05:44:58Z",
"published_at": "2025-12-28T05:44:57Z",
"assets": [
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333567799",
"id": 333567799,
"node_id": "RA_kwDOQshiJ84T4dc3",
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333683577",
"id": 333683577,
"node_id": "RA_kwDOQshiJ84T45t5",
"name": "extension-files.tar.gz",
"label": "",
"uploader": {
Expand All @@ -65,17 +65,17 @@
},
"content_type": "application/gzip",
"state": "uploaded",
"size": 73434,
"digest": "sha256:ca93cdaf875792eb22333f7ba5b13dd129552f388900e624422e73959338d8fb",
"size": 73579,
"digest": "sha256:664d4476dc5741e0df63d6264db43a63b9ab2a4deac3049a1e61e084ebf2639c",
"download_count": 0,
"created_at": "2025-12-27T22:46:31Z",
"updated_at": "2025-12-27T22:46:31Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.3/extension-files.tar.gz"
"created_at": "2025-12-28T05:44:58Z",
"updated_at": "2025-12-28T05:44:58Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.4/extension-files.tar.gz"
},
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333567800",
"id": 333567800,
"node_id": "RA_kwDOQshiJ84T4dc4",
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333683578",
"id": 333683578,
"node_id": "RA_kwDOQshiJ84T45t6",
"name": "extension-package.zip",
"label": "",
"uploader": {
Expand All @@ -101,15 +101,16 @@
},
"content_type": "application/zip",
"state": "uploaded",
"size": 75584,
"digest": "sha256:291750ec174d9aadade298d2a2aa1057d08a138e2650c97cd93d56b6bcbee713",
"size": 75736,
"digest": "sha256:b817ac0bba53872e6f725b38e16063c476790b8498953c1bec3d645ebcbebfb4",
"download_count": 0,
"created_at": "2025-12-27T22:46:31Z",
"updated_at": "2025-12-27T22:46:31Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.3/extension-package.zip"
"created_at": "2025-12-28T05:44:58Z",
"updated_at": "2025-12-28T05:44:58Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.4/extension-package.zip"
}
],
"tarball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/tarball/v2.0.3",
"zipball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/zipball/v2.0.3",
"body": ""
"tarball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/tarball/v2.0.4",
"zipball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/zipball/v2.0.4",
"body": "## What's Changed\n* short iframe wait form 10 to 5; skip ad junk sites by @rcholic in https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/pull/18\n\n\n**Full Changelog**: https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/compare/v2.0.2...v2.0.4",
"mentions_count": 1
}