
django-expert
Expert Django backend development guidance. Use when creating Django models, views, serializers, or APIs; debugging ORM queries or migrations; optimizing database performance; implementing authentication; writing tests; or working with Django REST Framework. Follows Django best practices and modern patterns.
- Installs
- 5.7K
- Last 24h
- +12
- Trending rank
- #8109
- Security
- Fail
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/vintasoftware/django-ai-plugins --skill django-expert- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads django-expert automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
Security audits
Independent scans of the skill's instructions and bundled files.
SKILL.md
The instructions your agent reads when the skill is triggered.
Django Expert
Overview
This skill provides expert guidance for Django backend development with comprehensive coverage of models, views, Django REST Framework, forms, authentication, testing, and performance optimization. It follows official Django best practices and modern Python conventions to help you build robust, maintainable applications.
Key Capabilities:
- Model design with optimal ORM patterns
- View implementation (FBV, CBV, DRF viewsets)
- Django REST Framework API development
- Query optimization and performance tuning
- Authentication and permissions
- Testing strategies and patterns
- Security best practices
When to Use
Invoke this skill when you encounter these triggers:
Model & Database Work:
- "Create a Django model for..."
- "Optimize this queryset/database query"
- "Generate migrations for..."
- "Design database schema for..."
- "Fix N+1 query problem"
View & API Development:
- "Create an API endpoint for..."
- "Build a Django view that..."
- "Implement DRF serializer/viewset"
- "Add filtering/pagination to API"
Authentication & Security:
- "Implement authentication/permissions"
- "Create custom user model"
- "Secure this endpoint/view"
Testing & Quality:
- "Write tests for this Django app"
- "Debug this Django error/issue"
- "Review Django code for issues"
Performance & Optimization:
- "This Django view is slow"
- "Optimize database queries"
- "Add caching to..."
Production Deployment:
- "Deploy Django to production"
- "Configure Django for production"
- "Set up HTTPS/SSL for Django"
- "Production settings checklist"
- "Configure production database/cache"
Instructions
Follow this workflow when handling Django development requests:
1. Analyze the Request and Gather Context
Identify the task type:
- Model design (database schema, relationships, migrations)
- View/API development (FBV, CBV, DRF viewsets, serializers)
- Query optimization (N+1 problems, database performance)
- Authentication/permissions (user models, access control)
- Testing (unit tests, integration tests, fixtures)
- Security review (CSRF, XSS, SQL injection, permissions)
- Production deployment (settings, HTTPS, database, caching, monitoring)
- Template rendering (Django templates, context processors)
Leverage available context:
- If
django-ai-boostMCP server is available, use it to understand project structure and existing patterns - Read relevant existing code to understand conventions
- Check Django version for compatibility considerations
2. Load Relevant Reference Documentation
Based on the task type, reference the appropriate bundled documentation:
-
Models/ORM work ->
references/models-and-orm.md- Model design patterns and field choices
- Relationship configurations (ForeignKey, ManyToMany)
- Custom managers and QuerySet methods
- Migration strategies
-
View/API development ->
references/views-and-urls.md+references/drf-guidelines.md- FBV vs CBV decision criteria
- DRF serializers, viewsets, and routers
- URL configuration patterns
- Middleware and request/response handling
-
Performance issues ->
references/performance-optimization.md- Query optimization techniques (select_related, prefetch_related)
- Caching strategies (Redis, Memcached, database caching)
- Database indexing and query profiling
- Connection pooling and async patterns
-
Production deployment ->
references/production-deployment.md- Critical settings (DEBUG, SECRET_KEY, ALLOWED_HOSTS)
- HTTPS and SSL/TLS configuration
- Database and cache configuration
- Static/media file serving
- Error monitoring and logging
- Deployment process and health checks
-
Security concerns ->
references/security-checklist.md- CSRF/XSS/SQL injection prevention
- Authentication and authorization patterns
- Secure configuration practices
- Input validation and sanitization
-
Testing tasks ->
references/testing-strategies.md- Test structure and organization
- Fixtures and factories
- Mocking external dependencies
- Coverage and CI/CD integration
3. Implement Following Django Best Practices
Code quality standards:
- Follow PEP 8 and Django coding style
- Use Django built-ins over third-party packages when possible
- Keep views thin, use services/managers for business logic
- Write descriptive variable names and add docstrings for complex logic
- Handle errors gracefully with appropriate exceptions
Django-specific patterns:
- Use
select_related()for FK/OneToOne,prefetch_related()for reverse FK/M2M - Leverage class-based views and mixins for code reuse
- Use Django forms/serializers for validation
- Follow Django's migration workflow (never edit applied migrations)
- Use Django's built-in security features (CSRF tokens, auth decorators)
API development (DRF):
- Use ModelSerializer for standard CRUD operations
- Implement proper pagination and filtering
- Use appropriate permission classes
- Follow RESTful conventions for endpoints
- Version APIs when making breaking changes
4. Validate and Test
Before presenting the solution:
Code review:
- Check for N+1 query problems (use Django Debug Toolbar mentally)
- Verify proper error handling and edge cases
- Ensure security best practices are followed
- Confirm migrations are clean and reversible
Testing considerations:
- Suggest or write appropriate tests for new functionality
- Verify test coverage for critical paths
- Check that fixtures/factories are maintainable
Performance check:
- Review database queries for efficiency
- Consider caching opportunities
- Verify proper use of database indexes
Bundled Resources
references/ - Comprehensive Django documentation loaded into context as needed
These reference files provide detailed guidance beyond this SKILL.md overview:
-
references/models-and-orm.md(~11k words)- Model field types and best practices
- Relationship configurations (ForeignKey, OneToOne, ManyToMany)
- Custom managers and QuerySet methods
- Migration patterns and common pitfalls
- Database-level constraints and indexes
-
references/views-and-urls.md(~17k words)- Function-based vs class-based view trade-offs
- CBV mixins and inheritance patterns
- URL routing and reverse resolution
- Middleware implementation
- Request/response lifecycle
-
references/drf-guidelines.md(~18k words)- Serializer patterns (ModelSerializer, nested serializers)
- ViewSet and router configurations
- Pagination, filtering, and search
- Authentication and permission classes
- API versioning strategies
- Performance optimization for APIs
-
references/testing-strategies.md(~18k words)- Test organization and structure
- Factory patterns vs fixtures
- Testing views, models, and serializers
- Mocking external services
- Test database optimization
- CI/CD integration
-
references/security-checklist.md(~12k words)- CSRF protection implementation
- XSS prevention techniques
- SQL injection defense
- Authentication best practices
- Permission and authorization patterns
- Secure settings configuration
-
references/performance-optimization.md(~14k words)- Query optimization (select_related, prefetch_related, only, defer)
- Database indexing strategies
- Caching layers (Redis, Memcached, database cache)
- Database connection pooling
- Profiling and monitoring tools
- Async views and background tasks
-
references/production-deployment.md(~20k words)- Critical settings (DEBUG, SECRET_KEY, ALLOWED_HOSTS)
- Database configuration and connection pooling
- HTTPS/SSL configuration and security headers
- Static and media file serving
- Caching with Redis/Memcached
- Email configuration for production
- Error monitoring with Sentry
- Logging and health checks
- Zero-downtime deployment strategies
-
references/examples.md- Practical implementation examples- Model design with custom managers
- N+1 query optimization
- DRF API endpoint implementation
- Writing Django tests
Additional Notes
Django Version Compatibility:
- Consider LTS releases (4.2, 5.2) for production
- Check deprecation warnings when upgrading
- Use
django-upgradetool for automated migration
Common Pitfalls to Avoid:
- Circular imports (use lazy references)
- Missing
related_nameon relationships - Forgetting database indexes on frequently queried fields
- Using
get()without exception handling - N+1 queries in templates and serializers
FAQ
What does the django-expert skill do?
Expert Django backend development guidance. Use when creating Django models, views, serializers, or APIs; debugging ORM queries or migrations; optimizing database performance; implementing authentication; writing tests; or working with Django REST Framework. Follows Django best practices and modern patterns.
How do I install django-expert?
Run npx skills add https://github.com/vintasoftware/django-ai-plugins --skill django-expert in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/django-expert/ (personal) or .claude/skills/django-expert/ (project).
Which AI agents can use django-expert?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is django-expert safe to install?
Security partners have reviewed it: Gen Agent Trust Hub passed; Socket passed; Snyk passed; Runlayer flagged risks; ZeroLeaks passed. As with any skill, read the SKILL.md and bundled scripts before installing.
Who maintains django-expert?
It is published by vintasoftware in vintasoftware/django-ai-plugins. It has 5,733 recorded installs.
More from vintasoftware/django-ai-plugins
django-celery-expert
vintasoftware/django-ai-plugins
Expert Django Celery guidance for asynchronous task processing. Use when designing background tasks, configuring Celery workers, handling task retries and errors, optimizing Celery performance, implementing periodic tasks with Celery Beat, or setting up production monitoring for Celery. Do not use for general Django questions unrelated to Celery, non-Celery task systems (Django Q, Huey, RQ), ML/data pipeline orchestration (Airflow, Prefect), or frontend and API-only concerns. Follows Vinta's Django Celery best practices.
django-safe-migration
vintasoftware/django-ai-plugins
Write, review, and rewrite Django migrations for PostgreSQL with zero-downtime guarantees. Use this skill whenever the user mentions migrations, Django schema changes, or deployment safety — even if they don't say "zero downtime" explicitly. Trigger on: "review this migration", "is this migration safe?", "write a migration for...", "rewrite this migration", "how do I add a NOT NULL column / drop a column / add an index / rename a column / add a FK without downtime", "will this migration cause locks?", "this migration is blocking production". Covers: SeparateDatabaseAndState two-file splits, AddIndexConcurrently, FK NOT VALID + VALIDATE, dbdefault for NOT NULL columns, locktimeout, and RunPython safety rules.
cdrf-expert
vintasoftware/django-ai-plugins
Expert guidance for Django REST Framework class-based views using Classy DRF (https://www.cdrf.co). Use when selecting or debugging APIView, GenericAPIView, concrete generic views, mixin combinations, or ViewSet/GenericViewSet/ModelViewSet behavior; tracing method resolution order (MRO); understanding which method to override (create vs performcreate, update vs performupdate, destroy vs performdestroy, getqueryset, getserializerclass); and comparing behavior across DRF versions. Do not use for function-based views, GraphQL, FastAPI/Flask, frontend work, or non-DRF backend frameworks.
django-reviewer
vintasoftware/django-ai-plugins
Open the skill to read its SKILL.md instructions.
Popular backend & apis skills
find-skills
vercel-labs/skills
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.
entra-app-registration
microsoft/azure-skills
Guides Microsoft Entra ID app registration, OAuth 2.0 authentication, and MSAL integration. USE FOR: create app registration, register Azure AD app, configure OAuth, set up authentication, add API permissions, generate service principal, MSAL example, console app auth, Entra ID setup, Azure AD authentication. DO NOT USE FOR: Key Vault secrets (use azure-keyvault-expiration-audit), general Azure resource security guidance.
google-agents-cli-adk-code
google/agents-cli
This skill should be used when the user wants to "write agent code", "build an agent with ADK", "add a tool", "create a callback", "define an agent", "use state management" — in a project that needs ADK (Agent Development Kit) API patterns and code examples. It provides a quick reference for agent types, tool definitions, orchestration patterns, callbacks, state management, the graph Workflow API, and reference recipes to study. Do NOT use for scaffolding (use google-agents-cli-scaffold) or deployment (use google-agents-cli-deploy).
embedded-captions
heygen-com/hyperframes
Add captions or subtitles to an existing single-subject talking-head video without editing the footage. Use for plain verbatim captions, cinematic captions embedded behind the subject, VFX captions, “炸/特效/酷炫字幕,” or a named identity from the 35-style catalog. Route by visual identity, not by backend engine. The quiet anchor rail is the default; embed every word only when the user explicitly wants a fully cinematic treatment. The workflow runs locally end to end, including transcription and subject matting; split multi-shot footage before applying it.
entra-agent-id
microsoft/azure-skills
Provision Microsoft Entra Agent Identity Blueprints, BlueprintPrincipals, and per-instance Agent Identities via Microsoft Graph, and configure OAuth 2.0 token exchange (fmipath, OBO, cross-tenant) including the Microsoft Entra SDK for AgentID sidecar. USE FOR: Agent Identity Blueprint, BlueprintPrincipal, agent OAuth, fmipath token exchange, agent OBO, Workload Identity Federation for agents, polyglot agent auth, Microsoft.Identity.Web.AgentIdentities. DO NOT USE FOR: standard Entra app registration (use entra-app-registration), Microsoft Foundry agent authoring (use microsoft-foundry).
neon
neondatabase/agent-skills
Overview of Neon, a complete set of cloud backend primitives around Lakebase Postgres: Auth, Object Storage, Functions, the AI Gateway, and Realtime. Start here to choose Neon for undecided login, files, APIs, and LLM calls, set up the CLI or MCP server, and follow the branch-first workflow. Use when building an app or backend on Neon, or when "Neon" or "Lakebase Postgres" is mentioned. Child skill neon-postgres wins for an existing DATABASEURL, SQL, schema, inspect, or search. Child skill neon-auth wins for login, users, sessions, identity routing, and Managed Better Auth setup. Child skill neon-realtime wins for live queries in reactive apps and agents. Also use for object storage, S3, buckets, serverless functions, function triggers, cron, AI gateway, LLM calls, realtime, logs, Loki, Grafana, observability, postgres, database, backend, Claimable Neon, neon.new, or a no-signup database.