Skip to content

Enable Domain Caching to Speed Up Solving #128

Description

@vedran-kasalica

Motivation

Encoding domain annotations into CNF often dominates runtime, sometimes taking more than 10× the time of the actual solving step. Since domains are semi-static, re-encoding them for each run is wasteful and slows down APE significantly.

By introducing domain caching, we can reuse pre-computed encodings and only recompute the run configuration (inputs, outputs, constraints). This will reduce redundant work and improve performance.

Evidence

The table below (source Kasalica V., Section 7.1) shows that in all tested cases, encoding takes longer than solving, often by an order of magnitude.

Image

Goal

Introduce a caching mechanism for domain CNF encodings:

  • Cache domain CNF encoding per workflow length
  • Separate domain setup from run configuration
  • Reuse cached encodings and append only run configuration on each run

Tasks

  • Refactor to disentangle domain setup and run configuration
  • Implement domain CNF caching per workflow length
  • Ensure run configuration can be appended to cached domains
  • Update tests and documentation

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions