Skip to content

Import declarative_component_schema for pydantic model parsing #146

@pnilan

Description

@pnilan

Problem

When an LLM generates a connector manifest, the returned manifest is currently handled as a plain dictionary. We want to parse it into a Pydantic model for better validation and type safety. To enable this, we need access to the declarative_component_schema from the airbyte-cdk.

Options

Option 1: Import airbyte-cdk as a dependency

Preferred approach.
Import the airbyte-cdk directly as a dependency. However, there are current version conflicts preventing this. To make it possible, the following dependencies in airbyte-cdk may need to be updated or removed:

  • jsonref
  • numpy
  • langchain (TBD)
  • langchain-core (TBD)

Option 2: Vendor the declarative_component_schema.py

If updating or removing dependencies in airbyte-cdk is not feasible or introduces breaking changes, we can vendor the declarative_component_schema into the mcp repository.

This approach mirrors the strategy used in the builder-ai repo, where CDK types are periodically vendored via a script (download_cdk_types.py). The same method could be applied to vendor the declarative component schema and its corresponding Pydantic models.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions