Skip to content
AI.info

Research

Multi-Objective Coevolution of Prompts and Templates for Circuit Approximation

Overview Research area: Evolutionary computation (cs.NE), specifically multi-objective co-evolution and its application to automated approximate digital circuit design, combined with large language mo

arXiv
2606.13089
Published
2026-06-11
Authors
Martin Tomasovic, Lukas Sekanina

AI summary

Overview

  • Research area: Evolutionary computation (cs.NE), specifically multi-objective co-evolution and its application to automated approximate digital circuit design, combined with large language model (LLM) prompting.
  • Technical level: Advanced. The paper assumes familiarity with Pareto-based multi-objective selection (NSGA-II), Cartesian genetic programming, circuit error metrics (WCE, MSE), and LLM prompting.
  • Scope in one sentence: The paper introduces and empirically evaluates a co-evolutionary algorithm in which an electrically represented population of 8-bit approximate multipliers and a population of LLM prompt templates evolve together, using an off-the-shelf LLM as the circuit-modification operator, targeting user-specified error–area specifications.

What This Paper Is About

Approximate multipliers deliberately allow output errors in exchange for smaller area, lower power, and lower latency, which suits error-resilient workloads such as neural networks. The best existing designs, collected in the EvoApproxLib library, were produced by long, expensive Cartesian genetic programming (CGP) runs, so improving on them is hard. This paper asks whether a general-purpose LLM, with no domain-specific training on approximate circuits, can be steered by evolved prompt templates to produce 8-bit approximate multipliers that reach better error–area trade-offs than EvoApproxLib designs near a user-given target.

Key Contributions

  1. First LLM-based multi-objective co-evolutionary system for circuit approximation. The authors state this is the first such system and that it requires no pretraining on a set of approximate circuits.
  2. Improved trade-offs over a state-of-the-art library. For 8-bit approximate multipliers the method created circuits with better trade-offs than the highly optimized circuits in EvoApproxLib.
  3. A second evolutionary loop for prompts. Prompt templates are evolved as a separate population, evaluated on a subset of circuits, and modified with LLM-driven mutation and crossover operators, so that the way the LLM is instructed adapts alongside the circuits.
  4. A controlled comparison of search strategies. Hill climbing, co-evolution with one LLM call per template (CoEA-1-15), and co-evolution with three LLM calls per template (CoEA-3-5) were compared under an identical budget of LLM calls.

Main Findings

  • Co-evolution beats hill climbing. Under the Mann–Whitney U test at α = 0.05, the hypervolume comparison of CoEA-3-5 vs hill climbing gave U = 100.00, p = 0.0002 (significant), and CoEA-1-15 vs hill climbing gave U = 100.00, p = 0.0002 (significant).
  • The two co-evolutionary variants are statistically comparable. CoEA-3-5 vs CoEA-1-15 gave U = 52.00, p = 0.9097 (not significant). In the per-generation comparison, CoEA-3-5 (generation 5) vs CoEA-1-15 (generation 15) gave U = 75.00, p = 0.0638 (not significant), while CoEA-3-5 (generation 5) vs CoEA-1-15 with a reduced 14 generations gave U = 80.00, p = 0.0256 (significant).
  • Multiple LLM calls per template widen the Pareto front. With k = 3, CoEA produced the highest number of unique solutions on the Pareto front, in a search the authors describe as more exploratory, reaching many solutions far from the specification.
  • Hill climbing converges narrowly. The hill-climbing algorithm produced the least competitive results and tended to converge to a few almost identical solutions.
  • Runtimes are close. The average execution time of CoEA-3-5 was slightly shorter than CoEA-1-15 (207 min vs 223 min).
  • New WCE–area trade-offs. Over 32 target error–area pairs, in 70 cases CoEA multipliers showed trade-offs between WCE and area not present in EvoApproxLib, and 24 of those lie on the global Pareto front of all 8-bit multipliers. The EvoApproxLib version used for the comparison contains 24 912 unsigned 8-bit approximate multipliers.
  • New MSE–area trade-offs. Repeating the experiment with MSE as the target error metric, 63 implementations showed trade-offs unseen in EvoApproxLib, and 23 of them are on the global Pareto front.
  • LLM inference dominates runtime. A single Qwen3-Coder-480B call to generate a new circuit takes about 10.0 seconds on average; GPT-OSS-120B responds to a template-modification prompt in approximately 5.3 seconds; evaluating the error of a single candidate circuit takes only about 0.5 seconds on average.
  • Far fewer circuit evaluations than CGP. Mrazek et al. report that a single CGP-based circuit approximation for one target error consumes up to 10^6 generations (population size 4), taking 7.8 to 147.7 min on a 2.4 GHz Intel Xeon CPU. The LLM-based approach requires one to two orders of magnitude fewer circuit evaluations.

Methodology in Plain English

The method maintains two populations that are synchronized every generation.

The circuit population holds candidate unsigned 8-bit multipliers, each written as a list of logic expressions over operand bits (INA, INB), internal nodes (N), and output bits (OUT), using C-style operators plus constants and parentheses — a form the authors chose because it resembles the logic equations LLMs commonly see. The initial population is seeded with approximate 8-bit multipliers of various quality. Each circuit is scored on two objectives: error (WCE or MSE computed for all 2^16 input vectors) and chip area, estimated as the sum of gate sizes for the 45 nm technology (INV 1.40, AND 2.34, OR 2.34, XOR 4.69, NAND 1.87, NOR 2.34, XNOR 4.69 μm²). A hard constraint requires exact multiplication whenever at least one operand is zero; violating it assigns an error fitness of infinity.

The template population holds prompt blueprints containing fixed text and placeholders such as {approx_circuit_wce}, {approx_circuit_area}, {target_wce}, and {target_area}. Placeholders can refer to specific circuits in the current population, for example a random circuit, the circuit closest to target, the second closest to target, the circuit with the best error metric, or the circuit with the best area. Templates are kept in an external JSON file and include categories such as generate, mutation, crossover, and post-process prompts.

To create a new circuit, a template is filled in, sent to the LLM, and repeated k times per template to yield k offspring. Parent and offspring circuits are merged and reduced with the RankAndCrowdingSurvival function from the pymoo library, which applies NSGA-II Pareto ranking and crowding distance. Template fitness uses two objectives: the ratio of valid to invalid circuits the template generated, and the average absolute difference between the target error and the errors of the generated circuits. Templates are then altered by LLM-driven mutation and crossover prompts (chosen at random), with crossover prompts asking the model to combine two templates toward smaller area at the same or lower WCE. Template parents and offspring are likewise merged and reduced by RankAndCrowdingSurvival.

Experimental settings: circuit population n = 30, k = 3 LLM calls per template, maximum templates y = 3m; template population m = 8, mutation probability 0.9, crossover probability 0.9, 3 prompt templates for mutation and 3 for crossover, and g = 27 generations per co-evolutionary run. Circuit generation used Qwen3-Coder-480B (a mixture-of-experts coding model with 480B total parameters, about 35B active per inference, optimized for long contexts up to 256k tokens). Template modification used GPT-OSS-120B (a 120B-parameter open-weight model) at temperature 0.4. The software is Python calling external LLMs, with circuit error simulation written in optimized C with OpenMP parallelization. For the strategy comparison, the budget was LLMpR = 450 calls per run over 10 independent runs, targeting T_E(WCE) = 21387 and T_A = 453 μm²; the hill-climbing baseline started from an EvoApproxLib circuit 1.2×–1.5× worse in both criteria than the target and used a single mutation template. Hypervolume was computed as the dominated area with respect to a reference point defined as the worst observed values increased by 1%. The models were accessed through the shared e-infra.cz infrastructure, so inference times were outside the authors' control.

Why This Matters

  • Research impact: The work shows that co-evolving the prompt itself, not just the artifact, is a useful mechanism when an LLM's output must satisfy a global, hard-to-articulate specification. It also extends co-evolutionary algorithms into approximate circuit design, where the authors note CoEAs had not previously been applied.
  • Real-world applications:
    • Error-resilient neural network accelerators, where multiplication dominates both training and inference and modest output error is tolerable.
    • Edge and embedded hardware, where area, latency, and power budgets are tight and the target specification approach (target error plus target area) matches real design flows.
    • ASIC and FPGA design exploration, using the produced multipliers as building blocks or as starting points near a desired operating point.
    • Hardware design automation more broadly, since the method needs only a general coding LLM rather than a model trained on a proprietary circuit dataset.
  • Industry relevance: The approach avoids costly domain-specific model training and, per the authors' comparison, needs one to two orders of magnitude fewer circuit evaluations than CGP-based approximation, though overall runtime is still dominated by LLM inference (10.0 seconds per circuit-generation call versus 0.5 seconds per circuit evaluation). The authors position this against GPTAC by Yi et al., the only prior LLM work on approximate circuit design, which relies on a domain-specific pretrained model and does not exhibit evolutionary algorithm properties.

Future Directions

  • A detailed statistical analysis of long-run behavior, since the strategy comparison found CoEA-3-5 and CoEA-1-15 statistically indistinguishable at 450 LLM calls per run but the long runs used k = 3 and g = 27.
  • A thorough comparison of alternative CoEA configurations and LLM configurations, including which models and temperatures work best for circuit generation versus template modification.
  • Further optimization of the core algorithm to reduce execution time, given that LLM inference dominates the runtime.
  • Extending the method to additional types of approximate circuits beyond 8-bit multipliers, and exploring further design criteria beyond error and area.

Target Audience

Researchers and practitioners in evolutionary computation, approximate computing, and LLM-driven program synthesis; hardware and EDA engineers interested in automating error–area trade-off exploration; and readers studying how prompt engineering can be turned into an evolvable, self-adapting component of a search algorithm. The paper is written at an advanced level, requiring background in multi-objective optimization and digital circuit representation.

Authors’ abstract

Approximate multipliers deliberately relax computational accuracy to achieve gains in power efficiency, latency, and silicon area, which makes them well-suited for error-resilient applications such as neural networks. In this work, we introduce a co-evolutionary algorithm that leverages an off-the-shelf large language model (LLM) without requiring domain-specific training to automate the design of optimized 8-bit approximate multipliers. The approach simultaneously evolves a population of candidate circuits and a population of prompt templates that steer LLM-driven modifications. Experimental results for several target design objectives demonstrate that the proposed method discovers approximate multipliers with improved error-area trade-offs compared to highly optimized circuits from the EvoApproxLib library.

Read the original paper