Skip to content

Auto detect input schema, remove input_adapter

Hongtao Yang requested to merge hyang/auto-detect-input-schema into main

What does this merge request do and why?

This MR adds the ability to automatically detect input table schema, and remove the need to specify input_adapter. The reason why this is desirable can be found in #217 (closed).

Specifically, this is achieved by

  • We construct different pydantic models for each input table types: issue/epic, doc, code-generation, code-explanation
  • Then we take advantage of pydantic's builtin model_validate function to try to deserilize the input data into one of the pydantic models.

NOTE: This is a breaking change that require users to update their config.

Ref: #217 (closed)

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Merge request checklist

  • I've ran the affected pipeline(s) to validate that nothing is broken.
  • Tests added for new functionality. If not, please raise an issue to follow up.
  • Documentation added/updated, if needed.
Edited by Hongtao Yang

Merge request reports