Skip to main content

Build system for agent memory

Project description

Synix logo

 ███████╗██╗   ██╗███╗   ██╗██╗██╗  ██╗
 ██╔════╝╚██╗ ██╔╝████╗  ██║██║╚██╗██╔╝
 ███████╗ ╚████╔╝ ██╔██╗ ██║██║ ╚███╔╝
 ╚════██║  ╚██╔╝  ██║╚██╗██║██║ ██╔██╗
 ███████║   ██║   ██║ ╚████║██║██╔╝ ██╗
 ╚══════╝   ╚═╝   ╚═╝  ╚═══╝╚═╝╚═╝  ╚═╝

A build system for agent memory.

The Problem

Agent memory hasn't converged. Mem0, Letta, Zep, LangMem — each bakes in a different architecture because the right one depends on your domain and changes as your agent evolves. Most systems force you to commit to a schema early. Changing your approach means migrations or starting over.

What Synix Does

Conversations are sources. Prompts are build rules. Summaries and world models are artifacts. Declare your memory architecture in Python, build it, then change it — only affected layers rebuild. Trace any artifact back through the dependency graph to its source conversation.

uvx synix build pipeline.py
uvx synix search "return policy"
uvx synix validate                # experimental

Quick Start

uvx synix init my-project
cd my-project

Add your API key (see pipeline.py for provider config), then build:

uvx synix build

Browse, search, and validate:

uvx synix list                    # all artifacts, grouped by layer
uvx synix show final-report       # render an artifact
uvx synix search "hiking"         # full-text search
uvx synix validate                # run declared validators (experimental)

Defining a Pipeline

A pipeline is a Python file. Layers are real objects with dependencies expressed as object references.

# pipeline.py
from synix import Pipeline, Source, SearchIndex
from synix.ext import MapSynthesis, ReduceSynthesis

pipeline = Pipeline("my-pipeline")
pipeline.source_dir = "./sources"
pipeline.build_dir = "./build"
pipeline.llm_config = {
    "provider": "anthropic",
    "model": "claude-haiku-4-5-20251001",
    "temperature": 0.3,
    "max_tokens": 1024,
}

# Parse source files
bios = Source("bios", dir="./sources/bios")

# 1:1 — apply a prompt to each input
work_styles = MapSynthesis(
    "work_styles",
    depends_on=[bios],
    prompt="Infer this person's work style in 2-3 sentences:\n\n{artifact}",
    artifact_type="work_style",
)

# N:1 — combine all inputs into one output
report = ReduceSynthesis(
    "report",
    depends_on=[work_styles],
    prompt="Write a team analysis from these profiles:\n\n{artifacts}",
    label="team-report",
    artifact_type="report",
)

pipeline.add(bios, work_styles, report)
pipeline.add(SearchIndex("search", sources=[work_styles, report], search=["fulltext"]))

This is a complete, working pipeline. uvx synix build pipeline.py runs it.

For the full pipeline API, built-in transforms, validators, and advanced patterns, see docs/pipeline-api.md.

Configurable Transforms (synix.ext)

Most LLM steps follow one of four patterns. The synix.ext module provides configurable transforms for each — no custom classes needed.

from synix.ext import MapSynthesis, GroupSynthesis, ReduceSynthesis, FoldSynthesis
Transform Pattern Use when...
MapSynthesis 1:1 Each input gets its own LLM call
GroupSynthesis N:M Group inputs by a metadata key, one output per group
ReduceSynthesis N:1 All inputs become a single output
FoldSynthesis N:1 sequential Accumulate through inputs one at a time

All four take a prompt string with placeholders like {artifact}, {artifacts}, {group_key}, {accumulated}. Changing the prompt automatically invalidates the cache.

For full parameter reference and examples of each, see docs/pipeline-api.md#configurable-transforms.

When you need logic beyond prompt templating — filtering, conditional branching, multi-step chains — write a custom Transform subclass.

Built-in Transforms

Pre-built transforms for common agent memory patterns. Import from synix.transforms:

Class What it does
EpisodeSummary 1 transcript → 1 episode summary
MonthlyRollup Group episodes by month, synthesize each
TopicalRollup Group episodes by user-defined topics
CoreSynthesis All rollups → single core memory document
Merge Group artifacts by content similarity (Jaccard)

CLI Reference

Command What it does
uvx synix init <name> Scaffold a new project with sources, pipeline, and README
uvx synix build Run the pipeline. Only rebuilds what changed
uvx synix plan Dry-run — show what would build without running transforms
uvx synix plan --explain-cache Plan with inline cache decision reasons
uvx synix list [layer] List all artifacts, optionally filtered by layer
uvx synix show <id> Display an artifact. Resolves by label or ID prefix. --raw for JSON
uvx synix search <query> Full-text search. --mode hybrid for semantic
uvx synix validate (Experimental) Run validators against build artifacts
uvx synix fix (Experimental) LLM-assisted repair of violations
uvx synix lineage <id> Show the full provenance chain for an artifact
uvx synix clean Delete the build directory
uvx synix batch-build run (Experimental) Submit a batch build via OpenAI Batch API

Key Capabilities

Incremental rebuilds — Change a prompt or add new sources. Only downstream artifacts reprocess.

Full provenance — Every artifact chains back to the source conversations that produced it. uvx synix lineage <id> shows the full tree.

Fingerprint-based caching — Build fingerprints capture inputs, prompts, model config, and transform source code. Change any component and only affected artifacts rebuild. See docs/cache-semantics.md.

Altitude-aware search — Query across episode summaries, rollups, or core memory. Drill into provenance from any result.

Architecture evolution — Swap monthly rollups for topic-based clustering. Transcripts and episodes stay cached. No migration scripts.

Where Synix Fits

Mem0 Letta Zep LangMem Synix
Approach API-first memory store Agent-managed memory Temporal knowledge graph Taxonomy-driven memory Build system with pipelines
Incremental rebuilds Yes
Provenance tracking Full chain to source
Architecture changes Migration Migration Migration Migration Rebuild
Schema Fixed Fixed Fixed Fixed You define it

Synix is not a memory store. It's the build system that produces one.

Learn More

Doc Contents
Pipeline API Full Python API — ext transforms, built-in transforms, projections, validators, custom transforms
Entity Model Artifact identity, storage format, cache logic
Cache Semantics Rebuild trigger matrix, fingerprint scheme
Batch Build (Experimental) OpenAI Batch API for 50% cost reduction
CLI UX Output formatting, color scheme

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

synix-0.12.1.tar.gz (3.7 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

synix-0.12.1-py3-none-any.whl (246.7 kB view details)

Uploaded Python 3

File details

Details for the file synix-0.12.1.tar.gz.

File metadata

  • Download URL: synix-0.12.1.tar.gz
  • Upload date:
  • Size: 3.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for synix-0.12.1.tar.gz
Algorithm Hash digest
SHA256 73d24f28c870243a377631baa3fba4c06b2a55775705779e53ab6ab813adec1b
MD5 bfb8e5d950578ce2e31bf0a625df2fb1
BLAKE2b-256 7a1f5d7ba1dbb4f4bcab5761ef30871bdbb004a608076f962dfcda907b6f615d

See more details on using hashes here.

Provenance

The following attestation bundles were made for synix-0.12.1.tar.gz:

Publisher: release.yml on marklubin/synix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file synix-0.12.1-py3-none-any.whl.

File metadata

  • Download URL: synix-0.12.1-py3-none-any.whl
  • Upload date:
  • Size: 246.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for synix-0.12.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2a5a39d4cc46dc7167819b5be7ff41bad71230881e4207a86a335a81c99256d6
MD5 12b0e0127cd7d0e400c7d4aa0f6fcf25
BLAKE2b-256 be275c950059fc2d7bcd3858ed7d95cff40d40fe28e864d12976619be38ba477

See more details on using hashes here.

Provenance

The following attestation bundles were made for synix-0.12.1-py3-none-any.whl:

Publisher: release.yml on marklubin/synix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page