Skip to content

Latest commit

 

History

75 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenSourceRail

OpenSourceRail is an open-source, deterministic urban-rail platform with a different economic model: retain design authority, software, fabrication, integration, operations and maintenance capability in-country instead of importing a closed foreign-turnkey system. GIS, CAD/IFC, simulation, cost and assurance share one Git-reviewable model.

Important

Repository outputs are planning and engineering-screening evidence—not bids, construction releases, safety certificates, approvals or endorsements.

The current survey, supplier, drawing, embedded-hardware, physical-test and approval gaps are consolidated in the reviewed roadmap. Useful CAD, IFC, PDF, image and animation artifacts remain tracked in GitHub; CI enforces a simple 50 MiB per-file ceiling rather than removing them from the public package.

OpenSourceRail light-metro reference trainset

Start here: complete PDF book, one-page overview, or ./install.sh then ./osr.

The public evidence scope covers 265 cities in 43 developing countries. One European comparison model in the 266-model engineering catalogue is retained only for technical inspection and excluded from public evidence and examples.

The Economic Case

The developing-world model places about $203B—roughly 75% of programme value—in domestic activity. Specialist imports are modeled at roughly one quarter. Comparative foreign-turnkey savings vary materially with procurement, financing and localisation assumptions, so exact sensitivity results stay in the reproducible portfolio calculation, not the headline claim. These are planning scenarios—not bids, audited origin claims or financing offers.

The route keeps civil works, vehicle structures, GFRP panels, interiors, wiring, software, integration and maintenance local where qualified. Specialist products use 25 real supplier-family anchors; every bought-in row has a fit gap and anchor-or-local-equivalent rule. Operators can localise progressively without silently changing safety assumptions, retaining skills and maintainable assets while reducing foreign-currency exposure.

Feature Highlights

OpenSourceRail is three connected products at deliberately different maturity:

Product v0.3 maturity Safe starting use
Design & Delivery Platform Serious demonstration City GIS, alignment, cost, IFC, procurement, schedule and project twin
Train + Infrastructure Reference System Engineering development Local-manufacture planning, supplier RFQs, prototype and civil option studies
Open GoA 4 Control System R&D / pre-certification Simulation, shadow mode, formal review and HIL—not live railway command

The first adoptable product is the non-safety owner/operator stack: simulator, Ops Core, asset register, QA, maintenance and evidence portal for an existing workshop, depot or pilot corridor. See the adoption boundary.

Capability Current implementation
Deterministic city generation Reproducible network, station, fleet, energy, engineering, finance and operations packages under cities/catalogue/.
Generatable project digital twin Every city regeneration joins its assets, BOM, finite-resource CPM, critical path, manufacturer candidate IDs and selection states, supplier/order-by plan, schedule of values, monthly local/import cash requirements, QA gates and construction-state timeline in one revisioned model. The compact summary is kept on GitHub; issued orders, deliveries, invoices, payments and actual progress persist separately in Ops Core.
Integrated Workbench City Studio, simulation, OCC training and Ops Core share city, actor, immutable revision, approved baseline, run and selected-asset context without merging authority boundaries.
Interactive network and service planning Edit lines, stations and alignment over 16 switchable local GIS layers; inspect roads, buildings, water, existing rail, demand, buildability, places and engineering assets; plan OD demand and service by line/day/time; compile content-addressed revisions for Git review.
Software in the loop One deterministic simulation connects train, station, energy, wayside, point/crossing, regenerative-braking and depot components to OCC evidence.
Civil BIM and GIS Generate OSR-ALN, GIS, IFC4.3, IDS/BCF, quantities, classifications and 4D construction review through the Bonsai civil workflow.
Buildable modular trainset The controlled LM3-FA-001 first-article baseline separates 101 product rows into 26 part→subassembly→car→trainset nodes, including explicit chassis/body/front, articulation, bogie/body connection and bogie-mounted drive units. Git includes 101 separate native FreeCAD parts and 26 tested assemblies, matching split IFC4.3 part/assembly files, 423 geometric primitives, nine timed methods, 20 tooling/mould families and shop travelers. All 54 bought-in rows now map to 39 manufacturer-sourced off-the-shelf or vehicle-specific RFQ candidates, with local-equivalent routes retained. Its 67 unresolved rows remain public work packages routed through one first-article execution pack and 12 honest evidence gates.
Automatic cost propagation CAD-indexed quantities feed the civil rate contract, city CAPEX, finance, IFC properties, national briefs and the developing-world portfolio summary.
Operations and assurance Authenticated city-scoped roles, managed photos/files, server-attested inspections and independent handback, controlled document revisions, NCR closeout, verified backups and acceptance evidence remain linked to source artifacts.
Deterministic browser testing Pinned Playwright acceptance verifies the integrated browser applications, adapters, engineering jobs and restart persistence.

Generate A City Delivery Twin

The city model is not limited to a route drawing or cost total. Regeneration creates a linked planning baseline that answers what must be built, what must be ordered, when it is required, which work is critical, and when local and foreign-currency cash is needed:

city GIS + design + fleet
          ↓
asset register → BOM demand → supplier/order-by plan
          ↓             ↓
finite-resource CPM → schedule of values → monthly cash requirements
          ↓
IFC/visualization state timeline + QA/work orders + recorded actuals

Use Workbench → Generate a city digital twin to select any catalogue city, regenerate it and open the result without a shell. Each city publishes a compact engineering/project-twin/summary.json; its reproducible operations bundle contains the complete task, procurement, cashflow and visualization records. Open Workbench → Operations → Project Twin to inspect the baseline and turn a planned requirement into a persisted draft purchase order. These are planning candidates—not issued contracts or construction releases—until the city records approval and actual commercial data.

The model uses about $0.9M per 3-car light-metro trainset as a local factory-gate planning target (LM3 build record: $885k) and $60k per supported vehicle/car module for one shared country factory. Homologation, supplier qualification, first-of-class engineering, warranty and deployment are separate gates and cannot be compared directly with an OEM delivered price.

Current System

City Studio Civil IFC coordination Any-city project digital twin
City Studio deterministic GIS workspace Bonsai IFC4.3 construction sequence Workbench any-city project digital-twin generator
Trainset assembly Simulation Fabrication and civil sequence
LM3 complete 127-node assembly OpenSourceRail simulator Guided fabrication and assembly digital twin

Review the full 88-second product assembly and 48-second civil IFC sequence.

Find Your Way

Use this only human-facing front door instead of browsing the generated file inventory.

I want to… Go here
Understand the whole system Architecture and software diagrams
Design a city, line, station or service Workbench and City Studio
Explore a country or city City catalogue; each local page contains only local evidence
Review costs or the portfolio Cost model and developing-world portfolio
Review trains, civil works or stations LM3 trainset, civil and stations
Review software, control electronics or operations Simulation coverage, control electronics and operations
Review safety, certification or open gaps Certification, safety case and roadmap
Understand the deployable signalling boundary Conservative pilot signalling profile and safety-controller selection gate
Contribute or make a release Contributing and release checklist
Share a short non-technical summary Generated one-page overview
Read the complete documentation Complete PDF book; rebuild it with ./osr book

Run The Platform

One-command Linux setup

On Debian, Ubuntu, Mint, Fedora, RHEL, Rocky, AlmaLinux, CentOS, openSUSE or Arch Linux, install the entire platform with one command:

./install.sh

It first reports what is already installed. Declining the installation makes no changes; accepting installs only missing native libraries and keeps Rust, Node.js, Python, uv, Trunk and browser tools under your home folder. It then asks whether to add the larger FreeCAD, Blender/Bonsai, QGIS, CloudCompare and SUMO applications, and whether to start the GUI. There are no setup options or environment variables to configure.

After setup, one command regenerates the shared design and cost data, product catalogues, browser and native applications, BOMs, IFC4.3 reference packages, the root PDF book, and documentation checks:

./osr build

It uses the checked-in city models and therefore does not silently reroute all 265 public city plans from changing internet data. Route changes are made in City Studio or regenerated explicitly with their source locks.

Run the integrated Workbench:

./osr

Open http://127.0.0.1:8090/. The local development server is not an authenticated public deployment.

Run the deterministic simulator:

./osr sim --duration 3600 --status-every 300

Disposable generated applications remain under build/frontend/, native executables under target/release/, and other local job output under build/. The public review set is deliberately outside those temporary trees: the reader book, tracked CAD assemblies and BIM coordination package are available directly from GitHub.

Evidence And Revision Model

city/project sources
        ↓
validated candidate + source locks
        ↓
immutable Git-reviewable revision
        ↓
GIS / OSR-ALN / IFC / CAD / cost / simulation artifacts
        ↓
approval evidence → training/operations baseline

Planning and training views cannot emit live OCC commands. A revision hash is not an approval; approval records are append-only and must reference independent review evidence. Generated city packages still require survey, calibrated demand, utility and ground data, supplier selection, first-article testing, competent engineering review and national authorization.

Source Of Truth

Change the source in the middle column and regenerate the output on the right. Generated files are review evidence, not parallel inputs.

Concern Edit here Derived or explanatory material
System boundaries and decisions docs/ARCHITECTURE.md and accepted docs/rfcs/ Diagrams, guides and component summaries
Software and simulation behaviour crates/ plus their tests WASM applications, simulation traces and coverage reports
GIS ingestion, city synthesis and scenario generation design/city-generation/ Published city catalogue and simulator inputs
Shared planning assumptions lib/templates/ and lib/recipes/ City designs, finance, energy and engineering evidence
City catalogue membership lib/city-batches/world-sample.toml cities/catalogue/ catalogue and national briefs
Interactive city revisions cities/workspaces/ Content-addressed candidates and exported city packages
Mechanical, station and reusable civil-component geometry design/component-catalogue/src/osr_mech/ FreeCAD review assemblies, BOMs, travelers and screenshots
LM3 bought-in component candidates lib/templates/trainset-cots-candidates.toml Generated manufacturer register, first-article work packages and city-twin order candidates
Survey, GIS and railway alignment Accepted deployment GIS plus OSR-ALN project sources QGIS layers, GeoPackages, corridor exports and IFC alignment references
Federated civil BIM Parametric component geometry plus approved alignment and engineering inputs IFC4.3 generated by civil_bonsai_ifc.py, checked with IfcOpenShell and reviewed in Bonsai
Civil rates and city costs lib/templates/civil-cost-calibration.toml, geometry and reviewed assumptions Generated rate contract, cost model and city CAPEX
Control-electronics integration control-electronics/ and governing RFCs Electronics BOMs, wiring packs and release evidence
Project controls, operations and safety requirements lib/templates/manufacturing-schedule.toml, docs/operations/, docs/certification/ and engineering/assurance/formal/ Per-city CPM/order/cashflow twin, portal data, safety-case views and acceptance reports

The artifact policy defines what Git keeps. The generated Markdown inventory is for search and CI only; it does not define architecture, status or reading order.

Verification

./osr test

See CONTRIBUTING.md, GOVERNANCE.md, CHANGELOG.md and the release checklist.

License

Software is Apache 2.0; control-electronics and open physical designs use CERN-OHL-S v2; documentation is CC-BY-SA 4.0.

See LICENSE.md and LICENSES/ for full texts.

About

Open-source urban rail design, simulation, operations, QA, maintenance, and certification-evidence stack for locally manufactured light metro systems.

Topics

Resources

Contributing

Stars

5 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages