feat: openai manifold

This commit is contained in:
Timothy J. Baek
2024-06-02 16:56:35 -07:00
parent c19f52bd7b
commit e024afc81c
3 changed files with 138 additions and 1 deletions

14
main.py
View File

@@ -506,6 +506,13 @@ async def filter_inlet(pipeline_id: str, form_data: FilterForm):
detail=f"Filter {pipeline_id} not found",
)
try:
pipeline = app.state.PIPELINES[form_data.body["model"]]
if pipeline["type"] == "manifold":
pipeline_id = pipeline_id.split(".")[0]
except:
pass
pipeline = PIPELINE_MODULES[pipeline_id]
try:
@@ -531,6 +538,13 @@ async def filter_outlet(pipeline_id: str, form_data: FilterForm):
detail=f"Filter {pipeline_id} not found",
)
try:
pipeline = app.state.PIPELINES[form_data.body["model"]]
if pipeline["type"] == "manifold":
pipeline_id = pipeline_id.split(".")[0]
except:
pass
pipeline = PIPELINE_MODULES[pipeline_id]
try: