返回资讯中心
外部精选
软件工程
#开发者实时流

Show HN: Tenbri, a log AI agents can’t secretly rewrite

An Agent Decision Record is a signed, append-only record of every decision an AI agent makes: who acted, under which rule and inputs, who approved, and what happened, verifiable offline by anyone. Tenbri is the open-sou…

Hacker News 最新akaabachi2026/10/20 · 26 天前24 分钟阅读

以下正文同步自 Hacker News 最新,版权归原站所有,已转换为易读排版。

An Agent Decision Record is a signed, append-only record of every decision an AI agent makes: who acted, under which rule and inputs, who approved, and what happened, verifiable offline by anyone. Tenbri is the open-source one. One line for Claude, OpenAI and LangGraph agents; plain files on storage you control.

Get startedExamplesAdaptersGitHub

agent.pyagent.tsrefund.pyrefund.ts

Copy

import tenbri

tenbri.init() # TENBRI_STREAM, TENBRI_AGENT, TENBRI_APPROVER tenbri.instrument_claude_agent_sdk() # every tool call becomes a signed decision

or: tenbri.instrument_openai_agents()

or: tenbri.instrument_langchain()

import { init } from 'tenbri' import { instrumentLangChain } from '@tenbri/langgraph'

init() // TENBRI_STREAM, TENBRI_AGENT, TENBRI_APPROVER instrumentLangChain() // every tool call becomes a signed decision

// or: instrumentClaudeAgentSdk(options) from '@tenbri/claude-agent-sdk' // or: instrumentOpenAIAgents() from '@tenbri/openai-agents'

None: if amount > 500: raise tenbri.Refused("over the ceiling") # recorded as refused stripe.Refund.create(charge=charge, amount=amount)

refund("ch_81f2", 4200) # intent before it runs, outcome after" data-astro-cid-p4mur4zr>import tenbri

tenbri.init()

@tenbri.decision("issue_refund", target="stripe:{charge}", policy="policy:refund@14") def refund(charge: str, amount: int) -> None: if amount > 500: raise tenbri.Refused("over the ceiling") # recorded as refused stripe.Refund.create(charge=charge, amount=amount)

refund("ch_81f2", 4200) # intent before it runs, outcome after

{ if (amount > 500) throw new Refused('over the ceiling') // recorded as refused await stripe.refunds.create({ charge, amount }) }, )

await refund({ charge: 'ch_81f2', amount: 4200 }) // intent before, outcome after" data-astro-cid-p4mur4zr>import { Refused, decision, init } from 'tenbri'

init()

const refund = decision( { action: 'issue_refund', target: 'stripe:{charge}', policy: 'policy:refund@14' }, async ({ charge, amount }: { charge: string; amount: number }) => { if (amount > 500) throw new Refused('over the ceiling') // recorded as refused await stripe.refunds.create({ charge, amount }) }, )

await refund({ charge: 'ch_81f2', amount: 4200 }) // intent before, outcome after

Claude Agent SDKOpenAI Agents SDKLangGraphLangChainAny Python functionAny TypeScript function

Tenbri UI

tenbrid serves a read-only UI over your streams: dashboards, every decision with its outcome, traces as timelines, and a verification check. Open it with a bearer token; it cannot write.

Overview, then the errors, one decision's timeline and signed chain, its whole trace, and the integrity check.

A refund function decorated with @tenbri.decision, called three times. Then someone edits one byte on disk. Real output from a run, with hashes and paths shortened.

Replay

create a stream; the CLI records its fingerprint on this machine

$export TENBRI_STREAM=audit/support TENBRI_AGENT=agent:support

$tenbri init

created stream tnb1:986d8e32f69cb7b19e170a65792a3588 at audit/support

stream key fingerprint (pin it): sha256:986d8e32…cd52f52

pinned in ~/demo/keys/pins: tenbri verify audit/support uses it

refund.py decorates a refund function with @tenbri.decision and calls it three times

$python refund.py

ok: re_123

refused: over the 500 EUR ceiling

error: nothing to refund

each call wrote an intent before it ran, then its outcome

$tenbri tail -n 6 --no-follow

3 2026-10-20T16:49:42.442Z decision intent agent:support issue_refund stripe:ch_3PqX - verified

4 2026-10-20T16:49:42.464Z decision outcome agent:support issue_refund stripe:ch_3PqX ok verified

5 2026-10-20T16:49:42.485Z decision intent agent:support issue_refund stripe:ch_9ZzY - verified

6 2026-10-20T16:49:42.504Z decision outcome agent:support issue_refund stripe:ch_9ZzY refused verified

7 2026-10-20T16:49:42.525Z decision intent agent:support issue_refund stripe:ch_0 - verified

8 2026-10-20T16:49:42.546Z decision outcome agent:support issue_refund stripe:ch_0 error verified

$tenbri show 4

seq 4 decision outcome 01M5D3G0HWD934QDJNSR0230F8

action issue_refund stripe:ch_3PqX

intent 01M5D3G0H716Y40JZR8KTCSXXY

principal agent:support

status ok

verification verified, pinned to sha256:986d8e32… (recorded in ~/demo/keys/pins)

checks every hash, signature and key against the recorded pin

$tenbri verify

verified 8 entries, stream tnb1:986d8e32…3588, pinned to sha256:986d8e32… (the pin recorded in ~/demo/keys/pins)

someone edits one refund on disk

$sed -i '' s/ch_9ZzY/ch_9ZzZ/ audit/support/batches/000000000005.jsonl

the first changed entry fails verification

$tenbri verify

broken at seq 5: bad_signature: the signature does not verify

4 entries verified before it, stream tnb1:986d8e32…3588 (the pin recorded in ~/demo/keys/pins)

OpenAIHugging Face

From the blog · Incident analysis

In July 2026, OpenAI agents broke out of an evaluation sandbox and attacked Hugging Face. Attribution took five days. What a signed record of every agent decision would have changed, and what it would not.

Disputes, incidents, policy changes and audits all ask the same question: what did the agent decide, and on whose authority?

Copy

$ tenbri verify verified 8 entries, stream tnb1:986d8e32…3588, pinned to sha256:986d8e32… (the pin recorded in ~/demo/keys/pins)

$ tenbri verify # after someone edits one batch on disk broken at seq 5: bad_signature: the signature does not verify 4 entries verified before it, stream tnb1:986d8e32…3588

$ tenbri verify audit/support --key sha256:986d8e32… # an auditor on another machine pins it

VerifyAnyone can check it, offline

Hand an auditor the stream and one fingerprint. Verification checks canonical bytes, the hash chain, every Ed25519 signature and every key, with no access to your systems. A checkpoint they kept catches truncation and forks.

Copy

$ tenbri query --rule policy:refund@14 3 2026-10-20T16:49:42.442Z decision intent agent:support issue_refund stripe:ch_3PqX - verified 5 2026-10-20T16:49:42.485Z decision intent agent:support issue_refund stripe:ch_9ZzY - verified 7 2026-10-20T16:49:42.525Z decision intent agent:support issue_refund stripe:ch_0 - verified

$ tenbri query --rule policy:refund@14 --json | jq .entry.action # JSON when piped

QueryEvery decision made under the old rule

Inputs are pinned by reference, version and keyed digest. When a policy changes, list what was decided under the previous version and review it. Each answer is re-checked against storage before it is returned.

Copy

unknown_actions = "reject"

[actions.issue_refund] target = "stripe:{charge}" # filled from the tool call's arguments policy = "policy:refund@14" # the rule that allowed it approval = true # a person must approve first inputs = ["policy:refund"]

[actions.issue_refund.fields."ext.refund.amount"] required = true type = "integer"

SchemasSay what each action must record

Declare actions once in tenbri.toml. The SDKs read it to map tool calls to actions, targets and policies, tenbrid enforces it at write time, and CI checks whole streams against it.

Copy

$ tenbri receipt create ./audit/support --entry 3 --out refund-3.receipt $ tenbri receipt verify refund-3.receipt --key sha256:9c1e… proves seq 3 (decision intent), id 01M4XBH0Y6…, ts 2026-10-14T14:02:13Z (claimed by the writer) in stream tnb1:1702…b7d8, checkpoint at size 8, pinned to sha256:9c1e…; key history: 2 key entries

ReceiptsProof you can hand over

A receipt proves specific entries with their inclusion proofs, the key history and an optional RFC 3161 timestamp. A customer, a regulator or the police verify it alone, without seeing the rest of the stream.

Copy

$ tenbri erase ./audit/support --subject subj_7f3c91d2 --reason dsr:2026-1042 --yes erased subject subj_7f3c91d2: 2 data key epochs deleted; erasure recorded at seq 7

$ tenbri verify ./audit/support --key sha256:9c1e… verified 8 entries, stream tnb1:1702…b7d8, pinned to sha256:9c1e…

PrivacyErase a person without breaking the chain

Only hashes go in the chain. Bodies are encrypted and input digests are keyed per subject, so deleting a subject's keys makes their data unreadable while every chain, checkpoint and receipt still verifies.

Copy

$ export TENBRI_STREAM=r2://audit/agents/support CLOUDFLARE_ACCOUNT_ID=…

$ curl -X POST https://tenbrid.internal:7070/v1/streams/support/intents
-H "Authorization: Bearer $TOKEN" -H "Idempotency-Key: $(ulid)"
-d '{"action":{"type":"issue_refund","target":"stripe:ch_81f2"}}' {"entry":{"kind":"decision","phase":"intent","seq":3,…},"replayed":false}

AnywhereYour storage, any language

A stream is plain files in a directory, S3, R2 or MinIO, with the keys kept apart. Write from Python, TypeScript or Rust, or run tenbrid and use REST or gRPC from anything else.

Observability tools such as Langfuse and MLflow answer how an agent ran. A decision record proves what it decided and on whose authority. Keep both: Tenbri links each decision to its OpenTelemetry trace.

One Rust core behind every SDK, the CLI and tenbrid. Turn on the optional parts when you need them; the rest is on the roadmap.

One Rust core behind every SDK, the CLI and tenbrid. Entries are signed and chained before they reach storage; signing keys never live with the stream.

Status as of 0.1.0-beta.5. Source: the Tenbri roadmap.

Tenbri gives you the records. It does not make a system compliant on its own.

Open source, Apache-2.0, written in Rust. Plain files on storage you control, and no telemetry.

正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。

打开原文
去社区讨论 →