Skip to content

Building and Managing TTYT-apps

This document will guide you through the process of building TTYT-apps.

Building apps in TTYT is easy. It requires:

  • A little bit of domain modelling
  • A bit of business analysis to document your business rules
  • Some creativity and trial-and-error

Luckily, TTYT gives you everything you need to achieve the three points above.

How TTYT-apps Work

TTYT-apps differ from what you might normally consider an app in a few key ways, summarised in the following table:

Classical application TTYT-app
UX A web app or mobile app A simple chat conversation
Logic An API with business logic encoded AI agents with grounding
Data A database A database

Put simply, a TTYT-app's user interacts with TTYT-apps through a chat interface, the logic is inferred by a team of AI agents, and the state is persisted in a database.

Getting Started

To get started creating a new TTYT-app, click on the App Builder button in the sidebar. In the bottom right, click on Build a new app. You have a choice of starter templates. Choose one, or click Start from scratch in the top right.

Fill in the app details: choose an emoji, a name, and provide a short description. Wait a few seconds and your brand new app will be ready.

Info

If the App Builder button in the sidebar is not visible, then you do not have the rights to build apps. Reach out to your organization administrator.

Once your application is provisioned, you will have a working app out of the box. If you chose to start from scratch, your app will only have the minimal entities required.

Warning

Your app is immediately available. If you do not want this, go to the settings tab of your app and set it to draft mode.

After creating an app you will see an editor that allows you to define the app logic.

You will see the app appear in the sidebar under the Apps section and under the Build a new app section. If you do not see the app, refresh your screen.

Defining Your TTYT-app Logic

Behind every TTYT conversation is a simple structure, called an app definition, that keeps it grounded in the real world. You can think of an app as being made up of:

  • Entities – the “things” your team cares about, such as requests, projects, people, or agreements.
  • Attributes – the pieces of information you want to remember about each entity, like a status, amount, date, or owner.
  • Constraints – the limits and checks that keep information sensible, such as “this must not be empty” or “this value must stay within an agreed range.”
  • Relationships – the ways entities connect to each other, like a request belonging to a project, or a person being responsible for a task.
  • Rules – the conditions that shape what should happen next, for example who needs to review something, when a status can change, or what to do when something is outside the usual pattern.

These parts work together:

  • Entities and attributes give your TTYT-app something concrete to reason about.
  • Constraints make sure the details stay trustworthy and meaningful.
  • Relationships let conversations move naturally between connected pieces of work.
  • Rules turn all of this into behaviour, guiding who is involved and what happens when.

When you design an app, you are really deciding what entities exist, which attributes matter, which constraints keep things safe, how everything is related, and what rules turn that structure into day-to-day decisions.

Info

To learn more about application design, check out the TTYT App Design Guide.

Once you are happy with your TTYT-app logic, you can save the app logic or choose to save and deploy.

You can find all app definitions by clicking on your app in the sidebar under Build a new app and going to the App logic tab.

Deploying TTYT-apps

Note

TTYT will guide you through the steps described below automatically, so you do not need to learn them all by heart.

App definitions need to be deployed to make them interactive. You can do this by going to the Deploy tab. TTYT-apps live in two environments:

  • Live: The version of your app that your users can use
  • Sandbox: A temporary version of your app in which you can experiment with new app definitions without impacting the data or the experience of your live app.

In the Deploy tab you will find tramlines on the left of the page with a plus button. Clicking the plus button will allow you to create new sandbox branches or create new plans.

Creating a Sandbox Branch

You can only create a sandbox branch if no sandbox branch already exists. Click the plus icon to create a new sandbox branch off the main branch. You have a choice between copying the data over from the main branch or starting with a clean slate:

  • Copy all current data: All data and users will be available in the sandbox branch
  • Start clean: All tables in the main branch will be available but will be empty

Applying Changes with Plans

Once you have a sandbox branch, the plus icon will allow you to create a new plan. A plan is a concept that allows you to change the database structure from its current structure into the structure described by a specific app definition. By default, the latest created app definition is selected.

Once the plan is created, you can review the changes that will occur. Select the Apply to Sandbox button to apply the structure changes to the database. If you only changed rules and the database structure remains unchanged, then the application will update only the rules.

Warning

Plans are not automatically applied, so do not forget to click the Apply to Sandbox button.

Plan application can overwrite or drop data in some cases, so always review the changelog. The TTYT beta environment currently does not allow you to edit this changelog, but this is on the roadmap. 🚀

Applying Your Changes to the main Branch

You can apply multiple changes in the sandbox branch as you iterate. Learn more about how you can use dummy users to simulate user interaction in the next section.

Once you are happy with your application behaviour, you can merge the changes into Live. To do that, click the Merge to Live button. This will apply the structure changes to the Live branch. Your sandbox data will not be applied.

Info

If the Merge to Live button is not visible, select the New sandbox branch created node in the tramlines and the button will be visible on the right.

If you want to start over, you can click Abandon Branch and all sandbox changes and data will be deleted.

Testing Your App

You can test against your sandbox branch by chatting, just like in the live branch. In the sidebar, the orange chat bubble will initiate a conversation with your sandbox branch. The orange table icon will bring you to the table view so you can understand the data.

In the sandbox branch, you can add dummy users which you can use to initiate conversations that impersonate different users. This can be useful to test user interactions, especially if your business logic relies on user roles. Go to the Users tab, select the sandbox branch and use the Create Dummy button to create a dummy account. Use the Chat as button to initiate an impersonated session. User impersonation is only possible in the sandbox branch.

Managing Users and Roles

In the sandbox branch, people with App Builder privileges can manage users and thus also manage user roles.

Info

Users are automatically added with an empty role on first interaction with any app. You can use the Users tab to manually add users and set their roles.

Configure TTYT-apps

In the Settings tab, there are a number of additional features and configurations.

  • App Info: Update app name, description and emoji
  • Draft & Visibility: Set draft mode to hide apps from people without App Builder privileges
  • Model Selection: Set which AI models should be used
  • Delete App: Permanently delete your app (irreversible)

Note

A note on AI models. TTYT uses two main groups of agents:

  • Chat agents
  • Business logic agents

Your choice of models will impact response times for the app. We recommend no reasoning effort for chat agents and only adding reasoning for business logic agents. Only increase the reasoning effort in the case where the app logic is too complex for lower reasoning levels.