7.2 KiB
Design History
This is a reasoning history, not a commit log. It records the problems that shaped Optimus so later changes can distinguish intentional design from accidental implementation.
Durable work instead of rerunning pipelines
Optimus grew around a practical problem: expensive and nondeterministic work should survive restarts and downstream changes.
A conventional pipeline runner tends to think in execution order. Optimus instead asks for a desired artifact and walks downward through the work needed to establish it. This made persisted intermediate results first-class rather than incidental cache files.
The important consequence was a pull-driven operation: request what you want, recursively establish what it depends on, and wake only the work that is actually missing or stale.
Content identity stopped unnecessary invalidation
A parent transformation can become stale because its recipe changed and still reproduce exactly the same semantic output.
If every downstream artifact invalidated merely because the parent reran, expensive/nondeterministic work would be repeated unnecessarily. Optimus therefore uses content hashes as the identity passed downstream. A rebuilt parent with unchanged content does not force descendants to rebuild.
This was especially valuable for LLM-heavy pipelines where unnecessary reruns can produce different answers even when nothing semantically changed.
Complete named parent sets became a useful default recipe check
resolveArtifact() compares the complete named set of source hashes rather than only overlapping hashes. Adding, removing, or renaming a semantic parent is therefore a recipe change under that helper.
The names matter because they describe roles, not just byte values.
This exact-source-set policy remains a useful framework service, but later clarification made an important boundary explicit: transformers own their own semantic freshness rules. resolveArtifact() is a strong default mechanism, not a universal definition imposed by Optimus.
Artifacts remained readable instead of becoming an opaque cache
As more intermediate work became durable, it became useful to inspect it directly while debugging, evaluating LLM output, comparing translations, and understanding provenance.
Artifact directories therefore function as organized workbenches/warehouses. They are not intended to become private implementation storage addressed only by hashes.
sourceRef supports human navigation while sourceHash remains the content-validity mechanism.
Modules became the team; transformers remained a subset
Optimus projects naturally accumulated participants that did not fit a strict "one transformer = one stage" model: source loaders, publishers, LLM wrappers, coordination helpers, and other services.
The resulting model is deliberately loose:
- Optimus organizes modules.
- Some modules are transformers.
- A transformer may own several closely related transformations.
- Ordinary module calls may express dependency relationships.
This avoids both a central monolith and artificial micro-transformers.
Humans are legitimate artifact producers
The first Optimus projects mostly received human-authored material through input folders and then transformed it mechanically or through LLMs.
The framework was later clarified to permit humans as active participants inside transformations as well. A module may interview a human, collect approvals, accept manually authored guide entries, or allow a human to stamp prepared material as valid.
No Optimus-level human workflow system was added. If recurring human interaction needs reusable machinery, it can emerge as its own module (for example a future Bumblebee transformer) once real implementations provide evidence for what that machinery should be.
2026-09-09 — framework vision documented without runtime change
The project documentation was revised to describe Optimus as a lightly opinionated pull-driven transformer framework rather than primarily as a durable artifact resolver.
This was a clarification of the implementation's existing shape, not a runtime redesign.
The discussion established these intentional boundaries:
- Optimus organizes modules and participates through shared framework services.
- Transformers are artifact-producing/validating modules, not mandatory micro-machines.
- Freshness semantics ultimately belong to each transformer.
- Artifact areas are readable workbenches/warehouses.
- Human, LLM, external, and deterministic producers are all permitted.
- Optimus provides services rather than domain restrictions.
- No generic human-task system, central DAG, universal transformer interface, or other speculative framework machinery should be added without evidence.
2026-09-10 — useful build reporting without the full role call
Real translation runs showed that printing every already-current artifact check made normal console output noisy. The useful operational fact was usually the moment Optimus decided that work actually had to run.
Optimus therefore gained two optional presentation settings: showOnEnsure (default false) and showOnBuild (default true). Standard resolveArtifact() work reports automatically, while custom-validity transformers can report the same events through tiny framework hooks. Presentation remains completely outside artifact semantics.
This also reinforced an earlier framework principle: Optimus conveniences are services, not contracts. A transformer with unusual validity rules does not have to adopt resolveArtifact() merely to obtain consistent console behavior.
2026-10-06 — ensure remains the dependency contract
Publication work exposed an important distinction between expensive evergreen artifacts and intentionally frozen editions. The tempting shortcut was to read an existing expensive artifact directly so a downstream publisher could not accidentally wake it. That would have inverted Optimus's pull model: the downstream consumer, rather than the owning transformer, would decide whether a historical copy was acceptable.
The clarified strategy is:
- live dependencies are ensured normally;
- if an ensure wakes work unnecessarily, the owning transformer's freshness inputs or validity policy are too broad and should be corrected there;
- low-level artifact reads remain available for transformer-owned validity, migration, repair, and inspection;
- an accepted result that should no longer be evergreen is exported/ejected and becomes ordinary input to another project, intentionally severing the live dependency edge.
This was a documentation clarification rather than a runtime change.
2026-10-20 — catalog-wide explicit artifact vacuum
The project-specific storage cleanup prototype was generalized into Optimus:
--vacuum verifies the present pull graph of all configured targets,
records an exact per-file checksummed plan in side-effects, and never rebuilds;
--vacuum --apply repeats the entire inspection and inventories before
removing unvisited files. Project-specific freshness still belongs to owning
transformers. An inspection-only hook makes custom results fail closed without
changing their normal build behavior. Nothing is vacuumed implicitly during
npx optimus or targeted builds, and the maintenance run does not create a
permanent declarative dependency graph.