Build AI methods with your coding agent, then run them anywhere: as an MCP for chatbots, as a webapp for people, or via API for your software.
migrate test pipelines and base library
Louis Choquel9b8628191e40
diff --git a/pipelex/cli/commands/migrate_cmd.py b/pipelex/cli/commands/migrate_cmd.pyindex 4d191bba4..ff395993d 100644--- a/pipelex/cli/commands/migrate_cmd.py+++ b/pipelex/cli/commands/migrate_cmd.py@@ -115,6 +115,6 @@ def migrate_cmd(),] = "./pipelex_libraries",dry_run: Annotated[bool, typer.Option("--dry-run", help="Preview changes without applying them")] = False,- backups: Annotated[bool, typer.Option("--backups/--no-backups", help="Create backup files before migration")] = True,+ backups: Annotated[bool, typer.Option("--backups/--no-backups", help="Create backup files before migration")] = False,) -> None:do_migrate(target_path=target_path, dry_run=dry_run, backups=backups)diff --git a/pipelex/libraries/pipelines/documents.toml b/pipelex/libraries/pipelines/documents.tomlindex 77fdfd536..c3826d8ad 100644--- a/pipelex/libraries/pipelines/documents.toml+++ b/pipelex/libraries/pipelines/documents.toml@@ -11,14 +11,16 @@ TextAndImagesContent = "A content that comprises text and images where the text# It can be named however you want# but it must be either an image or a pdf or a concept which refines one of them[pipe.ocr_page_contents_from_pdf]-PipeOcr = "Extract page contents from a PDF document"+type = "PipeOcr"+definition = "Extract page contents from a PDF document"inputs = { ocr_input = "PDF" }output = "Page"page_images = truepage_views = false[pipe.ocr_page_contents_and_views_from_pdf]-PipeOcr = "Extract page contents from a PDF document as well as full page views"+type = "PipeOcr"+definition = "Extract page contents from a PDF document as well as full page views"inputs = { ocr_input = "PDF" }output = "Page"page_images = truediff --git a/pipelex/libraries/pipelines/images.toml b/pipelex/libraries/pipelines/images.tomlindex f708d0e89..9d4197279 100644--- a/pipelex/libraries/pipelines/images.toml+++ b/pipelex/libraries/pipelines/images.toml@@ -20,7 +20,8 @@ refines = "Image"#################################################################[pipe.describe_image]-PipeLLM = "Describe an image"+type = "PipeLLM"+definition = "Describe an image"inputs = { image = "Image" }output = "VisualDescription"system_prompt = "You are a very good observer."@@ -30,7 +31,8 @@ Describe the provided image in great detail."""[pipe.describe_photo]-PipeLLM = "Describe a photo"+type = "PipeLLM"+definition = "Describe a photo"inputs = { photo = "Photo" }output = "VisualDescription"system_prompt = "You are a very good observer."@@ -48,14 +50,16 @@ Describe the provided photo and how it was shot: scene, lighting, camera, etc.# It can be named however you want,# but it must be either an ImgGenPrompt or a concept which refines ImgGenPrompt[pipe.generate_image]-PipeImgGen = "Generate an image"+type = "PipeImgGen"+definition = "Generate an image"inputs = { prompt = "ImgGenPrompt" }output = "Image"nb_steps = 2[pipe.generate_photo]-PipeImgGen = "Generate a photo"+type = "PipeImgGen"+definition = "Generate a photo"inputs = { prompt = "ImgGenPrompt" }output = "images.Photo"nb_steps = 8diff --git a/pipelex/libraries/pipelines/meta/meta_pipeline.toml b/pipelex/libraries/pipelines/meta/meta_pipeline.tomlindex 2ce797cfc..3d09717a3 100644--- a/pipelex/libraries/pipelines/meta/meta_pipeline.toml+++ b/pipelex/libraries/pipelines/meta/meta_pipeline.toml@@ -9,7 +9,8 @@ PipeBlueprint = "Details enabling to create a pipe"[pipe][pipe.generate_pipeline_blueprint]-PipeLLM = "Generate a PipelineLibraryBlueprint from natural language requirements"+type = "PipeLLM"+definition = "Generate a PipelineLibraryBlueprint from natural language requirements"inputs = { requirements = "Text" }output = "PipelineLibraryBlueprint"structuring_method = "preliminary_text"diff --git a/tests/test_pipelines/discord_newsletter.toml b/tests/test_pipelines/discord_newsletter.tomlindex 600f6c780..eb84f8682 100644--- a/tests/test_pipelines/discord_newsletter.toml+++ b/tests/test_pipelines/discord_newsletter.toml@@ -7,7 +7,8 @@ ChannelSummary = "A summarized Discord channel for newsletter inclusion"Newsletter = "The final newsletter content with organized channel summaries"[pipe.write_discord_newsletter]-PipeSequence = "Create a newsletter from Discord articles by summarizing channels and organizing content"+type = "PipeSequence"+definition = "Create a newsletter from Discord articles by summarizing channels and organizing content"inputs = { discord_channel_updates = "DiscordChannelUpdate" }output = "Newsletter"steps = [@@ -15,7 +16,8 @@ steps = [][pipe.summarize_discord_channel_update]-PipeLLM = "Summarize a Discord channel's messages into newsletter-friendly content"+type = "PipeLLM"+definition = "Summarize a Discord channel's messages into newsletter-friendly content"inputs = { discord_channel_update = "DiscordChannelUpdate" }output = "ChannelSummary"system_prompt = "You are a newsletter editor who creates engaging summaries of Discord channel content. You extract key information, preserve important links, and write in a clear, concise style suitable for newsletter readers."diff --git a/tests/test_pipelines/failing_pipelines.toml b/tests/test_pipelines/failing_pipelines.tomlindex ac775a9ff..64323fac3 100644--- a/tests/test_pipelines/failing_pipelines.toml+++ b/tests/test_pipelines/failing_pipelines.toml@@ -4,7 +4,8 @@ domain = "failing_pipelines"[pipe][pipe.dummy]-PipeLLM = "This pipe is a dummy pipe"+type = "PipeLLM"+definition = "This pipe is a dummy pipe"output = "Text"llm = { llm_handle = "gpt-4o-mini", temperature = 1, max_tokens = 50 }prompt_template = """@@ -12,7 +13,8 @@ This is a dummy prompt, do whatever you want. Something funny but not a joke, ok"""[pipe.infinite_loop_1]-PipeSequence = "This pipe will cause an infinite loop"+type = "PipeSequence"+definition = "This pipe will cause an infinite loop"output = "Text"steps = [{ pipe = "dummy", result = "dummy_result" },diff --git a/tests/test_pipelines/misc_tests/flows.toml b/tests/test_pipelines/misc_tests/flows.tomlindex dfb49b264..86674a112 100644--- a/tests/test_pipelines/misc_tests/flows.toml+++ b/tests/test_pipelines/misc_tests/flows.toml@@ -8,7 +8,8 @@ Color = "A color"[pipe][pipe.choose_colors]-PipeLLM = "Choose Colors"+type = "PipeLLM"+definition = "Choose Colors"output = "Color"prompt_template = """Choose {{ _nb_output }} colors.@@ -16,7 +17,8 @@ Choose {{ _nb_output }} colors.llm = "llm_for_creative_writing"[pipe.sequence_for_batch_test]-PipeSequence = "Sequence for parallel test"+type = "PipeSequence"+definition = "Sequence for parallel test"inputs = { color = "Color" }output = "Color"steps = [@@ -25,7 +27,8 @@ steps = [][pipe.capitalize_color]-PipeLLM = "Capitalize Colors"+type = "PipeLLM"+definition = "Capitalize Colors"inputs = { color = "Color" }output = "Color"prompt_template = """@@ -38,7 +41,8 @@ Output only the word, nothing else."""[pipe.capitalize_last_letter]-PipeLLM = "Capitalize Last Letter"+type = "PipeLLM"+definition = "Capitalize Last Letter"inputs = { capitalized_color = "Color" }output = "Color"prompt_template = """diff --git a/tests/test_pipelines/misc_tests/multiplicity.toml b/tests/test_pipelines/misc_tests/multiplicity.tomlindex 91c182b2b..1f8957e2a 100644--- a/tests/test_pipelines/misc_tests/multiplicity.toml+++ b/tests/test_pipelines/misc_tests/multiplicity.toml@@ -9,7 +9,8 @@ ProductOfNature = "Something produced by Nature"FantasyScene = "A fantasy scene"[pipe.original_power_ranger_colors]-PipeLLM = "Recall the colors of the original power rangers"+type = "PipeLLM"+definition = "Recall the colors of the original power rangers"output = "Color"prompt_template = """Remind me of the colors of the {{ _nb_output }} original power rangers.@@ -18,7 +19,8 @@ llm = "llm_for_creative_writing"nb_output = 5[pipe.alltime_power_ranger_colors]-PipeLLM = "Recall the colors of all the power rangers"+type = "PipeLLM"+definition = "Recall the colors of all the power rangers"output = "Color"prompt_template = """Remind me of the colors of all the power rangers over all series.@@ -27,7 +29,8 @@ Don't list the names of the characters or the name of the series: just list thellm = "llm_for_creative_writing"[pipe.imagine_nature_product]-PipeLLM = "Imagine a product of nature"+type = "PipeLLM"+definition = "Imagine a product of nature"inputs = { color = "Color" }output = "ProductOfNature"prompt_template = """@@ -36,7 +39,8 @@ Just state what it is in a single sentence."""[pipe.imagine_fantasy_scene_including_products_of_nature]-PipeLLM = "Imagine a fantasy scene including products of nature"+type = "PipeLLM"+definition = "Imagine a fantasy scene including products of nature"inputs = { product_of_nature = "ProductOfNature" }output = "FantasyScene"prompt_template = """@@ -48,7 +52,8 @@ Keep it short and concise, just one sentence."""[pipe.imagine_nature_scene_of_original_power_rangers_colors]-PipeSequence = "Imagine nature scenes of Power Rangers colors"+type = "PipeSequence"+definition = "Imagine nature scenes of Power Rangers colors"output = "Image"steps = [{ pipe = "original_power_ranger_colors", result = "color" },@@ -58,7 +63,8 @@ steps = [[pipe.imagine_nature_scene_of_alltime_power_rangers_colors]-PipeSequence = "Imagine nature scenes of Power Rangers colors"+type = "PipeSequence"+definition = "Imagine nature scenes of Power Rangers colors"output = "Image"steps = [{ pipe = "alltime_power_ranger_colors", result = "color", multiple_output = true },diff --git a/tests/test_pipelines/misc_tests/subfolder_1/cars.toml b/tests/test_pipelines/misc_tests/subfolder_1/cars.tomlindex e07230d48..47c961a64 100644--- a/tests/test_pipelines/misc_tests/subfolder_1/cars.toml+++ b/tests/test_pipelines/misc_tests/subfolder_1/cars.toml@@ -10,7 +10,8 @@ CarDescription = "A detailed description of a car model"[pipe][pipe.generate_car_description]-PipeLLM = "Generate a description of a car"+type = "PipeLLM"+definition = "Generate a description of a car"inputs = { car = "Car" }output = "CarDescription"prompt_template = """diff --git a/tests/test_pipelines/misc_tests/subfolder_2/animals.toml b/tests/test_pipelines/misc_tests/subfolder_2/animals.tomlindex 02dc21291..f35a6c846 100644--- a/tests/test_pipelines/misc_tests/subfolder_2/animals.toml+++ b/tests/test_pipelines/misc_tests/subfolder_2/animals.toml@@ -10,7 +10,8 @@ AnimalDescription = "A detailed description of an animal"[pipe][pipe.generate_animal_description]-PipeLLM = "Generate a description of an animal"+type = "PipeLLM"+definition = "Generate a description of an animal"inputs = { animal = "Animal" }output = "AnimalDescription"prompt_template = """diff --git a/tests/test_pipelines/misc_tests/subfolder_2/subfolder/flowers.toml b/tests/test_pipelines/misc_tests/subfolder_2/subfolder/flowers.tomlindex dfe99d7ea..2a879f1d9 100644--- a/tests/test_pipelines/misc_tests/subfolder_2/subfolder/flowers.toml+++ b/tests/test_pipelines/misc_tests/subfolder_2/subfolder/flowers.toml@@ -8,7 +8,8 @@ FlowerDescription = "A detailed description of a flower"[pipe][pipe.generate_flower_description]-PipeLLM = "Generate a description of a flower"+type = "PipeLLM"+definition = "Generate a description of a flower"inputs = { flower = "Flower" }output = "FlowerDescription"prompt_template = """diff --git a/tests/test_pipelines/misc_tests/test_image_inputs.toml b/tests/test_pipelines/misc_tests/test_image_inputs.tomlindex 0acd25588..329418215 100644--- a/tests/test_pipelines/misc_tests/test_image_inputs.toml+++ b/tests/test_pipelines/misc_tests/test_image_inputs.toml@@ -6,7 +6,8 @@ Article = "Article"[pipe][pipe.extract_article_from_image]-PipeLLM = "Describe a page content"+type = "PipeLLM"+definition = "Describe a page content"inputs = { image = "Image" }output = "Article"system_prompt = """@@ -17,7 +18,8 @@ Extract the text and the date of the article in the image."""[pipe.describe_page]-PipeLLM = "Describe a page"+type = "PipeLLM"+definition = "Describe a page"inputs = { "page.page_view" = "Image", page = "Page" }output = "Article"system_prompt = """diff --git a/tests/test_pipelines/misc_tests/test_jinja2.toml b/tests/test_pipelines/misc_tests/test_jinja2.tomlindex 664922f79..9a0d44398 100644--- a/tests/test_pipelines/misc_tests/test_jinja2.toml+++ b/tests/test_pipelines/misc_tests/test_jinja2.toml@@ -2,7 +2,8 @@ domain = "test_jinja2"definition = "This library is intended for testing Jinja2"[pipe.jinja2_test_1]-PipeJinja2 = "Jinja2 test 1"+type = "PipeJinja2"+definition = "Jinja2 test 1"inputs = { text = "Text" }output = "Text"jinja2 = """diff --git a/tests/test_pipelines/misc_tests/tests.toml b/tests/test_pipelines/misc_tests/tests.tomlindex 378121f5a..d5e91c743 100644--- a/tests/test_pipelines/misc_tests/tests.toml+++ b/tests/test_pipelines/misc_tests/tests.toml@@ -9,7 +9,8 @@ ArticleAndCritic = "An article and a critique of it"Complex = "A complex object"[pipe.simple_llm_test_from_image]-PipeLLM = "Simple LLM test from image"+type = "PipeLLM"+definition = "Simple LLM test from image"inputs = { image = "Image" }output = "Text"prompt_template = """@@ -17,7 +18,8 @@ Describe the using rap lyrics, including puns and references to the image."""[pipe.test_no_input]-PipeLLM = "No Input"+type = "PipeLLM"+definition = "No Input"output = "Text"llm = "llm_for_testing_gen_text"prompt_template = """@@ -25,7 +27,8 @@ Explain that this is a test prompt which took no input from the user."""[pipe.test_no_input_that_could_be_long]-PipeLLM = "No Input but generates a text that could be long"+type = "PipeLLM"+definition = "No Input but generates a text that could be long"output = "Text"llm = { llm_handle = "gpt-4o-mini", temperature = 0.5, max_tokens = 100 }prompt_template = """diff --git a/tests/test_pipelines/pipe_controllers/pipe_batch/uppercase_transformer.toml b/tests/test_pipelines/pipe_controllers/pipe_batch/uppercase_transformer.tomlindex 166ed5844..b13d3ad15 100644--- a/tests/test_pipelines/pipe_controllers/pipe_batch/uppercase_transformer.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_batch/uppercase_transformer.toml@@ -7,7 +7,8 @@ TextList = "List of Text"[pipe][pipe.test_pipe_batch]-PipeBatch = "Test pipe batch"+type = "PipeBatch"+definition = "Test pipe batch"inputs = { text_item = "Text", text_list = "TextList" }output = "UppercaseText"branch_pipe_code = "uppercase_transformer"@@ -15,7 +16,8 @@ input_list_name = "text_list"input_item_name = "text_item"[pipe.uppercase_transformer]-PipeLLM = "Transform text to uppercase"+type = "PipeLLM"+definition = "Transform text to uppercase"inputs = { text_item = "Text" }output = "UppercaseText"prompt_template = """diff --git a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_1.toml b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_1.tomlindex bef33ccdc..531fafd66 100644--- a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_1.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_1.toml@@ -6,7 +6,8 @@ CategoryInput = "Input with a category field"[pipe][pipe.basic_condition_by_category]-PipeCondition = "Route based on category field"+type = "PipeCondition"+definition = "Route based on category field"inputs = { input_data = "CategoryInput" }output = "native.Text"expression_template = "{{ input_data.category }}"@@ -17,21 +18,24 @@ medium = "process_medium"large = "process_large"[pipe.process_small]-PipeLLM = "Generate random text for small items"+type = "PipeLLM"+definition = "Generate random text for small items"output = "native.Text"prompt_template = """Output this only: "small""""[pipe.process_medium]-PipeLLM = "Generate random text for medium items"+type = "PipeLLM"+definition = "Generate random text for medium items"output = "native.Text"prompt_template = """Output this only: "medium""""[pipe.process_large]-PipeLLM = "Generate random text for large items"+type = "PipeLLM"+definition = "Generate random text for large items"output = "native.Text"prompt_template = """Output this only: "large"diff --git a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_2.toml b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_2.tomlindex 0b4050843..a9c21cd11 100644--- a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_2.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_2.toml@@ -6,7 +6,8 @@ CategoryInput = "Input with a category field"[pipe][pipe.basic_condition_by_category_2]-PipeCondition = "Route based on category field using expression"+type = "PipeCondition"+definition = "Route based on category field using expression"inputs = { input_data = "CategoryInput" }output = "native.Text"expression = "input_data.category"@@ -17,21 +18,24 @@ medium = "process_medium_2"large = "process_large_2"[pipe.process_small_2]-PipeLLM = "Generate random text for small items"+type = "PipeLLM"+definition = "Generate random text for small items"output = "native.Text"prompt_template = """Output this only: "small""""[pipe.process_medium_2]-PipeLLM = "Generate random text for medium items"+type = "PipeLLM"+definition = "Generate random text for medium items"output = "native.Text"prompt_template = """Output this only: "medium""""[pipe.process_large_2]-PipeLLM = "Generate random text for large items"+type = "PipeLLM"+definition = "Generate random text for large items"output = "native.Text"prompt_template = """Output this only: "large"diff --git a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_complex.toml b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_complex.tomlindex 9ea535763..54c1ea33d 100644--- a/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_complex.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_condition/pipe_condition_complex.toml@@ -9,7 +9,8 @@ ProcessingContext = "Combined processing context"[pipe]# Main entry point - routes by document type first[pipe.complex_document_processor]-PipeCondition = "Primary routing by document type"+type = "PipeCondition"+definition = "Primary routing by document type"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"expression_template = "{{ doc_request.document_type }}"@@ -21,7 +22,8 @@ legal = "legal_document_router"# Technical document processing branch[pipe.technical_document_router]-PipeCondition = "Route technical documents by priority and user level"+type = "PipeCondition"+definition = "Route technical documents by priority and user level"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"expression_template = "{% if doc_request.priority == 'urgent' %}urgent_tech{% elif user_profile.user_level == 'expert' and doc_request.complexity == 'high' %}expert_tech{% else %}standard_tech{% endif %}"@@ -33,7 +35,8 @@ standard_tech = "standard_technical_processor"# Business document processing branch[pipe.business_document_router]-PipeCondition = "Route business documents by department and priority"+type = "PipeCondition"+definition = "Route business documents by department and priority"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"expression_template = "{% if doc_request.priority == 'urgent' %}urgent_business{% elif user_profile.department == 'finance' %}finance_business{% elif user_profile.department == 'marketing' %}marketing_business{% else %}general_business{% endif %}"@@ -46,7 +49,8 @@ general_business = "general_business_processor"# Legal document processing branch[pipe.legal_document_router]-PipeCondition = "Route legal documents by complexity and user level"+type = "PipeCondition"+definition = "Route legal documents by complexity and user level"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"expression_template = "{% if doc_request.complexity == 'high' and user_profile.user_level != 'beginner' %}complex_legal{% elif doc_request.language != 'english' %}international_legal{% else %}standard_legal{% endif %}"@@ -58,7 +62,8 @@ standard_legal = "standard_legal_processor"# Leaf processors - Technical[pipe.urgent_technical_processor]-PipeLLM = "Process urgent technical documents with high priority"+type = "PipeLLM"+definition = "Process urgent technical documents with high priority"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -73,7 +78,8 @@ Output: "URGENT_TECHNICAL_PROCESSED""""[pipe.expert_technical_processor]-PipeLLM = "Process complex technical documents for expert users"+type = "PipeLLM"+definition = "Process complex technical documents for expert users"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -86,7 +92,8 @@ Output: "EXPERT_TECHNICAL_PROCESSED""""[pipe.standard_technical_processor]-PipeLLM = "Process standard technical documents"+type = "PipeLLM"+definition = "Process standard technical documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -99,7 +106,8 @@ Output: "STANDARD_TECHNICAL_PROCESSED"# Leaf processors - Business[pipe.urgent_business_processor]-PipeLLM = "Process urgent business documents"+type = "PipeLLM"+definition = "Process urgent business documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -111,7 +119,8 @@ Output: "URGENT_BUSINESS_PROCESSED""""[pipe.finance_business_processor]-PipeLLM = "Process finance business documents"+type = "PipeLLM"+definition = "Process finance business documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -123,7 +132,8 @@ Output: "FINANCE_BUSINESS_PROCESSED""""[pipe.marketing_business_processor]-PipeLLM = "Process marketing business documents"+type = "PipeLLM"+definition = "Process marketing business documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -135,7 +145,8 @@ Output: "MARKETING_BUSINESS_PROCESSED""""[pipe.general_business_processor]-PipeLLM = "Process general business documents"+type = "PipeLLM"+definition = "Process general business documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -148,7 +159,8 @@ Output: "GENERAL_BUSINESS_PROCESSED"# Leaf processors - Legal[pipe.complex_legal_processor]-PipeLLM = "Process complex legal documents"+type = "PipeLLM"+definition = "Process complex legal documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """@@ -161,7 +173,8 @@ Output: "COMPLEX_LEGAL_PROCESSED""""[pipe.international_legal_processor]-PipeLLM = "Process international legal documents"+type = "PipeLLM"+definition = "Process international legal documents"inputs = { doc_request = "DocumentRequest" }output = "native.Text"prompt_template = """@@ -173,7 +186,8 @@ Output: "INTERNATIONAL_LEGAL_PROCESSED""""[pipe.standard_legal_processor]-PipeLLM = "Process standard legal documents"+type = "PipeLLM"+definition = "Process standard legal documents"inputs = { doc_request = "DocumentRequest", user_profile = "UserProfile" }output = "native.Text"prompt_template = """diff --git a/tests/test_pipelines/pipe_controllers/pipe_condition/text_length_condition.toml b/tests/test_pipelines/pipe_controllers/pipe_condition/text_length_condition.tomlindex 46a1c41ab..6410f0f55 100644--- a/tests/test_pipelines/pipe_controllers/pipe_condition/text_length_condition.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_condition/text_length_condition.toml@@ -4,7 +4,8 @@ definition = "Test pipes for PipeCondition based on text length"[pipe][pipe.capitalize_long_text]-PipeLLM = "Capitalize text for long inputs"+type = "PipeLLM"+definition = "Capitalize text for long inputs"inputs = { input_text = "Text" }output = "Text"prompt_template = """Transform the following LONG text to uppercase and add "LONG: " prefix:@@ -14,7 +15,8 @@ prompt_template = """Transform the following LONG text to uppercase and add "LONReturn only the prefixed uppercase text, nothing else."""[pipe.add_prefix_short_text]-PipeLLM = "Add prefix for short text inputs"+type = "PipeLLM"+definition = "Add prefix for short text inputs"inputs = { input_text = "Text" }output = "Text"prompt_template = """Add the prefix "SHORT: " to the beginning of the following text:diff --git a/tests/test_pipelines/pipe_controllers/pipe_parallel/parallel_text_analysis.toml b/tests/test_pipelines/pipe_controllers/pipe_parallel/parallel_text_analysis.tomlindex a898a83c3..6c359aab5 100644--- a/tests/test_pipelines/pipe_controllers/pipe_parallel/parallel_text_analysis.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_parallel/parallel_text_analysis.toml@@ -4,7 +4,8 @@ definition = "Test pipes for PipeParallel text analysis"[pipe][pipe.analyze_sentiment]-PipeLLM = "Analyze sentiment of text"+type = "PipeLLM"+definition = "Analyze sentiment of text"inputs = { input_text = "Text" }output = "Text"prompt_template = """Analyze the sentiment of the following text and return only one word: positive, negative, or neutral.@@ -14,7 +15,8 @@ prompt_template = """Analyze the sentiment of the following text and return onlySentiment:"""[pipe.count_words]-PipeLLM = "Count words in text"+type = "PipeLLM"+definition = "Count words in text"inputs = { input_text = "Text" }output = "Text"prompt_template = """Count the number of words in the following text and return only the number:@@ -24,7 +26,8 @@ prompt_template = """Count the number of words in the following text and returnWord count:"""[pipe.extract_keywords]-PipeLLM = "Extract keywords from text"+type = "PipeLLM"+definition = "Extract keywords from text"inputs = { input_text = "Text" }output = "Text"prompt_template = """Extract the top 3 keywords from the following text. Return them as a comma-separated list:diff --git a/tests/test_pipelines/pipe_controllers/pipe_parallel/pipe_parallel_1.toml b/tests/test_pipelines/pipe_controllers/pipe_parallel/pipe_parallel_1.tomlindex 7fb132521..78c8d8619 100644--- a/tests/test_pipelines/pipe_controllers/pipe_parallel/pipe_parallel_1.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_parallel/pipe_parallel_1.toml@@ -9,7 +9,8 @@ CombinedAnalysis = "Combined analysis results from parallel processing"[pipe][pipe.parallel_document_analysis]-PipeParallel = "Analyze document length and content in parallel"+type = "PipeParallel"+definition = "Analyze document length and content in parallel"inputs = { document = "DocumentInput" }output = "CombinedAnalysis"add_each_output = true@@ -20,7 +21,8 @@ parallels = [][pipe.analyze_length]-PipeLLM = "Analyze document length and structure"+type = "PipeLLM"+definition = "Analyze document length and structure"inputs = { document = "DocumentInput" }output = "LengthAnalysis"llm = "llm_for_testing_gen_text"@@ -36,7 +38,8 @@ Provide a brief analysis focusing on:"""[pipe.analyze_content]-PipeLLM = "Analyze document content and themes"+type = "PipeLLM"+definition = "Analyze document content and themes"inputs = { document = "DocumentInput" }output = "ContentAnalysis"llm = "llm_for_testing_gen_text"diff --git a/tests/test_pipelines/pipe_controllers/pipe_sequence/capitalize_text.toml b/tests/test_pipelines/pipe_controllers/pipe_sequence/capitalize_text.tomlindex c4d279e63..87694b705 100644--- a/tests/test_pipelines/pipe_controllers/pipe_sequence/capitalize_text.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_sequence/capitalize_text.toml@@ -3,7 +3,8 @@ definition = "Test pipe for capitalizing text to uppercase"[pipe][pipe.capitalize_text]-PipeLLM = "Transform text to uppercase"+type = "PipeLLM"+definition = "Transform text to uppercase"inputs = { input_text = "Text" }output = "Text"prompt_template = """Transform the following text to uppercase:@@ -13,7 +14,8 @@ prompt_template = """Transform the following text to uppercase:Return only the uppercase text, nothing else."""[pipe.add_prefix]-PipeLLM = "Add PROCESSED prefix to text"+type = "PipeLLM"+definition = "Add PROCESSED prefix to text"inputs = { capitalized_text = "Text" }output = "Text"prompt_template = """Add the prefix "PROCESSED: " to the beginning of the following text:diff --git a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_1.toml b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_1.tomlindex 383388cf5..5a8fdb1d3 100644--- a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_1.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_1.toml@@ -9,7 +9,8 @@ SummaryText = "A summary of the processed text"[pipe][pipe.simple_text_sequence]-PipeSequence = "Process text through cleaning and summarization"+type = "PipeSequence"+definition = "Process text through cleaning and summarization"inputs = { raw_text = "RawText" }output = "SummaryText"steps = [@@ -18,7 +19,8 @@ steps = [][pipe.clean_text]-PipeLLM = "Clean and normalize the input text"+type = "PipeLLM"+definition = "Clean and normalize the input text"inputs = { raw_text = "RawText" }output = "CleanedText"llm = "llm_for_testing_gen_text"@@ -32,7 +34,8 @@ Clean and normalize the following text by:"""[pipe.generate_summary]-PipeLLM = "Generate a summary of the cleaned text"+type = "PipeLLM"+definition = "Generate a summary of the cleaned text"inputs = { cleaned_text = "CleanedText" }output = "SummaryText"llm = "llm_for_testing_gen_text"diff --git a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_2.toml b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_2.tomlindex b8613da31..689564787 100644--- a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_2.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_2.toml@@ -10,7 +10,8 @@ Document = "A document containing multiple customer reviews"[pipe][pipe.analyze_reviews_sequence]-PipeSequence = "Process customer reviews with sentiment analysis"+type = "PipeSequence"+definition = "Process customer reviews with sentiment analysis"inputs = { document = "Document" }output = "ProductRating"steps = [@@ -20,7 +21,8 @@ steps = [][pipe.extract_individual_reviews]-PipeLLM = "Extract individual reviews from document"+type = "PipeLLM"+definition = "Extract individual reviews from document"inputs = { document = "Document" }output = "CustomerReview"nb_output = 1@@ -32,7 +34,8 @@ Extract each individual customer review from this document as separate items:"""[pipe.analyze_review_sentiment]-PipeLLM = "Analyze sentiment of a single review"+type = "PipeLLM"+definition = "Analyze sentiment of a single review"inputs = { single_review = "CustomerReview" }output = "SentimentAnalysis"llm = "llm_for_testing_gen_text"@@ -45,7 +48,8 @@ Provide sentiment (positive/negative/neutral) and confidence score."""[pipe.aggregate_review_results]-PipeLLM = "Aggregate all review analyses into final rating"+type = "PipeLLM"+definition = "Aggregate all review analyses into final rating"inputs = { sentiment_analyses = "SentimentAnalysis" }output = "ProductRating"llm = "llm_for_testing_gen_text"diff --git a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_3.toml b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_3.tomlindex bd9f2220e..ee60d0f72 100644--- a/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_3.toml+++ b/tests/test_pipelines/pipe_controllers/pipe_sequence/pipe_sequence_3.toml@@ -11,7 +11,8 @@ BestIdea = "The top-ranked creative idea with justification"[pipe][pipe.creative_ideation_sequence]-PipeSequence = "Generate multiple ideas, analyze each individually, then select the best"+type = "PipeSequence"+definition = "Generate multiple ideas, analyze each individually, then select the best"inputs = { topic = "CreativeTopic" }output = "BestIdea"steps = [@@ -22,7 +23,8 @@ steps = [][pipe.generate_multiple_ideas]-PipeLLM = "Generate exactly 5 creative ideas for a topic"+type = "PipeLLM"+definition = "Generate exactly 5 creative ideas for a topic"inputs = { topic = "CreativeTopic" }output = "CreativeIdea"nb_output = 5@@ -41,7 +43,8 @@ Ideas:"""[pipe.brainstorm_concepts]-PipeLLM = "Brainstorm variable number of concepts"+type = "PipeLLM"+definition = "Brainstorm variable number of concepts"inputs = { topic = "CreativeTopic" }output = "CreativeIdea"multiple_output = true@@ -55,7 +58,8 @@ Each concept should be briefly described."""[pipe.analyze_single_idea]-PipeLLM = "Analyze a single idea in detail"+type = "PipeLLM"+definition = "Analyze a single idea in detail"inputs = { single_idea = "CreativeIdea" }output = "IdeaAnalysis"llm = "llm_for_testing_gen_text"@@ -75,7 +79,8 @@ Provide a comprehensive assessment."""[pipe.evaluate_all_ideas]-PipeLLM = "Evaluate and rank all analyzed ideas"+type = "PipeLLM"+definition = "Evaluate and rank all analyzed ideas"inputs = { detailed_analyses = "IdeaAnalysis" }output = "IdeaEvaluation"llm = "llm_for_testing_gen_text"@@ -91,7 +96,8 @@ Provide:"""[pipe.select_best_idea]-PipeLLM = "Select the best idea based on evaluation"+type = "PipeLLM"+definition = "Select the best idea based on evaluation"inputs = { evaluation = "IdeaEvaluation" }output = "BestIdea"llm = "llm_for_testing_gen_text"diff --git a/tests/test_pipelines/tricky_questions.toml b/tests/test_pipelines/tricky_questions.tomlindex f15dcd7e3..04e0648f1 100644--- a/tests/test_pipelines/tricky_questions.toml+++ b/tests/test_pipelines/tricky_questions.toml@@ -14,7 +14,8 @@ refines = "AnswerToAQuestion"[pipe][pipe.analyse_question_tricky]-PipeLLM = "Analyze a question to determine whether it's straightforward or tricky"+type = "PipeLLM"+definition = "Analyze a question to determine whether it's straightforward or tricky"inputs = { question = "Question" }output = "QuestionAnalysis"llm = "llm_to_reason"@@ -29,7 +30,8 @@ If there's an obvious trap, state it without getting into details."""[pipe.answer_after_analysis]-PipeLLM = "Answer knowingly after analyzing a question"+type = "PipeLLM"+definition = "Answer knowingly after analyzing a question"inputs = { question = "Question", question_analysis = "QuestionAnalysis" }output = "ThoughtfulAnswer"llm = "llm_to_reason"@@ -47,14 +49,16 @@ Answer in 4 parts:"""[pipe.conclude_thoughtful_answer]-PipeJinja2 = "Conclude a thoughtful answer"+type = "PipeJinja2"+definition = "Conclude a thoughtful answer"inputs = { thoughtful_answer = "ThoughtfulAnswer" }output = "ThoughtfulAnswerConclusion"jinja2 = "After analyzing the question, here is my answer: $thoughtful_answer.the_answer"[pipe.conclude_tricky_question_by_steps]-PipeSequence = "Answer a tricky question by first analyzing its trickiness and then concluding"+type = "PipeSequence"+definition = "Answer a tricky question by first analyzing its trickiness and then concluding"inputs = { question = "Question" }output = "ThoughtfulAnswerConclusion"steps = [