|
2 | 2 |
|
3 | 3 | <img src="app/public/logo.svg" alt="PyOps logo" width="100"> |
4 | 4 |
|
5 | | -A web-based factory planner and in-game ops assistant for **Factorio**, built for |
6 | | -the **Pyanodons (Py)** overhaul — like [YAFC](https://github.com/Yafc-CE/yafc-ce), |
7 | | -but in the browser, with deep in-game integration and an AI-assisted planner. It |
8 | | -runs locally alongside your Factorio install and reads recipe data straight from |
9 | | -the game; Py-specific views (like TURD) appear only when that data is present, but |
10 | | -it loads whatever mod set you sync. |
11 | | - |
12 | | -**Just want to run it?** PyOps ships as a self-updating **desktop app** for Linux, |
13 | | -macOS, and Windows — no toolchain needed. Grab a build from the |
14 | | -[Releases](https://github.com/ApocDev/pyops/releases) page (it still needs Factorio |
15 | | -installed locally to sync recipe data), or [run it from source](#run-it) to hack on |
16 | | -it. Build/release details: [`docs/desktop.md`](docs/desktop.md). |
17 | | - |
18 | | ---- |
19 | | - |
20 | | -## What it does |
21 | | - |
22 | | -- **Design production blocks** — set output goals + rates, pick recipes/machines/ |
23 | | - modules, and PyOps solves the run-rates and building counts for the whole chain |
24 | | - (cyclic loops, fluid temperatures, byproducts, spoilage). Pin counts, route |
25 | | - byproducts, fold chains into sub-blocks, or extract a recipe into its own block. |
26 | | -- **Balance the whole factory** — every block's imports/exports roll into one |
27 | | - ledger (deficits, surpluses, built-vs-required machines), with what-if. Supply |
28 | | - priorities let recovery blocks feed demand before dedicated fallback production. |
29 | | -- **Explore the data** — a searchable catalogue with a recipe explorer (producers/ |
30 | | - consumers ranked and availability-grouped) and a dependency-tree explorer. |
31 | | -- **Track TURD & research** — Py's tech upgrades are first-class; pick a path and |
32 | | - every block re-solves against your research horizon. |
33 | | -- **Plan with AI** — an OpenRouter-backed assistant drafts whole chains, honouring |
34 | | - what you can build now vs. after research, and can read the live factory. |
35 | | -- **Reach into the running game** — a companion mod links over localhost UDP: an |
36 | | - in-game block panel, locate, live sync of research/TURD/machines, and more. |
37 | | -- **Quality of life** — command palette (Ctrl+K), undo (Ctrl+Z), per-block |
38 | | - snapshots, backup/share, tasks & notes, light/dark theme, responsive to phone. |
39 | | - |
40 | | -Each subsystem has its own doc under [`docs/`](#documentation). |
41 | | - |
42 | | ---- |
| 5 | +PyOps is a local factory planner and in-game operations assistant for |
| 6 | +**Factorio**. It is designed around the **Pyanodons** mods, but works with vanilla |
| 7 | +Factorio and other mod packs by synchronizing recipes, technologies, machines, |
| 8 | +and icons from your own game. |
43 | 9 |
|
44 | | -## Screenshots |
| 10 | +**[Read the PyOps documentation →](https://apocdev.github.io/pyops/)** |
45 | 11 |
|
46 | | -**Factory ledger** — every block's flows in one balance sheet; deficits rank by % |
47 | | -of demand met. |
48 | | - |
| 12 | +Installation, first project, planning workflows, game integration, reference, |
| 13 | +and troubleshooting. |
49 | 14 |
|
50 | | -**Block editor** — goals in, solved rates and building counts out; toggle recipes/ |
51 | | -blocks off, fold into sub-blocks, or switch to a flow diagram. |
52 | | - |
| 15 | +**[Download the latest release →](https://github.com/ApocDev/pyops/releases)** |
53 | 16 |
|
54 | | -**AI assistant** — drafts a whole block from a goal, flagging byproducts, spoilage, |
55 | | -and TURD upgrades. |
56 | | - |
| 17 | +Self-updating desktop builds for Linux, macOS, and Windows. |
57 | 18 |
|
58 | | -**Browse** — every item, fluid, and recipe with produced-by / used-in, grouped by |
59 | | -availability and annotated with waste %. |
60 | | - |
| 19 | +## What PyOps does |
61 | 20 |
|
62 | | ---- |
| 21 | +- **Design production blocks** — set output goals and rates, choose recipes and |
| 22 | + machines, and solve full production chains including cycles, byproducts, |
| 23 | + spoilage, and fluid temperatures. |
| 24 | +- **Balance the factory** — combine every block's imports and exports in one |
| 25 | + ledger, identify shortfalls and surpluses, and test changes with what-if plans. |
| 26 | +- **Explore game data** — search items, fluids, recipes, producers, consumers, |
| 27 | + and dependency trees from the mod set you actually use. |
| 28 | +- **Plan around progression** — model research horizons and, when present, |
| 29 | + Pyanodons TURD choices throughout the factory. |
| 30 | +- **Connect to Factorio** — use the companion mod for live research, machine, |
| 31 | + location, and production-plan integration. |
| 32 | +- **Draft with the Assistant** — optionally use an OpenRouter-backed planning |
| 33 | + assistant that understands the current project and can propose production |
| 34 | + blocks for review. |
63 | 35 |
|
64 | | -## Run it |
| 36 | +The [planning guide](https://apocdev.github.io/pyops/guide/) explains how these |
| 37 | +parts fit into a complete workflow. |
65 | 38 |
|
66 | | -```bash |
67 | | -cd app |
68 | | -vp install # install dependencies (Node LTS + pnpm; Vite+ handles the rest) |
69 | | -vp dev # start PyOps at http://localhost:3000 |
70 | | -``` |
| 39 | +## Screenshots |
| 40 | + |
| 41 | +**Factory ledger** — the balance across every production block, including |
| 42 | +deficits, surpluses, and machine requirements. |
71 | 43 |
|
72 | | -Then open **⚙ Settings › Game data** and run a sync: PyOps launches Factorio |
73 | | -headlessly, reads its recipe data, and loads it into a local database (~1–2 min the |
74 | | -first time). Needs **Factorio 2.1** with the **Pyanodons** suite + |
75 | | -**pypostprocessing**. |
| 44 | + |
76 | 45 |
|
77 | | -- **Configuration** (env vars, remote access): [`docs/configuration.md`](docs/configuration.md) |
78 | | -- **In-game features** (companion mod, launching the bridge): [`docs/bridge.md`](docs/bridge.md) |
79 | | -- **AI assistant** needs an [OpenRouter](https://openrouter.ai) key (set it in |
80 | | - Settings or `OPENROUTER_API_KEY`). |
| 46 | +**Block editor** — goals in, solved rates and building counts out. |
81 | 47 |
|
82 | | -The dev server also exposes the PyOps MCP tool surface at |
83 | | -`http://localhost:3000/mcp` (project configs for Codex and Claude Code ship in the |
84 | | -repo). |
| 48 | + |
85 | 49 |
|
86 | | ---- |
| 50 | +**Assistant** — project-aware help for investigating and drafting production |
| 51 | +plans. |
87 | 52 |
|
88 | | -## Documentation |
| 53 | + |
89 | 54 |
|
90 | | -How PyOps works under the hood lives in [`docs/`](docs/): |
| 55 | +## Developing PyOps |
91 | 56 |
|
92 | | -- [Architecture](docs/architecture.md) — the one-app-plus-mod model and repo layout. |
93 | | -- [Data pipeline](docs/data-pipeline.md) — how the Factorio data sync works. |
94 | | -- [Block solver](docs/solver.md) — the planning math. |
95 | | -- [Factorio bridge](docs/bridge.md) — the in-game link and its setup. |
96 | | -- [AI assistant](docs/ai-assistant.md) — the planning agent. |
97 | | -- [Configuration](docs/configuration.md) — environment variables and remote access. |
98 | | -- [Desktop app](docs/desktop.md) — how the Tauri bundle is built and released. |
| 57 | +The repository contains three cooperating parts: |
99 | 58 |
|
100 | | -Contributing: `vp check` and `vp test` must be clean; the mod (`mod/`) is pure Lua, |
101 | | -no build step. See [`AGENTS.md`](AGENTS.md) for the full toolchain and conventions. |
| 59 | +- `app/` — the TanStack Start application and Tauri desktop shell; |
| 60 | +- `mod/` — the Factorio companion mod; |
| 61 | +- `docs/` — the VitePress documentation site. |
102 | 62 |
|
103 | | ---- |
| 63 | +Start the application from source with [Vite+](https://viteplus.dev/): |
104 | 64 |
|
105 | | -## Credits & inspiration |
| 65 | +```bash |
| 66 | +cd app |
| 67 | +vp install |
| 68 | +vp dev |
| 69 | +``` |
| 70 | + |
| 71 | +Run `vp check` and `vp test` from `app/` before submitting application changes. |
| 72 | +The companion mod is pure Lua and has no build step. |
| 73 | + |
| 74 | +For architecture, subsystem contracts, desktop packaging, and contributor |
| 75 | +workflows, read the hosted |
| 76 | +[development documentation](https://apocdev.github.io/pyops/development/). |
| 77 | +Repository-specific agent conventions remain in [`AGENTS.md`](AGENTS.md). |
| 78 | + |
| 79 | +To work on the documentation site: |
| 80 | + |
| 81 | +```bash |
| 82 | +cd docs |
| 83 | +vp install |
| 84 | +vp run docs:dev |
| 85 | +``` |
106 | 86 |
|
107 | | -- **[YAFC](https://github.com/Yafc-CE/yafc-ce)** — the planner model, cost-analysis |
108 | | - approach, and the "design blocks, balance the factory" shape. |
109 | | -- **[Helmod](https://mods.factorio.com/mod/helmod)** — the in-game production-block |
110 | | - panel is heavily inspired by Helmod's; no Helmod assets are bundled. |
111 | | -- **[Factory Search](https://mods.factorio.com/mod/FactorySearch)** — the "locate in |
112 | | - game" feature relays to its remote interface. |
113 | | -- **[pypostprocessing](https://mods.factorio.com/mod/pypostprocessing)** — makes a |
114 | | - clean, planner-friendly data dump possible. |
| 87 | +## Credits and inspiration |
115 | 88 |
|
116 | | ---- |
| 89 | +- **[YAFC](https://github.com/Yafc-CE/yafc-ce)** — the planner model, |
| 90 | + cost-analysis approach, and the design-blocks/balance-factory workflow. |
| 91 | +- **[Helmod](https://mods.factorio.com/mod/helmod)** — inspiration for the |
| 92 | + in-game production-block panel; no Helmod assets are bundled. |
| 93 | +- **[Factory Search](https://mods.factorio.com/mod/FactorySearch)** — the locate |
| 94 | + action can relay to its remote interface. |
| 95 | +- **[pypostprocessing](https://mods.factorio.com/mod/pypostprocessing)** — |
| 96 | + supplies additional planner-oriented metadata for Pyanodons data dumps. |
117 | 97 |
|
118 | 98 | ## License |
119 | 99 |
|
120 | | -Free software under the **GNU General Public License v3.0** — see [`LICENSE`](LICENSE). |
121 | | -Copyright (C) 2026 ApocDev. You're free to use, study, modify, and share it |
122 | | -(including commercially), but any distributed version or derivative must stay open |
123 | | -under the same GPLv3 terms — matching [YAFC](https://github.com/Yafc-CE/yafc-ce) and |
124 | | -[Helmod](https://mods.factorio.com/mod/helmod). Contributions accepted under the same |
125 | | -license. |
| 100 | +PyOps is free software under the **GNU General Public License v3.0**. See |
| 101 | +[`LICENSE`](LICENSE). Copyright (C) 2026 ApocDev. |
0 commit comments