flock-core 0.5.0b57__py3-none-any.whl → 0.5.0b58__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.

@@ -103,9 +103,9 @@ class WebSocketManager:
103
103
  # Store streaming output events for history (always, even if no clients)
104
104
  if isinstance(event, StreamingOutputEvent):
105
105
  self._streaming_history[event.agent_name].append(event)
106
- logger.debug(
107
- f"Stored streaming event for {event.agent_name}, history size: {len(self._streaming_history[event.agent_name])}"
108
- )
106
+ # logger.debug(
107
+ # f"Stored streaming event for {event.agent_name}, history size: {len(self._streaming_history[event.agent_name])}"
108
+ # )
109
109
 
110
110
  # If no clients, still log but don't broadcast
111
111
  if not self.clients:
@@ -115,11 +115,11 @@ class WebSocketManager:
115
115
  return
116
116
 
117
117
  # Log broadcast attempt
118
- logger.debug(f"Broadcasting {type(event).__name__} to {len(self.clients)} client(s)")
118
+ # logger.debug(f"Broadcasting {type(event).__name__} to {len(self.clients)} client(s)")
119
119
 
120
120
  # Serialize event to JSON using Pydantic's model_dump_json
121
121
  message = event.model_dump_json()
122
- logger.debug(f"Event JSON: {message[:200]}...") # Log first 200 chars
122
+ # logger.debug(f"Event JSON: {message[:200]}...") # Log first 200 chars
123
123
 
124
124
  # Broadcast to all clients concurrently
125
125
  # Use return_exceptions=True to handle client failures gracefully
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "flock-ui",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "flock-ui",
9
- "version": "0.1.2",
9
+ "version": "0.1.3",
10
10
  "license": "ISC",
11
11
  "dependencies": {
12
12
  "@types/dagre": "^0.7.53",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flock-core
3
- Version: 0.5.0b57
3
+ Version: 0.5.0b58
4
4
  Summary: Add your description here
5
5
  Author-email: Andre Ratzenberger <andre.ratzenberger@whiteduck.de>
6
6
  License-File: LICENSE
@@ -62,7 +62,8 @@ prompt = """You are an expert code reviewer. When you receive code, you should..
62
62
 
63
63
  # 500-line prompt that breaks when models update
64
64
 
65
- # How do I know that there isn't an even better prompt (you don't) -> proof of 'best possible performane' impossible
65
+ # How do I know that there isn't an even better prompt (you don't)
66
+ # -> proof of 'best possible performane' impossible
66
67
  ```
67
68
 
68
69
  **🧪 Testing Nightmares**
@@ -88,7 +89,8 @@ workflow.add_edge("agent_b", "agent_c")
88
89
  **🧠 God object anti-pattern:**
89
90
  ```python
90
91
  # One orchestrator needs domain knowledge of 20+ agents to route correctly
91
- # Orchestrator 'guesses' next agent based on a natural language description. Hardly fit for critical systems.
92
+ # Orchestrator 'guesses' next agent based on a natural language description.
93
+ # Hardly fit for critical systems.
92
94
  ```
93
95
 
94
96
  These aren't framework limitations, they're **architectural choices** that don't scale.
@@ -105,8 +107,51 @@ Flock takes a different path, combining two proven patterns:
105
107
 
106
108
  **Traditional approach:**
107
109
  ```python
108
- prompt = "Analyze this bug report and return JSON with severity, category, hypothesis..."
109
- result = llm.invoke(prompt) # Hope it works
110
+ prompt = """You are an expert software engineer and bug analyst. Your task is to analyze bug reports and provide structured diagnostic information.
111
+
112
+ INSTRUCTIONS:
113
+ 1. Read the bug report carefully
114
+ 2. Determine the severity level (must be exactly one of: Critical, High, Medium, Low)
115
+ 3. Classify the bug category (e.g., "performance", "security", "UI", "data corruption")
116
+ 4. Formulate a root cause hypothesis (minimum 50 characters)
117
+ 5. Assign a confidence score between 0.0 and 1.0
118
+
119
+ OUTPUT FORMAT:
120
+ You MUST return valid JSON with this exact structure:
121
+ {
122
+ "severity": "string (Critical|High|Medium|Low)",
123
+ "category": "string",
124
+ "root_cause_hypothesis": "string (minimum 50 characters)",
125
+ "confidence_score": "number (0.0 to 1.0)"
126
+ }
127
+
128
+ VALIDATION RULES:
129
+ - severity: Must be exactly one of: Critical, High, Medium, Low (case-sensitive)
130
+ - category: Must be a single word or short phrase describing the bug type
131
+ - root_cause_hypothesis: Must be at least 50 characters long and explain the likely cause
132
+ - confidence_score: Must be a decimal number between 0.0 and 1.0 inclusive
133
+
134
+ EXAMPLES:
135
+ Input: "App crashes when user clicks submit button"
136
+ Output: {"severity": "Critical", "category": "crash", "root_cause_hypothesis": "Null pointer exception in form validation logic when required fields are empty", "confidence_score": 0.85}
137
+
138
+ Input: "Login button has wrong color"
139
+ Output: {"severity": "Low", "category": "UI", "root_cause_hypothesis": "CSS class override not applied correctly in the theme configuration", "confidence_score": 0.9}
140
+
141
+ IMPORTANT:
142
+ - Do NOT include any explanatory text before or after the JSON
143
+ - Do NOT use markdown code blocks (no ```json```)
144
+ - Do NOT add comments in the JSON
145
+ - Ensure the JSON is valid and parseable
146
+ - If you cannot determine something, use your best judgment
147
+ - Never return null values
148
+
149
+ Now analyze this bug report:
150
+ {bug_report_text}"""
151
+
152
+ result = llm.invoke(prompt) # 500-line prompt that breaks when models update
153
+ # Then parse and hope it's valid JSON
154
+ data = json.loads(result.content) # Crashes in production 🔥
110
155
  ```
111
156
 
112
157
  **The Flock way:**
@@ -18,12 +18,12 @@ flock/dashboard/collector.py,sha256=dF8uddDMpOSdxGkhDSAvRNNaABo-TfOceipf1SQmLSU,
18
18
  flock/dashboard/events.py,sha256=ujdmRJK-GQubrv43qfQ73dnrTj7g39VzBkWfmskJ0j8,5234
19
19
  flock/dashboard/launcher.py,sha256=zXWVpyLNxCIu6fJ2L2j2sJ4oDWTvkxhT4FWz7K6eooM,8122
20
20
  flock/dashboard/service.py,sha256=5QGPT2xSbMx6Zd9_GSKJ8QtxOnBucx9BZAQhpWyUfgw,32097
21
- flock/dashboard/websocket.py,sha256=gGJPNLy4OR-0eTKJQ3oFmZVjCq-ulMNrKJVFCFcprhU,9003
21
+ flock/dashboard/websocket.py,sha256=RdJ7fhjNYJR8WHJ19wWdf9GEQtuKE14NmUpqm-QsLnA,9013
22
22
  flock/engines/__init__.py,sha256=waNyObJ8PKCLFZL3WUFynxSK-V47m559P3Px-vl_OSc,124
23
23
  flock/engines/dspy_engine.py,sha256=Q2gPYLW_f8f-JuBYOMtjtoCZH8Fc447zWF8cHpJl4ew,34538
24
24
  flock/frontend/README.md,sha256=OFdOItV8FGifmUDb694rV2xLC0vl1HlR5KBEtYv5AB0,25054
25
25
  flock/frontend/index.html,sha256=BFg1VR_YVAJ_MGN16xa7sT6wTGwtFYUhfJhGuKv89VM,312
26
- flock/frontend/package-lock.json,sha256=5c-ZQHqHYZ2CHlsyHOBss-tncxplSuHO3mddWt_-jJM,150998
26
+ flock/frontend/package-lock.json,sha256=F-KmPhq6IbHXzxtmHL0S7dt6DGs4fWrOkrfKeXaSx6U,150998
27
27
  flock/frontend/package.json,sha256=X5mMewghkW5K03Y4CI6unF2GIGbV0QoS-kZ04RNtQ3k,1258
28
28
  flock/frontend/tsconfig.json,sha256=B9p9jXohg_jrCZAq5_yIHvznpeXHiHQkwUZrVE2oMRA,705
29
29
  flock/frontend/tsconfig.node.json,sha256=u5_YWSqeNkZBRBIZ8Q2E2q6bospcyF23mO-taRO7glc,233
@@ -508,8 +508,8 @@ flock/themes/zenburned.toml,sha256=UEmquBbcAO3Zj652XKUwCsNoC2iQSlIh-q5c6DH-7Kc,1
508
508
  flock/themes/zenwritten-dark.toml,sha256=-dgaUfg1iCr5Dv4UEeHv_cN4GrPUCWAiHSxWK20X1kI,1663
509
509
  flock/themes/zenwritten-light.toml,sha256=G1iEheCPfBNsMTGaVpEVpDzYBHA_T-MV27rolUYolmE,1666
510
510
  flock/utility/output_utility_component.py,sha256=yVHhlIIIoYKziI5UyT_zvQb4G-NsxCTgLwA1wXXTTj4,9047
511
- flock_core-0.5.0b57.dist-info/METADATA,sha256=U4Iyr6iRPGRwYsXAGJQ0C2Ioy5FoLLjj2mMBVf5kGKQ,32802
512
- flock_core-0.5.0b57.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
513
- flock_core-0.5.0b57.dist-info/entry_points.txt,sha256=UQdPmtHd97gSA_IdLt9MOd-1rrf_WO-qsQeIiHWVrp4,42
514
- flock_core-0.5.0b57.dist-info/licenses/LICENSE,sha256=U3IZuTbC0yLj7huwJdldLBipSOHF4cPf6cUOodFiaBE,1072
515
- flock_core-0.5.0b57.dist-info/RECORD,,
511
+ flock_core-0.5.0b58.dist-info/METADATA,sha256=1frs-b0VPrAk3XwsqCa6pG03VeE0cDID7WtFsMeeezQ,34719
512
+ flock_core-0.5.0b58.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
513
+ flock_core-0.5.0b58.dist-info/entry_points.txt,sha256=UQdPmtHd97gSA_IdLt9MOd-1rrf_WO-qsQeIiHWVrp4,42
514
+ flock_core-0.5.0b58.dist-info/licenses/LICENSE,sha256=U3IZuTbC0yLj7huwJdldLBipSOHF4cPf6cUOodFiaBE,1072
515
+ flock_core-0.5.0b58.dist-info/RECORD,,