.. _chapter_phase_api:

Chapter: Phase API
==================

In this chapter, we introduce you to the **PyAutoFit** phase API, which long-term software projects can adopt to interface
**PyAutoFit** directly with your software and provide a better management of many of model composition and fitting,
such as visualization, outputting results in a structured format and augmenting data before a fit.

The chapter contains the following tutorials:

`Tutorial 1: Source Code <https://mybinder.org/v2/gh/Jammy2211/autofit_workspace/664a86aa84ddf8fdf044e2e4e7db21876ac1de91?filepath=howtofit%2Fchapter_phase_api%2Ftutorial_1_source_code.ipynb>`_
- How the source code of your software project should be structure to best use **PyAutoFit**.

`Tutorial 2: Visualization and Configs <https://mybinder.org/v2/gh/Jammy2211/autofit_workspace/664a86aa84ddf8fdf044e2e4e7db21876ac1de91?filepath=howtofit%2Fchapter_phase_api%2Ftutorial_2_visualization_and_configs.ipynb>`_
- How to set up your project to visualize results and use configuration files.

`Tutorial 3: Phase Customization <https://mybinder.org/v2/gh/Jammy2211/autofit_workspace/664a86aa84ddf8fdf044e2e4e7db21876ac1de91?filepath=howtofit%2Fchapter_phase_api%2Ftutorial_3_phase_customization.ipynb>`_
- Augmenting the ``data`` and customizing the likelihood function of a model-fit.

`Tutorial 4: Aggregator <https://mybinder.org/v2/gh/Jammy2211/autofit_workspace/664a86aa84ddf8fdf044e2e4e7db21876ac1de91?filepath=howtofit%2Fchapter_phase_api%2Ftutorial_4_aggregator.ipynb>`_
- Designing your project to be exploit **PyAutoFit**'s `Aggregator`.