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.
fix/input_memory-to-inputs (#394)
Thomas Hebrard2f8984ec5024
diff --git a/.cursor/rules/run_pipelex.mdc b/.cursor/rules/run_pipelex.mdcindex eebaa223c..838783897 100644--- a/.cursor/rules/run_pipelex.mdc+++ b/.cursor/rules/run_pipelex.mdc@@ -55,7 +55,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -94,7 +94,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -104,7 +104,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -113,7 +113,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -123,7 +123,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -135,7 +135,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.mdindex b467128ac..06a223540 100644--- a/.github/copilot-instructions.md+++ b/.github/copilot-instructions.md@@ -899,7 +899,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -938,7 +938,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -948,7 +948,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -957,7 +957,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -967,7 +967,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -979,7 +979,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/.windsurfrules.md b/.windsurfrules.mdindex b467128ac..06a223540 100644--- a/.windsurfrules.md+++ b/.windsurfrules.md@@ -899,7 +899,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -938,7 +938,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -948,7 +948,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -957,7 +957,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -967,7 +967,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -979,7 +979,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/AGENTS.md b/AGENTS.mdindex b467128ac..06a223540 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -899,7 +899,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -938,7 +938,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -948,7 +948,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -957,7 +957,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -967,7 +967,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -979,7 +979,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/BLACKBOX_RULES.md b/BLACKBOX_RULES.mdindex b467128ac..06a223540 100644--- a/BLACKBOX_RULES.md+++ b/BLACKBOX_RULES.md@@ -899,7 +899,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -938,7 +938,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -948,7 +948,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -957,7 +957,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -967,7 +967,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -979,7 +979,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 73bd79993..20ac69e50 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -11,6 +11,7 @@### Changed- Updated the `PipelexClient` and changed the route of the API calls to `v1/pipeline/execute` and `v1/pipeline/start`.+- Changed the parameter `input_memory` to `inputs` in the documentaton.## [v0.13.1] - 2025-10-22diff --git a/CLAUDE.md b/CLAUDE.mdindex b467128ac..06a223540 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -899,7 +899,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -938,7 +938,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -948,7 +948,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -957,7 +957,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -967,7 +967,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa## so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -979,7 +979,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/docs/pages/build-reliable-ai-workflows-with-pipelex/design_and_run_pipelines.md b/docs/pages/build-reliable-ai-workflows-with-pipelex/design_and_run_pipelines.mdindex 60f708bc4..6c429902c 100644--- a/docs/pages/build-reliable-ai-workflows-with-pipelex/design_and_run_pipelines.md+++ b/docs/pages/build-reliable-ai-workflows-with-pipelex/design_and_run_pipelines.md@@ -144,7 +144,7 @@ async def main():# Execute the pipeline and wait for the resultpipe_output = await execute_pipeline(pipe_code="description_to_tagline",- input_memory={+ inputs={"description": {"concept": "ProductDescription","content": "EcoClean Pro is a revolutionary biodegradable cleaning solution that removes 99.9% of germs while being completely safe for children and pets. Made from plant-based ingredients.",diff --git a/docs/pages/build-reliable-ai-workflows-with-pipelex/executing-pipelines-with-inputs.md b/docs/pages/build-reliable-ai-workflows-with-pipelex/executing-pipelines-with-inputs.mdindex 99eb77aed..f154c7d5d 100644--- a/docs/pages/build-reliable-ai-workflows-with-pipelex/executing-pipelines-with-inputs.md+++ b/docs/pages/build-reliable-ai-workflows-with-pipelex/executing-pipelines-with-inputs.md@@ -1,17 +1,17 @@# Executing Pipelines with Inputs-When you run a Pipelex pipeline from Python, you often need to provide input data. The `input_memory` parameter gives you a flexible and intuitive way to pass data to your pipelines.+When you run a Pipelex pipeline from Python, you often need to provide input data. The `inputs` parameter gives you a flexible and intuitive way to pass data to your pipelines.This guide explains the different formats you can use and when to use each one.-## Understanding input_memory+## Understanding inputs-The `input_memory` parameter accepts a dictionary where:+The `inputs` parameter accepts a dictionary where:- **Keys** are the input variable names (matching the `inputs` defined in your pipeline)- **Values** can be provided in multiple formats for convenience-Under the hood, `input_memory` uses this type definition:+Under the hood, `inputs` uses this type definition:```pythonStuffContentOrData = dict[str, Any] | StuffContent | list[Any] | str@@ -43,7 +43,7 @@ The simplest way to provide text input is with a plain string. Pipelex automatic```pythonpipe_output = await execute_pipeline(pipe_code="summarize_story",- input_memory={+ inputs={"story": """Once upon a time there was a brave knight who saved the kingdom from a dragon.[...]@@ -72,7 +72,7 @@ from pipelex.core.stuffs.pdf_content import PDFContentpipe_output = await execute_pipeline(pipe_code="process_invoice",- input_memory={+ inputs={"document": PDFContent(url="invoice.pdf"),},)@@ -85,7 +85,7 @@ from pipelex.core.stuffs.image_content import ImageContentpipe_output = await execute_pipeline(pipe_code="analyze_photo",- input_memory={+ inputs={"photo": ImageContent(url="photo.jpg"),},)@@ -112,7 +112,7 @@ from pipelex.core.stuffs.image_content import ImageContentpipe_output = await execute_pipeline(pipe_code="extract_gantt",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttChartImage", # Custom concept that refines Image"content": ImageContent(url="gantt.png"),@@ -126,7 +126,7 @@ pipe_output = await execute_pipeline(```pythonpipe_output = await execute_pipeline(pipe_code="answer_question",- input_memory={+ inputs={"question": {"concept": "qa.Question","content": "What is the capital of France?",@@ -146,7 +146,7 @@ pipe_output = await execute_pipeline(## Format 4: Multiple Inputs with Mixed Formats-You can mix and match formats freely in the same `input_memory` dictionary.+You can mix and match formats freely in the same `inputs` dictionary.### Complex Example@@ -155,7 +155,7 @@ from pipelex.core.stuffs.text_content import load_text_from_pathpipe_output = await execute_pipeline(pipe_code="analyze_contract",- input_memory={+ inputs={# Format 1: Simple string"client_instructions": "Focus on payment terms",@@ -208,7 +208,7 @@ Follow these simple rules:# Most document processing pipelines expect a PDF inputpipe_output = await execute_pipeline(pipe_code="extract_data",- input_memory={+ inputs={"document": PDFContent(url="document.pdf"),},)@@ -220,7 +220,7 @@ pipe_output = await execute_pipeline(# Image processing with native Image conceptpipe_output = await execute_pipeline(pipe_code="describe_image",- input_memory={+ inputs={"image": ImageContent(url="photo.jpg"),},)@@ -232,7 +232,7 @@ pipe_output = await execute_pipeline(# Simple text input for generation taskspipe_output = await execute_pipeline(pipe_code="write_story",- input_memory={+ inputs={"topic": "A robot learning to love",},)@@ -244,7 +244,7 @@ pipe_output = await execute_pipeline(# Custom concept that needs explicit specificationpipe_output = await execute_pipeline(pipe_code="process_tweet",- input_memory={+ inputs={"draft_tweet": {"concept": "social.DraftTweet","content": "Check out this amazing framework!",@@ -272,7 +272,7 @@ character = Character(# Pass it to the pipelinepipe_output = await execute_pipeline(pipe_code="analyze_character",- input_memory={+ inputs={"character": {"concept": "story.Character","content": character,@@ -283,7 +283,7 @@ pipe_output = await execute_pipeline(## Alternative: Using working_memory Directly-For advanced use cases, you can construct the working memory explicitly instead of using `input_memory`:+For advanced use cases, you can construct the working memory explicitly instead of using `inputs`:```pythonfrom pipelex.core.stuffs.stuff_factory import StuffFactory@@ -314,7 +314,7 @@ pipe_output = await execute_pipeline(- You're building complex multi-stuff scenarios- You're working with intermediate pipeline states-**For most cases, `input_memory` is simpler and recommended.**+**For most cases, `inputs` is simpler and recommended.**## Troubleshooting@@ -324,10 +324,10 @@ If you see an error about a concept not being found, you may need to use the exp```python# ❌ Won't work if MyType is a custom concept-input_memory={"data": my_value}+inputs={"data": my_value}# ✅ Use explicit format-input_memory={+inputs={"data": {"concept": "domain.MyType","content": my_value,@@ -341,7 +341,7 @@ Make sure the content type matches what your concept expects:```python# ❌ Wrong: passing a string when concept expects structured data-input_memory={+inputs={"character": {"concept": "story.Character","content": "Alice", # Should be a Character instance@@ -349,7 +349,7 @@ input_memory={}# ✅ Correct: pass the right type-input_memory={+inputs={"character": {"concept": "story.Character","content": Character(name="Alice", age=30, ...),diff --git a/docs/pages/build-reliable-ai-workflows-with-pipelex/understanding-multiplicity.md b/docs/pages/build-reliable-ai-workflows-with-pipelex/understanding-multiplicity.mdindex af6dc22fb..634953366 100644--- a/docs/pages/build-reliable-ai-workflows-with-pipelex/understanding-multiplicity.md+++ b/docs/pages/build-reliable-ai-workflows-with-pipelex/understanding-multiplicity.md@@ -377,7 +377,7 @@ from pipelex.pipeline.execute import execute_pipeline# Execute a pipe with multiple outputspipe_output = await execute_pipeline(pipe_code="extract_line_items",- input_memory={"invoice_text": "Your invoice text here..."}+ inputs={"invoice_text": "Your invoice text here..."})# Get the list of line items@@ -396,7 +396,7 @@ from pipelex.core.stuffs.text_content import TextContentpipe_output = await execute_pipeline(pipe_code="summarize_all_documents",- input_memory={+ inputs={"documents": [TextContent(text="Document 1 content..."),TextContent(text="Document 2 content..."),diff --git a/docs/pages/cookbook-examples/extract-dpe.md b/docs/pages/cookbook-examples/extract-dpe.mdindex 4af51b595..6978bd484 100644--- a/docs/pages/cookbook-examples/extract-dpe.md+++ b/docs/pages/cookbook-examples/extract-dpe.md@@ -14,7 +14,7 @@ The pipeline `power_extractor_dpe` is designed to recognize and extract the keyasync def extract_dpe(pdf_url: str) -> Dpe:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)diff --git a/docs/pages/cookbook-examples/extract-gantt.md b/docs/pages/cookbook-examples/extract-gantt.mdindex 9d8a5f99e..52bf9fd06 100644--- a/docs/pages/cookbook-examples/extract-gantt.md+++ b/docs/pages/cookbook-examples/extract-gantt.md@@ -15,7 +15,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttChartImage","content": ImageContent(url=image_url),diff --git a/docs/pages/cookbook-examples/extract-generic.md b/docs/pages/cookbook-examples/extract-generic.mdindex e62da82cc..c70ca64ef 100644--- a/docs/pages/cookbook-examples/extract-generic.md+++ b/docs/pages/cookbook-examples/extract-generic.md@@ -14,7 +14,7 @@ The `power_extractor` pipeline is at the heart of this example. After its executasync def extract_generic(pdf_url: str) -> TextAndImagesContent:pipe_output = await execute_pipeline(pipe_code="power_extractor",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)diff --git a/docs/pages/cookbook-examples/extract-proof-of-purchase.md b/docs/pages/cookbook-examples/extract-proof-of-purchase.mdindex 141dbf294..e79a230c8 100644--- a/docs/pages/cookbook-examples/extract-proof-of-purchase.md+++ b/docs/pages/cookbook-examples/extract-proof-of-purchase.md@@ -14,7 +14,7 @@ The pipeline `power_extractor_proof_of_purchase` is specifically designed to hanasync def extract_proof_of_purchase(pdf_url: str) -> ProofOfPurchase:pipe_output = await execute_pipeline(pipe_code="power_extractor_proof_of_purchase",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)diff --git a/docs/pages/cookbook-examples/extract-table.md b/docs/pages/cookbook-examples/extract-table.mdindex 80791a2ad..a7f68ebf5 100644--- a/docs/pages/cookbook-examples/extract-table.md+++ b/docs/pages/cookbook-examples/extract-table.md@@ -14,7 +14,7 @@ The pipeline `extract_html_table_and_review` takes an image of a table, processeasync def extract_table(table_screenshot: str) -> HtmlTable:pipe_output = await execute_pipeline(pipe_code="extract_html_table_and_review",- input_memory={+ inputs={"table_screenshot": {"concept": "tables.TableScreenshot","content": ImageContent(url=table_screenshot),diff --git a/docs/pages/cookbook-examples/invoice-extractor.md b/docs/pages/cookbook-examples/invoice-extractor.mdindex 8e37231ff..38653df1a 100644--- a/docs/pages/cookbook-examples/invoice-extractor.md+++ b/docs/pages/cookbook-examples/invoice-extractor.md@@ -14,7 +14,7 @@ The `process_invoice` pipeline is a complete workflow for invoice processing.async def process_invoice(pdf_url: str) -> ListContent[Invoice]:pipe_output = await execute_pipeline(pipe_code="process_invoice",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)diff --git a/docs/pages/cookbook-examples/simple-ocr.md b/docs/pages/cookbook-examples/simple-ocr.mdindex 5ec655a87..6f7a281a7 100644--- a/docs/pages/cookbook-examples/simple-ocr.md+++ b/docs/pages/cookbook-examples/simple-ocr.md@@ -16,7 +16,7 @@ The core of this example is a simple function that executes a pre-defined pipeliasync def simple_ocr(pdf_url: str) -> ListContent[PageContent]:pipe_output = await execute_pipeline(pipe_code="extract_page_contents_from_pdf",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -24,4 +24,4 @@ async def simple_ocr(pdf_url: str) -> ListContent[PageContent]:return page_content_list```-This showcases how easy it is to kick off a complex process with just a few lines of code. The `input_memory` dictionary simply maps the input name to the PDF content, and the pipeline handles the rest.\ No newline at end of file+This showcases how easy it is to kick off a complex process with just a few lines of code. The `inputs` dictionary simply maps the input name to the PDF content, and the pipeline handles the rest.\ No newline at end of filediff --git a/docs/pages/cookbook-examples/write-screenplay.md b/docs/pages/cookbook-examples/write-screenplay.mdindex b9c809949..27c3be8fa 100644--- a/docs/pages/cookbook-examples/write-screenplay.md+++ b/docs/pages/cookbook-examples/write-screenplay.md@@ -8,7 +8,7 @@ This example demonstrates how to use Pipelex for creative text generation. It ta## The Pipeline Explained-The `generate_screenplay` function takes a pitch as a string and executes the `generate_screenplay` pipeline, passing the pitch through the `input_memory` dictionary with the concept specification.+The `generate_screenplay` function takes a pitch as a string and executes the `generate_screenplay` pipeline, passing the pitch through the `inputs` dictionary with the concept specification.```pythonasync def generate_screenplay(pitch: str):@@ -16,7 +16,7 @@ async def generate_screenplay(pitch: str):pipe_output = await execute_pipeline(pipe_code="generate_screenplay",- input_memory={+ inputs={"pitch": {"concept": "screenplay.Pitch","content": pitch,diff --git a/docs/pages/cookbook-examples/write-tweet.md b/docs/pages/cookbook-examples/write-tweet.mdindex f91d853f3..cf4b7e844 100644--- a/docs/pages/cookbook-examples/write-tweet.md+++ b/docs/pages/cookbook-examples/write-tweet.md@@ -8,13 +8,13 @@ This example demonstrates how to create a pipeline that takes a draft of a tweet## The Pipeline Explained-The `optimize_tweet` function is the core of this example. It takes two strings, `draft_tweet` and `writing_style`, and executes the `optimize_tweet_sequence` pipeline, passing both inputs through the `input_memory` dictionary with their respective concept specifications.+The `optimize_tweet` function is the core of this example. It takes two strings, `draft_tweet` and `writing_style`, and executes the `optimize_tweet_sequence` pipeline, passing both inputs through the `inputs` dictionary with their respective concept specifications.```pythonasync def optimize_tweet(draft_tweet: str, writing_style: str) -> str:pipe_output = await execute_pipeline(pipe_code="optimize_tweet_sequence",- input_memory={+ inputs={"draft_tweet": {"concept": "tech_tweet.DraftTweet","content": draft_tweet,diff --git a/docs/pages/tools/cli.md b/docs/pages/tools/cli.mdindex c4baf1e70..ad6e30bd0 100644--- a/docs/pages/tools/cli.md+++ b/docs/pages/tools/cli.md@@ -323,7 +323,7 @@ Executes a pipeline, either from a standalone bundle (.plx) file or from your pr- `--pipe` - Pipe code to run (alternative to positional argument)- `--bundle` - Bundle file path (alternative to positional argument)-- `--inputs`, `-i` - Path to JSON file containing input_memory+- `--inputs`, `-i` - Path to JSON file containing inputs- `--output`, `-o` - Path to save output JSON (defaults to `results/run_{pipe_code}.json`)- `--no-output` - Skip saving output to file- `--no-pretty-print` - Skip pretty printing the main outputdiff --git a/pipelex/builder/builder_loop.py b/pipelex/builder/builder_loop.pyindex cd090e7eb..f5e75ab60 100644--- a/pipelex/builder/builder_loop.py+++ b/pipelex/builder/builder_loop.py@@ -24,7 +24,7 @@ class BuilderLoop:async def build_and_fix(self,pipe_code: str,- input_memory: PipelineInputs | None = None,+ inputs: PipelineInputs | None = None,is_save_first_iteration_enabled: bool = True,is_save_second_iteration_enabled: bool = True,) -> PipelexBundleSpec:@@ -32,7 +32,7 @@ class BuilderLoop:try:pipe_output = await execute_pipeline(pipe_code=pipe_code,- inputs=input_memory,+ inputs=inputs,)except PipelineExecutionError as exc:msg = f"Builder loop: Failed to execute pipeline: {exc}."diff --git a/pipelex/builder/runner_code.py b/pipelex/builder/runner_code.pyindex d27a9c01a..99511db90 100644--- a/pipelex/builder/runner_code.py+++ b/pipelex/builder/runner_code.py@@ -104,7 +104,7 @@ def generate_runner_code(pipe: PipeAbstract) -> str:])- # Build input_memory entries+ # Build inputs entriesif inputs.nb_inputs > 0:input_memory_entries: list[str] = []for var_name, input_req in inputs.root.items():@@ -127,7 +127,7 @@ def generate_runner_code(pipe: PipeAbstract) -> str:if inputs.nb_inputs > 0:function_lines.extend([- " input_memory={",+ " inputs={",input_memory_block," },",]diff --git a/pipelex/cli/commands/build_cmd.py b/pipelex/cli/commands/build_cmd.pyindex 94587ebb0..e0de0dee6 100644--- a/pipelex/cli/commands/build_cmd.py+++ b/pipelex/cli/commands/build_cmd.py@@ -94,7 +94,7 @@ def build_pipe_cmd(returntry:- pipelex_bundle_spec = await builder_loop.build_and_fix(pipe_code=builder_pipe, input_memory={"brief": prompt})+ pipelex_bundle_spec = await builder_loop.build_and_fix(pipe_code=builder_pipe, inputs={"brief": prompt})except PipeBuilderError as exc:msg = f"Builder loop: Failed to execute pipeline: {exc}."if exc.working_memory:@@ -346,7 +346,7 @@ def build_one_shot_cmd(def build_partial_cmd(inputs: Annotated[str,- typer.Argument(help="Inline brief or path to JSON file with input_memory"),+ typer.Argument(help="Inline brief or path to JSON file with inputs"),],builder_pipe: Annotated[str,@@ -386,15 +386,15 @@ def build_partial_cmd()ensure_directory_for_file_path(file_path=output_path)- input_memory: PipelineInputs | None = None+ pipeline_inputs: PipelineInputs | None = Noneif inputs.endswith(".json"):- input_memory = load_json_dict_from_path(inputs)+ pipeline_inputs = load_json_dict_from_path(inputs)else:- input_memory = {"brief": inputs}+ pipeline_inputs = {"brief": inputs}try:pipe_output = await execute_pipeline(pipe_code=builder_pipe,- inputs=input_memory,+ inputs=pipeline_inputs,)except PipelineExecutionError as exc:typer.secho(f"Failed to execute pipeline: {exc}", fg=typer.colors.RED, err=True)diff --git a/pipelex/cli/commands/run_cmd.py b/pipelex/cli/commands/run_cmd.pyindex 3470c28b8..5696d1bd5 100644--- a/pipelex/cli/commands/run_cmd.py+++ b/pipelex/cli/commands/run_cmd.py@@ -38,7 +38,7 @@ def run_cmd(] = None,inputs: Annotated[str | None,- typer.Option("--inputs", "-i", help="Path to JSON file with input_memory"),+ typer.Option("--inputs", "-i", help="Path to JSON file with inputs"),] = None,output: Annotated[str | None,@@ -142,13 +142,13 @@ def run_cmd(try:# Load inputs if provided- input_memory = None+ pipeline_inputs = Noneif inputs:if inputs.startswith("{"):- input_memory = json.loads(inputs)+ pipeline_inputs = json.loads(inputs)else:try:- input_memory = load_json_dict_from_path(inputs)+ pipeline_inputs = load_json_dict_from_path(inputs)typer.echo(f"Loaded inputs from: {inputs}")except FileNotFoundError as file_not_found_exc:typer.secho(f"Failed to load input file '{inputs}': file not found", fg=typer.colors.RED, err=True)@@ -163,7 +163,7 @@ def run_cmd(try:pipe_output = await execute_pipeline(pipe_code=pipe_code,- inputs=input_memory,+ inputs=pipeline_inputs,)except PipelineExecutionError as exc:typer.secho(f"Failed to execute pipeline: {exc}", fg=typer.colors.RED, err=True)diff --git a/pipelex/kit/agent_rules/run_pipelex.md b/pipelex/kit/agent_rules/run_pipelex.mdindex c9241dd75..2f146d388 100644--- a/pipelex/kit/agent_rules/run_pipelex.md+++ b/pipelex/kit/agent_rules/run_pipelex.md@@ -49,7 +49,7 @@ async def extract_gantt(image_url: str) -> GanttChart:# Run the pipepipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -88,7 +88,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# If you assign a string, by default it will be considered as a TextContent.pipe_output = await execute_pipeline(pipe_code="master_advisory_orchestrator",- input_memory={+ inputs={"user_input": problem_description,},)@@ -98,7 +98,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# the system knows what content it corresponds to:pipe_output = await execute_pipeline(pipe_code="power_extractor_dpe",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)@@ -107,7 +107,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# Because ImageContent is a native concept, we can use it directly as a value:pipe_output = await execute_pipeline(pipe_code="fashion_variation_pipeline",- input_memory={+ inputs={"fashion_photo": ImageContent(url=image_url),},)@@ -117,7 +117,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wa# so we must provide it using a dict with the concept and the content:pipe_output = await execute_pipeline(pipe_code="extract_gantt_by_steps",- input_memory={+ inputs={"gantt_chart_image": {"concept": "gantt.GanttImage","content": ImageContent(url=image_url),@@ -129,7 +129,7 @@ So here are a few concrete examples of calls to execute_pipeline with various wapipe_output = await execute_pipeline(pipe_code="retrieve_then_answer",dynamic_output_concept_code="contracts.Fees",- input_memory={+ inputs={"text": load_text_from_path(path=text_path),"question": {"concept": "answer.Question",diff --git a/pipelex/kit/migrations/migrate_0.11.0_0.12.x.md b/pipelex/kit/migrations/migrate_0.11.0_0.12.x.mdindex 198a79b07..7959a4155 100644--- a/pipelex/kit/migrations/migrate_0.11.0_0.12.x.md+++ b/pipelex/kit/migrations/migrate_0.11.0_0.12.x.md@@ -973,7 +973,7 @@ from pipelex.cogt.extract.extract_worker_abstract import ExtractWorkerAbstract```pythonpipe_output = await execute_pipeline(pipe_code="ocr_page_contents_from_pdf",- input_memory={+ inputs={"ocr_input": PDFContent(url=pdf_url),},)@@ -983,7 +983,7 @@ pipe_output = await execute_pipeline(```pythonpipe_output = await execute_pipeline(pipe_code="extract_page_contents_from_pdf",- input_memory={+ inputs={"document": PDFContent(url=pdf_url),},)diff --git a/tests/e2e/pipelex/pipes/pipe_controller/pipe_sequence/test_pipe_sequence_with_input_memory.py b/tests/e2e/pipelex/pipes/pipe_controller/pipe_sequence/test_pipe_sequence_with_input_memory.pyindex a08b69b06..2ddc2c22c 100644--- a/tests/e2e/pipelex/pipes/pipe_controller/pipe_sequence/test_pipe_sequence_with_input_memory.py+++ b/tests/e2e/pipelex/pipes/pipe_controller/pipe_sequence/test_pipe_sequence_with_input_memory.py@@ -90,8 +90,8 @@ class TestPipeSequenceWithInputMemory:"""Test pipe sequence functionality with input memory."""async def test_optimize_tweet_sequence_with_input_memory(self):- """Test the optimize_tweet_sequence pipeline using input_memory parameter."""- # Execute the pipeline using input_memory+ """Test the optimize_tweet_sequence pipeline using inputs parameter."""+ # Execute the pipeline using inputspipe_output = await execute_pipeline(pipe_code="optimize_tweet_sequence",inputs={