# General Rules

These rules apply to MixerSystem as a whole.

## Scope

- Keep only system-level concepts in this rules file.
- Put orchestration and agent rules in the workflows-layer rules.
- Put runtime/data and provider rules in the data-layer rules.

## Architecture

- The canonical lifecycle is `task -> plan -> module`.
- Every run is anchored to `work_folder`.
- Canonical artifacts are `task.md`, `plan.md`, and `module.md`.

## Contracts

- `work_folder`, `size`, and `depth` are runtime context concerns.
- Behavior controls such as `branch_count`, `max_revisions`, and `max_test_iterations` are explicit workflow parameters.
- Workflow success is completion; failure is exception-based.

## Naming

- Use `modules`, never `target_modules`.
- Keep path naming consistent: `task_path`, `plan_path`, `module_path`.
- Keep report naming consistent (`module.md` as module output).

## Source Layout

- Source lives in the `mixersystem/` package.
- `sync` generates runtime settings and skill files; it does not copy workflow/data source code into projects.
- Keep `.mix` docs scoped and avoid duplicating layer details across files.
