conduct-cli 0.4.68__tar.gz → 0.4.70__tar.gz
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.
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/PKG-INFO +1 -1
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/pyproject.toml +1 -1
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/main.py +45 -23
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/PKG-INFO +1 -1
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/README.md +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/setup.cfg +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/setup.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/__init__.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/api.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/guard.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/guardmcp.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_precompact_template.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_session_start_template.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_template.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/mcp_server.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/SOURCES.txt +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/dependency_links.txt +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/entry_points.txt +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/requires.txt +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/top_level.txt +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_guard_policy.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_guard_savings.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_hook_syntax.py +0 -0
- {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_switch.py +0 -0
|
@@ -2188,45 +2188,67 @@ def cmd_session_report(args):
|
|
|
2188
2188
|
developer = getattr(args, "developer", None) or getpass.getuser()
|
|
2189
2189
|
hostname = socket.gethostname()
|
|
2190
2190
|
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
|
|
2191
|
+
volume = stats.get("volume", {})
|
|
2192
|
+
behavior = stats.get("behavior", {})
|
|
2193
|
+
autonomy = stats.get("autonomy", {})
|
|
2194
|
+
tools = stats.get("tools", {})
|
|
2195
|
+
velocity = stats.get("velocity", {})
|
|
2196
|
+
|
|
2197
|
+
sessions = volume.get("total_sessions", "?")
|
|
2198
|
+
prompts = volume.get("total_prompts", "?")
|
|
2199
|
+
autonomy_score = autonomy.get("autonomy_score_0_100", "?")
|
|
2200
|
+
top_tools = [t[0] for t in (tools.get("top_tools") or [])[:5]]
|
|
2201
|
+
commits = velocity.get("git_commits_real", "?") if isinstance(velocity, dict) else "?"
|
|
2202
|
+
|
|
2203
|
+
# Derive a simple archetype label from the data
|
|
2204
|
+
planning_ratio = behavior.get("planning_ratio_explore_to_doing", 0)
|
|
2205
|
+
if autonomy_score != "?" and float(autonomy_score) >= 70:
|
|
2206
|
+
archetype = "Autonomous Builder"
|
|
2207
|
+
elif planning_ratio != 0 and float(planning_ratio) > 1.0:
|
|
2208
|
+
archetype = "Strategic Planner"
|
|
2209
|
+
else:
|
|
2210
|
+
archetype = "Execution-Focused Builder"
|
|
2195
2211
|
|
|
2212
|
+
scores_raw = stats.get("scores", {})
|
|
2196
2213
|
payload = {
|
|
2197
2214
|
"developer": developer,
|
|
2198
2215
|
"hostname": hostname,
|
|
2199
|
-
"archetype": archetype
|
|
2200
|
-
"
|
|
2201
|
-
|
|
2216
|
+
"archetype": archetype,
|
|
2217
|
+
"competency_scores": {
|
|
2218
|
+
"Execution": scores_raw.get("Execution", scores_raw.get("execution", autonomy_score)),
|
|
2219
|
+
"Planning": scores_raw.get("Planning", scores_raw.get("planning", planning_ratio)),
|
|
2220
|
+
"Engineering": scores_raw.get("Engineering", scores_raw.get("engineering", commits)),
|
|
2221
|
+
},
|
|
2202
2222
|
"total_sessions": sessions,
|
|
2203
|
-
"tools_detected":
|
|
2204
|
-
"report_md": report_md[:4000],
|
|
2205
|
-
"raw_stats":
|
|
2223
|
+
"tools_detected": top_tools,
|
|
2224
|
+
"report_md": report_md[:4000],
|
|
2225
|
+
"raw_stats": {
|
|
2226
|
+
"volume": volume,
|
|
2227
|
+
"autonomy": autonomy,
|
|
2228
|
+
"top_tools": top_tools,
|
|
2229
|
+
"velocity": velocity,
|
|
2230
|
+
"scope": stats.get("scope", ""),
|
|
2231
|
+
},
|
|
2206
2232
|
}
|
|
2207
2233
|
|
|
2208
2234
|
# ── 4. Send to Conduct API ────────────────────────────────────────────────
|
|
2209
2235
|
print("Sending report to admin…")
|
|
2210
|
-
resp = api.
|
|
2211
|
-
|
|
2212
|
-
"/session-reports",
|
|
2213
|
-
payload,
|
|
2236
|
+
resp = api.req(
|
|
2237
|
+
"POST",
|
|
2238
|
+
f"{server}/session-reports",
|
|
2214
2239
|
hdrs,
|
|
2240
|
+
body=payload,
|
|
2215
2241
|
)
|
|
2216
2242
|
|
|
2217
2243
|
shutil.rmtree(tmpdir, ignore_errors=True)
|
|
2218
2244
|
|
|
2219
2245
|
if resp and resp.get("id"):
|
|
2220
|
-
arch = payload["archetype"]
|
|
2221
|
-
exec_score = competency.get("execution", competency.get("Execution", "?"))
|
|
2222
|
-
plan_score = competency.get("planning", competency.get("Planning", "?"))
|
|
2223
|
-
eng_score = competency.get("engineering", competency.get("Engineering", "?"))
|
|
2224
2246
|
print(f"\nReport sent.")
|
|
2225
|
-
print(f" Archetype : {
|
|
2226
|
-
print(f"
|
|
2227
|
-
print(f" Sessions : {sessions}")
|
|
2228
|
-
if
|
|
2229
|
-
print(f"
|
|
2247
|
+
print(f" Archetype : {archetype}")
|
|
2248
|
+
print(f" Autonomy : {autonomy_score}/100 Planning ratio: {planning_ratio}")
|
|
2249
|
+
print(f" Sessions : {sessions} Prompts: {prompts} Commits: {commits}")
|
|
2250
|
+
if top_tools:
|
|
2251
|
+
print(f" Top tools : {', '.join(top_tools)}")
|
|
2230
2252
|
else:
|
|
2231
2253
|
print(f"WARNING: server response unexpected: {resp}")
|
|
2232
2254
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|