tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 251eeab1c468eb1557269952c712580e4cc16e29
parent c94d1b16b30f2f2736de8bb1d338496e9e5f7734
Author: agoloman <agoloman@mozilla.com>
Date:   Tue, 28 Oct 2025 04:03:55 +0200

Revert "Bug 1996648 - Update query intent detection model to mobilebert v0.2 r=Mardak,firefox-ai-ml-reviewers" for causing xpc failures @test_smart_assist_engine.js.

This reverts commit d98f6b4f0a1f49ebc48b50993cc8b1686831c74f.

Diffstat:
Mbrowser/components/genai/SmartAssistEngine.sys.mjs | 12++----------
1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/browser/components/genai/SmartAssistEngine.sys.mjs b/browser/components/genai/SmartAssistEngine.sys.mjs @@ -223,19 +223,11 @@ export const SmartAssistEngine = { const engine = await this._createEngine({ featureId: "smart-intent", modelId: "mozilla/mobilebert-query-intent-detection", - modelRevision: "v0.2.0", + modelRevision: "v0.1.0", taskName: "text-classification", }); - const threshold = 0.6; const resp = await engine.run({ args: [[query]] }); - // resp example: [{ label: "chat", score: 0.95 }, { label: "search", score: 0.04 }] - if ( - resp[0].label.toLowerCase() === "chat" && - resp[0].score >= threshold - ) { - return "chat"; - } - return "search"; + return resp[0].label.toLowerCase(); } catch (error) { console.error("Error using intent detection model:", error); throw error;