Spaces:
Running
Running
Reorganised layout to fit extra LLMs
Browse filesFor some reason hugging face won't allow me to change multiple documents in a single pull request
7 unmodified lines89101112132 unmodified lines1617181920212261 unmodified lines8485868788897 unmodified lines9798991001011021031041051061071081091107 unmodified linesfrom ring import LLM_GPT4ofrom ring import LLM_LLAMA2from ring import LLM_GEMINIfrom ring import PREF_ORDER_LLMS2 unmodified linesfrom ring import generate_responsefrom ring import generate_panel_response__version__ = "0.2.1"col1, col2 = st.columns([3, 1])61 unmodified lines###Start of Kaan Changes# Selectbox to determine which LLM becomes panel leadpanel_lead = st.radio("Which LLM would you like to lead this panel?",PREF_ORDER_LLMS,7 unmodified lines)options = PREF_ORDER_LLMS # [llm for llm in PREF_ORDER_LLMS if llm !=panel_lead] creates a list of options excluding the chosen panel leadselected_options = []# Put checkboxes into columns to be arranged horizontallycols = st.columns(len(options))for i, option in enumerate(options):with cols[i]:selected = st.checkbox(option, key=option, value=(i != 0))if selected:selected_options.append(option)submitted = st.form_submit_button("Submit")7 unmodified lines89101112131415162 unmodified lines1920212223242561 unmodified lines878889909192939495967 unmodified lines1041051061071081091101111121131141151161171181191207 unmodified linesfrom ring import LLM_GPT4ofrom ring import LLM_LLAMA2from ring import LLM_GEMINIfrom ring import LLM_AI21from ring import LLM_Claude2from ring import LLM_Coherefrom ring import PREF_ORDER_LLMS2 unmodified linesfrom ring import generate_responsefrom ring import generate_panel_response__version__ = "0.2.2"col1, col2 = st.columns([3, 1])61 unmodified lines###Start of Kaan Changes# Selectbox to determine which LLM becomes panel leadst.markdown("<style> .stRadio> div {gap:30px;} </style>",unsafe_allow_html=True,)panel_lead = st.radio("Which LLM would you like to lead this panel?",PREF_ORDER_LLMS,7 unmodified lines)options = PREF_ORDER_LLMS # [llm for llm in PREF_ORDER_LLMS if llm !=panel_lead] creates a list of options excluding the chosen panel leadselected_options = []#Put checkboxes into table arranged 4x2for row in range(2): # 2 rowscols = st.columns(4) # 4 columns in each rowfor col in range(4): # Iterate over each columnindex = row * 4 + colif index < len(options):with cols[col]:selected = st.checkbox(options[index], key=options[index])if selected:selected_options.append(options[index])submitted = st.form_submit_button("Submit")
app.py+19-9