DBase

AndroidIRCX AI and Scripting: A Smarter, Extensible IRC Client

AndroidIRCX AI and Scripting: A Smarter, Extensible IRC Client

AndroidIRCX AI and Scripting: A Smarter, Extensible IRC Client

• Sep 25, 2026 • 4 views

AndroidIRCX combines bring-your-own AI, a powerful JavaScript API, MCP and a permission-based add-on platform to make mobile IRC smarter, safer and deeply customizable.

AndroidIRCX AI and Scripting: A Smarter, Extensible IRC Client

IRC has always rewarded people who want more than a fixed chat window. The classic clients became lasting communities of their own because users could automate repetitive work, create commands, react to network events and shape the client around the way they used IRC.

AndroidIRCX is bringing that spirit to Android with two connected systems: a built-in JavaScript scripting API and a bring-your-own AI layer. The result is not an AI chatbot attached to IRC as an afterthought. It is a practical automation platform where scripts can understand IRC state, AI can help with language and context, and the user remains in control of every sensitive action.

The major AI features arrived in AndroidIRCX v1.9.56. The scripting and add-on work then grew into the much larger v1.10.0 platform, with richer APIs, safer permissions, isolated packaged add-ons, app-managed UI extensions, storage, files, diagnostics and recovery.

The complete technical reference lives in the AndroidIRCX Wiki. Start with AI, Scripting, MCP and Addon Platform.


AI that uses your provider, not ours

AndroidIRCX does not bundle a model, operate an AI proxy or sell a separate AI subscription. You connect your own provider and your phone talks to it directly.

Supported setups include:

  • Anthropic
  • OpenAI-compatible providers
  • Google Gemini
  • DeepSeek, Groq and OpenRouter
  • local models through software such as Ollama or LM Studio

This bring-your-own-provider design has useful consequences. You select the model, control the provider account and pay the provider directly. A local model can keep the entire request on your own network, needs no API key and does not require cloud-provider consent inside the app.

A Claude Pro/Max or ChatGPT Plus subscription is not an API key. AndroidIRCX uses developer APIs, so a separate developer key is required for cloud providers. Keys are stored in the Android device Keychain and deliberately excluded from backup exports.

AI uses the existing scripting-time system rather than a new paywall. Pro Unlimited and Supporter Pro users already have unlimited scripting time; other users use the same rewarded-time model as scripts.

AI inside JavaScript scripts

Scripts can ask a configured model a single question or hold a multi-turn exchange:

const answer = await api.ai.ask('Summarize this discussion', {
  channel: '#dev',
  maxTokens: 300,
  system: 'Return a short factual summary.',
});

The main calls are:

  • api.ai.ask(prompt, options?) for one question
  • api.ai.chat(messages, options?) for a conversation
  • api.ai.isAvailable() to check readiness
  • api.ai.listProviders() to list configured providers without exposing keys

Five AI examples ship disabled by default: the /ai task helper, /summarize, per-channel translation, reply suggestions on highlight and private moderation assistance. /ai reads recent channel context and presents a result for review; /aisend is the separate, deliberate action that publishes the last result. That separation helps prevent a message written by somebody else from turning into an instruction that the client posts as you.

AI calls are bounded per script: one turn every five seconds, 100 requests per day, two concurrent requests, an 8,000-character prompt limit and a response limit capped at 8,192 tokens. A broken loop therefore cannot silently run up a large provider bill.

The assistant understands your IRC session

The in-app assistant can answer questions using live AndroidIRCX context:

  • which channels you joined
  • what happened in a channel
  • who said something and when
  • locally stored history
  • scripts already saved in the app
  • AndroidIRCX documentation

Read operations can happen as part of the answer. Actions that change IRC state, such as sending, joining or leaving, stop for explicit approval and show what is about to happen.

The assistant supports several persistent conversations. It can also remember short facts between conversations, but those memories are visible as individual entries in Settings. Each can be deleted, all memory can be cleared, and the feature can be disabled. This is intentionally different from an invisible profile that the user cannot inspect.

The assistant can list, read, lint and save scripts. It never enables a script after saving it, because enabling code is the point at which it begins reacting to real IRC traffic.

AI-assisted script creation and editing

The scripting editor now acts like a small mobile IDE. Its AI button understands whether the editor is empty or already contains code:

  • Write a new script turns a plain-language request into JavaScript.
  • Change this script sends the current script with the requested change and preserves the rest.

Generated code is shown for review and checked before use. It is never silently saved or enabled. Both AI generation and editor autocomplete read the same internal API vocabulary, including signatures and descriptions, so suggestions match the functions the installed app actually exposes.

The editor also gained improved syntax highlighting, reliable caret and scrolling behavior, signatures in autocomplete, linting, landscape-friendly controls and protection against replacing an existing script without confirmation.


A scripting API built for real IRC work

AndroidIRCX scripts are JavaScript modules that export event hooks. They can react to connection, message, channel, CTCP, action, highlight, command, timer and raw-protocol activity.

module.exports = {
  onMessage: msg => {
    if (api.strip(msg.text).includes('release')) {
      api.echo(msg.channel, 'Release keyword detected.');
    }
  },
};

The API covers far more than sending a line:

  • local output with api.echo, real messages, notices, CTCP and actions
  • registered slash commands and nick/channel/tab context-menu items
  • timers, sound, notifications, clipboard and composer text
  • IRC formatting and stripping formatting before matching
  • joins, parts, modes, op/voice, bans, topics, away state and WHOIS helpers
  • saved channels, auto-join, reactions, user activity and flood logs
  • recent-message and history search
  • network requests through the same approved-site policy used by the assistant
  • per-script key/value storage, named text lists, tables, secrets and files
  • signals for communication between scripts

The scripting work also fixes two important older gaps. onRaw is now actually wired and observes every IRC line in both directions, while getTheme() now includes the active color palette rather than only a theme name and light/dark flag.

Cached IRC knowledge instead of needless network traffic

New knowledge APIs expose information AndroidIRCX already has:

  • api.users.* for identities, accounts, masks and shared channels
  • api.channelState.* for topics, modes and cached ban/exception/invite/quiet lists
  • api.server.* for server information, capabilities and ISUPPORT tokens

This matters for automation. A script that sends WHOIS for every message will eventually be throttled; a script that reads the app's Internal Address List-style cache is faster and quieter.

Identity-aware examples also teach safer habits. The built-in Auto-Op example trusts a network account, with CertFP as a fallback, rather than trusting a nickname that another user could later claim.

Storage, files and structured data

The expanded platform gives each script or add-on its own namespace.

Tables support TTL values, atomic increment, compare-and-set and all-or-nothing batches. These operations avoid race conditions that appear when two event handlers read and update the same counter at once.

Private workspaces use relative paths, atomic writes and quotas. Helpers parse lines, JSON, RFC 4180 CSV and INI without crashing the script on malformed input. Secrets live in a separate Keychain namespace, never appear in exports and cannot reveal their values through enumeration.

When a script needs a user file, Android's document picker mediates access. The script does not invent an arbitrary filesystem path; the user selects the document and can revoke the grant.

UI extensions that still belong to the app

Scripts and add-ons can contribute menus, toolbar actions, badges, forms and custom panels. They provide declarative data, not React components or executable UI code.

That distinction keeps the resulting interface compatible with themes, font scaling, accessibility, phone rotation and tablet layouts. Semantic tones such as warning are preferred over hard-coded colors, and the app validates labels, image addresses and panel schemas before rendering them.


Packaged .ircx-addon files and permissions

The v1.10.0 Addon Platform introduces signed .ircx-addon packages. A package contains a strict manifest, JavaScript entry point, declared assets and an optional signature.

Nineteen capabilities describe what an add-on wants to do, including IRC reading, sending and moderation; history; tabs; UI; themes; storage; secrets; public or private networking; user-selected files; notifications; clipboard access and AI.

Permissions are rechecked on every call. Revoking a capability therefore takes effect immediately, without reinstalling the add-on. Sensitive expert capabilities such as outgoing raw-line modification and private-network access cannot be granted permanently and must be reconfirmed per session.

Imported packages run in a separate QuickJS context with memory, stack and execution limits and without Android, React Native, network, filesystem, timer or module-loader objects. Host functionality is exposed only through permission-checked operations.

Editor scripts are different: they are code the user wrote or pasted and run in the app's JavaScript context with dangerous globals shadowed. The wiki is deliberately candid that this is not the same isolation as the packaged add-on runtime. Treat pasted scripts like any other pasted code.

At the time of the v1.10.0 documentation, the native runtime compiles into the release build, but imported packages have not yet completed on-device validation. The same expanded API is already reachable from the in-app script editor. That status is important: the platform is substantial and unit-tested, but package import should not be presented as battle-tested until device testing is complete.

Raw IRC access without sacrificing the connection

Raw protocol access is split into safe observation and expert modification.

irc.raw.observe can inspect incoming and outgoing traffic. irc.raw.modify can rewrite outgoing lines only. Incoming protocol handling never waits for isolated JavaScript, because delaying a PING, capability negotiation or registration line could hang the connection.

Transport-critical commands such as PING, PONG, CAP, AUTHENTICATE, ERROR and PASS are protected. Command injection through CR/LF is refused, timeouts fall back to the original line, repeated failures disable the add-on, and reconnect-loop detection can disable the last registered modifier. Safe Mode can start AndroidIRCX with third-party add-ons disabled.

Trust, diagnostics and recovery

Package signatures prove continuity, not safety. A valid signature says an update came from the same signing key; it does not say the code is harmless. A changed or removed key requires acknowledgement, while an invalid signature is blocked.

Per-add-on diagnostics show event volume, execution time, the slowest hook, errors, timeouts, sends, network calls and storage use. Exported recovery logs avoid channel names, nicknames, hostmasks, URLs, paths and message text.

The platform also includes install review, permission diffs, update rollback, feature groups, conformance linting and examples that start disabled. A failed update does not delete the working installed copy.


MCP connects AndroidIRCX to other tools

Model Context Protocol support works in both directions.

As an MCP client, AndroidIRCX can give its assistant tools from an HTTP MCP server, such as a notes service, search index or ticket system. Remote tools ask before execution by default. A trusted server may declare a read-only tool, but that shortcut applies only after the user explicitly marks the server as trusted.

As an MCP server, AndroidIRCX can expose channels, users and history to an assistant on another device. Actions are off by default and, while disabled, send/join/leave tools are not advertised at all. The server can bind only to the phone, to the current local network, or to every interface. Each start generates a fresh bearer token.

AndroidIRCX supports Streamable HTTP rather than stdio. A server running in Termux can still be used over 127.0.0.1; a server on a PC can be reached over the local network.

One security correction is worth recording: the first v1.9.56 MCP server displayed a token but did not verify it. v1.10.0 verifies the bearer token on every request using constant-time comparison. Anyone who previously exposed the older server beyond loopback should treat it as having been open during that period.

Privacy is part of the feature, not a settings footnote

Cloud AI is disabled until the user gives consent. Channel data is separately opt-in per channel, with the default off, because other people in an IRC room did not consent simply because one user configured a provider.

Before an approved request leaves the device, AndroidIRCX can replace nicknames consistently with pseudonyms and strip IP addresses, hostmasks and email addresses. Nickname replacement is disabled when an assistant must operate tools, because a tool cannot send to a fictional user3; the other redaction remains active.

Allowed-site rules block loopback, private ranges, link-local and .local destinations. Redirect targets are checked again, preventing an allowed public address from redirecting the app into a private network. Fetched pages and channel messages are always treated as data, not instructions.

A master switch stops every AI call immediately without deleting provider configuration.


Why this matters for IRC

These features make AndroidIRCX more than a mobile chat window. A user can create a command, automate moderation, build a channel dashboard, search cached IRC state, summarize a conversation, use a local model, or connect a desktop assistant to the phone's IRC session.

Just as importantly, the platform draws visible boundaries. AI proposes before it posts. Add-ons declare capabilities. Secrets remain outside backups. Network access follows an allowlist. Risky raw access is temporary and recoverable. Generated scripts remain disabled until the user makes the final choice.

That is the right direction for programmable IRC on a phone: powerful enough for people who remember mIRC scripting, but designed around Android permissions, modern privacy expectations and recovery when an experiment goes wrong.

Learn more

AndroidIRCX keeps the classic IRC idea alive: the client should belong to the user, and advanced users should be able to make it their own.

Comments (0)

Log in to leave a comment

No comments yet. Be the first to comment!

Share this post

Found this helpful? Share it with others!

Back

Cookie Consent

We use cookies to enhance your browsing experience, analyze site traffic, and personalize content. By clicking "Accept", you consent to our use of cookies in accordance with our Privacy Policy and GDPR regulations. Learn more