Support organization-scoped agents with isolated memory, skills, and project context

Open 💬 2 comments Opened May 17, 2026 by chac4l
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

Summary

Codex currently feels centered around one primary agent experience. As users connect more repositories, SSH hosts, teams, and long-running projects, a single agent can accumulate too much unrelated context over time.

It would be helpful to support multiple scoped agents, organized under higher-level organizations or companies, with separate memory, files, skills, and project context.

Problem

A single long-lived agent can become overloaded when it is used across many unrelated areas of work. Context from one project, company, server, or workflow may become irrelevant or even harmful when working on another.

For example, a user may have:

  1. Multiple organizations, companies, or clients.
  2. Several projects per organization.
  3. Different coding standards, deployment workflows, credentials, and operational assumptions.
  4. Specialized agents for backend, frontend, infrastructure, QA, data, or support.
  5. Shared organization-level knowledge that should not leak into unrelated organizations.

Without stronger separation, the agent has to remember too much and the user has to keep correcting scope manually.

Feature request

Add first-class support for a hierarchy such as:

Organization / Company
  -> Agent
      -> Projects / repositories / SSH hosts / memories / skills

Each organization could have shared context, while each agent inside that organization could have its own specialized memory, skills, files, and working scope.

Suggested design

  • Allow users to create multiple organizations or workspaces.
  • Allow each organization to contain multiple agents.
  • Give each agent isolated memory, skills, files, preferences, and project access.
  • Support optional shared organization-level memory for common standards and workflows.
  • Let agents communicate or delegate tasks to each other when explicitly allowed.
  • Make the active organization and agent visible in every conversation.
  • Allow moving or copying selected memories between agents when needed.
  • Support per-agent permissions for repositories, SSH hosts, tools, and approval policies.

Example use cases

  • Organization A has separate agents for backend, frontend, infrastructure, and QA.
  • Organization B has a different set of agents with unrelated repositories and standards.
  • A personal workspace has experimental agents that do not pollute professional memory.
  • An infrastructure agent can know deployment procedures without exposing that context to unrelated projects.
  • A code-review agent can keep review preferences separate from implementation agents.

Security and UX safeguards

  • Memories should not cross organization boundaries unless the user explicitly moves or shares them.
  • Tool access should be scoped per organization and per agent.
  • The UI should clearly show which organization and agent are active.
  • Export, archive, and reset options should exist for individual agents.
  • Users should be able to inspect what memory or files belong to each agent.

Expected benefit

This would make Codex more scalable for long-term professional use. It would reduce context pollution, improve agent specialization, and make Codex safer and more predictable across multiple organizations, projects, and environments.

Suggested labels, if available: enhancement, agents, memory, skills, workspaces, organizations

Redaction check

This request uses generic organization and project examples only. It does not include real company names, private repository names, server names, credentials, internal paths, or client-specific information.

View original on GitHub ↗

2 Comments

github-actions[bot] contributor · 3 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #23083
  • #22026
  • #22692

Powered by Codex Action

AaronZ345 · 2 months ago

Adding one concrete workflow that fits this request.

Today the only reliable way I have found to run several long-lived Codex agents with separate memories is to create a separate CODEX_HOME for each agent. Each home then carries its own config.toml, AGENTS.md, skills/plugins, sessions, and memories/ directory. That gives isolation, but it makes agent identity an environment-level workaround instead of a first-class Codex concept.

The friction shows up quickly:

  • switching agents means relaunching with a different CODEX_HOME
  • Desktop/App Server/remote sessions need to agree on which home is active
  • memory, skills, config, and sessions get coupled even when only memory isolation is needed
  • there is no obvious UI/CLI diagnostic for “which agent profile and memory root am I using right now?”
  • sharing a selected memory between agents becomes manual file copying rather than an explicit operation

What I would like is agent-scoped memory, not just project-scoped memory:

[agents.research]
memory_root = "~/.codex/agents/research/memories"
skills_root = "~/.codex/agents/research/skills"

[agents.engineering]
memory_root = "~/.codex/agents/engineering/memories"
skills_root = "~/.codex/agents/engineering/skills"

[memory]
shared_root = "~/.codex/memories/shared"
inherit_shared = true

The important part is that Codex could keep one installation/home, while letting the user choose an active agent profile with its own durable memory root. A profile could optionally inherit shared/global memories, but agent memories should not cross profiles unless the user explicitly moves or copies them.

A minimal version would already help a lot:

  • codex --agent research or an equivalent Desktop profile selector
  • per-agent memory_root
  • visible diagnostics for active agent + active memory roots
  • commands/UI to list, copy, move, or clear memories by agent profile

This is related to #18343 and #14330, but the missing layer here is specifically long-lived agent identity. Projects can share an agent, and one project may also need multiple specialized agents. Tying that boundary to CODEX_HOME works, but it is brittle and hard to inspect.