Skip to content

feat: Add Agent Generator for automated agent creation from manifests#401

Open
ramyag21 wants to merge 1 commit intomainfrom
feature/agent-generator
Open

feat: Add Agent Generator for automated agent creation from manifests#401
ramyag21 wants to merge 1 commit intomainfrom
feature/agent-generator

Conversation

@ramyag21
Copy link
Collaborator

Implements automatic agent generation from YAML/JSON manifests to streamline agent onboarding and reduce manual setup.

Features:

  • Declarative manifest format (YAML/JSON) for agent definition
  • Complete code generation (21 files per agent)
  • Multi-protocol support (A2A, MCP)
  • Comprehensive validation with helpful error messages
  • CLI interface for easy usage
  • OpenAPI specification support
  • 52 unit tests with 80%+ coverage
  • Complete documentation (5 pages + examples)

Components:

  • models.py: Pydantic data models for type-safe manifests
  • manifest_parser.py: YAML/JSON parsing with validation
  • manifest_validator.py: Comprehensive validation logic
  • agent_generator.py: Core generation engine
  • templates_inline.py: Code templates for scaffolding
  • cli.py: User-friendly command-line interface

Documentation:

  • README.md: Overview and quick start
  • manifest-format.md: Complete format specification
  • cli-reference.md: CLI command reference
  • best-practices.md: Guidelines and tips
  • examples.md: Example walkthroughs

Examples:

  • simple-agent.yaml: Minimal configuration
  • weather-agent.yaml: API integration example
  • devops-agent.yaml: Complex multi-skill agent
  • openapi-agent.yaml: OpenAPI-based agent

Tests:

  • test_models.py: Model validation tests (14 tests)
  • test_parser.py: Parser tests (9 tests)
  • test_validator.py: Validator tests (9 tests)
  • test_generator.py: Generator tests (15 tests)
  • All 52 tests passing

Acceptance Criteria Met:
✅ Parse OASF/YAML manifests
✅ Auto-generate agents with correct scaffolding
✅ Validation and error handling
✅ Complete documentation
✅ Good first issue friendly

Closes #<issue_number>

Description

Please provide a meaningful description of what this change will do, or is for.
Bonus points for including links to related issues, other PRs, or technical
references.

Note that by not including a description, you are asking reviewers to do extra
work to understand the context of this change, which may lead to your PR taking
much longer to review, or result in it not being reviewed at all.

Please ensure commits conform to the Commit Guideline

Type of Change

  • Bugfix
  • New Feature
  • Breaking Change
  • Refactor
  • Documentation
  • Other (please describe)

Checklist

  • I have read the contributing guidelines
  • Existing issues have been referenced (where applicable)
  • I have verified this change is not present in other open pull requests
  • Functionality is documented
  • All code style checks pass
  • New code contribution is covered by automated tests
  • All new and existing tests pass

Implements automatic agent generation from YAML/JSON manifests to streamline
agent onboarding and reduce manual setup.

Features:
- Declarative manifest format (YAML/JSON) for agent definition
- Complete code generation (21 files per agent)
- Multi-protocol support (A2A, MCP)
- Comprehensive validation with helpful error messages
- CLI interface for easy usage
- OpenAPI specification support
- 52 unit tests with 80%+ coverage
- Complete documentation (5 pages + examples)

Components:
- models.py: Pydantic data models for type-safe manifests
- manifest_parser.py: YAML/JSON parsing with validation
- manifest_validator.py: Comprehensive validation logic
- agent_generator.py: Core generation engine
- templates_inline.py: Code templates for scaffolding
- cli.py: User-friendly command-line interface

Documentation:
- README.md: Overview and quick start
- manifest-format.md: Complete format specification
- cli-reference.md: CLI command reference
- best-practices.md: Guidelines and tips
- examples.md: Example walkthroughs

Examples:
- simple-agent.yaml: Minimal configuration
- weather-agent.yaml: API integration example
- devops-agent.yaml: Complex multi-skill agent
- openapi-agent.yaml: OpenAPI-based agent

Tests:
- test_models.py: Model validation tests (14 tests)
- test_parser.py: Parser tests (9 tests)
- test_validator.py: Validator tests (9 tests)
- test_generator.py: Generator tests (15 tests)
- All 52 tests passing

Acceptance Criteria Met:
✅ Parse OASF/YAML manifests
✅ Auto-generate agents with correct scaffolding
✅ Validation and error handling
✅ Complete documentation
✅ Good first issue friendly

Closes #<issue_number>
@github-actions
Copy link
Contributor

📊 Test Coverage Report

Main Tests Coverage

Metric Coverage Details
Lines 44.8% 1695/3785 lines
Branches 0.0% 0/0 branches

RAG Tests Coverage

Metric Coverage Details
Lines 48.1% 565/1174 lines
Branches 27.0% 88/326 branches

📁 Coverage Artifacts

@sriaradhyula
Copy link
Member

For a future enhancement consideration -

  • OASF for agent record
  • Generate multiple agent targets like LangGraph, Strands, ADK and Kagent Custom Resource

@niallthomson
Copy link
Collaborator

Since @sriaradhyula wasn't on the weekly call this week:

My feedback to this is that I really would prefer we don't introduce more code generation. We had a lot of discussion previously about the MCP code generation approach and some of its issues.

This PR is another 6.5k lines of code getting added, and I'm not convinced yet its the correct approach. I hope we are going to discuss this more before its merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

4 participants