Convert gitgram/ and aitimemachine/ from embedded git repos (which showed as opaque submodule gitlinks on GitHub) into fully-tracked first-party content. AITM now merges its 7 vendored repos as first-party engines: - memory: beads (Go task DAG) + context7 (docs SDK), unified into saved_contexts - git: vendored C git (bundled binary) + gitnexus (in-process code intelligence) - agentic: a2a (@a2a-js/sdk) + pal (AITM-managed Python subprocess) Includes the full session's product build: Gitgram web/mobile/backend features, AITM website/CLI/MCP, the unified memory layer, engine build tooling (scripts/build-engines.sh, Dockerfile, CI), docs (README, ENGINES.md, ARCHITECTURE.md), and extensive test suites. Build artifacts, node_modules, external/, and gemini-cli are gitignored. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
49 lines
1.5 KiB
Python
49 lines
1.5 KiB
Python
"""Internal defaults and constants for clink."""
|
|
|
|
from __future__ import annotations
|
|
|
|
from dataclasses import dataclass, field
|
|
from pathlib import Path
|
|
|
|
DEFAULT_TIMEOUT_SECONDS = 1800
|
|
DEFAULT_STREAM_LIMIT = 10 * 1024 * 1024 # 10MB per stream
|
|
|
|
PROJECT_ROOT = Path(__file__).resolve().parent.parent
|
|
BUILTIN_PROMPTS_DIR = PROJECT_ROOT / "systemprompts" / "clink"
|
|
CONFIG_DIR = PROJECT_ROOT / "conf" / "cli_clients"
|
|
USER_CONFIG_DIR = Path.home() / ".pal" / "cli_clients"
|
|
|
|
|
|
@dataclass(frozen=True)
|
|
class CLIInternalDefaults:
|
|
"""Internal defaults applied to a CLI client during registry load."""
|
|
|
|
parser: str
|
|
additional_args: list[str] = field(default_factory=list)
|
|
env: dict[str, str] = field(default_factory=dict)
|
|
default_role_prompt: str | None = None
|
|
timeout_seconds: int = DEFAULT_TIMEOUT_SECONDS
|
|
runner: str | None = None
|
|
|
|
|
|
INTERNAL_DEFAULTS: dict[str, CLIInternalDefaults] = {
|
|
"gemini": CLIInternalDefaults(
|
|
parser="gemini_json",
|
|
additional_args=["-o", "json"],
|
|
default_role_prompt="systemprompts/clink/default.txt",
|
|
runner="gemini",
|
|
),
|
|
"codex": CLIInternalDefaults(
|
|
parser="codex_jsonl",
|
|
additional_args=["exec"],
|
|
default_role_prompt="systemprompts/clink/default.txt",
|
|
runner="codex",
|
|
),
|
|
"claude": CLIInternalDefaults(
|
|
parser="claude_json",
|
|
additional_args=["--print", "--output-format", "json"],
|
|
default_role_prompt="systemprompts/clink/default.txt",
|
|
runner="claude",
|
|
),
|
|
}
|