Tagged articles

FastAPI

137 articles · Page 2 of 2
Code Mala Tang
Code Mala Tang
Mar 22, 2025 · Backend Development

Pydantic & FastAPI: Optional Fields, Nested Models, and Advanced Validation

Learn how to leverage Pydantic in FastAPI to handle optional fields, validate nested data structures, enforce complex business rules with model validators, forbid extra fields, work with polymorphic models, and validate query and path parameters, all illustrated with clear Python code examples.

API designBackend DevelopmentData Validation
0 likes · 10 min read
Pydantic & FastAPI: Optional Fields, Nested Models, and Advanced Validation
Code Mala Tang
Code Mala Tang
Mar 21, 2025 · Backend Development

How to Implement Rate Limiting in FastAPI with SlowAPI

This tutorial explains how to add request rate limiting to a FastAPI application using the SlowAPI library, covering both IP‑based limits and custom token‑based strategies, with installation steps, code examples, and best‑practice recommendations.

FastAPIPythonSlowAPI
0 likes · 5 min read
How to Implement Rate Limiting in FastAPI with SlowAPI
Code Mala Tang
Code Mala Tang
Mar 20, 2025 · Backend Development

How to Design Scalable FastAPI Project Structures: File‑Based vs Module‑Based

This article compares two primary FastAPI project structure strategies—file‑type based and module‑function based—explaining why a well‑organized architecture improves scalability, maintainability, and team collaboration, and provides concrete directory layouts and best‑practice guidelines for building robust backend applications.

Backend DevelopmentFastAPIMicroservices
0 likes · 9 min read
How to Design Scalable FastAPI Project Structures: File‑Based vs Module‑Based
Code Mala Tang
Code Mala Tang
Mar 19, 2025 · Backend Development

Applying SOLID Principles and Design Patterns in FastAPI for Clean Architecture

This article explains how to apply SOLID principles and common design patterns such as DAO, service layer, and dependency inversion to FastAPI, demonstrating code examples that separate responsibilities, improve testability, and create a clean, maintainable backend architecture.

Backend DevelopmentDependency InjectionFastAPI
0 likes · 13 min read
Applying SOLID Principles and Design Patterns in FastAPI for Clean Architecture
21CTO
21CTO
Feb 16, 2025 · Artificial Intelligence

How to Deploy Your Own DeepSeek LLM Locally: Step-by-Step Guide

This guide walks you through setting up a local DeepSeek large language model, covering environment preparation, model acquisition, dependency installation, FastAPI service creation, Docker containerization, optional front‑end interface, performance tuning, and common troubleshooting steps.

AI modelDeepSeekDocker
0 likes · 7 min read
How to Deploy Your Own DeepSeek LLM Locally: Step-by-Step Guide
System Architect Go
System Architect Go
Nov 24, 2024 · Artificial Intelligence

Building a Web Voice Chatbot with Whisper, llama.cpp, and LLM

This article demonstrates how to build a web‑based voice chatbot by integrating Whisper speech‑to‑text, llama.cpp LLM inference, and WebSocket communication, detailing both the frontend JavaScript implementation and the Python FastAPI backend, along with Docker deployment and example code.

FastAPIJavaScriptLLM
0 likes · 10 min read
Building a Web Voice Chatbot with Whisper, llama.cpp, and LLM
JavaEdge
JavaEdge
Oct 15, 2024 · Artificial Intelligence

Build a Real‑Time Search & Bazi AI Agent with LangChain & FastAPI

This tutorial walks through creating a LangChain tool‑calling agent that combines a real‑time web search tool, a Qdrant vector store for local knowledge retrieval, and a custom Bazi fortune‑telling service, all wrapped in a FastAPI application for interactive use.

AI AgentFastAPILangChain
0 likes · 15 min read
Build a Real‑Time Search & Bazi AI Agent with LangChain & FastAPI
JavaEdge
JavaEdge
Oct 14, 2024 · Artificial Intelligence

Deploying LLMs with LangServe: A Complete Guide from Setup to Client Calls

This article introduces LangServe, explains its key features for LLM deployment, walks through environment setup, shows how to build a FastAPI‑based REST API with code examples, demonstrates testing via Postman and remote client calls, and summarizes its benefits for AI model serving.

AI model servingFastAPILLM deployment
0 likes · 9 min read
Deploying LLMs with LangServe: A Complete Guide from Setup to Client Calls
Python Programming Learning Circle
Python Programming Learning Circle
Aug 23, 2024 · Artificial Intelligence

Getting Started with Python Generative AI: Six Practical Projects Using Llama 2, LangChain, Streamlit, Gradio, FastAPI and SQL

This article presents six hands‑on Python generative‑AI projects—ranging from a Llama 2 chatbot built with Streamlit and Replicate to natural‑language‑to‑SQL conversion using LlamaIndex and SQLAlchemy—complete with environment setup, required code snippets, deployment tips and resource links for further exploration.

FastAPIGenerative AIGradio
0 likes · 20 min read
Getting Started with Python Generative AI: Six Practical Projects Using Llama 2, LangChain, Streamlit, Gradio, FastAPI and SQL
21CTO
21CTO
Jul 2, 2024 · Backend Development

FastAPI vs Flask: Why FastAPI Outperforms Flask for Modern APIs

This article compares FastAPI and Flask, highlighting FastAPI's speed, developer experience, and standards support, while providing practical migration guidance, code examples, configuration tips, async handling, dependency injection, testing, deployment, and documentation differences for Python web developers.

ASGIDependency InjectionFastAPI
0 likes · 25 min read
FastAPI vs Flask: Why FastAPI Outperforms Flask for Modern APIs
JavaEdge
JavaEdge
Jun 28, 2024 · Artificial Intelligence

Designing Agent Personality and Emotion Handling with LangChain Prompt Templates

This article explains how to craft system prompts that give an AI agent a distinct personality and emotional behavior, shows how to implement an emotion‑detection chain, compares ChatPromptTemplate.from_messages with from_template, and integrates the agent into a FastAPI service with full code examples.

AI AgentEmotion DetectionFastAPI
0 likes · 13 min read
Designing Agent Personality and Emotion Handling with LangChain Prompt Templates
JavaEdge
JavaEdge
Jun 27, 2024 · Backend Development

Build a FastAPI Chatbot with LangChain and WebSocket – Step‑by‑Step Guide

This tutorial walks through installing FastAPI and related packages, creating a basic FastAPI app, adding chat, PDF, and text endpoints, integrating LangChain tools for AI responses, implementing a WebSocket echo service, and running the server with uvicorn, all illustrated with code snippets and screenshots.

APIFastAPILangChain
0 likes · 8 min read
Build a FastAPI Chatbot with LangChain and WebSocket – Step‑by‑Step Guide
Python Programming Learning Circle
Python Programming Learning Circle
Apr 26, 2024 · Artificial Intelligence

Five Essential Python Libraries for Machine Learning Engineers

This article introduces five essential Python libraries—MLflow, Streamlit, FastAPI, XGBoost, and ELI5—that every junior or intermediate machine‑learning engineer and data scientist should master to streamline experiment tracking, build interactive web apps, deploy models efficiently, achieve fast accurate predictions, and improve model interpretability.

ELI5FastAPIMLflow
0 likes · 8 min read
Five Essential Python Libraries for Machine Learning Engineers
Liangxu Linux
Liangxu Linux
Mar 25, 2024 · Information Security

How to Use Gzip Compression to Overload Web Crawlers (Gzip Bomb Tutorial)

This guide shows how to create a tiny gzip‑compressed file, serve it with FastAPI, and exploit automatic decompression in Python's requests library to force a crawler to consume massive memory, effectively turning compression into a denial‑of‑service weapon.

Denial of ServiceFastAPIcompression
0 likes · 7 min read
How to Use Gzip Compression to Overload Web Crawlers (Gzip Bomb Tutorial)
DaTaobao Tech
DaTaobao Tech
Dec 27, 2023 · Artificial Intelligence

Deploying a Private LLM Knowledge Base on a MacBook

The guide walks through installing and quantizing the open‑source ChatGLM3‑6B model and the m3e‑base embedder on a MacBook, wrapping them with a FastAPI OpenAI‑compatible service, routing requests through a One‑API gateway, storing metadata in MongoDB and vectors in PostgreSQL pgvector, deploying FastGPT for RAG, ingesting data, and demonstrating 5‑7 second response times, while outlining future improvements.

ChatGLM3FastAPIKnowledge Base
0 likes · 23 min read
Deploying a Private LLM Knowledge Base on a MacBook
phodal
phodal
Aug 20, 2023 · Artificial Intelligence

How to Extend AutoDev with Custom LLMs and Prompt Actions

The article explains how to enhance the open‑source AutoDev coding assistant by configuring your own large language model, customizing IDE behavior, defining custom prompts and actions, and adjusting request/response handling via FastAPI, offering step‑by‑step JSON examples and guidance for advanced developers.

AutoDevFastAPIIDE integration
0 likes · 7 min read
How to Extend AutoDev with Custom LLMs and Prompt Actions
Python Programming Learning Circle
Python Programming Learning Circle
Aug 16, 2023 · Backend Development

Comprehensive List and Comparison of Python Web Frameworks

This article presents a curated collection of Python web frameworks, explains what a web framework is, outlines their purposes, and provides a ranked overview of each framework's official site, advantages, and disadvantages to help developers choose the most suitable option for their projects.

ComparisonDjangoFastAPI
0 likes · 23 min read
Comprehensive List and Comparison of Python Web Frameworks
MaGe Linux Operations
MaGe Linux Operations
Jul 17, 2023 · Backend Development

What Frameworks Shaped FastAPI? Lessons from Django, Flask, and More

This article explores the various Python frameworks and tools—Django, Django REST Framework, Flask, Requests, Swagger/OpenAPI, Marshmallow, Pydantic, Starlette, and Uvicorn—that inspired FastAPI, highlighting the features each contributed such as automatic documentation, micro‑framework flexibility, type‑hinted validation, and high‑performance async support.

APIFastAPIOpenAPI
0 likes · 10 min read
What Frameworks Shaped FastAPI? Lessons from Django, Flask, and More
Python Programming Learning Circle
Python Programming Learning Circle
Jul 27, 2022 · Backend Development

Comprehensive Overview of Python Web Frameworks

This article presents a detailed survey of over thirty Python web frameworks, describing their official sites, main features, advantages, and drawbacks, and offers guidance on selecting popular options such as Django, Flask, FastAPI, and many others for various development needs.

Backend DevelopmentDjangoFastAPI
0 likes · 20 min read
Comprehensive Overview of Python Web Frameworks
MaGe Linux Operations
MaGe Linux Operations
May 15, 2022 · Backend Development

Top 37 Python Web Frameworks: Features, Pros & Cons Explained

After two weeks of research, this guide presents a ranked list of 37 Python web frameworks—detailing their official sites, strengths, weaknesses, and visual overviews—to help developers choose the most supported and suitable framework for their projects.

Backend DevelopmentDjangoFastAPI
0 likes · 27 min read
Top 37 Python Web Frameworks: Features, Pros & Cons Explained
Programmer DD
Programmer DD
Jan 20, 2022 · Backend Development

Why FastAPI Is the Fastest Way to Build High‑Performance Python APIs

FastAPI is a high‑performance, easy‑to‑learn Python web framework that lets you build robust APIs quickly, offering features like speed, concise code, automatic validation, and OpenAPI compatibility, with simple installation via pip and interactive documentation out of the box.

ASGIBackend DevelopmentFastAPI
0 likes · 4 min read
Why FastAPI Is the Fastest Way to Build High‑Performance Python APIs
dbaplus Community
dbaplus Community
Jan 8, 2022 · Artificial Intelligence

How Ctrip Streamlined ML Model Development and Deployment with MLOps

This article explains how Ctrip tackled the long, costly ML model development‑to‑deployment pipeline by adopting and extending MLflow for full lifecycle management, covering model persistence, tracking, serving, custom pyfunc models, Dockerized deployment, scaling, and performance monitoring.

DockerFastAPIMLOps
0 likes · 14 min read
How Ctrip Streamlined ML Model Development and Deployment with MLOps
21CTO
21CTO
Feb 5, 2021 · Frontend Development

Boost Front‑End Prototyping with FakeAPI: Instant Mock Data Generation

This article introduces FakeAPI, a FastAPI‑based mock data service that lets front‑end developers quickly generate realistic JSON payloads, explains its endpoints, payload formats, repeat feature, and shows how to deploy it locally using Docker.

API mockDockerFake Data
0 likes · 4 min read
Boost Front‑End Prototyping with FakeAPI: Instant Mock Data Generation
Python Crawling & Data Mining
Python Crawling & Data Mining
Dec 25, 2020 · Backend Development

Mastering Python Rate Limiting: From ratelimiter to SlowAPI

This article explains how to control request frequency in Python using the ratelimiter library for synchronous and asynchronous code, and introduces SlowAPI as a flexible solution for FastAPI and Flask, helping backend developers reduce server load and protect APIs from abuse.

Backend DevelopmentFastAPIPython
0 likes · 6 min read
Mastering Python Rate Limiting: From ratelimiter to SlowAPI
Python Crawling & Data Mining
Python Crawling & Data Mining
Mar 26, 2020 · Backend Development

Master FastAPI: Build High‑Performance Python APIs Quickly

This article introduces FastAPI, a modern high‑performance Python web framework, walks through installation, basic routing, async handling, query and path parameters, data modeling with Pydantic, template rendering with Jinja2, and compares its speed to Flask, providing complete code examples and screenshots.

APIBackend DevelopmentFastAPI
0 likes · 10 min read
Master FastAPI: Build High‑Performance Python APIs Quickly