Skip to content

[Feature]: aioncore session create and session clear — the agent-facing CLI can talk to conversations but cannot open or reset one #965

Description

@mrjjstudio

Use case

One conversation acts as an orchestrator. It dispatches work to other conversations with aioncore session send-message, and that part works well today.

What it cannot do:

  • Open a fresh conversation for unrelated work.
  • Reset a conversation whose context has gone stale.

Both require a human to switch to the desktop app and click. That breaks unattended automation at exactly the point where the agent is otherwise self-sufficient: it can delegate, but it cannot manage the lifecycle of what it delegates to.

What the CLI exposes today

agent-facing-session-cli:

  • session capabilities
  • session list
  • session send-message

agent-facing-config-cli, conversation-adjacent:

  • config conversation rename
  • config cron jobs … and config cron current … — schedule a message into an existing conversation

The three-command session contract is hardcoded in
crates/aionui-app/src/commands/session_capabilities.rs
commands lists exactly capabilities, list, send-message. There is no create, clear, delete, or compact anywhere in the agent-facing surface.

The backend can already do this

#772 (merged, from #770) added POST /api/conversations/{id}/fork, which creates a new conversation with a workspace, an agent binding, and lazy backend-session materialization.

So conversation creation already exists server-side, with the hard parts solved. What is missing is the CLI surface over it.

Proposed shape (minimal)

session create   # stdin: { workspace, agent (or assistant_id), name? }  -> { conversation_id }
session clear    # stdin: { conversation_id }
  • create returns the new conversation id so the orchestrator can immediately send-message to it.
  • clear resets an existing conversation's context in place, keeping its id — so scheduled cron jobs and any stored id stay valid.

clear discards conversation state and cannot be undone. It should be marked accordingly in the capability contract. The config CLI already has this concept: CommandDescriptor carries a destructive flag, and config cron jobs delete sets it (config_capabilities.rs:138). The session contract currently has no equivalent field, so one would need adding there.

Naming and exact input fields are open — the request is the capability, not the spelling.

Prior art check

I searched issues and pull requests, open and closed, in both iOfficeAI/AionCore and iOfficeAI/AionUi, for conversation create / clear / reset / delete / compact and for agent-facing CLI framings. I found no existing issue or PR asking for this. The closest items are not the same request:

  • #772 / #770 — fork, HTTP only, forks from a chosen message rather than opening a fresh conversation.
  • #795 / #798 — trusted provisioning protocols, explicitly conversation-independent.

If I missed an existing issue, happy to close this as a duplicate.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions