Centralize institutions and acknowledgments data in single JSON source#699
Merged
Conversation
Add docs/static/institutions/institutions.json as canonical source for collaborating institutions and acknowledgments (funding + development credit). Docs homepage imports it at build time, GitHub Pages publishes it for the website repo to consume, and scripts/render_institutions.py regenerates the README.rst acknowledgments block. Pre-commit hook fails when README drifts from the JSON. Institutions: UChile (Leading), CENIA (Associated), IMFD (Collaborator), Unholster (Industry Partner). ANID appears via funding text and logo; UTFSM only mentioned in the acknowledgment text, no logo.
Individual RST image substitutions showed each logo at its native proportions, which looked inconsistent. The render script now trims each logo, scales it to a uniform cell, composes images/logos.png with Pillow, and the README displays that single banner. --check also detects a stale banner.
The acknowledgments text in institutions.json is now an object keyed by locale (en/es/pt). Docs homepages (en and the es translated copy) pick the current locale with English fallback; the es copy also drops its hardcoded logo list in favor of the JSON. README keeps English only. Portuguese exists for the website repository.
The institutions readme sync hook imports PIL to verify images/logos.png is in sync; the CI runner only installed pre-commit. Also trigger the hook when images/logos.png itself changes.
PNG bytes differ across platforms and Pillow versions, so comparing logos.png in --check made CI fail on banners generated locally. The check now verifies only the README text block; normal runs still regenerate the banner.
cristian-tamblay
approved these changes
Jun 15, 2026
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.
Summary
Centralizes the project's collaborating institutions and funding acknowledgments into a single source of truth:
docs/static/institutions/institutions.json. The docs homepage (en and es) imports it at build time, the website repository fetches it at build time from the raw GitHub URL, and a script regenerates the README acknowledgments section from it including a combined logo banner with all logos at uniform size. Adding or removing an institution now means editing one JSON file and rerunning one script.Also updates the institution list per team decision: University of Chile (Leading Institution), CENIA (Associated Institution), IMFD (Collaborator), Unholster (Industry Partner, new logo). ANID appears via funding text and logo; UTFSM is credited in the text only.
Type of Change
Check all that apply like this [x]:
Changes (by file)
docs/static/institutions/institutions.json: new canonical data file institutions (name, role, URL, logo) and acknowledgments (text in en/es/pt, grant ids, funder logos). Consumed by the docs homepage, the README generator script, and the website repository.scripts/render_institutions.py: new script that regenerates the README acknowledgments block and composesimages/logos.png(each logo trimmed and scaled to a uniform cell on a transparent banner).--checkmode verifies only the README text block, since PNG bytes vary across platforms/Pillow versions.README.rst: acknowledgments section replaced by an auto-generated block betweenINSTITUTIONS-BLOCKmarkers; shows the institution list with roles, the English funding text, and the combined banner.docs/src/pages/index.js: hardcoded logo array and funding paragraph replaced by the JSON import; text picks the current locale with English fallback.docs/i18n/es/docusaurus-plugin-content-pages/index.js: same refactor for the Spanish homepage copy (it had drifted: still listed UTFSM, missing Unholster).docs/static/img/institutions/unholster-logo.png: new logo.images/logos.png: now generated by the script (transparent background, uniform logo sizes)..pre-commit-config.yaml: newinstitutions-readme-synchook fails the commit if README drifts from the JSON..github/workflows/pre-commit.yaml: installs Pillow so the hook's script can run in CI.Testing
python scripts/render_institutions.pyis idempotent;--checkpasses after a run and fails when the JSON changes without regenerating.Notes
https://raw.githubusercontent.com/DashAISoftware/DashAI/develop/docs/static/institutions/institutions.jsonat build time (not at runtime, to avoid GitHub rate limiting on visitors) and readacknowledgments.text.<locale>the text field is an object keyed byen/es/pt, not a plain string. Portuguese exists only for the website; the docs have no pt locale. Logo image URLs resolve against the same base path (.../develop/docs/static/+ the entry'slogofield).dcc-logo.png(the only UChile logo in the repo) swap the file if a central university logo is preferred.utfsm-logo.pngis now unreferenced but left in place in case the decision reverses.