Spaces:
Build error
Build error
Download sidebar.py from niro-private/chatCSV: direct link, hf CLI and curl.
- Browser
- Download file 351 Bytes
-
https://huggingface.co/spaces/niro-private/chatCSV/resolve/main/sidebar.py
- Command line
-
hf download hf://spaces/niro-private/chatCSV/sidebar.py
-
curl -L -o sidebar.py https://huggingface.co/spaces/niro-private/chatCSV/resolve/main/sidebar.py
351 Bytes
| import streamlit as st | |
| def sidebar(supabase): | |
| st.sidebar.title("Database Information") | |
| number_of_docs = number_of_documents(supabase) | |
| st.sidebar.markdown(f"**Docs in DB:** {number_of_docs}") | |
| def number_of_documents(supabase): | |
| documents = supabase.table("documents").select("id", count="exact").execute() | |
| return documents.count |