Features
@Mentions
File Mentions

File References

File references allow you to seamlessly integrate any workspace file into your conversation with Bwat. Instead of manually copying code sections, simply type @/ and specify the file path to give Bwat complete context.

How to Use File References

When you enter @/ in chat, Bwat displays your project file structure. Browse through directories, select your target file, and its complete contents become immediately available - including all imports, related functions, and surrounding code context.

Practical Usage

Use file references when troubleshooting issues. Rather than guessing which code segments to share, simply reference the entire file:

Getting this validation error: Terminal Output (see below for output)

Relevant form component: 'src/components/RegistrationForm.vue' (see below for file content)

Backend handler: 'src/api/authService.js' (see below for file content)

What's causing this mismatch?

This approach provides Bwat with:

  • The complete error output
  • Full component implementation
  • Entire API endpoint logic All without any manual copying.

Key Benefits

  • Eliminates manual code section identification
  • Provides complete file context automatically
  • Maintains awareness of imports and dependencies
  • Reduces context-missing errors

Technical Implementation

When you use a file reference, Bwat:

  1. Detects file path patterns in your message
  2. Resolves absolute file paths relative to project root
  3. Verifies file type (text vs binary)
  4. For text files:
    • Reads complete contents
    • Preserves original formatting
    • Maintains syntax structure
  5. Structures the enhanced message with file content
  6. Processes with full file context for accurate analysis