Add Open Science Assistant (OSA) BIDS chat widget#2442
Open
neuromechanist wants to merge 1 commit into
Open
Conversation
Embed the OSA BIDS assistant via a Material theme override. The widget is a single self-contained script served from the OSA project's own domain; it renders its own floating button, persists chat history in localStorage across navigation, and is configured entirely from the BIDS community YAML config in the OSA repository. The only per-site setting is the community id. The script is intentionally unpinned so the BIDS community receives assistant updates without merging a new PR here. See bids-standard#2256 and bids-standard#2254.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2442 +/- ##
=======================================
Coverage 83.07% 83.07%
=======================================
Files 22 22
Lines 1696 1696
=======================================
Hits 1409 1409
Misses 287 287 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
neuromechanist
added a commit
to OpenScience-Collective/osa
that referenced
this pull request
Jun 8, 2026
Allow the BIDS assistant widget to load on the ReadTheDocs PR preview builds for bids-standard/bids-specification#2442 and bids-standard/bids-website#847 so reviewers can try the widget before merge. These two origins are temporary and should be removed once both PRs merge.
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add Open Science Assistant (OSA) BIDS chat widget
Closes part of #2256 (next-phase BIDS assistant)
Tip
Test the assistant from built PR link, on bottom right:
https://bids-specification--2442.org.readthedocs.build/en/2442/
Summary
This adds an embedded BIDS assistant to the specification site, powered by the Open Science Assistant (OSA) and its dedicated BIDS community. It is a single self-contained script (its own floating button, no iframe), configured entirely from a YAML file in the OSA repository.
This is offered as a complementary alternative to the iframe widget in #2254 (thanks @yarikoptic). Both proposals come out of the discussion in #2256; the maintainers can pick whichever fits best, or evaluate them side by side. Nothing here blocks or supersedes #2254.
What changes
Two minimal changes, mirroring the structure of #2254:
mkdocs.yml: settheme.custom_dir: src/overridessrc/overrides/main.html: a theme override that injects the OSA snippetNo CSS, no iframe, no toggle plumbing: the widget renders and manages its own UI.
Design notes (and how this differs from #2254)
localStorageacross page navigation — directly addressing the UX concern raised in the feat: Add AI BIDS assistant widget to the specification pages #2254 review thread (history lost when navigating between spec pages).What the BIDS assistant actually does
The whole assistant is defined in one community config (
src/assistants/bids/config.yaml), so the BIDS community can change behavior by editing YAML, with no OSA code changes. Current capabilities:raw.githubusercontent.com/.../master(spec) and.../main(website), so answers track the current text rather than a frozen snapshot. Coverage spans common principles, the schema, all 13 modalities (MRI, EEG, MEG, iEEG, PET, NIRS, Motion, Microscopy, MRS, EMG, behavioral, genetics, physiological), derivatives, getting-started, FAQs, tools, and governance.bids-specification,bids-validator,bids-website, andbids-examples, so the assistant can answer "what are the recent PRs / open issues / discussions about X" with real, linked items.lookup_beptool searches synced BIDS Extension Proposal content from open pull requests (the rendered BEP drafts), returning the direct PR and HTML-preview links.bids.Sync cadence: GitHub issues/PRs daily, papers weekly, BEPs weekly — so the knowledge base stays current.
Testing
mkdocs serverenders the widget on spec pages; the floating button opens the BIDS assistant and history survives navigation between pages.Links