# Transcript library intake and audit

Use this workflow when Margarita asks to collect, preserve, show, or link all previous transcriptions in the Cosmos Luminosity Portal.

## Core distinction

A transcript is not visibly present in the Portal merely because:

- a local source file exists;
- the library page mentions the recording;
- the transcript was delivered earlier in Telegram;
- a thematic Portal chapter was built from it.

For a transcript to be **in the Portal library**, it must have a stable public copy, an explicit catalog entry, and a verified working link.

## Full audit workflow

1. Read the current transcript catalog and general library page.
2. Search all relevant project roots for transcription artifacts, including common patterns:
   - `*transcript*.txt`;
   - `*транскрип*.txt`;
   - timestamped YouTube transcript files;
   - translated transcript packages whose names may say `полный перевод` rather than `transcript`.
3. Inspect prior session history when filenames are generic (`audio_from_drive`, hashes, Telegram cache names) and the human-readable title cannot be recovered from the file header.
4. Read file headers and representative lines before assigning a title. Preserve a source-near neutral name when the topic or recipient is uncertain.
5. Deduplicate by intellectual recording, not filename:
   - exclude TXT/SRT/JSON technical variants of one transcription;
   - exclude working chunks and assembled copies;
   - detect copies stored under different project paths;
   - retain genuinely distinct language versions (original and translation) as separate downloadable files under one recording.
6. Copy the chosen complete TXT versions into stable Portal public storage, using ASCII-safe public filenames while keeping clear Russian display titles in the catalog.
7. Maintain one class-level page such as `transcripts-library` grouped by useful source type: series/calls, questions and methods, practices, broadcasts/classes, perfume sources, marketing videos, etc.
8. Link the transcript catalog from both the main Portal index and the general books/source library. Keep books and transcripts visibly distinct.
9. State exact counts separately:
   - unique recordings;
   - downloadable files;
   - extra language versions.
10. Verify the live article API contains every link.
11. Fetch every public file URL and verify HTTP success **and non-empty response bodies**. Do not treat a missing `Content-Length` header as an empty file; read the response body or use downloaded-byte counts.
12. Return the exact direct Portal link to the transcript catalog and, when useful, the parent library link.

## Naming and privacy

- Do not infer private-client identities or sensitive topics from context when filenames are ambiguous.
- Generic source filenames should receive cautious labels such as `Материал для …` until Margarita approves a more descriptive title.
- Public filenames should avoid broken legacy encodings and confusable Unicode; display labels can remain natural Russian.
- Keep specialist publishing transcripts already belonging to a separate corpus (for example Human Design source books/courses) in that corpus unless Margarita explicitly asks to merge them into the working-transcript catalog.

## Portal page structure

A useful transcript catalog contains:

1. a short scope statement;
2. grouped direct links;
3. notes about source/original vs translation;
4. a count summary;
5. deduplication policy;
6. automatic intake rule for future transcripts.

## Future intake rule

After each new transcription:

1. verify completeness and ending;
2. save the stable TXT source;
3. add it to the central transcript catalog immediately;
4. connect it to any thematic Portal page built from it;
5. verify its public URL before reporting completion.

## Pitfalls

- Do not tell Margarita that files are “in the library” when the page only mentions their existence.
- Do not send only Telegram attachments when she asked to see them in the Portal.
- Do not make her search a broad book registry for transcript links; provide a dedicated transcript page.
- Do not upload every mechanical artifact and inflate the count.
- Do not collapse originals and translations into one unlabeled item.
- If an approval gate interrupts copying, state the exact pending operation; after approval, resume, catalog, and verify rather than stopping at the copy step.
