Inspiration

AI agents are becoming powerful, but their memory is still trapped inside individual chats, tools, and sessions.

In real business work, important knowledge is scattered across many places: project documents, design files, WBS sheets, customer inquiries, material test results, budgets, issue lists, and delivery evidence. When a new project starts, teams often need to re-read the same files again, and AI agents cannot easily carry context from one project to another.

We built Safe Memory Platform to solve this problem: turning business knowledge into portable, secure, reusable memory assets for AI agents.

What it does

Safe Memory Platform converts documents and department data into portable Safe Memory Packs.

A Safe Memory Pack is a policy-aware Business IQ file, stored as .smp.json. It can contain source text, embeddings, classification labels, provenance, policy flags, and a tamper-evident hash-chain ledger.

Agents can build, import, query, verify, export, and reuse these packs across different interfaces:

  • Web UI for drag-and-drop upload
  • ChatGPT Custom Actions via OpenAPI
  • Claude through a Remote MCP connector
  • Qwen-powered workflows through the backend

This means one project folder can become one reusable memory pack, and that pack can be reused by another project later.

Demo scenario

For the hackathon demo, we created a product-development scenario.

First, we prepared historical project and department data:

  • ALPHA: a retail AI concierge reference project
  • BETA: a smart factory quality and inspection reference project
  • GAMMA: a finance planning memory workspace reference project
  • DEPT: customer inquiries, material test results, and budget information
  • New Sportswear Program Brief: launch assumptions for the AeroFlex Urban Runner Jacket

Each group of files was converted into a Safe Memory Pack and stored in the server vault.

Then, when a new sportswear product-development program started, the agent reused these packs to generate a launch-ready project plan for the AeroFlex Urban Runner Jacket.

The final output included:

  • Executive summary
  • MVP scope
  • Alibaba Cloud + Qwen Cloud architecture
  • WBS and milestones
  • Budget allocation
  • Material and quality risks
  • Customer FAQ priorities
  • Launch readiness checklist
  • Human approval checkpoints

This shows that Safe Memory Packs are not just file summaries. They are reusable memory assets that can support real project decisions across departments.

How we built it

Safe Memory Platform runs on Alibaba Cloud.

The backend is deployed on Alibaba Cloud ECS in the Singapore region using Docker Compose. Caddy provides automatic HTTPS for the public domain https://smp.sdesigner.tokyo.

The backend is built with Python, FastAPI, Uvicorn, and Pydantic. It exposes multiple access paths:

  • REST API for Web UI and API clients
  • OpenAPI schema for ChatGPT Custom Actions
  • Remote MCP endpoint for Claude
  • One-time upload links for keyless user uploads

Qwen Cloud is the core AI engine. The platform uses Qwen Cloud through the DashScope-compatible OpenAI-style API.

Qwen Cloud is used for:

  • Text embeddings with text-embedding-v4
  • Confidentiality classification
  • Reasoning
  • Answer generation
  • Safe memory exchange decisions

Alibaba OSS is used for temporary pack handoff when enabled. Generated packs can be shared through stable download URLs, while OSS signed URLs remain hidden behind the server-side delivery flow.

The platform does not require an external vector database. Embeddings are stored inside each .smp.json pack, and search is performed through hybrid retrieval using cosine similarity and keyword matching.

Architecture

Safe Memory Platform has five main layers:

  1. Agent and client layer
    Web UI, ChatGPT Actions, Claude MCP, and one-time upload links.

  2. Edge and runtime layer
    Alibaba Cloud ECS, Docker Compose, Caddy HTTPS, and route dispatching.

  3. Application layer
    FastAPI backend, REST API, MCP server, Memory Forge, Memory Lens, Memory Workspace, policy engine, ledger, and job retention.

  4. AI and delivery services
    Qwen Cloud for embeddings, classification, reasoning, and answer generation. Alibaba OSS for secure temporary pack delivery.

  5. Local-first storage
    Safe Memory Packs are stored as .smp.json files under the server vault. Each pack is portable, verifiable, and reusable.

Key features

  • Convert many project files into one portable Safe Memory Pack
  • Store embeddings and policy metadata inside the pack
  • Query packs without an external vector database
  • Verify pack integrity with a hash-chain ledger
  • Prevent SECRET entries from being sent to external LLMs
  • Reuse the same pack across GPT, Claude, Web UI, and Qwen-powered workflows
  • Use one-time upload links so end users do not need to handle API keys
  • Support server-vault retention for long-term reusable memory

Challenges we ran into

One major challenge was that LLM tools cannot reliably transfer raw file bytes. GPT Actions and remote MCP tools are mainly JSON and text interfaces, and they have timeout and payload limitations.

We solved this by treating URLs as the exchange layer for knowledge. Instead of trying to pass large files through the LLM, Safe Memory Platform hosts memory packs and lets agents import them by reference.

Another challenge was SharePoint and OneDrive folder links. Anonymous folder links often return an HTML shell instead of real file bytes, so we added clear fallback flows using the Web upload page and one-time upload links.

We also had to make the system robust for live demos. If a Qwen API call fails or a model quota changes, the backend can fall back to deterministic embeddings and safe heuristic classification, so the workflow does not break.

We also implemented a native Remote MCP endpoint for Claude while keeping the existing OpenAPI Actions for GPT unchanged. This required careful routing so that /mcp could work without breaking streaming behavior.

Accomplishments

We built a live production system, not just a slide prototype.

Safe Memory Platform is running at:

https://smp.sdesigner.tokyo

The system supports:

  • Web upload
  • ChatGPT Custom Actions
  • Claude Remote MCP
  • Safe Memory Pack creation
  • Pack query
  • Pack import by URL
  • Pack export
  • Ledger verification
  • Server-vault retention
  • One-time upload links
  • Alibaba Cloud deployment
  • Qwen Cloud integration

In the demo, we successfully created and verified multiple memory packs, then reused them to generate a launch-ready product-development plan for a new sportswear product.

What we learned

We learned that agent memory should not be treated only as chat history.

For business use, memory needs to be portable, policy-aware, verifiable, and reusable across tools. It also needs to respect security boundaries: sensitive information should not be blindly sent to an external model.

We also learned that interoperability matters. The same memory asset should be usable from different agent interfaces, including GPT Actions, Claude MCP, Web UI, and Qwen-powered workflows.

What's next

Next, we want to expand Safe Memory Platform in several directions:

  • Larger enterprise folder ingestion
  • Better pack lineage visualization
  • More detailed access-control policies
  • Pack-to-pack dependency tracking
  • Local MCP support for desktop file workflows
  • Team-based memory governance
  • More Qwen-powered reasoning workflows
  • Marketplace-style exchange of reusable Business IQ packs

Our long-term vision is to make Safe Memory Packs a standard unit of reusable business knowledge for AI agents.

Why it matters

Safe Memory Platform turns scattered business files into portable, secure, reusable Business IQ.

A project can be captured once, verified once, and reused many times.

This helps AI agents move beyond isolated conversations and become reliable collaborators that can carry business context across sessions, departments, tools, and projects.

Built With

  • actions
  • agents
  • ai
  • alibaba
  • api
  • cybersecurity
  • docker
  • ecs
  • embeddings
  • fastapi
  • knowledge
  • management
  • mcp
  • memory
  • openapi
  • oss
  • pydantic
  • python
  • qwen
  • rag
  • rest
  • uvicorn
  • vector
Share this project:

Updates