Chordian Knowledge Memory for LangChain
langchain-chordian-knowledge-memory provides LangChain tools for Chordian's Memory REST API. It is separate from the Memory MCP client and from Chordian's platform Search API for people and companies.
Chordian Knowledge Memory unifies documents, entities, relationships, vector embeddings, provenance, and temporal history in one multi-model store. The search tool retrieves across these knowledge forms with hybrid search, while LangChain remains in control of agent orchestration.
What it provides
chordian_memory_searchperforms hybrid search across the configured knowledge memory.chordian_memory_savewrites text and metadata to memory.chordian_memory_get_entityexplores an entity in the memory graph.
Search and save use the documented Memory API endpoints. Platform Search API functions are intentionally out of scope for this package.
Requirements
- Python 3.11 or newer.
- A Chordian Memory API endpoint, such as
https://acme-1045.api.chordian.ai. - A Memory key (
mk_...) or an authorized OAuth access token. Platform keys (ck_...) are not supported here. - HTTPS for remote endpoints. Plain HTTP is permitted only for loopback testing.
The Memory key is sent in the Authorization: Bearer header. It is never placed in a URL, tool argument, or returned result. Chordian also documents value-level PII masking and hybrid post-quantum TLS key exchange (X25519 + ML-KEM-768); this package does not configure those platform controls.
Install and configure
Install the package from PyPI:
python -m pip install langchain-chordian-knowledge-memory
Set the endpoint and key in the environment, or pass them directly to create_memory_tools:
export CHORDIAN_MEMORY_ENDPOINT="https://acme-1045.api.chordian.ai"
read -r -s -p 'Chordian Memory key: ' CHORDIAN_MEMORY_API_KEY
export CHORDIAN_MEMORY_API_KEY
PowerShell:
$env:CHORDIAN_MEMORY_ENDPOINT = "https://acme-1045.api.chordian.ai"
$secret = Read-Host 'Chordian Memory key' -AsSecureString
$env:CHORDIAN_MEMORY_API_KEY = [System.Net.NetworkCredential]::new('', $secret).Password
Remove-Variable secret
Do not commit real keys or paste them into prompts. Use a least-privilege Memory key and an approved expiration.
Use the tools
from langchain_chordian_knowledge_memory import create_memory_tools
tools = create_memory_tools()
Use the returned tools with a LangChain agent, or call one directly:
search = next(tool for tool in tools if tool.name == "chordian_memory_search")
answer = await search.ainvoke({"query": "What is our refund window?", "top_k": 5})
chordian_memory_save changes stored data. Agents may call it if it is included in their tool list; review tool permissions and calls. Memory search results are returned to the calling application and may be sent to its model provider.
Optional default scopes can be fixed when constructing tools:
tools = create_memory_tools(vault="Sales", space="spc_123")
Individual search/save calls may also provide vault or space to select a scope.
API behavior
The tools follow the Chordian Python SDK contract:
- Hybrid search:
POST /api/v1/memory/search, withquery,limit, andtop_k. - Save:
POST /api/v1/memory/ingest, with content, metadata, and routing. - Entity lookup:
GET /api/v1/memory/graph/explore/{entity_id}, withdepth.
The platform Search API for company and people search is a separate API with a different host and key. It will be handled separately.
Test and build
python -m pip install -e ".[test]" ruff build
python -m pytest -q
ruff check .
python -m build
Tests use a local fake HTTP server. They do not call a live Chordian tenant or require a real key.
Source and license
The Memory API contract is documented in the Chordian Python SDK. This candidate uses MIT licensing, matching that repository's license.
Metadata
Release files for langchain-chordian-knowledge-memory 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| langchain_chordian_knowledge_memory-0.1.1.tar.gz | 8.7 kB | With provenance | Details for langchain_chordian_knowledge_memory-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| langchain_chordian_knowledge_memory-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for langchain_chordian_knowledge_memory-0.1.1-py3-none-any.whl |
Total release size: 15.5 kB
Release files / langchain_chordian_knowledge_memory-0.1.1.tar.gz
| Download URL | langchain_chordian_knowledge_memory-0.1.1.tar.gz |
|---|---|
| Size | 8.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b5efc68bade1ba5c1f38b7f897e31d3b0dd1f416be0a1540f5e0751decc2eceb
|
|
BLAKE2b-256 checksum How to use checksums |
07a4415807d599bb579509c488e5cb41f7ead065b853c72bfbf3f2a6ee1dabf4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 4, 2026.
Transparency logRelease files / langchain_chordian_knowledge_memory-0.1.1-py3-none-any.whl
| Download URL | langchain_chordian_knowledge_memory-0.1.1-py3-none-any.whl |
|---|---|
| Size | 6.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8baa627dac69d8870828ce4f4e9e307a9e942cad8dfac4ab847c3f770956f02c
|
|
BLAKE2b-256 checksum How to use checksums |
1ad576ba0e3234a5732e3d10dbb0260f2079242c32d18453eabbe6ccb0bb4267
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 4, 2026.
Transparency logSecurity for langchain-chordian-knowledge-memory 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for langchain_chordian_knowledge_memory-0.1.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 4, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.