export * as ConfigFlag from "./flag.js" /** The `OPENCODE_FLAGS` entry that enables all flags except opt-in-only flags, as in `all,-media_blob`. */ export const wildcard = "all" /** * Flags default to on in local and dev builds and off in releases, except for `optInOnly` flags, which must be * named explicitly in `experimental.` or `OPENCODE_FLAGS`. Read a flag with Core's `Flag.enabled("")`. */ export const registry = { todo: "Enable the experimental todowrite tool. Off by default in every build, including local and dev; opt in with OPENCODE_FLAGS=todo or experimental.todo: true.", media_blob: "Store new session media once in a deduplicated blob table instead of inline in every message row.", artifacts: "Enable experimental artifacts backed by pluggable providers.", console_watches: "Watch Slack threads, GitHub pull requests, issues, commits and Actions runs, and the workspace's MCP servers' events through OpenCode Console, and wake sessions when they change.", model_speeds: "Offer a model's faster and slower service tiers (fast, flex…) as speeds of that model: one entry in the model picker with a speed selector, instead of a separate entry per tier such as gpt-5.5-fast.", full_codemode: "Enable the full Code Mode work in progress.", codemode_agents: "Let Code Mode scripts start subagents with agent() and make single model calls with llm(), each optionally returning a value checked against a schema, so one script can fan work out, verify it and combine the results.", machines: "Let a tool path name a machine, as in gpu:/work/train.py, and act on that machine's files and processes.", home_memory: "Give sessions a shared global memory/, docs/ and scripts/ workspace the agent can use freely, tidied by a daily maintenance session that reads recent conversations across projects.", project_overlay: "Load a personal config dir for each project from ~/.config/opencode/project//, read like an extra .opencode dir that ranks above the repo's own.", opencode_api: 'Let Code Mode scripts call the OpenCode HTTP API with fetch("opencode:///api/..."), in-process and already signed in, with calls checked as the equivalent opencode api shell command. On by default in local and dev builds and unavailable in releases.', mcp_resilience: "Keep MCP tools available through dropped connections and reconnect on demand, using saved tool listings during startup.", mcp_skills: "Load skills from MCP servers that offer them (the io.modelcontextprotocol/skills extension), named :. A server that offers skills no longer has its instructions included.", compaction_jobs: "List a session's subagents, with their session IDs, and its running background jobs in its compaction checkpoints, so the agent can still continue or account for them after compacting.", sqlite_fts: "Build an SQLite full-text index of session titles and message text in the background, and enable the opencode.session.search and opencode.session.read tools. The index covers every session in the database and starts while any loaded location enables it; SQLite keeps it current from then on, also after this is turned off.", google_ai_plan: "Offer Sign in with Google (AI Ultra), which runs Gemini models on the user's Google AI plan instead of an API key.", browser_stream_tunnel: "Stream remote desktop browser TCP traffic over one prewarmed, ticket-authenticated binary WebSocket per live browser attachment instead of per-chunk RPC.", } as const satisfies Record export type Key = keyof typeof registry /** Flags the server reports to clients at `GET /api/experimental/flag`, so they can adapt their UI. */ export const ui: readonly Key[] = ["full_codemode"] export const optInOnly: ReadonlySet = new Set(["todo"]) /** Flags that stay off outside local and dev builds, whatever `OPENCODE_FLAGS` or config say. */ export const localOnly: ReadonlySet = new Set(["opencode_api", "google_ai_plan"])