Seshat AIDocumentation

Documentation / Concepts

Architecture

The layers of the Seshat runtime and what happens inside the query loop.

Seshat is organised in layers. Each one only depends on the layers below it, so you can use the top of the stack as an end user or reach down and replace a piece.

  1. InterfacesThe terminal agent, the gRPC server and the Go SDK. They all drive the same runtime.
  2. Query loopSends the conversation to the model, runs the tools it requests, and repeats until the task is done.
  3. Tools and permissionsFiles, shell, search, web, MCP servers and skills. Sensitive actions ask first.
  4. Providers and storageThe model providers behind one interface, and local storage for sessions.

The query loop

Every request goes through the same cycle:

  1. Your message and the conversation so far are sent to the model.
  2. If the model answers with text only, the loop ends.
  3. If it asks for tools, Seshat checks permissions, runs them, and adds the results to the conversation.
  4. The model is called again with those results, until it has nothing left to do.

Updated on 2026-10-07