https://github.com/gosling-lang/altgosling
Automatic generation of textual description for Gosling visualization
https://github.com/gosling-lang/altgosling
hidivelab
Last synced: 5 months ago
JSON representation
Automatic generation of textual description for Gosling visualization
- Host: GitHub
- URL: https://github.com/gosling-lang/altgosling
- Owner: gosling-lang
- License: mit
- Created: 2023-10-04T12:45:36.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2025-07-24T14:05:03.000Z (11 months ago)
- Last Synced: 2025-10-30T04:26:28.910Z (7 months ago)
- Topics: hidivelab
- Language: TypeScript
- Homepage:
- Size: 70.4 MB
- Stars: 5
- Watchers: 1
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.md
Awesome Lists containing this project
README
# AltGosling
AltGosling is a library based on [Gosling](https://github.com/gosling-lang/gosling.js) that automatically extracts features and converts these into natural language to describe Gosling visualizations. You can read more on our [documentation website](https://gosling-lang.github.io/altgosling/docs/).
## Why AltGosling?
There is a large gap in accessibility, specifically for people with blindness and low vision (BLV), on the web. The Web Content Accessibility Guidelines ([WCAG](https://www.w3.org/WAI/standards-guidelines/wcag/)) require text descriptions for images. AltGosling creates text descriptions for genomic visualizations created with Gosling. In this way, interactive visualizations can be deployed on the web and automatically include text descriptions.
## Installation
AltGosling is available as an [NPM package](https://www.npmjs.com/package/altgosling).
Install it with your favorite package manager.
```bash
npm install altgosling
```
## Quick Start with React
The fastest way to get AltGosling running is shown below.
```ts
import React from 'react';
import gosling from 'gosling.js';
import { AltGoslingComponent } from 'altgosling';
function Demo() {
// example spec
const goslingSpec = {
"title": "Tonsil ChIP-seq in Th1 cells",
"tracks": [
{
"layout": "linear",
"width": 800,
"height": 180,
"data": {
"url": "https://resgen.io/api/v1/tileset_info/?d=UvVPeLHuRDiYA3qwFlm7xQ",
"type": "multivec",
"row": "sample",
"column": "position",
"value": "peak",
"categories": ["sample 1"],
"binSize": 5
},
"mark": "bar",
"x": {"field": "start", "type": "genomic", "axis": "bottom"},
"xe": {"field": "end", "type": "genomic"},
"y": {"field": "peak", "type": "quantitative", "axis": "right"},
"size": {"value": 5}
}
]
}
return (
<>
>
);
}
```
## Demo
A demo of AltGosling is available [here](https://gosling-lang.github.io/altgosling/).
All examples are available in [demo/examples](https://github.com/gosling-lang/altgosling/tree/master/demo/examples).
## Contributing to AltGosling
We welcome contributions to AltGosling! Please refer to the [contributing guidelines](CONTRIBUTING.md).
## Team
[HiDIVE Lab](https://hidivelab.org)
- Thomas C. Smits
- Sehi L'Yi
- Andrew P. Mar
- Nils Gehlenborg
Questions can be directed towards
## Cite
Our paper in _Bioinformatics_ is available [here](https://doi.org/10.1093/bioinformatics/btae670).
Please cite this work as follows:
```
Thomas C Smits, Sehi L’Yi, Andrew P Mar, Nils Gehlenborg (2024). AltGosling: Automatic Generation of Text Descriptions for Accessible Genomics Data Visualization, Bioinformatics 40(12), btae670. 10.1093/bioinformatics/btae670