Skip to content

Commit fd21491

Browse files
committed
Merge branch 'main' into recursive_subsections
2 parents 1e14d99 + 16dac66 commit fd21491

22 files changed

+1016
-122
lines changed

.github/workflows/cdci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Python package
1+
name: CICD Python Package
22

33
on:
44
push:
@@ -155,7 +155,7 @@ jobs:
155155
- name: Build executable
156156
run: |
157157
cd gui
158-
pyinstaller -n vuegen_gui --onefile --windowed --collect-all pyvis --collect-all streamlit --collect-all st_aggrid --collect-all customtkinter --collect-all quarto_cli --collect-all plotly --collect-all _plotly_utils --collect-all traitlets --collect-all referencing --collect-all rpds --collect-all tenacity --collect-all pyvis --collect-all pandas --collect-all numpy --collect-all matplotlib --collect-all openpyxl --collect-all xlrd --collect-all nbformat --collect-all nbclient --collect-all altair --collect-all itables --collect-all kaleido --collect-all pyarrow --collect-all dataframe_image --collect-all narwhals --collect-all PIL --collect-all vl_convert --add-data ../docs/example_data/Basic_example_vuegen_demo_notebook:example_data/Basic_example_vuegen_demo_notebook --add-data ../docs/images/vuegen_logo.png:. app.py
158+
pyinstaller -n vuegen_gui --onefile --windowed --collect-all pyvis --collect-all streamlit --collect-all st_aggrid --collect-all customtkinter --collect-all quarto_cli --collect-all plotly --collect-all _plotly_utils --collect-all traitlets --collect-all referencing --collect-all rpds --collect-all tenacity --collect-all pandas --collect-all numpy --collect-all matplotlib --collect-all openpyxl --collect-all xlrd --collect-all nbformat --collect-all nbclient --collect-all altair --collect-all itables --collect-all kaleido --collect-all pyarrow --collect-all dataframe_image --collect-all narwhals --collect-all PIL --collect-all vl_convert --collect-all typing-extensions --add-data ../docs/example_data/Basic_example_vuegen_demo_notebook:example_data/Basic_example_vuegen_demo_notebook --add-data ../docs/images/vuegen_logo.png:. app.py
159159
# --windowed only for mac, see:
160160
# https://pyinstaller.org/en/stable/usage.html#building-macos-app-bundles
161161
# 'Under macOS, PyInstaller always builds a UNIX executable in dist.'

.github/workflows/docs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Test documentation building, and publish report to GitHub Pages
1+
name: Docs and Report Examples
22

33
on:
44
push:
@@ -10,7 +10,7 @@ on:
1010

1111
jobs:
1212
test:
13-
name: Test
13+
name: Test docs and report examples
1414
runs-on: ubuntu-latest
1515
strategy:
1616
matrix:

CONTRIBUTING.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,17 @@ you to share any suggestions or observations you have about this project.
2727

2828
Here are the ways you can submit your suggestions and contribute to the project:
2929

30-
1. **Reporting Issues or Suggesting Improvements:** If you have a [GitHub][github] account
31-
(or are willing to [open one][github-join]) but are unfamiliar with Git, you can report
32-
bugs or suggest improvements by [creating an issue][new-issue]. This GitHub feature allows
33-
for discussion threads on reported issues and proposed enhancements.
30+
### 1. Reporting Issues or Suggesting Improvements
3431

35-
2. **Submitting Changes via Pull Requests:** If you are comfortable using Git and would like to
36-
add or modify a functionality, you can submit a **pull request (PR)**. Instructions on how to contribute this way are provided in the next section.
32+
If you have a [GitHub][github] account (or are willing to [open one][github-join]) but are unfamiliar with Git, you can report bugs or suggest improvements by [creating an issue][new-issue]. This GitHub feature allows for discussion threads on reported issues and proposed enhancements.
3733

38-
3. **Providing Feedback via Email:** If you don’t have a GitHub account and are
39-
unfamiliar with Git, you can send feedback via email to [[email protected]][contact]. However, using GitHub is preferred, as it allows us to respond more quickly and track discussions openly.
34+
### 2. Submitting Changes via Pull Requests
35+
36+
If you are comfortable using Git and would like to add or modify a functionality, you can submit a **pull request (PR)**. Instructions on how to contribute this way are provided in the next section.
37+
38+
### 3. Providing Feedback via Email
39+
40+
If you don’t have a GitHub account and are unfamiliar with Git, you can send feedback via email to [[email protected]][contact]. However, using GitHub is preferred, as it allows us to respond more quickly and track discussions openly.
4041

4142
> [!NOTE]
4243
> The documentation for [Git][git-docs] and [GitHub][github-docs] are easy to follow, and you can learn the basics using their official guides.

README.md

Lines changed: 34 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
| Information | Links |
88
| :-------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
99
| **Package** | [![PyPI Latest Release](https://img.shields.io/pypi/v/vuegen.svg)][vuegen-pypi] [![Conda Latest Release](https://img.shields.io/conda/v/bioconda/vuegen.svg)][vuegen-conda] [![Supported versions](https://img.shields.io/pypi/pyversions/vuegen.svg)][vuegen-pypi] [![Docker Repository on Quay](https://quay.io/repository/dtu_biosustain_dsp/vuegen/status "Docker Repository on Quay")][vuegen-docker-quay] [![License](https://img.shields.io/github/license/Multiomics-Analytics-Group/vuegen)][vuegen-license] |
10-
| **Documentation** | [![made-with-sphinx-doc](https://img.shields.io/badge/Made%20with-Sphinx-1f425f.svg)](https://www.sphinx-doc.org/) ![Docs](https://readthedocs.org/projects/vuegen/badge/?style=flat) [![View - Documentation](https://img.shields.io/badge/view-Documentation-blue?style=flat)][vuegen-docs] |
10+
| **Documentation** | [![View - Documentation](https://img.shields.io/badge/view-Documentation-blue?style=flat)][vuegen-docs] [![made-with-sphinx-doc](https://img.shields.io/badge/Made%20with-Sphinx-1f425f.svg)](https://www.sphinx-doc.org/) ![Docs](https://readthedocs.org/projects/vuegen/badge/?style=flat) |
1111
| **Build** | [![CI](https://github.com/Multiomics-Analytics-Group/vuegen/actions/workflows/cdci.yml/badge.svg)][ci-gh-action] [![Docs](https://github.com/Multiomics-Analytics-Group/vuegen/actions/workflows/docs.yml/badge.svg)][ci-docs] |
1212
| **Examples** | [![HTML5](https://img.shields.io/badge/html5-%23E34F26.svg?style=for-the-badge&logo=html5&logoColor=white)][emp-html-demo] [![Streamlit](https://img.shields.io/badge/Streamlit-%23FE4B4B.svg?style=for-the-badge&logo=streamlit&logoColor=white)][emp-st-demo] |
1313
| **Discuss on GitHub** | [![GitHub issues](https://img.shields.io/github/issues/Multiomics-Analytics-Group/vuegen)][issues] [![GitHub pull requests](https://img.shields.io/github/issues-pr/Multiomics-Analytics-Group/vuegen)][pulls] |
@@ -98,7 +98,7 @@ If you prefer not to install VueGen on your system, a pre-configured Docker cont
9898

9999
### Nextflow and nf-core
100100

101-
VueGen is also available as a [nf-core][nfcore] module, customised for compatibility with the [Nextflow][nextflow] environment. This module is designed to automate report generation from outputs produced by other modules, subworkflows, or pipelines. The code and documentation for the nf-core module are available in the [nf-VueGen repository][nf-vuegen].
101+
VueGen is also available as a [nf-core][nfcore] module, customised for compatibility with the [Nextflow][nextflow] environment. This module is designed to automate report generation from outputs produced by other modules, subworkflows, or pipelines. You can read the offical documentation for the nf-core module [here](nf-vuegen-nf-core). Also, the source code and detailed documentation are available in the [nf-VueGen repository][nf-vuegen].
102102

103103
## Execution
104104

@@ -119,6 +119,7 @@ vuegen --directory docs/example_data/Earth_microbiome_vuegen_demo_notebook --rep
119119
Your input directory must follow a **nested folder structure**, where first-level folders are treated as **sections** and second-level folders as **subsections**, containing the components (plots, tables, networks, Markdown text, and HTML files).
120120

121121
Here is an example layout:
122+
122123
```
123124
report_folder/
124125
├── section1/
@@ -138,7 +139,7 @@ report_folder/
138139
> [!WARNING]
139140
> VueGen currently requires each section to contain at least one subsection folder. Defining only sections (with no subsections) or using deeper nesting levels (i.e., sub-subsections) will result in errors. In upcoming releases, we plan to support more flexible directory structures.
140141
141-
The titles for sections, subsections, and components are extracted from the corresponding folder and file names, and afterward, users can add descriptions, captions, and other details to the configuration file. Component types are inferred from the file extensions and names.
142+
The titles for sections, subsections, and components are extracted from the corresponding folder and file names, and afterward, users can add descriptions, captions, and other details to the configuration file. Component types are inferred from the file extensions and names.
142143
The order of sections, subsections, and components can be defined using numerical suffixes in folder and file names.
143144

144145
It's also possible to provide a configuration file instead of a directory:
@@ -206,6 +207,10 @@ from the releases page according to your operating system.
206207

207208
```bash
208209
conda create -n vuegen_gui -c conda-forge python=3.12 jupyter
210+
# in case you have errors, install vuegen addtionally
211+
conda activate vuegen_gui
212+
pip install vuegen
213+
# list all conda environments to find the location of the environment
209214
conda info -e # find environment location
210215
```
211216

@@ -233,7 +238,7 @@ More information regarding the app and builds can be found in the
233238

234239
VueGen’s functionality is demonstrated through two case studies:
235240

236-
**1. Predefined Directory**
241+
### 1. Predefined Directory
237242

238243
This introductory case study uses a predefined directory with plots, dataframes, Markdown, and HTML components. Users can generate reports in different formats and modify the configuration file to customize the report structure.
239244

@@ -242,7 +247,7 @@ This introductory case study uses a predefined directory with plots, dataframes,
242247
> [!NOTE]
243248
> The [configuration file][predef-dir-config] is available in the `docs/example_config_files` folder, and the [directory][predef-dir] with example data is in the `docs/example_data` folder.
244249
245-
**2. Earth Microbiome Project Data**
250+
### 2. Earth Microbiome Project Data
246251

247252
This advanced case study demonstrates the application of VueGen in a real-world scenario using data from the [Earth Microbiome Project (EMP)][emp]. The EMP is an initiative to characterize global microbial taxonomic and functional diversity. The notebook process the EMP data, create plots, dataframes, and other components, and organize outputs within a directory to produce reports. Report content and structure can be adapted by modifying the configuration file. Each report consists of sections on exploratory data analysis, metagenomics, and network analysis.
248253

@@ -252,30 +257,32 @@ This advanced case study demonstrates the application of VueGen in a real-world
252257
> The EMP case study is available online as [HTML][emp-html-demo] and [Streamlit][emp-st-demo] reports.
253258
> The [configuration file][emp-config] is available in the `docs/example_config_files` folder, and the [directory][emp-dir] with example data is in the `docs/example_data` folder.
254259
255-
**3. ChatBot Component**
260+
### 3. ChatBot Component
256261

257262
This case study highlights VueGen’s capability to embed a chatbot component into a report subsection,
258-
enabling interactive conversations inside the report.
263+
enabling interactive conversations inside the report. This component is streamlit-specific and is not
264+
available for other report types.
265+
259266

260267
Two API modes are supported:
261268

262269
- **Ollama-style streaming chat completion**
263-
If a `model` parameter is specified in the config file, VueGen assumes the chatbot is using Ollama’s [/api/chat endpoint][ollama_chat].
264-
Messages are handled as chat history, and the assistant responses are streamed in real time for a smooth and responsive experience.
265-
This mode supports LLMs such as `llama3`, `deepsek`, or `mistral`.
270+
If a `model` parameter is specified in the config file, VueGen assumes the chatbot is using Ollama’s [/api/chat endpoint][ollama_chat].
271+
Messages are handled as chat history, and the assistant responses are streamed in real time for a smooth and responsive experience.
272+
This mode supports LLMs such as `llama3`, `deepsek`, or `mistral`.
266273

267274
> [!TIP]
268275
> See [Ollama’s website][ollama] for more details.
269276
270277
- **Standard prompt-response API**
271-
If no `model` is provided, VueGen uses a simpler prompt-response flow.
272-
A single prompt is sent to an endpoint, and a structured JSON object is expected in return.
273-
Currently, the response can include:
278+
If no `model` is provided, VueGen uses a simpler prompt-response flow.
279+
A single prompt is sent to an endpoint, and a structured JSON object is expected in return.
280+
Currently, the response can include:
274281
- `text`: the main textual reply
275282
- `links`: a list of source URLs (optional)
276283
- `HTML content`: an HTML snippet with a Pyvis network visualization (optional)
277284

278-
This response structure is currently customized for an internal knowledge graph assistant, but VueGen is being actively developed
285+
This response structure is currently customized for an internal knowledge graph assistant, but VueGen is being actively developed
279286
to support more flexible and general-purpose response formats in future releases.
280287

281288
> [!NOTE]
@@ -285,9 +292,17 @@ to support more flexible and general-purpose response formats in future releases
285292

286293
Once a Streamlit report is generated, it can be deployed as a web application to make it accessible online. There are multiple ways to achieve this:
287294

288-
- **Streamlit Community Cloud**: Deploy your report easily using [Streamlit Cloud][st-cloud], as demonstrated in the [EMP VueGen Demo][emp-st-demo]. The process involves moving the necessary scripts, data, and a requirements.txt file into a GitHub repository. Then, the app can be deployed via the Streamlit Cloud interface. The deployment example is available in the `streamlit-report-example` branch.
289-
- **Standalone Executables**: Convert your Streamlit application into a desktop app by packaging it as an executable file for different operating systems. A detailed explanation of this process can be found in this [Streamlit forum post][st-forum-exe].
290-
- **Stlite**: Run Streamlit apps directly in the browser with [stlite][stlite], a WebAssembly port of Streamlit powered by Pyodide, eliminating the need for a server. It also allows packaging apps as standalone desktop executables using stlite desktop.
295+
### Streamlit Community Cloud
296+
297+
Deploy your report easily using [Streamlit Cloud][st-cloud], as demonstrated in the [EMP VueGen Demo][emp-st-demo]. The process involves moving the necessary scripts, data, and a requirements.txt file into a GitHub repository. Then, the app can be deployed via the Streamlit Cloud interface. The deployment example is available in the `streamlit-report-example` branch.
298+
299+
### Standalone Executables
300+
301+
Convert your Streamlit application into a desktop app by packaging it as an executable file for different operating systems. A detailed explanation of this process can be found in this [Streamlit forum post][st-forum-exe].
302+
303+
### Stlite
304+
305+
Run Streamlit apps directly in the browser with [stlite][stlite_repo], a WebAssembly port of Streamlit powered by Pyodide, eliminating the need for a server. It also allows packaging apps as standalone desktop executables using stlite desktop.
291306

292307
These options provide flexibility depending on whether the goal is online accessibility, lightweight execution, or local application distribution.
293308

@@ -352,6 +367,7 @@ We appreciate your feedback! If you have any comments, suggestions, or run into
352367
[nfcore]: https://nf-co.re/
353368
[nextflow]: https://www.nextflow.io/
354369
[nf-vuegen]: https://github.com/Multiomics-Analytics-Group/nf-vuegen/
370+
[nf-vuegen-nf-core]: https://nf-co.re/modules/vuegen/
355371
[colab_badge]: https://colab.research.google.com/assets/colab-badge.svg
356372
[colab_link_intro_demo]: https://colab.research.google.com/github/Multiomics-Analytics-Group/vuegen/blob/main/docs/vuegen_basic_case_study.ipynb
357373
[predef-dir-config]: https://github.com/Multiomics-Analytics-Group/vuegen/blob/main/docs/example_config_files/Basic_example_vuegen_demo_notebook_config.yaml
@@ -361,7 +377,7 @@ We appreciate your feedback! If you have any comments, suggestions, or run into
361377
[emp-config]: https://github.com/Multiomics-Analytics-Group/vuegen/blob/main/docs/example_config_files/Earth_microbiome_vuegen_demo_notebook_config
362378
[emp-dir]: https://github.com/Multiomics-Analytics-Group/vuegen/blob/main/docs/example_data/Earth_microbiome_vuegen_demo_notebook
363379
[st-cloud]: https://streamlit.io/cloud
364-
[stlite]: https://github.com/whitphx/stlite
380+
[stlite_repo]: https://github.com/whitphx/stlite
365381
[st-forum-exe]: https://discuss.streamlit.io/t/streamlit-deployment-as-an-executable-file-exe-for-windows-macos-and-android/6812
366382
[Mona]: https://multiomics-analytics-group.github.io/
367383
[Biosustain]: https://www.biosustain.dtu.dk/

0 commit comments

Comments
 (0)