from cadenza_cli import MeganTK — lets any project drive the hosted megan-tk governance directly. No
server to run, no model to download, no Supabase credentials.
megan-tk is Cadenza’s symbolic governance token. It watches a task unfold and
returns one thing: a decision — keep going or adapt here. It is the
torch-free “should I act, and where?” brain that sits above your policy; your own
change-doer acts on its verdict.
What it gives you
Token sessions
Give the token an objective and an ordered chain of milestones. Report what
you’ve reached (or what’s blocking), and it tells you whether to continue
or adapt, and at which milestone.
Disturbance anticipators
Feed it the times a periodic disturbance hits. It learns the rhythm and, at
any moment, tells you whether to protect now and which registered action
is best.
Metered usage
Every call is counted server-side against your account. Read it back with
cadenza usage or tk.usage() — per-route counts plus a session/anticipator
rollup.Zero-dependency SDK
The client is standard-library only — no torch, no extras. Drop it into a
lightweight project and call the API.
Two ways to reach it
| Path | Use it when |
|---|---|
SDK — from cadenza_cli import MeganTK | You’re building an application or control loop and want to call megan-tk from code. |
CLI — cadenza apikey, cadenza usage | You want your API key to paste elsewhere, or to inspect what you’ve consumed. |
The locked contract
megan-tk deliberately returns only the actionable decision — never the internals it used to reach it. This is a feature, not a limitation: you integrate against a stable, minimal decision surface, and the valuable mechanism can’t leak out of a response.When to use Megan
- You have a policy (scripted, learned, or a VLA) and want a governor that decides when it should deviate from plan and where.
- You need anticipatory safety against a recurring disturbance without hand- tuning timing.
- You want to consume Cadenza’s reasoning from an external project rather than
inside the
envmission workflow.
Next
Setup
Install the SDK, get your key, make your first call.
Build deep
Wire the token into a real control loop with the change-doer pattern.