# gfayrr/tasklace architecture

> Architecture diagram of the GitHub repository gfayrr/tasklace, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/gfayrr/tasklace
- Repository: https://github.com/gfayrr/tasklace

## Overview

Tasklace is currently a UI-independent Gantt scheduling core, not yet a desktop application. Its principal workflow is to validate project data, compute a schedule against working-time rules and dependencies, and exchange the project through native files or JSON/CSV. Other implemented capabilities include shared-project merging and repair, baselines, tag appearance and conflict detection. The graph reflects the core and documented capabilities; some subsystem connections are supported only by the README or SOURCE INDEX, since their implementations were not excerpted.

Main entry points: [`src/core/validation/read-project.ts`](https://github.com/gfayrr/tasklace/blob/main/src/core/validation/read-project.ts) (Project validation), [`src/core/scheduling/schedule-project.ts`](https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/schedule-project.ts) (Schedule engine), [`src/core/model/project.ts`](https://github.com/gfayrr/tasklace/blob/main/src/core/model/project.ts) (Project model), [`src/core/scheduling/task-placement.ts`](https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/task-placement.ts) (Task placement)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_schedule["Scheduling and calendars"]
  node_project["Project model<br/>[project.ts]"]
  node_schedule_engine["Schedule engine"]
  node_structure["Structure analysis"]
  node_placement["Task placement<br/>[task-placement.ts]"]
  node_calendar["Calendar compiler"]
  node_working_time["Working-time arithmetic<br/>[working-time.ts]"]
  node_task_slots["Task time slots<br/>[task-slots.ts]"]
end

subgraph group_data["Validation and exchange"]
  node_validation["Project validation<br/>[read-project.ts]"]
  node_issues["Validation issues"]
  node_native_file["Tasklace files<br/>[tasklace-file.ts]"]
  node_json["JSON exchange<br/>[project-json.ts]"]
  node_csv_import["CSV import"]
  node_csv_export["CSV export"]
end

subgraph group_collab["Shared projects"]
  node_shared_session["Shared session<br/>[shared-session.ts]"]
  node_shared_document["Shared document<br/>[shared-document.ts]"]
  node_shared_project["Shared project<br/>[shared-project.ts]"]
  node_repair["Merge repair<br/>[repair-project.ts]"]
end

subgraph group_features["Planning features"]
  node_baseline["Baseline snapshot<br/>[take-baseline.ts]"]
  node_tag_conflicts["Tag conflict detection<br/>[tag-conflicts.ts]"]
  node_tag_appearance["Tag appearance<br/>[tag-appearance.ts]"]
  node_tag_palette["Tag palette<br/>[tag-palette.ts]"]
end

node_user(("Project author"))

node_user -->|"provides data"| node_validation
node_validation -->|"validates into"| node_project
node_validation -->|"reports issues"| node_issues
node_validation -->|"checks structure"| node_structure
node_validation -->|"checks calendar"| node_calendar
node_schedule_engine -->|"analyzes structure"| node_structure
node_schedule_engine -->|"compiles calendar"| node_calendar
node_schedule_engine -->|"places tasks"| node_placement
node_placement -->|"computes slots"| node_task_slots
node_placement -->|"uses working hours"| node_working_time
node_task_slots -->|"uses working time"| node_working_time
node_calendar -.->|"supports arithmetic"| node_working_time
node_schedule_engine -->|"checks conflicts"| node_tag_conflicts
node_schedule_engine -->|"schedules project"| node_project
node_native_file -->|"validates contents"| node_validation
node_native_file -->|"uses project format"| node_shared_project
node_json -->|"validates imports"| node_validation
node_csv_import -->|"validates imports"| node_validation
node_csv_import -->|"checks schedulability"| node_schedule_engine
node_project -.->|"exports task table"| node_csv_export
node_project -.->|"exports document"| node_json
node_shared_session -->|"coordinates edits"| node_shared_document
node_shared_session -->|"uses project operations"| node_shared_project
node_shared_session -->|"repairs merges"| node_repair
node_shared_project -->|"reads and writes"| node_shared_document
node_shared_project -->|"repairs project"| node_repair
node_baseline -->|"captures schedule"| node_schedule_engine
node_baseline -->|"stores snapshot"| node_project
node_tag_conflicts -->|"uses task placement"| node_placement
node_tag_appearance -.->|"uses palette"| node_tag_palette

click node_project "https://github.com/gfayrr/tasklace/blob/main/src/core/model/project.ts"
click node_schedule_engine "https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/schedule-project.ts"
click node_structure "https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/project-structure.ts"
click node_placement "https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/task-placement.ts"
click node_calendar "https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/compile-calendar.ts"
click node_working_time "https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/working-time.ts"
click node_task_slots "https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/task-slots.ts"
click node_validation "https://github.com/gfayrr/tasklace/blob/main/src/core/validation/read-project.ts"
click node_issues "https://github.com/gfayrr/tasklace/blob/main/src/core/validation/validation-issues.ts"
click node_native_file "https://github.com/gfayrr/tasklace/blob/main/src/core/file/tasklace-file.ts"
click node_json "https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/project-json.ts"
click node_csv_import "https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/csv/project-csv-import.ts"
click node_csv_export "https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/csv/project-csv-export.ts"
click node_shared_session "https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-session.ts"
click node_shared_document "https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-document.ts"
click node_shared_project "https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-project.ts"
click node_repair "https://github.com/gfayrr/tasklace/blob/main/src/core/shared/repair-project.ts"
click node_baseline "https://github.com/gfayrr/tasklace/blob/main/src/core/baseline/take-baseline.ts"
click node_tag_conflicts "https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-conflicts.ts"
click node_tag_appearance "https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-appearance.ts"
click node_tag_palette "https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-palette.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_project,node_schedule_engine,node_structure,node_placement,node_calendar,node_working_time,node_task_slots toneBlue
class node_validation,node_issues,node_native_file,node_json,node_csv_import,node_csv_export toneAmber
class node_shared_session,node_shared_document,node_shared_project,node_repair toneMint
class node_baseline,node_tag_conflicts,node_tag_appearance,node_tag_palette toneRose
class node_user toneIndigo
```

## Components

### Scheduling and calendars

- [Project model](https://github.com/gfayrr/tasklace/blob/main/src/core/model/project.ts): `src/core/model/project.ts`
- [Schedule engine](https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/schedule-project.ts): `src/core/scheduling/schedule-project.ts`
- [Structure analysis](https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/project-structure.ts): `src/core/scheduling/project-structure.ts`
- [Task placement](https://github.com/gfayrr/tasklace/blob/main/src/core/scheduling/task-placement.ts): `src/core/scheduling/task-placement.ts`
- [Calendar compiler](https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/compile-calendar.ts): `src/core/calendar/compile-calendar.ts`
- [Working-time arithmetic](https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/working-time.ts): `src/core/calendar/working-time.ts`
- [Task time slots](https://github.com/gfayrr/tasklace/blob/main/src/core/calendar/task-slots.ts): `src/core/calendar/task-slots.ts`

### Validation and exchange

- [Project validation](https://github.com/gfayrr/tasklace/blob/main/src/core/validation/read-project.ts): `src/core/validation/read-project.ts`
- [Validation issues](https://github.com/gfayrr/tasklace/blob/main/src/core/validation/validation-issues.ts): `src/core/validation/validation-issues.ts`
- [Tasklace files](https://github.com/gfayrr/tasklace/blob/main/src/core/file/tasklace-file.ts): `src/core/file/tasklace-file.ts`
- [JSON exchange](https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/project-json.ts): `src/core/exchange/project-json.ts`
- [CSV import](https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/csv/project-csv-import.ts): `src/core/exchange/csv/project-csv-import.ts`
- [CSV export](https://github.com/gfayrr/tasklace/blob/main/src/core/exchange/csv/project-csv-export.ts): `src/core/exchange/csv/project-csv-export.ts`

### Shared projects

- [Shared session](https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-session.ts): `src/core/shared/shared-session.ts`
- [Shared document](https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-document.ts): `src/core/shared/shared-document.ts`
- [Shared project](https://github.com/gfayrr/tasklace/blob/main/src/core/shared/shared-project.ts): `src/core/shared/shared-project.ts`
- [Merge repair](https://github.com/gfayrr/tasklace/blob/main/src/core/shared/repair-project.ts): `src/core/shared/repair-project.ts`

### Planning features

- [Baseline snapshot](https://github.com/gfayrr/tasklace/blob/main/src/core/baseline/take-baseline.ts): `src/core/baseline/take-baseline.ts`
- [Tag conflict detection](https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-conflicts.ts): `src/core/tags/tag-conflicts.ts`
- [Tag appearance](https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-appearance.ts): `src/core/tags/tag-appearance.ts`
- [Tag palette](https://github.com/gfayrr/tasklace/blob/main/src/core/tags/tag-palette.ts): `src/core/tags/tag-palette.ts`

### Other components

- **Project author**

## Connections

- Project author → Project validation: provides data (evidence: `README.md`)
- Project validation → Project model: validates into (evidence: `src/core/validation/read-project.ts`)
- Project validation → Validation issues: reports issues (evidence: `src/core/validation/read-project.ts`)
- Project validation → Structure analysis: checks structure (evidence: `src/core/validation/read-project.ts`)
- Project validation → Calendar compiler: checks calendar (evidence: `src/core/validation/read-project.ts`)
- Schedule engine → Structure analysis: analyzes structure (evidence: `src/core/scheduling/schedule-project.ts`)
- Schedule engine → Calendar compiler: compiles calendar (evidence: `src/core/scheduling/schedule-project.ts`)
- Schedule engine → Task placement: places tasks (evidence: `src/core/scheduling/schedule-project.ts`)
- Task placement → Task time slots: computes slots (evidence: `src/core/scheduling/task-placement.ts`)
- Task placement → Working-time arithmetic: uses working hours (evidence: `src/core/scheduling/task-placement.ts`)
- Task time slots → Working-time arithmetic: uses working time (evidence: `src/core/calendar/task-slots.ts`)
- Calendar compiler → Working-time arithmetic: supports arithmetic (evidence: `src/core/calendar/working-time.ts`)
- Schedule engine → Tag conflict detection: checks conflicts (evidence: `src/core/scheduling/schedule-project.ts`)
- Schedule engine → Project model: schedules project (evidence: `src/core/scheduling/schedule-project.ts`)
- Tasklace files → Project validation: validates contents (evidence: `src/core/file/tasklace-file.ts`)
- Tasklace files → Shared project: uses project format (evidence: `src/core/file/tasklace-file.ts`)
- JSON exchange → Project validation: validates imports (evidence: `src/core/exchange/project-json.ts`)
- CSV import → Project validation: validates imports (evidence: `src/core/exchange/csv/project-csv-import.ts`)
- CSV import → Schedule engine: checks schedulability (evidence: `src/core/exchange/csv/project-csv-import.ts`)
- Project model → CSV export: exports task table (evidence: `README.md`)
- Project model → JSON exchange: exports document (evidence: `README.md`)
- Shared session → Shared document: coordinates edits (evidence: `src/core/shared/shared-session.ts`)
- Shared session → Shared project: uses project operations (evidence: `src/core/shared/shared-session.ts`)
- Shared session → Merge repair: repairs merges (evidence: `src/core/shared/shared-session.ts`)
- Shared project → Shared document: reads and writes (evidence: `src/core/shared/shared-project.ts`)
- Shared project → Merge repair: repairs project (evidence: `src/core/shared/shared-project.ts`)
- Baseline snapshot → Schedule engine: captures schedule (evidence: `src/core/baseline/take-baseline.ts`)
- Baseline snapshot → Project model: stores snapshot (evidence: `README.md`)
- Tag conflict detection → Task placement: uses task placement (evidence: `src/core/tags/tag-conflicts.ts`)
- Tag appearance → Tag palette: uses palette
