@sayknow-cli/coding-agent 0.7.9 → 0.7.11

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,25 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.7.11] - 2026-10-22
6
+
7
+ ### Fixed
8
+
9
+ - Signed `thinking` and `redactedThinking` blocks stay inline in the session instead of being moved to the resident text cache. A lost cache file was replaced with placeholder text under the original signature, and Anthropic then rejected every request with `Invalid signature in thinking block`. Sessions that already lost such a blob now drop that reasoning block (text and signature together) instead of replaying the placeholder.
10
+ - Auto-compaction no longer fails with `Missing resident text blob` when old history already lost a resident blob; the spilled copy records the missing-content placeholder, so compaction can still replace the damaged history.
11
+ - A failed `/fork` rolled back to entries that still pointed into the resident store the fork had just disposed, so every large string in the session became unreadable afterwards. The rollback now restores the materialized entries.
12
+
13
+ ## [0.7.10] - 2026-10-20
14
+
15
+ ### Added
16
+
17
+ - Bundled plugin `verification-receipts` (`packages/coding-agent/bundles/verification-receipts`, checkout install with `skc plugin install ... --user`). It adds `verification_run` (bun test or node --test on explicit files, per-file attribution, immutable freshness-bound receipts in a private store), `verification_status` and `verification_loop`, plus hooks that record a delegation gate when a background `task` starts and remind when it finishes. Advisory only; node:test needs Node 24.11.1 or newer.
18
+ - `gitlab` tool (opt-in with `gitlab.enabled`, registered when `glab` is installed): `mr_create` (returns an existing open MR instead of a duplicate, never prompts), `mr_view`, `mr_list`, and `ci_status` for gitlab.com and self-hosted instances known to `glab auth login`.
19
+
20
+ ### Fixed
21
+
22
+ - `--tools` naming a plugin-bundle, custom, or MCP tool no longer disables every tool. The parser dropped names that were not built-in, so `--tools verification_run` became an empty allowlist (the zero-tool selection), and a plugin tool requested by name was quarantined as a collision with its own request. Names now resolve against the session registry, which logs the unknown ones.
23
+
5
24
  ## [0.7.9] - 2026-10-17
6
25
 
7
26
  ### Fixed
@@ -3276,6 +3276,15 @@ export declare const SETTINGS_SCHEMA: {
3276
3276
  readonly description: "Enable the github tool (op-based dispatch for repository, issue, pull request, diff, search, checkout, push, and Actions watch workflows)";
3277
3277
  };
3278
3278
  };
3279
+ readonly "gitlab.enabled": {
3280
+ readonly type: "boolean";
3281
+ readonly default: false;
3282
+ readonly ui: {
3283
+ readonly tab: "tools";
3284
+ readonly label: "GitLab CLI";
3285
+ readonly description: "Enable the gitlab tool (op-based dispatch for merge request create/view/list and pipeline status via glab)";
3286
+ };
3287
+ };
3279
3288
  readonly "github.cache.enabled": {
3280
3289
  readonly type: "boolean";
3281
3290
  readonly default: true;
@@ -0,0 +1,128 @@
1
+ import type { AgentTool, AgentToolContext, AgentToolResult } from "@sayknow-cli/agent-core";
2
+ import * as z from "zod/v4";
3
+ import type { ToolSession } from ".";
4
+ import type { OutputMeta } from "./output-meta";
5
+ declare const gitlabSchema: z.ZodObject<{
6
+ op: z.ZodEnum<{
7
+ mr_create: "mr_create";
8
+ mr_view: "mr_view";
9
+ mr_list: "mr_list";
10
+ ci_status: "ci_status";
11
+ }>;
12
+ repo: z.ZodOptional<z.ZodString>;
13
+ mr: z.ZodOptional<z.ZodString>;
14
+ title: z.ZodOptional<z.ZodString>;
15
+ description: z.ZodOptional<z.ZodString>;
16
+ source: z.ZodOptional<z.ZodString>;
17
+ target: z.ZodOptional<z.ZodString>;
18
+ draft: z.ZodOptional<z.ZodBoolean>;
19
+ fill: z.ZodOptional<z.ZodBoolean>;
20
+ push: z.ZodOptional<z.ZodBoolean>;
21
+ reviewer: z.ZodOptional<z.ZodArray<z.ZodString>>;
22
+ assignee: z.ZodOptional<z.ZodArray<z.ZodString>>;
23
+ label: z.ZodOptional<z.ZodArray<z.ZodString>>;
24
+ removeSourceBranch: z.ZodOptional<z.ZodBoolean>;
25
+ squash: z.ZodOptional<z.ZodBoolean>;
26
+ state: z.ZodOptional<z.ZodEnum<{
27
+ all: "all";
28
+ opened: "opened";
29
+ merged: "merged";
30
+ closed: "closed";
31
+ }>>;
32
+ branch: z.ZodOptional<z.ZodString>;
33
+ limit: z.ZodOptional<z.ZodNumber>;
34
+ }, z.core.$strict>;
35
+ type GitlabInput = z.infer<typeof gitlabSchema>;
36
+ export interface GlabUser {
37
+ username?: string;
38
+ name?: string;
39
+ }
40
+ export interface GlabPipeline {
41
+ id?: number;
42
+ status?: string;
43
+ ref?: string;
44
+ sha?: string;
45
+ web_url?: string;
46
+ created_at?: string;
47
+ updated_at?: string;
48
+ jobs?: GlabJob[];
49
+ }
50
+ export interface GlabJob {
51
+ name?: string;
52
+ stage?: string;
53
+ status?: string;
54
+ web_url?: string;
55
+ failure_reason?: string;
56
+ allow_failure?: boolean;
57
+ }
58
+ export interface GlabMergeRequest {
59
+ iid?: number;
60
+ title?: string;
61
+ description?: string | null;
62
+ state?: string;
63
+ draft?: boolean;
64
+ web_url?: string;
65
+ source_branch?: string;
66
+ target_branch?: string;
67
+ author?: GlabUser | null;
68
+ reviewers?: GlabUser[] | null;
69
+ labels?: string[] | null;
70
+ created_at?: string;
71
+ updated_at?: string;
72
+ detailed_merge_status?: string;
73
+ has_conflicts?: boolean;
74
+ head_pipeline?: GlabPipeline | null;
75
+ }
76
+ export interface GitlabToolDetails {
77
+ meta?: OutputMeta;
78
+ op: GitlabInput["op"];
79
+ url?: string;
80
+ iid?: number;
81
+ created?: boolean;
82
+ }
83
+ export declare function formatMergeRequest(mr: GlabMergeRequest, heading: string): string;
84
+ export declare function formatPipeline(pipeline: GlabPipeline): string;
85
+ export declare class GitlabTool implements AgentTool<typeof gitlabSchema, GitlabToolDetails> {
86
+ #private;
87
+ private readonly session;
88
+ readonly name = "gitlab";
89
+ readonly summary = "Create and inspect GitLab merge requests and pipelines";
90
+ readonly loadMode = "discoverable";
91
+ readonly label = "GitLab";
92
+ readonly description: string;
93
+ readonly parameters: z.ZodObject<{
94
+ op: z.ZodEnum<{
95
+ mr_create: "mr_create";
96
+ mr_view: "mr_view";
97
+ mr_list: "mr_list";
98
+ ci_status: "ci_status";
99
+ }>;
100
+ repo: z.ZodOptional<z.ZodString>;
101
+ mr: z.ZodOptional<z.ZodString>;
102
+ title: z.ZodOptional<z.ZodString>;
103
+ description: z.ZodOptional<z.ZodString>;
104
+ source: z.ZodOptional<z.ZodString>;
105
+ target: z.ZodOptional<z.ZodString>;
106
+ draft: z.ZodOptional<z.ZodBoolean>;
107
+ fill: z.ZodOptional<z.ZodBoolean>;
108
+ push: z.ZodOptional<z.ZodBoolean>;
109
+ reviewer: z.ZodOptional<z.ZodArray<z.ZodString>>;
110
+ assignee: z.ZodOptional<z.ZodArray<z.ZodString>>;
111
+ label: z.ZodOptional<z.ZodArray<z.ZodString>>;
112
+ removeSourceBranch: z.ZodOptional<z.ZodBoolean>;
113
+ squash: z.ZodOptional<z.ZodBoolean>;
114
+ state: z.ZodOptional<z.ZodEnum<{
115
+ all: "all";
116
+ opened: "opened";
117
+ merged: "merged";
118
+ closed: "closed";
119
+ }>>;
120
+ branch: z.ZodOptional<z.ZodString>;
121
+ limit: z.ZodOptional<z.ZodNumber>;
122
+ }, z.core.$strict>;
123
+ readonly strict = true;
124
+ constructor(session: ToolSession);
125
+ static createIf(session: ToolSession): GitlabTool | null;
126
+ execute(_toolCallId: string, params: GitlabInput, signal?: AbortSignal, _onUpdate?: unknown, _context?: AgentToolContext): Promise<AgentToolResult<GitlabToolDetails>>;
127
+ }
128
+ export {};
@@ -42,6 +42,7 @@ export * from "./debug";
42
42
  export * from "./eval";
43
43
  export * from "./find";
44
44
  export * from "./gh";
45
+ export * from "./gitlab";
45
46
  export * from "./image-gen";
46
47
  export * from "./irc";
47
48
  export * from "./job";
@@ -390,4 +390,25 @@ export declare const github: {
390
390
  /** Run `gh` and return stdout as text. Throws on non-zero exit. */
391
391
  text(cwd: string, args: string[], signal?: AbortSignal, options?: GhCommandOptions): Promise<string>;
392
392
  };
393
+ export interface GlabCommandOptions {
394
+ repoProvided?: boolean;
395
+ }
396
+ /** Collapse glab's boxed, ANSI-colored error banner into one plain line. */
397
+ export declare function cleanGlabMessage(text: string): string;
398
+ export declare function formatGlabFailure(args: readonly string[], stdout: string, stderr: string, options?: GlabCommandOptions): string;
399
+ /**
400
+ * Parse `glab --output json` stdout. glab prints deprecation/update notices on stdout ahead of the
401
+ * payload in some versions, so parsing starts at the first line that opens a JSON value.
402
+ */
403
+ export declare function parseGlabJson<T>(stdout: string): T;
404
+ export declare const gitlab: {
405
+ /** Check if `glab` CLI is installed. */
406
+ available(): boolean;
407
+ /** Run a raw non-interactive `glab` command. Does not throw on non-zero exit. */
408
+ run(cwd: string, args: string[], signal?: AbortSignal): Promise<GhCommandResult>;
409
+ /** Run `glab` and parse stdout as JSON. Throws on non-zero exit or invalid JSON. */
410
+ json<T>(cwd: string, args: string[], signal?: AbortSignal, options?: GlabCommandOptions): Promise<T>;
411
+ /** Run `glab` and return stdout as text. Throws on non-zero exit. */
412
+ text(cwd: string, args: string[], signal?: AbortSignal, options?: GlabCommandOptions): Promise<string>;
413
+ };
393
414
  export {};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@sayknow-cli/coding-agent",
4
- "version": "0.7.9",
4
+ "version": "0.7.11",
5
5
  "description": "Sayknow-CLI CLI with read, bash, edit, write tools and session management",
6
6
  "homepage": "https://sayknow-cli.com",
7
7
  "author": "jaybeyond",
@@ -54,12 +54,12 @@
54
54
  "@agentclientprotocol/sdk": "1.3.0",
55
55
  "@babel/parser": "^7.29.3",
56
56
  "@mozilla/readability": "^0.6.0",
57
- "@sayknow-cli/stats": "0.7.9",
58
- "@sayknow-cli/agent-core": "0.7.9",
59
- "@sayknow-cli/ai": "0.7.9",
60
- "@sayknow-cli/natives": "0.7.9",
61
- "@sayknow-cli/tui": "0.7.9",
62
- "@sayknow-cli/utils": "0.7.9",
57
+ "@sayknow-cli/stats": "0.7.11",
58
+ "@sayknow-cli/agent-core": "0.7.11",
59
+ "@sayknow-cli/ai": "0.7.11",
60
+ "@sayknow-cli/natives": "0.7.11",
61
+ "@sayknow-cli/tui": "0.7.11",
62
+ "@sayknow-cli/utils": "0.7.11",
63
63
  "@puppeteer/browsers": "^2.13.0",
64
64
  "@types/turndown": "5.0.6",
65
65
  "@xterm/headless": "^6.0.0",
package/src/cli/args.ts CHANGED
@@ -3,10 +3,8 @@
3
3
  */
4
4
  import * as path from "node:path";
5
5
  import { type Effort, THINKING_EFFORTS } from "@sayknow-cli/ai";
6
- import { logger } from "@sayknow-cli/utils";
7
6
  import { CliParseError } from "@sayknow-cli/utils/cli";
8
7
  import { parseEffort } from "../thinking";
9
- import { BUILTIN_TOOLS } from "../tools";
10
8
 
11
9
  export type Mode = "text" | "json" | "acp";
12
10
 
@@ -189,22 +187,18 @@ export function parseArgs(args: string[]): Args {
189
187
  } else if (arg === "--tmux") {
190
188
  result.tmux = true;
191
189
  } else if (arg === "--tools" && i + 1 < args.length) {
192
- const toolNames = args[++i]
193
- .split(",")
194
- .map(s => s.trim().toLowerCase())
195
- .filter(Boolean);
196
- const validTools: string[] = [];
197
- for (const name of toolNames) {
198
- if (name in BUILTIN_TOOLS) {
199
- validTools.push(name);
200
- } else {
201
- logger.warn("Unknown tool passed to --tools", {
202
- tool: name,
203
- validTools: Object.keys(BUILTIN_TOOLS),
204
- });
205
- }
206
- }
207
- result.tools = validTools;
190
+ // Keep non-builtin names: custom, plugin-bundle, and MCP tools are only
191
+ // known once the session registry is built, which resolves (and warns
192
+ // about) names that match nothing. Dropping them here turned
193
+ // `--tools <plugin_tool>` into an empty list, which disables every tool.
194
+ result.tools = [
195
+ ...new Set(
196
+ args[++i]
197
+ .split(",")
198
+ .map(s => s.trim().toLowerCase())
199
+ .filter(Boolean),
200
+ ),
201
+ ];
208
202
  } else if (arg === "--thinking") {
209
203
  // Match --credential / --mcp-config: a missing value or a following flag is
210
204
  // a usage error, not a silent no-op / accidental consumption of `-p`.
@@ -2772,6 +2772,17 @@ export const SETTINGS_SCHEMA = {
2772
2772
  },
2773
2773
  },
2774
2774
 
2775
+ "gitlab.enabled": {
2776
+ type: "boolean",
2777
+ default: false,
2778
+ ui: {
2779
+ tab: "tools",
2780
+ label: "GitLab CLI",
2781
+ description:
2782
+ "Enable the gitlab tool (op-based dispatch for merge request create/view/list and pipeline status via glab)",
2783
+ },
2784
+ },
2785
+
2775
2786
  "github.cache.enabled": {
2776
2787
  type: "boolean",
2777
2788
  default: true,
@@ -589,6 +589,9 @@ export const deSettings: Record<string, string> = {
589
589
  "skill-Tool aktivieren, damit der Agent im nächsten Zug zu einer anderen verfügbaren Skill wechseln kann",
590
590
  "set:fetch.enabled:l": "URLs lesen",
591
591
  "set:fetch.enabled:d": "read-Tool das Abrufen und Verarbeiten von URLs erlauben",
592
+ "set:gitlab.enabled:l": "GitLab CLI",
593
+ "set:gitlab.enabled:d":
594
+ "gitlab-Werkzeug aktivieren (op-basierte Ausführung für Merge-Request-Erstellung/-Ansicht/-Liste und Pipeline-Status über glab)",
592
595
  "set:github.enabled:d":
593
596
  "github-Tool aktivieren (operationsbasiertes Dispatching für Repository, Issue, Pull Request, Diff, Suche, Checkout, Push und Actions-Watch-Workflows)",
594
597
  "set:github.cache.enabled:l": "GitHub-Ansichts-Cache",
@@ -573,6 +573,9 @@ export const esSettings: Record<string, string> = {
573
573
  "Habilitar la herramienta skill para que el agente pueda encadenar otra skill disponible en su siguiente turno",
574
574
  "set:fetch.enabled:l": "Leer URLs",
575
575
  "set:fetch.enabled:d": "Permitir que la herramienta read obtenga y procese URLs",
576
+ "set:gitlab.enabled:l": "GitLab CLI",
577
+ "set:gitlab.enabled:d":
578
+ "Habilitar la herramienta gitlab (despacho por op para crear/ver/listar merge requests y estado de pipelines mediante glab)",
576
579
  "set:github.enabled:d":
577
580
  "Habilitar la herramienta github (despacho basado en operaciones para repositorios, issues, pull requests, diff, búsqueda, checkout, push y flujos de monitoreo de Actions)",
578
581
  "set:github.cache.enabled:l": "Caché de vistas de GitHub",
@@ -560,6 +560,9 @@ export const frSettings: Record<string, string> = {
560
560
  "Activer l'outil skill pour que l'agent puisse enchaîner vers une autre skill disponible à son prochain tour",
561
561
  "set:fetch.enabled:l": "Lire les URL",
562
562
  "set:fetch.enabled:d": "Autoriser l'outil read à récupérer et traiter les URL",
563
+ "set:gitlab.enabled:l": "GitLab CLI",
564
+ "set:gitlab.enabled:d":
565
+ "Activer l'outil gitlab (répartition par op pour créer/afficher/lister les merge requests et l'état des pipelines via glab)",
563
566
  "set:github.enabled:d":
564
567
  "Activer l'outil github (dispatch par opérations pour dépôt, issue, pull request, diff, recherche, checkout, push et workflows de surveillance Actions)",
565
568
  "set:github.cache.enabled:l": "Cache des vues GitHub",
@@ -596,6 +596,9 @@ export const jaSettings: Record<string, string> = {
596
596
  "set:skill.enabled:d": "エージェントが次のターンで別の利用可能なスキルに連鎖できるよう skill ツールを有効化",
597
597
  "set:fetch.enabled:l": "URL を読み込む",
598
598
  "set:fetch.enabled:d": "read ツールが URL を取得・処理できるよう許可",
599
+ "set:gitlab.enabled:l": "GitLab CLI",
600
+ "set:gitlab.enabled:d":
601
+ "gitlab ツールを有効化 (glab によるマージリクエストの作成/表示/一覧とパイプライン状態の op ベースのディスパッチ)",
599
602
  "set:github.enabled:d":
600
603
  "github ツールを有効化(リポジトリ、Issue、プルリクエスト、diff、検索、チェックアウト、プッシュ、Actions ウォッチワークフローに対する op ベースのディスパッチ)",
601
604
  "set:github.cache.enabled:l": "GitHub ビューキャッシュ",
@@ -590,6 +590,9 @@ export const koSettings: Record<string, string> = {
590
590
  "set:skill.enabled:d": "에이전트가 다음 턴에 사용 가능한 다른 스킬로 연결할 수 있도록 skill 도구 활성화",
591
591
  "set:fetch.enabled:l": "URL 읽기",
592
592
  "set:fetch.enabled:d": "read 도구가 URL을 가져와 처리하도록 허용",
593
+ "set:gitlab.enabled:l": "GitLab CLI",
594
+ "set:gitlab.enabled:d":
595
+ "gitlab 도구 활성화 (glab을 통한 머지 리퀘스트 생성/조회/목록 및 파이프라인 상태에 대한 op 기반 디스패치)",
593
596
  "set:github.enabled:d":
594
597
  "github 도구 활성화 (리포지토리, 이슈, 풀 리퀘스트, diff, 검색, 체크아웃, 푸시, Actions 워치 워크플로에 대한 op 기반 디스패치)",
595
598
  "set:github.cache.enabled:l": "GitHub 뷰 캐시",
@@ -574,6 +574,8 @@ export const zhSettings: Record<string, string> = {
574
574
  "set:skill.enabled:d": "启用 skill 工具,使代理可在下一轮链接到另一个可用技能",
575
575
  "set:fetch.enabled:l": "读取 URL",
576
576
  "set:fetch.enabled:d": "允许 read 工具获取并处理 URL",
577
+ "set:gitlab.enabled:l": "GitLab CLI",
578
+ "set:gitlab.enabled:d": "启用 gitlab 工具(通过 glab 对合并请求创建/查看/列表及流水线状态进行基于 op 的调度)",
577
579
  "set:github.enabled:d":
578
580
  "启用 github 工具(针对仓库、议题、拉取请求、diff、搜索、检出、推送和 Actions 监视工作流的基于 op 的分发)",
579
581
  "set:github.cache.enabled:l": "GitHub 视图缓存",