Compare commits

...
Author SHA1 Message Date
poli0981andClaude Fable 5.2 d628b19d4d feat(advanced): the switch - Settings > Recording > Advanced metrics (telemetry.advanced, off by default); on, a session holds the Agent's one reader and stores its series and facts; Privacy Policy 2.15 and Disclaimer 2.15 (Advanced PR-5, D101/D109)
telemetry.advanced becomes RecorderOptions.AdvancedMetrics at each session's start. The Agent registers one
AdvancedHardwareHub; SessionRecorder holds it for a session's length only when the option is on, and the session's
TelemetryPoller gets it on the same condition. A session's facts are read once, off the capture loop, fifteen seconds
after the game's process is known or at the session's end; which display is the game's comes from Windows
(WindowGeometryProbe.MonitorDeviceOf). Off: not held, not asked, no chunk 9 or 10, no session_advanced row.

Settings gains the row (off in a viewer), strings in en/vi/ja, the guide's settings page. Privacy Policy 2.15 names
what is read and stored only while the option is on, and what never is. Disclaimer 2.15 (the owner's answer of
2026-11-11, D109): PawnIO and the admin mode are no longer "for the CPU temperature" alone; the admin mode's
disclosure follows (agent-admin-dialog/2), with Settings, the first run, the guide and LIMITATIONS.md. The accuracy
block gains an item. Nothing in src/native changes.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-11 18:56:26 +07:00
38 changed files with 561 additions and 44 deletions

No files matched your search

+16
View File
@@ -84,6 +84,22 @@ numeric core and does not move; the heading is the full version — corrected 20
was not read. One hour of them is about 0.2 MB. **A session recorded with the option off stores nothing of this**,
and the option does not exist yet. *A 0.1.0-beta.38 cannot open a ledger a later build has migrated.*
- **Settings ▸ Recording ▸ Advanced metrics — the switch exists, off by default.** On, the capture agent reads more
from the graphics driver and the hardware sensors during a session and stores it with the session: the graphics
card's memory, load, clocks, fans, voltages and power in detail, what each display can do with HDR and variable
refresh and what the game's display did, the driver's settings for the game — and, when the agent runs as
administrator with PawnIO installed, the processor per core, the memory and the motherboard's sensors. **Off,
nothing more is read or stored**, and the shared reader is not even started. It applies from the next session, and
a session recorded while it was off is not filled in later. NVIDIA's figures are read once a second, the sensors
every five. **No page shows what is stored yet** — that is the next pull requests' — and none of it is in an
export or a bug report.
- **The terms window shows the Privacy Policy 2.15 and the Disclaimer 2.15 once.** The Privacy Policy names what
Advanced metrics reads and stores, only while it is on, and what it never reads: a serial number, a display's
identification data, a list of other programs. The Disclaimer's two sentences about PawnIO and about running the
agent as administrator said "the CPU temperature"; they now also name the processor's, the memory's and the
motherboard's sensors, read with Advanced metrics on. The same sentence changed in Settings, the first run, the
administrator dialog, the guide and `LIMITATIONS.md`.
### Changed
- **A crash file from a newer build no longer loses its tail in an older one.** The file a session writes as it goes
+2 -1
View File
@@ -112,7 +112,8 @@ src/
# (one reader for the Agent, on its own thread, only while held - D107) over
# NvapiAdvancedReader (the bridge's ABI 3) and LhmAdvancedReader (LhmGroups:
# the card; as administrator with PawnIO the processor, memory and board -
# never storage, D103). No Agent code composes it yet. Recording/
# never storage, D103). The Agent composes it since the switch, `telemetry.advanced`
# (PR-5, 2026-11-11: off by default; on, a session holds the hub). Recording/
# AdvancedSessionBuilder stores what a session's samples carried (schema 0023:
# machine_profiles + session_advanced, adv.* series with NaN for a gap, D102).
FrameLedger.Infrastructure/ # SQLite, shm reader, vendor APIs, injector interop, parsers,
+23 -1
View File
@@ -173,6 +173,27 @@ shown is recorded too, from outside the game. ([Capture](docs/04_CAPTURE.md))
- **CPU temperature** needs *Run the agent as administrator* and the separately installed PawnIO driver, and
has not been verified on real hardware yet. CPU load is the time the processor was busy — not Task
Manager's "utility" figure, which can exceed 100%. ([Telemetry](docs/18_GPU_VENDOR_APIS.md))
- **Advanced metrics** (since 0.1.0-beta.39; Settings ▸ Recording, off by default) stores more of what the graphics
driver and the sensors report with each session. Its limits:
- **A session recorded while it was off is not filled in later**, and switching it on applies from the next session.
- **The driver's own figures** — the card's firmware and architecture, its memory in detail, what a display can do
with HDR and variable refresh, the driver's settings for the game — exist on **NVIDIA** cards only. On other cards
they read N/A; the card's sensors (fans, voltages, loads) are read on every brand, and none has been tested on an
AMD or Intel card.
- **The sensors are read every five seconds**, NVIDIA's figures every second; between two readings a sensor has no
value, and its last one is not repeated.
- **The processor's, the memory's and the motherboard's sensors** need *Run the agent as administrator* and the
separately installed PawnIO driver, and **have never been read on real hardware**. Without them they read N/A
with the reason.
- **A drive's temperature is not read at all**: the sensor library cannot list drives without touching removable
ones. Power supplies, fan controllers and batteries are not read either.
- **No serial number and no display identification data (EDID) is read**, so two PCs with the same parts look the
same.
- **None of these readings has been checked against another tool**, and they are **not in an export or a bug
report**.
- **No screen shows them yet** — the page comes with the release.
([Telemetry](docs/18_GPU_VENDOR_APIS.md#advanced-metrics-owner-decisions-d101d108-2026-11-11))
- **Whether the graphics card was held back by its power limit or by heat** (since 0.1.0-beta.14) is known only on
NVIDIA cards, and only as it was at each once-a-second reading. On other cards it reads N/A.
- **Frames per watt** (since 0.1.0-beta.14) counts the game's own frames — never generated ones — against the graphics
@@ -183,7 +204,8 @@ shown is recorded too, from outside the game. ([Capture](docs/04_CAPTURE.md))
Off by default. When on, **Windows asks every time the agent starts** and names an unknown publisher, because
FrameLedger is not signed. It lets FrameLedger open games that run as administrator and read the CPU
temperature; it does not bypass anti-cheat, does not open protected processes, and does not make games you
temperature — with Advanced metrics on, also the processor's, the memory's and the motherboard's sensors — where
PawnIO is installed; it does not bypass anti-cheat, does not open protected processes, and does not make games you
start from FrameLedger run as administrator. **The risk:** FrameLedger is installed in your user folder, so a
program running under your account could replace its files and would then run as administrator the next time
you accept the prompt. Turn it on only if you trust everything that runs under your account.
+8 -1
View File
@@ -12,7 +12,7 @@ app too (Help ▸ User guide, Help ▸ Limitations, Help ▸ Accessibility), and
[wiki](https://github.com/poli0981/frameledger/wiki) with the developer pages.
<!-- accuracy-block:begin -->
> ⚠ **What FrameLedger actually measures today — 2026-11-06.** The software is a beta; its latest
> ⚠ **What FrameLedger actually measures today — 2026-11-11.** The software is a beta; its latest
> **beta is `0.1.0-beta.38`** (2026-11-11), an unsigned installer built from that tag with its
> checksums published beside it (alphas — experimental builds that try a newer .NET — are published apart). The source holds the desktop app
> (library, store import, charts, settings) and the background Agent, which records a session when a
@@ -102,6 +102,13 @@ app too (Help ▸ User guide, Help ▸ Limitations, Help ▸ Accessibility), and
> Windows once a second and charted. Processor temperature is read only when the Agent runs as
> administrator — an option, off by default, for which Windows asks at every start of the Agent — with
> PawnIO installed, and that reading has not yet been checked on real hardware; everywhere else it is `N/A`.
> - **Advanced metrics (since beta.39; off unless you switch it on in Settings):** with it on, a session also stores
> what the graphics driver and the sensor library report about the hardware — the graphics card's memory, load,
> clocks, fans, voltages and power in detail, what a display can do, the driver's settings for the game — as they
> report it: NVIDIA's figures once a second, the sensor library's every five seconds. None of these readings has
> been checked against another tool. The processor's, the memory's and the motherboard's need the Agent as
> administrator with PawnIO and have never been read on real hardware; a drive's temperature is not read. No
> screen of the App shows them yet.
> - **Safety:** every pre-injection check runs before injection, including the signed-by-a-known-vendor
> half of the suspicious-module rule. During every capture the Agent re-runs the checks every 30 s and
> stops capturing on a refusal: a Direct3D or OpenGL game's hooks are removed, and the Vulkan layer
+1 -1
View File
@@ -162,7 +162,7 @@ The profile's own folder is refused there.)*
- **ADR-8:** **No evasion, ever** (`19_SAFETY` §What we will never build). This is an architectural constraint, not a preference — it defines what "correct" means for this codebase.
- **ADR-9:** Elevation demoted from required to optional; the Agent runs as a standard user by default.
**Chosen, not inherited, since beta.10 (owner decision D34, 2026-09-27):** Settings ▸ Capture agent ▸ *Run the agent as
administrator* (`capture.run_elevated`, off by default, a versioned disclosure — `agent-admin-dialog/1` — before it turns
administrator* (`capture.run_elevated`, off by default, a versioned disclosure — `agent-admin-dialog/2` *(`/1` until 2026-11-11, when Advanced metrics widened what the option adds — D101)* — before it turns
on). With it on, **Windows is asked every time the Agent starts** — a UAC prompt owned by the App's window when the App
starts it, flashing on the taskbar when the logon task does — and there is no silent path: no "highest privileges" task,
no service. The elevated Agent is started for one user (`--serve --for-user <SID>`) and refuses to run as another
+1
View File
@@ -467,6 +467,7 @@ switch's rule); integers are invariant-culture within an inclusive range; choice
| `capture.run_elevated` | bool | `0` | | The App when it starts the Agent, and an Agent the logon task started — both BEFORE the Agent exists, through `Infrastructure.Startup.RunElevatedSetting` (one row, `PRAGMA query_only`, no version gate, anything but `1` is off) (D34, beta.10): on, Windows is asked for administrator rights at every Agent start (`01_ARCHITECTURE` ADR-9) |
| `capture.min_session_s` | int | `30` | 5–600 | Agent, per session (FR-3.6) |
| `telemetry.interval_ms` | int | `1000` | 500–2000 | Agent, per session (FR-3.5) |
| `telemetry.advanced` | bool | `0` | | Agent, per session (FR-5.6, owner decision D101, 2026-11-11): **Advanced metrics**. On, a session holds the Agent's shared reader and stores its `adv.*` series and its `session_advanced` row (schema 0023); off — and any row that is not exactly `1` — nothing more is read or stored, and a session recorded while off has no row. Settings ▸ Recording (`18_GPU_VENDOR_APIS` §The switch) |
| `retention.raw_sessions_per_game` | int | `20` | 0–10000; **0 = unlimited** | Agent, per session (§Retention) |
| `retention.remove_uninstalled_games` | bool | `1` | | Agent, at every detection sweep (beta.19, D55, FR-1.8): on, an entry whose executable has been gone for ten minutes — its drive connected, the folder it was installed in still there — and that has no session and no anti-cheat block or exception is removed; off, it stays and reads *Not installed* (D41's behaviour) |
| `update.channel` | choice | ~~`stable`~~ `auto` (beta.14, D47) | `auto` · `stable` · `beta` | UI (P4 PR-5 reads it: `beta` = GitHub pre-releases too; `auto` follows the running copy, a pre-release asking for pre-releases — `11_UPDATER` §The update audit) |
+12 -1
View File
@@ -851,6 +851,17 @@ Tail view of `ui-*.log` / `agent-*.log` (toggle), level filter, search (`ui:Auto
> `PagesLoadTests`.
### Settings
> **Advanced metrics (2026-11-11, owner decision D101; Advanced PR-5).** The Recording section has **Advanced metrics**
> (`telemetry.advanced`, off by default, off in a viewer like every setting the Agent reads): one `ui:CardControl` with a
> `ToggleSwitch`, under *Raw series kept per game*. Its text says what is read, that off reads and stores nothing more,
> that it applies from the next session and that an earlier session is not filled in. The Agent reads it at each
> session's start, so the row gets the usual "Applied. The capture agent reads it at the next session" strip. **No page
> shows what it stores yet** — the navigation item and the page are PR-7's (D105). With it, three texts that said what
> an Agent running as administrator adds with PawnIO now name the processor's, the memory's and the motherboard's
> sensors beside the CPU temperature: the Agent section's elevation line, the first run's Agent step, and the admin
> mode's disclosure (`agent-admin-dialog/2`). Tests: `SettingsViewModelTests.AdvancedMetricsIsOffByDefaultAndItsToggleIsPersisted`,
> `ViewerModeTests.EverySettingTheAgentReadsIsOffInAViewer`, `GuideDocumentsTests.TheSettingsPageOfTheGuideNamesEverySetting`.
>
> **beta.23 (owner decisions D60/D61).** The Games section has, under the Play button, **Show game artwork**
> (`ui.game_art`, on) and **Colour the game page from its artwork** (`ui.game_art_tint`, on; disabled while the first is
> off) — the game page's artwork and its band's colour (§Games › Game detail, *The header's cover*). Neither downloads
@@ -891,7 +902,7 @@ Agent section: elevation state with a plain explanation of what elevation *optio
> **The admin mode, beta.10 (owner decision D34; `01_ARCHITECTURE` ADR-9).** The Agent section has a switch, *Run the agent
> as administrator* (`capture.run_elevated`, off by default). Turning it on opens a `ContentDialog`
> (`Services.AgentAdminPrompt`, text `FrameLedger.Shared`'s `Safety_AdminMode_*`, version `agent-admin-dialog/1` in its
> (`Services.AgentAdminPrompt`, text `FrameLedger.Shared`'s `Safety_AdminMode_*`, version `agent-admin-dialog/2` *(`/1` until 2026-11-11, when Advanced metrics widened what the option adds — D101)* in its
> corner) whose primary button is enabled only by ticking "I understand…" and whose default button keeps standard rights;
> declined, nothing is written. Either way the row is written and the Agent restarts — asked to stop over the pipe, its
> instance lock waited out, the connection's next round starting it the new way — **except under a running session**,
+31 -2
View File
@@ -580,7 +580,7 @@ states here what it built.
a command argument — the colour and info-frame controls — is refused like a writer: the check reads names, not
arguments, and nothing on the list is one. *(Built with ABI 3: `tools/nvapi-readonly-check.ps1`.)*
### The reader (built 2026-11-11; composed by nothing yet)
### The reader (built 2026-11-11; composed by the Agent since the switch)
`Application.Advanced.IAdvancedHardware` is the port: `Acquire()` keeps the reader running until the handle is let
go, `Latest` is the last tick without waiting, `ReadSessionFacts` reads one session's facts on the caller's thread.
@@ -611,7 +611,7 @@ and labelled with the hardware's words. A sensor with no family is not read.
sensor has no reading — its last value is not repeated. The same refresh is what the L2 telemetry layer does once
a second in every session: that cost is not this feature's, and is `20_OPEN_QUESTIONS` §M16.
### From the reader to the ledger (built 2026-11-11; produced by nothing yet)
### From the reader to the ledger (built 2026-11-11; fed since the switch)
- **The poller attaches, it does not read.** `TelemetryPoller` takes an optional `IAdvancedHardware`, holds it from
`Start` to `Dispose`, and at each poll takes `Latest` — a read of one reference. A snapshot it has not taken yet
@@ -625,6 +625,35 @@ and labelled with the hardware's words. A sensor with no family is not read.
aligned to `t_ms` with NaN for a tick with none, and builds the session's row: facts, sources, statistics,
directory. Schema 0023 and the rule for NaN are `06_DATA_MODEL` §Blob encoding and §Migrations.
### The switch (built 2026-11-11, Advanced PR-5)
`telemetry.advanced` (`SettingsRegistry.TelemetryAdvanced`, Boolean, default `0`, read by the Agent) becomes
`RecorderOptions.AdvancedMetrics` through `SettingsRecorderPolicy`, at each session's start like the other recording
settings; exactly `1` is on. From there:
- **The Agent has one reader** — `AgentServices` registers `AdvancedHardwareHub` as `IAdvancedHardware`, a tick a
second and a linger of ten — and nothing starts it but a holder. `SessionRecorder` holds it for a session's length
**only when the option is on**, and `AgentRecording` gives the session's `TelemetryPoller` the reader on the same
condition. Off: not held, not asked, no chunk 9 or 10, no row (`SessionRecorderTests.WithAdvancedMetricsOff…`).
- **A session's facts are read once, off the capture loop.** Fifteen seconds after the game's process is known — by
then it has a window — or at the session's end if that comes first, `IAdvancedHardware.ReadSessionFacts` runs on a
pool thread: asking the driver for a profile takes some hundred milliseconds. The finalize waits at most five
seconds for a read still in flight and stores the session without its facts rather than hold it. A read that
throws costs the facts, never the session.
- **Which display is the game's** comes from Windows, not from the game: `WindowGeometryProbe.MonitorDeviceOf` — the
monitor the process's largest visible window is on, as its GDI device name — which the reader hands to
`FlNvSessionDisplay`. No window, or a display another adapter drives: the session's display facts are absent.
- **The context reaches the crash file as it changes** (chunk 10), from `IAdvancedHardware.Latest` — a read of one
reference on the capture loop's task — so a recovered session keeps its machine facts, its sources and its
directory of series.
- **A session recorded with the option on always stores a row**, if only one that says every source is `Unknown`:
no row means "the option was off when this was recorded", which the page (PR-7) shows as such.
What elevation adds changed with this: an Agent running as administrator with PawnIO reads the processor, memory
and motherboard groups in a session with the option on. The texts that state what the admin mode adds say so —
Disclaimer 2.15 §5 and §5A (the owner's answer of 2026-11-11), the admin mode's disclosure (`agent-admin-dialog/2`),
Settings, the first run, the guide and `LIMITATIONS.md` — and Privacy Policy 2.15 names what is read and stored.
### What belongs to what
| Scope | What it is | Stored | Shown |
+1 -1
View File
@@ -1027,7 +1027,7 @@ injected or layered**.
If `OpenProcess` with the needed rights fails (protected process, higher integrity), do **not** escalate creatively. Report "cannot attach" and offer Tier-2. Never attempt to acquire privileges beyond running the Agent elevated at the user's explicit request.
> **The explicit request exists since beta.10 (owner decision D34, 2026-09-27): the admin mode.** An option off by default,
> turned on through a versioned disclosure (`Safety_AdminMode_*`, `agent-admin-dialog/1`) that states what it adds, what it
> turned on through a versioned disclosure (`Safety_AdminMode_*`, `agent-admin-dialog/2` *(`/1` until 2026-11-11, when Advanced metrics widened what the option adds — D101)*) that states what it adds, what it
> does not change, how Windows asks and the risk of a per-user install; then **Windows asks at every start of the Agent**
> (`01_ARCHITECTURE` ADR-9). What it does NOT do, each held by code rather than by this paragraph:
>
+1
View File
@@ -588,6 +588,7 @@ Where each owner decision is recorded — the file and its section, and a label
| D106 | [`18_GPU_VENDOR_APIS.md`](18_GPU_VENDOR_APIS.md) §Advanced metrics | a `.partial` chunk of an unknown type with a right checksum is skipped, where it ended the read |
| D107 | [`18_GPU_VENDOR_APIS.md`](18_GPU_VENDOR_APIS.md) §Advanced metrics | with no game running the Agent reads sensors only while the page is open |
| D108 | [`18_GPU_VENDOR_APIS.md`](18_GPU_VENDOR_APIS.md) §Advanced metrics | "never call a setter" is a build gate: every `NvAPI_*` call of the bridge is held to a committed list |
| D109 | [`../legal/DISCLAIMER.md`](../legal/DISCLAIMER.md) §5, §5A | asked on 2026-11-11 with both sentences quoted: the Disclaimer goes to 2.15 with the Privacy Policy — PawnIO and the admin mode are no longer "for the CPU temperature" alone; with Advanced metrics on they also read the processor's, the memory's and the motherboard's sensors. The admin mode's disclosure follows (`agent-admin-dialog/2`) |
---
+14
View File
@@ -63,6 +63,20 @@ are kept because they record what each version changed and why (owner decision D
>
> Version 2.5 (2026-09-27, 0.1.0-beta.10) adds how a tracked game's window is shown — read from Windows — and the engine build name read from an Unreal Engine game's executable. It is also the first version to say two things the software already did: it reads the **content** of a library game's executable (markers in its first 8 MB and its import table, since the detection of engines and features; and, when a session starts, the graphics-library markers in the whole file), and it reads the processor load and the memory in use (since 0.1.0-beta.3). Nothing here leaves your device, as before.
### What version 2.15 of the Privacy Policy and of the Disclaimer changed (0.1.0-beta.39)
**Advanced metrics** (owner decisions D101–D108; the Privacy Policy's content approved with the plan, the Disclaimer's
two sentences by the owner's answer of 2026-11-11). Privacy Policy §1 gains one item — what a session stores **only
while the option is on**: more sensor series of the graphics card, and of the processor, the memory and the motherboard
when the Agent runs as administrator with PawnIO; a description of the hardware; what each display can do and what the
game's display did; the graphics driver's settings, global and for the game — and what is never read: a serial
number, a display's EDID, a list of other programs. §3A says an export and a bug report do not carry it. §4 names the
same as things the software can observe, only while the option is on. The Disclaimer's §5 and §5A said PawnIO and the
admin mode were for the CPU temperature alone; both now name the processor's, the memory's and the motherboard's
sensors with the option on. The accuracy block gains an item that says none of these readings has been checked
against another tool. §2 is unchanged: nothing is sent, as before. (Versions 2.12 to 2.14 of the Privacy Policy and
2.12 to 2.14 of the Disclaimer are recorded in the changelog of the release that carried each.)
### What version 2.11 of the Privacy Policy changed (0.1.0-beta.23)
A game's page shows its artwork (beta.23 PR-3, owner decisions D60/D61; the wording approved with the plan). §1 adds the
+2 -1
View File
@@ -22,6 +22,7 @@ The link under them, *Read what the hook does and does not do*, opens the safety
| **Minimum session length (s)** | A shorter session is not kept. 5 to 600 seconds. *Agent.* | 30 |
| **Sensor interval (ms)** | How often the PC's sensors are read during a session. 500 to 2000 ms. *Agent.* | 1000 |
| **Raw series kept per game** | How many of each game's newest sessions keep their per-frame data; older ones keep their statistics. 0 keeps everything. *Agent.* | 20 |
| **Advanced metrics** | Reads more from the graphics driver and the hardware sensors during a session — the graphics card's memory and load in detail, each fan and voltage, what your display can do, the driver's settings for the game — and stores it with the session. Off: nothing more is read or stored. It applies from the next session; a session recorded while it was off is not filled in later. *Agent.* | Off |
## Data
@@ -34,7 +35,7 @@ The link under them, *Read what the hook does and does not do*, opens the safety
| Setting | What it does | Default |
|---|---|---|
| **Run the agent as administrator** | Lets FrameLedger measure games that run as administrator, and read CPU temperature with PawnIO installed. Windows asks every time the agent starts, at logon too. A warning explains the risk first; read [Limitations](../LIMITATIONS.md#running-the-agent-as-administrator). The agent restarts to apply it, or at its next start if a game is being recorded. | Off |
| **Run the agent as administrator** | Lets FrameLedger measure games that run as administrator, and — with PawnIO installed — read CPU temperature and, when *Advanced metrics* is on, the processor's, the memory's and the motherboard's sensors. Windows asks every time the agent starts, at logon too. A warning explains the risk first; read [Limitations](../LIMITATIONS.md#running-the-agent-as-administrator). The agent restarts to apply it, or at its next start if a game is being recorded. | Off |
| **Start the agent at logon** | **Register**, **Repair** or **Remove** a task that starts the agent when you log on, for your user only and without administrator rights. Without it, FrameLedger starts the agent when you open it. | Not installed |
## Appearance
+8 -1
View File
@@ -11,7 +11,7 @@
that changes what FrameLedger.Overlay or the capture host does; date the change.
HTML comments are not part of the block.
-->
> ⚠ **What FrameLedger actually measures today — 2026-11-06.** The software is a beta; its latest
> ⚠ **What FrameLedger actually measures today — 2026-11-11.** The software is a beta; its latest
> **beta is `0.1.0-beta.38`** (2026-11-11), an unsigned installer built from that tag with its
> checksums published beside it (alphas — experimental builds that try a newer .NET — are published apart). The source holds the desktop app
> (library, store import, charts, settings) and the background Agent, which records a session when a
@@ -101,6 +101,13 @@
> Windows once a second and charted. Processor temperature is read only when the Agent runs as
> administrator — an option, off by default, for which Windows asks at every start of the Agent — with
> PawnIO installed, and that reading has not yet been checked on real hardware; everywhere else it is `N/A`.
> - **Advanced metrics (since beta.39; off unless you switch it on in Settings):** with it on, a session also stores
> what the graphics driver and the sensor library report about the hardware — the graphics card's memory, load,
> clocks, fans, voltages and power in detail, what a display can do, the driver's settings for the game — as they
> report it: NVIDIA's figures once a second, the sensor library's every five seconds. None of these readings has
> been checked against another tool. The processor's, the memory's and the motherboard's need the Agent as
> administrator with PawnIO and have never been read on real hardware; a drive's temperature is not read. No
> screen of the App shows them yet.
> - **Safety:** every pre-injection check runs before injection, including the signed-by-a-known-vendor
> half of the suspicious-module rule. During every capture the Agent re-runs the checks every 30 s and
> stops capturing on a refusal: a Direct3D or OpenGL game's hooks are removed, and the Vulkan layer
+12 -4
View File
@@ -1,6 +1,6 @@
# FrameLedger — Disclaimer
**Version:** 2.14 · **Effective:** {{RELEASE_DATE}}
**Version:** 2.15 · **Effective:** {{RELEASE_DATE}}
## 0. This is pre-release software
@@ -120,7 +120,7 @@ Software running inside another process can, in principle, destabilize it. Frame
Frame timing is derived from high-resolution timestamps taken at the moment the game presents each frame; upscaling, frame-generation and ray-tracing state are read from the parameters the game passes to those APIs. This is substantially more accurate than inferring settings from files on disk, but **no measurement is guaranteed to be exact**:
<!-- accuracy-block:begin -->
> ⚠ **What FrameLedger actually measures today — 2026-11-06.** The software is a beta; its latest
> ⚠ **What FrameLedger actually measures today — 2026-11-11.** The software is a beta; its latest
> **beta is `0.1.0-beta.38`** (2026-11-11), an unsigned installer built from that tag with its
> checksums published beside it (alphas — experimental builds that try a newer .NET — are published apart). The source holds the desktop app
> (library, store import, charts, settings) and the background Agent, which records a session when a
@@ -210,6 +210,13 @@ Frame timing is derived from high-resolution timestamps taken at the moment the
> Windows once a second and charted. Processor temperature is read only when the Agent runs as
> administrator — an option, off by default, for which Windows asks at every start of the Agent — with
> PawnIO installed, and that reading has not yet been checked on real hardware; everywhere else it is `N/A`.
> - **Advanced metrics (since beta.39; off unless you switch it on in Settings):** with it on, a session also stores
> what the graphics driver and the sensor library report about the hardware — the graphics card's memory, load,
> clocks, fans, voltages and power in detail, what a display can do, the driver's settings for the game — as they
> report it: NVIDIA's figures once a second, the sensor library's every five seconds. None of these readings has
> been checked against another tool. The processor's, the memory's and the motherboard's need the Agent as
> administrator with PawnIO and have never been read on real hardware; a drive's temperature is not read. No
> screen of the App shows them yet.
> - **Safety:** every pre-injection check runs before injection, including the signed-by-a-known-vendor
> half of the suspicious-module rule. During every capture the Agent re-runs the checks every 30 s and
> stops capturing on a refusal: a Direct3D or OpenGL game's hooks are removed, and the Vulkan layer
@@ -251,14 +258,15 @@ be the difference between a game that runs and one that does not. Turn hooking o
## 5. Hardware and drivers
FrameLedger reads GPU telemetry through vendor libraries that ship with your graphics driver. It **only reads** — it never changes clocks, fan curves, power limits, or any other hardware setting. Optional CPU-temperature support relies on the separate third-party **PawnIO** driver, which you install at your own discretion under its own license; some anti-cheat systems object to third-party kernel drivers regardless of what they are used for.
FrameLedger reads GPU telemetry through vendor libraries that ship with your graphics driver. It **only reads** — it never changes clocks, fan curves, power limits, or any other hardware setting. Optional CPU-temperature support — and, with Advanced metrics on, reading the processor's, the memory's and the motherboard's sensors — relies on the separate third-party **PawnIO** driver, which you install at your own discretion under its own license; some anti-cheat systems object to third-party kernel drivers regardless of what they are used for.
## 5A. Running the capture agent as administrator — optional, and your decision
Since 0.1.0-beta.10 a Settings option, off unless you turn it on, starts FrameLedger's capture agent as administrator.
**Windows asks you every time the agent starts** — also when you sign in — and the prompt names an unknown publisher,
because FrameLedger is not code-signed. It lets FrameLedger open and measure a game that itself runs as administrator,
and read the CPU temperature where PawnIO is installed. It changes nothing in the anti-cheat guard (§2, §2A), opens no
and read the CPU temperature — and, with Advanced metrics on, the processor's, the memory's and the motherboard's
sensors — where PawnIO is installed. It changes nothing in the anti-cheat guard (§2, §2A), opens no
process that Windows or an anti-cheat driver protects, and never starts a game as administrator: games you start from
FrameLedger run with your standard rights.
+4 -3
View File
@@ -1,6 +1,6 @@
# FrameLedger — Privacy Policy
**Version:** 2.14 · **Effective:** {{RELEASE_DATE}}
**Version:** 2.15 · **Effective:** {{RELEASE_DATE}}
**Short version: everything stays on your PC. FrameLedger has no accounts, no telemetry, no analytics, and never uploads your data anywhere.**
@@ -11,6 +11,7 @@ Stored in `%LOCALAPPDATA%\FrameLedger` on your device:
- Your game library entries (names, executable paths, metadata you or the app filled in, and whether each one is recorded).
- Images you choose for a game (Edit…), copied into the `covers` folder; choosing the store's image again, or removing the game together with its sessions, deletes the copy. Artwork a store's app keeps on your PC, or a game ships in its own folder, is shown from where it is and not copied.
- Performance sessions: frame timing series, computed statistics, hardware sensor series (temperatures, load, power, memory usage, and the graphics card's clock speeds, fan speed, memory temperature and whether its power limit or heat held it back), the game's own memory use (its dedicated and shared video memory, private working set, working set and commit, once a second), session duration, crash flags, the graphics driver's settings the game ran under (NVIDIA only), how the game's window was shown (full-screen, borderless or windowed, for how long, its size and the monitor's), tags and notes you write.
- **Only while Settings ▸ Advanced metrics is on** (it is off unless you switch it on), with each session: more hardware sensor series — the graphics card's memory use in detail, its load by part, its clocks, voltages, currents, power, each fan and its video encoder's use; and, when the capture agent runs as administrator with PawnIO installed, the processor's temperatures, load, clocks, power and voltages by core, the memory in use and its modules' temperatures, and the motherboard's temperatures, fans and voltages — and a description of the hardware: the graphics card's firmware version, architecture, bus and memory sizes, the graphics driver's package and the chipset it names, the motherboard's and the memory modules' model names, what each connected display can do (the HDR formats it accepts, its brightness range, variable refresh), whether variable refresh was in use on the display the game ran on and the colour space the game presented in, and the graphics driver's settings — its global ones and the ones it holds for the game (NVIDIA only). No serial number, no display identification data (EDID) and no list of other programs is read or stored. Switching the option off stops the reading; what earlier sessions stored stays with them until you delete those sessions.
- A hardware snapshot per session (CPU/GPU model, driver version, RAM size, OS build, display mode) used for the "what changed between sessions" feature.
- App settings, logs (rotated daily — the app keeps 7 days, the capture agent 14 — including the logs written by the component loaded into games), and, after a crash of the app itself, crash dump files.
- Which games you enabled code injection for, and when you consented.
@@ -38,11 +39,11 @@ The "Report a bug" feature builds a zip file **on your device**, shows you exact
## 3A. Sharing an export or a bug report
An exported session (CSV or JSON) and a bug report can contain your games' names and **the paths to their files** — which include your **Windows user name** when a game is installed under your user folder — your hardware model, graphics driver and Windows build, the times you played, and your tags and notes. A bug report removes user directory paths from its logs; an export is written as it is. Look at a file before you share it. Once you share it, it is outside FrameLedger: whoever receives it, and the site you post it to, can read it under their own terms.
An exported session (CSV or JSON) and a bug report can contain your games' names and **the paths to their files** — which include your **Windows user name** when a game is installed under your user folder — your hardware model, graphics driver and Windows build, the times you played, and your tags and notes. What a session stores only while Advanced metrics is on (§1) is in neither: an export and a bug report carry what they carried before. A bug report removes user directory paths from its logs; an export is written as it is. Look at a file before you share it. Once you share it, it is outside FrameLedger: whoever receives it, and the site you post it to, can read it under their own terms.
## 4. What the app can technically observe
To do its job, FrameLedger observes: which of *your tracked* executables — the entries in your library whose recording is on — are running, and their process trees; whether a game you enabled hooking for runs in an app container, and which of Windows' code-protection settings it runs under (for example, accepting only Microsoft-signed code), read from Windows before any injection; the parameters your games pass to the graphics APIs it intercepts (presentation, upscaling, ray tracing, pipeline creation); the memory use of a tracked game's process — its dedicated and shared video memory, from Windows' GPU performance counters, and its working sets and commit, from Windows' process-memory information, for which a game it does not inject into is opened with the least access Windows offers and closed again (never its memory's content); loaded module names of a game being captured, the version information of its upscaling, frame-generation and neural-rendering libraries, and whether each was loaded from the game's folder or from the graphics driver's own copy (for detection and for the anti-cheat safety check); the names of the files in each library game's install folder, the version information of its executable and of the upscaling and neural-rendering libraries it ships, the content of its executable file (the markers of the engine and of the graphics libraries it carries, the libraries it imports, and the engine build name an Unreal Engine game carries), the version marks an engine keeps in its own files (Unity's player library and the header of its data file, the header of a Godot data pack, an RPG Maker game's title, core script and Game.ini, the library Game.ini names, and the version file of a Ren'Py game's engine), and the store files that name it (Steam's and GOG's, on your disk) and, for a game the Xbox app or the Microsoft Store installed, the package files in its install folder that describe it (`MicrosoftGame.config` and `appxmanifest.xml`) — to detect its engine, its engine version and its features and to check it for anti-cheat before any injection is possible; the lists of installed games that the Steam, GOG GALAXY, Epic Games and itch apps keep on your disk, and where GOG GALAXY is installed, the folders the Xbox app installs games into on each drive (named by the `.GamingRoot` file at the drive's root) with each game's package files, and Windows' answer to whether that game's package is installed for you — read when you import your library and when you press Play, to find the store that installed a game and hand the game to that store's app — Steam's and GOG GALAXY's also when you open a game's page, to find the artwork their apps keep for it; the cover and banner images that the Steam and GOG GALAXY apps keep on your disk for a game in your library and the logo and splash-screen images a game from the Xbox app ships in its own folder — read to show them on its page, never copied or sent anywhere; the size, position and state of a tracked game's window and the monitor it is on, read from Windows and not from the game, and — for a game FrameLedger injects into — whether the game asked for exclusive full-screen; the NVIDIA driver's settings for your tracked executables (read only: the DLSS and frame-generation overrides the NVIDIA App set); hardware sensor values from your graphics driver's own libraries; how busy the processor is and how much memory is in use, from Windows' own counters; the crash reports Windows keeps in its Application log about a tracked game's executable while it ran (to tell a crash from an ordinary exit — the reports are read, never sent anywhere); and the names of the programs a tracked game starts, so that a game's own crash reporter is recognised.
To do its job, FrameLedger observes: which of *your tracked* executables — the entries in your library whose recording is on — are running, and their process trees; whether a game you enabled hooking for runs in an app container, and which of Windows' code-protection settings it runs under (for example, accepting only Microsoft-signed code), read from Windows before any injection; the parameters your games pass to the graphics APIs it intercepts (presentation, upscaling, ray tracing, pipeline creation); the memory use of a tracked game's process — its dedicated and shared video memory, from Windows' GPU performance counters, and its working sets and commit, from Windows' process-memory information, for which a game it does not inject into is opened with the least access Windows offers and closed again (never its memory's content); loaded module names of a game being captured, the version information of its upscaling, frame-generation and neural-rendering libraries, and whether each was loaded from the game's folder or from the graphics driver's own copy (for detection and for the anti-cheat safety check); the names of the files in each library game's install folder, the version information of its executable and of the upscaling and neural-rendering libraries it ships, the content of its executable file (the markers of the engine and of the graphics libraries it carries, the libraries it imports, and the engine build name an Unreal Engine game carries), the version marks an engine keeps in its own files (Unity's player library and the header of its data file, the header of a Godot data pack, an RPG Maker game's title, core script and Game.ini, the library Game.ini names, and the version file of a Ren'Py game's engine), and the store files that name it (Steam's and GOG's, on your disk) and, for a game the Xbox app or the Microsoft Store installed, the package files in its install folder that describe it (`MicrosoftGame.config` and `appxmanifest.xml`) — to detect its engine, its engine version and its features and to check it for anti-cheat before any injection is possible; the lists of installed games that the Steam, GOG GALAXY, Epic Games and itch apps keep on your disk, and where GOG GALAXY is installed, the folders the Xbox app installs games into on each drive (named by the `.GamingRoot` file at the drive's root) with each game's package files, and Windows' answer to whether that game's package is installed for you — read when you import your library and when you press Play, to find the store that installed a game and hand the game to that store's app — Steam's and GOG GALAXY's also when you open a game's page, to find the artwork their apps keep for it; the cover and banner images that the Steam and GOG GALAXY apps keep on your disk for a game in your library and the logo and splash-screen images a game from the Xbox app ships in its own folder — read to show them on its page, never copied or sent anywhere; the size, position and state of a tracked game's window and the monitor it is on, read from Windows and not from the game, and — for a game FrameLedger injects into — whether the game asked for exclusive full-screen; the NVIDIA driver's settings for your tracked executables (read only: the DLSS and frame-generation overrides the NVIDIA App set); hardware sensor values from your graphics driver's own libraries; and — only while Advanced metrics is on — that driver's description of the graphics card and of each connected display, what it reports about the display a tracked game's window is on, its settings for a tracked game and its global ones (read only), and, when the capture agent runs as administrator with PawnIO installed, the sensors and model names of the processor, the memory and the motherboard (never a drive's); how busy the processor is and how much memory is in use, from Windows' own counters; the crash reports Windows keeps in its Application log about a tracked game's executable while it ran (to tell a crash from an ordinary exit — the reports are read, never sent anywhere); and the names of the programs a tracked game starts, so that a game's own crash reporter is recognised.
It does **not** read game memory outside those API parameters, and does not read game saves, chat, input content, network traffic, or anything unrelated to performance measurement. It records only for programs you added to your library and did not switch recording off for — a program whose recording is off is not watched at all — and injects only into games you individually enabled.
@@ -1,6 +1,7 @@
// SPDX-License-Identifier: GPL-3.0-only
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
using FrameLedger.Application.Advanced;
using FrameLedger.Application.AntiCheat;
using FrameLedger.Application.Capture;
using FrameLedger.Application.Consent;
@@ -43,6 +44,7 @@ internal sealed class AgentRecording
private readonly WindowGeometryProbe _display = new();
private readonly UserModeExceptionLapsePolicy _exceptionLapse;
private readonly ICrashReporterSightings _reporters;
private readonly IAdvancedHardware _advanced;
public AgentRecording(
IGameConsentStore store,
@@ -67,8 +69,10 @@ internal sealed class AgentRecording
IUserModeExceptionSwitch exceptions,
IOverlayToleranceChannel tolerance,
UserModeExceptionLapsePolicy exceptionLapse,
ICrashReporterSightings reporters)
ICrashReporterSightings reporters,
IAdvancedHardware advanced)
{
_advanced = advanced;
_reporters = reporters;
_profiles = profiles;
_exceptions = exceptions;
@@ -119,18 +123,21 @@ internal sealed class AgentRecording
_partials,
_finalizer,
_crashes,
static options => Poller(options.TelemetryInterval),
options => Poller(options.TelemetryInterval, options.AdvancedMetrics ? _advanced : null),
TimeProvider.System,
new RecorderOptions { MinimumSessionLength = minimum, PartialFlushInterval = flush },
_observer,
_policy,
_profiles,
_exceptionLapse,
_reporters);
_reporters,
_advanced);
}
/// <summary>L1 + L2 + L3 under the composite, one poller per session; the poller owns and disposes the layers. The interval is the session's (<c>telemetry.interval_ms</c>, D16).</summary>
public static TelemetryPoller Poller(TimeSpan interval)
/// <param name="interval">Between two polls.</param>
/// <param name="advanced">The Agent's shared advanced reader when the session records Advanced metrics (D101); null — the option off — composes none.</param>
public static TelemetryPoller Poller(TimeSpan interval, IAdvancedHardware? advanced = null)
{
// Ownership walks up one step at a time and each local is nulled at its hand-off, so a throw
// anywhere below disposes exactly what nobody owns yet.
@@ -161,7 +168,7 @@ internal sealed class AgentRecording
// The game process's own memory (beta.12, D43): read from outside it through FrameLedger.ProcessStats.dll, for
// whichever process the capture loop tells the poller to follow. Absent DLL = N/A, never a fault.
game = new GameMemoryReader(new NativeProcessStats());
var poller = new TelemetryPoller(composite, new TelemetryPollerOptions { Interval = interval }, TimeProvider.System, ownsSource: true, system, game);
var poller = new TelemetryPoller(composite, new TelemetryPollerOptions { Interval = interval }, TimeProvider.System, ownsSource: true, system, game, advanced);
composite = null;
system = null;
game = null;
@@ -2,6 +2,7 @@
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
using FrameLedger.Agent.Hosting;
using FrameLedger.Application.Advanced;
using FrameLedger.Application.AntiCheat;
using FrameLedger.Application.Capture;
using FrameLedger.Application.Consent;
@@ -120,6 +121,15 @@ internal static class AgentServices
services.AddSingleton<ISeriesCodec, DeflateSeriesCodec>();
services.AddSingleton<SessionFinalizer>();
services.AddSingleton(static sp => new PartialRecovery(sp.GetRequiredService<IPartialSessionStore>(), sp.GetRequiredService<SessionFinalizer>()));
// Advanced metrics (owner decisions D101 and D107): ONE reader for the whole Agent, on a thread of its own, that
// runs only while a session recorded with the option on - or the App's page - holds it, and closes ten seconds
// after the last lets go. Constructing it opens nothing; a PC idling with the Agent in the tray reads no sensor
// for this. The container disposes it with the host.
services.AddSingleton<IAdvancedHardware>(static _ => new AdvancedHardwareHub(
static () => AdvancedHardwareReader.OverThisPc(TimeProvider.System, static line => Serilog.Log.Information("{Line}", line)),
interval: TimeSpan.FromSeconds(1),
linger: TimeSpan.FromSeconds(10),
static line => Serilog.Log.Information("{Line}", line)));
services.AddSingleton<AgentRecording>();
}
@@ -214,6 +214,19 @@
SpinButtonPlacementMode="Inline"
Value="{Binding ViewModel.RetentionRawSessions, Mode=TwoWay}" />
</ui:CardControl>
<!-- Advanced metrics (owner decision D101, 2026-11-11): off by default, and off means nothing more is read or
stored. The Agent reads it at each session's start, so it is off in a viewer like every setting it reads. -->
<ui:CardControl Margin="0,8,0,0" Icon="{ui:SymbolIcon DataUsage24}">
<ui:CardControl.Header>
<StackPanel>
<ui:TextBlock FontTypography="BodyStrong" Text="{x:Static res:Strings.Settings_Advanced_Label}" />
<ui:TextBlock MaxWidth="560" HorizontalAlignment="Left" Style="{StaticResource SecondaryText}" Text="{x:Static res:Strings.Settings_Advanced_Body}" TextWrapping="Wrap" />
</StackPanel>
</ui:CardControl.Header>
<ui:ToggleSwitch AutomationProperties.Name="{x:Static res:Strings.Settings_Advanced_Label}"
IsChecked="{Binding ViewModel.AdvancedMetrics, Mode=TwoWay}"
IsEnabled="{Binding ViewModel.ActsOnThisPc}" />
</ui:CardControl>
<!-- beta.12: "Record games launched outside FrameLedger" stood here; nothing read it (capture.background,
06_DATA_MODEL §Settings registry), and with no way to start a game from the App "off" could only have
meant recording nothing. Removed until a launch path exists. -->
+6
View File
@@ -942,6 +942,8 @@ public static class Strings
nameof(Sessions_GameRamWs_Cell_Format),
nameof(Sessions_GameRamWs_Tooltip_Format),
nameof(Sessions_GameVram_Tooltip_Format),
nameof(Settings_Advanced_Body),
nameof(Settings_Advanced_Label),
nameof(Settings_Agent_Elevated),
nameof(Settings_Agent_Elevation_Body),
nameof(Settings_Agent_Elevation_Label),
@@ -3091,6 +3093,10 @@ public static class Strings
public static string Sessions_GameVram_Tooltip_Format => ResourceManager.GetString(nameof(Sessions_GameVram_Tooltip_Format), Culture) ?? nameof(Sessions_GameVram_Tooltip_Format);
public static string Settings_Advanced_Body => ResourceManager.GetString(nameof(Settings_Advanced_Body), Culture) ?? nameof(Settings_Advanced_Body);
public static string Settings_Advanced_Label => ResourceManager.GetString(nameof(Settings_Advanced_Label), Culture) ?? nameof(Settings_Advanced_Label);
public static string Settings_Agent_Elevated => ResourceManager.GetString(nameof(Settings_Agent_Elevated), Culture) ?? nameof(Settings_Agent_Elevated);
public static string Settings_Agent_Elevation_Body => ResourceManager.GetString(nameof(Settings_Agent_Elevation_Body), Culture) ?? nameof(Settings_Agent_Elevation_Body);
+10 -2
View File
@@ -405,6 +405,14 @@
<value>エージェントがルール更新に応答しませんでした。</value>
<comment>review</comment>
</data>
<data name="Settings_Advanced_Body" xml:space="preserve">
<value>セッション中にグラフィックス ドライバーとハードウェア センサーからさらに多くを読み取り、セッションと一緒に保存します - グラフィックス カードのメモリと負荷の詳細、各ファンと電圧、ディスプレイの対応機能、ゲームに対するドライバーの設定など。オフ: 追加の読み取りも保存も行いません。次のセッションから適用され、オフの間に記録したセッションが後から補われることはありません。</value>
<comment>review</comment>
</data>
<data name="Settings_Advanced_Label" xml:space="preserve">
<value>詳細メトリクス</value>
<comment>review</comment>
</data>
<data name="Settings_Appearance_Header" xml:space="preserve">
<value>外観</value>
<comment>review</comment>
@@ -1982,7 +1990,7 @@
<comment>review</comment>
</data>
<data name="Settings_Agent_Elevation_Body" xml:space="preserve">
<value>昇格はどのキャプチャティアにも必須ではありません。CPU 温度 (PawnIO 経由) と、昇格して動作するゲームへのアタッチを任意で有効にするだけです。フック・実測・記録はすべて昇格なしで動作します。</value>
<value>昇格はどのキャプチャティアにも必須ではありません。CPU 温度と、詳細メトリクスがオンの場合はプロセッサ・メモリ・マザーボードのセンサー (いずれも PawnIO 経由)、および昇格して動作するゲームへのアタッチを任意で有効にするだけです。フック・実測・記録はすべて昇格なしで動作します。</value>
<comment>review</comment>
</data>
<data name="Settings_Agent_Elevation_Label" xml:space="preserve">
@@ -2338,7 +2346,7 @@
<comment>review</comment>
</data>
<data name="FirstRun_Agent_Body" xml:space="preserve">
<value>FrameLedger は小さなキャプチャエージェントを標準ユーザーとして (昇格せずに) 起動します。昇格は任意で、どのキャプチャティアにも必須ではありません。CPU 温度 (PawnIO 経由) と、昇格して動作するゲームへのアタッチを有効にするだけです。以下はエージェントがこのマシンについて報告した内容です。</value>
<value>FrameLedger は小さなキャプチャエージェントを標準ユーザーとして (昇格せずに) 起動します。昇格は任意で、どのキャプチャティアにも必須ではありません。CPU 温度と、詳細メトリクスがオンの場合はプロセッサ・メモリ・マザーボードのセンサー (いずれも PawnIO 経由)、および昇格して動作するゲームへのアタッチを有効にするだけです。以下はエージェントがこのマシンについて報告した内容です。</value>
<comment>review</comment>
</data>
<data name="FirstRun_Agent_Header" xml:space="preserve">
+8 -2
View File
@@ -309,6 +309,12 @@
<data name="Rules_Update_Failed" xml:space="preserve">
<value>The agent did not answer the rules update.</value>
</data>
<data name="Settings_Advanced_Body" xml:space="preserve">
<value>Read more from the graphics driver and the hardware sensors during a session - the graphics card's memory and load in detail, each fan and voltage, what your display can do, the driver's settings for the game - and store it with the session. Off: nothing more is read or stored. It applies from the next session, and a session recorded while it was off is not filled in later.</value>
</data>
<data name="Settings_Advanced_Label" xml:space="preserve">
<value>Advanced metrics</value>
</data>
<data name="Settings_Appearance_Header" xml:space="preserve">
<value>Appearance</value>
</data>
@@ -1492,7 +1498,7 @@
<value>Running elevated.</value>
</data>
<data name="Settings_Agent_Elevation_Body" xml:space="preserve">
<value>Elevation is not required by any capture tier. It optionally unlocks CPU temperature (through PawnIO) and attaching to games that run elevated themselves. Everything else — hooking, measuring, recording — works without it.</value>
<value>Elevation is not required by any capture tier. It optionally unlocks CPU temperature and, with Advanced metrics on, the processor's, the memory's and the motherboard's sensors (both through PawnIO), and attaching to games that run elevated themselves. Everything else — hooking, measuring, recording — works without it.</value>
</data>
<data name="Settings_Agent_Elevation_Label" xml:space="preserve">
<value>Elevation</value>
@@ -1759,7 +1765,7 @@
<value>Accept</value>
</data>
<data name="FirstRun_Agent_Body" xml:space="preserve">
<value>FrameLedger starts a small capture agent beside itself, as a standard user — not elevated. Elevation is optional and is not required by any capture tier: it only unlocks CPU temperature (through PawnIO) and attaching to games that run elevated themselves. Below is what the agent reports about this machine.</value>
<value>FrameLedger starts a small capture agent beside itself, as a standard user — not elevated. Elevation is optional and is not required by any capture tier: it only unlocks CPU temperature and, with Advanced metrics on, the processor's, the memory's and the motherboard's sensors (both through PawnIO), and attaching to games that run elevated themselves. Below is what the agent reports about this machine.</value>
</data>
<data name="FirstRun_Agent_Header" xml:space="preserve">
<value>The capture agent</value>
+8 -2
View File
@@ -304,6 +304,12 @@
<data name="Rules_Update_Failed" xml:space="preserve">
<value>Agent không phản hồi yêu cầu cập nhật quy tắc.</value>
</data>
<data name="Settings_Advanced_Body" xml:space="preserve">
<value>Đọc thêm từ driver đồ hoạ và các cảm biến phần cứng trong lúc ghi phiên - bộ nhớ và tải của card đồ hoạ ở mức chi tiết, từng quạt và điện áp, khả năng của màn hình, thiết lập của driver cho game - và lưu cùng phiên. Tắt: không đọc và không lưu thêm gì. Áp dụng từ phiên kế tiếp; phiên đã ghi lúc tắt sẽ không được bổ sung về sau.</value>
</data>
<data name="Settings_Advanced_Label" xml:space="preserve">
<value>Thông số nâng cao</value>
</data>
<data name="Settings_Appearance_Header" xml:space="preserve">
<value>Giao diện</value>
</data>
@@ -1487,7 +1493,7 @@
<value>Đang chạy với quyền quản trị.</value>
</data>
<data name="Settings_Agent_Elevation_Body" xml:space="preserve">
<value>Không tier nào cần quyền quản trị. Nó chỉ tuỳ chọn mở khoá nhiệt độ CPU (qua PawnIO) và gắn vào game tự chạy với quyền quản trị. Mọi thứ khác — hook, đo, ghi — đều chạy không cần.</value>
<value>Không tier nào cần quyền quản trị. Nó chỉ tuỳ chọn mở khoá nhiệt độ CPU và, khi bật Thông số nâng cao, cảm biến của bộ xử lý, bộ nhớ và bo mạch (đều qua PawnIO), cùng việc gắn vào game tự chạy với quyền quản trị. Mọi thứ khác — hook, đo, ghi — đều chạy không cần.</value>
</data>
<data name="Settings_Agent_Elevation_Label" xml:space="preserve">
<value>Quyền quản trị</value>
@@ -1754,7 +1760,7 @@
<value>Chấp nhận</value>
</data>
<data name="FirstRun_Agent_Body" xml:space="preserve">
<value>FrameLedger khởi động một capture agent nhỏ bên cạnh nó, với quyền người dùng thường — không nâng quyền. Nâng quyền là tuỳ chọn và không tier thu thập nào yêu cầu: nó chỉ mở khoá nhiệt độ CPU (qua PawnIO) và gắn vào game tự chạy với quyền quản trị. Bên dưới là những gì agent báo cáo về máy này.</value>
<value>FrameLedger khởi động một capture agent nhỏ bên cạnh nó, với quyền người dùng thường — không nâng quyền. Nâng quyền là tuỳ chọn và không tier thu thập nào yêu cầu: nó chỉ mở khoá nhiệt độ CPU và, khi bật Thông số nâng cao, cảm biến của bộ xử lý, bộ nhớ và bo mạch (đều qua PawnIO), cùng việc gắn vào game tự chạy với quyền quản trị. Bên dưới là những gì agent báo cáo về máy này.</value>
</data>
<data name="FirstRun_Agent_Header" xml:space="preserve">
<value>Capture agent</value>
@@ -80,6 +80,13 @@ public sealed partial class SettingsViewModel : ObservableObject
[ObservableProperty]
private bool _removeUninstalledGames;
/// <summary>
/// "Advanced metrics" (owner decision D101, <c>telemetry.advanced</c>, off by default): the Agent reads more from the
/// graphics driver and the sensors during a session and stores it; off, nothing more is read or stored.
/// </summary>
[ObservableProperty]
private bool _advancedMetrics;
[ObservableProperty]
private int _minSessionSeconds;
@@ -425,6 +432,8 @@ public sealed partial class SettingsViewModel : ObservableObject
partial void OnRemoveUninstalledGamesChanged(bool value) => Persist(SettingsRegistry.RetentionRemoveUninstalledGames, value);
partial void OnAdvancedMetricsChanged(bool value) => Persist(SettingsRegistry.TelemetryAdvanced, value);
partial void OnHideAntiCheatHookingChanged(bool value) => Persist(SettingsRegistry.UiHideAntiCheatHooking, value);
/// <summary>D33: the option is one settings row the Agent reads at every session start and command; the list follows it.</summary>
@@ -580,6 +589,7 @@ public sealed partial class SettingsViewModel : ObservableObject
TelemetryIntervalMs = await _settings.GetIntegerAsync(SettingsRegistry.TelemetryIntervalMs).ConfigureAwait(true);
RetentionRawSessions = await _settings.GetIntegerAsync(SettingsRegistry.RetentionRawSessionsPerGame).ConfigureAwait(true);
RemoveUninstalledGames = await _settings.GetBooleanAsync(SettingsRegistry.RetentionRemoveUninstalledGames).ConfigureAwait(true);
AdvancedMetrics = await _settings.GetBooleanAsync(SettingsRegistry.TelemetryAdvanced).ConfigureAwait(true);
MinimizeToTray = await _settings.GetBooleanAsync(SettingsRegistry.UiMinimizeToTray).ConfigureAwait(true);
HideAntiCheatHooking = await _settings.GetBooleanAsync(SettingsRegistry.UiHideAntiCheatHooking).ConfigureAwait(true);
UserModeExceptions = await _settings.GetBooleanAsync(SettingsRegistry.HookingUserModeExceptions).ConfigureAwait(true);
@@ -17,4 +17,11 @@ public sealed record RecorderOptions
/// <summary>FR-3.5: the sensor poll interval (<c>telemetry.interval_ms</c>, 500–2000).</summary>
public TimeSpan TelemetryInterval { get; init; } = TimeSpan.FromSeconds(1);
/// <summary>
/// <c>telemetry.advanced</c> (owner decision D101): whether this session holds the shared advanced reader, carries
/// its readings and stores them. False — the default, and every recorder with no such reader — reads and stores
/// nothing more than a session always did.
/// </summary>
public bool AdvancedMetrics { get; init; }
}
@@ -2,6 +2,7 @@
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
using System.Globalization;
using FrameLedger.Application.Advanced;
using FrameLedger.Application.Capture;
using FrameLedger.Application.Persistence;
using FrameLedger.Application.Telemetry;
@@ -49,13 +50,17 @@ public sealed class SessionRecorder : ISessionRecorder
private readonly IDriverProfileSource? _profiles;
private readonly UserModeExceptionLapsePolicy? _exceptionLapse;
private readonly ICrashReporterSightings? _reporters;
private readonly IAdvancedHardware? _advanced;
public SessionRecorder(ICaptureSessionFactory sessions, IGameRepository games, IHardwareSnapshotRepository snapshots,
IHardwareSnapshotSource hardware, IPartialSessionStore partials, SessionFinalizer finalizer, ICrashEventSource crashes,
Func<RecorderOptions, ITelemetryPoller?> pollers, TimeProvider clock, RecorderOptions? options = null, ISessionObserver? observer = null,
IRecorderPolicy? policy = null, IDriverProfileSource? profiles = null, UserModeExceptionLapsePolicy? exceptionLapse = null,
ICrashReporterSightings? reporters = null)
ICrashReporterSightings? reporters = null, IAdvancedHardware? advanced = null)
{
// Advanced metrics (owner decision D101): the Agent's one shared reader, held by a session only when the option
// is on (RecorderOptions.AdvancedMetrics); null in every recorder that has none (the tests, the unshipped host).
_advanced = advanced;
// beta.14: the engine crash reporters the watcher saw the game start; null where nothing watches (the tests, the console).
_reporters = reporters;
// D33: ends a game's user-mode exception when a session under it ends badly; null in every recorder that has no
@@ -116,6 +121,11 @@ public sealed class SessionRecorder : ISessionRecorder
long qpcEpoch, long snapshotId, RecorderOptions options, CancellationToken ct)
{
ITelemetryPoller? poller = _pollers(options);
// Held for the whole session - the poller holds it too, and lets go before the finalize reads the last snapshot.
// With the option off nothing is held, and the shared reader is not started for this session (D101).
IAdvancedHardware? advanced = options.AdvancedMetrics ? _advanced : null;
using IDisposable? advancedHold = advanced?.Acquire();
// The driver profile, read BESIDE the session rather than before it (beta.8): a DRS load takes tens of milliseconds
// and a launch must not wait on it. The profile the driver applies is fixed when the process starts, so a read that
// starts here and is awaited at the end describes the run.
@@ -138,10 +148,11 @@ public sealed class SessionRecorder : ISessionRecorder
};
using var writer = new PartialSessionWriter(_partials.Create(header), _clock, options.PartialFlushInterval);
var run = new Run(writer, poller, _clock, _observer, guid);
var run = new Run(writer, poller, _clock, _observer, guid, advanced, request.NormalisedExePath);
writer.Note("started " + request.Mode);
CaptureOutcome outcome = await RunLoopAsync(request, run, ct).ConfigureAwait(false);
DateTimeOffset endedAt = _clock.GetUtcNow();
await run.CompleteAdvancedAsync().ConfigureAwait(false);
run.FinalFlush();
writer.Note("ended " + outcome.Reason);
@@ -207,6 +218,7 @@ public sealed class SessionRecorder : ISessionRecorder
Skeleton = skeleton,
Hooked = hooked ? Hooked(outcome, header.QpcFrequency) : null,
Sensors = writer.Sensors,
Advanced = writer.Advanced,
RetentionKeep = options.RetentionKeep,
MinimumSessionLength = options.MinimumSessionLength,
ExePath = request.NormalisedExePath,
@@ -335,12 +347,29 @@ public sealed class SessionRecorder : ISessionRecorder
/// The recorder's ears on the loop: the flush and the telemetry drain, on the loop's task — and, after
/// each of those, the outside observer's turn with the same tick.
/// </summary>
private sealed class Run(PartialSessionWriter writer, ITelemetryPoller? poller, TimeProvider clock, ISessionObserver? observer, Guid guid) : ICaptureObserver
private sealed class Run(PartialSessionWriter writer, ITelemetryPoller? poller, TimeProvider clock, ISessionObserver? observer, Guid guid,
IAdvancedHardware? advanced, string exePath) : ICaptureObserver
{
/// <summary>
/// How long after the game's process is known its session facts are asked for (owner decision D101): by then
/// it has a window, so the monitor it presents on can be found. A session shorter than the minimum is discarded
/// anyway; one that ends before this asks at its end.
/// </summary>
private static readonly TimeSpan _sessionFactsAfter = TimeSpan.FromSeconds(15);
/// <summary>The longest the finalize waits for a session-facts read still in flight.</summary>
private static readonly TimeSpan _sessionFactsWait = TimeSpan.FromSeconds(5);
private readonly List<TelemetrySample> _drained = [];
private CaptureProgress? _last;
private ulong _adapter;
private uint? _gamePid;
private long _gameSince;
private Task? _sessionFactsRead;
private volatile IReadOnlyList<AdvancedFact>? _sessionFacts;
private (IReadOnlyList<AdvancedFact>? Machine, IReadOnlyList<AdvancedSeriesInfo>? Series, AdvancedSources? Sources, IReadOnlyList<AdvancedFact>? Session) _context;
public DateTimeOffset? AttachedAt { get; private set; }
public void Attached(int pid, FlShmHandshake handshake)
@@ -357,6 +386,12 @@ public sealed class SessionRecorder : ISessionRecorder
public void Measuring(GameProcess target)
{
poller?.Follow(target);
if (advanced is not null && PidOf(target) is uint game && game != _gamePid)
{
_gamePid = game;
_gameSince = clock.GetTimestamp();
}
writer.Note(target.IsNone
? "memory: none"
: target.Pid is int pid
@@ -369,10 +404,93 @@ public sealed class SessionRecorder : ISessionRecorder
_last = progress;
FollowAdapter(progress.AdapterLuid);
DrainTelemetry();
UpdateAdvancedContext(atEnd: false);
writer.OnTick(progress);
observer?.Tick(guid, progress, _drained);
}
/// <summary>
/// Before the last flush (owner decision D101): the session's facts are asked for if they were not yet, a read in
/// flight is given a few seconds, and the context is set once more — so a session recorded with the option on
/// always stores a row, if only to say that nothing answered. Does nothing with the option off.
/// </summary>
public async Task CompleteAdvancedAsync()
{
if (advanced is null)
{
return;
}
UpdateAdvancedContext(atEnd: true);
if (_sessionFactsRead is { IsCompleted: false } pending)
{
try
{
await pending.WaitAsync(_sessionFactsWait, clock).ConfigureAwait(false);
}
catch (TimeoutException)
{
// The driver did not answer in time: the session is stored without its facts rather than held up.
}
}
UpdateAdvancedContext(atEnd: true);
if (writer.Advanced is null)
{
writer.SetAdvancedContext(new AdvancedSessionData([], [], [], AdvancedSources.Unknown));
}
}
/// <summary>
/// Keeps the writer's advanced context current — from the shared reader's latest snapshot, which is a read of
/// one reference, and from the session's facts once they were read. The facts are read OFF this task: asking
/// the driver for a profile takes some hundred milliseconds, and this is the capture loop's.
/// </summary>
private void UpdateAdvancedContext(bool atEnd)
{
if (advanced is null)
{
return;
}
if (_sessionFactsRead is null && _gamePid is uint pid && (atEnd || clock.GetElapsedTime(_gameSince) >= _sessionFactsAfter))
{
var target = new AdvancedSessionTarget(pid, exePath, GdiDeviceName: null);
_sessionFactsRead = Task.Run(() => _sessionFacts = ReadSessionFacts(advanced, target));
}
AdvancedSnapshot? snapshot = advanced.Latest;
IReadOnlyList<AdvancedFact>? session = _sessionFacts;
(IReadOnlyList<AdvancedFact>?, IReadOnlyList<AdvancedSeriesInfo>?, AdvancedSources?, IReadOnlyList<AdvancedFact>?) now = (snapshot?.MachineFacts, snapshot?.Series, snapshot?.Sources, session);
if ((snapshot is null && session is null)
|| (ReferenceEquals(now.Item1, _context.Machine) && ReferenceEquals(now.Item2, _context.Series) && Equals(now.Item3, _context.Sources) && ReferenceEquals(now.Item4, _context.Session)))
{
return;
}
_context = now;
writer.SetAdvancedContext(new AdvancedSessionData(snapshot?.MachineFacts ?? [], session ?? [], snapshot?.Series ?? [], snapshot?.Sources ?? AdvancedSources.Unknown));
}
private static IReadOnlyList<AdvancedFact> ReadSessionFacts(IAdvancedHardware advanced, AdvancedSessionTarget target)
{
try
{
return advanced.ReadSessionFacts(target);
}
catch (Exception e) when (e is not OperationCanceledException)
{
// The reader guards its sources; a throw here is a defect in it, and it costs the session its facts, not itself.
return [];
}
}
private static uint? PidOf(GameProcess target)
{
int? pid = target.IsNone ? null : target.Pid ?? (target.Processes.Count > 0 ? target.Processes[0].Pid : null);
return pid is > 0 ? (uint)pid.Value : null;
}
/// <summary>
/// The adapter the game presents on (beta.13): the Overlay publishes its LUID at the first present, the telemetry thread
/// is told once, and the <c>.partial</c> says whether its layers could follow — until then, and where they could not,
@@ -24,6 +24,7 @@ public sealed class SettingsRecorderPolicy : IRecorderPolicy
int minimumSeconds = await _settings.GetIntegerAsync(SettingsRegistry.CaptureMinSessionSeconds, ct).ConfigureAwait(false);
int keep = await _settings.GetIntegerAsync(SettingsRegistry.RetentionRawSessionsPerGame, ct).ConfigureAwait(false);
int intervalMs = await _settings.GetIntegerAsync(SettingsRegistry.TelemetryIntervalMs, ct).ConfigureAwait(false);
bool advanced = await _settings.GetBooleanAsync(SettingsRegistry.TelemetryAdvanced, ct).ConfigureAwait(false);
TimeSpan minimum = baseline.MinimumSessionLength < SessionFinalizer.MinimumSessionLength
? baseline.MinimumSessionLength
@@ -33,6 +34,7 @@ public sealed class SettingsRecorderPolicy : IRecorderPolicy
MinimumSessionLength = minimum,
RetentionKeep = keep == 0 ? int.MaxValue : keep,
TelemetryInterval = TimeSpan.FromMilliseconds(intervalMs),
AdvancedMetrics = advanced,
};
}
}
@@ -190,6 +190,22 @@ public static class SettingsRegistry
AgentReads = true,
};
/// <summary>
/// "Advanced metrics" (owner decision D101, 2026-11-11): whether the Agent reads, and a session stores, what the
/// vendor interfaces make available beyond the fixed sensors — NVAPI's facts and figures, every sensor
/// LibreHardwareMonitor has for the card and, as administrator with PawnIO, for the processor, memory and
/// motherboard (<c>18_GPU_VENDOR_APIS</c> §Advanced metrics). <b>Off by default, and off means nothing more is
/// read or stored</b>; a session recorded while it was off is never filled in afterwards. Read at each session's
/// start like every key the Agent reads. Exactly "1" is on.
/// </summary>
public static readonly SettingDefinition TelemetryAdvanced = new()
{
Key = "telemetry.advanced",
Kind = SettingKind.Boolean,
Default = "0",
AgentReads = true,
};
/// <summary>FR-3.5: telemetry at 1 Hz, configurable 0.5–2 s. Milliseconds.</summary>
public static readonly SettingDefinition TelemetryIntervalMs = new()
{
@@ -268,7 +284,7 @@ public static class SettingsRegistry
public static IReadOnlyList<SettingDefinition> All { get; } =
[
UiLanguage, UiTheme, UiStartWithWindows, UiMinimizeToTray, UiHideAntiCheatHooking, UiFpsDecimals, UiHideScrollBars, UiLibraryView, UiPlayMode,
UiGameArt, UiGameArtTint, CaptureBackground, HookingKillSwitch, HookingUserModeExceptions, CaptureRunElevated, CaptureMinSessionSeconds, TelemetryIntervalMs, RetentionRawSessionsPerGame,
UiGameArt, UiGameArtTint, CaptureBackground, HookingKillSwitch, HookingUserModeExceptions, CaptureRunElevated, CaptureMinSessionSeconds, TelemetryIntervalMs, TelemetryAdvanced, RetentionRawSessionsPerGame,
RetentionRemoveUninstalledGames, UpdateChannel, UpdateAutoCheck, PrivacyOnlineMetadata, LogDebug,
];
@@ -127,6 +127,37 @@ public sealed class WindowGeometryProbe : IDisplayProbe
return true;
}
/// <summary>
/// The GDI device name of the monitor the game's main window is on (<c>\\.\DISPLAY1</c>), or null when the game has
/// no window yet. Advanced metrics (owner decision D101) asks the driver about that display; the name is the
/// monitor's place in Windows' list — not an identity of the monitor, and never stored.
/// </summary>
public static unsafe string? MonitorDeviceOf(IReadOnlyCollection<int> pids)
{
ArgumentNullException.ThrowIfNull(pids);
if (pids.Count == 0)
{
return null;
}
HWND window = Largest(pids);
if (window.IsNull)
{
return null;
}
HMONITOR monitor = PInvoke.MonitorFromWindow(window, MONITOR_FROM_FLAGS.MONITOR_DEFAULTTONEAREST);
var info = new MONITORINFOEXW();
info.monitorInfo.cbSize = (uint)sizeof(MONITORINFOEXW);
if (monitor.IsNull || !PInvoke.GetMonitorInfo(monitor, (MONITORINFO*)&info))
{
return null;
}
string device = info.szDevice.ToString();
return device.Length == 0 ? null : device;
}
private static bool IsToolWindow(HWND window) =>
((WINDOW_EX_STYLE)(nuint)PInvoke.GetWindowLongPtr(window, WINDOW_LONG_PTR_INDEX.GWL_EXSTYLE)).HasFlag(WINDOW_EX_STYLE.WS_EX_TOOLWINDOW);
@@ -51,6 +51,7 @@ public sealed class AdvancedHardwareReader : IAdvancedHardwareReader
private readonly bool? _pawnIoInstalled;
private readonly TimeProvider _time;
private readonly Action<string> _note;
private readonly Func<uint, string?>? _monitorOf;
private NvapiAdvancedReader? _nvapi;
private LhmAdvancedReader? _lhm;
@@ -72,14 +73,17 @@ public sealed class AdvancedHardwareReader : IAdvancedHardwareReader
/// <param name="pawnIoInstalled">Whether PawnIO is installed; null when that could not be told, which is not a yes.</param>
/// <param name="time">The clock a snapshot is stamped with.</param>
/// <param name="note">Told, in one line, when a source is given up or initialised again — the Agent's log.</param>
/// <param name="monitorOf">Finds the GDI device name of the monitor a process's window is on, for a session that did not name one; null finds none.</param>
public AdvancedHardwareReader(
Func<NvapiAdvancedReader> nvapi,
Func<LhmGroups, LhmAdvancedReader> lhm,
bool elevated,
bool? pawnIoInstalled,
TimeProvider time,
Action<string>? note = null)
Action<string>? note = null,
Func<uint, string?>? monitorOf = null)
{
_monitorOf = monitorOf;
ArgumentNullException.ThrowIfNull(nvapi);
ArgumentNullException.ThrowIfNull(lhm);
ArgumentNullException.ThrowIfNull(time);
@@ -99,7 +103,8 @@ public sealed class AdvancedHardwareReader : IAdvancedHardwareReader
LhmEnvironment.IsElevated,
LhmEnvironment.IsPawnIoInstalled,
time,
note);
note,
static pid => Display.WindowGeometryProbe.MonitorDeviceOf([(int)pid]));
public void Open()
{
@@ -151,7 +156,10 @@ public sealed class AdvancedHardwareReader : IAdvancedHardwareReader
try
{
return _nvapi.ReadSessionFacts(target.GdiDeviceName, target.ProcessId, target.ExecutablePath);
// A session that names no monitor is asked about the one its window is on now - found from outside
// the game, by a user32 question about a top-level window (WindowGeometryProbe).
string? device = target.GdiDeviceName ?? _monitorOf?.Invoke(target.ProcessId);
return _nvapi.ReadSessionFacts(device, target.ProcessId, target.ExecutablePath);
}
catch (Exception e) when (e is not OperationCanceledException)
{
@@ -7,7 +7,9 @@ namespace FrameLedger.Shared.Safety;
/// The version of the admin mode's disclosure this build carries (beta.10, owner decision D34) — the
/// <c>Safety_AdminMode_*</c> strings in <c>Strings.resx</c> beside this file, shown before <c>capture.run_elevated</c> is
/// turned on. The same discipline as <see cref="SafetyDisclosure"/>: bump it whenever a <c>Safety_AdminMode_*</c> string
/// changes MEANING in any language.
/// changes MEANING in any language. <c>/2</c> since 2026-11-11 (owner decision D101): with Advanced metrics on, an Agent
/// running as administrator with PawnIO also reads the processor's, the memory's and the motherboard's sensors, and
/// "what it adds" says so.
/// </summary>
/// <remarks>
/// Nothing records an acceptance of it: the option being on is the acceptance, turning it on always shows the text, and
@@ -15,5 +17,5 @@ namespace FrameLedger.Shared.Safety;
/// </remarks>
public static class AgentAdminDisclosure
{
public const string Version = "agent-admin-dialog/1";
public const string Version = "agent-admin-dialog/2";
}
+1 -1
View File
@@ -56,7 +56,7 @@
<comment>safety: human review required</comment>
</data>
<data name="Safety_AdminMode_Adds" xml:space="preserve">
<value>What it adds: FrameLedger can open and measure a game that itself runs as administrator, and it can read the CPU temperature where PawnIO is installed.</value>
<value>What it adds: FrameLedger can open and measure a game that itself runs as administrator, and, where PawnIO is installed, it can read the CPU temperature and - with Advanced metrics on - the processor's, the memory's and the motherboard's sensors.</value>
<comment>safety: human review required</comment>
</data>
<data name="Safety_AdminMode_Unchanged" xml:space="preserve">
+1 -1
View File
@@ -59,7 +59,7 @@
<value>The capture agent normally runs with your standard rights, and every capture tier works that way. This option asks Windows to start it as administrator instead.</value>
</data>
<data name="Safety_AdminMode_Adds" xml:space="preserve">
<value>What it adds: FrameLedger can open and measure a game that itself runs as administrator, and it can read the CPU temperature where PawnIO is installed.</value>
<value>What it adds: FrameLedger can open and measure a game that itself runs as administrator, and, where PawnIO is installed, it can read the CPU temperature and - with Advanced metrics on - the processor's, the memory's and the motherboard's sensors.</value>
</data>
<data name="Safety_AdminMode_Unchanged" xml:space="preserve">
<value>What it does not change: a game with anti-cheat is still refused, and a process Windows protects stays unreadable. A Vulkan game that runs as administrator is still not measured, because Windows does not load FrameLedger's Vulkan layer into it. Games you start from FrameLedger still run with your standard rights.</value>
+1 -1
View File
@@ -53,7 +53,7 @@
<value>Capture agent bình thường chạy với quyền người dùng thường của bạn, và mọi tier ghi nhận đều hoạt động như vậy. Tuỳ chọn này yêu cầu Windows khởi động nó với quyền quản trị thay vào đó.</value>
</data>
<data name="Safety_AdminMode_Adds" xml:space="preserve">
<value>Điều nó thêm vào: FrameLedger có thể mở và đo một game tự chạy với quyền quản trị, và có thể đọc nhiệt độ CPU ở máy đã cài PawnIO.</value>
<value>Điều nó thêm vào: FrameLedger có thể mở và đo một game tự chạy với quyền quản trị, và, ở máy đã cài PawnIO, có thể đọc nhiệt độ CPU cùng - khi bật Thông số nâng cao - cảm biến của bộ xử lý, bộ nhớ và bo mạch.</value>
</data>
<data name="Safety_AdminMode_Unchanged" xml:space="preserve">
<value>Điều nó không thay đổi: game có anti-cheat vẫn bị từ chối, và tiến trình được Windows bảo vệ vẫn không đọc được. Game Vulkan chạy với quyền quản trị vẫn không được đo, vì Windows không nạp Vulkan layer của FrameLedger vào nó. Game bạn khởi động từ FrameLedger vẫn chạy với quyền người dùng thường.</value>
@@ -448,6 +448,31 @@ public sealed class SettingsViewModelTests
}
}
[Fact]
public async Task AdvancedMetricsIsOffByDefaultAndItsToggleIsPersisted()
{
// Owner decision D101 (2026-11-11): telemetry.advanced, default 0. The Agent reads it at the next session's
// start, so nothing here applies it at once - the row is what moves.
await using ScratchLedger s = await ScratchLedger.OpenAsync();
Harness h = await OpenAsync(s);
h.Vm.AdvancedMetrics.Should().BeFalse();
(await h.Settings.GetBooleanAsync(SettingsRegistry.TelemetryAdvanced, Ct)).Should().BeFalse();
h.Vm.AdvancedMetrics = true;
Task on = h.Vm.Pending;
await on;
(await h.Settings.GetBooleanAsync(SettingsRegistry.TelemetryAdvanced, Ct)).Should().BeTrue();
Harness reopened = await OpenAsync(s);
reopened.Vm.AdvancedMetrics.Should().BeTrue("the page shows what the row holds");
reopened.Vm.AdvancedMetrics = false;
Task off = reopened.Vm.Pending;
await off;
(await reopened.Settings.GetBooleanAsync(SettingsRegistry.TelemetryAdvanced, Ct)).Should().BeFalse();
}
[Fact]
public async Task HidingScrollBarsIsOffByDefaultAndItsToggleIsPersistedAndAppliedAtOnce()
{
@@ -156,6 +156,7 @@ public sealed class ViewerModeTests
[SettingsRegistry.CaptureRunElevated.Key] = ("IsChecked", "RunElevated, Mode=TwoWay"),
[SettingsRegistry.CaptureMinSessionSeconds.Key] = ("Value", "MinSessionSeconds, Mode=TwoWay"),
[SettingsRegistry.TelemetryIntervalMs.Key] = ("Value", "TelemetryIntervalMs, Mode=TwoWay"),
[SettingsRegistry.TelemetryAdvanced.Key] = ("IsChecked", "AdvancedMetrics, Mode=TwoWay"),
[SettingsRegistry.RetentionRawSessionsPerGame.Key] = ("Value", "RetentionRawSessions, Mode=TwoWay"),
[SettingsRegistry.RetentionRemoveUninstalledGames.Key] = ("IsChecked", "RemoveUninstalledGames, Mode=TwoWay"),
};
@@ -3,6 +3,7 @@
using System.Diagnostics;
using FluentAssertions;
using FrameLedger.Application.Advanced;
using FrameLedger.Application.AntiCheat;
using FrameLedger.Application.Capture;
using FrameLedger.Application.Consent;
@@ -303,7 +304,7 @@ public sealed class SessionRecorderTests : IAsyncDisposable
private async Task<Harness> MakeAsync(bool consented = true, AntiCheatVerdict? verdict = null, int records = 3_000, FakeLiveness? liveness = null, bool poller = true,
bool clockStepsOnDrain = false, IDriverProfileSource? profiles = null, bool excepted = false, IDisplayProbe? display = null, ulong adapterLuid = 0,
AntiCheatVerdict? rescan = null, ICrashReporterSightings? reporters = null)
AntiCheatVerdict? rescan = null, ICrashReporterSightings? reporters = null, IAdvancedHardware? advanced = null, bool advancedOn = false)
{
_db ??= await LedgerDatabase.OpenAsync(Path.Combine(_dir, LedgerPaths.DatabaseFileName), ct: TestContext.Current.CancellationToken).ConfigureAwait(false);
var store = new SqliteGameConsentStore(_db);
@@ -333,8 +334,8 @@ public sealed class SessionRecorderTests : IAsyncDisposable
games, new FakeSnapshots(), new FixedHardware(), partials,
new SessionFinalizer(sessions, new RawSeriesCodec()), new NoCrashEvents(),
_ => fakePoller, clock,
new RecorderOptions { PartialFlushInterval = TimeSpan.FromSeconds(10), MinimumSessionLength = SteppingClock.Step }, profiles: profiles,
exceptionLapse: new UserModeExceptionLapsePolicy(store, sessions), reporters: reporters);
new RecorderOptions { PartialFlushInterval = TimeSpan.FromSeconds(10), MinimumSessionLength = SteppingClock.Step, AdvancedMetrics = advancedOn }, profiles: profiles,
exceptionLapse: new UserModeExceptionLapsePolicy(store, sessions), reporters: reporters, advanced: advanced);
return new Harness { Recorder = recorder, Games = games, Sessions = sessions, Partials = partials, Clock = clock, Store = store, Poller = fakePoller };
}
@@ -737,4 +738,116 @@ public sealed class SessionRecorderTests : IAsyncDisposable
plain.DisplayWindowedMs.Should().BeNull("no reader, no display facts — N/A, never a zero");
SessionDisplayColumns.DisplayOf(plain).Should().BeNull();
}
/// <summary>The Agent's shared advanced reader (owner decision D101), scripted: what it last read, and what it answers about a session.</summary>
private sealed class FakeAdvanced : IAdvancedHardware
{
private int _acquired;
private int _released;
public int Acquired => Volatile.Read(ref _acquired);
public int Released => Volatile.Read(ref _released);
public AdvancedSnapshot? Latest { get; set; }
public List<AdvancedSessionTarget> Asked { get; } = [];
public bool Throws { get; init; }
public IDisposable Acquire()
{
Interlocked.Increment(ref _acquired);
return new Hold(this);
}
public IReadOnlyList<AdvancedFact> ReadSessionFacts(AdvancedSessionTarget target)
{
lock (Asked)
{
Asked.Add(target);
}
return Throws
? throw new InvalidOperationException("the driver did not answer")
: [new AdvancedFact("nvapi.session.vrr_enabled", Instance: null, AdvancedValue.Of(true))];
}
public static AdvancedSnapshot Snapshot() => new(
DateTimeOffset.UnixEpoch,
[],
[new AdvancedFact("nvapi.gpu.rt_cores", Instance: null, AdvancedValue.Of(84))],
[],
new AdvancedSources(AdvancedSourceStatus.Reading, NvapiCode: null, AdvancedSourceStatus.Reading, AdvancedSourceStatus.NotElevated));
private sealed class Hold(FakeAdvanced hub) : IDisposable
{
public void Dispose() => Interlocked.Increment(ref hub._released);
}
}
[Fact]
public async Task WithAdvancedMetricsOffTheSharedReaderIsNeverHeldAndTheSessionStoresNothingOfThem()
{
// D101: off means nothing more is read or stored - not held, not asked, no chunk, no row.
var hub = new FakeAdvanced { Latest = FakeAdvanced.Snapshot() };
Harness h = await MakeAsync(advanced: hub, advancedOn: false);
RecordedSession r = await h.Recorder.RecordAsync(Request(), TestContext.Current.CancellationToken);
hub.Acquired.Should().Be(0);
hub.Asked.Should().BeEmpty();
h.Sessions.Stored.Single().Advanced.Should().BeNull();
h.Partials.Created[r.Row.SessionGuid].AdvancedContexts.Should().BeEmpty();
}
[Fact]
public async Task WithAdvancedMetricsOnTheSessionHoldsTheReaderAsksItsFactsOnceAndStoresItsRow()
{
var hub = new FakeAdvanced { Latest = FakeAdvanced.Snapshot() };
Harness h = await MakeAsync(advanced: hub, advancedOn: true);
RecordedSession r = await h.Recorder.RecordAsync(Request(), TestContext.Current.CancellationToken);
hub.Acquired.Should().Be(1);
hub.Released.Should().Be(1, "the session lets go when it is over, and the shared reader closes some seconds after the last holder");
AdvancedSessionTarget asked = hub.Asked.Should().ContainSingle("a session's facts are read once").Subject;
asked.ExecutablePath.Should().Be(_exe);
asked.ProcessId.Should().Be(_pid);
AdvancedSessionRow row = h.Sessions.Stored.Single().Advanced.Should().BeOfType<AdvancedSessionRow>().Subject;
row.MachineFactsJson.Should().Contain("nvapi.gpu.rt_cores");
(IReadOnlyList<AdvancedFact> facts, AdvancedSources sources) = AdvancedJson.ParseSession(row.FactsJson);
facts.Should().ContainSingle().Which.Id.Should().Be("nvapi.session.vrr_enabled");
sources.ElevatedSensors.Should().Be(AdvancedSourceStatus.NotElevated);
h.Partials.Created[r.Row.SessionGuid].AdvancedContexts.Should().NotBeEmpty("the crash file carries the context, so a recovered session keeps it");
r.Row.Tier.Should().Be(CaptureTier.Hooked, "and the session itself is what it always was");
}
[Fact]
public async Task ASessionWithTheOptionOnWhoseReaderNeverAnsweredStillStoresARowThatSaysSo()
{
// Nothing was read: no snapshot, and the facts read threw. The row is there with every source unknown, which the
// page shows as N/A with its reason - where no row at all would read as "the option was off".
var hub = new FakeAdvanced { Latest = null, Throws = true };
Harness h = await MakeAsync(advanced: hub, advancedOn: true);
await h.Recorder.RecordAsync(Request(), TestContext.Current.CancellationToken);
AdvancedSessionRow row = h.Sessions.Stored.Single().Advanced.Should().BeOfType<AdvancedSessionRow>().Subject;
row.MachineFactsJson.Should().BeNull();
(IReadOnlyList<AdvancedFact> facts, AdvancedSources sources) = AdvancedJson.ParseSession(row.FactsJson);
facts.Should().BeEmpty("a read that threw costs the session its facts, not itself");
sources.Should().Be(AdvancedSources.Unknown);
hub.Released.Should().Be(1);
}
[Fact]
public async Task ARecorderWithNoSharedReaderRecordsAsBeforeWhateverTheOptionSays()
{
Harness h = await MakeAsync(advanced: null, advancedOn: true);
await h.Recorder.RecordAsync(Request(), TestContext.Current.CancellationToken);
h.Sessions.Stored.Single().Advanced.Should().BeNull("the unshipped host and the tests have no reader to hold");
}
}
@@ -77,6 +77,7 @@ public sealed class RegisteredSettingsTests
defaults.RetentionKeep.Should().Be(20);
defaults.TelemetryInterval.Should().Be(TimeSpan.FromSeconds(1));
defaults.PartialFlushInterval.Should().Be(baseline.PartialFlushInterval, "not a setting");
defaults.AdvancedMetrics.Should().BeFalse("D101: off by default, and off means nothing more is read or stored");
store.Rows["capture.min_session_s"] = "45";
store.Rows["retention.raw_sessions_per_game"] = "0";
@@ -85,6 +86,13 @@ public sealed class RegisteredSettingsTests
set.MinimumSessionLength.Should().Be(TimeSpan.FromSeconds(45));
set.RetentionKeep.Should().Be(int.MaxValue, "0 is unlimited: a sweep that keeps everything, never one that keeps nothing");
set.TelemetryInterval.Should().Be(TimeSpan.FromMilliseconds(500));
set.AdvancedMetrics.Should().BeFalse();
// telemetry.advanced (D101): exactly "1" is on, read like the others at each session's start.
store.Rows["telemetry.advanced"] = "1";
(await policy.ResolveAsync(baseline, Ct)).AdvancedMetrics.Should().BeTrue();
store.Rows["telemetry.advanced"] = "yes";
(await policy.ResolveAsync(baseline, Ct)).AdvancedMetrics.Should().BeFalse("a row that is not 0 or 1 reads as the default, never as on");
// An operator's bounded capture (--seconds 8 lowers the minimum to 8 s) keeps its bound under any setting.
RecorderOptions bounded = await policy.ResolveAsync(baseline with { MinimumSessionLength = TimeSpan.FromSeconds(8) }, Ct);
@@ -79,8 +79,9 @@ public sealed class SettingsRegistryTests
// capture.run_elevated joined on 2026-09-27 (D34): the admin mode, read before the Agent exists.
// capture.background left in beta.12: it was listed here and no Agent code ever read it; the key is reserved.
// retention.remove_uninstalled_games joined in beta.19 (D55): the detection sweep reads it at every pass.
// telemetry.advanced joined on 2026-11-11 (D101): Advanced metrics, off by default, read at each session's start.
agent.Should().BeEquivalentTo(["hooking.kill_switch", "hooking.usermode_ac_exceptions", "capture.run_elevated",
"capture.min_session_s", "telemetry.interval_ms", "retention.raw_sessions_per_game", "retention.remove_uninstalled_games"]);
"capture.min_session_s", "telemetry.interval_ms", "telemetry.advanced", "retention.raw_sessions_per_game", "retention.remove_uninstalled_games"]);
agent.Should().OnlyContain(static k => k.StartsWith("hooking.", StringComparison.Ordinal) || k.StartsWith("capture.", StringComparison.Ordinal)
|| k.StartsWith("telemetry.", StringComparison.Ordinal) || k.StartsWith("retention.", StringComparison.Ordinal));
}