Skip to main content

GenetiNav — navigational genomics toolkit

Project description

A terminal-based genomics toolkit for gene lookup, DNA sequence exploration, and genomic coordinate navigation. Built with Textual and Typer, powered by the public Ensembl REST API.

Type a gene symbol to retrieve its metadata, then drop into a colour-coded, scrollable sequence viewer with motif search, reverse-complement display, and live gene-boundary detection — all from your terminal.

Features

  • Gene lookup – resolve gene symbols via the Ensembl REST API (human, mouse, rat, zebrafish)
  • Interactive sequence viewer – scrollable, colour-coded nucleotide track with coordinate ruler, GC-content sparkline, minimap, and stats footer
  • Rich navigation – base-by-base and page-by-page scrolling, jump-to-coordinate or gene, motif search with next/prev match, zoom, and back/forward history
  • Reverse-complement toggle – flip the display in place without losing position
  • Dynamic gene-boundary detection – the viewer automatically relabels itself as you scroll across gene/intergenic boundaries
  • Search history – automatically recorded, capped at 200 entries, browsable and re-openable
  • Favourites – bookmark genes for quick future access
  • Theming – 10 built-in dark colour themes, each with its own DNA base-colour palette
  • Local caching – SQLite-backed response cache plus an in-memory chunked sequence cache with background prefetching
  • Export – Markdown, JSON, or FASTA (genomic / transcript / CDS) export of the current gene
  • Open in Ensembl – jump straight to the gene’s Ensembl page in your browser
  • Command palette – fuzzy-filterable command search, global and viewer-aware
  • Performance mode – disable animations for a snappier or headless-friendly session
  • Configurable – all preferences stored in ~/.genetinav/settings.json

Installation

GenetiNav requires Python 3.10+.

Install from PyPI using pip:

pip install genetinav

If you prefer an isolated, globally available installation, use pipx:

pipx install genetinav

After installation, the genetinav command will be available in your terminal.

Usage

Launch the interactive TUI:

genetinav

Opens the home screen with a search bar. Type a gene symbol and press Enter, or use a /command to navigate directly.

Quick gene lookup:

genetinav BRCA1
genetinav brca2

Performs an immediate lookup inside the TUI.

Subcommands

Command Description
genetinav search <GENE> Launch the TUI and look up <GENE>
genetinav settings Open the Settings screen directly

Flags

Flag Description
--version Print the version string and exit
--no-animation Disable animations / enable performance mode
--theme <NAME> Override the active colour theme for this session
--species <NAME> Override the default species for this session
--clear-cache Clear the local gene/sequence response cache and exit
--clear-history Clear the search history and exit
# Quick lookup with a specific theme
genetinav BRCA1 --theme midnight_genome

# Disable animations and set default species to mouse
genetinav --no-animation --species mouse

# Clear cached data
genetinav --clear-cache
genetinav --clear-history

In-app navigation

From the home screen, type a gene symbol or a slash command:

Command Action
/settings Open Settings
/help Show keybinding reference
/about About GenetiNav (and license)
/history View search history
/recent View search history
/favorites View saved favourites
/themes List available colour themes
/theme Prompt to switch active theme

Result screen keys

Key Action
o Open the sequence viewer
v Toggle favourite
c Show / copy genomic coordinates
n Start a new search
m Open the menu (Export, Open in Ensembl)
q / Esc Back to home

Sequence viewer keys

Key Action
/ Scroll 1 base pair
/ , PgUp / PgDn Scroll one full window
Home / End Jump to sequence start / end
g Go to a coordinate (e.g. chr9:5057799) or gene
/ Search for a DNA motif
n / N Next / previous match
c Toggle reverse-complement display
Ctrl+G Toggle the GC-content track
< / > Navigate back / forward in viewer history
+ / - Zoom window size in / out
Ctrl+P Open the command palette
q / Esc Close the viewer

Export Formats

From the result screen menu (m → Export):

Format Filename Contents
Markdown {SYMBOL}_export.md Symbol, species, location, summary
JSON {SYMBOL}_export.json Full GeneRecord dump
FASTA – Genomic {SYMBOL}_genomic_{timestamp}.fasta The gene’s chromosomal region
FASTA – Transcript {SYMBOL}_transcript_{timestamp}.fasta Canonical transcript cDNA
FASTA – CDS {SYMBOL}_cds_{timestamp}.fasta Canonical CDS (falls back to cDNA)

Configuration

Settings are stored in ~/.genetinav/settings.json and can be edited through the in-app Settings screen (/settings) or directly. The local database lives at ~/.genetinav/genetinav.db.

Setting Default Description
theme obsidian_helix Active colour theme
history_enabled true Record search history
cache_enabled true Cache Ensembl API responses locally
default_window_size 60 Sequence viewer window size (bases)
default_species human Default species for lookups
ruler_interval 10 Spacing between ruler tick labels

Available Themes

Ten dark, biologically-themed palettes, each defining both the UI chrome and the DNA base colours used by the sequence viewer:

  • obsidian_helix
  • midnight_genome
  • carbon_strand
  • void_polymer
  • deep_cell
  • nucleic_night
  • graphene_dark
  • helix_abyss
  • synthetic_strand
  • black_helix_neon

List them at any time with /themes, or switch instantly with /theme.

Data Source

Gene metadata and sequence data are retrieved from the Ensembl REST API (https://rest.ensembl.org/) using public, unauthenticated endpoints. GenetiNav is not affiliated with Ensembl.

Screenshots

Add screenshots or terminal recordings of GenetiNav below.

Home Screen Result Screen Sequence Viewer
Home screen placeholder Result screen placeholder Sequence viewer placeholder

Technologies

Library Purpose
Textual Terminal UI framework (screens, widgets, event loop)
Typer CLI argument parsing and subcommands
httpx HTTP client for the Ensembl REST API
SQLite Local persistence for cache, history, and favourites

Roadmap

Potential future directions, not yet implemented:

  • Wire up reserved settings (high contrast, monochrome, animation toggles) to live Settings controls
  • Persist CLI --theme / --species overrides back to settings.json
  • Automatic retry/backoff for Ensembl API rate limiting and transient network errors
  • Configurable export destination directory
  • Disk-persisted sequence and overlap caches for faster cold starts
  • Broader species support beyond human, mouse, rat, and zebrafish

License

Custom Source-Available License 1.0 – Copyright © 2026 BIOWESS. You may view, clone, run, and modify this software for personal or educational use, and share non-commercial educational derivatives with attribution. Commercial use, resale, rebranding, or hosting as a paid service is not permitted without prior written permission. See LICENSE for the full terms.

Credits & Acknowledgements

Gene and sequence data courtesy of the Ensembl project. Built with Textual and Typer by Textualize. Nucleotide colour convention inspired by IGV and the UCSC Genome Browser.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

genetinav-0.1.0.tar.gz (51.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

genetinav-0.1.0-py3-none-any.whl (72.4 kB view details)

Uploaded Python 3

File details

Details for the file genetinav-0.1.0.tar.gz.

File metadata

  • Download URL: genetinav-0.1.0.tar.gz
  • Upload date:
  • Size: 51.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for genetinav-0.1.0.tar.gz
Algorithm Hash digest
SHA256 32a76a488b97c1d9d25c1e2c86dca5ac8f1917630e8c90ef220cc52d840765ed
MD5 7fb6cb467704fc3d2278e51122cfd1f2
BLAKE2b-256 eeb66b95b3108dff2cf5ec7008fa5cf14785e341219a628e513e3a19d75c22ca

See more details on using hashes here.

File details

Details for the file genetinav-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: genetinav-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 72.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for genetinav-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d15283ec63de4a75cd33ac6c946c585d6d06ba07181051b67b6bd712496ce9e9
MD5 366a6812cc2623c149e4202d8fc9cb6f
BLAKE2b-256 a45cdec5dd3a2e39e1bfa90f3ad966b9787550fd63aff72cfa56c7f4825b8266

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page