Website Β· Documentation Β· Quickstart Β· API Reference Β· Changelog Β· Discord Β· Report a Bug
Build production LLM apps with 2 dependencies. Async-native RAG, Agents, and Graph workflows β no magic, no SaaS, no bloat.
"LangChain for people who hate LangChain."
SynapseKit is the minimal, async-first Python framework for LLM applications. 33 providers Β· 48+ tools Β· 64 loaders Β· 22 vector stores. Every abstraction is plain Python you can read, debug, and extend. No hidden chains. No global state. No lock-in.
β‘ Async-nativeEvery API isasync/await first.Sync wrappers for scripts and notebooks. No event loop surprises. |
π Streaming-firstToken-level streaming is the default,not an afterthought. Works across all providers. |
πͺΆ Minimal footprint2 hard dependencies:numpy + rank-bm25.Everything else is optional. Install only what you use. |
π One interface33 LLM providers and 22 vector storesbehind the same API. Swap without rewriting. |
π§© ComposableRAG pipelines, agents, and graph nodesare interchangeable. Wrap anything as anything. |
π TransparentNo hidden chains.Every step is plain Python you can read and override. |
10-Line Agent Example
from synapsekit import agent, tool
@tool
def get_weather(city: str) -> str:
"""Get current weather for a city."""
return f"Sunny, 22Β°C in {city}"
my_agent = agent(
model="gpt-4o-mini",
api_key="sk-...",
tools=[get_weather],
)
print(my_agent.run("What's the weather in Tokyo?"))
SynapseKit vs LangChain vs LlamaIndex
| SynapseKit | LangChain | LlamaIndex | |
|---|---|---|---|
| Hard dependencies | 2 | 50+ | 20+ |
| Install size | ~5 MB | ~200 MB+ | ~100 MB+ |
| Async-native | β Default | β οΈ Partial | β οΈ Partial |
| Streaming | β Default | β οΈ Varies | β οΈ Varies |
| Cost tracking | β Built-in | β LangSmith (SaaS) | β No |
| Evaluation / EvalCI | β CLI + GitHub Action | β LangSmith (SaaS) | β οΈ Built-in |
| Graph workflows | β Built-in | β οΈ LangGraph (separate pkg) | β No |
| Agent federation | β Built-in | β No | β No |
| Reasoning LLMs | β Unified adapter | β οΈ Manual | β οΈ Manual |
| Structured output | β Provider-agnostic | β οΈ Provider-specific | β οΈ Provider-specific |
| Agent memory backends | β 4 built-in | β οΈ Community plugins | β οΈ Community plugins |
| Observability | β Prometheus + Grafana | β No | β No |
| Type safety | β Strict dataclasses | β οΈ Partial | β οΈ Partial |
| LLM providers | 33 | 38+ | 20+ |
| Stack traces | Your code | Framework internals | Framework internals |
| License | Apache 2.0 | MIT | MIT |
LangChain has more raw integrations and more tutorials. That's not what SynapseKit is optimizing for. SynapseKit is optimizing for the engineer who needs to ship, debug, and maintain an LLM feature in production β where readable code, predictable async behavior, and no surprise SaaS bills actually matter.
Who is it for?
SynapseKit is for Python developers who want to ship LLM features without fighting their framework.
- Burned LangChain users β hit a wall with debugging, dependency hell, or version churn and want full control back
- Async backend engineers β building FastAPI services where LangChain's sync-first model feels bolted on
- Cost-conscious teams β startups and teams who don't want a LangSmith subscription for basic observability
- ML engineers β building RAG or agent pipelines who need full control over retrieval, prompting, and tool use
What it covers
|
π RAG Pipelines |
π€ Agents |
|
π Graph Workflows |
π§ LLM Providers |
|
π Vector Stores |
π§ Utilities |
|
π§ Reasoning LLMs (new in v1.7.0) |
βοΈ Cost-Quality Routing (new in v1.7.0) |
|
π― Prompt Optimization (new in v1.7.0) |
π Federated Retrieval (new in v1.7.0) |
|
π§ Smart Context Manager (new) |
β
Structured Output (new) |
|
πΈ Agent Federation (new) |
π Continuous Fine-Tuning Pipeline (new) |
|
β‘ Performance suite (new in v1.7.0) |
|
|
π§ͺ EvalCI β LLM Quality Gates |
|
|
π Agent Benchmarking π§ͺ EvalHub Community Suites |
|
ReasoningAgent (automatic routing)
import asyncio
from synapsekit import ReasoningAgent, ReasoningAgentConfig
from synapsekit.agents.tools import CalculatorTool
from synapsekit.llm import LLMConfig, OpenAILLM, ReasoningLLM
fast = OpenAILLM(
LLMConfig(model="gpt-4o-mini", api_key="sk-...", provider="openai")
)
reasoning = ReasoningLLM(model="o3", api_key="sk-...")
agent = ReasoningAgent(
ReasoningAgentConfig(
fast_llm=fast,
reasoning_llm=reasoning,
tools=[CalculatorTool()],
agent_type="function_calling",
)
)
async def main():
answer = await agent.run("Solve: find the eigenvalues of [[2,1],[1,2]]")
print(answer)
asyncio.run(main())
EvalHub quick usage
synapsekit bench --list
synapsekit bench --suite community/customer-support --model gpt-4o-mini
synapsekit bench --publish my_evals/ --name myorg/rag-finance
Docs: docs/evalhub.md
Integrations
One interface. 190+ integrations. Zero lock-in.
| π§ LLM Providers | π Vector Stores | π Data Loaders | π§ Agent Tools |
|---|---|---|---|
| 33 | 22 | 64 | 48+ |
Every integration is pip install synapsekit[name] β nothing else. Swap providers, vector stores, or loaders without touching your application code.
Icons use Google Favicons for reliability across light and dark themes.
π§ LLM Providers β 33 supported
Every provider implements the same
BaseLLMinterface. Auto-detected from model name βgpt-4oβ OpenAI,claude-*β Anthropic,gemini-*β Google. Swap without rewriting.
OpenAI |
Anthropic |
Gemini |
Azure OpenAI |
AWS Bedrock |
Vertex AI |
Mistral |
Cohere |
Groq |
Hugging Face |
Cloudflare |
Databricks |
Perplexity |
Replicate |
xAI (Grok) |
Baidu ERNIE |
DeepSeek |
Ollama |
Together AI |
OpenRouter |
Fireworks AI |
Cerebras |
SambaNova |
NovitaAI |
Writer |
AI21 Labs |
Aleph Alpha |
Minimax |
Moonshot |
Zhipu |
LM Studio |
llama.cpp |
vLLM |
GPT4All |
π Vector Stores β 22 backends
All implement
VectorStorewithadd(),search(),search_mmr(),save(), andload(). Built-inInMemoryVectorStoreneeds zero extra deps. Everything else ispip install synapsekit[name].
ChromaDB |
FAISS |
Qdrant |
Pinecone |
Weaviate |
Milvus |
LanceDB |
PGVector |
SQLiteVec |
MongoDB Atlas |
Redis |
Elasticsearch |
OpenSearch |
Supabase |
Cassandra |
DuckDB |
ClickHouse |
Marqo |
Typesense |
Vespa |
Zilliz |
π Data Loaders β 64 sources
All return
list[Document]with.textand.metadata. Every loader has a sync.load()and async.aload(). Load from disk, cloud, databases, or APIs β same interface everywhere.
File Formats
Word (DOCX) |
Excel (XLSX) |
PowerPoint |
HTML / XML |
Markdown |
LaTeX |
YAML / JSON |
|
Parquet |
Audio (Whisper) |
Video |
RSS / Sitemap |
Git Repo |
Cloud Storage
AWS S3 |
Google Drive |
Azure Blob |
OneDrive |
Dropbox |
Google Cloud |
Databases
PostgreSQL |
MySQL |
MongoDB |
DynamoDB |
Elasticsearch |
Redis |
BigQuery |
Snowflake |
SQLite |
Supabase |
APIs & Productivity
GitHub |
Jira |
Confluence |
Notion |
Slack |
Discord |
HubSpot |
Salesforce |
Airtable |
YouTube |
Wikipedia |
Obsidian |
Google Sheets |
Firebase |
Twilio |
|
arXiv |
PubMed |
Email (IMAP) |
π§ Agent Tools β 48+ built-in
All implement
BaseToolwith a single asyncrun(). Pass any list of tools toReActAgentorFunctionCallingAgent. Write your own in 5 lines.
DuckDuckGo |
Google Search |
Tavily |
Wolfram Alpha |
Wikipedia |
YouTube |
arXiv |
PubMed |
Slack |
Discord |
GitHub API |
Jira |
Notion |
Linear |
Stripe |
Twilio |
Google Calendar |
AWS Lambda |
Browser (Playwright) |
SQL Query |
Python REPL |
Shell |
π§ Memory & Cache Backends
SQLite |
Redis |
PostgreSQL |
DynamoDB |
Memcached |
π‘ Observability
OpenTelemetry |
Prometheus |
Grafana |
PrometheusMetrics records synapsekit_cost_usd_total, synapsekit_tokens_total, and synapsekit_latency_seconds per model/provider. Hooks into the existing observe span pipeline β no code changes needed. Helm chart for a Prometheus + Grafana stack ships in assets/helm/synapsekit-observability/. pip install synapsekit[observe].
Multi-Hop Knowledge Graph RAG
SynapseKit provides advanced retrieval modules, including vector search and multi-hop Knowledge Graph (KG) retrieval.
When to use which?
- Vector Search (Semantic): Best for broad conceptual queries, finding similar passages, or answering questions whose answers are contained within a single chunk of text.
- Knowledge Graph (KG): Best for specific, multi-hop reasoning questions where the relationship spans across multiple documents (e.g., finding out who owns the parent company of a subsidiary).
- Hybrid (Vector + KG): Combining both strategies guarantees that you capture deep semantic context while also exploring explicitly extracted entity relationships. Initialize the
RAGfacade withgraph_store=NetworkXStore()orNeo4jStore(...)to enable this out-of-the-box.
Production RAG ROI
from synapsekit import RAG, RAGEvaluator, SlackWebhookAlertSink
from synapsekit.cli.ui_server import create_app
rag = RAG(
model="gpt-4o-mini",
api_key="sk-...",
evaluator=RAGEvaluator(
judge_llm=judge_llm, # a cheaper judge model
sample_rate=0.1,
alert_sinks=[SlackWebhookAlertSink(webhook_url=SLACK_WEBHOOK_URL)],
),
)
app = create_app(tracer=rag.tracer, rag_evaluator=rag.evaluator)
answer = await rag.ask("What changed in the release notes?")
await rag.wait_for_evaluations()
metrics = rag.tracer.summary()
print(metrics["avg_rag_benefit_to_cost"])
print(metrics["total_rag_alerts"])
Don't see your stack?
Every integration is built the same way β most take under an hour.
Browse good first issue β Β· Contributing guide β Β· Discord β
We credit every contributor in the README and send a personal thank-you on Discord.
Install
pip
pip install synapsekit[openai] # OpenAI
pip install synapsekit[anthropic] # Anthropic + prompt caching
pip install synapsekit[ollama] # Ollama (local)
pip install synapsekit[performance] # orjson + uvloop + xxhash (faster)
pip install synapsekit[observe] # OpenTelemetry + Prometheus metrics
pip install synapsekit[training] # Continuous fine-tuning pipeline
pip install synapsekit[bench] # pytest-benchmark + ASV harness
pip install synapsekit[redis] # Redis agent registry + memory backends
pip install synapsekit[all] # Everything
uv
uv add synapsekit[openai]
uv add synapsekit[all]
Poetry
poetry add synapsekit[openai]
poetry add "synapsekit[all]"
Full installation options β docs
Observability guide β docs/observability.md
Documentation
Everything you need to get started and go deep is in the docs.
| π Quickstart | Up and running in 5 minutes |
| π RAG | Pipelines, loaders, retrieval, vector stores |
| π€ Agents | ReAct, function calling, tools, executor |
| π Graph Workflows | DAG pipelines, conditional routing, parallel execution |
| π§ LLM Providers | All 33 providers + ReasoningLLM with examples |
| π§ͺ EvalCI | LLM quality gates on every PR β GitHub Action |
| π API Reference | Full class and method reference |
Development
git clone https://github.com/SynapseKit/SynapseKit
cd SynapseKit
uv sync --group dev
uv run pytest tests/ -q
Contributing
Contributions are welcome β bug reports, documentation fixes, new providers, new features.
Read CONTRIBUTING.md to get started. Look for issues tagged good first issue if you're new.
Community
- π¬ Discord β chat, help, show and tell
- π¬ Discussions β ask questions, share ideas
- π§ Discord roles draft β proposed roles and permissions for issue #389
- π§ Discord release webhook draft β automate release announcements for issue #390
- π Bug reports
- π‘ Feature requests
- π Security policy