capsule-identity README

The project's README from github.com/unicity-aos/capsule-identity. As one markdown file: README.md.

astrid-capsule-identity

License: MIT OR Apache-2.0 MSRV: 1.94

The identity and system prompt builder for Astrid OS.

In the OS model, this capsule is /etc/profile. It owns the agent's spark identity, persists it as capsule state, and assembles the identity plus environment context into a system prompt.

How it works

On a spark.v1.request.build event:

  1. Loads the persisted spark identity from capsule KV state.
  2. Auto-detects home://.config/spark.toml if KV state is empty.
  3. Adds environment context (working directory, platform).
  4. Publishes the assembled prompt on spark.v1.response.ready.

If no identity exists yet, the prompt includes onboarding instructions. After onboarding, the LLM calls save_identity, which saves the chosen callsign, class, aura, signal, and core directives to capsule state and writes home://.config/spark.toml as a recovery copy.

State is scoped by Astrid's capsule KV isolation for the calling principal. Session ID is echoed back for react loop correlation.

IPC protocol

Direction Topic
Subscribe spark.v1.request.build
Subscribe tool.v1.execute.save_identity
Subscribe tool.v1.request.describe
Subscribe cli.v1.command.execute
Publish spark.v1.response.ready
Publish tool.v1.execute.*.result
Publish tool.v1.response.describe.*
Publish agent.v1.response

Development

cargo build
cargo test

License

Dual-licensed under MIT and Apache 2.0.

Copyright (c) 2025-2026 Joshua J. Bouw and Unicity Labs.

capsule-identity (unicity-aos/capsule-identity)

Searching Database…

What is this?It's the system-prompt builder capsule for Astrid OS (part of Unicity AOS) - it owns an agent's 'spark' identity, merges it with workspace and environment context, and assembles the resulting system prompt the LLM receives.
Is this a standalone app or part of something bigger?It's a capsule - a modular IPC service inside Astrid OS's capsule architecture, which the README compares to /etc/profile in a normal OS. It only runs as a component of Astrid OS/Unicity AOS, not on its own.
How do I get it running?It isn't launched manually - it activates when Astrid OS emits a spark.v1.request.build event, then loads the stored identity from capsule KV state or auto-detects it from home://.config/spark.toml.
Do I need Astrid OS to use this?Yes, it depends entirely on Astrid OS's capsule KV state and pub/sub IPC bus - it subscribes to topics like spark.v1.request.build and tool.v1.execute.saveidentity and has no independent runtime.
What happens the first time, before any identity is set up?If no identity has been saved yet, the assembled prompt includes onboarding instructions so the agent walks through picking a callsign, class, aura, signal, and core directives.
What identity fields get saved during onboarding?During onboarding the LLM calls saveidentity, which stores the callsign, class, aura, signal, and core directives, then writes a recovery copy to home://.config/spark.toml.
How does this capsule talk to the rest of Astrid OS?Entirely through pub/sub IPC: it listens for events like spark.v1.request.build and tool.v1.execute.saveidentity, and publishes the assembled prompt on spark.v1.response.ready.
Why is it compared to /etc/profile?Like /etc/profile initializes a shell session, this capsule initializes an agent's identity and environment context at the start of each session, echoing the session ID back for loop correlation.
Size
0.2 MB
Stars
8.4K
Age
7mo
Commits · 90 Days