Reference
Documentation
FPGAi — AI assistant for FPGA and digital design engineers.
Installation
FPGAi is a Python CLI agent. Requires Python 3.10+ and pip.
pip install fpgai
For simulation features, also install iverilog (Icarus Verilog):
# macOS brew install icarus-verilog # Ubuntu / Debian sudo apt install iverilog # Windows (WSL recommended) sudo apt install iverilog
Yosys (optional) enables synthesis checks after code generation. Install via your package manager or yosyshq.net.
Authentication
On first run (and after /logout), FPGAi shows a short setup wizard in the terminal. Your token is stored locally in ~/.fpgai/config.toml.
# First run launches the setup wizard automatically fpgai
The wizard offers two ways to sign in:
Email + password
Enter the credentials for your FPGAi account.
One-time token
For Google or GitHub sign-in, log in on the website and generate a one-time token from your Dashboard (or Agent Login), then choose "One-time token" in the wizard and paste it.
To switch accounts later, run /logout inside FPGAi and restart it.
Basic Usage
Navigate to your Vivado project directory and start FPGAi. Type your request in natural language.
cd ~/vivado/my_project fpgai
> Write a UART TX module, 115200 baud, 100MHz clock, 8N1
Searching knowledge base… 4 relevant docs found
I'll create a UART TX module. Defaulting to async reset (active-low), 8N1 framing, parameterized baud divider.
✓ src/uart_tx.v written
✓ tb/uart_tx_tb.v written
Running simulation… 8/8 tests passed ✓
FPGAi writes files directly into your project directory. Every write is backed up automatically — use /undo to restore.
Slash Commands
Type these at the FPGAi prompt at any time. Press Tab to autocomplete commands and their arguments.
Chat & Sessions
/newStart a new chat session.
/clearClear the terminal screen.
/compactSummarize and compress the current chat history (saved to .fpgai/context_summary.md) to free up context.
/historyList your past chat sessions.
/search<query>Search across your chat history.
File Management
/undoRevert the most recent file change from its automatic backup.
/filesList FPGAi-generated files in the project, with backup counts.
/diffShow the diff of the last file change.
/project[path] | infoChange the active project directory, or show its HDL and generated files.
/constraints[board] | listGenerate a constraint file for a board, or list supported boards.
Simulation & Waveforms
/simulate<file>Run simulation with the self-correcting loop (up to 10 fix iterations). Requires iverilog.
/waveform[open | signals | <file>]Open the latest VCD in GTKWave, or list its signal names.
/analyze-waveform<file.vcd|.fst>AI waveform analysis — anomaly detection plus LLM interpretation (credit cost: 5).
Analysis & HDL
/explain<text or file>Explain code, an error, a datasheet excerpt, or a Tcl script.
/tcl<intent>Generate Vivado/Quartus Tcl from a plain-language intent.
/image[path] [question]Send a screenshot or diagram to chat (no path = clipboard image; or just press Ctrl+V in the prompt). Requires a vision-capable model.
/fsm<file> [module]Extract a finite-state-machine diagram (Mermaid + SVG).
/blocks<file> [top]Render a module-level block diagram.
/document<file>Generate Markdown documentation for a module.
/cdc<file>First-pass clock-domain-crossing analysis (LLM-tier; not a Spyglass replacement).
/estimate<file>Estimate FPGA resource usage before synthesis.
/validate-constraints<constraint> [rtl ...]Cross-check an XDC/SDC file against the RTL.
/lint<file>Lint a file (Verilator/Icarus/GHDL syntax check plus custom and builtin style rules). Local only, no LLM call.
/review[file]AI code review of a file — omit the file to review the whole project.
/save<name>Write the last code block to a file (recovery when no file marker was emitted).
Settings
/modelChoose the LLM model (from those your administrator enabled).
/modeToggle code-sharing mode (query-only ↔ full-context).
/permissions[default|plan|auto-edit|yolo]Show or change local write guardrails.
/hdl<verilog|systemverilog|vhdl>Set your preferred HDL.
/apikeySet or remove your own LLM API key (BYOK).
/settingsShow all current settings.
Account & System
/accountShow your account info.
/usageShow your usage stats.
/feedback[text]Send product feedback.
/upgradeOpen the pricing page in your browser.
/logoutLog out and clear the stored token.
/helpList all available commands.
/versionShow the agent version.
/quitExit FPGAi (also /exit, or Ctrl+C).
Self-Correcting Testbench
FPGAi's signature feature: it doesn't just generate a testbench — it runs it and fixes errors automatically.
Ask for a testbench in natural language (e.g. "write a testbench for uart_tx"), then run /simulate <file> to start the loop.
Self-correction requires iverilog on your PATH. Free plan users get basic testbench generation without self-correction; the Professional plan enables the full loop.
Synthesis Check
After writing a Verilog or SystemVerilog file, FPGAi automatically runs a synthesis check using Yosys (if installed).
✓ src/spi_master.v written
Running synthesis check…
Synthesis OK — 142 cells, 89 wires
⚠ Latch inferred in state machine — consider adding a default case
Synthesis check is skipped if Yosys is not installed. Install it to catch latches, combinational loops, and unsynthesizable constructs before simulation.
Constraint Files
Generate XDC or SDC constraint files for popular FPGA boards.
# List supported boards /constraints list # Generate for a specific board /constraints arty-a7-35t /constraints basys3 /constraints de10-nano
Generated files include clock constraints and TODO markers for I/O pin assignments that require board-specific knowledge. See Supported Boards for the full list.
Project Context
FPGAi can read your existing project files and use them as context for generation and debugging.
Auto-context (query-only mode)
FPGAi reads file names and directory structure. No source code is sent to the server. This is the default.
Full-context mode (/mode)
Toggle with /mode. Relevant source code is sent to the AI alongside your prompt for better results. It exists in RAM during request processing and is not stored.
You control this. Change the default in ~/.fpgai/config.toml under the code_sharing_mode key (query-only or full-context).
Model Selection
FPGAi supports multiple LLM backends. Your administrator configures available models; you can choose from what's enabled.
# Inside FPGAi, switch models with the /model command /model # Or set a default in ~/.fpgai/config.toml: # [preferences] # default_model = "claude-sonnet-4-6"
Hosted model usage is limited by your monthly AI usage credit plus prepaid credit. Team usage draws from the shared Team wallet first and then only the caller's personal wallet, so one member cannot spend another member's personal credit. Bring your own API key for any supported provider to pay provider token costs directly; chat, RAG, and PageIndex LLM calls use your key when BYOK is active.
Configuration
Config file lives at ~/.fpgai/config.toml. Edit it with any text editor.
[server] url = "https://fpgaitool.com" [preferences] default_model = "claude-sonnet-4-6" code_sharing_mode = "query-only" # or "full-context" auto_update_check = true
To point at a self-hosted instance, set the url under [server] in ~/.fpgai/config.toml.
Supported Boards
| Board Key | Board | FPGA | Format | Clock |
|---|---|---|---|---|
| arty-a7-35t | Digilent Arty A7-35T | Xilinx Artix-7 | XDC | 100 MHz |
| basys3 | Digilent Basys 3 | Xilinx Artix-7 | XDC | 100 MHz |
| de10-nano | Terasic DE10-Nano | Intel Cyclone V | SDC | 50 MHz |
More boards coming soon. Request a board by opening a GitHub issue or contacting support.