@link-assistant/agent 0.18.3 → 0.19.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.
package/README.md CHANGED
@@ -514,7 +514,7 @@ The interactive prompt will guide you through configuring local or remote MCP se
514
514
 
515
515
  ### No Configuration Required
516
516
 
517
- - **WebSearch/CodeSearch**: Work without `LINK_ASSISTANT_AGENT_EXPERIMENTAL_EXA` environment variable (legacy `OPENCODE_EXPERIMENTAL_EXA` still supported)
517
+ - **WebSearch/CodeSearch**: Work without `LINK_ASSISTANT_AGENT_EXPERIMENTAL_EXA` environment variable
518
518
  - **Batch Tool**: Always enabled, no experimental flag needed
519
519
  - **All Tools**: No config files, API keys handled automatically
520
520
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@link-assistant/agent",
3
- "version": "0.18.3",
3
+ "version": "0.19.0",
4
4
  "description": "A minimal, public domain AI CLI agent compatible with OpenCode's JSON interface. Bun-only runtime.",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -66,7 +66,6 @@
66
66
  "@ai-sdk/openai": "^2.0.89",
67
67
  "@ai-sdk/openai-compatible": "^1.0.32",
68
68
  "@ai-sdk/xai": "^2.0.33",
69
- "@openrouter/ai-sdk-provider": "^2.2.3",
70
69
  "@clack/prompts": "^0.11.0",
71
70
  "@hono/standard-validator": "^0.2.0",
72
71
  "@hono/zod-validator": "^0.7.5",
@@ -75,6 +74,7 @@
75
74
  "@octokit/rest": "^22.0.1",
76
75
  "@openauthjs/openauth": "^0.4.3",
77
76
  "@opencode-ai/sdk": "^1.0.78",
77
+ "@openrouter/ai-sdk-provider": "^2.2.3",
78
78
  "@opentui/core": "^0.1.79",
79
79
  "@opentui/solid": "^0.1.79",
80
80
  "@parcel/watcher": "^2.5.1",
@@ -95,6 +95,7 @@
95
95
  "hono-openapi": "^1.1.1",
96
96
  "ignore": "^7.0.5",
97
97
  "jsonc-parser": "^3.3.1",
98
+ "lino-arguments": "^0.2.5",
98
99
  "lino-objects-codec": "^0.1.1",
99
100
  "log-lazy": "^1.0.4",
100
101
  "minimatch": "^10.1.1",
@@ -1,4 +1,4 @@
1
- import { Config } from '../config/config';
1
+ import { Config } from '../config/file-config';
2
2
  import z from 'zod';
3
3
  import { Provider } from '../provider/provider';
4
4
  import { generateObject, type ModelMessage } from 'ai';
package/src/bun/index.ts CHANGED
@@ -4,7 +4,7 @@ import { Log } from '../util/log';
4
4
  import path from 'path';
5
5
  import { NamedError } from '../util/error';
6
6
  import { readableStreamToText } from 'bun';
7
- import { Flag } from '../flag/flag';
7
+ import { config } from '../config/config';
8
8
  import { Lock } from '../util/lock';
9
9
 
10
10
  export namespace BunProc {
@@ -195,7 +195,7 @@ export namespace BunProc {
195
195
  }
196
196
 
197
197
  // Check for dry-run mode
198
- if (Flag.OPENCODE_DRY_RUN) {
198
+ if (config.dryRun) {
199
199
  log.info(() => ({
200
200
  message:
201
201
  '[DRY RUN] Would install package (skipping actual installation)',
@@ -5,7 +5,7 @@ import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/
5
5
  import * as prompts from '@clack/prompts';
6
6
  import { UI } from '../ui';
7
7
  import { Global } from '../../global';
8
- import { Config } from '../../config/config';
8
+ import { Config } from '../../config/file-config';
9
9
  import path from 'path';
10
10
  import fs from 'fs/promises';
11
11
 
@@ -2,7 +2,6 @@ import type { Argv } from 'yargs';
2
2
  import path from 'path';
3
3
  import { UI } from '../ui';
4
4
  import { cmd } from './cmd';
5
- import { Flag } from '../../flag/flag';
6
5
  import { Log } from '../../util/log';
7
6
  import { bootstrap } from '../bootstrap';
8
7
  import { Command } from '../../command';
@@ -110,7 +109,7 @@ export const RunCommand = cmd({
110
109
  },
111
110
  handler: async (args) => {
112
111
  // Note: verbose flag and logging are now initialized in middleware
113
- // See src/index.js main() function for the middleware that sets up Flag and Log.init()
112
+ // See src/index.js main() function for the middleware that sets up config and Log.init()
114
113
  let message = args.message.join(' ');
115
114
 
116
115
  const fileParts: any[] = [];
@@ -11,7 +11,7 @@ import { SessionPrompt } from '../session/prompt.ts';
11
11
  import { createEventHandler } from '../json-standard/index.ts';
12
12
  import { createContinuousStdinReader } from './input-queue.js';
13
13
  import { Log } from '../util/log.ts';
14
- import { Flag } from '../flag/flag.ts';
14
+ import { config } from '../config/config.ts';
15
15
  import { createVerboseFetch } from '../util/verbose-fetch.ts';
16
16
  import { outputStatus, outputError, outputInput } from './output.ts';
17
17
 
@@ -197,7 +197,7 @@ export async function runContinuousServerMode(
197
197
  compactionModel
198
198
  ) {
199
199
  // Check both CLI flag and environment variable for compact JSON mode
200
- const compactJson = argv['compact-json'] === true || Flag.COMPACT_JSON();
200
+ const compactJson = argv['compact-json'] === true || config.compactJson;
201
201
  const isInteractive = argv.interactive !== false;
202
202
  const autoMerge = argv['auto-merge-queued-messages'] !== false;
203
203
 
@@ -449,7 +449,7 @@ export async function runContinuousDirectMode(
449
449
  compactionModel
450
450
  ) {
451
451
  // Check both CLI flag and environment variable for compact JSON mode
452
- const compactJson = argv['compact-json'] === true || Flag.COMPACT_JSON();
452
+ const compactJson = argv['compact-json'] === true || config.compactJson;
453
453
  const isInteractive = argv.interactive !== false;
454
454
  const autoMerge = argv['auto-merge-queued-messages'] !== false;
455
455
 
package/src/cli/error.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { ConfigMarkdown } from '../config/markdown';
2
- import { Config } from '../config/config';
2
+ import { Config } from '../config/file-config';
3
3
  import { MCP } from '../mcp';
4
4
  import { UI } from './ui';
5
5
 
package/src/cli/output.ts CHANGED
@@ -10,7 +10,7 @@
10
10
  */
11
11
 
12
12
  import { EOL } from 'os';
13
- import { Flag } from '../flag/flag';
13
+ import { config } from '../config/config';
14
14
 
15
15
  /**
16
16
  * Output types for JSON messages
@@ -40,7 +40,7 @@ export interface OutputMessage {
40
40
 
41
41
  /**
42
42
  * Global compact JSON setting (can be set once at startup)
43
- * Initialized lazily from Flag.COMPACT_JSON() which checks AGENT_CLI_COMPACT env var
43
+ * Initialized lazily from config.compactJson which checks LINK_ASSISTANT_AGENT_COMPACT_JSON env var
44
44
  */
45
45
  let globalCompactJson: boolean | null = null;
46
46
 
@@ -49,8 +49,8 @@ let globalCompactJson: boolean | null = null;
49
49
  */
50
50
  export function setCompactJson(compact: boolean): void {
51
51
  globalCompactJson = compact;
52
- // Also update the Flag so other modules stay in sync
53
- Flag.setCompactJson(compact);
52
+ // Also update the config so other modules stay in sync
53
+ config.compactJson = compact;
54
54
  }
55
55
 
56
56
  /**
@@ -58,7 +58,7 @@ export function setCompactJson(compact: boolean): void {
58
58
  */
59
59
  export function isCompactJson(): boolean {
60
60
  if (globalCompactJson !== null) return globalCompactJson;
61
- return Flag.COMPACT_JSON();
61
+ return config.compactJson;
62
62
  }
63
63
 
64
64
  /**
@@ -1,5 +1,5 @@
1
1
  import z from 'zod';
2
- import { Config } from '../config/config';
2
+ import { Config } from '../config/file-config';
3
3
  import { Instance } from '../project/instance';
4
4
  import PROMPT_INITIALIZE from './template/initialize.txt';
5
5
  import { Bus } from '../bus';