Implement artifact-level render command with Markdown output and update docs
This commit is contained in:
@@ -14,7 +14,7 @@ must describe current behavior only; planned or speculative work belongs under
|
||||
## Project Shape
|
||||
|
||||
seriatim is a Go CLI for transcript artifact processing. The implemented
|
||||
commands are `merge`, `trim`, and `normalize`.
|
||||
commands are `merge`, `trim`, `normalize`, and `render`.
|
||||
|
||||
`merge` reads one or more JSON transcript files, optionally maps input files to
|
||||
canonical speakers, runs a registry-selected preprocessing chain, merges
|
||||
@@ -22,11 +22,12 @@ canonical segments into deterministic chronological order, runs a
|
||||
registry-selected postprocessing chain, validates the selected output schema,
|
||||
and writes JSON output plus an optional JSON report.
|
||||
|
||||
`trim` and `normalize` are artifact-level commands outside the merge pipeline.
|
||||
`trim` reads an existing seriatim output artifact and projects it by segment ID.
|
||||
`normalize` reads transcript-like JSON and emits one of seriatim's supported
|
||||
output schemas. Neither command runs merge preprocessing or postprocessing
|
||||
modules.
|
||||
`trim`, `normalize`, and `render` are artifact-level commands outside the merge
|
||||
pipeline. `trim` reads an existing seriatim output artifact and projects it by
|
||||
segment ID. `normalize` reads transcript-like JSON and emits one of seriatim's
|
||||
supported output schemas. `render` reads an existing seriatim output artifact
|
||||
and emits human-readable Markdown. None of these commands runs merge
|
||||
preprocessing or postprocessing modules.
|
||||
|
||||
The supported public output schemas are `seriatim-minimal`,
|
||||
`seriatim-intermediate`, and `seriatim-full`. For command and flag details, use
|
||||
@@ -66,9 +67,9 @@ collects report events, converts the final transcript, and writes optional
|
||||
reports. Built-in adapters and modules are registered from `internal/builtin`.
|
||||
|
||||
CLI code in `internal/cli` should parse flags, build validated config values,
|
||||
and delegate. `merge` delegates to `pipeline.Run`; `trim` and `normalize`
|
||||
perform artifact-level orchestration and delegate deterministic parsing,
|
||||
validation, and transformation work to their internal packages.
|
||||
and delegate. `merge` delegates to `pipeline.Run`; `trim`, `normalize`, and
|
||||
`render` perform artifact-level orchestration and delegate deterministic
|
||||
parsing, validation, and transformation work to their internal packages.
|
||||
|
||||
Config loading and validation belongs in `internal/config`. Filesystem reads and
|
||||
writes are adapter concerns and should not spread into pure transformation
|
||||
@@ -166,10 +167,10 @@ correction or annotation modules, inspect the package tests for overlap,
|
||||
coalesce, danglers, backchannel, filler, and autocorrect behavior.
|
||||
|
||||
When changing artifact-level commands, inspect `internal/trim`,
|
||||
`internal/normalize`, and their CLI tests. When changing public output shape or
|
||||
schema validation, inspect `schema` and `internal/artifact` tests. Report and
|
||||
diagnostic changes should be covered through the command or package tests that
|
||||
emit the affected events.
|
||||
`internal/normalize`, `internal/render`, and their CLI tests. When changing
|
||||
public output shape or schema validation, inspect `schema` and
|
||||
`internal/artifact` tests. Report and diagnostic changes should be covered
|
||||
through the command or package tests that emit the affected events.
|
||||
|
||||
## Dependency Policy
|
||||
|
||||
@@ -202,8 +203,8 @@ free of secrets or private transcript data.
|
||||
registry name.
|
||||
- Preserve deterministic ordering, final segment ID assignment, and schema
|
||||
validation before output acceptance.
|
||||
- Keep `trim` and `normalize` artifact-level; do not run merge modules from
|
||||
those commands.
|
||||
- Keep `trim`, `normalize`, and `render` artifact-level; do not run merge
|
||||
modules from those commands.
|
||||
- Keep public output schemas validated through `schema`.
|
||||
- Keep optional reports ordered, concise, and diagnostic.
|
||||
- Avoid broad dependencies without a concrete maintainability benefit.
|
||||
|
||||
@@ -16,6 +16,7 @@ It complements [architecture policy](architecture.md) and
|
||||
- `internal/artifact/`: conversion from internal merged model to public shapes.
|
||||
- `internal/trim/`: artifact-level trim logic.
|
||||
- `internal/normalize/`: artifact-level normalize parsing/building.
|
||||
- `internal/render/`: artifact-level rendering and renderer registry.
|
||||
- `internal/*` domain packages: overlap, coalesce, danglers, filler,
|
||||
backchannel, speaker, autocorrect, report, model.
|
||||
- `schema/`: public structs plus embedded JSON Schemas and validation.
|
||||
@@ -36,6 +37,7 @@ go run ./cmd/seriatim --help
|
||||
go run ./cmd/seriatim merge --help
|
||||
go run ./cmd/seriatim trim --help
|
||||
go run ./cmd/seriatim normalize --help
|
||||
go run ./cmd/seriatim render --help
|
||||
```
|
||||
|
||||
Current toolchain note:
|
||||
|
||||
Reference in New Issue
Block a user