Skip to content

tenon v0.8.0

Choose a tag to compare

@tenon-code-eu tenon-code-eu released this 26 Oct 22:12
· 73 commits to main since this release

tenon v0.8.0

The sobriety and memory release. tenon now measures the tokens it really spends and sends less of them. It also remembers your project between sessions, under the same rules as everything else: approval, audit, classification and the right to erasure.

Site and documentation (EN/FR): https://tenon-code-eu.github.io/tenon/

New

Token sobriety

  • Real usage: every model call records its input, output and cached tokens, read from the provider's stream. When the provider reports none, tenon estimates and marks the figure as estimated. Set stream_usage = false on a provider that rejects the option.
  • A lighter context, with the full history kept for audit, --resume, /rewind and routing:
    • identical tool results are sent once;
    • above 50 % of the window, the oldest tool results are replaced by a short stub until the context is under 40 %;
    • the masked set is kept from one request to the next, so the provider's prompt cache stays valid;
    • results of the agent tool are never masked;
    • long outputs keep their head and their tail.
  • Compaction is decided on what is actually sent.
  • Session budget: [budget] session_tokens warns at warn_at (80 % by default), then refuses the next turn with budget_exceeded (exit code 4 under --strict). A project can only lower it; a policy can impose it.
  • Small models: [routing] compaction and [routing] subagents send compaction and sub-agents to another provider, under the same checks as the session. A sensitive session always stays on routing.local.
  • Totals:
    • TUI status line: in 12.4k · out 1.1k · session 340k;
    • headless, on stderr: tokens: in … · out … · cached … · session …;
    • a Tokens section in the compliance export;
    • energy and CO₂e in the export, only with the factors you declare ([usage] wh_per_mtoken, gco2_per_kwh).

Governed memory

  • Three scopes:
    • project: .tenon/memory/, versioned with the code;
    • user: personal, for this project;
    • global: personal, for every project.
  • Progressive loading: only a short index enters the system prompt, and the model reads an entry with memory_read when it needs it.
  • Writing:
    • the model proposes with memory_write, which needs your approval and shows a diff;
    • you write with /remember;
    • rules can allow a scope, matched as <scope>/<id>, for example user/*.
  • Trust: a project entry that comes from someone else (clone, pull) is never loaded until you accept it with tenon memory trust.
  • Sensitivity:
    • secrets and personal data are redacted before anything is written;
    • an entry with a classification marker is stored in the personal scope, never in git;
    • such an entry is left out of the index;
    • reading it makes the session sensitive, and it is refused without a local model.
  • Retention: personal entries expire after 90 days without use ([memory] retention_days). Project entries do not expire.
  • Audit and erasure:
    • every write, read of a sensitive entry, trust and deletion is recorded, without title or content;
    • tenon memory list|show|forget|trust lets you list and erase entries;
    • the export has a Memory section.
  • Configuration and policy: [memory] enabled, project and retention_days. A project can only tighten, and a policy can switch memory off or cap retention. Erasure always stays possible.

Changes

  • New configuration keys: [budget], [usage], [memory], routing.compaction, routing.subagents, stream_usage.
  • New audit events:
    • Usage, ContextShaped, BudgetWarning;
    • MemoryWritten, MemoryRead, MemoryForgotten, MemoryTrusted.
  • A local provider used as a routing fallback never goes through the environment proxy.
  • The CI templates pin v0.8.0.

Known limits

  • Memory:
    • tenon memory forget removes the entry, not the past conversations that mention it, nor git history for project entries;
    • the memory lock between processes is Unix-only, like the rest of tenon.
  • Tokens:
    • the "tokens saved" figure is an estimate;
    • masking never lowers a session's sensitivity.
  • Linux and macOS only.

Verify

minisign -Vm SHA256SUMS -p tenon.pub
sha256sum -c SHA256SUMS --ignore-missing   # macOS: shasum -a 256 -c SHA256SUMS --ignore-missing