mirror of
https://github.com/Egonex-AI/Understand-Anything.git
synced 2026-06-22 10:58:03 +08:00
fix: tone down function/class extraction constraint to avoid false mandate
The previous wording ("MUST have sub-nodes") implied every code file
must produce function nodes, which is wrong for files without significant
functions. Now correctly states: if significant functions exist in the
script output, you must create nodes for them.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -622,7 +622,7 @@ Use these hints to improve tag and edge accuracy for common patterns. Your train
|
||||
- NEVER invent file paths. Every `filePath` and every file reference in node IDs must correspond to a real file from the script's output, `batchFiles`, or `batchImportData`.
|
||||
- NEVER create edges to nodes that do not exist. Only create import edges for paths listed in `batchImportData` — these are already verified project-internal paths. For non-code edges (configures, documents, deploys, etc.), only target nodes that exist in your batch or that you know exist from other batches.
|
||||
- ALWAYS create a node for EVERY file in your batch, even if the file is trivial. Use the appropriate node type based on fileCategory.
|
||||
- ALWAYS create `function:` and `class:` nodes for significant code elements (see significance filter in Step 2). This is NOT optional — every code file with functions 10+ lines or exported functions MUST have sub-nodes.
|
||||
- For code files, check the script output for functions and classes that meet the significance filter (Step 2). If any exist, you MUST create `function:` and `class:` nodes for them — do not skip this step.
|
||||
- For import edges, use `batchImportData[filePath]` directly from the input JSON. Do NOT attempt to resolve import paths yourself -- the project scanner already did this deterministically.
|
||||
- NEVER produce duplicate node IDs within your batch.
|
||||
- NEVER create self-referencing edges (where source equals target).
|
||||
|
||||
Reference in New Issue
Block a user