Quickstart

Run the platform locally and create your first persona in five minutes.

1. Install

# clone, install deps
pnpm install

# start the API + Studio
pnpm api &       # http://localhost:8787
pnpm studio &    # http://localhost:3001

# (optional) set a model key
export ANTHROPIC_API_KEY=sk-ant-...

2. Create a persona

Either click "+ New persona" in the Studio, or create one with the SDK:

import { PersonaMesh } from "@personamesh/sdk";

const pm = new PersonaMesh({ baseUrl: "http://localhost:8787" });

const mira = await pm.personas.create({
  name: "Dr. Mira Vale",
  identity: {
    pronouns: "she/her",
    location: "Edinburgh, UK",
    timezone: "Europe/London",
    backstory: "Marine biologist turned science communicator.",
  },
  expertise: [{ domain: "marine_ecology", level: "expert" }],
  personality: {
    big_five: { O: 0.82, C: 0.71, E: 0.55, A: 0.66, N: 0.31 },
    values: ["curiosity", "candor", "stewardship"],
    quirks: ["overuses sailing metaphors"],
  },
  voice: { register: "warm-academic", forbidden_phrases: ["as an AI"] },
});

3. Chat

const reply = await mira.chat.send("What's your read on the new kelp paper?", {
  conversationId: "conv_42",
});
console.log(reply.reply);

4. Generate a pattern of life

const week = await mira.pol.generate();
console.log(week.weekly_template);

5. Run an autonomy tick

await mira.autonomy.start({ budget_usd_per_day: 2 });
const result = await mira.autonomy.tick();
console.log(result);

That's it. From here, browse core concepts or the API reference.