flock-core 0.4.520__py3-none-any.whl → 0.4.521__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.

@@ -413,6 +413,7 @@ class FlockFactory:
413
413
  write_to_file: bool = False,
414
414
  stream: bool = False,
415
415
  include_thought_process: bool = False,
416
+ include_reasoning: bool = False,
416
417
  temporal_activity_config: TemporalActivityConfig | None = None,
417
418
  ) -> FlockAgent:
418
419
  """Creates a default FlockAgent.
@@ -433,6 +434,7 @@ class FlockFactory:
433
434
  max_retries=max_retries,
434
435
  stream=stream,
435
436
  include_thought_process=include_thought_process,
437
+ include_reasoning=include_reasoning,
436
438
  )
437
439
 
438
440
  evaluator = DeclarativeEvaluator(name="default", config=eval_config)
@@ -36,6 +36,10 @@ class DeclarativeEvaluatorConfig(FlockEvaluatorConfig):
36
36
  default=False,
37
37
  description="Include the thought process in the output.",
38
38
  )
39
+ include_reasoning: bool = Field(
40
+ default=False,
41
+ description="Include the reasoning in the output.",
42
+ )
39
43
  kwargs: dict[str, Any] = Field(default_factory=dict)
40
44
 
41
45
 
@@ -154,6 +158,9 @@ class DeclarativeEvaluator(
154
158
  self._lm_history = lm_history
155
159
 
156
160
  console.print("\n")
161
+ result_dict = self.filter_reasoning(
162
+ result_dict, self.config.include_reasoning
163
+ )
157
164
  return self.filter_thought_process(
158
165
  result_dict, self.config.include_thought_process
159
166
  )
@@ -170,6 +177,9 @@ class DeclarativeEvaluator(
170
177
  )
171
178
  self._cost = cost
172
179
  self._lm_history = lm_history
180
+ result_dict = self.filter_reasoning(
181
+ result_dict, self.config.include_reasoning
182
+ )
173
183
  return self.filter_thought_process(
174
184
  result_dict, self.config.include_thought_process
175
185
  )
@@ -190,5 +200,18 @@ class DeclarativeEvaluator(
190
200
  return {
191
201
  k: v
192
202
  for k, v in result_dict.items()
193
- if not (k.startswith("reasoning") or k.startswith("trajectory"))
203
+ if not (k.startswith("trajectory"))
204
+ }
205
+
206
+ def filter_reasoning(
207
+ self, result_dict: dict[str, Any], include_reasoning: bool
208
+ ) -> dict[str, Any]:
209
+ """Filter out reasoning from the result dictionary."""
210
+ if include_reasoning:
211
+ return result_dict
212
+ else:
213
+ return {
214
+ k: v
215
+ for k, v in result_dict.items()
216
+ if not (k.startswith("reasoning"))
194
217
  }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flock-core
3
- Version: 0.4.520
3
+ Version: 0.4.521
4
4
  Summary: Declarative LLM Orchestration at Scale
5
5
  Author-email: Andre Ratzenberger <andre.ratzenberger@whiteduck.de>
6
6
  License-File: LICENSE
@@ -29,7 +29,7 @@ flock/core/__init__.py,sha256=juwyNr3QqKXUS5-E3hlMYRhgqHgQBqgtP12OF3tUCAI,1249
29
29
  flock/core/flock.py,sha256=iR4i0_z0w2ns_iHbP7FqN--7wlsPIWch1H-BVecPs_I,38205
30
30
  flock/core/flock_agent.py,sha256=Hl6TONSiJi2I-N_49-1hkW2q_hyPXMebMr-5oZLI-PY,48842
31
31
  flock/core/flock_evaluator.py,sha256=TPy6u6XX3cqkY1r9NW1w2lTwCMNW7pxhFYKLefnEbXg,1820
32
- flock/core/flock_factory.py,sha256=siCShld0mHPzjsw2_TUhg_nesMYhocJympt1M8ch6p8,18724
32
+ flock/core/flock_factory.py,sha256=QI5qzxSyg3z3T3wRHoTOyegeaquyfUO5cJjpT_QgRl8,18814
33
33
  flock/core/flock_module.py,sha256=ObILimpVaPnaaqYvcBYJJ20lQzfrjgTdADplaNRjHU0,7448
34
34
  flock/core/flock_registry.py,sha256=KzdFfc3QC-Dk42G24hdf6Prp3HvGj9ymXR3TTBe-T-A,27161
35
35
  flock/core/flock_router.py,sha256=1OAXDsdaIIFApEfo6SRfFEDoTuGt3Si7n2MXiySEfis,2644
@@ -97,7 +97,7 @@ flock/core/util/loader.py,sha256=j3q2qem5bFMP2SmMuYjb-ISxsNGNZd1baQmpvAnRUUk,224
97
97
  flock/core/util/splitter.py,sha256=rDLnZX158PWkmW8vi2UfMLAMRXcHQFUIydAABd-lDGw,7154
98
98
  flock/evaluators/__init__.py,sha256=Y0cEkx0dujRmy--TDpKoTqFSLzbyFz8BwEOv8kdSUhg,22
99
99
  flock/evaluators/declarative/__init__.py,sha256=Y0cEkx0dujRmy--TDpKoTqFSLzbyFz8BwEOv8kdSUhg,22
100
- flock/evaluators/declarative/declarative_evaluator.py,sha256=tulTpUOXhF-wMe5a9ULpsCiS1o2Z-DOXOUTqOSzVYqI,7397
100
+ flock/evaluators/declarative/declarative_evaluator.py,sha256=vEdScni2uzOKFliFgSZEE1mgcDWM0s9MdOEga6a_nUM,8186
101
101
  flock/evaluators/memory/memory_evaluator.py,sha256=ySwz7kcc8suXMJ7gKNSWThW8iOMlE8lUcUzEAHvv8rw,3559
102
102
  flock/evaluators/test/test_case_evaluator.py,sha256=3Emcoty0LOLLBIuPGxSpKphuZC9Fu1DTr1vbGg-hd0Q,1233
103
103
  flock/evaluators/zep/zep_evaluator.py,sha256=6_5vTdU0yJAH8I8w3-MPXiAZx6iUPhAVCsHjrHzkPLM,2058
@@ -562,8 +562,8 @@ flock/workflow/agent_execution_activity.py,sha256=Gy6FtuVAjf0NiUXmC3syS2eJpNQF4R
562
562
  flock/workflow/flock_workflow.py,sha256=iSUF_soFvWar0ffpkzE4irkDZRx0p4HnwmEBi_Ne2sY,9666
563
563
  flock/workflow/temporal_config.py,sha256=3_8O7SDEjMsSMXsWJBfnb6XTp0TFaz39uyzSlMTSF_I,3988
564
564
  flock/workflow/temporal_setup.py,sha256=YIHnSBntzOchHfMSh8hoLeNXrz3B1UbR14YrR6soM7A,1606
565
- flock_core-0.4.520.dist-info/METADATA,sha256=0dDV8IbiheDnn0O-Tm6c0poo7h7kAq7U4vMzcrRk8dc,22786
566
- flock_core-0.4.520.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
567
- flock_core-0.4.520.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
568
- flock_core-0.4.520.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
569
- flock_core-0.4.520.dist-info/RECORD,,
565
+ flock_core-0.4.521.dist-info/METADATA,sha256=Iv--hXNCNCWGgnK0hrK8Jk4hXFRkg1k-m1OTg5Kil4U,22786
566
+ flock_core-0.4.521.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
567
+ flock_core-0.4.521.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
568
+ flock_core-0.4.521.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
569
+ flock_core-0.4.521.dist-info/RECORD,,