SmartMemory
Guides

Shipping Lite inside an app

What to settle before you distribute SmartMemory Lite inside a product, from the license to the update check, a key-free build, bundle size and packaging.

SmartMemory Lite runs in your own process with a SQLite graph and local vectors, so it can ship inside a desktop app, a game or a local tool. This page collects the decisions in one place. Each section links to the page that holds the detail.

1. License

A commercial product that includes the Lite runtime needs a Lite Redistribution Agreement. It is a one-page agreement, free during early access and below the revenue threshold it states. A free, non-commercial application does not need one. Read Licensing, complete the form there, and keep the PDF copy we email you. Your publisher or legal team will want to read it before you ship.

The people who use your application never need a license from us.

2. Turn off the update check for your shipped build

On first use in a process, Lite asks the SmartMemory API once whether a newer version exists. The request carries a random install id, versions, platform and the request IP address, so a shipped app would send it from every user's machine. Decide whether you want that. To turn it off, set one of these in the environment of the process that runs SmartMemory:

SMARTMEMORY_NO_UPDATE_CHECK=1
# or
DO_NOT_TRACK=1

After you sign the agreement, you can set SMARTMEMORY_LICENSE_KEY so installs are attributed to it. The key only attributes installs and unlocks nothing, and it is never read when the update check is off. See Update check and install counts.

3. Build without an LLM key

You do not need a provider key to run Lite. Force the no-LLM profile so behavior does not depend on what is in the user's environment:

from smartmemory.tools.factory import create_lite_memory
from smartmemory.pipeline.config import PipelineConfig

memory = create_lite_memory(
    data_dir=save_slot_dir,
    pipeline_profile=PipelineConfig.lite(llm_enabled=False),
)

Entities still come from pattern matching and spaCy NER, without LLM relation extraction. See Lite mode.

Do not ship a provider key inside your app. Also keep other providers' keys out of the process environment. create_lite_memory does not pin the embedding provider, so a provider key that appears after you ingested can switch the embedder and make semantic search return nothing. Set the local embedding provider in setup and keep it.

4. One data directory per store

data_dir holds the whole store. Use one directory per save slot, per user or per project, and delete the directory to delete that memory. The default is ~/.smartmemory. To keep an application's memory out of that shared location, always pass data_dir.

5. Plan for the model download

Lite uses a spaCy model (en_core_web_sm) and a local embedding model. In our onboarding test the two came to roughly 115 MB (about 15 MB and about 100 MB) and were downloaded on first run. Decide whether your installer bundles them or your app downloads them on first launch. PipelineConfig.lite_hermetic() refuses to download the spaCy model and raises an error if it is missing, which is the right choice when the model must come from your bundle. See Hermetic variant.

6. Packaging as one executable

Not tested. We have not verified that a Python process using SmartMemory freezes into a single executable with PyInstaller or a similar tool. Lite loads compiled modules, spaCy models and a local embedding model, and each of those can need explicit handling in a freezer. If you need one executable, test a frozen build early and tell us what you find at help@smartmemory.ai. Until it is tested, the supported way to ship is a Python environment or a sidecar process that you install alongside your app.

Search by metadata

If you keep several characters, users or projects in one store, tag each memory with metadata and filter on it at search time, instead of running one store per tag. See Filtering by metadata.

On this page