Conversations and scenarios
A conversation begins with a first calculation, which establishes the first scenario. As you continue, each request either refines the current scenario or branches into a new one. The conversation tracks a current scenario and the most recent scenario created, so you always know which state you are looking at.What-if exploration
When you change an input to explore an alternative — “what if the down payment were 15% instead of 20%” — TrueMath creates a new scenario. The original is preserved, so you can compare outcomes rather than overwrite them. Each calculation reports the action it took:new— a new scenario was created. Returned when you start a new conversation, explicitly ask for a new scenario, or change an input you already provided to explore an alternative — the original scenario is preserved so you can compare. Converting a value to a different unit does not create a new scenario; it changes what is shown, not the underlying calculation.extend— the current scenario was extended in place: additional values were supplied without changing any it already had. Converting a known value in the scenario to a different unit also returnsextend.discard— the requested calculation exactly matches one already in the scenario. Nothing was modified.fetch— an existing scenario was retrieved. Afetchdoes not return the scenario itself — read it withGET /v1/conversations/:id/context/:scenario_id.
Working with scenarios
- In the Playground, follow-up questions and what-if changes create and move between scenarios for you. See What-if scenarios.
- Over the API, you can retrieve the resolved state of every scenario in a conversation
with
GET /v1/conversations/:id/context, or a single scenario by its index withGET /v1/conversations/:id/context/:scenario_id.

