Getting Started
Now it’s your time to shine. Keep reading to learn more on how to make your docs beautiful and powerful.
Create your 1st Berri in just 2 steps!
👩🏽💻 Code: https://replit.com/@krrishdholakia/BerriAPIQuizlet?v=1#main.py
🚀 Playground - berri.ai/.
Step 1: Create an App
Creating an app requires 2 things:
- User email: so we can map the created app to your account
- Data source: This is either the file or url (website or api endpoint) you’d like to query.
Note: For our quick start we won’t go into it, but you also have the option of customizing your app (custom prompting, search strategies, etc.). Go to App Configurations to learn more.
For now, let’s do it on a sample pdf.
Ensure that you are reading the file and sending its contents. This works for PDF, DOC, TXT, CSV, and PPTX files.
Step 2: Try your app!
Congratulations, you’ve just built your first Berri app.
You can share this app with your friends with the website_endpoint, or integrate this into your app with the api_endpoint!
Here’s an example of how you can query the api endpoint:
url = api_endpoint
user_query = "What do you know?"
final_url = api_endpoint + "&query=" + user_query
response = requests.get(final_url)
print(response.text)
system_response = response.json()["response"]