Skip to content

Restructure into a dual-language (TypeScript + Python) library - #4

Merged
bigboateng merged 1 commit into
mainfrom
refactor/dual-language
Jun 13, 2026
Merged

Restructure into a dual-language (TypeScript + Python) library#4
bigboateng merged 1 commit into
mainfrom
refactor/dual-language

Conversation

@bigboateng

Copy link
Copy Markdown
Contributor

Restructure-only PR. Sets cmg up as a dual-language library (TypeScript + Python) with docs, a changelog, and the philosophy embedded, before any features.

What changed

  • Move: the entire TypeScript pnpm workspace moves into typescript/ as a unit, so every internal relative path is preserved. Verified: pnpm install + pnpm typecheck pass and example 01 runs identically.
  • Python side (python/): a real, dependency-free core (Transform, a runner that is sequential by default and a general DAG when given connections, RunContext signals -> TraceStep.metadata) plus math.sigmoid (forward + derivative). evaluators / feedback are scaffolded for parity. python3 tests/test_smoke.py passes (covers a linear graph, a non-linear merge, and sigmoid).
  • docs/: new philosophy.md (a CS engineer and an aerospace engineer can both use it; general tools over domain lock-in; the curse-of-expertise guard; problem-first plus small investigation), development.md (the acceptance discipline: parity in both languages, use-case-pulled, simple capability with hidden theory, a changelog entry per change), structure.md (the dual-language layout). 00-overview.md notes dual-language and reframes linearity as a default, not a limit.
  • CHANGELOG.md: introduced; entry 1 is this restructure (Change / Why / Domain influence / Languages).
  • README.md: rewritten for the dual-language layout.

Layout

docs/        language-agnostic: design, philosophy, development discipline
typescript/  the existing workspace (packages + examples), moved as a unit
python/      new: real minimal core + math, scaffolded evaluators/feedback
CHANGELOG.md

Scope

Restructure only. No feature code, no modelgraph changes, no DAG rewrite of the TS runner (reframed in docs only). Features and full Python parity land next, in both languages.

🤖 Generated with Claude Code

- Move the TypeScript pnpm workspace into typescript/ as a unit (build unchanged:
  install + typecheck pass, example 01 runs identically).
- Add python/: a real, dependency-free core (Transform, a runner that is
  sequential by default and a general DAG when given connections, RunContext
  signals) plus math.sigmoid; evaluators/feedback scaffolded for parity. Smoke
  test passes with plain python3.
- docs/: add philosophy.md, development.md, structure.md; note dual-language in
  00-overview and reframe linearity as a default, not a design limit.
- Start CHANGELOG.md (entry 1 = this restructure; Change/Why/Domain/Languages).
- Rewrite README for the dual-language layout.

Restructure only; features and full Python parity follow in both languages.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants