███╗ ███╗ ██████╗ ███████╗███████╗███████╗████████╗ ████╗ ████║██╔═══██╗██╔════╝██╔════╝██╔════╝╚══██╔══╝ ██╔████╔██║██║ ██║███████╗█████╗ █████╗ ██║ ██║╚██╔╝██║██║ ██║╚════██║██╔══╝ ██╔══╝ ██║ ██║ ╚═╝ ██║╚██████╔╝███████║██║ ███████╗ ██║ ╚═╝ ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚══════╝ ╚═╝
- Description
- Tech Stack
- AI Stack
- How it looks?
- Features
- Project Structure
- Commands
- How to run the project?
- License
- Author
Mosfet is an LLM-powered agent that you extend by adding Skills, Tools, MCP Servers, and Workflows. Each skill describes a capability or piece of knowledge the agent can draw on, tools let it take action, MCP servers connect it to external systems, and workflows chain these into a saved, repeatable procedure. The goal is to empower the LLM by simply dropping in more of these building blocks.
Status: early-stage / work in progress. A model-agnostic chat agent that reasons through multiple tool calls before answering, extending itself with skills and MCP servers along the way, with guardrails checking what goes in and out.
- Chat with the agent through your terminal or other communication channels.
- The agent can create skills for itself and reuse them whenever they apply.
- Save a multi-step procedure as a workflow, combining skills, tools, and other workflows, and run it again whenever you need it.
- Connect the agent to MCP servers so it can use their tools.
- The agent can work through multiple steps on its own before giving you a final answer.
- See what the agent is doing as it works, like loading a skill or calling a tool, instead of just watching a spinner.
- Safe, read-only actions run automatically, but the agent asks for your permission before doing anything else.
- Messages are checked for sensitive personal information before they reach the LLM and before a response reaches you.
- Point the agent at whichever LLM provider and model you want, hosted or local, and change it anytime.
- Install once and run the agent from anywhere on your machine.
- Chats pick up where you left off — each channel automatically resumes its last conversation.
.
src/
├── main.py # Entry point
├── llm.py # Guarded LLM entry point used by the agent loop
├── config_setup.py # Guided setup/update for provider config and credentials
├── update.py # Updates the local install to the latest release
├── core/ # Agent loop and skill/tool orchestration
├── adapters/ # Per-provider LLM and web-search adapters behind common interfaces
│ ├── llm_providers/
│ └── web_search_providers/
├── config/ # Provider selection, seed messages, and shared paths
├── extensions/ # Skills, tools, MCP servers, and workflows available to the agent
│ ├── mcp/
│ ├── skills/
│ ├── tools/
│ └── workflows/
├── guardrails/ # Content checks run on messages going into and out of the LLM
├── ui/ # Front-ends: terminal chat loop and Discord bot
└── utils/ # Shared helpers used across the codebase
scripts/
├── install.sh # Installs Mosfet into ~/.mosfet and adds `mosfet` to PATH
├── publish_docker_beta.sh # Builds and pushes the beta Docker image
└── restart_docker.sh # Restarts the local Mosfet container
Every option below runs the same commands, just with a different prefix in place of mosfet. The commands themselves:
Set up or update your provider, model, and web search provider, prompting for whichever credentials you need. Run it again anytime to change your setup. Rarely-changed settings like Ollama's server URL or Anthropic's response length cap live in src/config/advanced_providers.py if you ever need to adjust them.
mosfet configStart chatting. Defaults to the terminal.
mosfetStart chatting on Discord. Runs in the background by default so you don't need to keep a terminal open for it.
mosfet discord # start in the background
mosfet discord --foreground # attach to this terminal instead
mosfet discord --stop # stop a background botUpdate Mosfet to the latest release. Only works for the install-script setup below (Option 1); Docker installs update via docker compose pull && docker compose up -d instead.
mosfet updatebash <(curl -fsSL https://mosfet.shahtech.info)This clones the latest Mosfet release, sets up an isolated Python environment, and installs a mosfet command on your PATH. Once it finishes, run the commands in Commands as they are.
-
Clone the repo:
git clone git@github.com:busycaesar/Mosfet.git cd Mosfet -
Create a virtual environment and install dependencies:
python3 -m venv .venv source .venv/bin/activate pip install -r req.txt -
Run the commands in Commands, replacing
mosfetwithpython3 src/main.py, e.g.:python3 src/main.py config python3 src/main.py
-
Create a
docker-compose.ymlin the project directory:services: mosfet-app: image: busycaesar/mosfet:latest volumes: - ./mosfet.config.json:/app/mosfet.config.json - ./.env:/app/.env
-
Create
mosfet.config.jsonand.envin the same directory (an empty.envand amosfet.config.jsoncontaining{}are enough to start):echo '{}' > mosfet.config.json touch .env
-
Start the container:
docker compose up -d
-
Run the commands in Commands, prefixing
mosfetwithdocker compose exec -it mosfet-app, e.g.:docker compose exec -it mosfet-app mosfet config docker compose exec -it mosfet-app mosfet
mosfet.config.jsonand.envare bind-mounted, so anythingmosfet configwrites is saved straight back to those files in your project directory.