Skip to main content

Project Structure

After running aui import-agent or aui create-agent, your project directory looks like this:
my-agent/
├── agent.aui.json              # Agent identity, objective, guardrails, tone
├── parameters.aui.json         # Data units (input/output definitions)
├── entities.aui.json           # Groups of related parameters
├── integrations.aui.json       # API, RAG, and MCP connections
├── rules.aui.json              # Global behavioral rules
├── tools/                      # Agent capabilities (one file per tool)
│   ├── product_search.aui.json
│   └── generative_ai.aui.json
├── GUIDE.md                    # Step-by-step building guide
├── .auirc                      # Project config (agent ID, account, env)
├── .aui-schema/                # JSON schemas for validation
│   └── aui.dschema.json
└── .vscode/
    └── settings.json           # Schema autocomplete for VSCode/Cursor

File Reference

FilePurpose
agent.aui.jsonCore agent configuration — name, objective, personality, guardrails, tone of voice
parameters.aui.jsonDefines data units the agent collects or outputs
entities.aui.jsonGroups related parameters into logical entities
integrations.aui.jsonExternal connections — APIs, RAG knowledge bases, MCP servers
rules.aui.jsonGlobal behavioral rules that govern agent behavior
tools/*.aui.jsonIndividual tool definitions — each tool is a separate file
GUIDE.mdAuto-generated step-by-step building guide
.auircProject-level config linking to your account and agent
.aui-schema/JSON schemas for local validation and editor autocomplete
VSCode and Cursor get automatic JSON schema autocomplete for .aui.json files via the .vscode/settings.json generated during import.

Session

Stored at ~/.aui/session.json after login. Contains:
  • Auth token (JWT) and refresh token
  • User info (ID, email, name)
  • Organization ID and name
  • Account ID and name
  • Agent ID and name
  • Environment and API URL
  • Token expiry timestamp
Do not commit ~/.aui/ to version control. It contains authentication tokens and API keys.

Project Config (.auirc)

Created in your project directory by aui import-agent or aui create-agent:
.auirc
{
  "agent_code": "my_agent",
  "agent_id": "abc123",
  "environment": "staging",
  "account_id": "...",
  "organization_id": "...",
  "network_category_id": "...",
  "network_api_key": "..."
}
This file links your local project to a specific agent and account on the AUI platform.

Environment Variables

Environment variables override file-based configuration. Useful for CI/CD pipelines.
VariableDescription
AUI_AUTH_TOKENSkip login — use this JWT directly
AUI_API_URLOverride API base URL
AUI_ENVIRONMENTSet environment (staging, custom, production)
AUI_ACCOUNT_IDAccount ID
AUI_ORGANIZATION_IDOrganization ID
AUI_AGENT_CODEAgent code
AUI_KBM_API_KEYRAG knowledge base API key
AUI_AGENT_TOOLS_API_KEYAgent Settings API key
AUI_API_WORKFLOW_KEYAPI Workflow key
# Example: run a command against production without switching env
AUI_ENVIRONMENT=production aui list-agents

Secure Key Files

Additional credentials are stored as secure files (mode 600) in ~/.aui/:
FilePurpose
~/.aui/kbm-keyRAG API key
~/.aui/agent-settings-keyAgent Settings API key
~/.aui/api-workflow-keyAPI Workflow key

Environments

AUI supports three environments:
EnvironmentDescription
stagingDevelopment and testing
customCustom environment
productionLive production environment
Switch environments:
aui env staging
aui env production
aui env custom
The active environment is stored in ~/.aui/environment.

Next Steps