From 9e1b854863528bcc14436e901d784f6fc04cbd42 Mon Sep 17 00:00:00 2001 From: Michael Rienstra Date: Thu, 30 Oct 2025 19:31:57 -0700 Subject: [PATCH 1/2] `architecture.rst`, add `aw-server-rust`, misc. cleanup --- src/architecture.rst | 43 +++++++++++++++++++++++++------------------ 1 file changed, 25 insertions(+), 18 deletions(-) diff --git a/src/architecture.rst b/src/architecture.rst index 059bc55..61cc5c7 100644 --- a/src/architecture.rst +++ b/src/architecture.rst @@ -15,16 +15,23 @@ The illustration below is a graph of the fundamental dependencies between projec Server ------ -Known as :gh-aw:`aw-server`, it handles storage and retrieval of all activities/entries in buckets. Usually there exists one bucket per watcher. +ActivityWatch has two server implementations: -The server also hosts the Web UI (aw-webui) which does all communication with the server using the REST API. +- :gh-aw:`aw-server` - The current default Python implementation +- :gh-aw:`aw-server-rust` - A Rust implementation that is the planned future default -Clients (watchers, importers, and observers) --------------------------------------------- +The server handles storage and retrieval of all activities/entries in buckets. Usually there exists one bucket per watcher. -Since aw-server doesn't do any data collection on it's own, we need watchers that observe the world and sent the data off to aw-server for storage. +The server also hosts the Web UI (``aw-webui``) which does all communication with the server using the REST API. -These utilize the aw-client library for making requests to the aw-server. +Clients (watchers and importers) +-------------------------------- + +Since ``aw-server`` doesn't do any data collection on it's own, we need watchers that observe the world and sent the data off to ``aw-server`` for storage. + +These utilize the ``aw-client`` library for making requests to the ``aw-server``. + +ActivityWatch can't track everything, so sometimes you might want to import data from another source, that's where importers come in. For a list of watchers, see :doc:`watchers`. For a list of importers see :doc:`importers`. @@ -32,40 +39,40 @@ For a list of watchers, see :doc:`watchers`. For a list of importers see :doc:`i User interfaces --------------- -ActivityWatch currently has two user interfaces, aw-qt and aw-webui. +ActivityWatch currently has two user interfaces, ``aw-qt`` and ``aw-webui``. - :gh-aw:`aw-qt` - Manages the server and watchers to make ActivityWatch easy to use for end-users. -- :gh-aw:`aw-webui` - Offers visualization and an overview of the database. Hosted by aw-server in the bundle. +- :gh-aw:`aw-webui` - Offers visualization and an overview of the database. Hosted by ``aw-server`` in the bundle. Libraries --------- Some of the logic of ActivityWatch is shared across the server and clients, for these cases we moved some logic into separate libraries. -aw-core -^^^^^^^ +:gh-aw:`aw-core` +^^^^^^^^^^^^^^^^ -The aw-core library contains many of the essential parts of ActivityWatch, notably: +The ``aw-core`` library contains many of the essential parts of ActivityWatch, notably: - The `buckets-and-events` - The datastore layer - Event transformation and queries - Utilities (configuration, logging, decorators) -aw-client -^^^^^^^^^ +:gh-aw:`aw-client` +^^^^^^^^^^^^^^^^^^ Writing these clients is something we've tried to make as easy as possible by creating client libraries with a clear API. -A client could both be a watcher which sends data as well as a visualizer which fetches and presents data from the aw-server. +A client could both be a watcher which sends data as well as a visualizer which fetches and presents data from the ``aw-server``. -Currently the primary client library is written in Python (known simply as aw-client) but a client library written in JavaScript is on the way and is expected to have the same level of support in the future. +Currently the primary client library is written in Python (known simply as ``aw-client``) but a client library written in JavaScript is on the way and is expected to have the same level of support in the future. - :gh-aw:`aw-client` (Python) - :gh-aw:`aw-client-js` (TypeScript/JavaScript, beta) - :gh-aw:`aw-client-rust ` (Rust, work in progress) -aw-analysis -^^^^^^^^^^^ +:gh-aw:`aw-research` +^^^^^^^^^^^^^^^^^^^^ -There are also plans to create a library called :gh-aw:`aw-analysis` to aid in +There are also plans to create a library called ``aw-research`` to aid in different types of analysis and transformation one might want to make using ActivityWatch data. From 00baaccf91106cc4b508af857e315b702d77fedc Mon Sep 17 00:00:00 2001 From: Michael Rienstra Date: Thu, 30 Oct 2025 19:34:50 -0700 Subject: [PATCH 2/2] `custom.css`: make inline look less alarming Default is `#e74c3c` which reads like "error", changed to a dark orange which seems more neutral, but still "sticks out" enough for skimming purposes. --- src/_static/css/custom.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/_static/css/custom.css b/src/_static/css/custom.css index 2cc2758..f454bf1 100644 --- a/src/_static/css/custom.css +++ b/src/_static/css/custom.css @@ -15,6 +15,10 @@ code { color: rgb(51, 51, 51); } +.rst-content code.literal, .rst-content tt.literal { + color: #a34400; +} + .rst-content .section ul p { margin-bottom: 0px !important; }