Skip to content

Commit 7995835

Browse files
committed
changes requested by Lokesh - 2
1 parent fe16765 commit 7995835

File tree

1 file changed

+10
-40
lines changed

1 file changed

+10
-40
lines changed

tutorial/markdown/python/streamlit/flight_search_streamlit_couchbase.md

Lines changed: 10 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -31,49 +31,16 @@ This tutorial will guide you through building a fully functional Streamlit appli
3131

3232
By the end of this tutorial, you will have a working flight visualization tool and a deeper understanding of how to integrate Couchbase with Streamlit for interactive data applications.
3333

34-
The final app will look like this hosted Streamlit application: [Couchbase Connector Demo App](https://couchbase-connector-demo-app.streamlit.app/). The original code for this demo is available [here](https://github.com/couchbase-examples/streamlit-quickstart/blob/main/Demo.py).
35-
36-
#### Screenshots of the Final App
37-
<table align="center">
38-
<tr>
39-
<td align="center">
40-
<img src="startup_demo_tab.png" style="width: 200vw; height: auto; border-radius: 1vw;">
41-
</td>
42-
<td align="center">
43-
<img src="flight_visuals_tab.png" style="width: 200vw; height: auto; border-radius: 1vw;">
44-
</td>
45-
</tr>
46-
<tr>
47-
<td align="center">
48-
<img src="hotel_near_landmarks_tab.png" style="width: 200vw; height: auto; border-radius: 1vw;">
49-
</td>
50-
<td align="center">
51-
<img src="hotels_in_city_tab.png" style="width: 200vw; height: auto; border-radius: 1vw;">
52-
</td>
53-
</tr>
54-
</table>
34+
### Try It Now on Streamlit Cloud
35+
You can experience the application live on Streamlit Cloud: [Try the Couchbase Connector Demo App](https://couchbase-connector-demo-app.streamlit.app/). If the application doesn't load, the app may have gone to sleep due to inactivity. If you see a 'Zzzz' screen, click the 'Yes, get this app back up!' button to wake it up and wait for a while as it restarts.
36+
37+
The original code for this demo is available [here](https://github.com/couchbase-examples/streamlit-quickstart/blob/main/Demo.py).
5538

5639
## Basic Concepts
5740

58-
### Understanding JSON and Document Databases
59-
Couchbase is a NoSQL document database that stores data in JSON format. This allows for flexible and scalable data modeling. JSON (JavaScript Object Notation) is a lightweight data format that is:
60-
- **Human-readable**: Easy to interpret and debug.
61-
- **Flexible**: Supports hierarchical structures.
62-
- **Efficient**: Quick to parse and generate.
63-
64-
Example JSON document:
65-
```json
66-
{
67-
"id": "user_123",
68-
"name": "Alice Smith",
69-
"email": "[email protected]",
70-
"age": 21,
71-
"preferences": {
72-
"theme": "dark",
73-
"notifications": true
74-
}
75-
}
76-
```
41+
### JSON and Document Databases in Couchbase
42+
Couchbase is a NoSQL document database that stores data in JSON format. This allows for flexible and scalable data modeling.
43+
7744
Couchbase Uses JSON because:
7845
- **Flexible Schema**: No predefined structure, allowing easy adaptation to changing requirements.
7946
- **Efficient Querying**: Uses SQL-like SQL++ queries for fast data retrieval.
@@ -123,17 +90,20 @@ These collections provide the necessary data for flight visualization, enabling
12390
- Displays airports on an OpenStreetMap-based interactive map.
12491
- Allows users to select specific airports and visualize routes between them.
12592
- Uses Plotly for dynamic visualization of routes.
93+
<img src="flight_visuals_tab.png" style="width: 100%; height: auto; border-radius: 10px;">
12694

12795
2. **Landmark and Hotel Visualization**
12896
- Shows landmarks along with relevant details such as activities, address, and descriptions.
12997
- Displays hotels near selected landmarks within a specified distance.
13098
- Uses Geopy to calculate distances between landmarks and hotels.
13199
- Color-coded markers distinguish landmarks and hotels.
100+
<img src="hotel_near_landmarks_tab.png" style="width: 100%; height: auto; border-radius: 10px;">
132101

133102
3. **Hotel Listings by City**
134103
- Users can select multiple cities to view hotels.
135104
- Displays hotels on an interactive map, color-coded based on average ratings.
136105
- Includes additional details such as price, amenities, and customer ratings.
106+
<img src="hotels_in_city_tab.png" style="width: 100%; height: auto; border-radius: 10px;">
137107

138108
4. **Efficient Data Retrieval from Couchbase**
139109
- Queries optimized to fetch only relevant data for visualization.

0 commit comments

Comments
 (0)