Prompt nodes now accept TXT, Markdown, and DOCX uploads while preserving the node contract as plain prompt text. The canvas preview shows imported Markdown as a lightweight document card, and DOCX extraction stays local to body text so generation inputs remain deterministic.
Constraint: Text-class nodes must still output plain text into existing workflow edges.
Rejected: Add a full document editor/parser layer | too broad for the requested node-level upload and preview behavior.
Confidence: high
Scope-risk: moderate
Directive: Keep uploaded document data normalized to prompt text unless downstream nodes explicitly gain rich document inputs.
Tested: npm run test:run -- src/components/__tests__/PromptNode.test.tsx src/components/modals/__tests__/MarkdownEditorModal.test.tsx src/utils/__tests__/textDocumentImport.test.ts --reporter=dot
Tested: npm run build
Tested: git diff --check
Not-tested: npm run lint still fails because Next 16 treats the existing next lint script as a /lint project path.
The provider branch makes model defaults and Popi metadata resolution more asynchronous, while the local UI keeps duplicate node-body settings hidden. This keeps pricing available when metadata is already complete, avoids refreshing placeholder Popi selections, preserves explicit Popi schema hydration, and fixes strict TypeScript narrowing exposed by the merged media upload route.
Constraint: Preserve hidden node-body settings while keeping Popi provider schema hydration available.
Rejected: Re-enable inline node settings for all external providers | would reintroduce duplicated controls the user asked to hide.
Confidence: high
Scope-risk: moderate
Directive: Do not fetch per-model schemas for hidden non-Popi node settings unless an explicit modelSchemaRequestId requests it.
Tested: npm run test:run -- src/components/__tests__/PromptNode.test.tsx src/components/__tests__/WorkflowCanvas.test.tsx src/components/modals/__tests__/MarkdownEditorModal.test.tsx src/components/__tests__/FloatingNodeHeader.test.tsx src/components/__tests__/LLMGenerateNode.test.tsx src/components/__tests__/GenerateImageNode.test.tsx src/components/__tests__/GenerateVideoNode.test.tsx src/components/__tests__/GenerationComposer.test.tsx src/app/api/generate/providers/__tests__/popiserver.test.ts src/app/api/__tests__/popiserverModels.test.ts --reporter=dot
Tested: npm run build
Tested: git diff --check
Tested: rg -n '^(<<<<<<<|=======|>>>>>>>)' src
Not-tested: npm run lint cannot run because the existing Next 16 script maps next lint to a missing ./lint project directory.
Text prompt and LLM output nodes need document-style editing without changing their existing node data contracts, so Markdown editing now writes back to the same prompt/outputText fields and Markdown files import as prompt nodes. Canvas shortcuts ignore local editors so document copy/paste remains native inside the modal.
Constraint: Preserve existing prompt and LLM node data contracts
Rejected: Replace inline prompt editing | would change current node interaction behavior
Confidence: high
Scope-risk: moderate
Directive: Keep canvas-level keyboard shortcuts out of modal and contentEditable targets
Tested: npm run test:run -- src/components/__tests__/PromptNode.test.tsx src/components/__tests__/WorkflowCanvas.test.tsx src/components/modals/__tests__/MarkdownEditorModal.test.tsx src/components/__tests__/FloatingNodeHeader.test.tsx src/components/__tests__/LLMGenerateNode.test.tsx
Tested: npm run build
Tested: git diff --check
Not-tested: npm run lint (existing Next 16 next lint path failure)
Vidu rejects generic video reference payloads, while the canvas preview also needs to keep long prompt text inside the prompt node bounds. This keeps provider-specific video reference fields for Vidu and constrains long prompt previews without changing the Seedance media field mapping.
Constraint: Vidu/NewApiWG expects reference_video_urls for video-reference generation.
Rejected: Change all video providers to reference_* fields | Seedance has existing coverage and logs using generic images/videos/audios.
Confidence: high
Scope-risk: narrow
Directive: Do not collapse Vidu video references back to videos without validating against the gateway schema.
Tested: npm run test:run -- src/app/api/generate/providers/__tests__/newapiwg.test.ts src/components/__tests__/PromptNode.test.tsx
Tested: git diff --check
Tested: npm run build
Not-tested: Real Vidu generation, to avoid consuming account points.
Local reference images were reaching the gateway as localhost URLs, and selected image/video nodes still exposed duplicate inline settings while the composer is the active control surface. This keeps gateway media inputs self-contained, maps GPT Image 2 sizes from the actual aspect ratio controls, and keeps node bodies focused on preview/output state.
Constraint: NewApiWG upstream cannot fetch browser-local /api/images URLs.
Constraint: Selected-node composer owns image and video generation controls.
Rejected: Keep localhost reference URLs | remote gateway requests cannot dereference local browser routes.
Rejected: Keep duplicate inline settings | it creates conflicting controls with the composer.
Confidence: high
Scope-risk: moderate
Directive: Do not send /api/images temporary URLs to NewApiWG upstream; resolve them to data URLs before provider calls.
Tested: npm run test:run -- src/app/api/generate/providers/__tests__/newapiwg.test.ts src/app/api/generate/__tests__/route.test.ts src/components/__tests__/GenerateImageNode.test.tsx src/components/__tests__/GenerateVideoNode.test.tsx src/components/__tests__/PromptNode.test.tsx src/lib/__tests__/llmModels.test.ts src/store/__tests__/workflowStore.integration.test.ts
Tested: npm run build
Tested: git diff --check
Not-tested: npm run lint still fails because next lint resolves to a nonexistent lint directory under Next 16.