Observed since 21 Oct, 09:49 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
This python package help to interact with Generative AI - Large Language Models. It interacts with AIaaS LLM , AIaaS embedding , AIaaS Audio set of APIs to cater the request.
AIaaS_Falcon is Generative AI - LLM library interacts with different model api endpoints., allowing operations such as listing models, creating embeddings, and generating text based on certain configurations. AIaaS_Falcon helps to invoking the RAG pipeline in seconds.
Ensure you have the requests and google-api-core libraries installed:
pip install aiaas-falcon
if you want to install from source
git clone https://github.com/Praveengovianalytics/AIaaS_falcon && cd AIaaS_falcon
pip install -e .
Falcon Class__init__ (config)
Intialise the Falcon object with endpoint configs.
Parameter:
current_active()
Check current endpoint active
add_endpoint(api_name,protocol,host_name_port,api_endpoint,api_key,use_pil=False)
Add a new endpoint.
Parameter:
list_endpoint()
List out all endpoints in the endpoint management manager
set_endpoint(name)
Set target endpoint to active
Parameter:
remove_endpoint(name)
Delete endpoint by name
Parameter:
current_pii()
Check current Personal Identifier Information Protection activation status
switch_pii()
Switch current Personal Identifier Information Protection activation status
list_models()
List out models available
initalise_pii()
Download and intialise PII Protection.
Note: This does not activate PII but initialise dependencies
health()
Check health of current endpoint
create_embedding(file_path)
Create embeddings by sending files to the API.
Parameter:
generate_text_full(query="", context="", use_file=0, model="", chat_history=[], max_new_tokens: int = 200, temperature: float = 0, top_k: int = -1, frequency_penalty: int = 0, repetition_penalty: int = 1, presence_penalty: float = 0, fetch_k=100000, select_k=4, api_version='2023-05-15', guardrail={'jailbreak': False, 'moderation': False}, custom_guardrail=None)
Generate text using LLM endpoint. Note: Some parameter of the endpoint is endpoint-specific.
Parameter:
create_embedding before use. list_models to check for model available.use_file is 1use_file is 1 evaluate_parameter(config)
Carry out grid search for parameter
Parameter:
decrypt_hash(encrypted_data)
Decret the configuration from experiment id.
Parameter:
from aiaas_falcon import Falcon
model=Falcon(api_name="azure_1",protocol='https',host_name_port='example.com',api_key='API_KEY',api_endpoint='azure',log_key="KEY")
model.list_models()
model.generate_text_full(query="Hello, introduce yourself",model='gpt-35-turbo-0613-vanilla',api_version='2023-05-15')
AIaaS_Falcon library simplifies interactions with the LLM API's, providing a straightforward way to perform various operations such as listing models, creating embeddings, and generating text.
Download counts and popularity will appear here as the collector receives them.
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 0.2.2 | 4 Jan 2024 | 8 |
This describes our collected data; it is not a security assessment.
Observed since 21 Oct, 09:49 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:b88e98a2957d4b8a67f51e92971d1177f5a111be1e9cf270fafbca6c455a4a09