Coach: ein API-Key gilt fuer die ganze Instanz, Warm-ups zaehlen nicht, Retries bei 429/5xx, sichtbare Admin-Felder
- Instanz-Modus: nur eine persoenliche Anmeldung (Setup-Token/OAuth) bindet sich an das erste Profil, ein API-Key ist gemessen und wird von allen Profilen unter den Tageslimits geteilt. Die Bindung passiert jetzt wirklich beim Einreihen eines Jobs (jobs.enqueue), vorher gab es sie nur in den Tests. - HTTP-Adapter: 429/500/502/503/504/529 werden zweimal mit kurzer Pause wiederholt, ein 4xx nie. retryDelayMs fuer Tests. - Payload: Warm-up-Saetze wie in progression.js aus readSession/stalls, done/planned, Top-Satz, setsByBodyPart und workingWeights herausgefiltert; in vollen Sessions als warmup:true markiert, common.md sagt dem Modell, was das ist. - Admin-Karte: .field im Card hat jetzt eine sichtbare Flaeche, die Limit-Zahlenfelder sind echte Felder statt weisser Browser-Boxen; Text zu 'Whose account pays' unterscheidet API-Key und persoenliche Anmeldung. - Neuer Test e2e-apikey: Key ueber die Admin-Routen einlegen, Modelle listen, Review durch die echte Queue gegen einen lokalen Anthropic/OpenAI/Gemini-Stand-in, inkl. Header, Cache-Block, Schema, Retry und Auth-Fehler. api 150, frontend 1029, mcp 45 gruen.
This commit is contained in:
1 parent
63cf1deaed
commit
02c75b320d
14 files changed
+311
-35
No files matched your search
+12
-7
@@ -136,11 +136,10 @@ unprivileged, and which account is being spent.
|
||||
|
||||
**4. Use it** — as above.
|
||||
|
||||
> **On a multi-profile instance, read [Whose account pays](#whose-account-pays) first.** In the
|
||||
> default instance mode the credential binds to the first profile that spends it and **every
|
||||
> other profile is refused**, by design. That is the right behaviour when one person's personal
|
||||
> subscription is behind it — but on a shared box it means one user gets the Coach and the rest
|
||||
> get a refusal until per-profile sign-in exists.
|
||||
> **On a multi-profile instance, read [Whose account pays](#whose-account-pays) first.** An API
|
||||
> key is shared by every profile under the daily limits. A *personal* credential — a Claude Code
|
||||
> setup token — binds to the first profile that spends it and **every other profile is refused**,
|
||||
> by design: that is the right behaviour when one person's personal subscription is behind it.
|
||||
|
||||
### A debrief of one workout
|
||||
|
||||
@@ -177,8 +176,14 @@ to be. The Coach spends a real provider account, and there are two shapes:
|
||||
| **instance** | one account, stored encrypted in `coach.json` | the single-profile instance most people run |
|
||||
| **profile** | one account per profile, in its own `coach-auth-<uid>.json` | anything with more than one profile |
|
||||
|
||||
In instance mode the credential **binds to the first profile that spends it**. Any other profile
|
||||
is refused:
|
||||
In instance mode it depends on what kind of credential was pasted:
|
||||
|
||||
- **An API key** (Anthropic, OpenAI, Gemini, an OpenAI-compatible endpoint) is shared by every
|
||||
profile on the instance. It is metered, issued for exactly this kind of use, and the daily
|
||||
limits in the admin card are what bound what it can spend. This is the shape a household or a
|
||||
small gym wants.
|
||||
- **A personal credential** — a Claude Code setup token or an OAuth login — **binds to the first
|
||||
profile that spends it**. Any other profile is refused:
|
||||
|
||||
> This instance is configured with a single shared account — ask your admin to enable
|
||||
> per-profile sign-in.
|
||||
|
||||
Reference in new issue
Block a user