Why We Rebuilt Microsoft Office From Scratch for AI Agents - Yijia Liang, Compound AI
Key Takeaway
Rebuilding Office suite tools from scratch as headless, AI-native engines enables financial firms to delegate complex, multi-week deal workflows to autonomous agents.
Highlights
Rewriting Office from scratch required 1.5 trillion input/output tokens and over 8 million lines of code.
Recreating a performant Excel replica took 800,000 lines of Rust code.
Headless engines recalculate 20-megabyte Excel workbooks 4x faster than standard desktop applications.
Compound uses agent swarms to process data rooms containing over 15,000 files without relying solely on vector databases.
Transitioning from a data room to a fully prepared set of investment committee models, slides, and memos compresses a four-week process down to a few days.
Timeline
Challenges of Personal Agents in Institutional Finance
Background agents have advanced significantly for personal use cases like booking flights or tracking calendar events, but these capabilities do not directly translate to private equity or venture capital workflows. Deal teams operate under strict non-disclosure agreements and handle massive institutional data repositories. Solving this requires building real team collaboration, executing long tasks in parallel, and managing complex enterprise data.
- Personal agents succeed through reliable background tasks, proactivity, and integrations with personal context.
- Institutional finance requires compressing four-week analysis processes into a few days rather than simple background tasks.
- Managing directors prefer controlled input over rogue background agents burning tokens without supervision.
- Financial data involves petabytes of unstructured data across SharePoint and data rooms containing 15,000 files.
Multiplayer Collaboration and Email Integration
Deal execution relies heavily on team collaboration rather than isolated single-player workflows. By embedding agents directly into standard communication channels like Outlook threads, multiple deal team members share a unified context with the AI. Designing these email agents requires balancing strict security protocols with human-like interaction pacing to avoid disruptive message spam.
- Single-player AI tools used via plugins or web apps force users to manually download and upload files to collaborate.
- Every agent created in Compound includes a built-in inbox to integrate directly into Outlook email threads.
- Email agents require strict authentication and read-and-write access management to maintain strict confidentiality.
- Built-in response latency prevents automated agents from spamming fast-moving group email threads.
Rebuilding Microsoft Office for Headless Agent Execution
Standard desktop office applications tie execution speeds to local CPU constraints and lack the necessary programmatic hooks for iterative AI checking loops. Developing custom headless engines for Excel, PowerPoint, and Word allows agents to render, check, and fix formatting errors autonomously. This architecture supports rapid iteration, allowing five-person teams to review large slide decks in an afternoon instead of weeks.
- Desktop plugins, virtual machines, and off-the-shelf engines fail to scale for parallel financial modeling tasks.
- Rewriting Microsoft Office from scratch consumed 1.5 trillion tokens and 8 million lines of code.
- IronCalc served as the open-source foundation for creating a pixel-perfect, 800,000-line Rust replica of Excel.
- Headless engines execute 20-megabyte workbook recalculations 4x faster than standard desktop software.
Handling Breadth and Depth of Enterprise Data
Institutional data presents challenges in both breadth, such as 15,000-file data rooms, and depth, such as 30-megabyte financial models containing millions of formulas. Deploying coding agents in parallel swarms grounds every finding in verifiable source citations. Ultimately, robust backend infrastructure enables financial teams to trust AI outputs completely and scale deal evaluation capacity tenfold.
- Agent swarms read and analyze large file directories via grep and slice patterns instead of relying solely on vector databases.
- Custom Excel engines process 30-megabyte models faster and cheaper by exposing rich APIs directly to the agent.
- Financial professionals shift focus from manual data validation to imparting strategic judgment on deals.
- Adoption shifts from co-pilot assistance toward fully autonomous autopilot execution for complex financial workflows.
Description
Yijia Liang spent years as a finance analyst living in Excel and PowerPoint before founding Compound to build autonomous AI analysts for institutional investors. Personal agents took off because they run reliably in the background, act on their own and connect to your context, but finance needs more: multiplayer agents with their own inboxes that join deal-team email threads, a headless Office engine rebuilt from scratch with agents (1.5 trillion tokens and over 8 million lines of code) that runs work in parallel and checks its own formatting, and agent swarms that can work through data rooms of 15,000+ files. Chapters: 0:00 Intro 0:52 Why personal agents took off 1:34 Why that breaks in finance 3:12 Multiplayer agents 4:10 An inbox for every agent 5:28 Why off-the-shelf Office tools fall short 6:04 Rebuilding Office from scratch 7:38 Why headless is faster 8:21 Comments and collaboration 9:08 Write, render, check, fix 9:55 Huge data rooms and models 13:10 From copilot to autopilot 15:09 Wrap-up Yijia Liang https://getcompound.ai Join us in SF for the second annual AIE CODE summit: https://aie.codes our last flagship summit of 2026. Applications live now!
