Skip to main content

Memory Fields

Memory Fields is a Python client for interacting with the SenTech AI Memory API, enabling users to add, query, and manage memory fields efficiently.

Installation

You can install the package using pip:

pip install memory-fields

Usage

Import and Initialize the Client**

from memoryfields import EMFClient

# Replace 'your_api_key' with a valid API key
client = EMFClient(api_key="your_api_key")

Add Memory to a Field**

response = client.add_memory(
    field_id="12345",
    content="This is a test memory.",
    timestamp=1700000000
)
print(response)

Query Memories**

results = client.query_memory(field_id="12345", query="What do I remember?")
print(results)

Query with an Image**

image_results = client.query_image(field_id="12345", image_path="sample.jpg")
print(image_results)

API Methods

Method Description
add_memory(field_id, content, timestamp, relevance=1.0, decay_rate=0.01, salience=1.0) Adds a memory to a specified field.
query_memory(field_id, query, top_k=50, depth_k=3) Searches a field for relevant memories based on a text query.
query_image(field_id, query=None, image_path=None, top_k=50) Performs a combined query using text and an optional image.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

Contact

For support or inquiries, reach out via GitHub Issues. or email us at service@sentech.ai

Release files for memoryfields 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for memoryfields 0.1.1
File Size Uploaded
memoryfields-0.1.1.tar.gz 3.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for memoryfields 0.1.1
File Interpreter ABI Platform
memoryfields-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 6.8 kB

Release files / memoryfields-0.1.1.tar.gz

Download URL memoryfields-0.1.1.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
98895723909a24e81278710d6bc40f11baaef95f6799778366d7ad1efe90b767
BLAKE2b-256 checksum
How to use checksums
92f0546e3e9933cd637790d779d5bc53e65bc2ba67c51b3eea4d6a9bf2b8f1ab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.11.0rc2

Release files / memoryfields-0.1.1-py3-none-any.whl

Download URL memoryfields-0.1.1-py3-none-any.whl
Size 3.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
227de83d168ea7eceee16d7a5f2ec563fcde3a9efc4e50cb22d9bcae0768a303
BLAKE2b-256 checksum
How to use checksums
170bd46a35df547e87a81a32487ff2791d862998b53e9f681b0a4a306e7ea0b1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.11.0rc2

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page