five-on-it / apps/api/src/settings
apps/api/src/settings
The platform's settings, set by an admin at runtime (GET/PUT/DELETE /admin/settings, admin.ts): the spending limits and the creation's caps, over the configuration's defaults. The environment (FOI_CREATOR_MONTHLY_USD, FOI_QUOTA_*, FOI_CREATOR_JOB_USD, FOI_CREATOR_BUILDS, FOI_CREATOR_CHOICES) gives the defaults; a setting an admin gave replaces its default until it is reset (one key, or all of them), kept in the store (PlatformSettings: memory, a file, Postgres's platform_settings), so it outlives a restart. Every change goes to the admins' audit log (action: 'settings').
| Key | Default | What |
|---|---|---|
monthlyUsd | FOI_CREATOR_MONTHLY_USD (25) | The model's hard cap a month (USD), 0 to 10,000; each day's budget is what is left of it over the days left. |
quotaBuilds, quotaRooms, quotaCreations | FOI_QUOTA_BUILDS (100), FOI_QUOTA_ROOMS (50), FOI_QUOTA_CREATIONS (5) | Every account's builds, rooms and creations a day, but for an account's override (0 blocks). |
creationUsd, creationBuilds | FOI_CREATOR_JOB_USD (0.5), FOI_CREATOR_BUILDS (12) | What one creation may spend (USD, over 0, 100 at most) and the builds it may run (1 to 100), but for an account's override. |
turnMinutes | 20 | The minutes one turn of a creation may run (1 to 120). |
turnCalls, turnInputTokens, turnOutputTokens, turnMaxTokens | 30, 600,000, 40,000, 8,000 (TURN_LIMITS) | A turn's caps on the model, sent to the runner with its claim: its calls, its tokens read and answered, the most one call answers with. |
concurrency | none | How many creations run at once on the whole platform, at most (1 to 100): the runners' slots (FOI_CREATOR_CONCURRENCY each) beyond it wait. It never runs more than the runners have slots. |
modelChoices | FOI_CREATOR_CHOICES (with claude: Opus, Sonnet, Haiku 5.5) | The models an owner may pick (1 to 12 ids, in order); with claude, each one Anthropic's list prices. |
defaultModel | the first choice | The choice picked by default (one of modelChoices). |