Skip to content

Foundational Enhancement: BAML Integration for Structured Agent Communication #20

@reza899

Description

@reza899

Overview

Integrate BAML (Basically a Made-up Language) framework to replace ad-hoc prompt engineering with type-safe, schema-validated LLM interactions across all 5 AutoSDLC agents.

Problem Statement

Current Phase 3 implementation relies on:

  • Ad-hoc prompt engineering in agent tools
  • Mock implementations without schema validation
  • Manual string manipulation for agent communication
  • Limited multi-model flexibility

Solution: BAML Integration

BAML provides:

  • Type-safe prompt engineering with schema validation
  • Multi-model support with easy switching/fallbacks
  • Structured agent coordination via validated schemas
  • VSCode integration for prompt debugging
  • Streaming and tool-calling for complex workflows

Implementation Plan

Phase 1: Foundation (Week 1)

  • Install BAML dependencies (@boundaryml/baml, @boundaryml/baml-cli)
  • Create baml_src/ directory with schema definitions
  • Define core schemas for agent communication
  • Update build process to include BAML compilation

Phase 2: Agent Integration (Week 2)

  • Refactor BaseAgent to use BAML functions
  • Replace mock tools in all 5 agents with BAML-validated implementations
  • Update Agent_Output.md generation with schemas
  • Add multi-model fallback strategies

Phase 3: Enhancement (Week 3)

Integration with Existing Issues

This enhancement amplifies existing Phase 3 work:

Success Metrics

  • 100% schema validation for agent communication
  • Zero string-based prompt engineering
  • Multi-model flexibility across all agents
  • Enhanced reliability and maintainability
  • Improved debugging capabilities

Dependencies

  • Must integrate with existing Phase 3 tracks
  • Requires updates to documentation and existing issues
  • Compatible with current TDD approach and testing framework

This is a foundational enhancement that makes all other Phase 3 work more robust and maintainable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions