In an effort to make this process easier, we created a framework for making a shareable dashboard for proof-of-concept use cases.
Let’s look at the specific technologies in play.
Streamlit is a Python framework that makes creating dashboards easier than ever. It lets you create a full, interactive dashboard without ever touching HTML or JS. Streamlit internally handles all of the front-end code and reduces complex structures to one-line functions. This allows everyone to create impressive dashboards with only a few lines of Python.
We used Streamlit for the front-end aspect of the Dashboard.
TigerGraph is the fastest graph database platform in the world. With TigerGraph, you can create graphs with billions of nodes and edges that operate in realtime. TigerGraph also makes use of GSQL, their own graph query language that mimics SQL syntax and allows for quick and easy querying of graph data.
We used TigerGraph to store our data. Specifically, we used the Covid-19 Starter Kit from TigerGraph, which has Covid-19 data from the Korean Centers for Disease Control & Prevention (KCDC),
Google Colab is a free, cloud-based, Jupyter notebook environment. With Colab, you can create Python scripts without having to worry about disk space and RAM on your local machine. Additionally, like any file stored in Google Drive, Colab notebooks are completely sharable.
We used Google Colab to make the dashboard shareable and allow each user to have their own copy.
Now, let’s walk through the process of launching the dashboard. The entire process takes about 15 minutes and no requires no code, making it accessible to everyone.
Creating a TigerGraph Cloud Account
Choose Covid-19 Starter Kit
Loading Data Into the Graph
Creating the Streamlit Dashboard
Running the Google Colab Notebook
Exploring your dashboard
1. Creating a TigerGraph Cloud Account
The first step is creating a TigerGraph Cloud account. Head over to the TigerGraph signup page and follow the steps provided.
You can also watch this demo if you get lost along the way.
2. Choose Covid-19 Starter Kit
Once your account has been created, you need to create a graph database. Start by clicking the My Solutions button and choose the Covid-19 Analysis starter kit.
3. Loading Data Into the Graph
Once it’s ready, load GraphStudio and click the Load Data tab. Hit the play button, and the data will start loading.
Once done, the graph is now good to go. There are lots of other tabs that let you explore the graph and the data. There are also a number of premade queries that show off the native GSQL used by TigerGraph.
We’ll skip over these features for now, and move on to creating the visualization.
4. Creating the Streamlit Dashboard
Luckily, the script to create the streamlit dashboard is already written. If you want to see how the dashboard was made, check out this blog by Rohan Shiva. Next, continue to the premade Google Colab notebook.
5. Running the Google Colab Notebook
When you start up the notebook, you’ll come across a form asking for the information for your graph instance.
Once you enter your information, hit the Launch Dashboard button. This will start the loading process. The program will take about 2 minutes to load.
You may be wondering, what’s happening behind the scenes?
The code first installs the pyTigerGraph Python package. This package simplifies the TigerGraph connection process and lets you call TigerGraph functions in Python
The code then grabs other packages like Streamlit
Next, it grabs the script for the Streamlit dashboard and the corresponding query that extracts information from the graph.
Then, using pyTigerGraph, the query is uploaded to the graph
Finally, the code configures a secure tunnel using ngrok to deploy the streamlit app. Normally streamlit is deployed locally, but the localhost can’t be accessed from Google Colab (since it’s a cloud environment). Thus, we use ngrok to link the localhost to a live website.
6. Exploring your Dashboard
Once the loading has taken place, the dashboard is good to go. Hit the link provided, and you’ll be brought to a webpage with the Streamlit visualization. You now have a full stack app at your disposal!
We presented a general framework for creating readily-deployable, premade dashboards. The entire process takes about 15 minutes and requires no code, making it accessible to everyone. This process can be applied to other technologies as well, as long as the 3 main components are me:
Dr. Jay Yu is the VP of Product and Innovation at TigerGraph, responsible for driving product strategy and roadmap, as well as fostering innovation in graph database engine and graph solutions. He is a proven hands-on full-stack innovator, strategic thinker, leader, and evangelist for new technology and product, with 25+ years of industry experience ranging from highly scalable distributed database engine company (Teradata), B2B e-commerce services startup, to consumer-facing financial applications company (Intuit). He received his PhD from the University of Wisconsin - Madison, where he specialized in large scale parallel database systems
Todd Blaschka |COO
Todd Blaschka is a veteran in the enterprise software industry. He is passionate about creating entirely new segments in data, analytics and AI, with the distinction of establishing graph analytics as a Gartner Top 10 Data & Analytics trend two years in a row. By fervently focusing on critical industry and customer challenges, the companies under Todd's leadership have delivered significant quantifiable results to the largest brands in the world through channel and solution sales approach. Prior to TigerGraph, Todd led go to market and customer experience functions at Clustrix (acquired by MariaDB), Dataguise and IBM.