bclearer-core
The bclearer_core package is the foundational component of the bCLEARer™ framework, providing essential utilities and services required for the data pipeline architecture in semantic engineering. It encompasses core functionalities that are utilized across the entire framework, ensuring consistency and extensibility.
Overview
The bclearer_core library offers a collection of modules responsible for handling common tasks and configurations that are integral to the bCLEARer framework. These components form the backbone of the system and enable efficient management of knowledge, configurations, constants, and stages within the pipeline.
Structure
The package consists of several key modules:
- ckids: Manages unique identifiers within the bCLEARer framework, ensuring consistency and traceability across components.
- common_knowledge: Contains shared knowledge and common utilities that are used across the framework.
- configuration_managers: Responsible for managing and handling various configurations for bCLEARer applications and processes.
- configurations: Defines standard configuration structures and utilities for the framework.
- constants: Stores and manages global constants used throughout the bCLEARer framework.
- nf: Manages foundational operations, providing core support for various tasks.
- pipeline_builder: Provides CLI tooling to generate and manage pipeline structures based on configuration.
- substages: Handles the different substages of the data pipeline, offering utilities to manage transitions and execution within stages.
Installation
To install this package, use pip:
pip install bclearer-core
Or, clone this repository and install it locally:
git clone https://github.com/ontoledgy-labs/bclearer.git
cd bclearer/libraries/core
pip install .
Usage
To use the core functionalities, import the desired module. For example:
from bclearer_core import configurations
# Example usage
config = configurations.load_configuration(config_path="path/to/config.yaml")
print(config)
Pipeline Builder
The Pipeline Builder is a powerful tool included in bclearer_core that helps you generate and manage bCLEARer pipeline structures based on JSON configuration. It eliminates the need to manually create the complex directory and file structure required for bCLEARer pipelines.
Using the Pipeline Builder CLI
To access the pipeline builder CLI tool, you need to install the full bCLEARer PDK (not just bclearer-core). The tool can be used in two ways:
Option 1: Using Python module syntax
# Generate a sample configuration file
python -m bclearer_core.pipeline_builder sample --output my_config.json
# Create a new pipeline from configuration file
python -m bclearer_core.pipeline_builder create --config my_config.json
# Create a pipeline interactively
python -m bclearer_core.pipeline_builder create --interactive
# Create a pipeline in a specific output directory
python -m bclearer_core.pipeline_builder create --config my_config.json --output /path/to/output/directory
# Update an existing pipeline with new components
python -m bclearer_core.pipeline_builder update --config updated_config.json --pipeline path/to/domain_name_pipelines
# Show detailed help
python -m bclearer_core.pipeline_builder help
Option 2: Installing the full bclearer package
If you install the full bclearer package (which includes all components including core, interop_services, and orchestration_services), you'll have access to the bclearer-pipeline-builder command directly:
# First, install the full package from the GitHub repository
pip install git+https://github.com/ontoledgy-labs/bclearer.git
# Then you can use the command directly
bclearer-pipeline-builder sample --output my_config.json
bclearer-pipeline-builder create --config my_config.json
bclearer-pipeline-builder create --interactive
Configuration Structure
The pipeline configuration uses a JSON structure that defines the domain, pipelines, thin slices, stages, sub-stages, and b-units:
{
"domain_name": "example_domain",
"pipelines": [
{
"name": "example_pipeline",
"thin_slices": [
{
"name": "example_thin_slice",
"stages": [
{
"name": "1c_collect",
"sub_stages": [
{
"name": "sub_stage_1",
"b_units": ["example_b_unit"]
}
],
"b_units": ["collector_b_unit"]
},
// More stages: 2l_load, 3e_evolve, 4a_assimilate, 5r_reuse
]
}
]
}
]
}
Creating a New Pipeline in Your Project
Follow these steps to create a new bCLEARer pipeline in your project:
-
First, make sure you have
bclearer-coreinstalled in your project:pip install bclearer-core
-
Generate a sample configuration file:
python -m bclearer_core.pipeline_builder sample --output my_pipeline_config.json
-
Edit the configuration file to match your pipeline requirements.
-
Create the pipeline structure:
python -m bclearer_core.pipeline_builder create --config my_pipeline_config.json --output ./pipelines/
-
The tool will generate a complete pipeline structure including:
- Pipeline orchestrators
- Stage orchestrators
- Sub-stage orchestrators
- Thin slice orchestrators
- B-unit skeletons
- Application runner
- Test infrastructure
-
Customize the generated code to implement your specific pipeline logic.
Updating an Existing Pipeline
When your pipeline requirements change, you can update an existing pipeline:
-
Modify your configuration file to add new components.
-
Run the update command:
python -m bclearer_core.pipeline_builder update --config updated_config.json --pipeline ./pipelines/example_domain_pipelines
-
This will add new components without modifying existing ones.
Interactive Pipeline Creation
For guided pipeline creation:
python -m bclearer_core.pipeline_builder create --interactive
This will walk you through a series of prompts to define your pipeline structure.
Contributing
Issues and feedback are welcome. Code pull requests are not being accepted yet, so please raise anything you find as an issue rather than as a patch.
For anything that does not fit an issue, contact support@ontoledgy.io.
Licence
This project is licensed under the GNU Affero General Public License v3.0 or later (AGPL-3.0-or-later). See the LICENSE file for the full text.
Commercial licences are available for organisations that cannot comply with the AGPL's network-use and source-disclosure terms. Contact support@ontoledgy.io for details.
Metadata
Release files for bclearer-core 0.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| bclearer_core-0.8.0.tar.gz | 162.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| bclearer_core-0.8.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 558.1 kB
Release files / bclearer_core-0.8.0.tar.gz
| Download URL | bclearer_core-0.8.0.tar.gz |
|---|---|
| Size | 162.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a930351925220522d8a7a3e37b8d5fb8c8ddfe149eaf1ef659d8b29b5fd30e93
|
|
BLAKE2b-256 checksum How to use checksums |
076e18f266eee6c97fcc30cac3ecb9a36746055c11050ee554db9a6d12f19afc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.
Transparency logRelease files / bclearer_core-0.8.0-py3-none-any.whl
| Download URL | bclearer_core-0.8.0-py3-none-any.whl |
|---|---|
| Size | 395.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b948afe0ab8717699fbfb05e3352c67ab797daf0b856acb5e06de99b6c1c5bce
|
|
BLAKE2b-256 checksum How to use checksums |
65b8b0da04bcf05d331296cf90cd63258dd94ea568b22e1f9b577417d6b48045
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.
Transparency log