Repository navigation
Conversation
Plan for running the Railway dispatcher experiment (the cleaned simulator of the standalone railway_sim prototype) on the platform's generic pipeline, with requirements, design, change inventory, steps and open questions. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…mples The cleaned, headless simulator of the standalone railway_sim prototype (branch FHNWtec-version): six scripted Flatland scenarios, two decision modes, payload drafts and 38 tests, with a README. Only the payload docstring changes: it points at the plan instead of the handover notes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…he scenario infrastructure sim/marey.py ports the standalone prototype's ZWL mapping and link map (identical results on all six maps) and adds the planned path per train; infra_payload() sends marey_mapping, planned_paths and link_map, so the frontend can draw the ZWL and the link map from the context. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
usecases_examples/Railway/devstack starts the Event, Context, Historic and Recommendation services on SQLite with AUTH_DISABLED, registers Railway and puts a gateway on port 3200 in front of them that stands in for nginx, Keycloak and OperatorFabric. It serves the built frontend or the Vite dev server, keeps its venv, databases and logs in the gitignored .cache/, and comes with seed and smoke scripts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cypress/e2e/railway.cy.ts logs in through the dev gateway, answers the consent question and saves the shot 00-baseline of today's Railway page; cypress.config.ts records a video and opens a 1600x900 window. The baseline shot is kept with the plan. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chenkins
commented
Nov 10, 2026
…art dialog Q2 is decided as ab): RailwayManager looks the open decision's recommendations up in a copy of recommendations.json, generated from the scenario files by the simulator, with the option of moving the lookup into an agent route of the simulator later. Q6 is decided as railway_sim's Experiment, with the mode set per run. Q3 now proposes a start dialog and a progress bar, after PowerGrid's agent choice, shown in a new sequence diagram. The modes get requirements F37 to F39, and phases 1 and 2 are recorded as carried out. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chenkins
commented
Nov 10, 2026
chenkins
commented
Nov 10, 2026
…tions Q8 is decided as a): the two-step choice lives in the Railway use case only, as ColearningChoice.vue in Railway's own assistant panel, with no change to shared code. Q8 now lists its options with a screenshot of the platform's flat recommendation list in both modes and a mockup of the two-step panel, and notes that the reference screenshot shows a Ko-Lernen decision. Q2 is marked as decided, and Q6 names the cleaned simulator's session file and why a mode per run adds little code. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chenkins
commented
Nov 10, 2026
chenkins
commented
Nov 10, 2026
…lway session flow Q5 is decided as one questionnaire at the end through the post-logout survey, with how the platform ties its answers to a person and how they are collected. Q16 drops the Testprotokoll, and Q14 falls away. Q11 gets the option of one shared user with the participant code typed into the start dialog. Q3 gets today's page with the experimenter starting the simulation (e) and an overlay between scenarios (f), with a mockup of introductions as feed cards and the place of the status line. Q27 keeps the simulator an always-on service rather than running it in the Context Service. The new section 4.2.6 draws a session from the start dialog to the end screen, with the experimenter's case shaded. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…session D10 now ties every logged record to the Experiment by the platform's trace session id or its timestamp, instead of one user per participant: the platform logs no user and has no participant concept, and the post-logout survey already uses that id. Q11 is decided as one shared railway_user with no participant code; the start dialog sends the trace session id as the experiment's session_id, which also seeds the run order. The participant field leaves the data model, the examples, the dev gateway, Cypress and the deployment seed files. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…de Q15 and Q26 The new design requirement D20 keeps everything outside usecases_examples backwards compatible: every field added to Railway's schemas and frontend types is optional, and the Railway page, its apply and RailwayManager pick the new path only when the new data is there, so today's Leaflet map, catalog recommendations and /transport_plan keep working. Breaking changes become none. The run's mode travels as run_mode, since the catalog path reads event["mode"]. Q15 is decided as extending the existing Railway use case and Q26 as a scenario list route on the simulator, so S3 and S4 are no longer blocked. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… the action row options Revise the run flow (session end time, run list on session start, 409 on a running session), update the findings and status, and add Q28 (Ko-Lernen actions a train does not offer) with options a)-c) and a mockup of a) and b). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ep gaps in the Railway plan Decide Q29 a): a session start posts run 1 as ready and ends a session another login left running, with sequence diagrams of both gaps and both options. Fix "Beenden" versus the end screen, the German-only survey chain, the Blocked-by columns, tests, follow-ups and new patterns. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…n questions Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…-on service Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…f both placements Decide Q17 b), the platform's recommendation cards with the handover's KPI labels, and Q18 a), the two-step Ko-Lernen choice in the assistant panel. Add mockups of both options, the handover's sources, and sequence diagrams of both placements with the folders of their components. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…gs as steps Q22 gets options a) and b) with a mockup on the Railway page. b), the proposal, keeps F26's text and adds a logout hint, because the questionnaire comes only after the logout. The plan's status moves into the step tables: Commit(s), Findings, Category and Severity columns replace the Done column and the Carried out and Remaining tables, and the five open findings become steps S18 to S22. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ions Q22 b) adds one view to the Szenario-Loader, which already checks the end condition, while a) needs that check too plus a centre-panel state in Context.vue. The difference is a few lines, so the choice rests on what the study used and on the logout hint. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…art dialog Q22 is decided as b): F26's end text in the Szenario-Loader with a logout hint, as the questionnaire comes only after the logout. Q23 is decided as a): the single run with the scenario dropdown stays. With the Testprotokoll dropped, that leaves only d) for Q13, so the start dialog offers the Experiment and the single run. F21, F26, section 1.7, Q3 d) and S12 follow, and S12 and S13 are no longer blocked by a decision. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Q19 gets option c), the mode only in the progress bar, as in railway_sim's Experiment banner, with a mockup of a) to c) and their costs, advantages and disadvantages. A state label would repeat the decision prompt and the start dialog. F23, the components table, Q3 d) and S12 follow, and S10 is no longer blocked by Q19. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…unblocks every step Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…Railway events and contexts Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…receive the operator's choice Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…y the simulator Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…steps S28 to S44 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… steps and phases done or open Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…starts Railway's feed shows only the running scenario's cards: a card's session_id and scenario_id must match the latest context, and between two runs, while the next introduction shows, the feed is already empty. The simulator only sends, so nothing is deleted; cards of other publishers and every card without a Railway session stay. The filter lives in entities/Railway/feed/ and reaches the shared feed through its sections option. The timeline still lists the earlier runs' cards. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…table
The train table ("Zugtabelle") gets "Von" and "Nach" columns: the station
at the first and the last cell of the train's route, from the scenario's
infrastructure ("–" when no station is there). Texts in German, English
and French; the table's cells no longer wrap.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…its direction In the Kartenansicht each train is a pill along its track, as long as its name needs (about 2-3 cells), with the name inside and a "▶" at its front in the direction it runs; north and south trains stand upright, so the name is never upside down. The tag above the train is gone, and with it the "+delay" label that arrived trains, which are not drawn, never showed. Held trains stay red, highlighted ones keep their orange outline. Shots 04-map, 06-status and 14-compare are refreshed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…resolved PR threads Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The trains now carry their name and a ▶ on the map, and each scenario starts with an empty feed: retake 01, 02, 03, 07, 08, 09, 10, 12 and 17 from the Cypress spec of c67f8a1. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…, S-45) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…opens A decision card of the scripted simulator (scenario_id and decision_index) opens on the recommendation tab at once, as the event view's "Empfehlung anfordern" would open it. The request still goes through the Recommendation Service and records the RECOMMENDATIONS trace; ASKFORHELP is only sent for a real click. Opening another decision card while the tab is open asks again. Other cards keep the event view. Both tabs share loadRecommendations(). Closes F-23 (S-32). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Event Service merges events with the same id_event, id_train and event_type. The same login playing a scenario again (a single run after "Neue Sitzung", or the Experiment stopped and started again) kept its session id, so the second play's cards fell into the first's. id_event now also carries the session's start. Closes F-9 (S-29). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…srupted The holds of slow trains (speed < 1) shared the dict of the event and decision holds, so affected_trains named a slow train every other step and the views highlighted it. They are now kept in _speed_holds; the steps are unchanged, an event or decision hold still replaces a running speed hold. Closes F-10 (S-30). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SessionRunner sent to the platform while holding its lock, so a slow or unreachable platform held up the browser's "Weiter", apply and stop. The payloads are now built under the lock in the order they happen, queued as copies, and sent after it is released by one sender at a time, so their order is kept. Closes F-12 (S-36). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Switching from the simulator's views to the geographic map (standalone mode, or a context without infra) left the context tab index on a tab that no longer exists, so no tab was shown. The tabs are now computed once, and the index goes back to the first tab when it is out of range. Closes F-11 (S-33). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The progress bar showed the latest context's session, which may still be a session of the previous login that nobody ended. ownSession() in loader.ts now gives the session only to its own login (its trace session id), for the progress bar and the start dialog alike. Closes F-14 (S-34). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
When the request that runs a single run (next) failed, its ready state mapped to no dialog, and the error was not shown. loaderView() now keeps the start dialog with the error after a failed start; starting again ends the run left waiting in the simulator first, which refuses a second start of the same session. Closes F-13 (S-37). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Since S-32 opening a decision card requests its recommendations at once, so a slow answer for a card opened before could fill the open card's panel and be applied with its event id. loadRecommendations() now counts its requests and drops every answer but the latest's. Closes F-15 (S-35). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The hand-written KPIs of the scenarios' options contradicted the simulation. compute_kpis.py now plays every option from the scenario's start to its end (sim/kpis.py) and writes experiment_scenarios/kpis.json, which the scenarios read in place of their own KPIs (kept as kpis_hand_written): the delay as in the train table, summed and per train, and the energy, the steps all trains spend on the grid. Dropped connections are left out, since no scenario defines its connections. export_recommendations.py carries them into both recommendations.json; the assistant and the Ko-Lernen choice show them via kpiRows(). Closes F-21 (S-28), as decided in Q-33. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e colour, in both track views Follow-up of F-25. In the Kartenansicht and the Linienansicht each train now fills its cell with the bounds of a station's box, its name fitted inside and a "▶" pointing the way it runs (lineHeading() on the line view); the tag above the train is gone. A light grid shows the cells' boundaries, with row and column numbers along the edges (cellGrid(), cellNumbers()); a failure shows as a red frame. Closes F-28 (S-47). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The line above the drawing at an open decision now reads "Simulation pausiert – Entscheidung erforderlich, bitte Ereigniskarte öffnen" (and in English and French), so the participant sees why the trains stand. Closes F-29 (S-48). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A decision card looked like every other card in the feed. Railway's feed now marks it in the severity slot: "⚠ Entscheidung" while the decision is open, "✓ Entschieden" once the context records it (feed/decisionMark.ts). Other cards get no mark. Closes F-27 (S-46). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The train table did not show where a train is now. A "Position / Richtung" column gives its cell (row, column, as numbered on the drawings) and its heading, e.g. "7, 9 → Ost", and "–" before it departs. Closes F-33 (S-52). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The train table did not show how long a train has stood still.
ScenarioPlayer.stopped_steps counts, per train, the steps it has stood in
the same cell on the grid so far, for whatever reason (an event, a
decision, its slow speed, a train ahead); the context carries it per train
and the table shows it as "Stillstand" ("Breakdown delay"), "–" from an
older simulator without it.
Closes F-34 (S-53).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…o S-48, S-52 and S-53 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…simulator's runs Applying a decision sets its card to ND, and the shared feed then asked "Event ended, would you like to close the corresponding notifications?" while the run went on. Railway's feed now passes autoclose false while the simulator's views are shown, or while the feed holds a simulator card (with scenario_id), since an event can end before the page reads the run's first context. Standalone mode and the geographic map keep the question. Closes F-32 (S-51). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The simulator sent each event once and never ended it, so a train_delay card stayed red in the feed and open on the Timeline for good. The first send stays unended; when the step counter reaches the event's timestep + duration, ScenarioPlayer calls on_event_end and SessionRunner sends the same event again (same ids and start_date) with end_date now and criticality ND, as PowerGrid ends its events. The Event Service merges it into the card, which turns grey, and the Timeline shows its end. Info events are not ended; an end the run does not reach is not sent. Closes F-36 (S-55). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ts of S-51 and S-55 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Summary
RAILWAY_SIMU_UPSTREAMsetting of the frontend; the Kubernetes route is still open.Carried out
usecases_examples/Railway.RailwayManager./railway-simu/proxy in every nginx config.Dockerfileand own compose, image built with/railway-simu,cabProcessperimeter seeded, deployment docs and checklist.Remaining
/railway-simu/location in the Kubernetes ConfigMap andRAILWAY_SIMU_UPSTREAMon the frontend pod; waits for Q30, where the simulator runs on the server.feat(deploy): route /railway-simu/ to the Railway simulator on KubernetesRequirements and walk-through
Plan: docs/plans/railway-use-case.md. Screenshots on the dev stack without Docker (
usecases_examples/Railway/devstack, 4 steps/s, 1600×900), German unless noted; "before" is today's Railway page with a context in today's schema, after on this branch (4190e38; later rows on the commit that added or last changed their shot), byfrontend/cypress/e2e/railway.cy.ts.RailwayManagerCHAINS.Railway, Germanrailway_sim.png; remaining differences listed in the Railway README §2.4devstack/start.sh, Cypress specmainthe dialog stays EnglishWalk-through: the Cypress run of all 13 tests before S24–S27 (4 min), uploaded by hand:
railway-walkthrough.mp4
Follow-ups (not in this PR)
RailwayManager's file.