Skip to content

Latest commit

 

History

History
43 lines (34 loc) · 1.24 KB

README.md

File metadata and controls

43 lines (34 loc) · 1.24 KB

Context Python SDK

⚡ Python SDK for accessing the Context API

How to use it

Instantiate the SDK

from context import ContextSdk, ContextSdkConfig

sdk = ContextSdk(
    ContextSdkConfig(
        api_key="", # your API key
    )
)

Search for documents/snippets

bot_id = "k7rB5_3JT"
query = "How can I get started with Helius?"
top_k = 1
result = self.sdk.search(bot_id, query, top_k)

print(result) # will be a list of snippets