Skip to content

About

In-browser tools for bacterial genome analysis 🦅

Resources

Stars

14 stars

Watchers

3 watching

Forks

Repository files navigation

sparrowhawk

Access Sparrowhawk at https://sparrowhawk.bacpop.org

Sparrowhawk is a WebAssembly toolkit for analysis of bacterial genomes including:

Documentation

Docs, including a development guide for WebAssembly methods, are here: https://sparrowhawk-docs.bacpop.org .

WebAssembly?

  • Easy: WebAssembly (WASM) runs directly in your browser, so no installation is needed.
  • Private: Everything is processed locally, on your own machine, so no data is transferred to external servers.
  • Fast: All code is optimised for rapid analysis, and some modules even support using your local GPU for increased speed.
  • Up-to-date: Our packages build both native and WASM code, so the latest features and updates continue to be included.

For larger analyses, some browsers (Chrome, Safari, Edge) are faster than others.

Sparrowhawk?

Sparrowhawk was at one time the Archmage of Earthsea. Also, the sparrowhawk (Accipiter nisus) is a bird of prey native to Europe (and the island of Gont).

For fans and haters of backronyms: Speedy Private ARchitecture Running On-device WHich Analyses With K-mers

Contributors

Citation

Sparrohawk's preprint is published on bioRxiv (2026.11.18.767565). You may use the following bibtex entry:

@article{rodriguez-bouza2026sparrowhawk,
        author    = {Rodr{\'\i}guez-Bouza, V{\'\i}ctor and von Wachsmann, Johanna H. and Constantinides, Bede and Andr{\'e}oletti, Antoine and Odih, Erkison E. and Nesterenko, Luca and Gupta, Vikas and Lees, John A.},
        title     = {{Sparrowhawk}: harnessing {WebAssembly} for private microbial genomics, and beyond},
        journal   = {bioRxiv},
        year      = {2026},
        month     = nov,
        eid       = {2026.11.18.767565},
        doi       = {10.64898/2026.11.18.767565},
        url       = {https://www.biorxiv.org/content/10.64898/2026.11.18.767565v1},
        publisher = {Cold Spring Harbor Laboratory},
        note      = {Preprint}
}

Desktop program

Sparrowhawk can also be run as a desktop program, with the same tools as the website. Each release has, under "Assets":

  • GNU/Linux (x86_64): an AppImage. Make it executable (chmod +x Sparrowhawk-*.AppImage) and run it.
  • Windows (x86_64): an installer (.exe).
  • macOS (Apple silicon): a disk image (.dmg). Open it and drag Sparrowhawk to Applications.

The programs are not signed, so your system will warn you the first time you open them:

  • Windows: on the SmartScreen warning, click "More info" and then "Run anyway".
  • macOS: allow it in System Settings → Privacy & Security, or run xattr -cr /Applications/Sparrowhawk.app in a terminal.





Disclaimer ⚠️ 🚧

This is a work in progress project. This in particular implies:

  • Not all the main features we want are yet implemented.
  • Code might be messy, and not even documented.
  • General documentation on how to install and use the tool might be short or even missing.
  • Finding unexpected errors/behaviour or bugs should not be a surprise.
  • Some features might be partially hardcoded.

These (and potentially other) items will be progressively fixed before version 1.0.

Developers (developers, developers, developers)

I want to create something similar to this with my method, what do I do?

We have created a guide that details an example on how would such a method be created. Additionally, we have prepared a SKILLS.md and a AGENTS.md in the case you want to draft or outline such a project with the help of LLMs. Point them to the SKILLS.md file, that is designed to guide them developing both the interface of your method to the web part, and the web itself. We have improved this file by doing two exercises manually. We have adapted the nice bioinformatics read mapping crate rammap-rs to an Sparrowhawk analogous web in rammap-web. Additionally, and to show the applicability on other scientific fields, we have done a small port of the Combine toolkit, in C++ and Python, to Rust, and taking advantage of the Rust port of Minuit2 of minuit2-rs, and a slightly extended oxyroot-rs, we created combine-web using Sparrowhawk as scaffold.

Installation

Development has been done only on x86_64 GNU/Linux-based systems, and most surely will probably stay that way, although different systems have been explored with its usage via the website. To use it you will need to have NPM installed, as well as a working Rust installation (check the official Rust website for information on how to get it) and then download and install the required packages as follows (for example, to get the vX.Y.Z version)

git clone --branch vX.Y.Z --recurse-submodules https://github.com/bacpop/sparrowhawk.git
cd sparrowhawk/www
npm install

Note for macOS enjoyers

It has been found that there is an issue when compiling some crates to wasm32-unknown-unknown in macOS due to the weird clang packaging there. Following this issue, it seems that installing llvm fixes it.

Usage

Once you have it installed, you can run the following, that will automatically compile to WebAssembly sparrowhawk-asm and run the development server locally (from the www folder!):

npm run serve

Customize configuration

See Configuration Reference.

About

In-browser tools for bacterial genome analysis 🦅

Resources

Stars

14 stars

Watchers

3 watching

Forks

Releases

Contributors

Languages