ContextFort automatically captures screenshots of every agent interaction, creating a complete visual audit trail. Screenshots are captured in pairs (before/after) for most actions, providing clear evidence of what the agent saw and what changed.
Privacy Notice: Screenshots may contain sensitive information (PII, PHI, financial data). All screenshots are stored locally on your machine and never transmitted externally.
Page Navigation: When agent navigates to a new URL, a “page_read” event is logged but no screenshot is captured (only metadata). This reduces storage usage while maintaining navigation history.
function onMessageScreenshotTrigger(message, tab) { let activation = activeAgentTabs.get(tab.id); if (!activation) return; if (message.action === 'click') { chrome.tabs.get(tab.id, (currentTab) => { if (chrome.runtime.lastError || !currentTab) return; // Capture BEFORE screenshot chrome.tabs.captureVisibleTab(tab.windowId, { format: 'png' }, (dataUrl1) => { if (chrome.runtime.lastError) return; saveEventData(dataUrl1, false, currentTab.url, currentTab.title, null) .then(actionId => { // Wait 300ms for page to update setTimeout(() => { chrome.tabs.get(tab.id, (resultTab) => { if (chrome.runtime.lastError || !resultTab) return; // Capture AFTER screenshot chrome.tabs.captureVisibleTab(tab.windowId, { format: 'png' }, (dataUrl2) => { if (chrome.runtime.lastError) return; saveEventData(dataUrl2, true, resultTab.url, resultTab.title, actionId); }); }); }, 300); }); }); }); }}
Why 300ms delay?
What if page takes longer?
Most web interactions complete within 300ms:
Button clicks trigger immediate UI changes
Modal dialogs appear instantly
Form validations show feedback quickly
300ms balances capturing the result without unnecessary delay.
If navigation or async loading takes longer than 300ms, the “after” screenshot may not show the final state. Future versions may implement adaptive delays based on network activity.
const inputDebounceTimers = new Map();const INPUT_DEBOUNCE_MS = 1000;function onMessageScreenshotTrigger(message, tab) { if (message.action === 'input') { let debounceState = inputDebounceTimers.get(tab.id); if (!debounceState) { debounceState = { timer: null, inputs: [], tabInfo: null }; inputDebounceTimers.set(tab.id, debounceState); } // Clear existing timer if (debounceState.timer) { clearTimeout(debounceState.timer); } // Collect input value debounceState.inputs.push({ element: message.element, inputValue: message.inputValue, timestamp: new Date().toISOString() }); // Set new timer debounceState.timer = setTimeout(() => { const collectedInputs = debounceState.inputs; const inputValues = collectedInputs.map(i => i.inputValue); inputDebounceTimers.delete(tab.id); chrome.tabs.get(tab.id, (currentTab) => { if (chrome.runtime.lastError || !currentTab) return; // Wait 500ms for rendering setTimeout(() => { chrome.tabs.captureVisibleTab(tab.windowId, { format: 'png' }, (dataUrl) => { if (chrome.runtime.lastError) return; // Save with ALL input values const screenshotData = { id: Date.now() + Math.random(), sessionId: activation.sessionId, tabId: tab.id, url: currentTab.url, title: currentTab.title, reason: 'agent_event', timestamp: new Date().toISOString(), dataUrl: dataUrl, eventType: 'input', eventDetails: { inputValues: inputValues, // Array of all input values actionType: 'input_result' } }; queuedStorageWrite(screenshotData, activation); }); }, 500); }); }, INPUT_DEBOUNCE_MS); }}
Why debounce input events?
Without debouncing, typing “Hello World” would trigger 11 screenshots (one per keystroke). Debouncing ensures only one screenshot is captured after typing is complete.Debounce Timer: 1000ms (1 second)
Additional Delay: 500ms for rendering
Total Delay: 1.5 seconds after last keystroke
Why collect all input values?
The inputValues array captures the full typing sequence:
chrome.storage.local.clear(() => { console.log('All ContextFort data deleted');});
3
Delete Specific Screenshots
Currently, you can delete all screenshots via Chrome storage. Individual screenshot deletion via the dashboard is not yet available.To delete all screenshots: