AI Agent
Run Claude Code in a terminal next to your rules, with your own Claude subscription. The agent edits rules as files, you review every change before it reaches the document.
The agent side bar runs Claude Code, Anthropic's coding agent, in a real terminal inside the editor. It works on the iLogic rules of the active document: it reads and edits them, checks them with the same compiler the editor uses, runs them when you allow it, and looks up the Inventor API. Every change it makes comes back to you as an unsaved edit with a diff, and nothing reaches the Inventor document until you accept it.
Claude Code runs under your own Claude account. You need Claude Code installed and a Pro, Max, Team or Enterprise plan (or a Console account). iLogic Code never sees your sign-in and is not billed for anything. A session sends what the agent works on to Anthropic; see AI Agent Privacy. OpenAI Codex will follow as a second agent.
Opening the agent
Click the terminal icon in the rail (below Snippets), or press Ctrl+Alt+B. The side bar opens to the right of the editor; drag its left edge to resize it, or collapse it to a thin strip with the button in its header.
Ctrl+Shift+A moves the keyboard between the editor and the terminal. While the terminal has the keys, it shows an accent outline and the hint Keys go to the terminal; almost every key then goes to Claude Code (Ctrl+C, Ctrl+R, Esc, Shift+Tab...), except the agent shortcuts.
When Locals and Watches are docked on the right, they become tabs of the side bar next to Agent.
Installing and signing in
The panel guides you through the first start:
| State | What you see |
|---|---|
| Claude Code not found | Install Claude Code runs Anthropic's official installer visibly in a terminal session. Set path manually opens Settings → AI Agents if it is installed somewhere unusual. |
| Installed, not signed in | Sign in starts Claude Code, which opens your browser for its own login. |
| Ready | Pick a profile (Claude Code or PowerShell) and Start session, or Resume last conversation once the document has one. |
iLogic Code finds Claude Code in the native installer's folder, WinGet's links folder, an npm global install, or on PATH. When it finds more than one, sessions use the newest version, so an install you stopped updating doesn't get picked by accident. Settings → AI Agents lists every install it found; Use pins one, and with one pinned, Settings and the panel tell you when another install is newer.
Update in Settings → AI Agents updates Claude Code the way it was installed, visibly in a terminal session: claude update for the native installer, winget upgrade --id Anthropic.ClaudeCode for WinGet, and npm install -g @anthropic-ai/claude-code@latest for npm (WinGet and npm installs don't update themselves). Close running Claude Code sessions first; they keep claude.exe in use.
Each new session opens with the ExtrabbitCode banner; press any key to skip it, or turn it off in Settings.
Claude Code starts with its light or dark theme to match the editor's theme (the ANSI variants, which draw with the terminal's own colors). Your Claude Code theme setting is left as it is for your other terminals. After switching the editor's theme, restart the session to match again.
Sessions
Every session is a tab in the side bar with a status dot:
| Dot | Meaning |
|---|---|
| Blue | Working (output is streaming) |
| Gold | Waiting for you (Claude Code asked for permission or finished a turn) |
| Green | Ready at its prompt |
| Grey ring | Exited |
The toolbar shows which document the session works on, and restarts or ends the session or opens its folder. To start over with an empty conversation, type /clear in Claude Code (cls in PowerShell). Claude Code allows one session per document; PowerShell sessions are unlimited. While the side bar is hidden, the rail icon and the status bar report what the agent is doing.
If the active document changes, a running session keeps working on its own document and offers to start a session for the new one. When Inventor restarts, previous sessions come back as cards with Resume conversation, which restarts Claude Code where it stopped. If there is no earlier conversation to pick up (nothing was said in that session), a new one starts in the same tab.
What the agent works with
Each document gets its own agent folder (see Files & Logs). When a session starts, iLogic Code writes:
rules\: the document's rules, one.vbfile per rule. The agent edits these with its own tools.AGENTS.md: instructions about iLogic, the folder, and the tools below, plus your own instructions.
External rule folders on local drives are added to the session too. Network folders (\\server\share) are not, because Claude Code can't add them.
The session is also connected to iLogic Code's tools for Inventor:
| Tool | What it does |
|---|---|
check_rule | Compiles a rule with the editor's compiler and returns its errors and warnings. Works for document and external rules: a name is a document rule first, then an external rule of that name; a full path is an external rule file |
run_rule | Runs a rule as saved (a document rule, or an external rule by name or path) and returns the outcome, errors and log lines. Refused while the rule has unsaved or unaccepted changes |
get_run_log | The most recent runs from the run log |
list_rules, list_parameters, get_active_document | The document's rules, parameters and details |
get_editor_context | The rule you are looking at, your selection and the Error List |
open_rule | Opens a document or external rule in the editor |
create_rule | Creates a new rule, optionally from one of your templates (variables filled in). When the agent passes code or a template, the rule is created empty and the code opens for your review like any other change |
list_templates, get_template | Your rule templates from the Templates tab, in your order, with their descriptions; a template's text, optionally with its variables filled in for a rule |
rename_rule, delete_rule | Renames or deletes a rule. Both are refused while the rule has unsaved or unaccepted changes; a deleted rule's text is kept in the recovered folder first |
get_rule_behavior, set_rule_behavior | Reads or sets a rule's iLogic flags: suppressed, silent operation, fire dependent rules immediately, don't run automatically |
list_external_rules, run_external_rule | The external rule files, and running one on the active document |
search_snippets | Searches iLogic's snippet library for idiomatic code |
get_model_tree, list_iproperties, list_open_documents | The model browser tree, the document's iProperties, and the open documents |
inventor_api_docs | Looks up the Inventor API reference for your Inventor version on inventor.autodeskapi.dev |
Claude Code asks you before it uses a tool, unless you allow it for the session. Running rules (run_rule, run_external_rule) follows Allow the agent to run rules instead: with Ask, Claude Code asks before every run whatever its permission mode (Claude Code 2.1.214 or later), Always runs them without asking, and Never makes them refuse. A bundled inventor-api-docs skill teaches the agent how to use the API reference.
Reviewing the agent's changes
When the agent changes a rule file, the rule's tab opens as unsaved, marked with a small bot glyph (also in the rule list), and shows a diff: the rule as saved in the document on the left, the agent's version on the right. The right side stays editable, with completions, hover and live errors as in the normal editor, so you can adjust the agent's version before you accept it. The review ends with one of:
| Action | Result |
|---|---|
| Accept and save | Saves the right side (the agent's version, with your adjustments) into the document |
| Revert | Drops the change, in the editor and in the agent's file |
If you had your own unsaved edits in that rule, they stay in the editor and a banner offers Compare, Take agent version or Keep mine.
A new .vb file the agent creates appears in Document Rules marked from agent; open it to create the rule and review its text, or dismiss it.
External rules are plain files, so the agent's change to one is saved right away. An open tab of it reloads, or, when you have unsaved edits in it, shows a banner to compare, take the file's version or keep yours (see Rules Explorer).
Handing context to the agent
These actions paste a reference at Claude Code's prompt and move the keys to the terminal. Nothing is sent: add your question and press Enter.
| Action | Pastes |
|---|---|
Send selection to agent (editor right-click, Ctrl+Alt+A) | @rules/Main.vb#L10-12 |
| Ask agent on an Error List row | The rule, line and the error message |
| Ask agent on an Error or Fatal log line | The rule, the run time and the message |
| Open agent for this rule (right-click a tab, or a rule in Document Rules or External Rules) | @rules/Main.vb, or an external rule's full path |
| Drag a rule (from Document Rules, External Rules or its tab) onto the terminal | The same reference; drop several to name them all |
If no session runs for the document, one starts first.
You can also just name a rule in your message: the agent finds the document's rules in its rules\ folder and lists them with its tools. Claude Code completes file names after @ at its prompt too, so @rules/ offers every rule of the document. External rules on local drives are readable by the agent; rules on a network share (\\server\share) aren't added to the session, so Claude Code asks before it reads one.
Your instructions
Tell the agent about your conventions once, for example naming rules, a header every rule starts with, or how progress is reported. Open Edit instructions in Settings → AI Agents, or Agent instructions in the side bar's new-session menu. The instructions open as a Markdown file in an editor tab: write, save with Ctrl+S, and close it like a rule. If you close it with unsaved changes, you are asked whether to save them.
The first time, the file starts with a short template inside a <!-- --> comment. Text inside comments is not sent to the agent, so the template's examples only apply once you write them out. The file is agent-instructions.md in the editor's data folder (see Files & Logs), and its text is added to every agent session's AGENTS.md when the session starts: start a new session after saving.
Claude Code also reads your own ~/.claude/CLAUDE.md, which applies to all your Claude Code sessions, not only the ones in iLogic Code.
Settings
See Settings → AI Agents for the Claude Code path, extra arguments, permission mode, whether the agent may run rules, and the terminal.
Privacy
What you and the agent work on in a session, such as rule code from the document, is sent to Anthropic under your account and its terms. iLogic Code itself sends nothing to Anthropic. AI Agent Privacy lists what a session can send, what is stored on your machine, and how to control it.