2023-06-11 16:37:28 +03:00
---
2024-04-22 18:34:11 +03:00
title: Technical Design
description: Learn how Quivr works under the hood
icon: microchip
2024-04-23 01:40:29 +03:00
---
2023-12-29 13:52:34 +03:00
## Backend Stack
### FastAPI: The Foundation of Quivr
FastAPI is central to Quivr's high-performance capabilities. Here, we explore its role and the benefits it brings to the table.
<AccordionGroup>
<Accordion title="Introduction to FastAPI">
2024-04-23 01:40:29 +03:00
FastAPI is a leading-edge web framework for building APIs with Python 3.6+.
It stands out for its speed, efficiency, and compatibility with modern
development needs. - **Speed**: FastAPI is one of the fastest web frameworks
for Python... - **Type Checking**: Utilizes Python type hints for
validation... - **Asynchronous Coding**: Supports asynchronous request
handling...
2023-12-29 13:52:34 +03:00
</Accordion>
<Accordion title="Choosing FastAPI for Quivr">
Our selection of FastAPI aligns perfectly with Quivr's design philosophy...
2024-04-23 01:40:29 +03:00
- **Performance and Scalability**: FastAPI's speed makes Quivr highly
efficient... - **Ease of Use**: Its intuitive design allows for rapid
development... - **Rich Feature Set**: FastAPI comes with built-in support
for data validation...
2023-12-29 13:52:34 +03:00
</Accordion>
<Accordion title="FastAPI vs Other Frameworks">
2024-04-23 01:40:29 +03:00
FastAPI's performance metrics are superior when compared to counterparts
like Flask and Django... - **Flask**: While Flask is simpler, FastAPI
provides built-in support... - **Django**: Django is a full-stack framework,
but for API development...
2023-12-29 13:52:34 +03:00
</Accordion>
</AccordionGroup>
### Authentication: Secure Access to Quivr
Secure and streamlined authentication is key to accessing Quivr's features.
<Steps>
<Step title="Account Creation">
Sign up for Quivr and navigate to the `/user` page on your user dashboard.
</Step>
<Step title="API Key Generation">
2024-04-23 01:40:29 +03:00
Generate your unique API key in the settings, your access token to Quivr's
backend services.
2023-12-29 13:52:34 +03:00
</Step>
<Step title="API Key Usage">
Include the generated API key in the request header for secure access.
</Step>
</Steps>
### The Architecture of Our Kingdom: Robust and Scalable
Quivr's architecture is a testament to modern, scalable web service design:
<CardGroup cols={2}>
<Card title="Load Balancer" icon="network-wired">
2024-04-23 01:40:29 +03:00
The Load Balancer efficiently manages incoming traffic, ensuring optimal
performance.
2023-12-29 13:52:34 +03:00
</Card>
<Card title="Container Service" icon="docker">
2024-04-23 01:40:29 +03:00
Our Container Service orchestrates digital services, maintaining operational
harmony.
2023-12-29 13:52:34 +03:00
</Card>
<Card title="Queue" icon="crown">
The Queue system prioritizes and manages task execution.
</Card>
<Card title="Celery Worker" icon="list">
Celery Worker handles queued tasks, ensuring timely and effective execution.
</Card>
</CardGroup>
### Words of Wisdom: Keeping Your API Secure
<Warning>
2024-04-23 01:40:29 +03:00
Always protect your API key. It's crucial for maintaining the security and
integrity of your access to Quivr.
2023-12-29 13:52:34 +03:00
</Warning>
### The Balance of Power: Pros and Cons Analysis
Understanding the pros and cons of FastAPI helps in making informed decisions:
<AccordionGroup>
<Accordion title="Advantages of Using FastAPI">
FastAPI enhances development with its swift performance...
</Accordion>
<Accordion title="Considerations for FastAPI">
2024-04-23 01:40:29 +03:00
While advantageous, FastAPI requires understanding of modern programming
concepts...
2023-12-29 13:52:34 +03:00
</Accordion>
</AccordionGroup>
### Interactive API Sandbox: Experience Quivr in Action
Engage with Quivr's functionality in real-time in our interactive API sandbox:
<Info>
2024-04-23 01:40:29 +03:00
🌐 [Test and refine your API calls using our
sandbox.](https://api.quivr.app/docs)
2023-12-29 13:52:34 +03:00
</Info>
## Frontend
2024-04-23 01:40:29 +03:00
### Next.js and Vercel: The Dynamic Duo
2023-12-29 13:52:34 +03:00
Quivr's frontend is crafted with Next.js, a cutting-edge React framework, and is hosted on Vercel, a platform tailored for frontend frameworks like Next.js. This combination provides a seamless, efficient, and scalable user experience.
### Next.js: The Power of React Enhanced
2024-04-23 01:40:29 +03:00
2023-12-29 13:52:34 +03:00
Next.js is chosen for its robust features that elevate the React development experience:
<AccordionGroup>
<Accordion title="Server-Side Rendering & Static Generation">
2024-04-23 01:40:29 +03:00
Next.js supports SSR and Static Generation, crucial for performance and SEO.
This ensures Quivr's pages are pre-rendered for faster load times and
improved search engine visibility.
2023-12-29 13:52:34 +03:00
</Accordion>
<Accordion title="API Routes">
2024-04-23 01:40:29 +03:00
Next.js allows the creation of API endpoints within the application,
enabling a seamless blend of client and server-side logic.
2023-12-29 13:52:34 +03:00
</Accordion>
<Accordion title="Enhanced Development Experience">
2024-04-23 01:40:29 +03:00
With features like fast refresh and built-in CSS support, Next.js
streamlines the development process, boosting developer productivity.
2023-12-29 13:52:34 +03:00
</Accordion>
<Accordion title="Scalability">
2024-04-23 01:40:29 +03:00
Next.js's architecture facilitates easy scaling of applications to meet
growing user bases and complex features.
2023-12-29 13:52:34 +03:00
</Accordion>
</AccordionGroup>
### Vercel: Optimized Hosting for Next.js
Vercel, renowned for its global deployment capabilities and serverless functions, hosts Quivr's frontend:
<CardGroup cols={2}>
<Card title="Optimized for Next.js" icon="react">
2024-04-23 01:40:29 +03:00
Vercel, built by the creators of Next.js, ensures seamless integration and
optimal performance for Quivr's frontend.
2023-12-29 13:52:34 +03:00
</Card>
<Card title="Edge Network" icon="network-wired">
2024-04-23 01:40:29 +03:00
Leveraging Vercel's Edge Network reduces latency and speeds up content
delivery, enhancing user experience.
2023-12-29 13:52:34 +03:00
</Card>
<Card title="Continuous Deployment" icon="octopus-deploy">
2024-04-23 01:40:29 +03:00
Continuous deployment on Vercel allows for swift and efficient updates,
keeping Quivr's frontend up-to-date.
2023-12-29 13:52:34 +03:00
</Card>
<Card title="Scalable Infrastructure" icon="layer-group">
2024-04-23 01:40:29 +03:00
Vercel's infrastructure automatically scales to meet user demand, ensuring
consistent performance even during peak times.
2023-12-29 13:52:34 +03:00
</Card>
</CardGroup>
<Tip>
2024-04-23 01:40:29 +03:00
By combining Next.js and Vercel, Quivr achieves a robust, scalable, and
responsive web application, meeting the demands of modern web users and
developers.
2023-12-29 13:52:34 +03:00
</Tip>
2024-04-23 01:40:29 +03:00
This integration of Next.js and Vercel is a testament to Quivr's commitment to delivering
high-quality, responsive, and dynamic web applications, catering to modern web development
needs.
2023-06-19 12:58:03 +03:00
2023-12-29 13:52:34 +03:00
## Architectural Overview
Explore the intricacies of Quivr's architecture through this detailed diagram:
2023-06-19 12:58:03 +03:00
2023-12-29 13:52:34 +03:00
<Frame>
2024-04-23 01:40:29 +03:00
<img
src="/images/architectural-high-level.png"
alt="Quivr Architecture Diagram"
/>
2023-12-29 13:52:34 +03:00
</Frame>
2023-06-19 12:58:03 +03:00
2023-12-29 13:52:34 +03:00
## Quivr Community
2023-06-19 12:58:03 +03:00
2023-12-29 13:52:34 +03:00
Your input is invaluable in shaping the future of Quivr. Connect with us:
2023-06-19 12:58:03 +03:00
2023-12-29 13:52:34 +03:00
<Tabs>
<Tab title="Feedback">
Share your feedback and suggestions to enhance Quivr.
</Tab>
<Tab title="Community">
2024-04-23 01:40:29 +03:00
Engage with peers in our forums and social platforms for support and
collaboration.
2023-12-29 13:52:34 +03:00
</Tab>
</Tabs>
2023-06-19 12:58:03 +03:00
2024-04-23 01:40:29 +03:00
---