Files
LexAI/docs/MEMORY.md
john kevin asprec 2c00d2e431
Some checks failed
CI — Test & Build / Test & Build (pull_request) Has been cancelled
Preview — PR Build Check / PR Preview Build (pull_request) Has been cancelled
feat(cli): add initial CLI implementation with argument parsing and prompt handling
- Created package.json and package-lock.json for CLI package.
- Implemented argument parsing in args.ts to handle various flags and commands.
- Developed main CLI logic in cli.ts to execute commands and handle errors.
- Added configuration loading from a JSON file in config.ts, with environment variable support.
- Implemented prompt resolution and provider interaction in prompt.ts.
- Added usage documentation for the CLI.
- Configured TypeScript settings in tsconfig.json for the CLI package.
- Updated README in vscode package to reflect the new CLI functionality.
- Refactored root tsconfig.json to streamline project structure.
2026-08-13 19:19:42 +08:00

1.8 KiB

Project memory

Curated long-term knowledge. Hard cap: 60 lines of entries.

Verified facts

  • LexAI monorepo: packages/chrome (WXT), packages/vscode, packages/cli; shared src/lib.
  • Portable core: providers.ts, actions.ts, types.ts. Chrome-only: crypto.ts, messaging.ts.
  • Providers: OpenAI, Anthropic, Groq, OpenRouter — callProvider / PROVIDER_SPECS.
  • VS Code: Secret Storage; Code Assist; prefs lexai.*.
  • CLI: lexai prompt; LEXAI_API_KEY; optional ~/.lexai/config.json (no apiKey).
  • Chrome entrypoints: packages/chrome/entrypoints/; build → packages/chrome/.output/chrome-mv3/.
  • Selection minimum: MIN_SELECTION_LENGTH (10). Chrome onMessage must return true; snapshot before await.

Conventions

  • Style Chrome UI with inline styles (Tailwind not wired).
  • Prefer encrypted Chrome key path; keep plaintext apiKey fallback until migration.
  • VS Code / CLI must not import @lib/crypto or @lib/messaging.
  • Root scripts: install:all, chrome:*, vscode:*, cli:*.

Environment quirks

  • Node 22 pinned in CI; npx wxt prepare required before Chrome typecheck on fresh clone.
  • PowerShell may not accept && — chain with ; if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }.

Key paths and entry points

What Where
Chrome entrypoints packages/chrome/entrypoints/
Shared lib src/lib/
VS Code packages/vscode/
CLI packages/cli/
OSS meta root README.md, LICENSE, CONTRIBUTING.md, CODE_OF_CONDUCT.md
Issue/PR templates .gitea/ISSUE_TEMPLATE/, .gitea/PULL_REQUEST_TEMPLATE.md

Expiring notes

  • None yet.

Consolidation log

Date Action Reason
2026-08-13 Seeded after VS Code v1 /project-init stubs + port