Repository: Avaiga/taipy
File: taipy/core/cycle/cycle.py (Python)

Code before:
    At its creation, a new scenario is attached to a single cycle, the one that
    matches its optional _frequency_ and its _creation_date_.

    The possible frequencies are:

    - `Frequency.DAILY`
    - `Frequency.WEEKLY`
    - `Frequency.MONTHLY`
    - `Frequency.QUARTERLY`
    - `Frequency.YEARLY`

    Attributes:
        id (str): The unique identifier of the cycle.
        frequency (Frequency^): The frequency of this cycle.
        creation_date (datetime): The date and time of the creation of this cycle.
        start_date (datetime): The date and time of the start of this cycle.
        end_date (datetime): The date and time of the end of this cycle.
        name (str): The name of this cycle.
        properties (dict[str, Any]): A dictionary of additional properties.

    !!! example "Example for January cycle"

        ![cycles](../refmans/img/cycles_january_colored.svg){ align=left width="250" }

        Let's assume an end-user publishes production orders (i.e., a production plan) every
        month. During each month (the cycle), he/she will be interested in "playing" with
        different scenarios until only one of those scenarios is selected as the official
        production plan to be published. Each month is modeled as a cycle, and each cycle
        can contain one or more scenarios.

        The picture on the left shows the tree of entities: Cycles, Scenarios, and their
        associated Sequence(s). There is an existing past cycle for December and a current
        cycle for January containing a single scenario.

    When comes the end of a _cycle_ (start date + duration), only one of the scenarios is
    applied in production. This "official" scenario is called the _**primary scenario**_.
    Only one _**primary scenario**_ per cycle is allowed.

    !!! example "Example for February cycle"

        ![cycles](../pic/cycles_colored.svg){ align=left width="250" }
        Now the user starts working on the February work cycle. He or she creates two
        scenarios for the February cycle (one with a low capacity assumption and one with
        a high capacity assumption). The user can then decide to elect the low capacity
        scenario as the "official" scenario for February. To accomplish that, he just
        needs to promote the low capacity scenario as _**primary**_ for the February cycle.

        The tree of entities resulting from the various scenarios created is represented
        in the picture on the left. The underlined scenarios are _**primary**_.

    !!! note

Review comment (suggestion):
```suggestion
        month. During each month (the cycle), he/she will be interested in experimenting with
```

Code after:
    `Cycle^`s are created along with the `Scenario^`s that are attached to them.
    At its creation, a new scenario is attached to a single cycle, the one that
    matches its optional _frequency_ and its _creation_date_.

    The possible frequencies are:

    - `Frequency.DAILY`
    - `Frequency.WEEKLY`
    - `Frequency.MONTHLY`
    - `Frequency.QUARTERLY`
    - `Frequency.YEARLY`

    Attributes:
        id (str): The unique identifier of the cycle.
        frequency (Frequency^): The frequency of this cycle.
        creation_date (datetime): The date and time of the creation of this cycle.
        start_date (datetime): The date and time of the start of this cycle.
        end_date (datetime): The date and time of the end of this cycle.
        name (str): The name of this cycle.
        properties (dict[str, Any]): A dictionary of additional properties.

    !!! example "Example for January cycle"

        ![cycles](../refmans/img/cycles_january_colored.svg){ align=left width="250" }

        Let's assume an end-user publishes production orders (i.e., a production plan) every
        month. During each month (the cycle), he/she will be interested in experimenting with
        different scenarios until only one of those scenarios is selected as the official
        production plan to be published. Each month is modeled as a cycle, and each cycle
        can contain one or more scenarios.

        The picture on the left shows the tree of entities: Cycles, Scenarios, and their
        associated Sequence(s). There is an existing past cycle for December and a current
        cycle for January containing a single scenario.

    When comes the end of a _cycle_ (start date + duration), only one of the scenarios is
    applied in production. This "official" scenario is called the _**primary scenario**_.
    Only one _**primary scenario**_ per cycle is allowed.

    !!! example "Example for February cycle"

        ![cycles](../pic/cycles_colored.svg){ align=left width="250" }
        Now the user starts working on the February work cycle. He or she creates two
        scenarios for the February cycle (one with a low capacity assumption and one with
        a high capacity assumption). The user can then decide to elect the low capacity
        scenario as the "official" scenario for February. To accomplish that, he just
        needs to promote the low capacity scenario as _**primary**_ for the February cycle.

        The tree of entities resulting from the various scenarios created is represented
        in the picture on the left. The underlined scenarios are _**primary**_.