Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
114 commits
Select commit Hold shift + click to select a range
a70c7a5
established missing implementation warning framework
doublergreer Mar 26, 2026
2653177
incorrect draft of lvl2
doublergreer Mar 31, 2026
8f8c624
resolving original plasmid part overwrite issue in digestion
doublergreer Mar 31, 2026
6083612
unique objects for each lvl1 + passing in final doc for continuity
doublergreer Apr 1, 2026
7f68281
only grab first and last fusion site from new composite
doublergreer Apr 1, 2026
53716c0
codex check
doublergreer Apr 2, 2026
c2fc5c3
linking xml to json and json to protocol
Gonza10V Apr 3, 2026
5438141
Revise README for clarity and add project purpose
Gonza10V Apr 4, 2026
45d1a26
Rename project and update metadata in pyproject.toml
Gonza10V Apr 4, 2026
74fe1d8
Delete SBOL2Build.ipynb
Gonza10V Apr 4, 2026
1ad96f2
backbone now listed last in product
doublergreer Apr 6, 2026
0a2aa91
Enhance README with project details and workflow
Gonza10V Apr 7, 2026
56173d9
Add PRODUCT.md for BuildCompiler overview
Gonza10V Apr 7, 2026
813f7d5
Add Developer Guide for AI Agents
Gonza10V Apr 7, 2026
fd65c9a
type correction on ligation products
doublergreer Apr 7, 2026
ee7451f
function to simplify complex plasmid part representation to a scar-TU…
doublergreer Apr 7, 2026
5640cd8
intermediate w/ annos not working
doublergreer Apr 8, 2026
f4a8701
Implement BuildCompiler transformation orchestration stage
Gonza10V Apr 9, 2026
d4ee967
encapsulate TU annotaitons and sequence
doublergreer Apr 14, 2026
e073084
constant list of tuples defining TU fusion site order for l2 assemblies
doublergreer Apr 14, 2026
3c26af0
grab first and last fusion site now in order they appear
doublergreer Apr 14, 2026
def5b8b
digestion now takes in Plasmid object; implementation selection happe…
doublergreer Apr 14, 2026
2747758
remove todo
doublergreer Apr 21, 2026
494ddcf
ligase and RE flow optimized + domestication added if not found
doublergreer Apr 21, 2026
69fea09
definition->identity
doublergreer Apr 21, 2026
d9fbdf2
lvl2 and multi-design lvl1 drafts
doublergreer Apr 27, 2026
88a3b44
docstring updates
doublergreer Apr 27, 2026
6bce1f0
Add plating workflow with SBOL/protocol artifact generation
Gonza10V Apr 28, 2026
873ed74
Merge pull request #50 from MyersResearchGroup/codex/implement-buildc…
Gonza10V Apr 28, 2026
c75a283
Implement full_build orchestration with manifest and packaging
Gonza10V Apr 28, 2026
fe3e9e7
Add full_build quickstart notebook example
Gonza10V Apr 28, 2026
230f2ba
get referencing CD in extract toplevel definition
doublergreer Apr 28, 2026
de292b8
ironing out iterative lvl1
doublergreer Apr 28, 2026
a0f395c
better doc search in get_or_pull
doublergreer Apr 29, 2026
fb76b9c
added combinatorial design support to lvl1
doublergreer Apr 29, 2026
44a0ae3
Add SBOL2 Transformation class and wire BuildCompiler transformation
Gonza10V Apr 30, 2026
2665860
Refactor plating to metadata and layout artifact outputs
Gonza10V Apr 30, 2026
932d474
Merge pull request #51 from MyersResearchGroup/codex/implement-buildc…
Gonza10V Apr 30, 2026
b61cfb1
Add files via upload
Gonza10V May 5, 2026
21271fb
Add clean-architecture package scaffolding for issue #53
Gonza10V May 5, 2026
35ff52d
Merge pull request #68 from MyersResearchGroup/codex/create-clean-arc…
Gonza10V May 5, 2026
c843d64
Add domain enums and result dataclass contracts for full_build
Gonza10V May 5, 2026
f16874b
Raise declared minimum Python version to 3.10
Gonza10V May 5, 2026
72303d1
Merge pull request #69 from MyersResearchGroup/codex/implement-domain…
Gonza10V May 5, 2026
9a475bd
Add composed BuildOptions API dataclasses
Gonza10V May 5, 2026
d5108ec
Merge pull request #70 from MyersResearchGroup/codex/implement-buildo…
Gonza10V May 5, 2026
4b3298c
Add BuildCompiler API skeleton facade
Gonza10V May 5, 2026
123e984
Merge pull request #71 from MyersResearchGroup/codex/add-buildcompile…
Gonza10V May 5, 2026
2c67234
Implement SBOL resolver and inventory indexes foundation
Gonza10V May 5, 2026
c621e45
Fix generated product reindexing for existing plasmids
Gonza10V May 5, 2026
adf812c
Fix resolver to accept pulled SBOL objects directly
Gonza10V May 5, 2026
adf2a24
Merge pull request #72 from MyersResearchGroup/codex/implement-sbol-r…
Gonza10V May 5, 2026
3196051
Implement full-build planning classifier and combinatorial expansion
Gonza10V May 6, 2026
d1e615f
Add lvl1 part-set validation in planning classifier
Gonza10V May 6, 2026
9027a70
Fix combinatorial part ordering by variable reference
Gonza10V May 6, 2026
7b87035
Merge pull request #73 from MyersResearchGroup/codex/implement-full-b…
Gonza10V May 6, 2026
52d4ec4
Implement compatibility selector and deterministic route scoring
Gonza10V May 6, 2026
2765225
Fix lvl2 region_order constraint validation
Gonza10V May 6, 2026
197f7e2
Merge pull request #74 from MyersResearchGroup/codex/implement-compat…
Gonza10V May 6, 2026
bc95f5f
Add SBOL AssemblyService wrapper and contracts
Gonza10V May 6, 2026
366efce
Merge pull request #75 from MyersResearchGroup/codex/port-assemblyser…
Gonza10V May 6, 2026
e4e6516
Implement lvl1 assembly stage orchestration and PUDU JSON adapter
Gonza10V May 6, 2026
dd0ed63
Fix lvl1 stage to accept planner part_order constraints
Gonza10V May 6, 2026
a3424a8
Merge pull request #76 from MyersResearchGroup/codex/implement-lvl1-a…
Gonza10V May 6, 2026
eb16ac7
Implement domestication planner, service, and stage with approvals
Gonza10V May 6, 2026
b50b13f
Fix domestication SBOL implementation metadata and role copying
Gonza10V May 6, 2026
690f0bc
Merge pull request #77 from MyersResearchGroup/codex/implement-domest…
Gonza10V May 6, 2026
3fdcf3e
Implement lvl2 assembly stage with route blocking promotion
Gonza10V May 6, 2026
a85ed13
Fix lvl2 region_order handling to preserve requested region set
Gonza10V May 6, 2026
06e8290
Fallback to arbitrary lvl2 order when region_order cannot be satisfied
Gonza10V May 6, 2026
c277ef9
Merge branch 'codex/implement-lvl2-assembly-stage' into codex/github-…
Gonza10V May 6, 2026
cb661e7
Merge pull request #79 from MyersResearchGroup/codex/github-mention-i…
Gonza10V May 6, 2026
ee455f0
Merge pull request #78 from MyersResearchGroup/codex/implement-lvl2-a…
Gonza10V May 6, 2026
1a71a26
Implement bounded full-build executor and wire compiler API
Gonza10V May 6, 2026
66563eb
Merge pull request #80 from MyersResearchGroup/codex/implement-full-b…
Gonza10V May 6, 2026
672f780
Add compiler-only protocol adapters and simulation boundary
Gonza10V May 6, 2026
80de92e
Merge pull request #81 from MyersResearchGroup/codex/implement-pudu-a…
Gonza10V May 6, 2026
b7f7214
Add reporting graph summary and optional detailed report
Gonza10V May 6, 2026
3619932
Fix report executive summary for failed builds
Gonza10V May 6, 2026
5ecb9b3
Merge pull request #82 from MyersResearchGroup/codex/implement-buildg…
Gonza10V May 6, 2026
26c3e12
Add core CI workflow and offline end-to-end pytest fixtures
Gonza10V May 6, 2026
9fdffd6
ci: scope ruff gate to offline core test paths
Gonza10V May 6, 2026
9577d67
Merge pull request #83 from MyersResearchGroup/codex/add-end-to-end-f…
Gonza10V May 6, 2026
79b6b3a
new tests for digestion and ligation
doublergreer May 7, 2026
e622941
combinatorial test
doublergreer May 7, 2026
4e704fc
type and error handling adjustments
doublergreer May 8, 2026
a0bb9e0
adjusting backbone arg to allow for dictionary mapping design.display…
doublergreer May 8, 2026
cc967fe
type correction
doublergreer May 8, 2026
b4fb2ca
Add local SBOL document indexing entry point
Gonza10V May 8, 2026
4e9f961
activity tests for digestion and ligation
doublergreer May 12, 2026
3dc25ee
test buildcompiler draft
doublergreer May 12, 2026
7d346cf
level 1 and first comb test complete
doublergreer May 12, 2026
da38668
removed superfluous prints
doublergreer May 12, 2026
d2fe409
new test suite
doublergreer May 12, 2026
feb64fa
synbiohub.org->api.synbiohub.org
doublergreer May 13, 2026
3384148
secret access for github job
doublergreer May 13, 2026
cecf73f
api for pulls only
doublergreer May 13, 2026
26e638d
api for collections
doublergreer May 13, 2026
f91e490
revert api for collections
doublergreer May 13, 2026
bb8d338
added server mode flag to add api. to canonical sbh registry uris
doublergreer May 13, 2026
776bc73
notebooks for creating various implementations used in buildcompiler
doublergreer May 13, 2026
767fa6b
decouple forward and reverse fusion site matching to fix skipped back…
doublergreer May 16, 2026
0454cfe
lvl2 working
doublergreer May 16, 2026
307f61c
lvl2 test draft
doublergreer May 17, 2026
9cebf0d
lvl1 TU tests for lvl2 assembly
doublergreer May 18, 2026
769bd06
Fix local document indexing to avoid duplicate re-indexing
Gonza10V May 18, 2026
fa0a2b5
Merge pull request #100 from MyersResearchGroup/codex/add-local-sbol-…
Gonza10V May 18, 2026
207b68c
transformation test
doublergreer May 18, 2026
1c67d56
notebook updates
doublergreer May 18, 2026
2237123
added transformation
doublergreer May 18, 2026
28cebdc
Merge branch 'full_build' into assembly_lvl2
Gonza10V Jul 9, 2026
2ed6001
Fix domestication BsaI implementation reference
Gonza10V Jul 9, 2026
f10a5b4
Respect supplied level 2 backbone
Gonza10V Jul 9, 2026
de4387a
Select top-level design for lvl2 TU extraction
Gonza10V Jul 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: CI

on:
pull_request:
push:
branches:
- main
- full_build

jobs:
core:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install package
run: |
python -m pip install -U pip
python -m pip install -e ".[test]"
python -m pip install ruff
- name: Ruff check
run: ruff check tests/conftest.py tests/unit tests/stages tests/integration
- name: Core tests
run: pytest tests/unit tests/stages tests/integration
3 changes: 3 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,8 @@ jobs:
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with unittest
env:
SBH_USERNAME: ${{ secrets.SBH_USERNAME }}
SBH_PASSWORD: ${{ secrets.SBH_PASSWORD }}
run: |
python -m unittest discover -s tests
160 changes: 160 additions & 0 deletions ADR-001.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
# ADR-001: Replace Prototype BuildCompiler Structure with Clean Architecture

## Status

Accepted.

## Context

The current BuildCompiler prototype proves important pieces of the desired workflow, especially level-1 assembly and SBOL digestion/ligation behavior. However, the current structure mixes too many responsibilities in a small number of files:

- collection indexing
- SynBioHub pulling
- plasmid/backbone/reagent tracking
- domestication
- level-1 assembly
- placeholder level-2 assembly
- transformation
- plating
- PUDU JSON conversion
- manual protocol helpers
- Opentrons simulation helpers

The new `full_build` vision requires a dependency-resolving compiler pipeline, partial success semantics, route optimization, structured blockers, approvals, graph/reporting, and optional protocol generation. Preserving old APIs and module boundaries would slow implementation and make Codex work harder to verify.

## Decision

Rewrite the internals around a clean architecture while keeping only the root package name `buildcompiler`.

Do not preserve legacy APIs, compatibility wrappers, or old module boundaries.

The target architecture separates:

```text
api
public compiler object and options

domain
stable contracts and normalized domain records

planning
design classification, validation, combinatorial expansion

execution
worklist and bounded full-build loop

stages
biological build operations

sbol
SBOL resolver and SBOL construction services

inventory
indexed material lookup and compatibility selection

adapters
PUDU and Opentrons handoff boundaries

reporting
graph, summary, report, serialization
```

## Options considered

### Option 1: Incrementally patch the existing `BuildCompiler` class

Pros:

- Smaller initial diff.
- May preserve existing notebooks temporarily.
- Easier to start quickly.

Cons:

- Reinforces the current god-class structure.
- Makes partial success and structured blockers awkward.
- Makes Codex tasks harder to scope.
- Encourages hidden compatibility behavior.
- Risks coupling PUDU/Opentrons side effects to compiler-only mode.

### Option 2: Preserve public wrappers but move internals

Pros:

- Gives users a transition path.
- Reduces immediate breakage.

Cons:

- Adds compatibility traces the project does not need.
- Doubles API surface during a major refactor.
- Forces new contracts to fit old return shapes.
- Makes partial success harder to expose cleanly.

### Option 3: Clean architecture rewrite with no compatibility traces

Pros:

- Best long-term module boundaries.
- Makes Codex tasks smaller and safer.
- Enables testable contracts before complex stages.
- Separates compiler-only mode from automation side effects.
- Treats expected build blockers as structured data.
- Supports route optimization, reporting, and approvals naturally.

Cons:

- Larger initial migration.
- Existing notebooks/imports will break.
- Requires disciplined milestone sequencing.
- Requires new documentation and tests early.

## Rationale

Option 3 is best now because the user explicitly prefers clean architecture over compatibility and wants the current repository treated as inspiration, not an API to preserve.

The new `full_build` behavior is not a small extension. It is a compiler pipeline with:

- planning
- inventory lookup
- route optimization
- staged execution
- retry loops
- structured missing inputs
- approval gates
- SBOL artifacts
- PUDU JSON adapters
- reporting

Those concerns need explicit boundaries.

## Consequences

- The root package remains `buildcompiler`.
- Existing method signatures such as `compiler.assembly_lvl1(raw_component_definition)` do not need to survive.
- `BuildCompiler.__init__` becomes dependency-injected and lightweight.
- `BuildCompiler.from_synbiohub(...)` owns convenience loading/indexing.
- Stages use a uniform `run(request, context) -> StageResult` contract.
- Inventory records replace the old `Plasmid` class.
- PUDU/Opentrons are optional adapters, not core dependencies.
- Codex should implement in milestone order and keep tests passing at each step.

## Risks and mitigations

| Risk | Mitigation |
|---|---|
| Rewrite grows too large | Implement milestone-by-milestone with tests. |
| Working level-1 assembly regresses | Port current `Assembly` behavior mostly intact before deeper cleanup. |
| Users lose old APIs | Accepted tradeoff; update docs and examples for new API. |
| SBOL identity bugs | Use identity-based domain contracts and central `SbolResolver`. |
| Route optimizer is hard to debug | Use explicit score dataclasses and detailed report alternatives. |
| Automation dependencies destabilize core CI | Keep PUDU/Opentrons optional and out of default CI. |

## Revisit triggers

Revisit this decision if:

- A downstream user requires stable old APIs for publication or production workflows.
- SynBioSuite integration depends on old imports.
- The clean rewrite cannot pass level-1 fixture tests after the assembly service port.
- A future release needs a compatibility bridge for migration.
Loading
Loading