LLxprt Code

repository·main·Indexed 20 days ago

https://github.com/vybestack/llxprt-code

An AI-powered, provider-agnostic coding assistant for terminal-native workflows. It supports various LLMs (Anthropic, OpenAI, Gemini, Kimi, etc.) and local models via LM Studio or Ollama through an interactive REPL or CLI. Features include a VS Code companion extension for editor context and native diffing, a multi-provider architecture using the IProvider interface, and a behavioral evaluation system for validating non-deterministic LLM workflows.

Tokens
679.4K
Snippets
1.6K
Records
2.8K
Agent score
72%

What's inside @vybestack/llxprt-code

  1. Overview of the Todo List Implementation Plan

    main

    The Todo List feature is designed to provide LLMs with task management capabilities within the gemini-cli environment. It enables LLMs to track multi-step tasks, report progress to the user, maintain focus during complex workflows, and prevent the omission of critical steps.

    Key functional components include:

    • Task Tracking: Managing multi-step workflows.
    • Progress Visibility: Showing real-time status to the user.
    • Focus Maintenance: Ensuring the agent stays on track during long-running tasks.
  2. Overview of Agent API Capability Gaps (Plan PLAN-20260622-COREAPIGAP)

    main

    This plan addresses seven specific capability gaps in the @vybestack/llxprt-code-agents public API. These gaps currently prevent the CLI from interacting with the core engine through first-class Agent methods, forcing the use of agent.getConfig() escape hatches. The goal is to make the Agent facade adequate for all seven capabilities so that any UI (not just the CLI) can consume the core API directly.

    Resolved Capability Gaps

    GapTitleDescription
    G1Approval mode read/writeAccess and modify the engine's approval mode (e.g., getApprovalMode(), setApprovalMode()).
    G2Policy inspectionRead-only access to the policy engine, rules, and decision logic.
    G3Async-task adminManage asynchronous tasks (list, get, cancel) via /task functionality.
    G4Hooks administrationManage the hook system, including viewing and setting disabled hooks.
    G5Detailed OAuth stateAccess detailed authentication status and priority via OAuthManager.
    G6MCP OAuth + deep detailPerform the full MCP OAuth flow (authenticate → restart server → set tools) and refresh parity.
    G7Built-in tool-key storageAccess built-in tool-key storage (distinct from provider auth keys).
  3. Overview of OAuth Authentication Remediation Plan

    main

    The project-plans/authfixes-remediation/ directory contains a structured plan to resolve critical failures in the OAuth authentication implementation. The remediation focuses on five primary issue categories: security (cache clearing), persistence (token saving), provider implementation (Gemini OAuth), legacy migration (removing oauth_creds.json), and async initialization (fixing fire-and-forget patterns).

    Critical Path for Implementation:

    1. P1: Fix Gemini OAuth logout cache clearing.
    2. P2: Fix token persistence (MultiProviderTokenStore usage).
    3. P3: Implement real Gemini OAuth provider logic.

    Project Metadata:

    • Total Estimated Effort: 2-3 days
    • Risk Level: High (affects authentication system)
    • Backward Compatibility: Maintained
  4. Overview of Advanced Features

    main

    LLxprt Code provides several advanced capabilities for power users:

    • Settings & Profiles: Fine-tune model parameters and save them as reusable configurations.
    • Subagents: Create specialized assistants for different tasks with isolated contexts.
    • MCP Servers: Connect external tools and data sources via the Model Context Protocol.
    • Checkpointing: Save and resume complex, multi-turn conversations.
    • IDE Integration: Connect to VS Code and other editors for seamless workflow.
  5. Overview of the Auth Refactor (PLAN-20260608-ISSUE1586)

    main

    This plan outlines the architectural refactor of the authentication system to decouple packages/auth from the core, CLI, providers, and tools. The goal is to create a standalone authentication package with zero dependencies on the main project components.

    Key Architectural Changes:

    • Public Entry Point: AuthPrecedenceResolver serves as the primary public interface for authentication logic.
    • Adapter Pattern: Provider-specific authentication logic is handled via registered adapters.
    • OAuth Separation: The OAuth manager is split into two distinct parts: an auth domain interface and a CLI-specific implementation.
    • Auth Modes: A clean separation is established between direct authentication and proxy authentication.
  6. Overview of AppContainer.tsx Refactor (Issue #1576)

    main

    The AppContainer.tsx file in packages/cli/src/ui/ is being decomposed from a single 2,518-line file into a modular architecture based on React hooks and builders. The goal is to improve maintainability by ensuring no single file exceeds 800 lines and no single function exceeds 80 lines, while maintaining full test coverage and idempotency under React StrictMode.

    Target Directory Structure

    The new architecture resides in packages/cli/src/ui/containers/AppContainer/ and is organized into:

    • hooks/: Contains specialized logic (e.g., useInputHandling.ts, useOAuthOrchestration.ts, useKeybindings.ts).
    • builders/: Contains logic for constructing state and actions (e.g., buildUIState.ts, buildUIActions.ts).
    • AppContainer.tsx: The main entry point, reduced to ~650 lines.
  7. Core Public Agent API Gaps and Remediation Overview

    main

    The LLxprt Code core API is undergoing remediation to enable the refactoring of the CLI to consume the core API (#1595). The primary goal is to bridge six specific gaps between the existing createAgent(AgentConfig) implementation and the requirements for a fully functional, integrated agent surface.

    Identified Gaps

    • C1: Missing Config-injection seam: createAgent only accepts AgentConfig. A new fromConfig function is being added to allow agents to be initialized from an existing Config object.
    • C2: Missing Settings/Config surface: The Agent currently lacks methods to access or modify settings. New ephemeral get/set/getAll methods are being added.
    • C3: CLI Turn Routing: Current CLI turns do not route through agent.stream() or agent.chat(). Parity is being established to ensure turns use these methods.
    • H1: Missing Client Contract: The AgentClientContract is not currently exported from the curated API barrel (packages/agents/src/api/index.ts). It will be promoted there to serve as the stable public boundary.
    • H2: Provider Runtime Adoption: There is no seam to pass an existing ProviderManager into the runtime context. An optional providerManager? field is being added to IsolatedRuntimeContextOptions.
    • H3: Sequence Model Stub: getCurrentSequenceModel is currently a stub and will be implemented to delegate to the resolved client.

    Key Architectural Decisions

    • fromConfig is additive: It is a separate exported function, not an overload of createAgent. It accepts FromConfigOptions which includes an optional messageBus.
    • Non-breaking changes: The existing createAgent(AgentConfig) path and all current exports remain unchanged. The new providerManager? option is optional, ensuring backward compatibility.
    • Contract Promotion: AgentClientContract will be re-exported as a type-only export from packages/agents/src/api/index.ts.
  8. Review CodeRabbit and CodeQL Audit Summary

    main

    This audit summarizes findings from CodeQL (Security Scanning) and CodeRabbit (Inline and Body reviews) for PR #848.

    Audit Categories:

    • CodeQL: Focuses on security vulnerabilities like js/polynomial-redos.
    • CodeRabbit Inline: Comments directly on code diffs (e.g., logic errors, type mismatches, documentation errors).
    • CodeRabbit Outside Diff: Comments in the review body regarding general code quality, consistency, or files not included in the current diff (e.g., using Vitest vs Jest, logging system usage).
  9. A2A Implementation Phase Groups and Roadmap

    main

    The implementation is divided into five logical groups covering the lifecycle of the A2A Remote Agent:

    • Group 1: Foundation (P00a-P08): Preflight verification, Discriminated union types (breaking change), and A2A utilities (text extraction).
    • Group 2: Authentication (P09-P14): Auth provider abstraction, NoAuthProvider, and GoogleADCAuthProvider (requires google-auth-library).
    • Group 3: Core Infrastructure (P15-P23): A2AClientManager (requires @google/genai-a2a-sdk), Async AgentRegistry (breaking change), and RemoteAgentInvocation.
    • Group 4: Integration (P24-P32): Execution dispatch (breaking change), TOML integration, Integration fixes, Migration, and E2E testing.
    • Group 5: Completion (P33): Final verification against all 62 EARS requirements.
  10. Use LLxprt Code Companion Features

    main

    The extension provides several context-aware features for AI-assisted coding:

    • Open Editor File Context: The CLI gains awareness of all files currently open in your editor to understand project structure.
    • Selection Context: The CLI can access your cursor position and any text you have selected.
    • Native Diffing: When LLxprt Code suggests changes, they are displayed in a native VS Code diff view. You can review, accept, or reject these changes directly in the editor.
    • Quick Launch: You can start a new session via the Command Palette.
  11. Use the @vybestack/llxprt-code-ide-integration package

    main

    The @vybestack/llxprt-code-ide-integration package provides tools for IDE detection, managing IDE context, communicating with IDE companion MCP clients, and interacting with LSP (Language Server Protocol) services.

    While @vybestack/llxprt-code-core re-exports these symbols for backward compatibility, new integrations should ideally depend directly on @vybestack/llxprt-code-ide-integration to follow the project's acyclic dependency architecture (core -> ide-integration -> telemetry).