The four levels
Settings are defined in.factory/ folders with a consistent structure at four levels:
.factory/ folder can contain:
settings.json– general settings (models, safety, preferences, telemetry).mcp.json– MCP server configurations.droids/– droid definitions.commands/– custom commands.hooks/– hook definitions.skills/– skill definitions.
Settings JSON schema
Below is the full schema for org-managed settings. These are configured by org admins through the Enterprise Controls page in the Factory app. Every property is optional — omit any field you do not need to set.Session default preferences.
Maximum autonomy level any user or project can set. One of
off, low, medium, high.Whether sessions are synced to the cloud.
Include a
Co-authored-by: Droid trailer in git commits.Enable Droid Shield safety checks.
Automatically connect to the IDE on session start.
Shell command patterns that are always allowed (accumulated across levels).
Shell command patterns that are always denied (accumulated across levels).
Org-provisioned custom model definitions.
Org-level model access control.
Per-user model overrides. Map of user ID to policy object.
Map of plugin name in
plugin@marketplace format to true (enabled) or false (disabled). Plugins set to true are automatically installed on CLI startup once their marketplace is available.Additional plugin marketplaces. Map of marketplace name to a source object. Marketplaces listed here are automatically cloned and registered on CLI startup.
Marketplace sources that are strictly enforced. Each entry is a source object directly (e.g.
{ "source": "github", "repo": "owner/repo" }), not wrapped in a source key like extraKnownMarketplaces values.Supported model IDs
The following model identifiers can be used inallowedModelIds and blockedModelIds:
| Provider | Model IDs |
|---|---|
| Anthropic | claude-sonnet-4-5-20250929, claude-sonnet-4-6, claude-opus-4-5-20251101, claude-opus-4-6, claude-opus-4-6-fast, claude-haiku-4-5-20251001 |
| OpenAI | gpt-5.1, gpt-5.1-codex, gpt-5.1-codex-max, gpt-5.2, gpt-5.2-codex, gpt-5.3-codex |
gemini-3-pro-preview, gemini-3-flash-preview, gemini-3.1-pro-preview | |
| XAI | grok-code-fast-1 |
| Open source | glm-4.7, glm-5, kimi-k2.5, minimax-m2.5 |
Extension‑only semantics
Factory uses extension‑only semantics instead of traditional “override” behavior.- Higher levels (org, project) cannot be overridden by lower levels.
- Lower levels (folder, user) can only add to what higher levels define when those fields are unset.
- This ensures org policies remain intact even as projects and users customize their experience.
1. Simple values – first wins
For simple scalar values (strings, numbers, booleans):- The first level that sets a value “wins.”
- Lower levels cannot change or remove that value.
sessionDefaultSettings.modelsessionDefaultSettings.autonomyModemaxAutonomyLevel
2. Arrays – union, cannot remove
Array fields accumulate across levels:- Org entries are always present and cannot be removed.
- Project and folder levels can add more entries.
- User level can add more entries but cannot remove or weaken higher‑level entries.
- Command allow lists and deny lists.
- Lists of enabled hooks or features.
3. Objects – keys are locked per level
For object fields:- Keys defined at a higher level are locked; their contents cannot be changed by lower levels.
- Lower levels can add new keys but not modify or delete existing ones.
customModels– org definesclaude-enterprise; projects can addpayments-gpt, users can addpersonal-experimental, but none can change or removeclaude-enterprise.- MCP server definitions – org defines which servers exist and how they connect; projects decide which to use.
Org configuration
Large organizations typically manage an org‑level.factory bundle or config endpoint that:
- Specifies allowed models, gateways, and BYOK policies.
- Defines global command allow/deny lists.
- Sets defaults for autonomy, reasoning effort, and safety features like Droid Shield.
- Configures OTEL defaults (endpoints, sampling, and attributes).
- Publishes org‑standard droids, commands, and hooks.
Project and folder configuration
Projects and folders use.factory/ directories checked into version control to specialize org policy for particular codebases and teams.
Common responsibilities include:
- Adding project‑specific models and gateways within the allowed set.
- Defining project‑specific droids (for example,
/migrate-service,/refactor-module). - Configuring hooks that know about the project’s tests, linters, and deployment processes.
- Tightening safety controls for high‑risk repositories.
.factory/ directories are useful in monorepos where different subsystems have different policies.
User configuration
Developers can configure~/.factory/ for personal preferences only where higher levels are silent.
Examples:
- Choosing a preferred model from the allowed set.
- Setting default behavior for display options and minor UX preferences.
- Enabling additional hooks or tools that do not conflict with org policy.
- Re‑enable models or tools that org or project settings have disallowed.
- Loosen command allow/deny lists.
- Reduce autonomy or safety requirements set by org or project.
Example: enforcing a model policy
Suppose your org wants to:- Allow only approved enterprise models.
- Disallow user‑supplied API keys.
- Force all prompts through a particular LLM gateway.
- Define the allowed models and gateway endpoints in the org
.factory/settings.json. - Set a policy flag to disable user BYOK entirely.
- Configure hooks to verify that any model selection or endpoint use matches the org‑approved set.
Example: environment‑specific autonomy
Consider an org that wants to:- Allow high autonomy in CI and sandboxed containers.
- Limit autonomy on developer laptops.
- At org level, set
maxAutonomyLeveltohigh. - In project settings, define environment‑aware hooks that:
- Inspect environment tags (for example,
environment.type=local|ci|sandbox). - Downgrade or block autonomy levels above
mediumwhen running on laptops.
- Inspect environment tags (for example,
- Optionally, define stricter folder‑level policies for particularly sensitive repos.
Example: full org-managed settings
Putting it all together
The hierarchical settings system underpins everything described in the other enterprise pages:- Identity & Access Management – who can change which level of settings.
- Privacy, Data Flows & Governance – where data and telemetry are allowed to go.
- Network & Deployment Configuration – which environments Droid can run in and how it connects.
- LLM Safety & Agent Controls – policies for commands, tools, and Droid Shield.
- Models, LLM Gateways & Integrations – control over models, gateways, MCP servers, droids, and commands.
- Compliance, Audit & Monitoring – guarantees and telemetry used to prove compliance.
