OpenMaja Hobby project · Proof-of-concept under development

FolderBot

A sub-project of OpenMaja

FolderBot is a durable, resumable AI workspace built entirely on your Microsoft 365 tenant — no custom servers, no infrastructure to manage.

The problem

Copilot Studio conversations are ephemeral. After 30 minutes of inactivity, 60 minutes of total session duration, or 100 conversation turns, the session resets and context is lost.

FolderBot solves this by giving every session a persistent workspace backed by OneDrive for Business.

What FolderBot does

Every session gets its own folder in OneDrive containing the agent’s state, working memory, active plan, conversation log, and any files it creates. Close the browser, come back the next day, type /resume — and the agent picks up exactly where it left off.

FolderBot · Copilot Studio
Continue the Vendor Assessment from last week
FolderBot 📂 Resuming session 20260525-VendorAssessment
FolderBot
Session restored · Last active 6 days ago
Active plan: Vendor shortlist — step 2 of 4 complete
You were reviewing the compliance checklist.
What's left to do?
FolderBot Steps remaining: security review (3 vendors), final scoring matrix, executive summary. Starting the security review now…
FolderBot
✅ Security review complete.
Saved to your OneDrive: outputs/security-review.md 📄
Good. Rewrite it for exec audience — shorter, no technical jargon.
FolderBot

How it works

User (M365 Copilot / Teams / web)


FolderBot Orchestrator        ← routes sessions, enforces policy


FolderBot SessionBot          ← file operations, memory, plan, results

        ├──────────────────────────────────────┐
        ▼                                      ▼
Power Automate                         Local Runner (optional)
← OneDrive CRUD via M365 connectors    ← browser tab, runs JS tools on session files
        │                                      │
        └──────────────────┬───────────────────┘

               OneDrive for Business
               ← durable workspace (all session state lives here)

Key features

Session workspace

Each session is a folder in OneDrive:

FolderBot/
  SOUL.md                    ← global behavior rules (customize per tenant)
  tools/                     ← built-in JS tools (runner.html lives here too)
  user_tools/                ← your custom JS tools (optional)
  sessions/
    20260520-MyProject/
      state.json             ← authoritative session state
      memory.md              ← compact working memory
      plan.md                ← active task plan
      history.jsonl          ← full conversation log
      inputs/                ← user-supplied input files
      outputs/               ← agent-produced output files
      jobs/                  ← runner job queue (created on first RunJS call)

Components

ComponentTypeRequires
OrchestratorCopilot Studio agentCopilot Studio
SessionBotCopilot Studio agentCopilot Studio
PA Flows (×12)Power Automate cloud flowsPower Automate · OneDrive for Business connector
Local Runner (optional)Browser tab (tools/runner.html)Chrome or Edge · OneDrive sync client

Built-in JS tools (run via Local Runner)

ToolWhat it does
patchApply a unified diff to a session file
regex-replaceRegex find/replace with capture group support
fetch-apiHTTP fetch with optional origin allowlist
write-rootWrite a file to the FolderBot root — used to install new custom tools

Custom tools can be added to user_tools/ and are picked up by the runner automatically.

FolderBot does not require OpenMaja itself. It deploys entirely within standard M365 tooling using native connectors. The Local Runner is an optional enhancement — all core operations work via Power Automate alone.

Status

v0.2.0.0 — Core system feature-complete and tested end-to-end; Local Runner available as an optional extension.

Getting Started

Everything you need to deploy FolderBot in your M365 tenant is in the repository.

→ Get Started with openmaja-folderbot on GitHub