hacpdsae2023 commited on
Commit
8f37445
·
1 Parent(s): 0037ea6

Test colors

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -2,17 +2,19 @@ import streamlit as st
2
  from datasets import load_dataset
3
  import networkx as nx
4
  import numpy as np
 
5
  dataset = load_dataset("roneneldan/TinyStories")
6
 
7
  st.markdown('# Short Stories, networks and connections')
8
  st.markdown('In this example we consider the semantic similarity between short stories generatited by GenAI.')
9
  st.markdown('We study the relationshis between the stories using a network. The laplacian connectivity provides inights about the closeness of the graph')
10
 
11
- st.markdown('# Short Stories')
12
  st.markdown('We are using a sample fo the [TinyStories](roneneldan/TinyStories) dataset from roneneldan work')
13
  text_text = dataset['train'][10]['text']
14
  st.write(text_text)
15
  st.markdown(':red[' + text_text + ']' )
 
16
 
17
  st.markdown('The threshold changes the level of connectivity in the network. The reange is from 0 (less similar) to 1 (completely similar)')
18
  threshhold = st.slider('Threshhold',0.0,1.0,step=0.1)
 
2
  from datasets import load_dataset
3
  import networkx as nx
4
  import numpy as np
5
+ import pandas as pd
6
  dataset = load_dataset("roneneldan/TinyStories")
7
 
8
  st.markdown('# Short Stories, networks and connections')
9
  st.markdown('In this example we consider the semantic similarity between short stories generatited by GenAI.')
10
  st.markdown('We study the relationshis between the stories using a network. The laplacian connectivity provides inights about the closeness of the graph')
11
 
12
+ st.markdown('## Short Stories')
13
  st.markdown('We are using a sample fo the [TinyStories](roneneldan/TinyStories) dataset from roneneldan work')
14
  text_text = dataset['train'][10]['text']
15
  st.write(text_text)
16
  st.markdown(':red[' + text_text + ']' )
17
+ st.markdown("The next word is <span style='color:red'>red</span>",unsafe_allow_html=True)
18
 
19
  st.markdown('The threshold changes the level of connectivity in the network. The reange is from 0 (less similar) to 1 (completely similar)')
20
  threshhold = st.slider('Threshhold',0.0,1.0,step=0.1)