Skip to main content
The agent can read, write, and edit any file inside your open project folder. When you ask it to implement a feature or fix a bug, it typically starts by reading the relevant files to understand the current state, then makes targeted edits — creating new files or modifying existing ones with surgical precision. Every file operation appears as a badge in the chat so you can follow exactly what was touched.

Available tools

Reads the content of a file, with optional line-range scoping. The agent uses this to understand existing code before making changes.The tool returns up to 3,000 lines per call. If the file is longer, it tells the agent the remaining line count and suggests the next range to fetch — so no content is silently truncated.Binary files are detected automatically and not shown as text.Chat badge example: Reading src/components/Button.tsx
Writes a new file to disk, creating any missing parent directories. By default it refuses to overwrite an existing file — it will suggest edit_file instead — unless you explicitly ask the agent to replace the file entirely.Chat badge example: Writing src/utils/format.ts
Replaces an exact string within a file with new content. This is safer than a full overwrite for modifying existing code: the old string must match exactly, so the agent can’t accidentally clobber unrelated sections of the file.If the target string appears more than once in the file, the edit is rejected — the agent must be more specific.Chat badge example: Editing src/api/client.ts
Finds files whose paths match a glob pattern. Useful for discovering all files of a given type before reading or editing them.Example patterns:
**/*.ts          — all TypeScript files anywhere in the project
src/**/*.rs      — all Rust files under src/
**/*.test.{ts,js} — all test files
Chat badge example: Listing project root
Searches file contents using a regex or literal string pattern. Uses ripgrep when it is installed, falling back to a built-in search otherwise. Results include file paths and line numbers.You can combine grep with an optional glob to narrow the search to specific file types — for example, search for useState only in .tsx files.Chat badge example: Searching handleSubmit
Finds where a function, class, struct, interface, type, or constant is defined. The agent passes the exact symbol name and the tool returns matching definition lines with file paths and line numbers.This is faster than a broad grep when you know the symbol name — the search pattern targets definition keywords (fn, function, class, def, struct, type, etc.) directly.Chat badge example: Finding AuthProvider
Lists the files and subdirectories at a given path, with optional depth control. Build directories and dependency caches (node_modules, target, .vs) are automatically skipped to keep the output clean.Chat badge example: Listing src/components
Deletes a file from the project. The agent uses this to clean up generated files, remove obsolete code, or tidy up after a refactor.Chat badge example: Deleting src/legacy/old-utils.ts
Moves or renames a file within the project. Parent directories for the new path are created automatically if they do not exist.Chat badge example: Renaming src/utils.ts

How the agent uses file tools

For most tasks the agent follows a consistent pattern:
  1. Explore — calls list_dir or glob to understand the project structure.
  2. Read — calls read_file on relevant files to understand the current code.
  3. Search — calls grep or find_symbol to locate the exact section it needs.
  4. Edit or write — calls edit_file for targeted changes or write_file for new files.
The agent prefers edit_file over write_file for existing files because it is more precise and less likely to discard content unintentionally.

Viewing file activity in chat

Every file operation appears inline in the conversation as a collapsible badge. The badge shows a short label like Reading src/auth.ts. Click the expand arrow to see the full file path, the line range read (for read_file), or a diff of what was changed (for edit_file and write_file). When the agent reads several files simultaneously — a common optimisation when exploring a codebase — they appear as a grouped batch badge.

Project scope

The agent only accesses files within the project folder you have open in Luminy. It cannot read files outside that directory tree unless you explicitly open an additional folder.
If the agent seems to be making changes without fully understanding the existing code, ask it to read the file first before editing. Explicitly mentioning the file path helps it target the right location.
File writes are immediate and permanent. Luminy does not maintain an undo buffer. Use git to track your changes — ask the agent to commit its work after completing a task so you have a clean rollback point.