OASIS: Simulating Social Media With One Million AI Agents
What happens when you put a million AI agents on a simulated Twitter? OASIS (Open Agent Social Interaction Simulations) from CAMEL-AI answers that question â and the results are genuinely interesting for anyone studying how information spreads, opinions polarize, and crowds behave online.
What OASIS Does
OASIS is a scalable social media simulator where LLM-powered agents interact on platforms modeled after Twitter and Reddit. Each agent has a profile, preferences, and the ability to perform 23 distinct actions â following, posting, commenting, liking, disliking, reposting, searching, muting, and more.
The key claim: it scales to one million agents, enabling studies at a scale comparable to real social media platforms. Thatâs not a toy sandbox â itâs large enough to observe emergent phenomena that only appear at scale.
Why This Matters
Social media research has a data problem. You can study real platforms, but you canât run controlled experiments â you canât replay a scenario with different variables, inject specific content, or isolate causes. OASIS gives researchers a lab environment where they can:
- Track misinformation spread â seed false information and watch how it propagates through the network
- Study group polarization â observe how agents with different profiles cluster and radicalize
- Analyze herd behavior â see how recommendation algorithms amplify trends
- Test content moderation strategies â experiment with interventions before deploying them on real platforms
- Simulate platform design changes â what happens if you remove likes? Change the algorithm? Add friction to reposting?
This is computational social science at a scale that wasnât possible before LLMs made it feasible to give each agent realistic, context-dependent behavior.
Technical Architecture
OASIS is built on the CAMEL multi-agent framework and uses a gym-style environment API:
import oasis
# Create agent graph from profiles
agent_graph = await generate_reddit_agent_graph(
profile_path="./data/reddit/user_data_36.json",
model=openai_model,
available_actions=available_actions,
)
# Make the environment
env = oasis.make(
agent_graph=agent_graph,
platform=oasis.DefaultPlatformType.REDDIT,
database_path="./data/simulation.db",
)
# Step through the simulation
await env.reset()
await env.step(actions)
Key components:
- Agent profiles â JSON-defined personas with interests, demographics, and behavioral tendencies
- Platform simulation â Twitter and Reddit environments with authentic mechanics
- Recommendation systems â interest-based and hot-score algorithms that determine what agents see
- Action space â 23 actions covering the full range of social media interactions
- SQLite storage â all interactions logged for post-simulation analysis
- LLM backbone â uses GPT-4o-mini by default via CAMELâs model abstraction (supports other providers)
The 23 Actions
Agents arenât limited to posting and liking. The full action space includes:
Creating posts, commenting, liking/disliking posts, liking/disliking comments, reposting, following, muting, searching posts, searching users, viewing trends, refreshing feeds, and doing nothing â that last one matters because real users donât engage with every piece of content they see.
This granularity is what separates OASIS from simpler agent simulations. The âdo nothingâ action alone introduces realistic engagement rates rather than forcing 100% participation.
Practical Use Cases
For researchers: Run reproducible experiments on social dynamics. Seed a conspiracy theory with 10 agents and measure how many of the remaining 999,990 encounter it within 100 time steps. Change the recommendation algorithm and re-run. Publish with reproducible results.
For platform designers: Test moderation policies, algorithm changes, and UI modifications in simulation before A/B testing with real users. Whatâs the polarization impact of removing public like counts?
For AI safety: Study how AI-generated content interacts with AI consumers at scale. When both the content creators and the audience are LLM-powered, what feedback loops emerge?
For educators: Demonstrate social media dynamics in a classroom setting. Students can design experiments, run simulations, and analyze results without needing access to real platform data.
How It Compares
OASIS occupies a unique niche. Most multi-agent frameworks weâve covered are about task completion â agents collaborating to write code, do research, or manage workflows. OASIS is about social simulation: agents donât have goals to accomplish, they have personalities to express.
The closest comparison is GenSim (Stanfordâs âSmallvilleâ paper), which simulated 25 agents in a virtual town. OASIS scales that concept by 40,000Ă and specializes it for social media dynamics.
Other multi-agent coordination frameworks like CAMEL (OASISâs parent project), CrewAI, and PraisonAI are task-oriented. OpenSpace explored collective intelligence but at much smaller scale. OASIS is the first open-source framework purpose-built for million-agent social simulation.
Token Costs and Scaling
Running a million LLM agents isnât free. At GPT-4o-mini pricing, even a single simulation step across all agents adds up. The practical approach is to run smaller simulations (hundreds to thousands of agents) for most experiments and reserve million-agent runs for validating scale-dependent phenomena.
The pip install camel-oasis package handles the infrastructure, but youâll want to budget API costs carefully for large runs. Local models via Ollama could reduce costs dramatically for experiments where GPT-4o-mini quality isnât necessary.
Getting Started
pip install camel-oasis
export OPENAI_API_KEY=your-key
Download a sample profile dataset from the repo and run the quickstart example. The documentation covers custom agent profiles, platform configuration, and analysis tools.
The Bigger Picture
Weâre at an inflection point where AI agents arenât just tools â theyâre subjects of study. OASIS treats LLM agents as synthetic populations for social science research, which is a fundamentally different use case from everything else in the agent ecosystem.
The implications extend beyond academia. As AI-generated content floods real social platforms, understanding how synthetic agents interact at scale becomes a practical necessity, not just an intellectual exercise. OASIS gives us a sandbox to study that future before it fully arrives.