feat(pipeline): replace ParsePages with ParseRawPages + RawPage type

Strips slug authority from the LLM. The new RawPage type carries only
{title, type, subtype, domain, content} — no paths or frontmatter.
Pipeline will derive slugs deterministically (Task 4).

pipeline.go gets a temporary bridge stub (TODO task4) to keep the
package compiling between tasks.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Mathias Bergqvist
2026-04-23 18:41:33 +02:00
parent 989f375aec
commit 26b5636b43
3 changed files with 55 additions and 29 deletions

View File

@@ -52,8 +52,11 @@ func Run(ctx context.Context, cfg Config, brainDir, content, source string, dryR
if err != nil {
return Result{}, fmt.Errorf("LLM call: %w", err)
}
pages, warnings := ParsePages(output)
allPages = append(allPages, pages...)
// TODO(task4): replace with RawPage-based pipeline
rawPages, warnings := ParseRawPages(output)
for _, rp := range rawPages {
allPages = append(allPages, wiki.Page{Path: rp.Type + "/" + rp.Title, Content: rp.Content})
}
allWarnings = append(allWarnings, warnings...)
}