The Rules for AI documentation mention that it is possible to use the @file syntax to attach the content of a file to a rule. Meaning the file content will be added to the context during the first submit and no tool is necessary to access the file.
But after running a lot of experiment, it seems that the @file syntax does ont work for rules. Am I correct?
Note: below the paragraph of Rules for AI mentioning the @file syntax.
Reference Files
Use
@file
in your project rules to include additional files as context when the rule is applied. Using the@file
syntax inside a rule, you can include the contents of another file as part of the rule’s context.For example, a rule could include
@file ../api-guide.md
to attach an API guide whenever that rule is applied, giving the AI more information.These features work together to make rules powerful. You can even reference one rule file from within another using
@file
, effectively chaining multiple rules together for complex scenarios.Rules don’t just contain instructions; they can also include file attachments to provide vital context.