find_model
Search for model/subcircuit candidates across loaded or built-in libraries using fuzzy or exact matching, returning ranked results with port, parameter, and device details.
Instructions
Find model/subcircuit candidates across loaded (and optionally built-in) libraries. Default is fuzzy matching — finds typos, case variants, and near-neighbour part numbers (e.g., '2N3905' → '2N3904'); pass exact=true to only return the exact case-insensitive match. Returns ranked candidates with similarity score and an include_directive emitted in the simulator's native path form (on WSL this is the Windows path LTspice.exe expects, not the /mnt/c Linux path). Each candidate carries ports (the .SUBCKT port list, empty for .MODEL) and params (default parameter values from the body / params: clause). For .MODEL devices it also carries device_type (the SPICE device token: NPN, PNP, D, NMOS, VDMOS, NJF …) and, for recognised tokens, a usage connection-order string (e.g. Qxxx C B E <name>) — a .MODEL gives parameters but not node order, and wiring the part in the wrong order simulates silently wrong.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| full | No | Include the full SPICE definition text + parameter list of every returned candidate. Folds the old ``model_info`` tool into this one — call ``find_model(name=X, exact=true, full=true)`` for a single model's body. | |
| name | Yes | Model/subcircuit name to match (case-insensitive) | |
| exact | No | Only return the exact case-insensitive match (score=1.0) if any; skips fuzzy scoring. | |
| limit | No | Max suggestions to return (1-25). Ignored when exact=true. | |
| cutoff | No | Minimum fuzzy similarity ratio (0.0-1.0). Lower = more matches, noisier. Ignored when exact=true. | |
| format | No | Response format: 'json' for structured data, 'text' for human-readable | |
| include_builtin | No | Also walk built-in simulator libraries (slower; lazy-parses all built-ins on first call). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| exact | No | ||
| query | No | ||
| cutoff | No | ||
| results | No | ||
| include_builtin | No |