Skip to main content

Ally AI

How to use

Config File

llm:
  api_key: '<private-key>'
  api_version: "<api-version>"
  endpoint: "<endpoint>"
  model: "<model-name>"
  deployment_name: '<deployment-name>'
  temperature: 0.7
  streaming: true

embeddings:
  api_key: '<private-key>'
  api_version: "<api-version>"
  endpoint: "<endpoint>"
  model: "<model-name>"
  deployment_name: '<deployment-name>'

Create LLM

Use Default Settings in LLM

from ally_ai.llamaindex import LLM

llm = LLM()
response = llm.invoke('What is an ally?')
print(response)

Use Custom Settings in LLM

my_llm:
  api_key: '<private-key>'
  api_version: "<api-version>"
from ally_ai.llamaindex import LLM, Settings

settings = Settings(section='my_llm')
llm = LLM(settings=settings)
print(llm.settings.path)
print(llm.settings.section)

Override Settings in LLM

from ally_ai.llamaindex import LLM, Settings

settings = Settings(section='my_llm', api_key='<new-api-key>')
llm = LLM(settings=settings)
response = llm.invoke('What is an ally?')
print(response)

How to Create Embeddings

from ally_ai.llamaindex import Embeddings

embeddings = Embeddings()
response = embeddings.embed_query('What is an ally?')
print(response)

Download files

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

Source Distribution

ally_ai_llamaindex-0.1.0.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

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

ally_ai_llamaindex-0.1.0-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file ally_ai_llamaindex-0.1.0.tar.gz.

File metadata

  • Download URL: ally_ai_llamaindex-0.1.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.10

File hashes

Hashes for ally_ai_llamaindex-0.1.0.tar.gz
Algorithm Hash digest
SHA256 af09d54e4e714e1d45a4504ba2706f5e3caf68cabe7cafb70d6441432a2e7567
MD5 4bef5c2c8b46ed0a843c9950095f74c7
BLAKE2b-256 83e68193697341be656c509501ca23fc129649ba1e465ac5d98ba89e807e2614

See more details on using hashes here.

File details

Details for the file ally_ai_llamaindex-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ally_ai_llamaindex-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e19f93f82f1da930ea7014ef92dc7ef3eb551cb5dbdd70888a4e5f19d350b139
MD5 b1da6e2a19c7c42e5b2471292a5df7b2
BLAKE2b-256 1ee3648f6f2ad0dbb77b63093b290d0cf05ccb801a5420bed05f558a2fd74e30

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

0.0.3

2 files

0.0.2

2 files

0.0.1

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page