Skip to content

Gas City Doctrine Enforcement (v2.0) - Sessions perform work. (Sessions are disposable). - Beads remember work. (Durable universal substrate). - Convoys group work. - Mail coordinates work. - Formulas remember how. (Reusable methods). - Agents execute. - Packs configure. - Rigs scope. - Orders trigger. - Events prove what happened. - Work is not complete until verified and promoted (Capability, Skill, Formula, Pack, Order, Policy). (No parallel "learning lifecycles" or "agent memory" outside this machinery).

DRUPAL FACTORY MASTER PLAN

STATUS: WORKING / IN-PROGRESS ARCHITECTURE AUDIT

Evidence-backed execution plan covering the 48 active projects under blueflyio/agent-platform/drupal. Primary objective: OWN LESS, REUSE MORE, EXTEND MORE, CONFIGURE MORE, DELETE ONLY AFTER PROOF.

Freeze on destructive branches enacted. All projects default to INVESTIGATE pending rigorous overlap proofs against Drupal CMS 2.1 and stable contrib. This document is incomplete. 47/48 projects are marked INVESTIGATE. Factory boundaries and duplication audits are TBD.

1. Executive Summary

This document serves as the single evidence-backed Factory Master Plan for the blueflyio/agent-platform/drupal hierarchy. The goal is to aggressively reduce custom code by shifting to stable Drupal core and contrib modules, using configuration (recipes, ECA) instead of PHP, and maintaining strict factory boundaries. Destructive actions are frozen pending proven functional equivalence.

2. Current GitLab Inventory

  • Target Group: blueflyio/agent-platform/drupal
  • Total Discovered: 75
  • Active Projects: 48
  • Archived: 23
  • Marked for Deletion: 4

3. Drupal Core / CMS Baseline

Target baseline is Drupal 11.4 core + Drupal CMS 2.1 (for recipes, governance, accessibility, SEO, and basic security defaults).

4. Contrib-First Reference Architecture

Core components: ai, ai_agents, eca, tool_api, search_api. Custom implementations should map to these or provide thin wrappers where gaps exist.

5. Factory Ownership Boundaries

  • Gas City: Orchestration / Work Execution
  • Beads: Durable Work Graph
  • Dolt: Beads Persistence
  • Drupal: Human Governance / Content / Context / Application UI
  • ContextControl: Governed Context / Provenance
  • Agent Protocol: MCP / Tool Protocol
  • OSSA: Portable Agent Definitions
  • DUADP: Discovery
  • GitLab: Source / CI / Release
  • 1Password: Secret Authority

6. Complete Project Audit

Project Type Current Capability Core/Contrib/Recipe Alternative Proven Overlap Unique Value Disposition Custom Code Reduction Migration Risk Evidence
blueflyio/agent-platform/drupal/contrib-ready/ai_agents_ossa DRUPAL_MODULE Drupal module — OSSA agent framework. Core integration of the Open Standard for Software Agents protocol within Drupal's AI module ecosystem. TBD TBD OSSA integration into Drupal's AI ecosystem. INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/contrib-ready/ai_provider_apple DRUPAL_MODULE Drupal module — Apple Intelligence provider. Integrates Apple on-device AI models as providers within the Drupal AI module framework. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/contrib-ready/api_normalization DRUPAL_MODULE Drupal module — API normalization layer. Normalizes JSON:API and REST responses to consistent schemas for agent and frontend consumption. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/contrib-ready/dita_ccms DRUPAL_MODULE Drupal module — DITA content component management. Integrates DITA-compliant structured authoring and topic management within Drupal. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/contrib-ready/duadp_client DRUPAL_MODULE Drupal module — DUADP client. Publishes /.well-known/duadp.json, enables federation discovery, trust tier governance, and AI context bridge. drupal.org project: drupal/duadp. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/contrib-ready/ottermon DRUPAL_MODULE OtterMon for Drupal: Drupal-native assurance framework (checks, evidence, behaviors) that pushes snapshots and check results to OtterMon. TBD TBD Drupal-native assurance framework (checks, evidence, behaviors). INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/lab/drupaldolt LAB_EXPERIMENT TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/agent_api DRUPAL_MODULE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/agentdash_platform DRUPAL_MODULE Drupal module — AgentDash platform integration. Backend Drupal module providing API endpoints and data models for the AgentDash Node.js frontend. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/agentic_canvas_blocks DRUPAL_MODULE Drupal module — Agentic Canvas block library. Custom block types and layout components for the Agentic Canvas theme. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_agui DRUPAL_MODULE Building the a user-interface that is 100% built by agents, for AI Agents, using OSSA tools and @ag-ui/core TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_client DRUPAL_MODULE Drupal module — OSSA agent client. Provides the Drupal integration layer for executing OSSA-compliant agents from within Drupal sites. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_communication DRUPAL_MODULE Drupal module — agent communication channels. Provides email, SMS, and webhook output channels for AI agent responses within Drupal. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_kagent DRUPAL_MODULE Drupal module — Kagent provider. Integrates Kubernetes-native agents (kagent) as OSSA agents within the Drupal AI Agents framework. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_marketplace DRUPAL_MODULE Drupal module — agent marketplace consumer. Enables Drupal sites to discover and install agents from the platform marketplace registry. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_orchestra DRUPAL_MODULE Drupal module — Orchestra agent provider. Integrates multi-agent orchestration workflows as OSSA agents within Drupal. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/ai_agents_tunnel DRUPAL_MODULE Drupal module — agent tunnel. Provides secure tunneling for agent-to-Drupal callbacks and webhook delivery through the platform mesh. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/alternative_services DRUPAL_MODULE Drupal module — alternative service overrides. Provides service substitution patterns for overriding core and contrib Drupal services. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/blockchain_manager DRUPAL_MODULE Drupal module — blockchain manager. Manages on-chain agent identity, credential anchoring, and trust verification for platform agents. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/blu_fleet DRUPAL_MODULE Drupal module for agent fleet management within the Bluefly platform control plane. Handles agent registration, lifecycle tracking, and fleet state within the Drupal-native governance layer. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/cedar_policy DRUPAL_MODULE Drupal module — Cedar policy integration. Enforces attribute-based access control (ABAC) on Drupal entities and agent actions using Cedar policy definitions. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/charts_ai_analytics DRUPAL_MODULE WIP — AI analytics charts. Experimental charting and visualization components for agent performance metrics and platform analytics dashboards. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/code_executor DRUPAL_MODULE Drupal module — code execution sandbox. Provides secure code execution capabilities for AI agents operating within the Drupal platform. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/contractplane_client DRUPAL_MODULE Drupal module — ContractPlane API client. BlueFly-private cross-site module providing HTTP client and service layer for ContractPlane.ai API integration. Composer type: drupal-custom-module. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/copaw_bridge DRUPAL_MODULE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/dragonfly_client DRUPAL_MODULE Dragonfly client library — TypeScript/JavaScript SDK for integrating with the Dragonfly SaaS platform API. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/kb_cache DRUPAL_MODULE Drupal module — knowledge base cache (kb_cache). Sovereign AI memory layer: stores agent observations, tool outputs, and structured knowledge as Drupal nodes with ECA-driven lifecycle management. TBD TBD Sovereign AI memory layer for agent observations and tool outputs. INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/layout_system_converter DRUPAL_MODULE Drupal module — layout system converter. Migrates legacy Panels and Display Suite layouts to Drupal Layout Builder for agent platform sites. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/mcp_gateway DRUPAL_MODULE Drupal module — local MCP gateway/broker layer over contrib MCP primitives. Server connection registry, OAuth-scope hint inspection, capability metadata. No execution orchestration. (Renamed from mcp_registry.) TBD TBD Thin local gateway over contrib MCP primitives. No execution orchestration. INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/openclaw DRUPAL_MODULE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/playbook_engine DRUPAL_MODULE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/recipe_onboarding DRUPAL_MODULE Drupal recipe — platform onboarding. Installs and configures the base set of modules and settings for new agent platform Drupal sites. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/simple_age_gate DRUPAL_MODULE Drupal module — simple age gate. Lightweight age verification gate for Drupal sites requiring age-restricted content controls. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/private/skills_browser DRUPAL_MODULE Drupal module — skills browser. Provides a Drupal admin UI for discovering, previewing, and installing agent skills from the platform registry. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_agent_platform DRUPAL_RECIPE Drupal recipe — full agent platform stack. Meta-recipe that installs the complete agent platform module suite on a Drupal site. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_ai_marketplace DRUPAL_RECIPE Drupal recipe — AI marketplace setup. Configures the full AI marketplace module stack, content types, and views for marketplace-enabled sites. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_amcs DRUPAL_RECIPE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_blucity DRUPAL_RECIPE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_contextual_memory DRUPAL_RECIPE Drupal recipe — contextual memory. Installs kb_cache, ECA workflows, and taxonomy configuration for AI Bead state on Drupal sites. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_contractplane_intent DRUPAL_RECIPE Captures Drupal entity actions and pipes them to ContractPlane as intents via ECA, without custom code TBD No overlap. ECA configuration only. Entity action to ContractPlane intent mapping via ECA without custom code. KEEP TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_digital_service_baseline DRUPAL_RECIPE Drupal recipe — Digital Service Baseline. Provides a governed CMS foundation aligned to accessibility, privacy, content governance, search, analytics, and federal design expectations for regulated service organizations. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_ottermon_baseline DRUPAL_RECIPE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/recipes/recipe_secure_drupal DRUPAL_RECIPE Drupal recipe — secure Drupal baseline. Applies security hardening, content security policies, and permission defaults to new Drupal installations. TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/site-templates/amcs/amcs-demo SITE_TEMPLATE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/site-templates/amcs/site_template_amcs SITE_TEMPLATE TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/themes/agentic_canvas_theme DRUPAL_THEME Drupal theme engine — Agentic Canvas. Base theme for Drupal sites in the agent platform ecosystem. Built on Radix with agent-aware layout regions AND AGUI integration TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/themes/bluefly_theme DRUPAL_THEME Bluefly.io marketing theme — Satoshi typography, Figma-synced SDC tokens. Composer package: drupal/bluefly_theme TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
blueflyio/agent-platform/drupal/themes/contextcontrol_theme DRUPAL_THEME TBD TBD TBD INVESTIGATE TBD TBD Pending source inspection
## 7. Contrib-Ready Audit
Pending full repository clone and file-by-file inspection.

8. Private Module Audit

Pending full repository clone and file-by-file inspection.

9. Recipe Audit

Pending configuration diff against official drupal_cms recipes.

10. Site Template Audit

Includes site_template_amcs and amcs-demo. Pending composer.json inspection. amcs-demo is a pic, test of the site_template, not to be edited, we regenerate this locally to test the template.

11. Theme Audit

Pending template and asset inspection.

12. Lab Audit

Pending inspection of experimental code bounds.

13. Cross-Project Duplication

To be mapped after codebase parsing. E.g., verifying if execution orchestration is accidentally duplicated across modules.

14. Recipe / Config Migration Opportunities

To be determined. E.g., hardcoded logic -> ECA; config defaults -> Recipes.

15. Upstream Contribution Candidates

Modules with generic capabilities (not Bluefly-specific) will be identified for contribution.

16. Factory Boundary Violations

Flagging any Drupal module that attempts to act as CI/CD orchestrator, secret store, or generic task persistence layer.

17. Existing Candidate Patch Safety Review

The following destructive branches have been frozen and treated as CANDIDATE PATCHES ONLY: - duadp_client (branch=feat/registry-cull-jsonapi) - ai_provider_apple (branch=chore/provider-consolidation-phase2) - ai_agents_ossa (branch=chore/ossa-eca-shift)

DISPOSITION: HOLD_OR_ABANDON_CANDIDATE_PATCH. Safety unproven.

18. Master Reduction Roadmap

WAVE 0 — Stop/recover unsafe changes (Completed: Frozen branches). WAVES 1-5 pending evidence gathering.

19. Bead Execution Plan

Implementation Beads will only be created when the audit proves actionable work (e.g., exact PHP to remove, exact capability replacement). No "refactor entire repo" Beads allowed.

20. Acceptance Criteria

All tech-debt Beads must merge cleanly to release/v0.1.x, pass tests, and satisfy the proven migration path.