Files
CatoandClaude Opus 5.5 7f1dc4198d AI article writing: long text fitted, not refused; throw everything in and Cat writes it (#1838)
* fix(ai): fit long briefs instead of refusing them; actionable input errors

A pasted chat in Ask Cat's "What would you like to write about?" box hit a
300-character zod cap and answered "Invalid request". AI routes now fit free
text to the model budget (ai-kit fitPromptText) and explain real refusals
by field, limit and fix (ai-kit explainInputIssues).

Needs @bitbaum/ai-kit with the input module (bitbaum/ai-kit#119).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* feat(articles): AI-first writing — throw everything in, Cat writes it

An empty article now opens with "Write with Cat": thoughts, speech, a
pasted chat, links, notes and pictures go in; one button writes a cited,
illustrated article that opens in the editor for changes.

- POST /api/ai/writing/compose: thin route over services/cat/writing-compose,
  which binds writingkit's composeArticle to OrangeCat's adapters — ai-kit
  readPage (SSRF-checked), the platform serving chain, vision through the
  same chain (describePlatformImage), Openverse for illustrations, and the
  writer's recent posts for voice.
- ArticlePile: writingkit's PileComposer with OrangeCat's words, mic and
  picture storage.

Needs @bitbaum/ai-kit 1.31 and @bitbaum/writingkit 0.4.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* chore(deps): @bitbaum/ai-kit ^1.31.0 (fitPromptText, explainInputIssues)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* fix(types): AI input and compose pass strict exactOptionalPropertyTypes

Absent optional fields are left out instead of set to undefined
(toPileItems, labels, credit, voice, fetch signal).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* feat(articles): an empty article leads with Write with Cat

The article-writing browser test guarded "editor visible near the top" —
the title-first assumption the owner retired on 15 Nov 2026 (AI-first:
throw everything in, Cat writes it). It now guards the new rule: Write with
Cat near the top on a phone, the editor still on the page, and the Ask Cat
draft flow, overflow and 44px checks unchanged. The pile's one action is
ink, not the accent (One orange).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-19 16:18:51 +01:00
..