refactor(packages/coding-agent): migrated imports to pi-ai submodules

- Migrated Effort and THINKING_EFFORTS imports to @oh-my-pi/pi-ai/effort in CLI args and launch command files.
- Split model-registry dependencies across focused @oh-my-pi/pi-ai submodules instead of the root barrel export.
This commit is contained in:
can1357
2026-06-06 22:58:33 +02:00
parent ba6cc67f38
commit 76f08dd7d3
3 changed files with 10 additions and 18 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
/**
* CLI argument parsing and help display
*/
import { type Effort, THINKING_EFFORTS } from "@oh-my-pi/pi-ai";
import { type Effort, THINKING_EFFORTS } from "@oh-my-pi/pi-ai/effort";
import { APP_NAME, CONFIG_DIR_NAME, logger } from "@oh-my-pi/pi-utils";
import chalk from "chalk";
import { parseEffort } from "../thinking";
+1 -1
View File
@@ -2,7 +2,7 @@
* Root command for the coding agent CLI.
*/
import { THINKING_EFFORTS } from "@oh-my-pi/pi-ai";
import { THINKING_EFFORTS } from "@oh-my-pi/pi-ai/effort";
import { APP_NAME } from "@oh-my-pi/pi-utils";
import { Args, Command, Flags } from "@oh-my-pi/pi-utils/cli";
import { parseArgs } from "../cli/args";
@@ -1,27 +1,19 @@
import * as path from "node:path";
import { registerCustomApi, unregisterCustomApis } from "@oh-my-pi/pi-ai/api-registry";
import { readModelCache } from "@oh-my-pi/pi-ai/model-cache";
import { createModelManager, type ModelManagerOptions, type ModelRefreshStrategy } from "@oh-my-pi/pi-ai/model-manager";
import { enrichModelThinking } from "@oh-my-pi/pi-ai/model-thinking";
import { getBundledModels, getBundledProviders } from "@oh-my-pi/pi-ai/models";
import {
type Api,
type AssistantMessageEventStream,
type Context,
createModelManager,
enrichModelThinking,
getBundledModels,
getBundledProviders,
googleAntigravityModelManagerOptions,
googleGeminiCliModelManagerOptions,
type Model,
type ModelManagerOptions,
type ModelRefreshStrategy,
openaiCodexModelManagerOptions,
PROVIDER_DESCRIPTORS,
readModelCache,
registerCustomApi,
type SimpleStreamOptions,
type ThinkingConfig,
UNK_CONTEXT_WINDOW,
UNK_MAX_TOKENS,
unregisterCustomApis,
} from "@oh-my-pi/pi-ai";
} from "@oh-my-pi/pi-ai/provider-models";
import type { Api, Context, Model, SimpleStreamOptions, ThinkingConfig } from "@oh-my-pi/pi-ai/types";
import type { AssistantMessageEventStream } from "@oh-my-pi/pi-ai/utils/event-stream";
// Sentinel for local-only OAuth token (LM Studio, vLLM) — declared inline to avoid loading
// any provider module at startup. Must match `DEFAULT_LOCAL_TOKEN` in oauth/lm-studio.ts.