Convert And Save • AI Agents Framework

convert_and_save: Converts the provided JSON data into the desired YAML format and saves it to a file.

convert_and_save

Method

</div>

This is a method of the AutoGenerator class in the auto module.

Converts the provided JSON data into the desired YAML format and saves it to a file.

Signature

python
def convert_and_save(json_data: Any, merge: Any) -> Any

Parameters

ParamField Any

The JSON data representing the team structure.

ParamField Any

Whether to merge with existing agents.yaml file instead of overwriting.

Returns

ResponseField Any

The result of the operation.

Uses

  • exists
  • merge_with_existing_agents
  • f.write
  • logger.debug

Source

View on GitHub

praisonai/auto.py at line 1324