"""Practice Fields Hub — Curated Therapeutic Practice Spaces"""
import streamlit as st
import base64
import os
st.set_page_config(page_title="Practice Fields", page_icon="🌱", layout="wide")
def get_image_base64(image_path):
"""Convert image to base64 for embedding in HTML."""
try:
with open(image_path, "rb") as f:
return base64.b64encode(f.read()).decode()
except:
return None
# Get base path for images
BASE_PATH = os.path.dirname(os.path.abspath(__file__))
IMG_PATH = os.path.join(BASE_PATH, "images")
st.markdown("""
""", unsafe_allow_html=True)
if "clinician_name" not in st.session_state:
st.session_state.clinician_name = ""
if "clinician_orientation" not in st.session_state:
st.session_state.clinician_orientation = ""
if "onboarded" not in st.session_state:
st.session_state.onboarded = False
# Load images
IMAGES = {
"shadowbox": get_image_base64(os.path.join(IMG_PATH, "shadowbox.webp")),
"tendsend": get_image_base64(os.path.join(IMG_PATH, "tendsend.webp")),
"buildabot": get_image_base64(os.path.join(IMG_PATH, "buildabot.webp")),
"diagnosis": get_image_base64(os.path.join(IMG_PATH, "diagnosis.webp")),
"gspt": get_image_base64(os.path.join(IMG_PATH, "gspt.webp")),
"learnnvc": get_image_base64(os.path.join(IMG_PATH, "learnnvc.webp")),
"difficultconversations": get_image_base64(os.path.join(IMG_PATH, "difficultconversations.webp")),
}
def img_tag(key):
if IMAGES.get(key):
return f''
return ""
SPACES = [
{"key": "shadowbox", "title": "ShadowBox Library", "desc": "A resonant library for hard thoughts. Psychoeducation without synthetic intimacy.", "url": "https://huggingface.co/spaces/jostlebot/shadowbox.library"},
{"key": "tendsend", "title": "Tend & Send", "desc": "Craft messages with care. Practice tending to yourself before sending.", "url": "https://huggingface.co/spaces/jostlebot/TendSend.PrototypeBot"},
{"key": "buildabot", "title": "Build a Bot", "desc": "AI literacy — understand how LLMs work, spot synthetic intimacy.", "url": "https://huggingface.co/spaces/jostlebot/BuildABot.2"},
{"key": "diagnosis", "title": "Diagnosis Explorer", "desc": "Understand diagnostic categories with nuance and care.", "url": "https://huggingface.co/spaces/jostlebot/DiagnosisExplorer"},
{"key": "gspt", "title": "GSPT", "desc": "Generating Safer Passages of Text. Warm, boundaried reflections.", "url": "https://huggingface.co/spaces/jostlebot/GSPT"},
{"key": "learnnvc", "title": "Learn NVC", "desc": "Practice Nonviolent Communication. Transform judgments into needs.", "url": "https://huggingface.co/spaces/jostlebot/LearnNVC"},
{"key": "difficultconversations", "title": "Difficult Conversations", "desc": "Rehearse hard conversations before having them for real.", "url": "https://huggingface.co/spaces/jostlebot/PracticeDifficultConversations"},
]
if not st.session_state.onboarded:
st.markdown("""
This is a prototype demonstration of what becomes possible when mental health professionals bring clinical insight, experience, and wisdom to the design of AI-assisted tools.
Each space represents bounded, trauma-informed innovation — using LLMs as a relational medium with extraordinary strategic care. Not replacing therapy. Not performing synthetic intimacy. Building bridges back to human connection.
Created by a licensed clinician exploring what ethical, clinically-grounded AI practice spaces can look like.
Practice Spaces
', unsafe_allow_html=True) col1, col2 = st.columns(2, gap="medium") for i, s in enumerate(SPACES): with col1 if i % 2 == 0 else col2: st.markdown(f""" {img_tag(s["key"])}