npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

modai-protocol

v1.6.2

Published

Modular AI protocol - works on any endpoint

Readme

Modai

Modai is a modern, TypeScript-powered framework that enables large language models (LLMs) to interact with the real world via extendable "tools"—like running shell commands or reading files. Designed for safety, flexibility, and developer delight.


✨ Features

  • Multi-provider LLM support: OpenAI, Claude, Ollama, and custom endpoints.
  • Pluggable, secure tools: Run system commands, access the filesystem, automate anything.
  • Protocol-driven: All interactions flow through a predictable JSON protocol for tool use.
  • Easy extension: Add your own tools or providers with simple base classes.
  • Contextual awareness: Seamlessly pipes tool results into LLM conversations.
  • Built in TypeScript: Type safety out-of-the-box, ready for Node.js or via CLI.

📦 Installation & Setup

Method 1: NPM (recommended)

pnpm i -g modai-framework # or npm. also no need for -g (--global) if you want it to be project-level.

done. lol..

Method 2: Clone the repository and install dependencies

git clone https://github.com/neoapps-dev/modai.git
cd modai
pnpm install   # or: npm install   # choose your package manager

Build the TypeScript project:

pnpm run build  # or: npm run build

You can now use Modai via CLI or import it in local projects using:

import { Modai } from "./src";

(Adjust the import path depending on where/how you use the framework.)


🚀 Quick Start

import { Modai } from "./src";

const modai = new Modai({
  provider: "openai", // Also supports "claude", "ollama", "custom"
  apiKey: "YOUR_API_KEY", // Needed for OpenAI/Claude
  model: "gpt-4.1", // Model selection
  // Optionally add: baseUrl, name, etc
});

// Chat with an LLM agent
const response = await modai.chat("List files in the current directory.");

// (Optional) Automatically extract and run any tool requests:
const toolResults = await modai.extractAndExecuteTools(response);

for (const { tool, result } of toolResults) {
  if (result.success) {
    console.log(`> ${tool}:`, result.data);
  }
}

// Or: Directly invoke a tool (scripting/programmatic use)
const execResult = await modai.processRequest({
  protocol: "modai",
  tool: "exec",
  arguments: { command: "ls -la" },
});
console.log(execResult.data.stdout);

🛠️ Core Tools

  • exec — Run system shell commands (with output capture)
  • file — Read, write, and list files/folders
  • registry — Utility for plugin/tool loading

🤖 Supported LLM Providers

  • OpenAI (ChatGPT, GPT-4)
  • Anthropic Claude
  • Ollama (local open-source models)
  • Custom: Point to any compatible LLM API

🧩 Extending Modai

To add a new provider:

  • Implement a provider in src/providers/ extending BaseProvider

To add a new tool:

  • Create a file in src/tools/, extending BaseTool
  • Register it in your config

Example: Custom Tool

this. Can be installed via /install neoapps-dev/modai-echo or ask the LLM to install it :)


💡 Example Use Cases

  • AI developer agents (automate code, DevOps, builds, refactoring)
  • Smart LLM-driven automation on local or cloud systems
  • Chatbots with tool-use and access to real data
  • Autonomous research, writing, document analysis

🤝 Contributing

PRs, feedback, and issues welcome!

  • Fork, branch, modify, and submit a Pull Request
  • Describe your changes, tests appreciated!

📄 License

MIT License

Made with ❤️ and TypeScript by @neoapps-dev