flock-core 0.4.0b26__py3-none-any.whl → 0.4.0b28__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of flock-core might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flock-core
3
- Version: 0.4.0b26
3
+ Version: 0.4.0b28
4
4
  Summary: Declarative LLM Orchestration at Scale
5
5
  Author-email: Andre Ratzenberger <andre.ratzenberger@whiteduck.de>
6
6
  License-File: LICENSE
@@ -126,7 +126,7 @@ Flock's power comes from a few key ideas (Learn more in the [Full Documentation]
126
126
  6. **Tool Integration:** Equip agents with standard or custom Python functions (`@flock_tool`) registered via the `FlockRegistry`.
127
127
  7. **Registry:** A central place (`@flock_component`, `@flock_type`, `@flock_tool`) to register your custom classes, types, and functions, enabling robust serialization and dynamic loading.
128
128
 
129
- ## 💾 Installation
129
+ ## 💾 Installation - Use Flock in your project
130
130
 
131
131
  Get started with the core Flock library:
132
132
 
@@ -148,7 +148,27 @@ uv pip install flock-core[tools]
148
148
  uv pip install flock-core[all]
149
149
  ```
150
150
 
151
- Environment Setup:
151
+ ## 🔑 Installation - Develop Flock
152
+
153
+ ```bash
154
+ git clone https://github.com/whiteducksoftware/flock.git
155
+ cd flock
156
+
157
+ # One-liner dev setup after cloning
158
+ pip install poethepoet && poe install
159
+ ```
160
+
161
+ Additional provided `poe` tasks and commands:
162
+
163
+ ```bash
164
+ poe install # Install the project
165
+ poe build # Build the project
166
+ poe docs # Serve the docs
167
+ poe format # Format the code
168
+ poe lint # Lint the code
169
+ ```
170
+
171
+ ## 🔑 Environment Setup
152
172
 
153
173
  Flock uses environment variables (typically in a .env file) for configuration, especially API keys. Create a .env file in your project root:
154
174
 
@@ -173,7 +193,7 @@ DEFAULT_MODEL="openai/gpt-4o" # Default LLM if agent doesn't specify
173
193
  # VARS_PER_PAGE="20"
174
194
  ```
175
195
 
176
- Remember to add .env to your .gitignore!
196
+ Be sure that the .env file is added to your .gitignore!
177
197
 
178
198
  ## ⚡ Quick Start Syntax
179
199
 
@@ -216,13 +236,98 @@ if __name__ == "__main__":
216
236
 
217
237
  ## 🐤 New in Flock 0.4.0 `Magpie` 🐤
218
238
 
219
- ### REST API - Deploy Flock Agents as REST API Endpoints
239
+ Version 0.4.0 brings significant enhancements focused on usability, deployment, and robustness:
240
+
241
+
242
+ ### 🚀 REST API - Deploy Flock Agents as REST API Endpoints
243
+
244
+ Easily deploy your Flock agents as scalable REST API endpoints. Interact with your agent workflows via standard HTTP requests.
245
+
246
+ --------------------------------
247
+
248
+ ### 🖥️ Web UI - Test Flock Agents in the Browser
249
+
250
+ Test and interact with your Flock agents directly in your browser through an integrated web interface.
251
+
252
+ --------------------------------
253
+
254
+ ### ⌨️ CLI Tool - Manage Flock Agents via the Command Line
255
+
256
+ Manage Flock configurations, run agents, and inspect results directly from your command line.
257
+
258
+ --------------------------------
259
+
260
+ ### 💾 Enhanced Serialization - Share, Deploy, and Run Flock Agents by human readable yaml files
261
+
262
+ Define and share entire Flock configurations, including agents and components, using human-readable YAML files. Load flocks directly from these files for easy deployment and versioning.
220
263
 
221
- ### Web UI - Test Flock Agents in the Browser
264
+ --------------------------------
222
265
 
223
- ### CLI Tool - Manage Flock Agents via the Command Line
266
+ ### 💾 New execution flows
224
267
 
225
- ### Serialization - Share, Deploy, and Run Flock Agents by human readable yaml files
268
+ Run Flock in batch mode to process multiple inputs at once or in evaluation mode to test agents with different inputs.
269
+
270
+ --------------------------------
271
+
272
+ ### ⏱️ Robust Temporal Integration
273
+
274
+ Flock 0.4.0 introduces first-class support for Temporal.io, enabling you to build truly production-grade, reliable, and scalable agent workflows. Move beyond simple local execution and leverage Temporal's power for:
275
+
276
+ * **Fault Tolerance:** Workflows automatically resume from the last successful step after failures.
277
+ * **Retries:** Configure automatic retries for activities (like LLM calls or tool usage) with exponential backoff.
278
+ * **Scalability:** Distribute workflow and activity execution across multiple worker processes using Task Queues.
279
+ * **Observability:** Gain deep insights into workflow execution history via the Temporal UI.
280
+
281
+ Flock makes this easy with:
282
+
283
+ * **Declarative Configuration:** Define Temporal timeouts, retry policies, and task queues directly within your `Flock` and `FlockAgent` configurations (YAML or Python).
284
+ * **Correct Patterns:** Uses Temporal's recommended granular activity execution for better control and visibility.
285
+ * **Clear Worker Separation:** Provides guidance and flags for running dedicated Temporal workers, separating development convenience from production best practices.
286
+
287
+ Visit the [Temporal Documentation](https://learn.temporal.io/python/workflows/) for more information on how to use Temporal.
288
+
289
+ Or check out the [Flock Showcase](https://github.com/whiteducksoftware/flock-showcase) for a complete example of a Flock that uses Temporal or our [docs](https://whiteducksoftware.github.io/flock/guides/temporal-configuration/) for more information.
290
+
291
+ Here's an example of how to configure a Flock to use Temporal:
292
+
293
+ ```python
294
+ from flock.core import Flock, FlockFactory
295
+
296
+ from flock.workflow.temporal_config import (
297
+ TemporalActivityConfig,
298
+ TemporalRetryPolicyConfig,
299
+ TemporalWorkflowConfig,
300
+ )
301
+
302
+ # Flock-scoped temporal config
303
+ flock = Flock(
304
+ enable_temporal=True,
305
+ temporal_config=TemporalWorkflowConfig(
306
+ task_queue="flock-test-queue",
307
+ workflow_execution_timeout=timedelta(minutes=10),
308
+ default_activity_retry_policy=TemporalRetryPolicyConfig(
309
+ maximum_attempts=2
310
+ ),
311
+ ),
312
+ )
313
+
314
+ # Agent-scoped temporal config
315
+ content_agent = FlockFactory.create_default_agent(
316
+ name="content_agent",
317
+ input="funny_title, funny_slide_headers",
318
+ output="funny_slide_content",
319
+ temporal_activity_config=TemporalActivityConfig(
320
+ start_to_close_timeout=timedelta(minutes=1),
321
+ retry_policy=TemporalRetryPolicyConfig(
322
+ maximum_attempts=4,
323
+ initial_interval=timedelta(seconds=2),
324
+ non_retryable_error_types=["ValueError"],
325
+ ),
326
+ ),
327
+ )
328
+ ```
329
+
330
+ --------------------------------
226
331
 
227
332
  ### ✨ Utility: @flockclass Hydrator
228
333
 
@@ -255,6 +360,8 @@ async def create_character():
255
360
  # asyncio.run(create_character())
256
361
  ```
257
362
 
363
+ --------------------------------
364
+
258
365
  ## 📚 Examples & Tutorials
259
366
 
260
367
  For a comprehensive set of examples, ranging from basic usage to complex projects and advanced features, please visit our dedicated showcase repository:
@@ -19,11 +19,11 @@ flock/cli/view_results.py,sha256=dOzK0O1FHSIDERnx48y-2Xke9BkOHS7pcOhs64AyIg0,781
19
19
  flock/cli/yaml_editor.py,sha256=K3N0bh61G1TSDAZDnurqW9e_-hO6CtSQKXQqlDhCjVo,12527
20
20
  flock/cli/assets/release_notes.md,sha256=bqnk50jxM3w5uY44Dc7MkdT8XmRREFxrVBAG9XCOSSU,4896
21
21
  flock/core/__init__.py,sha256=p7lmQULRu9ejIAELfanZiyMhW0CougIPvyFHW2nqBFQ,847
22
- flock/core/flock.py,sha256=eymHQ4BT-mVT-ml4Eod13iuS5-sAskDgOa83qwAyFos,25776
23
- flock/core/flock_agent.py,sha256=9hAkWUpxxz2nFamTENFhLBzAFOdIfLZTQuVcn68G1l0,38890
22
+ flock/core/flock.py,sha256=_T_KAFePtEGDzfiFGV1HCdz7VHzj_U0cCquhAQ4xMAM,28199
23
+ flock/core/flock_agent.py,sha256=nga2x75EBUworW8TMJLzC0BdPZtX2G8lqJyPy-ac484,39027
24
24
  flock/core/flock_evaluator.py,sha256=dOXZeDOGZcAmJ9ahqq_2bdGUU1VOXY4skmwTVpAjiVw,1685
25
- flock/core/flock_factory.py,sha256=uRqcpu1fFbsDKp5YhGk47c6NjC36vAowQ3wzaQqmkBo,2972
26
- flock/core/flock_module.py,sha256=96aFVYAgwpKN53xGbivQDUpikOYGFCxK5mqhclOcxY0,3003
25
+ flock/core/flock_factory.py,sha256=_4zsjkEmJnCR7IvJ3SUHnDbX6c7Tt3E4P5ohxwKvE6w,3173
26
+ flock/core/flock_module.py,sha256=2MdAh-n0o4uw7jogvW9iHjVPUawUNN1oGor5ego3RLI,3057
27
27
  flock/core/flock_registry.py,sha256=Qcu9juUFNyDAOEsqVxauwVlWdfgKZrSzc8yT8JMiK-c,24246
28
28
  flock/core/flock_router.py,sha256=1OAXDsdaIIFApEfo6SRfFEDoTuGt3Si7n2MXiySEfis,2644
29
29
  flock/core/api/__init__.py,sha256=OKlhzDWZJfA6ddBwxQUmATY0TSzESsH032u00iVGvdA,228
@@ -35,14 +35,14 @@ flock/core/api/runner.py,sha256=PjKQyMNawHm_N-X2uTUWBKAKBe7AEzNmRIGwQI6tUWw,1156
35
35
  flock/core/api/ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
36
36
  flock/core/api/ui/routes.py,sha256=nS-wWO94mshE5ozWfOQZ-HOvtes_1qxDVcqpMZtU5JQ,8885
37
37
  flock/core/api/ui/utils.py,sha256=V7PqYHNK519hFJ8jvvwf7bGpbBXCRz_HQG3BDCCqlNA,4802
38
- flock/core/context/context.py,sha256=8bjRLZ74oacRNBaHmDNXdQKfB-95poF7Pp03n2k0zcQ,6437
38
+ flock/core/context/context.py,sha256=GFqMwYXLheqECGvWcxar7sQ2-GuY3RVynZ7kjwd65R0,6875
39
39
  flock/core/context/context_manager.py,sha256=FANSWa6DEhdhtZ7t_9Gza0v80UdpoDOhHbfVOccmjkA,1181
40
40
  flock/core/context/context_vars.py,sha256=ASPA29hpENWub4mgRoG62FtTVakCHQZfn6IhJQKe3C8,347
41
41
  flock/core/evaluation/utils.py,sha256=ZJkIMC9YT-HA2SPCZ4_bQ98isW1i6nbltVEYbjze-b0,12827
42
42
  flock/core/execution/batch_executor.py,sha256=nvsFOVaH4c4uPw_gwZ5jCIULpK59EL1kmcoPTja5kko,13745
43
43
  flock/core/execution/evaluation_executor.py,sha256=D9EO0sU-2qWj3vomjmUUi-DOtHNJNFRf30kGDHuzREE,17702
44
44
  flock/core/execution/local_executor.py,sha256=rnIQvaJOs6zZORUcR3vvyS6LPREDJTjaygl_Db0M8ao,952
45
- flock/core/execution/temporal_executor.py,sha256=ZDTdTI13UKIAFQmBGA9fISDmDfHNsKJIjcKLOXEvhro,1949
45
+ flock/core/execution/temporal_executor.py,sha256=dHcb0xuzPFWU_wbwTgI7glLNyyppei93Txs2sapjhaw,6283
46
46
  flock/core/interpreter/python_interpreter.py,sha256=RaUMZuufsKBNQ4FAeSaOgUuxzs8VYu5TgUUs-xwaxxM,26376
47
47
  flock/core/logging/__init__.py,sha256=Q8hp9-1ilPIUIV0jLgJ3_cP7COrea32cVwL7dicPnlM,82
48
48
  flock/core/logging/logging.py,sha256=JcgABQ8QJU1hhzhfF93eqnE0jhyXGZ2oObZst68sKR8,15409
@@ -80,14 +80,14 @@ flock/evaluators/declarative/declarative_evaluator.py,sha256=q3qKHuKrj17mhaoOZuK
80
80
  flock/evaluators/memory/memory_evaluator.py,sha256=ySwz7kcc8suXMJ7gKNSWThW8iOMlE8lUcUzEAHvv8rw,3559
81
81
  flock/evaluators/test/test_case_evaluator.py,sha256=3Emcoty0LOLLBIuPGxSpKphuZC9Fu1DTr1vbGg-hd0Q,1233
82
82
  flock/evaluators/zep/zep_evaluator.py,sha256=6_5vTdU0yJAH8I8w3-MPXiAZx6iUPhAVCsHjrHzkPLM,2058
83
- flock/modules/assertion/assertion_module.py,sha256=vzv38E8mvVBQXON_YJ8GFF4kB-sWNychQrMVFmugEjU,12860
84
- flock/modules/callback/callback_module.py,sha256=q2z-KX7QHlbfDncEP9c_W_DxhYyD6fe9MQfISO9OgrU,2939
85
- flock/modules/memory/memory_module.py,sha256=MBsUCpnMWY184PlZUKw91b8Yf0jCg9ixsxiqx2tK8LM,15020
83
+ flock/modules/assertion/assertion_module.py,sha256=gnHwWe3TCFEtbQrQ_Dvd1m62GvD71h-lsPlQbOJFKQ0,12863
84
+ flock/modules/callback/callback_module.py,sha256=k5995AaIqZ-aAbFOyFbq57ObpBEFM-BghE2KwnXdmII,2942
85
+ flock/modules/memory/memory_module.py,sha256=fXkR0JZTZbtUHk3e93-JLHe7_OCjPoa8qZbkHiX4qHI,15032
86
86
  flock/modules/memory/memory_parser.py,sha256=FLH7GL8XThvHiCMfX3eQH7Sz-f62fzhAUmO6_gaDI7U,4372
87
87
  flock/modules/memory/memory_storage.py,sha256=CNcLDMmvv0x7Z3YMKr6VveS_VCa7rKPw8l2d-XgqokA,27246
88
- flock/modules/output/output_module.py,sha256=V2g7UF538dwCe4J2QsemADMOnorGfK5Z995Q2ZIV7K4,7385
89
- flock/modules/performance/metrics_module.py,sha256=SptJzBmtVyVloi8-QtJ1jF0pBak1kelsMiZQfoeHr-4,16953
90
- flock/modules/zep/zep_module.py,sha256=uWhSXma4EIMt70L1_588FLnoLNmU8l7Vhhy1viRK1dk,6115
88
+ flock/modules/output/output_module.py,sha256=2QDW0voU9TZWlL2225k1W3xhWWTfjnfBheC4xIMyBDQ,7388
89
+ flock/modules/performance/metrics_module.py,sha256=G_2CFmPKM36wokrYKhWuGFM_CTOW2IdKfBDK7KYnUBk,16965
90
+ flock/modules/zep/zep_module.py,sha256=biR8oDBAMpyKWO4qTCD6yyRgPPqHwNr23CZ8JSFF3bY,6121
91
91
  flock/platform/docker_tools.py,sha256=fpA7-6rJBjPOUBLdQP4ny2QPgJ_042nmqRn5GtKnoYw,1445
92
92
  flock/platform/jaeger_install.py,sha256=MyOMJQx4TQSMYvdUJxfiGSo3YCtsfkbNXcAcQ9bjETA,2898
93
93
  flock/routers/__init__.py,sha256=w9uL34Auuo26-q_EGlE8Z9iHsw6S8qutTAH_ZI7pn7M,39
@@ -440,10 +440,12 @@ flock/themes/zenwritten-light.toml,sha256=G1iEheCPfBNsMTGaVpEVpDzYBHA_T-MV27rolU
440
440
  flock/workflow/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
441
441
  flock/workflow/activities.py,sha256=Rcgcepa-RzaEjKo2aNuI14O_sX8ij0RrqeyPa0oSw8M,9910
442
442
  flock/workflow/agent_activities.py,sha256=NhBZscflEf2IMfSRa_pBM_TRP7uVEF_O0ROvWZ33eDc,963
443
- flock/workflow/flock_workflow.py,sha256=I9MryXW_bqYVTHx-nl2epbTqeRy27CAWHHA7ZZA0nAk,1696
444
- flock/workflow/temporal_setup.py,sha256=epYMHdmTFC6njn3eaJOcs7E5yB0sxqHoMBvFeKSbKE8,1701
445
- flock_core-0.4.0b26.dist-info/METADATA,sha256=hX9OrCZRs6Neu4seUKingm6YggEYeTL9_aVcONqHreo,13004
446
- flock_core-0.4.0b26.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
447
- flock_core-0.4.0b26.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
448
- flock_core-0.4.0b26.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
449
- flock_core-0.4.0b26.dist-info/RECORD,,
443
+ flock/workflow/agent_execution_activity.py,sha256=Gy6FtuVAjf0NiUXmC3syS2eJpNQF4R3pmwMq47NYW3U,9462
444
+ flock/workflow/flock_workflow.py,sha256=iSUF_soFvWar0ffpkzE4irkDZRx0p4HnwmEBi_Ne2sY,9666
445
+ flock/workflow/temporal_config.py,sha256=3_8O7SDEjMsSMXsWJBfnb6XTp0TFaz39uyzSlMTSF_I,3988
446
+ flock/workflow/temporal_setup.py,sha256=YIHnSBntzOchHfMSh8hoLeNXrz3B1UbR14YrR6soM7A,1606
447
+ flock_core-0.4.0b28.dist-info/METADATA,sha256=6gX5rmbMq9bFCCegflDpQ_RH6JZyZiyRDy4l6_rV0Xs,17125
448
+ flock_core-0.4.0b28.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
449
+ flock_core-0.4.0b28.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
450
+ flock_core-0.4.0b28.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
451
+ flock_core-0.4.0b28.dist-info/RECORD,,