-
Notifications
You must be signed in to change notification settings - Fork 535
Add LLM-Context.md #1287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Add LLM-Context.md #1287
Conversation
Adding context file for helping LLMs understand and use PhysicsNeMo codebase to help users
Added detailed design patterns and architectural guidelines for PhysicsNeMo, including registry patterns, module hierarchy, configuration management, and more. Updated the document to enhance clarity and usability for developers.
| **Example:** | ||
|
|
||
| ```python | ||
| from physicsnemo.core.version_check import check_min_version, require_version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This syntax is incorrect; check_min_version does not exist in this module.
| **Pattern:** | ||
|
|
||
| ```python | ||
| def forward(self, x: torch.Tensor, mask: Optional[torch.Tensor] = None) -> torch.Tensor: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| def forward(self, x: torch.Tensor, mask: Optional[torch.Tensor] = None) -> torch.Tensor: | |
| def forward(self, x: torch.Tensor, mask: torch.Tensor | None = None) -> torch.Tensor: |
The existing syntax here will throw a Ruff formatting error.
| @@ -0,0 +1,973 @@ | |||
| # LLM-Context.md | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general, it seems like this LLM-Context.md may be better suited for ./.cursor/rules, and indeed some of the contents here duplicate existing rules. Perhaps we can deduplicate and consolidate these?
|
|
||
| PhysicsNeMo provides a rich set of **domain-specific datapipes**: | ||
|
|
||
| **Organization:** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cursor / Claude Code / other agent-based tooling should be able to dynamically scan the repository structure and docs here to determine repo organization and layout. I'm a bit concerned that hard-coding a directory structure like this will create multiple sources of truth down the road as the repo evolves. Could we perhaps remove this and instead let the agent dynamically determine repo structure?
|
|
||
| **Pattern Type:** Living Documentation | ||
|
|
||
| **Related Rules:** MOD-003a through MOD-003k |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this section add any new detail that the existing referenced .cursor/rules/ do not already have? If not, creating multiple sources of truth will increase maintenance burden.
Adding context file for helping LLMs understand and use PhysicsNeMo codebase to help users
PhysicsNeMo Pull Request
Description
Checklist
Dependencies
Review Process
All PRs are reviewed by the PhysicsNeMo team before merging.
Depending on which files are changed, GitHub may automatically assign a maintainer for review.
We are also testing AI-based code review tools (e.g., Greptile), which may add automated comments with a confidence score.
This score reflects the AI’s assessment of merge readiness and is not a qualitative judgment of your work, nor is
it an indication that the PR will be accepted / rejected.
AI-generated feedback should be reviewed critically for usefulness.
You are not required to respond to every AI comment, but they are intended to help both authors and reviewers.
Please react to Greptile comments with 👍 or 👎 to provide feedback on their accuracy.