Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: "Frédéric Bour" <frederic.bour@lakaban.net>
To: caml-list@inria.fr
Subject: Re: [Caml-list] where are we on the Hoogle for OCaml front?
Date: Mon, 6 Feb 2017 16:55:47 +0000	[thread overview]
Message-ID: <83522776-37b5-754b-aa01-f05e6af8f56f@lakaban.net> (raw)
In-Reply-To: <CALdWJ+wTfo5yG4jxvNgewMmyjL-GvzqtwtNz5H4P3=NEKb6M1g@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2453 bytes --]

The experimental version of Merlin implements a similar feature (however 
it looks only in loaded packages, not the whole opam universe).

It is based on names (normalizing type constructors to resolve aliases), 
and uses variance information (types occurring in positive and negative 
positions) to guide the search.

The prototype query language looks like "-int +string" for "string of 
int". You can see a demo here: 
http://alfred.lakaban.net/~def/polarity.webm .


On 06/02/2017 16:46, Ivan Gotovchits wrote:
> Well yes, the theory is not required, but it is better to know one :) 
> I provided a link mostly because it is a sort of a homepage for 
> type-isomorphic search. There are links to the CamlLight 
> implementations (yeah the idea was there for some time) and Haskel. 
> Speaking of modern implementations, Argot [1] is the only example that 
> comes to mind. It has the isomorphic search and a type manifest 
> search. The search is implemented mostly in Javascript (generated from 
> OCaml). (Probably, you heard the story that it is broken and 
> abandoned, and yadda yadda...)
>
> The digest of the theory, is that we have the following rules:
>
> 1. a -> b -> c ~ b -> a -> c
> 2. a * b -> c ~ a -> b -> c
> 3. unit -> a ~ a
>
> And by applying these rules recursively we can build a set of types 
> that are isomorphic to the query (or partition all the types into the 
> isomoprhism groups).
>
>
> [1]: http://ocaml.github.io/platform-dev/packages/argot/
>
>
>
> On Mon, Feb 6, 2017 at 11:34 AM, Daniel Bünzli 
> <daniel.buenzli@erratique.ch <mailto:daniel.buenzli@erratique.ch>> wrote:
>
>     On Monday, 6 February 2017 at 17:07, Ivan Gotovchits wrote:
>     > That's why the search should be up-to some isomorphism, e.g.,
>     >
>     > int -> float -> bool
>     >
>     >
>     > is isomoprhic to
>     >
>     > float -> int -> bool
>
>     The papers you mention seem to be about the type ismorophism
>     theory but I can't see any that tries to asses end-user
>     information needs and retrieval evaluation. I'm not sure you need
>     the full theory to build an effective system to support a
>     programmer, e.g. what about the effectiveness of a full type
>     isomorphism search vs a bag of type identifiers with functional
>     position model. Meaningfully limiting the query power to an IR
>     system is a problem in practice, for space, computational and user
>     interface reasons.
>
>     D
>
>
>


[-- Attachment #2: Type: text/html, Size: 4359 bytes --]

  reply	other threads:[~2017-02-06 16:55 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-27 14:22 [Caml-list] FroCoS 2017 - 2nd Call for Papers Geoff Sutcliffe
2017-01-27 16:39 ` [Caml-list] where are we on the Hoogle for OCaml front? Francois BERENGER
2017-02-04  3:58   ` Jacques Garrigue
2017-02-06 14:35     ` Francois BERENGER
2017-02-06 15:46     ` Daniel Bünzli
2017-02-06 14:02       ` Hendrik Boom
2017-02-06 16:00         ` Daniel Bünzli
2017-02-06 16:07           ` Ivan Gotovchits
2017-02-06 16:11             ` Ivan Gotovchits
2017-02-06 16:34             ` Daniel Bünzli
2017-02-06 16:46               ` Ivan Gotovchits
2017-02-06 16:55                 ` Frédéric Bour [this message]
2017-02-06 16:01         ` Ivan Gotovchits
2017-02-06 16:06           ` Daniel Bünzli
2017-02-06 17:46       ` Francois BERENGER

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83522776-37b5-754b-aa01-f05e6af8f56f@lakaban.net \
    --to=frederic.bour@lakaban.net \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox