Quantcast
Channel: Andrej Baranovskij Blog
Browsing all 705 articles
Browse latest View live

Deploying FastAPI Applications to Hugging Face Spaces

In this video, I demonstrate how to deploy a FastAPI backend API to Hugging Face Spaces using Docker. I cover creating a Dockerfile, setting up secrets for FastAPI, and deploying the application on the...

View Article


Efficient Document Data Extraction with Sparrow UI: Streamlit, FastAPI, and...

In this easy-to-follow video, I show you how I built Sparrow UI, a tool for pulling data from documents using Streamlit. With Sparrow UI, you can upload a document and quickly run a data extraction...

View Article


Optimizing ML Model Loading Time Using LRU Cache in FastAPI

Are you facing challenges with the time it takes to load large ML models in your backend API? This video presents a practical solution: utilizing LRU cache with properly annotated functions....

View Article

Optimizing FastAPI for Concurrent Users when Running Hugging Face ML Models

To serve multiple concurrent users accessing FastAPI endpoint running Hugging Face API, you must start the FastAPI app with several workers. It will ensure current user requests will not be blocked if...

View Article

Speeding Up FastAPI App with Background Tasks

FastAPI runs background tasks in a parallel thread, which prevents blocking app endpoints when a long task executes. I explain it in this video and show the benefit of running time-consuming operations...

View Article


Document AI: How To Convert Colab ML Notebook Into FastAPI App

I explain how I converted Donut ML model fine-tuning code implemented as Colab notebook into API running as FastAPI app. I share several hints how to simplify code refactoring efforts.  

View Article

ChatGPT/GPT-4 for Receipt OCR Data Analysis

I show how ChatGPT works with array data generated from OCR engine by extracting text from the receipt document. ChatGPT can parse and understand the data. What is great about it - GPT-4 model...

View Article

PaddleOCR as a Service with FastAPI

PaddleOCR is a great tool to extract text data from docs, and it can group related words into a sentence. Such functionality can simplify extracted data analysis. In this video, I explain how to run it...

View Article


Building Your Own ChatGPT Plugin

I explain how to get started with ChatGPT plugin development. It is essential to understand how to define OpenAPI specification to match endpoints. In this example, you will see a working use case with...

View Article


File Upload App for ChatGPT

ChatGPT doesn't provide a file upload option out of the box. I explained the app I built with Streamlit to handle file upload and allow ChatGPT to fetch file content through the plugin and unique key.  

View Article

FastAPI, Pydantic and MongoDB for Beginners

I show how to initialize a connection to MongoDB from FastAPI endpoint with a startup event. Before pushing it to MongoDB collection, new record validation is done with Pydantic. I like the flexibility...

View Article

ChatGPT Plugin with Persistent Storage

Receipt Assistant is our ChatGPT plugin with persistent storage support. I show how it works to upload a scanned receipt and store OCR result converted to key/value pairs by ChatGPT. Load data back...

View Article

ChatGPT Plugin Backend with FastAPI

This tutorial explains how to integrate FastAPI backend with ChatGPT plugin implemented in Python. Backend stores data from ChatGPT in MongoDB to be persistent and available across sessions.  

View Article


Deploy Local ML Apps with Ngrok

Ngrok helps to run your local apps online with access on the Web. It provides HTTPS with auto renewal, content compression. With Ngrok you can serve your ML apps running on local infra to external...

View Article

ChatGPT Plugin OAuth with Logto

You can setup OAuth for ChatGPT plugin, to be able to get user info. This is needed when the plugin works with user data, and you want to keep that data across sessions. With OAuth you can authenticate...

View Article


How to Host FastAPI from Your Computer with ngrok

With ngrok you can host your FastAPI app from your computer. This can be a handy and cheaper option for some projects. In this video, I explain my experience running FastAPI apps from my very own Cloud...

View Article

Computer Vision with ChatGPT - Receipt Assistant Plugin

Our plugin - Receipt Assistant was approved to be included in ChatGPT store. I explain how it works and how to use it in combination with other plugins, for example, to display charts. Receipt...

View Article


Data Filtering and Aggregation with Receipt Assistant Plugin for ChatGPT

I explain Receipt Assistant plugin for ChatGPT from a user perspective. I show how to fetch previously processed and saved receipt data, including filtering and aggregation. Also, I show how you can...

View Article

LLama 2 LLM for PDF Invoice Data Extraction

I show how you can extract data from text PDF invoice using LLama2 LLM model running on a free Colab GPU instance. I specifically explain how you can improve data retrieval using carefully crafted...

View Article

Pros and Cons of Developing Your Own ChatGPT Plugin

I've been running ChatGPT plugin in prod for a month and sharing my thoughts about the pros and cons of developing it. Would I build a new ChatGPT plugin?  

View Article
Browsing all 705 articles
Browse latest View live