Skip to main content
prompt GP ChatGPT

Django Web App taste — ChatGPT prompt for Django

The Django Web App taste prompt for ChatGPT sets Python and Django coding preferences. It covers project structure, APIs, tests, and deployment settings.

CC0-1.0 ★ 178,201 updated 2026-10-24

Open on GitHub

What Django Web App taste does

The prompt sets conventions for Django projects: begin with a custom AbstractUser model, separate settings by environment, and keep business logic in service functions or model methods. It favors generic views for CRUD and Django REST Framework or django-ninja for APIs with explicit schemas.

Other guidelines cover database queries and constraints, background jobs, and tests with pytest-django and factory_boy. Multi-step writes use transaction.atomic; queued jobs should have explicit retries. A migration that has already run in production must not be edited.

For deployment, the prompt calls for DEBUG=False, a configured ALLOWED_HOSTS, and a passing python manage.py check --deploy in CI. It also names Ruff, mypy, and django-stubs, plus WhiteNoise or a CDN for static files and object storage for user uploads.

What it helps with

  • set conventions for a new Django project
  • keep business logic out of views and signals
  • choose an API, testing, and background-job approach
  • check Django deployment settings

Example prompts for the agent

  • Set up a Django project with a custom user model and environment-specific settings.
  • Design a Django REST Framework API with explicit serializers and tests.
  • Review these Django deployment settings and suggest changes.

How to install Django Web App taste

How to use

Paste the text at the start of a chat or into project instructions

Questions about Django Web App taste

How do I install Django Web App taste in Claude Code?

Add the prompt file at .claude/commands/prompts.csv.md. In ChatGPT, provide the prompt in a message.

What does Django Web App taste do?

It sets Django development conventions for project structure, database access, APIs, tests, and deployment.

Which testing tools does Django Web App taste recommend?

It names pytest-django and factory_boy for tests. Query counts can be checked with django-debug-toolbar or assertNumQueries.

Source text

prompts.csv · CC0-1.0
# Django Web App taste of a Python backend engineer
- Start every project with a custom user model (AbstractUser) even if it adds no fields yet. Confidence: 0.95
- Split settings by environment and read secrets and URLs from environment variables with django-environ or similar. Confidence: 0.90
- Keep apps small and domain-focused; an app that imports half the project is a sign it should be split or merged. Confidence: 0.75
- Put business logic in plain service functions or model methods, not in views, serializers or signals. Confidence: 0.85
- Avoid signals for core workflows; call the side effect explicitly so the flow is readable and testable. Confidence: 0.85
- Use select_related and prefetch_related deliberately and check query counts with django-debug-toolbar or assertNumQueries. Confidence: 0.90
- Add database constraints (UniqueConstraint, CheckConstraint) instead of relying only on form or serializer validation. Confidence: 0.90
- Review every generated migration before committing and never edit a migration that has already run in production. Confidence: 0.90
- Write data migrations with RunPython using apps.get_model, never importing models directly. Confidence: 0.85
- Prefer class-based generic views for CRUD and function views for anything with unusual control flow. Confidence: 0.70
- Use Django REST Framework or django-ninja for APIs, with explicit serializers or schemas rather than fields = "__all__". Confidence: 0.85
- Wrap multi-step writes in transaction.atomic and enqueue background jobs with transaction.on_commit. Confidence: 0.90
- Run slow or external work in Celery or another task queue, with idempotent tasks and explicit retries. Confidence: 0.85
- Write tests with pytest-django and factory_boy instead of fixtures checked in as JSON. Confidence: 0.85
- Keep the admin for staff operations; customize list_display, search_fields and list_select_related so it stays fast. Confidence: 0.80
- Serve static files with WhiteNoise or a CDN and user uploads from object storage, never from the app server disk. Confidence: 0.85
- Run behind gunicorn or uvicorn with DEBUG=False, ALLOWED_HOSTS set and python manage.py check --deploy passing in CI. Confidence: 0.95
- Use HTMX with server-rendered templates before reaching for a separate SPA. Confidence: 0.65
- Pin dependencies with a lock file and upgrade Django LTS releases on a schedule. Confidence: 0.80
- Lint and format with Ruff and type check with mypy plus django-stubs. Confidence: 0.75

© f · CC0-1.0 · f/prompts.chat

Similar prompts

All prompts for Backend and APIs →

From the same set218

The whole set →
LLM Application taste The LLM Application taste prompt for ChatGPT lays out engineering practices for applications built with language models. It covers prompt evaluation, tool use, and handling untrusted input. GP ChatGPT ★ 178,201repo stars FastAPI Service taste FastAPI Service taste — a prompt for ChatGPT and Claude.ai that enforces backend engineering standards for FastAPI. Sets architectural conventions before generating API code. GP ChatGPT ★ 178,201repo stars Jetpack Compose Android App taste The Jetpack Compose Android App taste ChatGPT prompt sets Kotlin and Compose conventions for Android app development. It covers screen architecture, UI state, testing, and builds. GP ChatGPT ★ 178,201repo stars Data Pipeline taste Data Pipeline taste — a prompt for ChatGPT and Claude.ai establishes data engineering rules for reliable pipeline design. Guides warehouse modeling around ELT principles and strict schema separation. GP ChatGPT ★ 178,201repo stars Python Auto Typer with Customizable Delay The Python Auto Typer with Customizable Delay prompt creates a Python desktop application for automatic text typing with a configurable delay. It enables the development of a GUI tool that compiles into a Windows executable. GP ChatGPT ★ 178,201repo stars SwiftUI iOS App taste SwiftUI iOS App taste — a set of rules for SwiftUI work: how to build screens, where state lives and which APIs to drop. Useful when an agent writes fresh iOS code. GP ChatGPT ★ 178,201repo stars Event-Driven Architecture taste Event-Driven Architecture taste sets architectural guidelines for distributed systems: past-tense domain events, transactional outbox patterns, idempotent consumers, and sagas over two-phase commits. GP ChatGPT ★ 178,201repo stars Code Review taste The Code Review taste prompt sets practical review standards for pull requests, from checking correctness to labeling comments by severity. Use it when you want a consistent review checklist. GP ChatGPT ★ 178,201repo stars

Project sponsors

Companies that keep this analytics open