Deploy pipelines
Deploy your pipelines to Neum AI Cloud
Neum AI provides a managed cloud enviornment to run and manage your pipelines. It offers capabilities like pipeline management, run scheduling, automatic synchronization as well as a high scale distributed architecture to run large jobs. Learn more about the difference between Local and Cloud enviornments for Neum AI.
Test pipeline locally
Before we deploy the pipeline to Neum AI Cloud, lets run a quick local test to make sure things are working as expected.
Validate
Run a local validation of the pipeline
print("Pipeline validation successful? " + pipeline.validate())
Test pipeline
Run a test to make sure the pipeline runs smoothly end to end
result = pipeline.run()
info = pipeline.sink.info()
print("Vectors written in pipeline run: " + result)
print(info)
Test search
Finally, lets test the stored vectors
results = pipeline.search(query="What are the challenges with scaling RAG?", number_of_results=3)
for result in results:
print(result.metadata)
Deploy pipeline to Neum AI Cloud
To deploy the pipeline, we will leverage the built-in functions.
from neumai.Client.NeumClient import NeumClient
neumClient = NeumClient(api_key = '<INSERT NEUMAI API KEY>')
neumClient.create_pipeline(pipeline=pipeline)
Once deployed, you can go to Neum AI Cloud dashboard to see the status and pipeline information. Alternatively, you can programmatically query:
Get pipeline information
from neumai.Client.NeumClient import NeumClient
neumClient = NeumClient(api_key = '<INSERT NEUMAI API KEY>')
neumClient.get_pipeline(pipeline_id='<pipeline_id from above>')
Search pipeline
from neumai.Client.NeumClient import NeumClient
neumClient = NeumClient(api_key = '<INSERT NEUMAI API KEY>')
neumClient.search_pipeline(pipeline_id='<pipeline_id from above>', query=<search query>)
Was this page helpful?