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.
Files changed (24) hide show
  1. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/PKG-INFO +1 -1
  2. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/pyproject.toml +1 -1
  3. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/main.py +45 -23
  4. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/PKG-INFO +1 -1
  5. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/README.md +0 -0
  6. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/setup.cfg +0 -0
  7. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/setup.py +0 -0
  8. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/__init__.py +0 -0
  9. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/api.py +0 -0
  10. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/guard.py +0 -0
  11. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/guardmcp.py +0 -0
  12. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_precompact_template.py +0 -0
  13. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_session_start_template.py +0 -0
  14. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/hook_template.py +0 -0
  15. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli/mcp_server.py +0 -0
  16. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/SOURCES.txt +0 -0
  17. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/dependency_links.txt +0 -0
  18. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/entry_points.txt +0 -0
  19. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/requires.txt +0 -0
  20. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/src/conduct_cli.egg-info/top_level.txt +0 -0
  21. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_guard_policy.py +0 -0
  22. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_guard_savings.py +0 -0
  23. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_hook_syntax.py +0 -0
  24. {conduct_cli-0.4.68 → conduct_cli-0.4.70}/tests/test_switch.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: conduct-cli
3
- Version: 0.4.68
3
+ Version: 0.4.70
4
4
  Summary: CLI for Conduct AI — install agents, manage projects, run tests
5
5
  Author-email: Conduct AI <hello@conductai.ai>
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "conduct-cli"
7
- version = "0.4.68"
7
+ version = "0.4.70"
8
8
  description = "CLI for Conduct AI — install agents, manage projects, run tests"
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -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
- archetype = stats.get("archetype", {})
2192
- competency = stats.get("competency_scores", stats.get("competencies", {}))
2193
- sessions = stats.get("total_sessions", stats.get("session_count", "?"))
2194
- tools_used = stats.get("tools_detected", stats.get("tools", []))
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.get("name", archetype) if isinstance(archetype, dict) else str(archetype),
2200
- "archetype_description": archetype.get("description", "") if isinstance(archetype, dict) else "",
2201
- "competency_scores": competency,
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": tools_used,
2204
- "report_md": report_md[:4000], # cap to avoid huge payloads
2205
- "raw_stats": 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.post(
2211
- server,
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 : {arch}")
2226
- print(f" Execution : {exec_score} Planning: {plan_score} Engineering: {eng_score}")
2227
- print(f" Sessions : {sessions}")
2228
- if tools_used:
2229
- print(f" Tools : {', '.join(tools_used) if isinstance(tools_used, list) else tools_used}")
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
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: conduct-cli
3
- Version: 0.4.68
3
+ Version: 0.4.70
4
4
  Summary: CLI for Conduct AI — install agents, manage projects, run tests
5
5
  Author-email: Conduct AI <hello@conductai.ai>
6
6
  License: MIT
File without changes
File without changes
File without changes