Difference between revisions of "Applications and libraries"

From HaskellWiki
Jump to navigation Jump to search
(136 intermediate revisions by 33 users not shown)
Line 1: Line 1:
  +
[[Category:Libraries]] [[Category:Tools]]
{{unknown copyright}}
 
   
  +
The number of Haskell packages is growing rapidly. The section 'Haskell library collections' gives an ordering of all these packages by relative importance. In the section 'Haskell applications and libraries' an ordering by category is given. Finally some guidelines for developers of new packages are presented.
'''This page is being restructured, if possible refrain from editing it today. If you want to add something send an e-mail to bringert@cs.chalmers.se''' -- BjornBringert, 2006-03-22
 
   
  +
== Haskell library collections ==
The first place to look for data types or functions that do what you
 
want is the Standard Prelude, then the
 
[[Language and library specification]] (both parts of
 
the Haskell standards documentation), then in whatever extra libraries
 
are provided by the Haskell implementation you are using, then on the
 
page you are looking at. If it is not here, then it may be in the
 
[http://www.cse.unsw.edu.au/~dons/announce.html archives] of the
 
[[Haskell Weekly News]].
 
   
  +
=== Haskell Prelude ===
Search the standard libraries collection (by name or type signature)
 
  +
The most important Haskell library is called the [http://www.haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html Prelude]. It is implicitly imported by default, and includes the most commonly used functions. Make sure you know what they do and how to use them effectively.
using [http://haskell.org/hoogle Hoogle].
 
   
  +
=== The Haskell 2010 libraries ===
__TOC__
 
  +
The Haskell 2010 [[Language and library specification]] defines a set of [http://www.haskell.org/onlinereport/haskell2010/haskellpa2.html libraries] with basic functionality which all Haskell implementations should support, including the Prelude. Changes to these libraries are handled by the [http://hackage.haskell.org/trac/haskell-prime/ Haskell'] process.
   
  +
Haskell modules that almost everybody uses are in this group, for example:
There is an effort underway to standardise many of the extra libraries that come with Haskell implementations, and at the same time extend the module namespace into a hierarchy. A document describing this project can be found [http://www.haskell.org/~simonmar/libraries/libraries.html here], and there is a [http://www.haskell.org/mailman/listinfo/libraries mailing list] for discussing issues related to libraries.
 
  +
[http://www.haskell.org/onlinereport/haskell2010/haskellch13.html Control.Monad], [http://www.haskell.org/onlinereport/haskell2010/haskellch20.html Data.List]
  +
and [http://www.haskell.org/onlinereport/haskell2010/haskellch41.html System.IO]. Within GHC, these are mostly grouped into the [http://hackage.haskell.org/package/base base] package, but for example [http://www.haskell.org/onlinereport/haskell2010/haskellch14.html Data.Array] is the [http://hackage.haskell.org/package/array array] package.
   
  +
=== The GHC standard libraries ===
A large collection of [http://www.haskell.org/ghc/docs/latest/html/libraries/index.html standard hierarchical libraries] are currently distributed with GHC (from version 5.04), Hugs (from Nov 2003), and nhc98 (from 1.16).
 
  +
GHC comes with an expanded version of the Haskell 2010 libraries. Together these are called the [http://www.haskell.org/ghc/docs/latest/html/libraries/index.html GHC standard libraries]. Changes to these libraries are handled by the package maintainer if one exists, or the [[Library submissions]] process if not. [http://www.haskell.org/hoogle/ Hoogle] - the Haskell API Search Engine - indexes the [http://www.haskell.org/ghc/docs/latest/html/libraries/index.html GHC standard libraries].
   
  +
Examples of libraries, or packages, that belong to this group are:
[[Cabal]], The Common Architecture for Building Applications and Libraries, is an framework for packaging, building, and installing any tool developed in the Haskell language.
 
  +
[http://hackage.haskell.org/package/bytestring bytestring],
  +
[http://hackage.haskell.org/package/containers containers] and [http://hackage.haskell.org/package/Win32 Win32].
   
  +
=== Haskell Platform libraries ===
This page is intended as a comprehensive list of all Haskell libraries and tools. Some of these are proof-of-concepts rather than production code. Some have no longer been maintained for a long time.
 
  +
On top of the GHC standard libraries, the [http://www.haskell.org/platform/ Haskell Platform] comes preinstalled with some additional packages that together form the [http://www.haskell.org/platform/contents.html#packages-and-documentation Haskell Platform libraries]. These libraries have been thoroughly tested before being included. The addition of these libraries with the [http://www.haskell.org/platform/ Haskell Platform] is what makes it 'batteries included'.
   
  +
Examples of included packages are: [http://hackage.haskell.org/package/mtl Monad transformer library], [http://hackage.haskell.org/package/parallel parallel] and [http://hackage.haskell.org/package/QuickCheck QuickCheck].
On freshmeat.com there is [http://freshmeat.net/browse/834/?topic_id=834 an alternative list of public domain software written in Haskell]. That list is currently short (for you to change that), but in particular it displays the current development status of the software. Even more Haskell projects are documented in the [http://haskell.org/communities/ community reports] and in the archives of the [[Haskell Weekly News]].
 
   
  +
=== The Hackage database ===
== Program Development ==
 
  +
[http://hackage.haskell.org/packages/archive/pkg-list.html Hackage] is the final layer of the Haskell library collections. [http://hackage.haskell.org/packages/archive/pkg-list.html Hackage] aims to provide a comprehensive collection of released Haskell packages, similar to Perl's CPAN or Python's PyPI.
   
  +
Start on [http://hackage.haskell.org/packages/archive/pkg-list.html Hackage] if you are looking for some functionality that did not come preinstalled with the [http://www.haskell.org/platform/ Haskell Platform].
See [[ProgramDevelopment]].
 
   
  +
See also the [[Hackage|Hackage wiki page]] and [[Cabal/How to install a Cabal package | how to install a Cabal package]].
== Data structures ==
 
   
  +
== Haskell applications and libraries ==
See [[DataStructures]].
 
   
  +
Applications, libraries and tools for Haskell or written in Haskell have been classified below, but you should check [http://hackage.haskell.org/packages/archive/pkg-list.html Hackage] for the latest list.
== Extended Haskell ==
 
   
  +
* [[/Music and sound/|Audio, music and sound]]
See [[ExtendedHaskell]].
 
  +
* [[/Bioinformatics/]]
  +
* [[/Concurrency and parallelism/]]
  +
* [[/Compilers and interpreters/]]
  +
* [[/Compiler tools|Compiler construction, lexing, parsing, pretty printing]]
  +
* [[/Cryptography|Cryptography and hashing]]
  +
* [[/Data structures | Data Structures and IO Libraries]]
  +
* [[/Database interfaces/]]
  +
* [[/Editors|Editors written in Haskell]] and [[Editors|editors for Haskell]].
  +
* [[/Extended Haskell/]]
  +
* [[/Games/]]
  +
* [[/Generic programming/]]
  +
* [[/GUI libraries|Graphical User Interface (GUI) Libraries]]
  +
* [[/Graphics/]]
  +
* [[/Hardware verification/]]
  +
* [[/Linguistics|Linguistics and natural language processing]]
  +
* [[/Mathematics/|Mathematics and physics]]
  +
* [[/Network/]]
  +
* [[/Operating system/|Operating systems and systems programming]] (also emulators)
  +
* [[/Program development/]]
  +
* [[/Robotics/]]
  +
* [[/Theorem provers/]]
  +
* [[/Interfacing other languages|Tools for interfacing with other languages]]
  +
* [[Web|Web, HTML, XML]]
   
  +
Other places to look include:
== Interfacing with other languages and systems ==
 
  +
* The [[Library]] hierarchy page on this wiki.
  +
* The Haskell [[Haskell Communities and Activities Report|community reports]].
  +
* The [http://www.haskell.org/mailman/listinfo/libraries mailing list] for discussion of issues related to libraries.
   
  +
You can also [http://www.reddit.com/r/haskell_proposals/top/?t=month propose and vote on new libraries] that you'd like on [http://www.reddit.com/r/haskell reddit], and look at our past [http://hackage.haskell.org/trac/summer-of-code/ Summer of Code proposals].
=== Web services and Remote Procedure Call libraries ===
 
   
  +
== Guidelines for developers ==
See [[RPC]].
 
   
  +
[[Image:Cabal-With-Text-small.png|frame|Built with Cabal]]
=== Tools for interfacing with other languages ===
 
   
  +
Developer guides:
See [[InterfacingOtherLanguages]].
 
   
  +
* [[How to write a Haskell program|How to write a new Haskell library]]
== Databases ==
 
  +
* [[Library submissions|How to propose changes to the standard libraries]]
  +
* [http://web.archive.org/web/20071011215053/http://pupeno.com/2006/12/12/the-lambda-revolution-v/ Creating a .deb from a Haskell Cabal package] (in the Web Archive)
  +
* Guide to making standard [[Library submissions|library submissions]]
  +
* If you notice the library documentation is lacking, or could be improved, [http://www.haskell.org/haskellwiki/Improving_library_documentation please report it here]
  +
* [http://www.google.com/codesearch Google Code Search] can help identify common idioms, improving your API.
  +
* [[Future projects]], more projects people would like.
  +
* [[Cabal]], The Common Architecture for Building Applications and Libraries, is a framework for packaging, building, and installing any tool developed in the Haskell language.
  +
* [[Hack-Nix]], a set of tools based on the [http://nixos.org Nix] package manager to manage multiple setups to build a project
   
  +
Proposals for the module name space layout that can be used to guide the construction of new libraries.
See [[DatabaseInterfaces]].
 
   
  +
* [[Hierarchical module names|Almost current guide]]
== Graphical User Interface Libraries ==
 
  +
* [http://www.cs.york.ac.uk/fp/libraries/layout.html Proposal 1]
  +
* [http://www.cs.york.ac.uk/fp/libraries/layoutSM.html Proposal 2]
   
  +
=== Libraries for other languages ===
See [[GUILibraries]].
 
   
  +
If you are thinking about designing a new library for Haskell, you ought to look what has been done in other languages. Here are standard library definitions for
== Graphics ==
 
   
  +
* [http://wiki.clean.cs.ru.nl/Libraries Clean]
See [[Graphics]].
 
  +
* [http://www.standardml.org/Basis/ Standard ML]
 
  +
* [http://caml.inria.fr/pub/docs/manual-ocaml/manual034.html Objective Caml]
== Web, HTML, XML ==
 
  +
* [http://srfi.schemers.org/ Scheme]
 
See [[WebProgramming]]. For web services, see [[RPC]].
 
 
== Pretty-printer libraries ==
 
 
See [[PrettyPrinting]].
 
 
== Compiler, parsing and lexing tools ==
 
 
See [[CompilerTools]].
 
 
== Music ==
 
 
See [[Music]].
 
 
== Numerical algorithms and mathematics ==
 
 
See [[MathematicsLibraries]].
 
 
== Hardware verification ==
 
 
See [[HardwareVerification]].
 
 
== Robots ==
 
 
See [[Robots]].
 
 
== Genetic programming ==
 
 
See [[GeneticProgramming]].
 
 
== Natural language processing ==
 
 
See [[Linguistics]].
 
 
== Various ==
 
 
<dl>
 
<dt>[http://www.cse.unsw.edu.au/~dons/hs-plugins/ hs-plugins]
 
<dd>A library for compiling and loading plugins into a running Haskell program.</dd>
 
<dt>[http://www.volker-wysk.de/hsshellscript HsShellScript]</dt>
 
<dd>A library for using Haskell for tasks which are usually done by shell scripts, e.g. command line parsing, analysing paths, etc.</dd>
 
 
<dt>[http://www-i2.informatik.rwth-aachen.de/~michaelw/hmpi.html hMPI]</dt>
 
 
<dd>hMPI is an acronym for HaskellMPI. It is a Haskell binding
 
conforming to MPI (Message Passing Interface) standard 1.1/1.2. The
 
programmer is in full control over the communication between the
 
nodes of a cluster.</dd>
 
 
<dt>[http://web.archive.org/web/*/http://www.numeric-quest.com/haskell/smartest.html Smarty]<em>(since 10/06/2003: via Internet Archive)</em></dt>
 
 
<dd>The world's smartest i/o device for Haskell. An interface
 
between Haskell and Squeak, a freely available Smalltalk language
 
and environment.</dd>
 
 
<dt>[http://www.haskell.org/~petersen/haskell/popenhs/ popenhs]</dt>
 
 
<dd>A small library, based on runProcess in the standardised posix library.
 
It provides lazy output from subprocesses.</dd>
 
 
<dt>[http://www2-data.informatik.unibw-muenchen.de/EdComb/ EdComb]
 
<dd>Editor combinators allow to assemble structure editors compositionally instead of generating them from descriptions, just
 
as parsing combinators allow to assemble parsers compositionally instead of employing parser generators to generate
 
parsers from grammar descriptions.
 
<dt>[http://ls5-www.cs.uni-dortmund.de/~peter/Expander2/Expander2.html Expander2]</dt>
 
<dd>Expander2 is a flexible multi-purpose workbench for rewriting, verification,
 
constraint solving, flow graph analysis and related procedures that
 
build up proofs or computation sequences. Moreover, tailor-made
 
interpreters display terms as 2D structures ranging from trees and
 
rooted graphs to tables, fractals and
 
other turtle-system-generated pictures.</dd>
 
 
<dt>[http://www.cs.vu.nl/Strafunski/ Strafunski]</dt>
 
 
<dd>Strafunski is a Haskell bundle that provides support for
 
generic programming in Haskell, based on the concept of a
 
functional strategy. It consists of a combinator library
 
(StrategyLib) and a precompiler (DrIFT-Strafunski).</dd>
 
 
<dt>[http://www.cin.ufpe.br/~haskell/fungen FunGEn - a game engine for Haskell]</dt>
 
 
<dd>FunGEn (Functional Game Engine) is a 2D platform-independent
 
game engine implemented in and for Haskell, using HOpenGL. It is
 
intended to help game programmers in the game development process,
 
in a faster and automated way.</dd>
 
 
<dt>[http://www.haskell.org/crypto The Haskell Cryptographic Library]</dt>
 
 
<dd>A library of cryptographic functions collected together in one package.</dd>
 
 
<dt>[http://www.cif.rochester.edu/~sankeld/RSA/ RSA]</dt>
 
 
<dd>A number theory library, RSA library, and RSA programs.</dd>
 
 
<dt>[http://web.comlab.ox.ac.uk/oucl/work/ian.lynagh/ Implementations of MD5, SHA1 and DES]</dt>
 
 
<dt>[http://www.dcs.gla.ac.uk/~meurig/regexp/ Regular expression library]</dt>
 
 
<dd>Inspired by the Perl regular expression library, written purely
 
in Haskell. Also part of the GHC distribution.</dd>
 
 
<dt>[http://www.cl.cam.ac.uk/users/kw217/libs/ Partial v0.1]</dt>
 
 
<dd>The Partial library provides a partial order class. It also
 
provides routines for generating a Hasse diagram from a set and a
 
partial order. Renderers are provided for the abstract Hasse
 
diagram representation into LaTeX (via Xy-pic) and into dot, the
 
format for AT&amp;T's Graphviz tools. Since no horizontal sorting
 
is done, the Xy-pic output is rather poor at present; dot does a
 
much better job with its layout optimisation algorithm.</dd>
 
 
<dt>[http://web.archive.org/web/*/http://www.numeric-quest.com/funpdf/ fun-&gt;pdf]<em>(since 10/06/2003: via Internet Archive)</em></dt>
 
 
<dd>An implementation of a PDF dynamic writer in Haskell.</dd>
 
 
<dt>[http://www.pms.informatik.uni-muenchen.de/mitarbeiter/panne/haskell_libs/GetOpt.html GetOpt]</dt>
 
 
<dd>A module for GNU-/POSIX-like option handling of commandline
 
arguments</dd>
 
</dl>
 
 
== Collections of libraries ==
 
 
* [http://www.cs.york.ac.uk/fp/software.html Software available from the York FP group]
 
* [http://repetae.net/john/computer/haskell/ John Meacham's Haskell tools and libraries]
 
* [http://www.cit.gu.edu.au/~arock/haskell/index.html Andrew Rock's library of useful modules]
 
* [http://www.informatik.uni-bonn.de/~ralf/software.html Libraries by Ralf Hinze] for data structures, sorting, searching, parsing, pretty printing, numerical algorithms, monads, etc.
 
* [http://web.archive.org/web/*/http://www.numeric-quest.com/haskell/index.html Collection of Haskell modules] ''(since 10/06/2003: via Internet Archive)'' by Jan Skibinski, Numeric Quest Inc.
 
* [http://www.pms.informatik.uni-muenchen.de/mitarbeiter/panne/haskell_libs/ Sven's Haskell Libaries] for interfacing to DaVinci, HTML/Cgi, OpenGL; a module for option handling, a Haskell parser, a binary library.
 
* [http://web.comlab.ox.ac.uk/oucl/work/ian.lynagh/ Ian Lynagh's Haskell libraries]
 
* [http://www.reid-consulting-uk.ltd.uk/projects/index.html Reid Consulting's Libraries and Programs] CMI, TSL, Knit, Greencard, HGL, HSX11, HSWin32
 
 
== Libraries for other languages ==
 
If you are thinking about designing a new library for Haskell, you
 
ought to look what has been done in other languages. Here are
 
standard library definitions for
 
 
<ul>
 
<li>[http://srfi.schemers.org/ Scheme]</li>
 
 
<li>[http://cm.bell-labs.com/cm/cs/what/smlnj/doc/basis/index.html ML]</li>
 
</ul>
 

Revision as of 13:04, 27 June 2014


The number of Haskell packages is growing rapidly. The section 'Haskell library collections' gives an ordering of all these packages by relative importance. In the section 'Haskell applications and libraries' an ordering by category is given. Finally some guidelines for developers of new packages are presented.

Haskell library collections

Haskell Prelude

The most important Haskell library is called the Prelude. It is implicitly imported by default, and includes the most commonly used functions. Make sure you know what they do and how to use them effectively.

The Haskell 2010 libraries

The Haskell 2010 Language and library specification defines a set of libraries with basic functionality which all Haskell implementations should support, including the Prelude. Changes to these libraries are handled by the Haskell' process.

Haskell modules that almost everybody uses are in this group, for example: Control.Monad, Data.List and System.IO. Within GHC, these are mostly grouped into the base package, but for example Data.Array is the array package.

The GHC standard libraries

GHC comes with an expanded version of the Haskell 2010 libraries. Together these are called the GHC standard libraries. Changes to these libraries are handled by the package maintainer if one exists, or the Library submissions process if not. Hoogle - the Haskell API Search Engine - indexes the GHC standard libraries.

Examples of libraries, or packages, that belong to this group are: bytestring, containers and Win32.

Haskell Platform libraries

On top of the GHC standard libraries, the Haskell Platform comes preinstalled with some additional packages that together form the Haskell Platform libraries. These libraries have been thoroughly tested before being included. The addition of these libraries with the Haskell Platform is what makes it 'batteries included'.

Examples of included packages are: Monad transformer library, parallel and QuickCheck.

The Hackage database

Hackage is the final layer of the Haskell library collections. Hackage aims to provide a comprehensive collection of released Haskell packages, similar to Perl's CPAN or Python's PyPI.

Start on Hackage if you are looking for some functionality that did not come preinstalled with the Haskell Platform.

See also the Hackage wiki page and how to install a Cabal package.

Haskell applications and libraries

Applications, libraries and tools for Haskell or written in Haskell have been classified below, but you should check Hackage for the latest list.

Other places to look include:

You can also propose and vote on new libraries that you'd like on reddit, and look at our past Summer of Code proposals.

Guidelines for developers

Built with Cabal

Developer guides:

Proposals for the module name space layout that can be used to guide the construction of new libraries.

Libraries for other languages

If you are thinking about designing a new library for Haskell, you ought to look what has been done in other languages. Here are standard library definitions for