ClawLearn is an AI tutor that adapts to how a student learns, explains concepts, generates quizzes, and tracks progress. The entire app natively bridges a custom Node.js (Express) backend serving OpenClaw agents to OpenWebUI for a fluid user experience.
- LLM: Ollama Cloud (
ollama/kimi-k2.5:cloud) - Agents: OpenClaw Gateway (
openclaw gateway) running locally along with definedagents.yamltools. - Backend: Node.js (Express) routing custom logic to OpenClaw via
npxchild processes - Storage: SQLite3 via
sqlite3driver - UI: OpenWebUI
To set up and run ClawLearn on your machine, simply follow these steps:
-
Start the Docker Containers Initialize the system and securely pass your Ollama cloud API key and Discord credentials by starting the Docker Compose stack:
OLLAMA_API_KEY="your_api_key_here" DISCORD_TOKEN="your_token" DISCORD_CHANNEL_ID="your_channel_id" docker compose up -d --build
-
Onboard the OpenClaw Daemon Local Package The background Node.js daemon requires an interactive setup wizard to initialize its memory system. Since the daemon is now installed locally via your project's
package.json, you must run this once:docker exec -it clawlearn-backend npx openclaw onboard(Follow the prompts on your screen! OpenClaw will configure your local models. Since we use
kimi-k2.5:cloud, it will prompt you if it is missing. Make sure when asked for the Ollama URL, you MUST explicitly specifyhttp://ollama:11434instead of the local 127.0.0.1 default so it can resolve through the container proxy network!) -
Access the Application
- OpenWebUI: Open http://localhost:3000 in your browser. (Note: The OpenWebUI container can take 1-3 minutes to become fully available on the first boot as it initializes its database. If it is not working immediately, please wait a minute or run
docker compose logs -f openwebuito check its progress.)
- OpenWebUI: Open http://localhost:3000 in your browser. (Note: The OpenWebUI container can take 1-3 minutes to become fully available on the first boot as it initializes its database. If it is not working immediately, please wait a minute or run
OpenWebUI is directly hooked up to the Node.js Express backend API via standard OpenAI connections to seamlessly serve agents. When you chat:
-
Select one of the injected ClawLearn models in the top-left corner of OpenWebUI:
claw-tutor-agent: Adapts dynamically as a Personal Tutor to simplify and explain concepts.claw-quiz-generator: Provide a topic in your prompt, and it generates 10 multi-choice questions. After submission, it calculates a percentage score and stores the record in SQL.grade-evaluator(Background): Operates autonomously using OpenClaw Heartbeat. Every 5 minutes, it checks the SQLite database for new quiz results, assigns grades (A-F), and sends notifications via Discord. It also handles interactive feedback in the chat.
-
The UI natively talks to the Express service (
localhost:8000/v1/chat/completions). -
Behind the scenes, the Express.js server leverages the official
openclawlocal module natively via Nodechild_process.exechooks to contact the local API Gateway and seamlessly orchestrate your request across memory-enabled agents!
The integration of the OpenClaw framework drastically reduced the backend complexity of ClawLearn by abstracting away the heavy lifting of LLM orchestration.
- Declarative Agent Workspaces: Instead of manually passing messy, repetitive system prompts to an LLM script for every single contextual request across the application, OpenClaw helped by declaratively define isolated, specialized agents (like the
tutor-agent,quiz-generator, andgrade-evaluator) in organized workspace configuration folders (agent.yaml). This permanently maps their persistent personas natively! - Native Tool Calling & Cloud Logic: OpenClaw handles the ingestion of complex tool directives (such as the initialized
web_searchand the built-indiscordskill) and properly routes logic over cloud-hosted protocols out of the box. This completely decoupled those burdens from the Node.js Express wrappers! - Dedicated Daemon Memory: By delegating distinct agent states to the headless OpenClaw Gateway Daemon running locally in the background, conversational memory persistence and workspace session histories are automatically tracked by the agent runtime network instead of bloating our native SQLite database or application routing layers!
