Документация доступна только на английском языке.

Tools

The built-in tools the agent uses to read, edit, search, run commands, delegate and ask, and how they vary by model family.

The agent acts through tools. Nib's tool names and input fields (Read, Edit, Bash, file_path, old_string, …) are the ones existing hooks, permission rules and skills are written against, so they work unchanged.

Every call goes through the same gate: input validation and repair, PreToolUse hooks, the permission engine, the tool itself, then PostToolUse hooks. Read-only calls in the same batch run in parallel.

Built-in tools

Files

ToolWhat it does
ReadReads a file with line numbers. Up to 2,000 lines by default; offset and limit for ranges, and a negative offset reads from the end. Also reads images, PDFs (up to 20 pages per call) and Jupyter notebooks
WriteCreates or overwrites a file, creating parent directories as needed
EditReplaces an exact string in a file. Fails if the text isn't unique unless replace_all is set
ApplyPatchApplies a V4A patch that can add, update, move and delete several files atomically. GPT-family models see it as apply_patch
EditLinesEdits by line anchors from the latest Read. Used for the few models that edit more reliably this way
NotebookEditReplaces, inserts or deletes a single cell in a .ipynb notebook
ToolWhat it does
GrepSearches file contents with a regular expression (ripgrep syntax). Runs ripgrep's search engine in-process, so rg doesn't need to be installed. As in ripgrep, lookarounds and backreferences aren't supported, and the error says so
GlobFinds files by name pattern, such as src/**/*.{ts,tsx}
RepoMapShows a compact map of the repository or a folder: the most relevant files with their exported symbols, and file counts per folder

Shell

ToolWhat it does
BashRuns a shell command and returns its output. Default timeout 120 s, maximum 600 s. On Windows it runs in Git Bash
PowerShellRuns a PowerShell command and returns its output, with the same timeouts as Bash. The shell on Windows without Git Bash, where there is no Bash tool. Each command needs your approval in Ask mode: rules can deny or ask for a command, but not approve one
ProcessStarts and manages long-running processes such as dev servers and watchers. Waits until a port, URL or log line says the process is ready
TerminalDrives an interactive program on a pseudo-terminal: REPLs, debuggers, ssh, prompts, terminal UIs. Not on Windows yet
MonitorWatches a background command, a running process or a file, and passes each new output line (optionally filtered by a pattern) to the agent while it keeps working. Ends at a deadline (5 minutes by default, 30 at most)
StopMonitorEnds a Monitor watch early

Web

ToolWhat it does
WebFetchFetches a public page and returns it as Markdown. Refuses private network addresses, and reports cross-host redirects instead of following them
WebSearchSearches the web and returns titles, URLs, snippets and, when the search service extracts it, each page's text as Markdown
BrowserBrowses in Nib's built-in browser, on a tab you see live in the Browser pane: opens a page, reads and acts on it, takes screenshots, and reads console and network logs
ScreenshotLooks at a local page (localhost, 127.0.0.1, file://) in a real browser and returns a screenshot with console errors, at one or several viewport sizes
PreviewOpens a running local dev server in the built-in browser and returns a screenshot with console errors

Planning and conversation

ToolWhat it does
TodoWriteMaintains the session's task list. GPT-family models use UpdatePlan (update_plan) instead, and current Claude models plan without a progress tool
AskUserQuestionAsks you one to four multiple-choice questions when the agent is blocked on a decision that is yours
NextStepsPuts one to three follow-up buttons under the agent's final message. A click sends that step as your message
EnterPlanMode, ExitPlanModeSwitch into plan mode, and present a plan for approval
SkillLoads a skill
ToolSearchLoads deferred tools by name or keyword
UseToolCalls a tool that ToolSearch loaded

Agents

ToolWhat it does
AgentStarts a subagent with a fresh context for a self-contained task
SendMessageSends a message to another agent: a subagent, a teammate, or another session
ListAgentsLists the agents you can message
TaskStopStops a background agent, or a background shell command or process
WorkflowRuns a script that orchestrates many subagents in the background and reports only its result. Used only when you ask for multi-agent orchestration

Code intelligence

ToolWhat it does
DiagnosticsReports compiler and language-server errors and warnings for files
LSPRead-only language-server queries: go to definition or implementation, find references, hover, document and workspace symbols, call hierarchy
RenameSymbolRenames a symbol across the project through the language server. It first shows one combined diff and the textual mentions the server won't change (comments, strings); applying writes every file at once

Tests and review

ToolWhat it does
RunTestsRuns the project's tests (the framework is detected) and returns pass, fail and skip counts with each failure's location and message. The full log is saved as an artifact
ReportFindingsReturns a code review's verified findings as structured data, once, at the end of the review

Session

ToolWhat it does
ChapterStarts a new chapter: a divider in the transcript and an entry in its table of contents
CompactReplaces the earlier turns in the agent's context with a summary, when you ask for it or accept the offer. Your transcript keeps every turn
HistorySearches and re-reads this session's complete history, including what was compacted or trimmed from the agent's context. Reading other sessions of the project follows your permission mode: default asks you first, auto mode leaves it to the classifier, and a History(…) rule can allow it
RenameSessionRenames this session or another of yours
ArchiveSessionArchives another of your sessions. It leaves the sidebar and can be restored
ForkSessionStarts a new session with this conversation and its settings so far, in the same place, so you can try another way without losing this one
EnterWorktree, ExitWorktreeMoves the session into a new git worktree on its own branch, and back out, keeping or removing the worktree. Only when you ask for isolated work

Scheduling

ToolWhat it does
CronCreateSchedules a prompt in this session on a five-field cron schedule in your local time zone, recurring or once. Jobs run only while the session is idle, and recurring ones expire after 7 days
CronDelete, CronListCancel a scheduled job, and list this session's jobs with their next run times
ScheduleWakeupSchedules the next iteration of a self-paced /loop

Artifacts and handoff

ToolWhat it does
ArtifactCreates and edits living artifacts (dashboards, small apps, docs, decks, diagrams and tables) that you see in the Artifact pane
ArtifactCheckBuilds an artifact and renders it without a window: build errors, console errors, data binding states and a screenshot
ArtifactDataGives an artifact live data and capabilities
ArtifactCommentsReads the comments you pinned on an artifact, and resolves them once addressed
MoveSessionContinues the session on a new cloud computer when you ask, so the work goes on after you close your laptop (cloud computers aren't open yet)
StructuredOutputReturns the final answer as JSON that matches the session's output schema, such as the Agent SDK's outputFormat

Some tools are there only when the session's host provides what they need: History (a saved history), the scheduling tools (a scheduler), the worktree tools (worktrees), Browser, Screenshot and Preview (a browser), the artifact tools (artifacts), MoveSession (somewhere to move), Workflow (workflows), Skill (at least one skill) and StructuredOutput (an output schema).

Behavior worth knowing

Read before edit. Edit and EditLines work only on a file the agent has read, and Write overwrites only a file it has read in full. ApplyPatch needs no read: its patch carries the lines it must match. After a partial read, Edit may change only the lines that were seen. Nib records the file's size and modification time at read time and checks them again before writing. If the file changed since, Edit still applies an exact, unique match and says the file changed, while a fuzzy match is refused until the agent reads the file again; Write refuses to overwrite it. A change that lands while Nib is writing aborts the write.

Fuzzy matching, reported. If Edit's old_string doesn't match exactly, Nib tries a ladder of increasingly lenient matches (line endings and typographic quotes, dashes and spaces folded to plain ones, then trailing whitespace ignored, then indentation ignored, then a block matched by its first and last lines). It reports which tier it used, and refuses matches that are suspiciously different in size.

Diagnostics after edits. After an edit, Nib runs the relevant checker (tsgo or tsc for TypeScript, or a language server) and appends new errors to the tool result. The agent sees a type error it introduced in the same step.

A shell that behaves. Each Bash command runs non-interactively: stdin is closed and pagers are disabled (PAGER=cat, GIT_PAGER=cat), so nothing hangs waiting for input. The working directory carries over between calls while it stays inside the workspace. Secrets are stripped from the environment. A command that runs past its timeout is moved to the background instead of being killed, and the agent is notified when it exits; a command that starts with sleep is killed.

Exit codes in context. Exit code 1 from grep, rg, find, diff, test and git diff means "no matches" or "different", and isn't treated as an error.

Large outputs spill to artifacts. Output over about 30,000 characters is cut to its head and tail, and the full text is saved as an artifact. The agent can Read or Grep it as artifact:<id>, so nothing is lost and the context stays small.

Tools per model family

Each model's profile picks the tool set it works best with. Hooks and permission rules always see the canonical name in the first column.

ToolClaudeGPTGemini and most open modelsLine-anchor models
Read✓✓✓✓ (with line anchors)
Edit✓—✓—
ApplyPatch—as apply_patch——
EditLines———✓
Write✓✓✓✓
TodoWriteOlder models (see below)—✓✓
UpdatePlan—as update_plan——
ToolSearch, UseTool✓—✓✓
Everything else✓✓✓✓
  • Claude: current models (the 5 series, and the 4 series after Opus 4.7, Sonnet 4.6 and Haiku 4.5) plan without a progress tool. Set CLAUDE_CODE_ENABLE_TODO_TOOLS=1 to give them TodoWrite back.
  • GPT: GPT-5 and later edit with apply_patch; gpt-oss uses Edit. GPT models get every tool up front, so they don't need ToolSearch.
  • Line-anchor models: a few small models whose profile picked EditLines because it made their edits more reliable.

Deferred tools

Every tool definition costs context on every turn. Tools that are useful but rarely needed are deferred: the model sees only their names, and loads the full definition with ToolSearch when it needs one.

The core set is what most turns need: reading, editing, writing and searching files, Bash, the progress tool, Agent, AskUserQuestion, the web tools, ToolSearch, UseTool, NextSteps, and SendMessage, ListAgents, History, Skill, Artifact and StructuredOutput when the session has them. Everything else is deferred, MCP tools included. GPT-family models get every tool up front instead.

Loading a tool doesn't change the tools sent with each request, so the start of the prompt stays byte-identical from turn to turn and the provider's prompt cache keeps working. The loaded definition arrives as the result of ToolSearch, and the agent calls the tool through UseTool. On routes where the provider can defer tools itself, Nib uses that for the models that support it.

MCP tools

Tools from MCP servers appear as mcp__<server>__<tool>. They are deferred unless the server marks them as always loaded. Two extra tools, ListMcpResourcesTool and ReadMcpResourceTool, read resources the servers expose.

Limiting tools

  • Deny a tool for everyone with a permission rule: "deny": ["WebSearch"].
  • Deny it for one run: nib --disallowedTools WebFetch.
  • Give a subagent a narrower set with tools: in its frontmatter, or take tools away from a skill with disallowed-tools:.

На этой странице