This repository contains the frontend code for the RI-SCALE Model Hub, utilizing the Hypha backend.
The scripts/ directory contains several utility scripts for managing the hub during development.
Ensure you have the required Python packages installed:
pip install hypha-rpc requestsIf you encounter 403 Forbidden errors when accessing the hub or artifacts (especially after changing storage backends), use this script to restore public read access.
Usage:
# Using a token directly
python3 scripts/fix_hub_permissions.py --token <YOUR_HYPHA_TOKEN>
# Using environment variable
export HYPHA_TOKEN=<YOUR_HYPHA_TOKEN>
python3 scripts/fix_hub_permissions.pyTo upload a sample artifact that demonstrates the "Open App" (static site) feature:
# Using a token
python3 scripts/upload_sample.py --token <YOUR_HYPHA_TOKEN>This will create an artifact ri-scale/sample-static-app containing an index.html file.
Run this script to inspect the current configuration and permissions of the hub artifact without modifying them.
python3 scripts/diagnose_hub.pyArtifacts containing an index.html file will display an "Open App" button in the interface. This opens the static site directly in the browser, served via Hypha.
For branch-safe dev deployments, production-only app IDs, health monitoring, and rollback automation, see:
docs/chat-proxy-cicd.md
- Keep
src/pages/AgentPage.tsxagent-agnostic. It should orchestrate execution, retries, and generic fallback handling only. - Keep BioImage Finder domain logic in
scripts/agent_startup_scripts/bioimage_finder_startup_script.py. - BioImage-specific search result shaping (compact payloads) and dataset fallback summaries must be implemented in the startup script, not in generic frontend orchestration code.
- Keep chat-proxy app agent-agnostic with a minimal surface (
setup,chat_completion,resolve_url).