Skip to main content

Nuant Quantitative System SDK

Project description

Getting Started

Nuant Quantitative System SDK is a purpose-built SDK for decentralized finance. It enables a unified lifecycle that supports research, protocol-level simulation, backtesting, optimization, and live monitoring. Designed to empower quants, researchers, and developers, NQS makes it easy to experiment, iterate, and bring DeFi protocols and strategies from concept to execution.

This repository is the public endpoint for the nqs-sdk package, available on PyPI, providing all the tools needed to build, test, and run strategies within a single, integrated environment.

Prerequisites

Before installing the NQS SDK, ensure you have:

  • Python 3.12 (currently supported version; more versions coming soon)
  • pip package manager

Installation

Install the NQS SDK using pip:

pip install nqs-sdk

Note: This installation will also include several other packages provided by Nuant.

Environment Configuration

Get your API key from

https://agents.nuant.ai/subscribe

This following command creates a nuant-quantlib.toml file with the required proxy configuration for accessing Nuant’s GraphQL API. Make sure to replace YOUR_API_KEY.

(
echo "[proxy]"
echo 'url = "https://data.app.nuant.com/graphql"'
echo 'api-key = "YOUR_API_KEY" # <- the one, you got previously'
) > nuant-quantlib.toml

Then, export it as an environment variable:

export QUANTLIB_CONFIG=/path/to/nuant-quantlib.toml

Verify Installation

First, verify that the installation was successful:

import nqs_sdk
print(f"NQS SDK version: {nqs_sdk.__version__}")

Quick Start

Basic Use Case

Here’s a simple example to get you started with the NQS SDK:

import nqs_sdk.preload  # noqa: F401 # should be always on top
from nqs_sdk import Simulation
from nqs_sdk.protocols import UniswapV3
import json

# Initialize simulation with protocols and configuration
# You can use the example config or create your own with create_config.py
uniswap_v3 = UniswapV3Factory() # factory for all UniswapV3 instances
sim = Simulation([uniswap_v3], "./examples/configs/basic_config.yml")

# Run the simulation
all_observables_str = sim.run() # this intermediate step will be fixed soon
all_observables = json.loads(all_observables_str)

# Access results
print(f"Simulation completed with {len(all_observables)} observables")

Getting Involved

Now that you have the NQS SDK installed and understand the basics, you might want to:

Known issues and roadmap

Coming soon:

  • API stabilisation
  • API examples with arbitrageur or other multi-agents scenarios

And later:

  • Compound V2 support, more protocols will follow

  • Open Rust API to extend core interfaces directly in Rust

  • API for external data provider

    (currently the NQS SDK uses quantlib and data.app.nuant.com for data handling)

  • EVM based any protocol executions

Known issues:

  • Support of Python 3.11 and 3.13
  • Support of Linux arm64

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

nqs_sdk-0.6.3-cp312-cp312-win_amd64.whl (12.0 MB view details)

Uploaded CPython 3.12Windows x86-64

nqs_sdk-0.6.3-cp312-cp312-manylinux_2_28_x86_64.whl (14.0 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

nqs_sdk-0.6.3-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl (22.6 MB view details)

Uploaded CPython 3.12macOS 10.12+ universal2 (ARM64, x86-64)macOS 10.12+ x86-64macOS 11.0+ ARM64

File details

Details for the file nqs_sdk-0.6.3-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: nqs_sdk-0.6.3-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 12.0 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for nqs_sdk-0.6.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 a4357ee0b46a2938cff2a60f594012a009b21482ef47f17223ae3a97cf9a064b
MD5 583ea449942717ba9cc7974e1c66b67c
BLAKE2b-256 6f976e6ed94031b14f43dc14ddd5d0e1fdc44fe9210d83dfe7ffcc0068cb9aba

See more details on using hashes here.

File details

Details for the file nqs_sdk-0.6.3-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for nqs_sdk-0.6.3-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 e841f0c153b49a85683346846a65a53a468cf5033f5eb638788fbcacaff30ec2
MD5 9f04259d97bcf11c8ed7fde15618b50f
BLAKE2b-256 ca85646371e4e2f12c3fd48ac18475903e06608fc526429d6753b1e86b727db7

See more details on using hashes here.

File details

Details for the file nqs_sdk-0.6.3-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl.

File metadata

File hashes

Hashes for nqs_sdk-0.6.3-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm Hash digest
SHA256 b306d54cd84933b8c91a5ef66e6742b6495ed47fa017b1c069edf4f183b70744
MD5 9c6e17de5af654ada6b7a340d3e00a57
BLAKE2b-256 b39ca5847d4be0cb5477e5a43d3b75abc06a1a1d755ab404aeb492076b7bdac0

See more details on using hashes here.

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