Skip to content

Rename core Jido.Identity self-model namespace to unblock cryptographic jido_identity package #276

@mikehostetler

Description

@mikehostetler

Summary

Rename the current core Jido.Identity agent self-model namespace so Jido.Identity can be owned by the extracted cryptographic jido_identity package.

This came up while extracting Arbor security primitives into independent Jido packages. The first package, jido_identity, exposes Jido.Identity as a narrow cryptographic principal API: Ed25519 signing identities, deterministic principal IDs, signed request envelopes, replay protection, registry status, and key-store behaviours.

Core Jido already defines Jido.Identity for a different concept: an agent self-model/profile state primitive stored under agent.state[:__identity__]. That creates a hard compile-time module collision when an app tries to install both :jido and :jido_identity.

Current Core Jido Meaning

Today core Jido.Identity is not cryptographic identity. It is agent profile/lifecycle state:

  • Jido.Identity: struct with rev, profile, created_at, updated_at
  • Jido.Identity.Agent: helpers for agent.state[:__identity__]
  • Jido.Identity.Profile: profile field helpers
  • Jido.Identity.Plugin: default singleton plugin for the :__identity__ state key
  • Jido.Identity.Actions.Evolve: simulated age/profile evolution action

That is useful functionality, but it is semantically different from a cryptographic principal identity.

Proposed Direction

Reserve Jido.Identity for the extracted cryptographic identity package and rename the current core self-model modules.

Suggested rename:

Jido.Identity                    -> Jido.Agent.SelfModel
Jido.Identity.Agent              -> Jido.Agent.SelfModel.Agent
Jido.Identity.Profile            -> Jido.Agent.SelfModel.Profile
Jido.Identity.Actions.Evolve     -> Jido.Agent.SelfModel.Actions.Evolve
Jido.Identity.Plugin             -> Jido.Agent.SelfModel.Plugin

Keep the state key :__identity__ for now to avoid unnecessary persisted-state churn. The immediate blocker is the module namespace, not necessarily the state key. A later migration could rename the state key to :__self_model__ if we want that cleanup.

Compatibility Notes

Do not leave compatibility shim modules under Jido.Identity in core Jido if we want :jido and :jido_identity to compile together. Any core module named Jido.Identity or Jido.Identity.* keeps the conflict alive.

This is likely a breaking change and may belong in a major release unless we are comfortable making the namespace cleanup sooner.

Integration Shape After Rename

Dependency direction should be:

jido -> jido_identity

not:

jido_identity -> jido

That keeps jido_identity foundational and independently usable by Arbor, gateways, non-Jido runtimes, and future package extraction work.

After the namespace is free, core Jido can optionally add a small bridge under a Jido-owned namespace, for example:

Jido.Agent.Principal
Jido.Agent.Principal.Plugin
Jido.Signal.Ext.Principal

The bridge should store only authenticated public metadata such as:

%{
  principal_id: "agent_...",
  key_version: 1,
  verified_at: DateTime.utc_now()
}

Private keys should never be stored in Jido agent state.

Acceptance Criteria

  • Core self-model identity modules are renamed away from Jido.Identity*.
  • Default plugin list uses the renamed self-model plugin.
  • Docs refer to the concept as self-model/profile/lifecycle identity rather than cryptographic identity.
  • Tests are updated for the renamed modules.
  • No core Jido module defines Jido.Identity or Jido.Identity.*.
  • A compile/integration test verifies that :jido and :jido_identity can be installed together.

Follow-up

Once this lands, jido_identity can remove its Livebook source-loading workaround and be demonstrated as a normal Mix dependency alongside core Jido.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions