CktGen: Automated Analog Circuit Design with Generative Artificial Intelligence

Yuxuan Hou, Jianrong Zhang, Hua Chen, Min Zhou, Faxin Yu, Hehe Fan, Yi Yang, Roger Zimmermann

Abstract

The automatic synthesis of analog circuits presents significant challenges. Most existing approaches formulate the problem as a single-objective optimization task, overlooking the fact that design specifications for a given circuit type can vary widely across applications. To address this limitation, we introduce specification-conditioned analog circuit generation, a task that directly generates analog circuits based on stated specifications. We propose CktGen, a simple yet effective variational autoencoder model that maps discretized specifications and circuits into a joint latent space and reconstructs the circuit from that latent vector. To address the one-to-many relationship between specifications and circuits, we decouple the encoding process and align their mapped latent space using contrastive training and classifier guidance. By canonicalizing the latent space, we can further optimize and search for an optimal circuit that meets the valid target specification. Experimental results on the open circuit benchmark demonstrate that CktGen achieves substantial improvements over existing state-of-the-art methods.

Introduction

Analog circuit design remains a labor-intensive process heavily reliant on expert intuition, contrasting sharply with the highly automated nature of digital design. Current Electronic Design Automation (EDA) tools typically treat circuit synthesis as a single-objective optimization problem, such as maximizing a specific Figure of Merit (FoM). This approach suffers from two major flaws: rigidity and the inability to handle one-to-many mappings. If design requirements shift—for instance, requiring higher gain at the cost of bandwidth—the optimization process must often restart from scratch. Furthermore, a single set of performance specifications can be met by multiple distinct circuit topologies and device sizes. Standard machine learning models often struggle with this diversity, collapsing into non-functional "average" solutions.

Methodology

CktGen addresses these challenges through a conditional generative framework designed to map performance specifications directly to viable circuit implementations.

Overview of the CktGen framework showing (a) the training phase with joint latent space alignment and (b) the inference phase using multi-armed bandit optimization.

Architectural Components

The model architecture consists of four primary modules:

  1. Dual Encoders: A transformer-based circuit encoder ($E^{ckt}$) and a multilayer perceptron (MLP) specification encoder ($E^{spec}$) map inputs into a shared "canonical" latent space. Specifications are discretized into interval-based classes to stabilize training.
  2. Alignment Strategy: To organize the latent space, the framework employs contrastive training (InfoNCE loss) to separate different specification classes and classifier guidance to ensure circuits clustered together meet their intended targets.
  3. Autoregressive Generator: The generator ($G$) is a GPT-like transformer that reconstructs circuits piece-by-piece (nodes, positions, and edges), ensuring the output is a valid Directed Acyclic Graph (DAG).
  4. Test-Time Optimization: During inference, a Multi-Armed Bandit (MAB) algorithm searches the learned latent space for the optimal circuit satisfying user constraints without requiring model retraining.
Detailed architecture of CktGen, including the circuit encoder (a), specification encoder (b), latent space alignment (c), and the autoregressive transformer decoder (d).

Experimental Setup and Results

The study utilizes the Open Circuit Benchmark (OCB), specifically Ckt-Bench-101 (10,000 circuits) and Ckt-Bench-301 (50,000 circuits). Specifications include key metrics: Gain, Bandwidth (BW), and Phase Margin (PM).

CktGen demonstrates a significant leap over previous baselines such as PACE and CktGNN:

  • Retrieval Precision: On Ckt-Bench-101, CktGen achieved a Top-1 retrieval precision of 35.73%, compared to just 3.4% for the next best baseline.
  • Specification Accuracy (Spec-Acc): CktGen reached 47.57% accuracy in hitting target specifications, while all baselines remained below 3%.
  • Design Success: When searching for circuits meeting specific thresholds, CktGen achieved over 85% accuracy across both benchmarks.
  • Efficiency: The model generates a circuit in approximately 4.59 ms, enabling real-time design exploration.

Conclusion and Future Work

CktGen represents a major advancement in automated analog design by successfully navigating the complex one-to-many mapping between specifications and topologies. However, limitations remain, particularly regarding data scarcity for rare specifications and the lack of physical layout awareness. Future work will focus on integrating closed-loop feedback with SPICE simulators to refine designs based on high-fidelity physics and extending the framework to account for layout parasitics in silicon manufacturing.

Summary updated

Abstract

The automatic synthesis of analog circuits presents significant challenges. Most existing approaches formulate the problem as a single-objective optimization task, overlooking the fact that design specifications for a given circuit type can vary widely across applications. To address this limitation, we introduce specification-conditioned analog circuit generation, a task that directly generates analog circuits based on stated specifications. The motivation is to find an effective method that leverages existing well-designed circuits to improve automation in analog circuit design. Specifically, we propose CktGen, a simple yet effective variational autoencoder model that maps discretized specifications and circuits into a joint latent space and reconstructs the circuit from that latent vector. Notably, as a single specification may correspond to multiple valid circuits, naively fusing the specification information into a generative model does not capture these one-to-many relationships. To address this, we first decouple the encoding process of circuits and specifications and align their mapped latent space. Then, we employ contrastive training with a filter mask to maximize differences between encoded circuits and specifications. Furthermore, classifier guidance along with latent feature alignment promotes the clustering of circuits sharing the same specification, thus avoiding model collapse into trivial one-to-one mappings. By canonicalizing the latent space with respect to the specifications, we can further optimize and search for an optimal circuit that meets the valid target specification. We conduct comprehensive experiments on the open circuit benchmark and introduce several metrics to evaluate cross-model consistency in the specification-conditioned circuit generation task. The experimental results demonstrate that CktGen achieves substantial improvements over existing state-of-the-art methods.
BibTeX
@inproceedings{hou2025cktgen,
  author = {Yuxuan Hou and Jianrong Zhang and Hua Chen and Min Zhou and Faxin Yu and Hehe Fan and Yi Yang and Roger Zimmermann and Yi Yang},
  title = {{CktGen: Automated Analog Circuit Design with Generative Artificial Intelligence}},
  booktitle = {Engineering},
  year = {2025},
  url = {https://openreview.net/forum?id=juItKzaoIV},
}
Figure