Your own self-evolving AI agent powered by Elixir/OTP
Elixir
70
172 commits
updated Aug 8, 2026
Your own self-evolving AI agent
A long-running agent that works in the chat apps you already use, calls tools, remembers context, and keeps improving through real-world use.
NexAgent is an AI agent built for real-world, long-running use.
It is not just a one-shot CLI demo, and it is not just a thin prompt wrapper around a model. NexAgent is built around a more specific goal: keep an agent online, place it inside the chat apps you already use, give it memory and tools, let it manage background work, and make it capable of improving over time.
Two ideas define the project today:
If you only remember three things about NexAgent, they should be:
flowchart TD
A["Chat Apps<br/>Telegram / Feishu / Discord / Slack / DingTalk"] --> B["Gateway"]
B --> C["InboundWorker"]
C --> D["Runner"]
D --> E["Sessions + Memory"]
D --> F["Tools + Skills"]
D --> G["Cron + Subagent"]
D --> H["Reflect + Upgrade Code"]
H --> I["CodeUpgrade + UpgradeManager"]
| Use case | What NexAgent is doing |
|---|---|
| Always-on assistant | Stays in your chat apps and keeps per-chat context over time |
| Personal knowledge agent | Combines long-term memory, history, and retrieval |
| Automation assistant | Uses cron for reminders, recurring jobs, and background work |
| A growing agent | Expands through skills, tools, and code-level self-improvement |
| Capability | What it means |
|---|---|
| Self-evolving by design | soul_update, memory_write, skill_capture, tool_create, reflect, and upgrade_code keep the agent from staying static |
| Long-running sessions | Sessions are scoped by channel:chat_id and keep memory, history, and isolation |
| Works in your chat apps | Telegram, Feishu, Discord, Slack, and DingTalk are already supported |
| Tools, skills, and memory built in | File access, shell, web, messaging, memory search, scheduling, and skills come built in |
| Background work included | Cron jobs and subagents are part of the system, not an afterthought |
| Built on Elixir/OTP | Supervision trees, service processes, and hot reload support real-world uptime |
Many agent projects are good at finishing a single task. NexAgent is focused on a different set of questions: once an agent is actually deployed into chat environments and kept online, how should sessions, memory, jobs, failure handling, and self-improvement be organized?
NexAgent is not differentiated by “one more tool” or “one more model.” Its real difference is that evolution is treated as a core system capability.
That path is layered:
SOUL.md: adjust behavior, tone, and valuesMEMORY.md / HISTORY.md / daily logs: accumulate long-term experiencereflect and upgrade_code to inspect and modify the agent itselfThat is why “self-evolving” is not just a slogan here. It is a direction that runs from prompt and memory all the way down to source code.
If an agent only runs once in a while, the runtime matters less. If it needs to stay online, manage multiple chat surfaces, run background work, recover from failures, and eventually hot-upgrade itself, OTP stops being an implementation detail and becomes part of the product.
NexAgent already follows that path in code:
Application manages infrastructure, workers, and channel lifecycles through a supervision treeGateway manages chat app connectionsInboundWorker consumes inbound messages and routes sessionsSessionManager, Tool.Registry, Cron, and Subagent run as long-lived servicesCodeUpgrade and UpgradeManager handle hot updates, versioning, and rollback pathsThat is why Elixir/OTP is not background trivia in this project. It is one of the main reasons the project exists in this form.
NexAgent is not trying to solve “how do we wrap one more model call.” It is trying to solve a more operational set of problems:
| Traditional agent prototype | What NexAgent is aiming for |
|---|---|
| One-off tasks in a CLI | Long-lived agents inside chat apps |
| Mostly depends on the current context window | Sessions, memory, history, and retrieval |
| New capabilities mainly come from prompt edits | Tools, skills, and code-level self-improvement |
| Failures tend to kill the whole turn | OTP supervision and long-lived services keep the system stable |
| Capabilities are mostly fixed after deployment | The agent keeps evolving while it runs |
Requirements:
~> 1.18Install dependencies:
git clone https://github.com/gofenix/nex-agent.git
cd nex-agent
mix deps.get
mix nex.agent onboard
You can also point the CLI at a specific instance:
mix nex.agent -c /path/to/config.json -w /path/to/workspace onboard
On first run, NexAgent creates the config and workspace for that instance:
~/.nex/agent/
├── config.json
├── tools/
└── workspace/
├── AGENTS.md
├── SOUL.md
├── USER.md
├── skills/
├── sessions/
└── memory/
├── MEMORY.md
├── HISTORY.md
└── YYYY-MM-DD/log.md
The most direct path is to set provider, model, and API key through the CLI:
mix nex.agent config set provider openai
mix nex.agent config set model gpt-4o
mix nex.agent config set api_key openai sk-xxx
If you want to use Ollama:
mix nex.agent config set provider ollama
mix nex.agent config set model llama3.1
Default providers:
anthropicopenaiopenrouterollamaProvider access is unified through req_llm, so NexAgent no longer needs a
separate handwritten client module for each provider.
Config file location:
~/.nex/agent/config.json
If you pass --config and do not set defaults.workspace, the workspace defaults to
Path.dirname(config.json)/workspace for that instance.
The CLI is a host shell for the agent runtime. Capability-specific actions stay inside the agent loop through tools and skills; the CLI itself only manages sessions and runtime state.
Single message:
mix nex.agent -m "hello"
Interactive mode:
mix nex.agent
mix nex.agent gateway
Check status:
mix nex.agent status
Target a specific instance:
mix nex.agent -c /path/to/config.json status
mix nex.agent -c /path/to/config.json -w /path/to/workspace gateway
Stop the gateway:
mix nex.agent gateway stop
NexAgent is not meant to live only in a terminal.
The goal is to place the agent inside the chat apps you already use, so it becomes part of real communication and workflows.
Currently supported in code:
| Channel | What you need |
|---|---|
| Telegram | Bot token |
| Feishu | App ID + App Secret |
| Discord | Bot token |
| Slack | Bot token + App-level token |
| DingTalk | App Key + App Secret |
Telegram is the easiest place to start.
@BotFatherconfig.json or through the CLIExample:
mix nex.agent config set telegram.enabled true
mix nex.agent config set telegram.token 123456:ABCDEF
mix nex.agent config set telegram.allow_from 10001,10002
mix nex.agent config set telegram.reply_to_message true
mix nex.agent gateway
Other chat apps are currently better configured directly in ~/.nex/agent/config.json.
Feishu is still supported as a chat channel.
What changed is the workspace automation surface:
feishu_* business tools for Docs, Sheets, Base, Calendar, Tasks, Drive, chat administration, or search.bash tool with external lark-cli.lark-cli is not vendored or auto-installed by NexAgent. Install it separately from larksuite/cli.lark-cli is missing, the shell error should be surfaced directly and then followed with an installation hint.NexAgent currently supports:
The simplest starting points are usually:
Runner handles the agent loop and then dispatches to the selected provider implementation.
Default built-in tools:
readwriteeditlist_dirbashweb_searchweb_fetchmessagememory_writecronspawn_taskskill_discoverskill_getskill_captureskill_importskill_synctool_listtool_createtool_deletesoul_updatereflectupgrade_codeTogether, these cover files, shell commands, web access, outbound messaging, long-term memory, scheduling, skill growth, tool growth, and code upgrades.
Custom Elixir tools live in ~/.nex/agent/workspace/tools/<name>/ and are registered as first-class tools.
tool_create creates a workspace custom tooltool_list inspects built-in and custom toolstool_delete removes a custom toolBeyond tools, NexAgent has a Markdown-based skills system.
Skills are reusable workflow modules that help the agent:
Instance-local runtime skill packages live in workspace/skills/<name>/. Discover them through skill_discover, inspect them through skill_get, and capture new local knowledge packages through skill_capture.
Repository-owned workflow policy can also live in .nex/skills/<name>/SKILL.md.
When skill_runtime.enabled is turned on, repo-local Markdown skills are migrated into runtime-managed packages under workspace/skills/rt__*.
Code-based capabilities belong in the tool system, where Elixir modules implement deterministic behavior through Tool.Behaviour.
Runner.run/3, temp workspaces, real Tool.Registry, stubbed LLM calls, and stubbed GitHub responses. These tests run in the default mix test path and are tagged :e2e.:live_e2e and is excluded from default test runs. Use mix test --only live_e2e when OPENAI_API_KEY is set. The GitHub live import path also requires GH_TOKEN or GITHUB_TOKEN.SKILL_RUNTIME_LIVE_REPO, SKILL_RUNTIME_LIVE_COMMIT_SHA, and SKILL_RUNTIME_LIVE_PATH. In GitHub Actions those default to ${GITHUB_REPOSITORY}, ${GITHUB_SHA}, and test/support/fixtures/skill_runtime/live_packages/live_echo_playbook.mix test. Live E2E runs only in the dedicated manual/nightly workflow.NexAgent sessions are not just short-lived context windows. They are persistent conversations with memory layers behind them.
Sessions are scoped by channel:chat_id, for example:
telegram:123456discord:channel_idThis keeps different chat surfaces isolated instead of blending everything into one conversation stream.
Basic control commands already exist:
/new: start a new session/stop: stop active tasks for the current sessionThe memory system is layered:
MEMORY.md: long-term memoryHISTORY.md: searchable historyYYYY-MM-DD/log.md: operational memory and accumulated experienceMemory.Index: BM25-style retrievalThe point of this design is simple:
This is one of the defining capabilities of NexAgent.
Its evolution does not happen at a single point. It happens in six layers.
SOUL: who the agent is and which long-term principles it followsUSER: who the user is and how the agent should collaborate with themMEMORY: durable facts about the environment, project, and operational contextSKILL: reusable workflows and procedural knowledgeTOOL: deterministic executable capabilitiesCODE: internal implementation upgradesSOUL.md adjusts behavior, personality, and values.
USER.md captures who the user is, how they prefer to collaborate, and what should stay stable across sessions.
Through MEMORY.md, HISTORY.md, and daily logs, the agent can keep accumulating durable project and environment facts instead of depending only on the current chat window.
Through skill_capture, the agent can keep expanding reusable workflows and procedural knowledge. Discovery is unified through skill_discover and skill_get, while trusted package-style skills can be imported and refreshed through skill_import and skill_sync.
Through tool_create and workspace custom tools, the agent can keep expanding deterministic executable capability.
The code layer has its own explicit upgrade path:
reflect: inspect module source, history, and diffsupgrade_code: submit updated module codeCodeUpgrade: backup, validate, compile, load, and version codeUpgradeManager: coordinate code upgrades, hot swaps, and rollback pathsThat is what makes NexAgent more than a configurable agent. It is an agent system that is explicitly being built to learn, extend, and upgrade itself across multiple layers.
flowchart LR
A["Reflect<br/>Read source / history / diff"] --> B["Understand<br/>Find the problem or opportunity"]
B --> C["Upgrade Code<br/>Submit new code"]
C --> D["CodeUpgrade<br/>Backup / validate / compile / load"]
D --> E["UpgradeManager<br/>Hot-swap / rollback protection"]
E --> F["Agent keeps running"]
NexAgent includes a built-in cron tool for scheduled jobs.
Supported operations:
Supported scheduling modes:
every_secondscron_expratTo reduce long-running cost, cron execution is deliberately lighter:
spawn_task creates a background subagent for an independent task.
It fits cases like:
When it finishes, the result is sent back through the bus.
NexAgent is not a loose collection of scripts. It is a layered, long-running system.
flowchart TB
subgraph L1["Entry Layer"]
A["Chat Apps"]
B["Gateway"]
end
subgraph L2["Agent Layer"]
C["InboundWorker"]
D["Runner"]
end
subgraph L3["Capability Layer"]
E["Sessions"]
F["Memory + Memory.Index"]
G["Tools + Tool.Registry"]
H["Skills"]
end
subgraph L4["Background Layer"]
I["Cron"]
J["Subagent"]
end
subgraph L5["Code Layer"]
K["Reflect + Upgrade Code"]
L["CodeUpgrade + UpgradeManager"]
end
A --> B --> C --> D
D --> E
D --> F
D --> G
D --> H
D --> I
D --> J
D --> K --> L
Another way to read the system is:
Core roles in code:
Gateway: manage chat app connection processesInboundWorker: route inbound messagesRunner: build context and execute the agent loopSessionManager: manage persisted sessionsMemory / Memory.Index: manage long-term memory and retrievalTool.Registry: manage tools dynamicallySkills: load and execute skillsCron: manage scheduled jobsSubagent: manage background subagentsCodeUpgrade / UpgradeManager: manage source-level code upgradesThese parts are held together by an OTP supervision tree instead of being scattered across unrelated scripts.
NexAgent already has some important boundaries in place:
allow_fromIt is not finished, but the direction is clear: this is not meant to become an unrestricted local god-agent by default.
If you had to compress the project into one line:
NexAgent is a self-evolving AI agent built on Elixir/OTP for long-running, real-world use.
Its differentiator is not just “one more provider” or “a few more tools.” It is the attempt to combine all of these in one system:
If you care about how agents can keep existing in real environments, not just finish a single demo task, that is the path NexAgent is pushing forward.
158 commits
14 commits
Elixir
99.5%
Your own self-evolving AI agent powered by Elixir/OTP
Elixir
70
172 commits
updated Aug 8, 2026
Your own self-evolving AI agent
A long-running agent that works in the chat apps you already use, calls tools, remembers context, and keeps improving through real-world use.
NexAgent is an AI agent built for real-world, long-running use.
It is not just a one-shot CLI demo, and it is not just a thin prompt wrapper around a model. NexAgent is built around a more specific goal: keep an agent online, place it inside the chat apps you already use, give it memory and tools, let it manage background work, and make it capable of improving over time.
Two ideas define the project today:
If you only remember three things about NexAgent, they should be:
flowchart TD
A["Chat Apps<br/>Telegram / Feishu / Discord / Slack / DingTalk"] --> B["Gateway"]
B --> C["InboundWorker"]
C --> D["Runner"]
D --> E["Sessions + Memory"]
D --> F["Tools + Skills"]
D --> G["Cron + Subagent"]
D --> H["Reflect + Upgrade Code"]
H --> I["CodeUpgrade + UpgradeManager"]
| Use case | What NexAgent is doing |
|---|---|
| Always-on assistant | Stays in your chat apps and keeps per-chat context over time |
| Personal knowledge agent | Combines long-term memory, history, and retrieval |
| Automation assistant | Uses cron for reminders, recurring jobs, and background work |
| A growing agent | Expands through skills, tools, and code-level self-improvement |
| Capability | What it means |
|---|---|
| Self-evolving by design | soul_update, memory_write, skill_capture, tool_create, reflect, and upgrade_code keep the agent from staying static |
| Long-running sessions | Sessions are scoped by channel:chat_id and keep memory, history, and isolation |
| Works in your chat apps | Telegram, Feishu, Discord, Slack, and DingTalk are already supported |
| Tools, skills, and memory built in | File access, shell, web, messaging, memory search, scheduling, and skills come built in |
| Background work included | Cron jobs and subagents are part of the system, not an afterthought |
| Built on Elixir/OTP | Supervision trees, service processes, and hot reload support real-world uptime |
Many agent projects are good at finishing a single task. NexAgent is focused on a different set of questions: once an agent is actually deployed into chat environments and kept online, how should sessions, memory, jobs, failure handling, and self-improvement be organized?
NexAgent is not differentiated by “one more tool” or “one more model.” Its real difference is that evolution is treated as a core system capability.
That path is layered:
SOUL.md: adjust behavior, tone, and valuesMEMORY.md / HISTORY.md / daily logs: accumulate long-term experiencereflect and upgrade_code to inspect and modify the agent itselfThat is why “self-evolving” is not just a slogan here. It is a direction that runs from prompt and memory all the way down to source code.
If an agent only runs once in a while, the runtime matters less. If it needs to stay online, manage multiple chat surfaces, run background work, recover from failures, and eventually hot-upgrade itself, OTP stops being an implementation detail and becomes part of the product.
NexAgent already follows that path in code:
Application manages infrastructure, workers, and channel lifecycles through a supervision treeGateway manages chat app connectionsInboundWorker consumes inbound messages and routes sessionsSessionManager, Tool.Registry, Cron, and Subagent run as long-lived servicesCodeUpgrade and UpgradeManager handle hot updates, versioning, and rollback pathsThat is why Elixir/OTP is not background trivia in this project. It is one of the main reasons the project exists in this form.
NexAgent is not trying to solve “how do we wrap one more model call.” It is trying to solve a more operational set of problems:
| Traditional agent prototype | What NexAgent is aiming for |
|---|---|
| One-off tasks in a CLI | Long-lived agents inside chat apps |
| Mostly depends on the current context window | Sessions, memory, history, and retrieval |
| New capabilities mainly come from prompt edits | Tools, skills, and code-level self-improvement |
| Failures tend to kill the whole turn | OTP supervision and long-lived services keep the system stable |
| Capabilities are mostly fixed after deployment | The agent keeps evolving while it runs |
Requirements:
~> 1.18Install dependencies:
git clone https://github.com/gofenix/nex-agent.git
cd nex-agent
mix deps.get
mix nex.agent onboard
You can also point the CLI at a specific instance:
mix nex.agent -c /path/to/config.json -w /path/to/workspace onboard
On first run, NexAgent creates the config and workspace for that instance:
~/.nex/agent/
├── config.json
├── tools/
└── workspace/
├── AGENTS.md
├── SOUL.md
├── USER.md
├── skills/
├── sessions/
└── memory/
├── MEMORY.md
├── HISTORY.md
└── YYYY-MM-DD/log.md
The most direct path is to set provider, model, and API key through the CLI:
mix nex.agent config set provider openai
mix nex.agent config set model gpt-4o
mix nex.agent config set api_key openai sk-xxx
If you want to use Ollama:
mix nex.agent config set provider ollama
mix nex.agent config set model llama3.1
Default providers:
anthropicopenaiopenrouterollamaProvider access is unified through req_llm, so NexAgent no longer needs a
separate handwritten client module for each provider.
Config file location:
~/.nex/agent/config.json
If you pass --config and do not set defaults.workspace, the workspace defaults to
Path.dirname(config.json)/workspace for that instance.
The CLI is a host shell for the agent runtime. Capability-specific actions stay inside the agent loop through tools and skills; the CLI itself only manages sessions and runtime state.
Single message:
mix nex.agent -m "hello"
Interactive mode:
mix nex.agent
mix nex.agent gateway
Check status:
mix nex.agent status
Target a specific instance:
mix nex.agent -c /path/to/config.json status
mix nex.agent -c /path/to/config.json -w /path/to/workspace gateway
Stop the gateway:
mix nex.agent gateway stop
NexAgent is not meant to live only in a terminal.
The goal is to place the agent inside the chat apps you already use, so it becomes part of real communication and workflows.
Currently supported in code:
| Channel | What you need |
|---|---|
| Telegram | Bot token |
| Feishu | App ID + App Secret |
| Discord | Bot token |
| Slack | Bot token + App-level token |
| DingTalk | App Key + App Secret |
Telegram is the easiest place to start.
@BotFatherconfig.json or through the CLIExample:
mix nex.agent config set telegram.enabled true
mix nex.agent config set telegram.token 123456:ABCDEF
mix nex.agent config set telegram.allow_from 10001,10002
mix nex.agent config set telegram.reply_to_message true
mix nex.agent gateway
Other chat apps are currently better configured directly in ~/.nex/agent/config.json.
Feishu is still supported as a chat channel.
What changed is the workspace automation surface:
feishu_* business tools for Docs, Sheets, Base, Calendar, Tasks, Drive, chat administration, or search.bash tool with external lark-cli.lark-cli is not vendored or auto-installed by NexAgent. Install it separately from larksuite/cli.lark-cli is missing, the shell error should be surfaced directly and then followed with an installation hint.NexAgent currently supports:
The simplest starting points are usually:
Runner handles the agent loop and then dispatches to the selected provider implementation.
Default built-in tools:
readwriteeditlist_dirbashweb_searchweb_fetchmessagememory_writecronspawn_taskskill_discoverskill_getskill_captureskill_importskill_synctool_listtool_createtool_deletesoul_updatereflectupgrade_codeTogether, these cover files, shell commands, web access, outbound messaging, long-term memory, scheduling, skill growth, tool growth, and code upgrades.
Custom Elixir tools live in ~/.nex/agent/workspace/tools/<name>/ and are registered as first-class tools.
tool_create creates a workspace custom tooltool_list inspects built-in and custom toolstool_delete removes a custom toolBeyond tools, NexAgent has a Markdown-based skills system.
Skills are reusable workflow modules that help the agent:
Instance-local runtime skill packages live in workspace/skills/<name>/. Discover them through skill_discover, inspect them through skill_get, and capture new local knowledge packages through skill_capture.
Repository-owned workflow policy can also live in .nex/skills/<name>/SKILL.md.
When skill_runtime.enabled is turned on, repo-local Markdown skills are migrated into runtime-managed packages under workspace/skills/rt__*.
Code-based capabilities belong in the tool system, where Elixir modules implement deterministic behavior through Tool.Behaviour.
Runner.run/3, temp workspaces, real Tool.Registry, stubbed LLM calls, and stubbed GitHub responses. These tests run in the default mix test path and are tagged :e2e.:live_e2e and is excluded from default test runs. Use mix test --only live_e2e when OPENAI_API_KEY is set. The GitHub live import path also requires GH_TOKEN or GITHUB_TOKEN.SKILL_RUNTIME_LIVE_REPO, SKILL_RUNTIME_LIVE_COMMIT_SHA, and SKILL_RUNTIME_LIVE_PATH. In GitHub Actions those default to ${GITHUB_REPOSITORY}, ${GITHUB_SHA}, and test/support/fixtures/skill_runtime/live_packages/live_echo_playbook.mix test. Live E2E runs only in the dedicated manual/nightly workflow.NexAgent sessions are not just short-lived context windows. They are persistent conversations with memory layers behind them.
Sessions are scoped by channel:chat_id, for example:
telegram:123456discord:channel_idThis keeps different chat surfaces isolated instead of blending everything into one conversation stream.
Basic control commands already exist:
/new: start a new session/stop: stop active tasks for the current sessionThe memory system is layered:
MEMORY.md: long-term memoryHISTORY.md: searchable historyYYYY-MM-DD/log.md: operational memory and accumulated experienceMemory.Index: BM25-style retrievalThe point of this design is simple:
This is one of the defining capabilities of NexAgent.
Its evolution does not happen at a single point. It happens in six layers.
SOUL: who the agent is and which long-term principles it followsUSER: who the user is and how the agent should collaborate with themMEMORY: durable facts about the environment, project, and operational contextSKILL: reusable workflows and procedural knowledgeTOOL: deterministic executable capabilitiesCODE: internal implementation upgradesSOUL.md adjusts behavior, personality, and values.
USER.md captures who the user is, how they prefer to collaborate, and what should stay stable across sessions.
Through MEMORY.md, HISTORY.md, and daily logs, the agent can keep accumulating durable project and environment facts instead of depending only on the current chat window.
Through skill_capture, the agent can keep expanding reusable workflows and procedural knowledge. Discovery is unified through skill_discover and skill_get, while trusted package-style skills can be imported and refreshed through skill_import and skill_sync.
Through tool_create and workspace custom tools, the agent can keep expanding deterministic executable capability.
The code layer has its own explicit upgrade path:
reflect: inspect module source, history, and diffsupgrade_code: submit updated module codeCodeUpgrade: backup, validate, compile, load, and version codeUpgradeManager: coordinate code upgrades, hot swaps, and rollback pathsThat is what makes NexAgent more than a configurable agent. It is an agent system that is explicitly being built to learn, extend, and upgrade itself across multiple layers.
flowchart LR
A["Reflect<br/>Read source / history / diff"] --> B["Understand<br/>Find the problem or opportunity"]
B --> C["Upgrade Code<br/>Submit new code"]
C --> D["CodeUpgrade<br/>Backup / validate / compile / load"]
D --> E["UpgradeManager<br/>Hot-swap / rollback protection"]
E --> F["Agent keeps running"]
NexAgent includes a built-in cron tool for scheduled jobs.
Supported operations:
Supported scheduling modes:
every_secondscron_expratTo reduce long-running cost, cron execution is deliberately lighter:
spawn_task creates a background subagent for an independent task.
It fits cases like:
When it finishes, the result is sent back through the bus.
NexAgent is not a loose collection of scripts. It is a layered, long-running system.
flowchart TB
subgraph L1["Entry Layer"]
A["Chat Apps"]
B["Gateway"]
end
subgraph L2["Agent Layer"]
C["InboundWorker"]
D["Runner"]
end
subgraph L3["Capability Layer"]
E["Sessions"]
F["Memory + Memory.Index"]
G["Tools + Tool.Registry"]
H["Skills"]
end
subgraph L4["Background Layer"]
I["Cron"]
J["Subagent"]
end
subgraph L5["Code Layer"]
K["Reflect + Upgrade Code"]
L["CodeUpgrade + UpgradeManager"]
end
A --> B --> C --> D
D --> E
D --> F
D --> G
D --> H
D --> I
D --> J
D --> K --> L
Another way to read the system is:
Core roles in code:
Gateway: manage chat app connection processesInboundWorker: route inbound messagesRunner: build context and execute the agent loopSessionManager: manage persisted sessionsMemory / Memory.Index: manage long-term memory and retrievalTool.Registry: manage tools dynamicallySkills: load and execute skillsCron: manage scheduled jobsSubagent: manage background subagentsCodeUpgrade / UpgradeManager: manage source-level code upgradesThese parts are held together by an OTP supervision tree instead of being scattered across unrelated scripts.
NexAgent already has some important boundaries in place:
allow_fromIt is not finished, but the direction is clear: this is not meant to become an unrestricted local god-agent by default.
If you had to compress the project into one line:
NexAgent is a self-evolving AI agent built on Elixir/OTP for long-running, real-world use.
Its differentiator is not just “one more provider” or “a few more tools.” It is the attempt to combine all of these in one system:
If you care about how agents can keep existing in real environments, not just finish a single demo task, that is the path NexAgent is pushing forward.
158 commits
14 commits
Elixir
99.5%