From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.devel Subject: RE: handling many matches Date: Sat, 2 May 2020 12:51:31 -0700 (PDT) Message-ID: <3c78acf7-b76e-41b7-a323-c26f3301d3c9@default> References: <<119c0543-387d-4fad-b7fe-b4e07a7be4f8@default>> <> <<837dxuvohj.fsf@gnu.org>> <> <<83wo5usaui.fsf@gnu.org>> <<14f6ff0f-afcc-5cc2-b8ce-491209c1e739@yandex.ru>> <<83y2qaqoxi.fsf@gnu.org>> <<5f531674-88b2-55fd-a677-7cbd57a62b91@yandex.ru>> <<83tv0yqmeq.fsf@gnu.org>> <> <<83pnbmqjcz.fsf@gnu.org>> <> <<83imheqin8.fsf@gnu.org>> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="74945"; mail-complaints-to="usenet@ciao.gmane.io" Cc: jonas@bernoul.li, emacs-devel@gnu.org, monnier@iro.umontreal.ca, adam@alphapapa.net, kyle@kyleam.com, drew.adams@oracle.com To: Eli Zaretskii , Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 02 21:52:20 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jUyBP-000JNB-Fa for ged-emacs-devel@m.gmane-mx.org; Sat, 02 May 2020 21:52:19 +0200 Original-Received: from localhost ([::1]:57052 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jUyBO-0008WL-Ht for ged-emacs-devel@m.gmane-mx.org; Sat, 02 May 2020 15:52:18 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49378) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jUyAs-00085M-4A for emacs-devel@gnu.org; Sat, 02 May 2020 15:51:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jUyAr-00073A-Do for emacs-devel@gnu.org; Sat, 02 May 2020 15:51:45 -0400 Original-Received: from aserp2120.oracle.com ([141.146.126.78]:51168) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jUyAn-0006YH-NX; Sat, 02 May 2020 15:51:41 -0400 Original-Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 042JnIiS001813; Sat, 2 May 2020 19:51:35 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=FlD3SJeKLRX+HsGDGo5ibVD2egosxl3Ml/oblh0CeGc=; b=qu21sjBBtiy1DscuRZ60tFIPgFo/JVd0ZNbCzFgWlFOVlofSLcB5+Al7/LhTqtYqn2ii bH9FUZVWY7qIYIQ/p58pyi/8aS3FkdXa3rAxOMcZy0T/Z2G9qGj+7yf4g8jrrzSabhxa lNf/2n6XtqiIJMjgEg8JtDBc9cHdU/7ughsqDezDu7QXup2gpqVd+ztloJPsDX6Gq/nX bkvFms69sCnXtX80p955zVyWAkdE6nM33B/je2iLCMTqlOslpBjs3Ypx5iKgrP4Mc004 koAqG7cGwGDHdG+vAe2iez/UAMgW+Z6zMKVno6S/GDOuDZ1pdZOYgkRqupLYRXKlK1XS Eg== Original-Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by aserp2120.oracle.com with ESMTP id 30s0tm1qdf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 02 May 2020 19:51:35 +0000 Original-Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 042JlUZ7118586; Sat, 2 May 2020 19:51:34 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userp3030.oracle.com with ESMTP id 30rwysmnrv-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 02 May 2020 19:51:34 +0000 Original-Received: from abhmp0014.oracle.com (abhmp0014.oracle.com [141.146.116.20]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 042JpWBZ021730; Sat, 2 May 2020 19:51:32 GMT In-Reply-To: <<83imheqin8.fsf@gnu.org>> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4993.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9609 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=999 bulkscore=0 phishscore=0 malwarescore=0 spamscore=0 adultscore=0 mlxscore=0 suspectscore=18 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2005020173 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9609 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 malwarescore=0 mlxscore=0 priorityscore=1501 lowpriorityscore=0 spamscore=0 suspectscore=18 phishscore=0 clxscore=1015 bulkscore=0 mlxlogscore=999 adultscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2005020173 Received-SPF: pass client-ip=141.146.126.78; envelope-from=drew.adams@oracle.com; helo=aserp2120.oracle.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/02 12:49:53 X-ACL-Warn: Detected OS = Linux 3.x [generic] [fuzzy] X-Received-From: 141.146.126.78 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:248556 Archived-At: > You are still thinking about what our fuzzy completion does. That's > not how you get scores that are relevant for the user, because how > close the hit is to what the user typed is mostly irrelevant. Hear, hear! Maybe not "mostly" - depends on the use case. But certainly _in general_. Yes, relevance (score) varies, depending on the use case. In general, what's relevant is scoring the thing that is represented by its name, not the name itself. And how is that relevance determined? Typically, you need to use the PREDICATE arg to `completing-read', to match not only the name but also the accompanying data in an alist entry - data that can be super rich. Of course, that works only for an alist arg, not for an obarray, hash table, etc. But there are hacks for those other arg types (property on a symbol or string candidate, for example).