Skip to content

SYSTEM_PROMPT: Support Nested Ignore-Aware Folder/File Structure #18

@manojsinghnegiwd

Description

@manojsinghnegiwd

Summary

The SYSTEM_PROMPT needs to be enhanced so it parses a nested, hierarchical version of the project ignore paths specified in .agnignore or .gitignore, instead of a flat list. This will allow the system to understand the folder structure more deeply and enable file references/context to be derived from this structured map—improving file matching and contextual awareness.

Task

  • Modify SYSTEM_PROMPT logic so it reads and expands .agnignore and/or .gitignore patterns into a nested, hierarchical folder/file structure.
  • Use this structure for future path matching within the agent, allowing agn to infer directory and file relationships.
  • Ensure SYSTEM_PROMPT always leverages this nested view for ignore and structural queries instead of a flat file list.
  • Validate that ignored paths (per the ignore file rules) are still excluded from non-ignored file/folder representations.

Acceptance criteria:

  • SYSTEM_PROMPT uses a hierarchical structure derived from ignore files.
  • File and folder suggestions, path expansions, and references respect ignore rules and leverage the nested map.
  • Solution works with both .agnignore and .gitignore if either/both exist.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions