codegpt-ai 2.3.0 → 2.7.0

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 (2) hide show
  1. package/chat.py +61 -9
  2. package/package.json +1 -1
package/chat.py CHANGED
@@ -1236,15 +1236,67 @@ def print_header(model):
1236
1236
  mem_count = len(load_memories())
1237
1237
 
1238
1238
  console.print()
1239
- # Claude Code style banner — red and blue
1240
- console.print(Text.from_markup(
1241
- "[bold red] ╭─────────────────────────────────╮[/]\n"
1242
- "[bold red] │[/] [bold red]│[/]\n"
1243
- "[bold red] │[/] [bold red]Code[/][bold bright_blue]GPT[/] [dim]v2.0[/] [bold red]│[/]\n"
1244
- "[bold red] │[/] [dim]local ai · 123 commands[/] [bold red]│[/]\n"
1245
- "[bold red] │[/] [bold red]│[/]\n"
1246
- "[bold red] ╰─────────────────────────────────╯[/]"
1247
- ))
1239
+
1240
+ # Banner parts
1241
+ R = "bold red"
1242
+ B = "bold bright_blue"
1243
+ D = "dim"
1244
+
1245
+ def build_banner(pos):
1246
+ """Build banner with spider at given position (0-7 around the border)."""
1247
+ sp_faces = [" /╲(o.o)╱\\", " /╲(o.o)╱\\", "~~~(o.o)>", "~~~(o.o)>",
1248
+ " \\╱(o.o)╲/", " \\╱(o.o)╲/", "<(o.o)~~~", "<(o.o)~~~"]
1249
+ spider = sp_faces[pos % 8]
1250
+
1251
+ top_b = f"[{R}] ╔════════════════════════════════════════════════════╗[/]"
1252
+ bot_b = f"[{R}] ╚════════════════════════════════════════════════════╝[/]"
1253
+ empty = f"[{R}] ║[/] [{R}]║[/]"
1254
+ title = f"[{R}] ║[/] [{R}]C[/][{B}]o[/][{R}]d[/][{B}]e[/] [{R}]G[/][{B}]P[/][{R}]T[/] [{D}]v2.0[/] [{R}]║[/]"
1255
+ sub = f"[{R}] ║[/] [{D}]local ai · powered by ollama[/] [{R}]║[/]"
1256
+ stats = f"[{R}] ║[/] [{B}]123[/] [{D}]commands ·[/] [{B}]26[/] [{D}]tools ·[/] [{B}]8[/] [{D}]agents[/] [{R}]║[/]"
1257
+
1258
+ lines = []
1259
+ p = pos % 8
1260
+
1261
+ if p in (0, 1): # top
1262
+ lines.append(f"[{D}] {spider}[/]")
1263
+ lines.append(f"[{D}] ||[/]")
1264
+ lines.extend([top_b, empty, title, sub, stats, empty, bot_b])
1265
+ elif p in (2, 3): # right
1266
+ lines.append(top_b)
1267
+ lines.append(empty)
1268
+ lines.append(title)
1269
+ lines.append(f"[{R}] ║[/] [{D}]local ai · powered by ollama[/] [{R}]║[/][{D}]~~{spider}[/]")
1270
+ lines.extend([stats, empty, bot_b])
1271
+ elif p in (4, 5): # bottom
1272
+ lines.extend([top_b, empty, title, sub, stats, empty, bot_b])
1273
+ lines.append(f"[{D}] ||[/]")
1274
+ lines.append(f"[{D}] {spider}[/]")
1275
+ else: # left (6, 7)
1276
+ lines.append(top_b)
1277
+ lines.append(empty)
1278
+ lines.append(f"[{D}]{spider}~~[/][{R}]║[/] [{R}]C[/][{B}]o[/][{R}]d[/][{B}]e[/] [{R}]G[/][{B}]P[/][{R}]T[/] [{D}]v2.0[/] [{R}]║[/]")
1279
+ lines.extend([sub, stats, empty, bot_b])
1280
+
1281
+ return "\n".join(lines)
1282
+
1283
+ # Animate spider crawling around the banner
1284
+ try:
1285
+ with Live(
1286
+ Text.from_markup(build_banner(0)),
1287
+ console=console, refresh_per_second=6, transient=True,
1288
+ ) as live:
1289
+ for frame in range(16): # 2 full laps
1290
+ live.update(Text.from_markup(build_banner(frame)))
1291
+ time.sleep(0.2)
1292
+
1293
+ # Final position — static
1294
+ import random
1295
+ final = random.randint(0, 7)
1296
+ console.print(Text.from_markup(build_banner(final)))
1297
+ except Exception:
1298
+ # Fallback if Live doesn't work
1299
+ console.print(Text.from_markup(build_banner(0)))
1248
1300
  console.print()
1249
1301
  console.print(Text.from_markup(
1250
1302
  f" [dim]model[/] [bright_blue]{model}[/]\n"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codegpt-ai",
3
- "version": "2.3.0",
3
+ "version": "2.7.0",
4
4
  "description": "Local AI Assistant Hub — 80+ commands, 29 tools, 8 agents, training, security",
5
5
  "author": "ArukuX",
6
6
  "license": "MIT",