From 296469417ddda7a18bf08d66ca39f167902de396 Mon Sep 17 00:00:00 2001 From: Thomas Hebrard Date: Mon, 16 Jun 2025 17:02:27 +0200 Subject: [PATCH] dev to release/v0.4.1 (#92) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix/codex-tests-makefile * feature/allow-codex-branch-names (#82) * Fix/mistral ocr image file type handling (#84) ### ๐Ÿ“ Description - mistral ocr image file type handling ### ๐Ÿ”„ Type of Change - [ ] ๐Ÿ› Bug fix - [ ] โœจ New feature - [ ] ๐Ÿ’ฅ Breaking change - [ ] ๐Ÿ“š Documentation update - [ ] ๐Ÿงน Code refactor - [ ] โšก Performance improvement - [X] โœ… Test update ### ๐Ÿงช Tests - test_ocr to test both png and jpeg * Feature/pipelex get instance (#85) - Make it safer and more tolerant to add domains from toml - Pipelex.get_instance() * Feature/epic docs and examples (#87) ### ๐Ÿ”— Related Issues ### ๐Ÿ“ Description - Docs - Rules - Polish - Breaking change: StuffFactory.make_stuff() arg `concept_code` renamed to `concept_str` because it bow tolerates concepts not fully formed, i.e. without domain, e.g. Text of PDF (implicit prefix is **_native_**) ### ๐Ÿ”„ Type of Change - [X] ๐Ÿ› Bug fix - [X] โœจ New feature - [X] ๐Ÿ’ฅ Breaking change - [XXX] ๐Ÿ“š Documentation update - [X] ๐Ÿงน Code refactor - [ ] โšก Performance improvement - [X] โœ… Test update ### ๐Ÿงช Tests - For concept refines: TestConceptRefinesValidationFunction and TestConceptPydanticFieldValidation * bump release/v0.4.0 * Changelog 0.4.0 and flow chart on one more example * Addition to changelog * fix gha docs * fix/discord-link (#90) * Fix/typo and hello world code (#91) * Typo fix * Added Hello-World-Code to docs * Changelog + bump version * changed changelog version --------- Co-authored-by: Louis Choquel Co-authored-by: Louis Choquel --- .cursor/rules/llms.mdc | 2 +- CHANGELOG.md | 7 ++- README.md | 4 +- docs/pages/cookbook-examples/hello-world.md | 53 ++++++++++++++++++++- docs/pages/installation/index.md | 2 +- mkdocs.yml | 2 +- pyproject.toml | 2 +- 7 files changed, 64 insertions(+), 8 deletions(-) diff --git a/.cursor/rules/llms.mdc b/.cursor/rules/llms.mdc index 6de8f9f08..94a66595e 100644 --- a/.cursor/rules/llms.mdc +++ b/.cursor/rules/llms.mdc @@ -17,7 +17,7 @@ An llm_handle matches the handle (an id of sorts) with the full specification of - llm_version - llm_platform_choice -The declaration of llm_handleslooks like this in toml syntax: +The declaration of llm_handles looks like this in toml syntax: ```toml [llm_handles] gpt-4o-2024-08-06 = { llm_name = "gpt-4o", llm_version = "2024-08-06" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 7f60f5767..9e3c3bbd2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## [v0.4.1] - 2025-06-16 + +- Changed discord link to the new one: https://go.pipelex.com/discord +- Added `hello-world` example in the `cookbook-examples` of the documentation. + ## [v0.4.0] - 2025-06-16 ### Highlight: Complete documentation overhaul @@ -113,7 +118,7 @@ is_reporting_enabled = true ## [v0.2.13] - 2025-06-06 -- Added Discord badge on the Readme. Join the community! -> https://discord.gg/SReshKQjWt +- Added Discord badge on the Readme. Join the community! -> https://go.pipelex.com/discord - Added a client for the Pipelex API. Join the waitlist -> https://www.pipelex.com/signup - Removed the `run_pipe_code` function. Replaced by `execute_pipeline` in `pipelex.pipeline.execute`. - Added llm deck `llm_for_img_to_text`. diff --git a/README.md b/README.md index 3529a2a7f..eaec2e984 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ alt="PyPI โ€“ latest release">

- Discord + Discord YouTube Website Cookbook @@ -275,7 +275,7 @@ We welcome contributions! Please see our [Contributing Guidelines](CONTRIBUTING. Join our vibrant Discord community to connect with other developers, share your experiences, and get help with your Pipelex projects! -[![Discord](https://img.shields.io/badge/Discord-5865F2?logo=discord&logoColor=white)](https://discord.gg/SReshKQjWt) +[![Discord](https://img.shields.io/badge/Discord-5865F2?logo=discord&logoColor=white)](https://go.pipelex.com/discord) ## ๐Ÿ’ฌ Support diff --git a/docs/pages/cookbook-examples/hello-world.md b/docs/pages/cookbook-examples/hello-world.md index c1f7dcddc..60bc763b2 100644 --- a/docs/pages/cookbook-examples/hello-world.md +++ b/docs/pages/cookbook-examples/hello-world.md @@ -10,6 +10,55 @@ You can find the complete code for this example in the Pipelex Cookbook reposito [**โžก๏ธ View on GitHub: quick_start/hello_world.py**](https://github.com/Pipelex/pipelex-cookbook/blob/main/quick_start/hello_world.py) +## The Pipeline Explained + +The `hello_world` function demonstrates the simplest possible Pipelex pipeline. It runs a single pipe that generates a haiku about "Hello World". + +```python +import asyncio + +from pipelex import pretty_print +from pipelex.pipelex import Pipelex +from pipelex.pipeline.execute import execute_pipeline + + +async def hello_world(): + + # Execute the pipeline + pipe_output, _ = await execute_pipeline( + pipe_code="hello_world", + ) + + # Print the output + pretty_print(pipe_output, title="Your first Pipelex output") + + +# start Pipelex +Pipelex.make() +# run sample using asyncio +asyncio.run(hello_world()) +``` + +This example shows the minimal setup needed to run a Pipelex pipeline: initialize Pipelex, execute a pipeline by its code name, and pretty-print the results. + +## The Pipeline Definition: `hello_world.toml` + +The pipeline definition is extremely simple - it's a single LLM call that generates a haiku: + +```toml +domain = "quick_start" +definition = "Discovering Pipelex" + +[pipe] +[pipe.hello_world] +PipeLLM = "Write text about Hello World." +output = "Text" +llm = { llm_handle = "gpt-4o-mini", temperature = 0.9, max_tokens = "auto" } +prompt = """ +Write a haiku about Hello World. +""" +``` + ## How to run 1. Clone the cookbook repository: @@ -25,4 +74,6 @@ You can find the complete code for this example in the Pipelex Cookbook reposito 4. Run the example: ```bash python quick_start/hello_world.py - ``` \ No newline at end of file + ``` + +Expected output: A haiku about "Hello World" displayed with pretty formatting. diff --git a/docs/pages/installation/index.md b/docs/pages/installation/index.md index 618dffb6a..a91431937 100644 --- a/docs/pages/installation/index.md +++ b/docs/pages/installation/index.md @@ -61,4 +61,4 @@ Learn more about pipelex_libraries in our [Libraries documentation](../build-rel - `pipelex init-config`: This cli command will create a `pipelex.toml` file at the root of the project, with basic configuration. This configuration file gathers all configuration for feature flags, logging, cost reporting, and so on... Learn more in our [Configuration documentation](../configuration/index.md) -๐Ÿ’ก _Any troubles? Have a look at our [Cookbook](https://github.com/Pipelex/pipelex-cookbook)! and come ask for help on our [Discord](https://discord.gg/SReshKQjWt)_ +๐Ÿ’ก _Any troubles? Have a look at our [Cookbook](https://github.com/Pipelex/pipelex-cookbook)! and come ask for help on our [Discord](https://go.pipelex.com/discord)_ diff --git a/mkdocs.yml b/mkdocs.yml index 67c537bed..bb376bd13 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -42,7 +42,7 @@ extra: link: https://x.com/PipelexAI name: Pipelex on X - icon: fontawesome/brands/discord - link: https://discord.gg/SReshKQjWt + link: https://go.pipelex.com/discord name: Pipelex on Discord generator: false diff --git a/pyproject.toml b/pyproject.toml index e1588192e..fd88ac582 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "pipelex" -version = "0.4.0" +version = "0.4.1" description = "Pipelex is an open-source dev tool based on a simple declarative language that lets you define replicable, structured, composable LLM pipelines." authors = [{ name = "Evotis S.A.S.", email = "evotis@pipelex.com" }] maintainers = [{ name = "Pipelex staff", email = "oss@pipelex.com" }]