docs: document subgraph limitations with autogrow and matchtype (#8709)

## Summary

Document why autogrow and matchtype don't work inside subgraphs,
covering root cause, symptoms, workarounds, and historical context.

## Changes

- **What**: Add `src/core/graph/subgraph-dynamic-input-limitations.md`
explaining the static-vs-dynamic impedance mismatch between subgraph
slots (fixed type at creation) and matchtype/autogrow (runtime
mutations). Includes Mermaid diagrams, workarounds, and PR history. Link
added to `src/lib/litegraph/AGENTS.md` for discoverability.

## Review Focus

- Accuracy of the technical explanation — @AustinMroz authored
matchtype/autogrow, @webfiltered authored the subgraph system
- Whether the workarounds section is practical and complete
- File placement: colocated at `src/core/graph/` next to both
`subgraph/` and `widgets/dynamicWidgets.ts`

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-8709-docs-document-subgraph-limitations-with-autogrow-and-matchtype-3006d73d36508134a64ce8c2c49e05f1)
by [Unito](https://www.unito.io)

---------

Co-authored-by: GitHub Action <action@github.com>
This commit is contained in:
Christian Byrne
2026-02-19 21:29:17 -08:00
committed by GitHub
parent 18875fb5e7
commit 9dc6203b3d
2 changed files with 56 additions and 0 deletions

View File

@@ -28,6 +28,10 @@ import { LGraph } from '@/lib/litegraph/src/LGraph'
**Root cause**: `LGraph``Subgraph` circular dependency (Subgraph extends LGraph, LGraph creates Subgraph instances).
## Known Limitations
- Subgraph dynamic input limitations (autogrow/matchtype): see [`src/core/graph/subgraph-dynamic-input-limitations.md`](../../core/graph/subgraph-dynamic-input-limitations.md)
## Test Helpers
```typescript