> For the complete documentation index, see [llms.txt](https://tivet.gitbook.io/tivet-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tivet.gitbook.io/tivet-docs/overview.md).

# Overview

***

### Why use Tivet Actors? <a href="#why-use-rivet-actors" id="why-use-rivet-actors"></a>

Tivet Actors offer several compelling advantages for building agents that require realtime and  stateful functionality:

* **Enhanced Performance**: By integrating compute (i.e., "RPC") with data (i.e., "state"), performance is significantly improved.
* **Simplified Architecture**: Replace complex infrastructure (e.g., caches, queues, pub/sub) with actors for a more straightforward architecture.
* **Built-in Fault Tolerance**: Actors provide natural fault tolerance as state is durable and failures do not cascade.
* **Reduced Latency**: Achieve lower latency for users by running at the edge and combining compute with data.

***

### Core Features <a href="#core-features" id="core-features"></a>

* **Remote Procedure Call** (RPC) is how clients communicate with actors and how actors communicate with each other.
* **State** is the data belonging to each actor. State cannot be shared between actors. State is stored in memory (unless it's too large) for fast reads and writes. State is durable and will always survive a crash or upgrade. You can update state without having to do anything special.
* **Events** are used for real-time communication between clients and actors. Clients can subscribe to events with `actor.on("myEvent")`, and actors can publish events with `this._broadcast("myEvent")` or `connection.send("myEvent")`.
* **Connections** represent a client that's currently connected to the actor. Connections have their own state, e.g., `userId`. You can use `onConnect` to authenticate connections before they can communicate with the actor.
* **Edge Networking**: Automatically distribute your applications near your users for ultra-low latency.
* **Fault Tolerance**: Ensure application & state resilience through crashes with zero downtime.
* **Runs Forever, Sleeps When Idle**: Always available, sleeps on network inactivity or timeouts, and wakes instantly on demand.
