GPT Address API (GPTAAPI) for Naruno
GPTAAPI is a decentralized API for OpenAI GPT. It allows you to use GPT without exposing your API key to the public. It is based on the Naruno blockchain and uses the Naruno API to communicate with the blockchain. GPTAAPI is written in Python and uses the OpenAI GPT-3 API to communicate with GPT.
Features
- Decentralized system
- Secure communication between nodes
- Fast and easy to use
- Secure point for GPT API's
- Uses encryption to protect sensitive information
Installation
You can install GPTAAPI by pip3:
pip3 install gpt_address_api
Usage
*If you want to use gpt_address_api you must to use Naruno. For now please checkout the Baklava Testnet.
Getting address of client and server:
narunocli -pw
Server
For accessing your gpt api on blockchain you should create a gpt_address_api, giving trusted user addresses and api_key.
from gpt_address_api import gptaapi
my_gptaapi_server = gptaapi("MyNarunoPass")
my_gptaapi_server.set_encrypt_key("mystrongencrypt_key")
my_gptaapi_server.set_api_key("my_open_ai_api_key")
my_gptaapi_server.add_user("client_address")
my_gptaapi_server.run()
also you can use in command line:
gptaapi --password MyNarunoPass --encrypt_key "mystrongencrypt_key" --trusted_users ["client_address"] --api_key my_open_ai_api_key run
Client
To use gptaapi, you can call the gptaapi.ask function with your blockchain address, message and encryption key as the parameter:
from gpt_address_api import gptaapi
my_gptaapi_client = gptaapi("MyNarunoPass")
response = my_gptaapi_client.ask("server_address", "Hello gpt, how are you", "mystrongencrypt_key")
print(response)
my_gptaapi_client.close()
also you can use in command line:
gptaapi --password "MyNarunoPass" ask "server_address" "Hello gpt, how are you" "mystrongencrypt_key"
This will return the response of gpt result.
Contributing
Contributions to gptaapi are welcome! If you have any suggestions or find a bug, please open an issue on the GitHub repository. If you want to contribute code, please fork the repository and create a pull request.
License
gptaapi is released under the MPL-2.0 License.
Metadata
Release files for gpt-address-api 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 | |
|---|---|---|---|---|
| gpt_address_api-0.1.1.tar.gz | 8.7 kB | Without provenance | Details |
Release files / gpt_address_api-0.1.1.tar.gz
| Download URL | gpt_address_api-0.1.1.tar.gz |
|---|---|
| Size | 8.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7544a89683a0e003d6ffd38365d89a48ffe2ed291604c711649dcc0012b3eda1
|
|
BLAKE2b-256 checksum How to use checksums |
65737aff97895dc70f7ba0fcc61305be0bd419617e4b0a284cdc64d448816e54
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.16
|
Security for gpt-address-api 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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A 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.