qmetrics.net

Django Polymorphic

Django ORM extension for polymorphic model inheritance

Frameworks & PlatformsDesktop/CLI app
Django Polymorphic screenshot

Extends Django model inheritance so base-model queries return concrete subclass instances instead of the parent type.

Overview

Django Polymorphic builds on standard Django model inheritance and makes working with subclassed models more natural. When you query at the base model level, results come back as the actual inherited model classes rather than only the parent class, which vanilla Django often returns.

The package integrates with the Django admin, ORM relations such as foreign keys, many-to-many fields, and one-to-one fields, and supports filtering and ordering on inherited fields. You can filter by concrete types using instanceof-style helpers, union querysets from different models, use custom managers, and turn polymorphic behavior off when needed.

Formsets, proxy models, and optional integrations with projects such as django-guardian, django-extra-views, django-reversion, and model-bakery appear in the documentation. Each subclass may require extra joins when fetching data, which the authors note as a performance consideration.

Compared with plain Django inheritance, the focus is automatic downcasting and type-aware querying so applications that model several subtypes under one base can load and administer them as their real types.

Key features

  • Admin integration for polymorphic models
  • ORM support for FK, M2M, and O2O
  • instanceof and notinstanceof filtering
  • Combine querysets from different models
  • Custom user-defined managers
  • Minimal queries for inherited rows
  • Optional non-polymorphic queries
  • Formset and proxy model support

Use cases

  • Multiple project subtypes under one base model
  • Admin lists showing real subclass instances
  • Filtering queryset results by concrete model type
  • Relations that resolve to polymorphic targets

Tags

Similar software

ECC

Open-source agent engineering toolkit for coding harnesses

ECC adds planning, verification, review, memory, skills, and security scanning to coding agents such as Claude Code, Codex, and Cursor. It installs as plugins, packages, and managed adapters across multiple harnesses.

★ 311.7k⟳ 8 days agoMIT
Frameworks & PlatformsDesktop/CLI app

React

JavaScript library for web and native user interfaces

React helps developers build interfaces from reusable components that manage their own state. Views update declaratively when underlying data changes.

★ 253k⟳ 2 days agoMIT
Frameworks & PlatformsDesktop/CLI app

Flutter

Open-source UI framework for multi-platform apps from one codebase

Flutter is an SDK for building user experiences for mobile, web, and desktop from a single codebase. It uses the Dart language and compiles to native machine code or web targets.

★ 181.5k⟳ todayBSD-3-Clause
Open Source Alternative to:Ionic Enterprise

Bootstrap

Responsive HTML, CSS, and JavaScript front-end toolkit

Bootstrap supplies CSS, JavaScript, and Sass-based styles for building responsive, mobile-first sites. It ships prebuilt grid layouts, UI components, and optional JavaScript plugins.

★ 175.1k⟳ 2 days agoMIT

Langflow

Visual low-code builder for AI agents and workflows

Langflow is a visual builder for AI agents and workflows. Flows can be customized in Python and deployed as an API or as an MCP server, with support for major LLMs and vector databases.

★ 157k⟳ todayMIT
Open Source Alternative to:Relevance AIVoiceflow

LangChain

Framework for agents and LLM-powered applications

LangChain helps developers chain interoperable components and integrations to build agents and LLM-powered applications. It offers a standard interface for models, embeddings, vector stores, and related pieces.

★ 150.1k⟳ 2 days agoMIT