From mboxrd@z Thu Jan 1 00:00:00 1970 From: zimoun Subject: Re: Inverted index to accelerate guix package search Date: Tue, 14 Jan 2020 21:55:57 +0100 Message-ID: References: <87a76r68u6.fsf@ambrevar.xyz> <87muaqnmod.fsf@ambrevar.xyz> <87h80y12k3.fsf@roquette.mug.biscuolo.net> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:37620) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1irTES-0005Tt-2a for guix-devel@gnu.org; Tue, 14 Jan 2020 15:56:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1irTEQ-0007jV-QM for guix-devel@gnu.org; Tue, 14 Jan 2020 15:56:11 -0500 Received: from mail-qk1-x729.google.com ([2607:f8b0:4864:20::729]:40031) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1irTEQ-0007j5-Kb for guix-devel@gnu.org; Tue, 14 Jan 2020 15:56:10 -0500 Received: by mail-qk1-x729.google.com with SMTP id c17so13545331qkg.7 for ; Tue, 14 Jan 2020 12:56:10 -0800 (PST) In-Reply-To: <87h80y12k3.fsf@roquette.mug.biscuolo.net> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane-mx.org@gnu.org Sender: "Guix-devel" To: Giovanni Biscuolo Cc: Guix Devel Hi, On Tue, 14 Jan 2020 at 16:27, Giovanni Biscuolo wrote: > Pierre Neidhardt writes: > > By the way, what about using Xapian in Guix? Xapian could be really cool! However, the size of this dependency should be evaluated; then optional feature or not. > Actually I would love to search (tag?!?) for packages/services/machines > (profiles?) the same way I query my email database with notmuch: it > would give me a fourth dimension in "DevOps" :-) Currently, you can output all the packages with 'guix search ""' and index them using the Python API. It is not so nice but it should give an idea about what to expose first to Guile. > I cannot find Guile in Xapian bindings [1] but NotDeft [2] have some > Emacs Lisp code to interact with Xapian There is some work. IMHO. If Guix goes to Xapian, all the Git history of all the packages should be indexed. Today, it is really hard to find the right commit corresponding to the right version -- the only solution I have is "git log"+grep; not really friendly. Some discussion spoke about using an external index, fetched for example on the Guix Data Service. But I personally do not like to rely on external service accessible through the network. However, note that index all the packages of all the Guix history using guile-git+fold-packages is not straightforward: resource consuming and piece of well-thought data structures. Well, now "guix time-machine" is here, Guix is lacking tools to browse the history of all the packages. Cheers, simon