AI Collaboration Methods for DDSE v1.1 TDR Creation

This guide outlines systematic approaches for collaborating with AI tools to create Technical Decision Records that comply with TDR specifications


---

## MDD Collaboration Framework - Major Design Decisions
{: #mdd-framework}

Major Design Decisions require strategic stakeholder alignment and cross-system impact analysis. This framework guides systematic MDD development with AI-assisted analysis.

### Major Decision Scope

**MDDs address:**
- Product strategy and technology stack selection
- System-wide architectural patterns and constraints
- Business-critical technical trade-offs and risk assessments
- Long-term technology evolution and migration strategies

### AI Collaboration Approach for MDDs

```yaml
# Strategic Decision Context

decision_scope: "enterprise_wide"
stakeholder_alignment: "required"
impact_assessment: "comprehensive"
ai_analysis_focus:
  - "Technology landscape evaluation"
  - "Risk assessment and mitigation strategies"
  - "Cost-benefit analysis with quantitative modeling"
  - "Implementation roadmap and timeline estimation"

Access MDD Template →


EDR Collaboration Framework - Engineering Decisions

Engineering Decision Records establish development practices, tools, and cross-cutting methodologies that affect team workflow and code quality.

Engineering Decision Scope

EDRs address:

  • Development workflow and tooling standardization
  • Testing strategies and quality assurance practices
  • Deployment pipelines and environment management
  • Code review processes and development standards

AI Collaboration Approach for EDRs

# Engineering Practice Context

practice_scope: "team_wide"
implementation_impact: "workflow_change"
ai_guidance_focus:
  - "Best practice research and analysis"
  - "Tool configuration and setup automation"
  - "Process documentation and guidelines"
  - "Metrics and success criteria definition"

Access EDR Template →


TDM Collaboration Framework - Technical Decision Memos

Technical Decision Memos provide lightweight documentation for tactical decisions with limited scope and clear expiration or review timelines.

Technical Memo Scope

TDMs address:

  • Temporary implementation approaches and workarounds
  • Experimental parameters and proof-of-concept configurations
  • Time-bound tactical decisions with planned review dates
  • Quick resolution documentation for recurring technical questions

AI Collaboration Approach for TDMs

# Tactical Decision Context

decision_urgency: "immediate"
scope_limitation: "well_defined"
review_schedule: "required"
ai_assistance_focus:
  - "Rapid research and option evaluation"
  - "Implementation guidance for temporary solutions"
  - "Risk assessment for tactical approaches"
  - "Clear documentation for future review"

Access TDM Template →DSE v1.1 methodology. The approach leverages AI’s natural language processing capabilities while ensuring adherence to DDSE specifications, including the new Contract Decision Records (CDRs) and Greenfield Architecture Pattern.

Methodological Overview

AI-Human Collaboration Framework

Effective TDR creation with AI tools requires a structured approach that combines human domain expertise with AI’s pattern recognition and generation capabilities. This collaboration follows a systematic process optimized for DDSE v1.1 features:

Key v1.1 Enhancements:

  • Contract-Driven Development: CDRs enable parallel frontend/backend development through AI-generated mock services
  • Greenfield Architecture Pattern: Systematic 3-phase approach for new project decision governance
  • Enhanced AI Context: Improved integration specifications with contract validation and traceability
  • Decision-to-Implementation Traceability: Required code annotations linking implementations to TDRs

TDR Type Selection Framework

Decision Classification Matrix:


IDR Collaboration Framework - Implementation Decisions

Implementation Decision Records represent the most frequent type of technical decision documentation. This section outlines the systematic approach to collaborating with AI tools for IDR creation.

Phase 1: Context Preparation

Prepare the necessary context for AI collaboration by assembling:

---
decision_id: "idr-001"  # Sequential identifier within project scope
title: ""               # Concise decision statement
status: "proposed"      # Current decision state in lifecycle
decision_type: "implementation"
created: "2025-01-27"
author: ""              # Decision authority or team identifier
---

Common IDR Categories:

  • API design patterns and validation strategies
  • Error handling and exception management approaches
  • Data access patterns and query organization methods
  • Testing strategies and file organization conventions

Phase 2: Decision Context Development

Structure the decision context for AI understanding:

# Decision Context

## Current State Analysis
- Existing implementation patterns and their limitations
- Identified problems or inefficiencies in current approach
- Technical debt or maintenance challenges

## Decision Drivers
- Technical requirements driving the need for standardization
- Constraints imposed by existing system architecture
- Team capabilities and knowledge requirements

Phase 3: Collaborative Decision Documentation

Work with AI to document the decision outcome:

# Decision Outcome

[Clearly state the decided approach]

## Selected Implementation Pattern
**Pattern: [Name and brief description]**

### Technical Specifications
- Specific technologies, libraries, or frameworks to utilize
- Implementation steps and integration requirements
- Code organization and structural requirements

## Impact Assessment

### Benefits
- Problems resolved by this implementation approach
- Improvements in maintainability, performance, or developer experience
- Alignment with broader architectural decisions

### Trade-offs
- Technical limitations or constraints introduced
- Additional complexity or learning requirements
- Migration effort for existing implementations

Phase 4: AI Integration Specifications

Define how AI tools should interpret and implement the decision:

# AI Context

## Implementation Guidance
Priority order: [First implement X, then Y, finally Z]
Required patterns: [Specific coding patterns to follow]
Preferred libraries: [Recommended tools and frameworks]

## Constraint Framework
MUST requirements: [Non-negotiable implementation rules]
SHOULD preferences: [Strong recommendations for consistency]  
AVOID patterns: [Deprecated or problematic approaches]

## Traceability Requirements ⭐ *New in v1.1*
decision_references: "All implementing code MUST include @implements IDR-XXX annotations"
code_annotations: "Use /* @implements IDR-XXX: Decision Title */ in implementation files"
validation_rules: "CI/CD pipeline MUST validate decision reference compliance"

## Reference Examples
[Include code snippets demonstrating preferred patterns]

Phase 5: Documentation Integration

# Related Decisions
- [Links to dependent or related TDRs]
- [Architectural decisions that inform this implementation]
- [Previous decisions this supersedes or modifies]

# External References
- [Relevant documentation, standards, or research]
- [Framework documentation or best practice guides]
- [Performance benchmarks or comparative analysis]

Access IDR Template →


ADR Collaboration Framework - Architectural Decisions

Architectural Decision Records require more comprehensive analysis and stakeholder consideration. This framework guides systematic ADR development with AI assistance.

Architectural Decision Scope

ADRs address:

  • Technology platform selection (databases, frameworks, programming languages)
  • System architecture patterns and structural decisions
  • Integration strategies and communication protocols
  • Cross-cutting technical concerns affecting multiple system components

AI Collaboration Approach for ADRs

## Options Analysis Framework

### Option 1: [Technology/Architectural Approach A]
- **Technical Benefits:** Performance, scalability, maintainability advantages
- **Implementation Challenges:** Complexity, learning curve, integration requirements
- **Operational Impact:** Deployment, monitoring, and maintenance considerations

### Option 2: [Technology/Architectural Approach B]  
- **Technical Benefits:** Alternative advantages and different optimization focus
- **Implementation Challenges:** Different complexity and resource requirements
- **Operational Impact:** Alternative operational considerations

## Decision Criteria Matrix
- Performance and scalability requirements analysis
- Team technical expertise and learning requirements
- Operational complexity and maintenance burden assessment
- Long-term strategic alignment and flexibility considerations

Access ADR Template →


CDR Collaboration Framework - Contract Decision Records ⭐ New in v1.1

Contract Decision Records represent the most crucial addition in DDSE v1.1, enabling contract-driven development and parallel team collaboration. CDRs define implementable specifications for service boundaries and API contracts.

Contract Decision Scope

CDRs address:

  • REST API specifications with OpenAPI 3.0 schemas
  • GraphQL schemas and resolver contracts
  • Message queue formats and event schemas
  • Database interface contracts and data access patterns
  • Service integration protocols and authentication requirements

AI Collaboration Approach for CDRs

# Contract Context Preparation

contract_type: "REST API"
implementation_priorities:
  - "OpenAPI 3.0 specification compliance"
  - "Backward compatibility during evolution"
  - "Clear error handling and status codes"
validation_rules:
  - "All endpoints must have proper HTTP status codes"
  - "Request/response schemas must be validated"
  - "API versioning strategy must be followed"
framework_hints:
  backend: "Express.js with TypeScript"
  frontend: "React with TypeScript"
  testing: "Jest with supertest for API testing"
traceability_requirements: ⭐ *New in v1.1*
  code_annotations: "@implements CDR-XXX: Contract Title"
  contract_validation: "All endpoints MUST match OpenAPI specification"
  mock_service_generation: "AI tools MUST generate mocks from contract specs"

Contract Specification Framework

## Contract Specification

### API Endpoints

#### POST /api/users
```yaml
openapi: 3.0.0
paths:
  '/api/users':
    post:
      summary: Create new user account
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required: [email, password]
              properties:
                email:
                  type: string
                  format: email
                password:
                  type: string
                  minLength: 8
      responses:
        '201':
          description: User created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/User'
        '400':
          description: Invalid input data
        '409':
          description: User already exists

AI Integration Specifications

# AI Context for Contract Implementation

## Mock Service Generation
generate_mocks: true
mock_data_strategy: "realistic_faker_data"
response_delays: "100-300ms"

## Contract Validation
validate_requests: true
enforce_schemas: true
contract_testing: "consumer_driven"

## Parallel Development Enablement
frontend_development: "independent_with_mocks"
backend_development: "contract_first_implementation"
integration_testing: "contract_compliance_required"

Contract Evolution Management

## Contract Evolution Strategy

### Versioning Approach
- **Semantic Versioning**: Major.Minor.Patch for API versions
- **Backward Compatibility**: Maintain compatibility for minor versions
- **Breaking Changes**: Require major version increment

### Migration Process
- **Deprecation Notice**: 3 release cycles minimum
- **Sunset Timeline**: 12 months for major version support
- **Client Migration**: Automated migration tools where possible

Access CDR Template →


Systematic TDR Development Approaches

Rapid Documentation Method (Implementation Focus)

For immediate implementation needs:

  1. Decision Identification: Clearly articulate the specific implementation question
  2. Template Selection: Choose IDR framework for implementation-level decisions
  3. Essential Documentation: Focus on context, outcome, and AI guidance sections
  4. Validation Process: Verify against DDSE specification requirements
  5. Integration: Incorporate into team repository and reference in code

Comprehensive Analysis Method (Architectural Focus)

For significant architectural decisions:

  1. Decision Scope Definition: Determine architectural impact and stakeholder involvement
  2. Context Gathering: Collect requirements, constraints, and alternative approaches
  3. Systematic Documentation: Complete analysis including multiple options and trade-offs
  4. AI Integration Planning: Define specific guidance for AI tool implementation
  5. Relationship Mapping: Connect to related decisions and establish dependencies
  6. Review and Validation: Team review and alignment before implementation

Enterprise Integration Method (Organizational Focus)

For organization-wide implementation:

  1. Stakeholder Alignment: Ensure appropriate decision authority and approval processes
  2. Risk Assessment: Analyze implementation, operational, and strategic risks
  3. Approval Workflow: Establish required reviews and organizational sign-offs
  4. Implementation Strategy: Define rollout approach and timeline
  5. Success Metrics: Establish evaluation criteria for decision effectiveness

Greenfield Architecture Pattern ⭐ New in v1.1

The Greenfield Architecture Pattern provides a systematic 3-phase approach for establishing comprehensive decision governance in new projects from day one, optimized for AI-assisted development.

Phase 1: Decision Foundation

Objective: Establish complete architectural decision hierarchy before implementation begins.

# Phase 1 AI Collaboration Context

focus: "architectural_foundation"
deliverables:
  - "Complete MDD hierarchy for product strategy"
  - "System ADRs for architecture style and major components"  
  - "EDRs for development workflow and practices"
ai_guidance:
  priority: "decision_completeness_over_implementation_speed"
  validation: "architectural_coherence_check"
  output: "structured_decision_hierarchy"

AI Collaboration Approach:

  1. Strategic Analysis: Use AI to analyze business requirements and generate MDD options
  2. Architecture Exploration: Collaborate with AI to explore architectural patterns and trade-offs
  3. Practice Definition: Establish development practices and tooling decisions with AI assistance

Phase 2: Contract Definition

Objective: Create implementable contracts that enable parallel development across teams.

# Phase 2 AI Collaboration Context

focus: "contract_driven_enablement"
deliverables:
  - "CDRs for all service boundaries and APIs"
  - "Data schemas and integration contracts"
  - "Mock implementations for frontend development"
ai_guidance:
  priority: "contract_completeness_and_implementability"
  validation: "openapi_schema_compliance"
  output: "executable_service_contracts"

Contract-First Development:

  1. API Design: Collaborate with AI to design OpenAPI specifications
  2. Mock Generation: Use AI to generate realistic mock services from contracts
  3. Validation Setup: Establish contract testing with AI-generated test scenarios

Phase 3: Parallel Development Enablement

Objective: Enable simultaneous frontend/backend development with minimal team dependencies.

# Phase 3 AI Collaboration Context

focus: "parallel_implementation"
deliverables:
  - "Mock services running with realistic data"
  - "Contract validation and testing frameworks"
  - "Implementation IDRs with AI context"
ai_guidance:
  priority: "contract_compliance_and_team_velocity"
  validation: "implementation_contract_alignment"
  output: "production_ready_implementations"

Implementation Strategy:

  • Frontend Teams: Develop against mock services with AI-generated realistic data
  • Backend Teams: Implement contract specifications with AI-assisted validation
  • Integration Testing: Use AI to generate comprehensive contract compliance tests

Greenfield Success Metrics

  • Decision Coverage: 100% of architectural concerns addressed in decision hierarchy
  • Contract Completeness: Full API contract coverage for all service boundaries
  • Parallel Efficiency: High team velocity with minimal cross-team blocking
  • AI Integration: Effective AI-assisted development with contract validation

Decision-to-Implementation Traceability ⭐ New in v1.1

DDSE v1.1 requires explicit traceability between TDRs and implementation code through standardized annotations and validation mechanisms.

Traceability Annotation Framework

Implementation Decision References

/**
 * @implements IDR-005: Error Handling Patterns
 * @see tdr/idr/idr-005-error-handling-patterns.md
 * User authentication service following standardized error patterns
 */
export class AuthService {
  // Implementation follows IDR-005 specifications
}

Contract Implementation References

/**
 * @implements CDR-001: User Management API Contract
 * @contract GET /api/v1/users/{id}
 * @see tdr/cdr/cdr-001-user-management-api.md
 */
export async function getUserById(id: string): Promise<UserResponse> {
  // Implementation must match CDR-001 OpenAPI specification
}

Architectural Decision Implementation

/**
 * @implements ADR-003: JWT Authentication Strategy
 * @implements EDR-002: Repository Pattern Implementation
 * @see tdr/adr/adr-003-jwt-authentication.md
 */
export class UserRepository {
  // Implementation follows ADR-003 and EDR-002 specifications
}

AI-Assisted Traceability

Automated Annotation Generation

AI tools SHOULD automatically generate traceability annotations when implementing TDR specifications:

# AI Context for Traceability
generate_annotations: true
annotation_format: "@implements {TDR-ID}: {TDR-Title}"
validation_level: "strict"  # Enforce exact TDR reference compliance
link_validation: true       # Verify @see references point to existing files

Traceability Validation

// AI validation checks during code generation
/**
 * Validates that implementation aligns with referenced TDR
 * @param code Generated implementation code
 * @param tdrReference Referenced TDR identifier
 * @returns Compliance validation results
 */
export function validateTDRCompliance(
  code: string, 
  tdrReference: string
): ComplianceResult {
  // AI validates implementation against TDR specifications
}

AI Collaboration Quality Criteria ⭐ Enhanced in v1.1

Effective AI Context Characteristics

When working with AI tools for TDR implementation in v1.1:

  • Contract Specificity: Provide complete OpenAPI specifications and schema definitions rather than general API guidance
  • Traceability Requirements: Include decision references that AI tools can embed in generated code annotations
  • Validation Rules: Define specific contract compliance rules that AI can verify during implementation
  • Implementation Sequence: Establish clear dependency order for parallel development coordination
  • Mock Service Enablement: Specify realistic data generation requirements for contract-driven development

AI Integration Assessment

Evaluate AI collaboration effectiveness by:

  • Contract Compliance: Does AI output strictly adhere to CDR specifications and OpenAPI schemas?
  • Traceability Integration: Does AI-generated code include proper decision reference annotations?
  • Mock Service Quality: Do AI-generated mocks enable effective frontend development without backend dependencies?
  • Validation Coverage: Does AI implementation include comprehensive contract testing and validation?
  • Evolution Support: Can AI tools properly handle contract versioning and backward compatibility requirements?

Contract-Driven AI Development ⭐ New in v1.1

Mock Service Generation

AI tools SHOULD:

  • Generate realistic mock data based on OpenAPI schemas
  • Implement proper HTTP status codes and error responses
  • Maintain consistency with contract specifications
  • Enable immediate frontend development without backend blocking

Contract Validation

AI assistants MUST:

  • Validate generated code against CDR contract specifications
  • Flag contract violations during implementation
  • Suggest contract-compliant alternatives for invalid patterns
  • Maintain traceability links to relevant CDRs in code annotations

Methodological Best Practices ⭐ Enhanced in v1.1

Documentation Principles

  • Decision Focus: Document the decision itself, not implementation tutorials
  • Contract Specifications: Include complete, implementable API contracts in CDRs
  • Clear Outcomes: Ensure unambiguous decision statements and rationale
  • Contextual Clarity: Provide sufficient background for future reference and AI assistance
  • AI Integration: Include specific guidance for AI tool utilization with contract validation
  • Traceability Requirements: Define decision reference patterns for code annotations
  • Relationship Management: Connect decisions through explicit dependencies and contract relationships

Contract-Driven Development Practices ⭐ New in v1.1

  • Contract-First Design: Define CDRs before implementation begins
  • Mock Service Strategy: Generate realistic mocks from contract specifications
  • Parallel Team Enablement: Structure contracts to minimize cross-team dependencies
  • Evolution Planning: Include versioning and backward compatibility strategies
  • AI Context Optimization: Provide contract specifications that AI tools can directly implement

Common Implementation Challenges

  • Over-Documentation: Excessive detail that obscures core decision information
  • Incomplete Contracts: CDR specifications that lack implementation detail for AI tools
  • Unclear Decision Statements: Ambiguous outcomes leading to inconsistent implementation
  • Missing Context: Insufficient background for future decision evaluation
  • Poor AI Integration: Vague guidance that doesn’t effectively direct AI tools
  • Contract Inconsistency: CDRs that don’t align with architectural decisions
  • Traceability Gaps: Missing decision references in implementation code
  • Disconnected Decisions: Isolated TDRs without clear relationships to related decisions

Implementation Resources ⭐ Updated for v1.1

Template Access:

v1.1 Implementation Guides:

v1.1 Implementation Path:

For greenfield projects, follow the systematic 3-phase Greenfield Architecture Pattern:

  1. Decision Foundation: Start with MDD and ADR documentation to establish architectural vision
  2. Contract Definition: Create CDRs for all service boundaries with AI-generated mock services
  3. Parallel Development: Enable contract-driven implementation with traceability validation

For existing projects, adopt incrementally:

  1. Start with IDRs: Begin with implementation-level decisions for immediate AI assistance value
  2. Add Contract Definition: Introduce CDRs for new API development and service boundaries
  3. Establish Traceability: Implement code annotation standards for decision-implementation links
  4. Scale Systematically: Gradually expand to full TDR hierarchy as team familiarity grows

Traceability Integration:

  • All generated code MUST include @implements TDR-ID: Title annotations
  • AI tools SHOULD validate implementation against TDR specifications
  • CI/CD pipelines SHOULD enforce decision reference compliance