Spaces:
Build error

YashB1 commited on
Commit
baf9aa8
·
verified ·
1 Parent(s): 72b10ae

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -85,12 +85,13 @@
85
  ################################################### Approach 3
86
  import streamlit as st
87
  from datasets import Dataset
 
88
 
89
  # Function to push feedback data to Hugging Face Hub dataset
90
  def push_to_dataset(feedback, comments):
91
  # Load existing dataset or create a new one if it doesn't exist
92
  try:
93
- dataset = Dataset.load_dataset("YashB1/Feedbacks", split="train")
94
  except FileNotFoundError:
95
  # If dataset doesn't exist, create a new one
96
  dataset = Dataset.from_dict({"feedback": [], "comments": []})
 
85
  ################################################### Approach 3
86
  import streamlit as st
87
  from datasets import Dataset
88
+ from datasets import load_dataset
89
 
90
  # Function to push feedback data to Hugging Face Hub dataset
91
  def push_to_dataset(feedback, comments):
92
  # Load existing dataset or create a new one if it doesn't exist
93
  try:
94
+ dataset = load_dataset("YashB1/Feedbacks", split="train")
95
  except FileNotFoundError:
96
  # If dataset doesn't exist, create a new one
97
  dataset = Dataset.from_dict({"feedback": [], "comments": []})