High-performance browser automation bridge and multi-instance orchestrator with advanced stealth injection and real-time dashboard.
fix: recognize proceed-to-payment checkout intent
zhaod32a1ffa1a6f0
diff --git a/internal/semantic/improvements_test.go b/internal/semantic/improvements_test.goindex 319f276e..d9da2d51 100644--- a/internal/semantic/improvements_test.go+++ b/internal/semantic/improvements_test.go@@ -542,6 +542,26 @@ func TestCombined_Synonym_Purchase_Checkout(t *testing.T) {}}+func TestCombined_Synonym_ProceedToPayment_PlaceOrder(t *testing.T) {+ sites := buildRealWorldElements()+ matcher := NewCombinedMatcher(NewHashingEmbedder(128))++ result, err := matcher.Find(context.Background(), "proceed to payment", sites["ecommerce"], FindOptions{+ Threshold: 0.15,+ TopK: 5,+ })+ if err != nil {+ t.Fatal(err)+ }+ t.Logf("Query='proceed to payment': BestRef=%s Score=%.3f", result.BestRef, result.BestScore)+ for _, m := range result.Matches {+ t.Logf(" match: ref=%s score=%.3f role=%s name=%s", m.Ref, m.Score, m.Role, m.Name)+ }+ if result.BestRef != "e8" {+ t.Fatalf("expected 'proceed to payment' to match 'Place Order' (e8), got %s", result.BestRef)+ }+}+func TestCombined_Synonym_Dismiss_Close(t *testing.T) {sites := buildRealWorldElements()matcher := NewCombinedMatcher(NewHashingEmbedder(128))diff --git a/internal/semantic/synonyms.go b/internal/semantic/synonyms.goindex 35622ad3..f196c56e 100644--- a/internal/semantic/synonyms.go+++ b/internal/semantic/synonyms.go@@ -55,7 +55,7 @@ var uiSynonyms = map[string][]string{// Shopping & e-commerce"cart": {"basket", "bag", "shopping cart"},- "checkout": {"pay", "purchase", "buy", "place order", "order"},+ "checkout": {"pay", "payment", "purchase", "buy", "place order", "order", "proceed to payment"},"price": {"cost", "amount", "total"},"quantity": {"qty", "count", "amount"},