> For the complete documentation index, see [llms.txt](https://ai-os-and-trend-finder.gitbook.io/ai-os-and-trend-finder-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ai-os-and-trend-finder.gitbook.io/ai-os-and-trend-finder-docs/.spec_system/archive/sessions/phase15-session01-scheduler-config-contract/tasks.md).

# Task Checklist

**Session ID**: `phase15-session01-scheduler-config-contract` **Total Tasks**: 12 **Estimated Duration**: 3-4 hours **Created**: 2026-05-31

***

## Legend

* `[x]` = Completed
* `[ ]` = Pending
* `[P]` = Parallelizable (can run with other \[P] tasks)
* `[SNNMM]` = Session reference (NN=phase number, MM=session number)
* `TNNN` = Task ID

***

## Progress Summary

| Category       | Total  | Done   | Remaining |
| -------------- | ------ | ------ | --------- |
| Setup          | 3      | 3      | 0         |
| Foundation     | 3      | 3      | 0         |
| Implementation | 4      | 4      | 0         |
| Testing        | 2      | 2      | 0         |
| **Total**      | **12** | **12** | **0**     |

***

## Setup (3 tasks)

Initial scheduler config boundaries and docs scaffolding.

* [x] T001 \[S1501] Verify current scheduler registry/status/test boundaries before editing (`scripts/lib/scheduler/registry.ts`)
* [x] T002 \[S1501] Add private scheduler config ignore coverage (`.gitignore`)
* [x] T003 \[S1501] \[P] Add scheduler template/private-file docs (`data/ai-os.scheduler.example.json`, `data/README_data.md`)

***

## Foundation (3 tasks)

Typed config contract, validation, and exports.

* [x] T004 \[S1501] Define scheduler config input/result/status projection types (`scripts/lib/scheduler/types.ts`)
* [x] T005 \[S1501] Create scheduler config parser with missing/loaded/invalid states (`scripts/lib/scheduler/config.ts`)
* [x] T006 \[S1501] Implement job ID, cadence ID, Dream `HH:MM`, and unsafe-field validation with schema-validated input and explicit error mapping (`scripts/lib/scheduler/config.ts`)

***

## Implementation (4 tasks)

Config-aware status projection without changing scheduler execution.

* [x] T007 \[S1501] Export scheduler config helpers (`scripts/lib/scheduler/index.ts`)
* [x] T008 \[S1501] Extend scheduler status building to read config with missing-config fallback and timer intent separation (`scripts/lib/scheduler/operator-status.ts`)
* [x] T009 \[S1501] Format config-aware human and JSON status output without raw config contents, paths, command bodies, or secrets (`scripts/lib/scheduler/operator-status.ts`)
* [x] T010 \[S1501] \[P] Update scheduler config guidance and environment notes (`docs/runbooks/scheduled-aggregate.md`, `docs/runbooks/ai-os-dream.md`, `.env.local.example`)

***

## Testing (2 tasks)

Focused verification and hygiene.

* [x] T011 \[S1501] Add config/status/CLI coverage for missing, valid, invalid, and redacted config states (`scripts/lib/__tests__/scheduler-config.test.ts`, `scripts/lib/__tests__/scheduler-operator-status.test.ts`, `scripts/lib/__tests__/scheduler-status-cli.test.ts`)
* [x] T012 \[S1501] Run focused scheduler config/status tests plus `bun run typecheck:scripts` and `git diff --check` (`scripts/lib/__tests__/scheduler-config.test.ts`)

***

## Completion Checklist

Before marking session complete:

* [x] All tasks marked `[x]`
* [x] All tests passing
* [x] All files ASCII-encoded
* [x] implementation-notes.md updated
* [x] Ready for the validate workflow step

***

## Next Steps

Run `updateprd` to sync the phase state and mark the session complete.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://ai-os-and-trend-finder.gitbook.io/ai-os-and-trend-finder-docs/.spec_system/archive/sessions/phase15-session01-scheduler-config-contract/tasks.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
