Skip to main content

Python client for the Mantium API

Project description

Mantium Client

Mantium logo CI status PyPI License

A Python client library for Mantium services.

Prerequisites

Before you start working with this client, there are a few steps you need to complete. These prerequisites will help ensure that you can seamlessly interact with Mantium's functionalities.

1. Request Beta Access

Firstly, you need to sign up for beta access. Visit the Mantium Beta Signup page, fill in the necessary details, and submit your form to request beta access. Once your request has been approved, you'll be granted access to create an account and explore Mantium's extensive range of features.

2. Create an Application

After creating an account and logging in, your next step is to create an application. Mantium offers a variety of pre-made templates to simplify this process. For example, you might choose the Recipe Management template.

When you create an application from a pre-made template, two key steps will occur:

  1. You will upload files or connect to a data source such as Notion or Slack. This is where the application will pull content from.
  2. The content provided by you will be pre-processed, vectorized, and then stored in a Redis vector database.

After performing these steps, you can engage with your data in a meaningful way through the application you've just created.

3. Enable API Access

From your dashboard or main menu, locate and click on the User Profile section.

Within your user profile, there's an option to enable Python Client Access. This step is vital as it unlocks the interface that the client will use to communicate with your application:

User Profile Navigation

4. Client ID and Client Secret

Upon enabling API access, Mantium will present a Client ID and Client Secret. These unique identifiers authenticate your client's requests to the Mantium application. Please record them carefully. You will need to use them with the MantiumClient, as shown in the Usage section below.

Installation

Use the package manager pip to install this client.

pip install mantium-client

Usage

from mantium_spec.api.applications_api import ApplicationsApi
from mantium_client.api_client import MantiumClient

client = MantiumClient(client_id=client_id, client_secret=client_secret)
apps_api = ApplicationsApi(client)

# returns a list of applications
apps_api.list_applications()

# returns an application's details
apps_api.get_application_detail(application_id)

# query an application
query_request = {'query': 'What should I have for dinner tonight?'}
return apps_api.query_application(application_id, query_request)

License

Apache-2.0

Development

This is only necessary if you want to develop in this project.

We use poetry for dependency management.

pip install poetry
poetry install --with dev,test --verbose

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

mantium_client-0.1.5.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

mantium_client-0.1.5-py3-none-any.whl (11.5 kB view details)

Uploaded Python 3

File details

Details for the file mantium_client-0.1.5.tar.gz.

File metadata

  • Download URL: mantium_client-0.1.5.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for mantium_client-0.1.5.tar.gz
Algorithm Hash digest
SHA256 d9e9ffe8093a0c58b74cd47c650fd6b216a43081d81a32e92ea14eac42a02b6c
MD5 6f9c5ef5b46ad220b3d132ee6ee76e27
BLAKE2b-256 579b174f3635ae3697d24bb0d46a4ccd77c8215a09cce9d233d1af68a1511715

See more details on using hashes here.

File details

Details for the file mantium_client-0.1.5-py3-none-any.whl.

File metadata

File hashes

Hashes for mantium_client-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 e3c4a752a25be658b9c31a883b804b4fca718e170d0c7a3e0c3f7d3c6064bf0a
MD5 7539de5ef448c6e2f7c011ac5b781662
BLAKE2b-256 363996ff3fafbac91f1d04df95b03ba738f807ea6499e1db741f914b65a2d800

See more details on using hashes here.

Supported by

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