Skip to main content

Open-source computational logic engine for global building codes and standards.

Project description

aeclib

Open-source automated code compliance building codes and standards.

aeclib translates building code provisions into executable and testable logic.

Installation

pip install aeclib

Intent

The goal of aeclib is to provide a unified "Logic Layer" for the AEC industry to support automated compliance and computational design.

Usage

aeclib is designed as a Stateless Logic Layer. It provides the atomic building blocks of architectural compliance without dictating a specific data schema.

Atomic Logic

Each function in aeclib maps to a specific engineering or code requirement. You are responsible for mapping your own data (JSON, BIM, or Database) to the function's parameters.

Compositional Compliance

The library is designed to be composed into your own application logic. Below is an example of how a user might bring their own JSON design data and map it to a custom Python class to run a specific chapter's compliance check:

{
  "space_id": "RM-101",
  "function_type": "business",
  "gross_area": 1500.0,
  "net_area": 1200.0,
  "design_occupancy_count": 12
}
from aeclib.occupancy import validate_occupant_load_without_fixed_seating, validate_increased_occupant_load

class MyProjectChecker:
    def check_space_occupancy(self, data: dict):
        # 1. Check required minimum occupant load (Section 1004.5)
        is_load_valid = validate_occupant_load_without_fixed_seating(
            function_type=data["function_type"],
            gross_area=data["gross_area"],
            net_area=data["net_area"],
            design_occupancy_count=data["design_occupancy_count"]
        )

        # 2. Check maximum density limit (Section 1004.5.1)
        is_density_valid = validate_increased_occupant_load(
            area=data["gross_area"],
            occupant_count=data["design_occupancy_count"]
        )

        return is_load_valid and is_density_valid

Expected Output

When a design fact fails to comply, the library will return False and log a detailed warning:

WARNING:aeclib:Compliance Fail: Design occupancy (35) is less than required minimum of 40 for educational_classroom (net area: 800.0, factor: 20).

When a design is compliant, the function returns True.

License

Licensed under the Apache License 2.0.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aeclib-0.1.0.tar.gz (8.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

aeclib-0.1.0-py3-none-any.whl (8.9 kB view details)

Uploaded Python 3

File details

Details for the file aeclib-0.1.0.tar.gz.

File metadata

  • Download URL: aeclib-0.1.0.tar.gz
  • Upload date:
  • Size: 8.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for aeclib-0.1.0.tar.gz
Algorithm Hash digest
SHA256 94b72c8d1b64a8a8a5f96498265f19ad2b5d022566d45ac2f2a854a2bfe784d5
MD5 7b3c7e3279ca8b2d8c457cbc2a767617
BLAKE2b-256 c11e615a6e95e95d499c27b94669ecdffceb50aa5d688fa259fdd26bbdb60af6

See more details on using hashes here.

File details

Details for the file aeclib-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: aeclib-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for aeclib-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 044dc7f815cb95543a2309cb0ad2c3b99110fbe285b130276d8ec8d31728dcbd
MD5 da6e753b26fcbf8ac05806f65b7018ae
BLAKE2b-256 cfea35444be74051cf5079ee3109496ec66a80255697f89cc8d08fd6cad2ca04

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page