> For the complete documentation index, see [llms.txt](https://faction-os.gitbook.io/faction-os-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://faction-os.gitbook.io/faction-os-docs/.spec_system/archive/sessions/phase04-session03-draft-asset-generation-and-source-capture/tasks.md).

# Task Checklist

**Session ID**: `phase04-session03-draft-asset-generation-and-source-capture` **Total Tasks**: 22 **Estimated Duration**: 3-4 hours **Created**: 2026-05-29

***

## Legend

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

***

## Progress Summary

| Category       | Total  | Done   | Remaining |
| -------------- | ------ | ------ | --------- |
| Setup          | 3      | 3      | 0         |
| Foundation     | 6      | 6      | 0         |
| Implementation | 10     | 10     | 0         |
| Testing        | 3      | 3      | 0         |
| **Total**      | **22** | **22** | **0**     |

***

## Setup (3 tasks)

Initial configuration, source review, and session evidence setup.

### Repository

* [x] T001 \[S0403] Verify Session 01/02 prerequisites, media tooling baseline, ignored `tmp/` staging, and provider variable names without reading secret values (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/implementation-notes.md`)
* [x] T002 \[S0403] \[P] Inventory S0403-owned media matrix rows and current catalog fixture coverage for target selection (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/implementation-notes.md`)
* [x] T003 \[S0403] \[P] Create implementation and security evidence placeholders with provider-secret, quarantine, no-runtime-promotion, and deferral checklists (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/security-compliance.md`)

***

## Foundation (6 tasks)

Draft target structure, brief pack, manifest baseline, and command surfaces.

### Assets

* [x] T004 \[S0403] \[P] Create generated-draft README defining non-runtime storage, ignored staging, review status, and Session 04 promotion handoff (`assets/generated/phase04/README.md`)
* [x] T005 \[S0403] Create redacted draft target and brief pack for selected visual/audio categories with rejection criteria and no direct `EXAMPLES/` inputs (`assets/generated/phase04/draft-briefs.md`)
* [x] T006 \[S0403] Create draft generation manifest schema baseline with required provenance, rights, cost, output metadata, disposition, and blocker fields (`assets/generated/phase04/draft-generation-manifest.json`)

### Scripts

* [x] T007 \[S0403] \[P] Add manifest checker with schema-validated input, safe path rules, required non-runtime blockers, and explicit error mapping (`scripts/check-media-generation-manifest.mjs`)
* [x] T008 \[S0403] Add draft generation command skeleton with dry-run default, credential-presence checks, ignored staging paths, budget caps, and duplicate-target prevention while in-flight (`scripts/generate-media-drafts.mjs`)
* [x] T009 \[S0403] Wire root draft-generation scripts for dry-run and manifest validation (`package.json`)

***

## Implementation (10 tasks)

Main draft generation, catalog, docs, and security implementation.

### Scripts

* [x] T010 \[S0403] Implement fal.ai draft request handling with timeout, retry/backoff, redacted logging, ignored output writes, and compensation on partial failure (`scripts/generate-media-drafts.mjs`)
* [x] T011 \[S0403] Implement ElevenLabs draft request handling with timeout, retry/backoff, redacted logging, ignored output writes, and compensation on partial failure (`scripts/generate-media-drafts.mjs`)
* [x] T012 \[S0403] Implement output probe and manifest update flow for byte size, dimensions or duration, format, non-sensitive IDs, cost, and reviewer disposition (`scripts/generate-media-drafts.mjs`)

### Assets

* [x] T013 \[S0403] Populate draft manifest with generated, rejected, or explicitly deferred target records and non-runtime release blockers (`assets/generated/phase04/draft-generation-manifest.json`)
* [x] T014 \[S0403] Run approved dry-run or provider-backed generation targets and record ignored staging paths or deferrals without tracked raw outputs (`tmp/media-generation/phase04-session03/`)

### Apps Web

* [x] T015 \[S0403] Extend app media catalog groups and fixtures for useful S0403 draft or planned records without marking them release-ready (`apps/web/src/data/mediaCatalog.ts`)
* [x] T016 \[S0403] Update app media catalog tests for blocked generated-reference/planned records, standalone demo boundaries, and no approved runtime draft paths (`apps/web/tests/mediaCatalog.test.ts`)

### Docs

* [x] T017 \[S0403] Update media docs with draft generation workflow, manifest fields, ignored staging, provider-secret rules, and Session 04 handoff (`docs/media-assets.md`)
* [x] T018 \[S0403] Update assets README for generated-draft evidence, non-runtime boundaries, ignored staging, and promotion handoff (`assets/README_assets.md`)
* [x] T019 \[S0403] Update scripts README with media draft generation and manifest check commands (`scripts/README_scripts.md`)

***

## Testing (3 tasks)

Verification and quality assurance.

### Repository

* [x] T020 \[S0403] Run media tooling, draft manifest, dry-run, focused catalog tests, and app typecheck; record command evidence and any existing host-tool gaps (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/implementation-notes.md`)
* [x] T021 \[S0403] Run privacy/quarantine checks for secrets, raw prompts, account IDs, raw provider payloads, broad local paths, tracked raw outputs, and direct `EXAMPLES/` promotion (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/security-compliance.md`)
* [x] T022 \[S0403] Run diff hygiene, ASCII, LF, and final no-runtime-reference review; update session evidence for validate handoff (`.spec_system/specs/phase04-session03-draft-asset-generation-and-source-capture/implementation-notes.md`)

***

## Completion Checklist

Before marking session complete:

* [x] All tasks marked `[x]`
* [x] All tests passing or existing host-tool gaps documented
* [x] All files ASCII-encoded
* [x] implementation-notes.md updated
* [x] security-compliance.md updated
* [x] Ready for the validate workflow step

***

## Next Steps

Session work is complete. Use the validation and updateprd reports to close the session, then return to `plansession` if Phase 04 still has remaining sessions.


---

# 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://faction-os.gitbook.io/faction-os-docs/.spec_system/archive/sessions/phase04-session03-draft-asset-generation-and-source-capture/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.
